Пример #1
0
			<tbody>
			<?php 
foreach ($this->items as $i => $l) {
    $checked = JHTML::_('grid.id', $i, $l->id);
    $published = JHTML::_('grid.published', $l, $i);
    $link = JRoute::_('index.php?option=com_matukio&controller=eventlist&task=editEvent&id=' . $l->id);
    $curdate = MatukioHelperUtilsDate::getCurrentDate();
    $booked = MatukioHelperUtilsEvents::calculateBookedPlaces($l)->booked;
    $status_img = MatukioHelperUtilsBasic::getStatusImage($l);
    $available_img = MatukioHelperUtilsBasic::getAvailableImage($l, $booked);
    $bookable_image = MatukioHelperUtilsBasic::getBookableImage($l);
    $rating_image = MatukioHelperUtilsBasic::getRatingImage($l);
    // Triggers publish / unpublish
    $published_image = MatukioHelperUtilsBasic::getPublishedImage($l, $i);
    // Triggers canceld / active
    $cancel_image = MatukioHelperUtilsBasic::getCancelImage($l, $i);
    $title = strlen($l->title) < 70 ? $l->title : substr($l->title, 0, 67) . "...";
    $category = strlen($l->category) < 25 ? $l->title : substr($l->category, 0, 22) . "...";
    $begin = JHTML::_('date', $l->begin, MatukioHelperSettings::getSettings('date_format_without_time', 'd-m-Y')) . ", " . JHTML::_('date', $l->begin, MatukioHelperSettings::getSettings('time_format', 'H:i'));
    $end = JHTML::_('date', $l->end, MatukioHelperSettings::getSettings('date_format_without_time', 'd-m-Y')) . ", " . JHTML::_('date', $l->end, MatukioHelperSettings::getSettings('time_format', 'H:i'));
    $bplaces = '<a href="index.php?option=com_matukio&view=bookings&event_id=' . $l->id . '" value="' . $booked . '">' . $booked . "</a>";
    ?>
				<tr class="<?php 
    echo "row" . $i % 2;
    ?>
">
					<td>
						<a onclick="window.parent.selectEvent('<?php 
    echo $l->id;
    ?>
',