Slider home page fix menu mobile
This commit is contained in:
@ -73,7 +73,7 @@ var swiper = new Swiper(".carosellofeatured", {
|
||||
|
||||
|
||||
|
||||
<div class="featured">
|
||||
<div class="featured mt-5">
|
||||
<?php if ($this->params->get('show_page_heading') != 0) : ?>
|
||||
<div class="titolo-featured">
|
||||
<?php echo $this->escape($this->params->get('page_heading')); ?>
|
||||
@ -100,10 +100,6 @@ var swiper = new Swiper(".carosellofeatured", {
|
||||
<?php $blogClass .= (int) $this->params->get('num_columns'); ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="swiper-controls container">
|
||||
<div class="swiper-button-next swiper-button-next"></div>
|
||||
<div class="swiper-button-prev swiper-button-prev"></div>
|
||||
</div>
|
||||
<div class="swiper carosellofeatured">
|
||||
<div class="swiper-wrapper">
|
||||
<?php foreach ($this->intro_items as $key => &$item) : ?>
|
||||
@ -116,7 +112,11 @@ var swiper = new Swiper(".carosellofeatured", {
|
||||
</div>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="swiper-controls container">
|
||||
<div class="swiper-button-next swiper-button-next"></div>
|
||||
<div class="swiper-button-prev swiper-button-prev"></div>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
415
templates/joomla-italia-theme/html/com_jem/category/calendar.php
Normal file
415
templates/joomla-italia-theme/html/com_jem/category/calendar.php
Normal file
@ -0,0 +1,415 @@
|
||||
<?php
|
||||
/**
|
||||
* @package JEM
|
||||
* @copyright (C) 2013-2024 joomlaeventmanager.net
|
||||
* @copyright (C) 2005-2009 Christoph Lukes
|
||||
* @license https://www.gnu.org/licenses/gpl-3.0 GNU/GPL
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Router\Route;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
|
||||
?>
|
||||
|
||||
<div id="jem" class="jlcalendar jem_calendar<?php echo $this->pageclass_sfx;?>">
|
||||
<div class="buttons">
|
||||
<?php
|
||||
$btn_params = array('print_link' => $this->print_link, 'ical_link' => $this->ical_link);
|
||||
echo JemOutput::createButtonBar($this->getName(), $this->permissions, $btn_params);
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php if ($this->params->get('show_page_heading', 1)): ?>
|
||||
<h1 class="componentheading">
|
||||
<?php echo $this->escape($this->params->get('page_heading')); ?>
|
||||
</h1>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ($this->params->get('showintrotext')) : ?>
|
||||
<div class="description no_space floattext">
|
||||
<?php echo $this->params->get('introtext'); ?>
|
||||
</div>
|
||||
<p> </p>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php
|
||||
$countcatevents = array ();
|
||||
$countperday = array();
|
||||
$limit = $this->params->get('daylimit', 10);
|
||||
$evbg_usecatcolor = $this->params->get('eventbg_usecatcolor', 0);
|
||||
$showtime = $this->settings->get('global_show_timedetails', 1);
|
||||
|
||||
foreach ($this->rows as $row) :
|
||||
if (!JemHelper::isValidDate($row->dates)) {
|
||||
continue; // skip, open date !
|
||||
}
|
||||
|
||||
//get event date
|
||||
$year = date('Y', strtotime($row->dates));
|
||||
$month = date('m', strtotime($row->dates));
|
||||
$day = date('d', strtotime($row->dates));
|
||||
|
||||
@$countperday[$year.$month.$day]++;
|
||||
if ($countperday[$year.$month.$day] == $limit+1) {
|
||||
$var1a = Route::_('index.php?option=com_jem&view=day&id='.$year.$month.$day.'&catid='.$this->catid);
|
||||
$var1b = Text::_('COM_JEM_AND_MORE');
|
||||
$var1c = "<a href=\"".$var1a."\">".$var1b."</a>";
|
||||
$id = 'eventandmore';
|
||||
|
||||
/**
|
||||
* $cal->setEventContent($year,$month,$day,$content,[$contentUrl,$id])
|
||||
*
|
||||
* Info from: https://www.micronetwork.de/activecalendar/demo/doc/doc_en.html
|
||||
*
|
||||
* Call this method, if you want the class to create a new HTML table within the date specified by the parameters $year, $month, $day.
|
||||
* The parameter $content can be a string or an array.
|
||||
* If $content is a string, then the new generated table will contain one row with the value of $content.
|
||||
* If it is an array, the generated table will contain as many rows as the array length and each row will contain the value of each array item.
|
||||
* The parameter $contentUrl is optional: If you set a $contentUrl, an event content specific link (..href='$contentUrl'..) will be generated
|
||||
* in the 'event content' table row(s), even if the method $cal->enableDayLinks($link) was not called.
|
||||
* The parameter $id is optional as well: if you set an $id, a HTML class='$id' will be generated for each event content (default: 'eventcontent').
|
||||
*/
|
||||
|
||||
$this->cal->setEventContent($year, $month, $day, $var1c, null, $id);
|
||||
continue;
|
||||
} elseif ($countperday[$year.$month.$day] > $limit+1) {
|
||||
continue;
|
||||
}
|
||||
|
||||
//for time in tooltip
|
||||
$timehtml = '';
|
||||
|
||||
if ($showtime) {
|
||||
$start = JemOutput::formattime($row->times);
|
||||
$end = JemOutput::formattime($row->endtimes);
|
||||
|
||||
if ($start != '') {
|
||||
$timehtml = '<div class="time"><span class="text-label">'.Text::_('COM_JEM_TIME_SHORT').': </span>';
|
||||
$timehtml .= $start;
|
||||
if ($end != '') {
|
||||
$timehtml .= ' - '.$end;
|
||||
}
|
||||
$timehtml .= '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
$eventname = '<div class="eventName">'.Text::_('COM_JEM_TITLE_SHORT').': '.$this->escape($row->title).'</div>';
|
||||
$detaillink = Route::_(JemHelperRoute::getEventRoute($row->slug));
|
||||
$eventid = $this->escape($row->id);
|
||||
|
||||
//initialize variables
|
||||
$multicatname = '';
|
||||
$colorpic = '';
|
||||
$nr = is_array($row->categories) ? count($row->categories) : 0;
|
||||
$ix = 0;
|
||||
$content = '';
|
||||
$contentend = '';
|
||||
$catcolor = array();
|
||||
|
||||
//walk through categories assigned to an event
|
||||
foreach((array)$row->categories AS $category) {
|
||||
//Currently only one id possible...so simply just pick one up...
|
||||
$detaillink = Route::_(JemHelperRoute::getEventRoute($row->slug));
|
||||
|
||||
//wrap a div for each category around the event for show hide toggler
|
||||
$content .= '<div id="scat" class="cat'.$category->id.'">';
|
||||
$contentend .= '</div>';
|
||||
|
||||
//attach category color if any in front of the catname
|
||||
if ($category->color) {
|
||||
$multicatname .= '<span class="colorpic" style="background-color: '.$category->color.';"></span> '.$category->catname;
|
||||
} else {
|
||||
$multicatname .= $category->catname;
|
||||
}
|
||||
|
||||
$ix++;
|
||||
if ($ix != $nr) {
|
||||
$multicatname .= ', ';
|
||||
}
|
||||
|
||||
//attach category color if any in front of the event title in the calendar overview
|
||||
if (isset($category->color) && $category->color) {
|
||||
$colorpic .= '<span class="colorpic" style="background-color: '.$category->color.';"></span>';
|
||||
$catcolor[$category->color] = $category->color; // we need to list all different colors of this event
|
||||
}
|
||||
|
||||
//count occurence of the category
|
||||
if (!isset($row->multi) || ($row->multi == 'first')) {
|
||||
if (!array_key_exists($category->id, $countcatevents)) {
|
||||
$countcatevents[$category->id] = 1;
|
||||
} else {
|
||||
$countcatevents[$category->id]++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// multiday
|
||||
$multi_mode = 0; // single day
|
||||
$multi_icon = '';
|
||||
if (isset($row->multi)) {
|
||||
switch ($row->multi) {
|
||||
case 'first': // first day
|
||||
$multi_mode = 1;
|
||||
$multi_icon = HTMLHelper::_("image","com_jem/arrow-left.png",'', NULL, true);
|
||||
break;
|
||||
case 'middle': // middle day
|
||||
$multi_mode = 2;
|
||||
$multi_icon = HTMLHelper::_("image","com_jem/arrow-middle.png",'', NULL, true);
|
||||
break;
|
||||
case 'zlast': // last day
|
||||
$multi_mode = 3;
|
||||
$multi_icon = HTMLHelper::_("image","com_jem/arrow-right.png",'', NULL, true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
//for time in calendar
|
||||
$timetp = '';
|
||||
|
||||
if ($showtime) {
|
||||
$start = JemOutput::formattime($row->times,'',false);
|
||||
$end = JemOutput::formattime($row->endtimes,'',false);
|
||||
|
||||
switch ($multi_mode) {
|
||||
case 1:
|
||||
$timetp .= $multi_icon . ' ' . $start . '<br />';
|
||||
break;
|
||||
case 2:
|
||||
$timetp .= $multi_icon . '<br />';
|
||||
break;
|
||||
case 3:
|
||||
$timetp .= $multi_icon . ' ' . $end . '<br />';
|
||||
break;
|
||||
default:
|
||||
if ($start != '') {
|
||||
$timetp .= $start;
|
||||
if ($end != '') {
|
||||
$timetp .= ' - '.$end;
|
||||
}
|
||||
$timetp .= '<br />';
|
||||
}
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
if (!empty($multi_icon)) {
|
||||
$timetp .= $multi_icon . ' ';
|
||||
}
|
||||
}
|
||||
|
||||
$catname = '<div class="catname">'.$multicatname.'</div>';
|
||||
|
||||
$eventdate = !empty($row->multistartdate) ? JemOutput::formatdate($row->multistartdate) : JemOutput::formatdate($row->dates);
|
||||
if (!empty($row->multienddate)) {
|
||||
$eventdate .= ' - ' . JemOutput::formatdate($row->multienddate);
|
||||
} else if ($row->enddates && $row->dates < $row->enddates) {
|
||||
$eventdate .= ' - ' . JemOutput::formatdate($row->enddates);
|
||||
}
|
||||
|
||||
//venue
|
||||
if ($this->jemsettings->showlocate == 1) {
|
||||
$venue = '<div class="location"><span class="text-label">'.Text::_('COM_JEM_VENUE_SHORT').': </span>';
|
||||
$venue .= !empty($row->venue) ? $this->escape($row->venue) : '-';
|
||||
$venue .= '</div>';
|
||||
} else {
|
||||
$venue = '';
|
||||
}
|
||||
|
||||
// state if unpublished
|
||||
$statusicon = '';
|
||||
if (isset($row->published) && ($row->published != 1)) {
|
||||
$statusicon = JemOutput::publishstateicon($row);
|
||||
$eventstate = '<div class="eventstate"><span class="text-label">'.Text::_('JSTATUS').': </span>';
|
||||
switch ($row->published) {
|
||||
case 1: $eventstate .= Text::_('JPUBLISHED'); break;
|
||||
case 0: $eventstate .= Text::_('JUNPUBLISHED'); break;
|
||||
case 2: $eventstate .= Text::_('JARCHIVED'); break;
|
||||
case -2: $eventstate .= Text::_('JTRASHED'); break;
|
||||
}
|
||||
$eventstate .= '</div>';
|
||||
} else {
|
||||
$eventstate = '';
|
||||
}
|
||||
|
||||
//date in tooltip
|
||||
$multidaydate = '<div class="time"><span class="text-label">'.Text::_('COM_JEM_DATE').': </span>';
|
||||
switch ($multi_mode) {
|
||||
case 1: // first day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->dates, $row->times, $row->enddates, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->dates, $row->times, $row->enddates, $row->endtimes);
|
||||
break;
|
||||
case 2: // middle day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes);
|
||||
break;
|
||||
case 3: // last day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes);
|
||||
break;
|
||||
default: // single day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->dates, $row->times, $row->enddates, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->dates, $row->times, $row->enddates, $row->endtimes);
|
||||
break;
|
||||
}
|
||||
$multidaydate .= '</div>';
|
||||
|
||||
//create little Edit and/or Copy icon on top right corner of event if user is allowed to edit and/or create
|
||||
$editicon = '';
|
||||
if (!$this->print) {
|
||||
$btns = array();
|
||||
if ($this->params->get('show_editevent_icon', 0) && $row->params->get('access-edit', false)) {
|
||||
$btns[] = JemOutput::editbutton($row, null, null, true, 'editevent');
|
||||
}
|
||||
if ($this->params->get('show_copyevent_icon', 0) && $this->permissions->canAddEvent) {
|
||||
$btns[] = JemOutput::copybutton($row, null, null, true, 'editevent');
|
||||
}
|
||||
if (!empty($btns)) {
|
||||
$editicon .= '<div class="inline-button-right">';
|
||||
$editicon .= join(' ', $btns);
|
||||
$editicon .= '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
//get border for featured event
|
||||
$usefeaturedborder = $this->params->get('usefeaturedborder', 0);
|
||||
$featuredbordercolor = $this->params->get('featuredbordercolor', 0);
|
||||
$featuredclass = '';
|
||||
$featuredstyle ='';
|
||||
if($usefeaturedborder && $row->featured){
|
||||
$featuredclass="borderfeatured";
|
||||
$featuredstyle="border-color:" . $featuredbordercolor;
|
||||
}
|
||||
|
||||
//generate the output
|
||||
// if we have exact one color from categories we can use this as background color of event
|
||||
$content .= '<div class="eventcontentinner event_id' . $eventid . ' cat_id' . $category->id . ' ' . $featuredclass . '" style="' . $featuredstyle;
|
||||
if (!empty($evbg_usecatcolor) && (count($catcolor) == 1)) {
|
||||
$content .= '; background-color:'.array_pop($catcolor).'">';
|
||||
} else {
|
||||
$content .= '">' . $colorpic;
|
||||
}
|
||||
$content .= $editicon;
|
||||
$content .= JemHelper::caltooltip($catname.$eventname.$timehtml.$venue.$eventstate, $eventdate, $row->title . $statusicon, $detaillink, 'editlinktip hasTip', $timetp, $category->color);
|
||||
$content .= $contentend . '</div>';
|
||||
|
||||
$this->cal->setEventContent($year, $month, $day, $content);
|
||||
endforeach;
|
||||
|
||||
// enable little icon right beside day number to allow event creation
|
||||
if (!$this->print && $this->params->get('show_addevent_icon', 0) && !empty($this->permissions->canAddEvent)) {
|
||||
$html = JemOutput::prepareAddEventButton('catid='.$this->catid);
|
||||
$this->cal->enableNewEventLinks($html);
|
||||
}
|
||||
|
||||
$displayLegend = (int)$this->params->get('displayLegend', 1);
|
||||
if ($displayLegend == 2) : ?>
|
||||
<!-- Calendar legend above -->
|
||||
<div id="jlcalendarlegend">
|
||||
|
||||
<!-- Calendar Legend -->
|
||||
<div class="calendarLegends">
|
||||
<?php
|
||||
if ($this->params->get('displayLegend')) {
|
||||
|
||||
##############
|
||||
## FOR EACH ##
|
||||
##############
|
||||
|
||||
$counter = array();
|
||||
|
||||
# walk through events
|
||||
foreach ($this->rows as $row) {
|
||||
foreach ($row->categories as $cat) {
|
||||
# skip foreign categories - we are restricted to one
|
||||
if ($cat->id != $this->catid) {
|
||||
continue;
|
||||
}
|
||||
|
||||
# sort out dupes for the counter (catid-legend)
|
||||
if (!in_array($cat->id, $counter)) {
|
||||
# add cat id to cat counter
|
||||
$counter[] = $cat->id;
|
||||
|
||||
# build legend
|
||||
if (array_key_exists($cat->id, $countcatevents)) {
|
||||
?>
|
||||
<div class="eventCat btn btn-outline-dark" id="cat<?php echo $cat->id; ?>">
|
||||
<?php
|
||||
if (isset($cat->color) && $cat->color) {
|
||||
echo '<span class="colorpic" style="background-color: '.$cat->color.';"></span>';
|
||||
}
|
||||
echo $cat->catname.' ('.$countcatevents[$cat->id].')';
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php
|
||||
// print the calendar
|
||||
echo $this->cal->showMonth();
|
||||
?>
|
||||
|
||||
<?php if ($displayLegend == 1) : ?>
|
||||
<!-- Calendar legend below -->
|
||||
<div id="jlcalendarlegend">
|
||||
|
||||
<!-- Calendar Legend -->
|
||||
<div class="calendarLegends">
|
||||
<?php
|
||||
|
||||
##############
|
||||
## FOR EACH ##
|
||||
##############
|
||||
|
||||
$counter = array();
|
||||
|
||||
# walk through events
|
||||
foreach ($this->rows as $row) {
|
||||
foreach ($row->categories as $cat) {
|
||||
# skip foreign categories - we are restricted to one
|
||||
if ($cat->id != $this->catid) {
|
||||
continue;
|
||||
}
|
||||
|
||||
# sort out dupes for the counter (catid-legend)
|
||||
if (!in_array($cat->id, $counter)) {
|
||||
# add cat id to cat counter
|
||||
$counter[] = $cat->id;
|
||||
|
||||
# build legend
|
||||
if (array_key_exists($cat->id, $countcatevents)) {
|
||||
?>
|
||||
<div class="eventCat btn btn-outline-dark" id="cat<?php echo $cat->id; ?>">
|
||||
<?php
|
||||
if (isset($cat->color) && $cat->color) {
|
||||
echo '<span class="colorpic" style="background-color: '.$cat->color.';"></span>';
|
||||
}
|
||||
echo $cat->catname.' ('.$countcatevents[$cat->id].')';
|
||||
?>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="clr"></div>
|
||||
|
||||
<div class="copyright">
|
||||
<?php echo JemOutput::footer(); ?>
|
||||
</div>
|
||||
</div>
|
||||
106
templates/joomla-italia-theme/html/com_jem/category/default.php
Normal file
106
templates/joomla-italia-theme/html/com_jem/category/default.php
Normal file
@ -0,0 +1,106 @@
|
||||
<?php
|
||||
/**
|
||||
* @package JEM
|
||||
* @copyright (C) 2013-2024 joomlaeventmanager.net
|
||||
* @copyright (C) 2005-2009 Christoph Lukes
|
||||
* @license https://www.gnu.org/licenses/gpl-3.0 GNU/GPL
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
?>
|
||||
<div id="jem" class="jem_category<?php echo $this->pageclass_sfx;?>">
|
||||
<div class="buttons">
|
||||
<?php
|
||||
$btn_params = array('id' => $this->category->slug, 'slug' => $this->category->slug, 'task' => $this->task, 'print_link' => $this->print_link);
|
||||
echo JemOutput::createButtonBar($this->getName(), $this->permissions, $btn_params);
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php if ($this->params->get('show_page_heading', 1)) : ?>
|
||||
<h1 class='componentheading'>
|
||||
<?php echo $this->escape($this->params->get('page_heading')); ?>
|
||||
</h1>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="clr"></div>
|
||||
|
||||
<div class="floattext">
|
||||
<?php if ($this->jemsettings->discatheader) : ?>
|
||||
<div class="catimg">
|
||||
<?php
|
||||
// flyer
|
||||
if (empty($this->category->image)) {
|
||||
$jemsettings = JEMHelper::config();
|
||||
$imgattribs['width'] = $jemsettings->imagewidth;
|
||||
$imgattribs['height'] = $jemsettings->imagehight;
|
||||
|
||||
echo HTMLHelper::_('image', 'com_jem/noimage.png', $this->category->catname, $imgattribs, true);
|
||||
}
|
||||
else {
|
||||
echo JemOutput::flyer($this->category, $this->cimage, 'category');
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="description">
|
||||
<p><?php echo $this->description; ?></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!--subcategories-->
|
||||
<?php
|
||||
if ($this->showsubcats && $this->maxLevel != 0 && !empty($this->category->id) && !empty($this->children[$this->category->id])) :
|
||||
$countsubcats = 0;
|
||||
foreach ($this->children[$this->category->id] as $id => $child) :
|
||||
// Do we have any non-empty subcategory or should generally show empty subcategories?
|
||||
// Note: We also show empty subcategories if they have at least one non-empty subsubcategory.
|
||||
if ($this->showemptysubcats || ($child->getNumItems(true) > 0)) :
|
||||
++$countsubcats;
|
||||
endif;
|
||||
endforeach;
|
||||
if ($countsubcats) :
|
||||
?>
|
||||
<div class="cat-children">
|
||||
<?php if ($this->params->get('show_category_heading_title_text', 1) == 1) : ?>
|
||||
<h3>
|
||||
<?php echo TEXT::_('COM_JEM_SUBCATEGORIES'); ?>
|
||||
</h3>
|
||||
<?php endif; ?>
|
||||
<?php echo $this->loadTemplate('subcategories'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
<form action="<?php echo htmlspecialchars($this->action); ?>" method="post" id="adminForm">
|
||||
<!--table-->
|
||||
<?php echo $this->loadTemplate('events_table'); ?>
|
||||
<input type="hidden" name="option" value="com_jem" />
|
||||
<input type="hidden" name="filter_order" value="<?php echo $this->lists['order']; ?>" />
|
||||
<input type="hidden" name="filter_order_Dir" value="<?php echo $this->lists['order_Dir']; ?>" />
|
||||
<input type="hidden" name="view" value="category" />
|
||||
<input type="hidden" name="task" value="<?php echo $this->task; ?>" />
|
||||
<input type="hidden" name="id" value="<?php echo $this->category->id; ?>" />
|
||||
</form>
|
||||
|
||||
<!--pagination-->
|
||||
<div class="pagination">
|
||||
<?php echo $this->pagination->getPagesLinks(); ?>
|
||||
</div>
|
||||
|
||||
<!-- iCal -->
|
||||
<div id="iCal" class="iCal">
|
||||
<?php echo JemOutput::icalbutton($this->category->id, 'category'); ?>
|
||||
</div>
|
||||
|
||||
<!-- copyright -->
|
||||
<div class="copyright">
|
||||
<?php echo JemOutput::footer( ); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php echo JemOutput::lightbox(); ?>
|
||||
@ -0,0 +1,94 @@
|
||||
<?php
|
||||
/**
|
||||
* @package JEM
|
||||
* @copyright (C) 2013-2024 joomlaeventmanager.net
|
||||
* @copyright (C) 2005-2009 Christoph Lukes
|
||||
* @license https://www.gnu.org/licenses/gpl-3.0 GNU/GPL
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Router\Route;
|
||||
|
||||
$class = ' class="first"';
|
||||
?>
|
||||
|
||||
<?php /*
|
||||
<div class="subcategories">
|
||||
<?php //echo Text::_('COM_JEM_SUBCATEGORIES'); ?>
|
||||
</div>
|
||||
*/ ?>
|
||||
|
||||
<?php if (array_key_exists($this->category->id, $this->children) && (count($this->children[$this->category->id]) > 0)) : ?>
|
||||
<?php
|
||||
$lastid = 0;
|
||||
foreach ($this->children[$this->category->id] as $id => $child) :
|
||||
if ($this->params->get('showemptychilds', 1) || ($child->getNumItems(true) > 0)) :
|
||||
$lastid = $id;
|
||||
endif;
|
||||
endforeach;
|
||||
?>
|
||||
|
||||
<ul>
|
||||
<?php foreach ($this->children[$this->category->id] as $id => $child) : ?>
|
||||
|
||||
<?php
|
||||
// Note: We don't skip empty subcategories if they have at least one non-empty subsubcategory.
|
||||
if (!$this->params->get('showemptychilds', 1) && ($child->getNumItems(true) <= 0)) :
|
||||
continue; // skip this subcat
|
||||
endif;
|
||||
|
||||
if ($id == $lastid) :
|
||||
$class = ' class="last"';
|
||||
endif;
|
||||
?>
|
||||
|
||||
<li<?php echo $class; ?>>
|
||||
<?php $class = ''; ?>
|
||||
<span class="item-title">
|
||||
<a href="<?php echo Route::_(JemHelperRoute::getCategoryRoute($child->id, $this->task)); ?>">
|
||||
<?php echo $this->escape($child->catname); ?>
|
||||
</a>
|
||||
</span>
|
||||
<?php if ($this->params->get('show_subcat_desc') == 1) : ?>
|
||||
<?php if ($child->description) : ?>
|
||||
<div class="category-desc">
|
||||
<?php echo HTMLHelper::_('content.prepare', $child->description, '', 'com_content.category'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php if ( $this->params->get('show_cat_num_articles', 1)) : ?>
|
||||
<dl>
|
||||
<dt>
|
||||
<?php echo Text::_('COM_JEM_EVENTS') . ':' ; ?>
|
||||
</dt>
|
||||
<dd>
|
||||
<?php echo $child->getNumItems(false); /* count direct events only, not recursive */ ?>
|
||||
</dd>
|
||||
</dl>
|
||||
<?php endif; ?>
|
||||
<?php elseif ($this->params->get('show_cat_num_articles', 1)) : ?>
|
||||
<?php echo ' (' . $child->getNumItems(false) . ')'; /* count direct events only, not recursive */ ?>
|
||||
<?php /* experimental * /
|
||||
$count = $child->getNumItemsByState(false);
|
||||
echo ' (' . $count['published'] . ' + ' . $count['unpublished'] . ' / ' . $count['archived'] . ' - ' . $count['trashed'] . ')';
|
||||
/**/
|
||||
?>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if (count($child->getChildren()) > 0 ) :
|
||||
$this->children[$child->id] = $child->getChildren();
|
||||
$this->category = $child;
|
||||
$this->maxLevel--;
|
||||
if ($this->maxLevel != 0) :
|
||||
echo $this->loadTemplate('subcategories');
|
||||
endif;
|
||||
$this->category = $child->getParent();
|
||||
$this->maxLevel++;
|
||||
endif; ?>
|
||||
</li>
|
||||
<?php // endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
@ -0,0 +1,433 @@
|
||||
<?php
|
||||
/**
|
||||
* @package JEM
|
||||
* @copyright (C) 2013-2024 joomlaeventmanager.net
|
||||
* @copyright (C) 2005-2009 Christoph Lukes
|
||||
* @license https://www.gnu.org/licenses/gpl-3.0 GNU/GPL
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Router\Route;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
?>
|
||||
|
||||
<div id="jem" class="jlcalendar jem_calendar<?php echo $this->pageclass_sfx;?>">
|
||||
<div class="buttons">
|
||||
<?php
|
||||
$btn_params = array('print_link' => $this->print_link, 'ical_link' => $this->ical_link);
|
||||
echo JemOutput::createButtonBar($this->getName().'-cal', $this->permissions, $btn_params);
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php if ($this->params->get('show_page_heading', 1)): ?>
|
||||
<h1 class="componentheading">
|
||||
<?php echo $this->escape($this->params->get('page_heading')); ?>
|
||||
</h1>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ($this->params->get('showintrotext')) : ?>
|
||||
<div class="description no_space floattext">
|
||||
<?php echo $this->params->get('introtext'); ?>
|
||||
</div>
|
||||
<p> </p>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php
|
||||
$countcatevents = array ();
|
||||
$countperday = array();
|
||||
$limit = $this->params->get('daylimit', 10);
|
||||
$evbg_usecatcolor = $this->params->get('eventbg_usecatcolor', 0);
|
||||
$showtime = $this->settings->get('global_show_timedetails', 1);
|
||||
|
||||
foreach ($this->rows as $row) :
|
||||
if (!JemHelper::isValidDate($row->dates)) {
|
||||
continue; // skip, open date !
|
||||
}
|
||||
|
||||
//get event date
|
||||
$year = date('Y', strtotime($row->dates));
|
||||
$month = date('m', strtotime($row->dates));
|
||||
$day = date('d', strtotime($row->dates));
|
||||
|
||||
@$countperday[$year.$month.$day]++;
|
||||
if ($countperday[$year.$month.$day] == $limit+1) {
|
||||
$var1a = Route::_('index.php?option=com_jem&view=day&id='.$year.$month.$day.'&catid='.$this->catid);
|
||||
$var1b = Text::_('COM_JEM_AND_MORE');
|
||||
$var1c = "<a href=\"".$var1a."\">".$var1b."</a>";
|
||||
$id = 'eventandmore';
|
||||
|
||||
/**
|
||||
* $cal->setEventContent($year,$month,$day,$content,[$contentUrl,$id])
|
||||
*
|
||||
* Info from: https://www.micronetwork.de/activecalendar/demo/doc/doc_en.html
|
||||
*
|
||||
* Call this method, if you want the class to create a new HTML table within the date specified by the parameters $year, $month, $day.
|
||||
* The parameter $content can be a string or an array.
|
||||
* If $content is a string, then the new generated table will contain one row with the value of $content.
|
||||
* If it is an array, the generated table will contain as many rows as the array length and each row will contain the value of each array item.
|
||||
* The parameter $contentUrl is optional: If you set a $contentUrl, an event content specific link (..href='$contentUrl'..) will be generated
|
||||
* in the 'event content' table row(s), even if the method $cal->enableDayLinks($link) was not called.
|
||||
* The parameter $id is optional as well: if you set an $id, a HTML class='$id' will be generated for each event content (default: 'eventcontent').
|
||||
*/
|
||||
|
||||
$this->cal->setEventContent($year, $month, $day, $var1c, null, $id);
|
||||
continue;
|
||||
} elseif ($countperday[$year.$month.$day] > $limit+1) {
|
||||
continue;
|
||||
}
|
||||
|
||||
//for time in tooltip
|
||||
$timehtml = '';
|
||||
|
||||
if ($showtime) {
|
||||
$start = JemOutput::formattime($row->times);
|
||||
$end = JemOutput::formattime($row->endtimes);
|
||||
|
||||
if ($start != '') {
|
||||
$timehtml = '<div class="time"><span class="text-label">'.Text::_('COM_JEM_TIME_SHORT').': </span>';
|
||||
$timehtml .= $start;
|
||||
if ($end != '') {
|
||||
$timehtml .= ' - '.$end;
|
||||
}
|
||||
$timehtml .= '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
$eventname = '<div class="eventName">'.Text::_('COM_JEM_TITLE_SHORT').': '.$this->escape($row->title).'</div>';
|
||||
$detaillink = Route::_(JemHelperRoute::getEventRoute($row->slug));
|
||||
$eventid = $this->escape($row->id);
|
||||
|
||||
//initialize variables
|
||||
$multicatname = '';
|
||||
$colorpic = '';
|
||||
$nr = is_array($row->categories) ? count($row->categories) : 0;
|
||||
$ix = 0;
|
||||
$content = '';
|
||||
$contentend = '';
|
||||
$catcolor = array();
|
||||
|
||||
//walk through categories assigned to an event
|
||||
foreach((array)$row->categories AS $category) {
|
||||
//Currently only one id possible...so simply just pick one up...
|
||||
$detaillink = Route::_(JemHelperRoute::getEventRoute($row->slug));
|
||||
|
||||
//wrap a div for each category around the event for show hide toggler
|
||||
$content .= '<div id="scat" class="cat'.$category->id.'">';
|
||||
$contentend .= '</div>';
|
||||
|
||||
//attach category color if any in front of the catname
|
||||
if ($category->color) {
|
||||
$multicatname .= '<span class="colorpic" style="background-color: '.$category->color.';"></span> '.$category->catname;
|
||||
} else {
|
||||
$multicatname .= $category->catname;
|
||||
}
|
||||
|
||||
$ix++;
|
||||
if ($ix != $nr) {
|
||||
$multicatname .= ', ';
|
||||
}
|
||||
|
||||
//attach category color if any in front of the event title in the calendar overview
|
||||
if (isset($category->color) && $category->color) {
|
||||
$colorpic .= '<span class="colorpic" style="background-color: '.$category->color.';"></span>';
|
||||
$catcolor[$category->color] = $category->color; // we need to list all different colors of this event
|
||||
}
|
||||
|
||||
//count occurence of the category
|
||||
if (!isset($row->multi) || ($row->multi == 'first')) {
|
||||
if (!array_key_exists($category->id, $countcatevents)) {
|
||||
$countcatevents[$category->id] = 1;
|
||||
} else {
|
||||
$countcatevents[$category->id]++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// multiday
|
||||
$multi_mode = 0; // single day
|
||||
$multi_icon = '';
|
||||
if (isset($row->multi)) {
|
||||
switch ($row->multi) {
|
||||
case 'first': // first day
|
||||
$multi_mode = 1;
|
||||
$multi_icon = HTMLHelper::_("image","com_jem/arrow-left.png",'', NULL, true);
|
||||
break;
|
||||
case 'middle': // middle day
|
||||
$multi_mode = 2;
|
||||
$multi_icon = HTMLHelper::_("image","com_jem/arrow-middle.png",'', NULL, true);
|
||||
break;
|
||||
case 'zlast': // last day
|
||||
$multi_mode = 3;
|
||||
$multi_icon = HTMLHelper::_("image","com_jem/arrow-right.png",'', NULL, true);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
//for time in calendar
|
||||
$timetp = '';
|
||||
|
||||
if ($showtime) {
|
||||
$start = JemOutput::formattime($row->times,'',false);
|
||||
$end = JemOutput::formattime($row->endtimes,'',false);
|
||||
|
||||
switch ($multi_mode) {
|
||||
case 1:
|
||||
$timetp .= $multi_icon . ' ' . $start . '<br />';
|
||||
break;
|
||||
case 2:
|
||||
$timetp .= $multi_icon . '<br />';
|
||||
break;
|
||||
case 3:
|
||||
$timetp .= $multi_icon . ' ' . $end . '<br />';
|
||||
break;
|
||||
default:
|
||||
if ($start != '') {
|
||||
$timetp .= $start;
|
||||
if ($end != '') {
|
||||
$timetp .= ' - '.$end;
|
||||
}
|
||||
$timetp .= '<br />';
|
||||
}
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
if (!empty($multi_icon)) {
|
||||
$timetp .= $multi_icon . ' ';
|
||||
}
|
||||
}
|
||||
|
||||
$catname = '<div class="catname">'.$multicatname.'</div>';
|
||||
|
||||
$eventdate = !empty($row->multistartdate) ? JemOutput::formatdate($row->multistartdate) : JemOutput::formatdate($row->dates);
|
||||
if (!empty($row->multienddate)) {
|
||||
$eventdate .= ' - ' . JemOutput::formatdate($row->multienddate);
|
||||
} else if ($row->enddates && $row->dates < $row->enddates) {
|
||||
$eventdate .= ' - ' . JemOutput::formatdate($row->enddates);
|
||||
}
|
||||
|
||||
//venue
|
||||
if ($this->jemsettings->showlocate == 1) {
|
||||
$venue = '<div class="location"><span class="text-label">'.Text::_('COM_JEM_VENUE_SHORT').': </span>';
|
||||
$venue .= !empty($row->venue) ? $this->escape($row->venue) : '-';
|
||||
$venue .= '</div>';
|
||||
} else {
|
||||
$venue = '';
|
||||
}
|
||||
|
||||
// state if unpublished
|
||||
$statusicon = '';
|
||||
if (isset($row->published) && ($row->published != 1)) {
|
||||
$statusicon = JemOutput::publishstateicon($row);
|
||||
$eventstate = '<div class="eventstate"><span class="text-label">'.Text::_('JSTATUS').': </span>';
|
||||
switch ($row->published) {
|
||||
case 1: $eventstate .= Text::_('JPUBLISHED'); break;
|
||||
case 0: $eventstate .= Text::_('JUNPUBLISHED'); break;
|
||||
case 2: $eventstate .= Text::_('JARCHIVED'); break;
|
||||
case -2: $eventstate .= Text::_('JTRASHED'); break;
|
||||
}
|
||||
$eventstate .= '</div>';
|
||||
} else {
|
||||
$eventstate = '';
|
||||
}
|
||||
|
||||
//date in tooltip
|
||||
$multidaydate = '<div class="time"><span class="text-label">'.Text::_('COM_JEM_DATE').': </span>';
|
||||
switch ($multi_mode) {
|
||||
case 1: // first day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->dates, $row->times, $row->enddates, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->dates, $row->times, $row->enddates, $row->endtimes);
|
||||
break;
|
||||
case 2: // middle day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes);
|
||||
break;
|
||||
case 3: // last day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->multistartdate, $row->times, $row->multienddate, $row->endtimes);
|
||||
break;
|
||||
default: // single day
|
||||
$multidaydate .= JemOutput::formatShortDateTime($row->dates, $row->times, $row->enddates, $row->endtimes, $showtime);
|
||||
$multidaydate .= JemOutput::formatSchemaOrgDateTime($row->dates, $row->times, $row->enddates, $row->endtimes);
|
||||
break;
|
||||
}
|
||||
$multidaydate .= '</div>';
|
||||
|
||||
//create little Edit and/or Copy icon on top right corner of event if user is allowed to edit and/or create
|
||||
$editicon = '';
|
||||
if (!$this->print) {
|
||||
$btns = array();
|
||||
if ($this->params->get('show_editevent_icon', 0) && $row->params->get('access-edit', false)) {
|
||||
$btns[] = JemOutput::editbutton($row, null, null, true, 'editevent');
|
||||
}
|
||||
if ($this->params->get('show_copyevent_icon', 0) && $this->permissions->canAddEvent) {
|
||||
$btns[] = JemOutput::copybutton($row, null, null, true, 'editevent');
|
||||
}
|
||||
if (!empty($btns)) {
|
||||
$editicon .= '<div class="inline-button-right">';
|
||||
$editicon .= join(' ', $btns);
|
||||
$editicon .= '</div>';
|
||||
}
|
||||
}
|
||||
|
||||
//get border for featured event
|
||||
$usefeaturedborder = $this->params->get('usefeaturedborder', 0);
|
||||
$featuredbordercolor = $this->params->get('featuredbordercolor', 0);
|
||||
$featuredclass = '';
|
||||
$featuredstyle ='';
|
||||
if($usefeaturedborder && $row->featured){
|
||||
$featuredclass="borderfeatured";
|
||||
$featuredstyle="border-color:" . $featuredbordercolor;
|
||||
}
|
||||
|
||||
//generate the output
|
||||
// if we have exact one color from categories we can use this as background color of event
|
||||
$content .= '<div class="eventcontentinner event_id' . $eventid . ' cat_id' . $category->id . ' ' . $featuredclass . '" style="' . $featuredstyle;
|
||||
if (!empty($evbg_usecatcolor) && (count($catcolor) == 1)) {
|
||||
$content .= '; background-color:'.array_pop($catcolor);
|
||||
$content .= '" onclick="location.href=\''.$detaillink.'\'">';
|
||||
} else {
|
||||
$content .= '" onclick="location.href=\''.$detaillink.'\'">' . $colorpic;
|
||||
}
|
||||
$content .= $editicon;
|
||||
$content .= JemHelper::caltooltip($catname.$eventname.$timehtml.$venue.$eventstate, $eventdate, $row->title . $statusicon, $detaillink, 'editlinktip hasTip', $timetp, $category->color);
|
||||
$content .= $contentend . '</div>';
|
||||
|
||||
$this->cal->setEventContent($year, $month, $day, $content);
|
||||
endforeach;
|
||||
|
||||
// enable little icon right beside day number to allow event creation
|
||||
if (!$this->print && $this->params->get('show_addevent_icon', 0) && !empty($this->permissions->canAddEvent)) {
|
||||
$html = JemOutput::prepareAddEventButton('catid='.$this->catid);
|
||||
$this->cal->enableNewEventLinks($html);
|
||||
}
|
||||
|
||||
$displayLegend = (int)$this->params->get('displayLegend', 1);
|
||||
if ($displayLegend == 2) : ?>
|
||||
<!-- Calendar legend above -->
|
||||
<div id="jlcalendarlegend">
|
||||
|
||||
<!-- Calendar buttons -->
|
||||
<div class="calendarButtons jem-row jem-justify-start">
|
||||
<button id="buttonshowall" class="calendarButton btn btn-outline-dark">
|
||||
<?php echo Text::_('COM_JEM_SHOWALL'); ?>
|
||||
</button>
|
||||
<button id="buttonhideall" class="calendarButton btn btn-outline-dark">
|
||||
<?php echo Text::_('COM_JEM_HIDEALL'); ?>
|
||||
</button>
|
||||
</div>
|
||||
<!-- Calendar Legend -->
|
||||
<div class="calendarLegends jem-row jem-justify-start">
|
||||
<?php
|
||||
if ($this->params->get('displayLegend')) {
|
||||
|
||||
##############
|
||||
## FOR EACH ##
|
||||
##############
|
||||
|
||||
$counter = array();
|
||||
|
||||
# walk through events
|
||||
foreach ($this->rows as $row) {
|
||||
foreach ($row->categories as $cat) {
|
||||
# skip foreign categories - we are restricted to one
|
||||
if ($cat->id != $this->catid) {
|
||||
continue;
|
||||
}
|
||||
|
||||
# sort out dupes for the counter (catid-legend)
|
||||
if (!in_array($cat->id, $counter)) {
|
||||
# add cat id to cat counter
|
||||
$counter[] = $cat->id;
|
||||
|
||||
# build legend
|
||||
if (array_key_exists($cat->id, $countcatevents)) {
|
||||
?>
|
||||
<button class="eventCat btn btn-outline-dark" id="cat<?php echo $cat->id; ?>">
|
||||
<?php
|
||||
if (isset($cat->color) && $cat->color) {
|
||||
echo '<span class="colorpic" style="background-color: '.$cat->color.';"></span>';
|
||||
}
|
||||
echo $cat->catname.' ('.$countcatevents[$cat->id].')';
|
||||
?>
|
||||
</button>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php
|
||||
// print the calendar
|
||||
echo $this->cal->showMonth();
|
||||
?>
|
||||
|
||||
<?php if ($displayLegend == 1) : ?>
|
||||
<!-- Calendar legend below -->
|
||||
<div id="jlcalendarlegend">
|
||||
|
||||
<!-- Calendar buttons -->
|
||||
<div class="calendarButtons jem-row jem-justify-start">
|
||||
<button id="buttonshowall" class="calendarButton btn btn-outline-dark">
|
||||
<?php echo Text::_('COM_JEM_SHOWALL'); ?>
|
||||
</button>
|
||||
<button id="buttonhideall" class="calendarButton btn btn-outline-dark">
|
||||
<?php echo Text::_('COM_JEM_HIDEALL'); ?>
|
||||
</button>
|
||||
</div>
|
||||
<!-- Calendar Legend -->
|
||||
<div class="calendarLegends jem-row jem-justify-start">
|
||||
<?php
|
||||
|
||||
##############
|
||||
## FOR EACH ##
|
||||
##############
|
||||
|
||||
$counter = array();
|
||||
|
||||
# walk through events
|
||||
foreach ($this->rows as $row) {
|
||||
foreach ($row->categories as $cat) {
|
||||
# skip foreign categories - we are restricted to one
|
||||
if ($cat->id != $this->catid) {
|
||||
continue;
|
||||
}
|
||||
|
||||
# sort out dupes for the counter (catid-legend)
|
||||
if (!in_array($cat->id, $counter)) {
|
||||
# add cat id to cat counter
|
||||
$counter[] = $cat->id;
|
||||
|
||||
# build legend
|
||||
if (array_key_exists($cat->id, $countcatevents)) {
|
||||
?>
|
||||
<button class="eventCat btn btn-outline-dark" id="cat<?php echo $cat->id; ?>">
|
||||
<?php
|
||||
if (isset($cat->color) && $cat->color) {
|
||||
echo '<span class="colorpic" style="background-color: '.$cat->color.';"></span>';
|
||||
}
|
||||
echo $cat->catname.' ('.$countcatevents[$cat->id].')';
|
||||
?>
|
||||
</button>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="clr"></div>
|
||||
|
||||
<div class="copyright">
|
||||
<?php echo JemOutput::footer(); ?>
|
||||
</div>
|
||||
</div>
|
||||
@ -0,0 +1,114 @@
|
||||
<?php
|
||||
/**
|
||||
* @package JEM
|
||||
* @copyright (C) 2013-2024 joomlaeventmanager.net
|
||||
* @copyright (C) 2005-2009 Christoph Lukes
|
||||
* @license https://www.gnu.org/licenses/gpl-3.0 GNU/GPL
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
|
||||
?>
|
||||
<div id="jem" class="jem_category<?php echo $this->pageclass_sfx;?>">
|
||||
<div class="buttons">
|
||||
<?php
|
||||
$btn_params = array('id' => $this->category->slug, 'slug' => $this->category->slug, 'task' => $this->task, 'print_link' => $this->print_link);
|
||||
echo JemOutput::createButtonBar($this->getName(), $this->permissions, $btn_params);
|
||||
?>
|
||||
</div>
|
||||
|
||||
<?php if ($this->params->get('show_page_heading', 1)) : ?>
|
||||
<h1 class='componentheading'>
|
||||
<?php echo $this->escape($this->params->get('page_heading')); ?>
|
||||
</h1>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ($this->escape($this->params->get('page_heading')) != $this->escape($this->category->title)) : ?>
|
||||
<?php if ($this->params->get('show_page_heading', 1)) : ?>
|
||||
<h2 class="jem-category-title">
|
||||
<?php echo $this->escape($this->category->title);?>
|
||||
</h2>
|
||||
<?php else : ?>
|
||||
<h1 class="jem-category-title">
|
||||
<?php echo $this->escape($this->category->title);?>
|
||||
</h1>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<style>
|
||||
.jem-catimg {
|
||||
flex-basis: <?php echo $this->jemsettings->imagewidth; ?>px;
|
||||
}
|
||||
</style>
|
||||
|
||||
<?php if (($this->jemsettings->discatheader) && (!empty($this->category->image))) : ?>
|
||||
<div class="jem-catimg">
|
||||
<?php echo JemOutput::flyer($this->category, $this->cimage, 'category'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<div class="description">
|
||||
<p><?php echo $this->description; ?></p>
|
||||
</div>
|
||||
|
||||
<div class="jem-clear">
|
||||
</div>
|
||||
|
||||
<!--subcategories-->
|
||||
<?php
|
||||
if ($this->showsubcats && $this->maxLevel != 0 && !empty($this->category->id) && !empty($this->children[$this->category->id])) :
|
||||
$countsubcats = 0;
|
||||
foreach ($this->children[$this->category->id] as $id => $child) :
|
||||
// Do we have any non-empty subcategory or should generally show empty subcategories?
|
||||
// Note: We also show empty subcategories if they have at least one non-empty subsubcategory.
|
||||
if ($this->showemptysubcats || ($child->getNumItems(true) > 0)) :
|
||||
++$countsubcats;
|
||||
endif;
|
||||
endforeach;
|
||||
if ($countsubcats) :
|
||||
?>
|
||||
<div class="cat-children">
|
||||
<?php if ($this->params->get('show_category_heading_title_text', 1) == 1) : ?>
|
||||
<h2>
|
||||
<?php echo Text::_('COM_JEM_SUBCATEGORIES'); ?>
|
||||
</h2>
|
||||
<?php endif; ?>
|
||||
<?php echo $this->loadTemplate('subcategories'); ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
|
||||
<h2>
|
||||
<?php echo Text::_('COM_JEM_EVENTS'); ?>
|
||||
</h2>
|
||||
<form action="<?php echo htmlspecialchars($this->action); ?>" method="post" id="adminForm">
|
||||
<!--table-->
|
||||
<?php echo $this->loadTemplate('events_table'); ?>
|
||||
<input type="hidden" name="option" value="com_jem" />
|
||||
<input type="hidden" name="filter_order" value="<?php echo $this->lists['order']; ?>" />
|
||||
<input type="hidden" name="filter_order_Dir" value="<?php echo $this->lists['order_Dir']; ?>" />
|
||||
<input type="hidden" name="view" value="category" />
|
||||
<input type="hidden" name="task" value="<?php echo $this->task; ?>" />
|
||||
<input type="hidden" name="id" value="<?php echo $this->category->id; ?>" />
|
||||
</form>
|
||||
|
||||
<!--pagination-->
|
||||
<div class="pagination">
|
||||
<?php echo $this->pagination->getPagesLinks(); ?>
|
||||
</div>
|
||||
|
||||
<!-- iCal -->
|
||||
<div id="iCal" class="iCal">
|
||||
<?php echo JemOutput::icalbutton($this->category->id, 'category'); ?>
|
||||
</div>
|
||||
|
||||
<!-- copyright -->
|
||||
<div class="copyright">
|
||||
<?php echo JemOutput::footer(); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php echo JemOutput::lightbox(); ?>
|
||||
@ -11,6 +11,9 @@
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Pcrt\Module\Highlights\Site\Helper\HighlightsHelper;
|
||||
use Joomla\CMS\Helper\ModuleHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
$elements = HighlightsHelper::getList($params);
|
||||
|
||||
@ -22,35 +25,120 @@ $field_name = !empty($tableField[1]) ? $tableField[1] : '';
|
||||
$opacita = $params->get('opacita', []);
|
||||
$sfondo = $params->get('sfondo', []);
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
|
||||
|
||||
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->useStyle('swiper.css.styles', ['position' => 'before']);
|
||||
$wa->useScript('swiper.js.scripts');
|
||||
|
||||
|
||||
$wa->addInlineScript('
|
||||
window.addEventListener("DOMContentLoaded", function(){
|
||||
|
||||
var swiper = new Swiper(".sliderfull'. $module->id . '", {
|
||||
slidesPerView: "auto",
|
||||
spaceBetween: 0,
|
||||
loop: true,
|
||||
pagination: {
|
||||
el: ".swiper-pagination",
|
||||
clickable: true,
|
||||
},
|
||||
});
|
||||
});
|
||||
|
||||
', [], ['type' => 'text/javascript']);
|
||||
|
||||
|
||||
?>
|
||||
|
||||
<?php if (!empty($elements)) : ?>
|
||||
<div class="bd-example w-100">
|
||||
<div class="bd-example-tabs">
|
||||
<div class="row">
|
||||
<!-- Macro a sinistra -->
|
||||
<div class="col-4 col-md-3">
|
||||
<div class="nav nav-tabs nav-tabs-vertical nav-tabs-vertical-background" id="nav-vertical-tab-bg" role="tablist" aria-orientation="vertical">
|
||||
<?php foreach ($elements as $index => $element) : ?>
|
||||
<a class="nav-link <?php echo $index === 0 ? 'active' : ''; ?>" id="nav-vertical-tab-<?php echo $index; ?>-tab" data-bs-toggle="tab" href="#nav-vertical-tab-<?php echo $index; ?>" role="tab" aria-controls="nav-vertical-tab-<?php echo $index; ?>" aria-selected="<?php echo $index === 0 ? 'true' : 'false'; ?>">
|
||||
<?php echo $element->sottotitolo; ?>
|
||||
</a>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
</div>
|
||||
<!-- Contenuto a destra -->
|
||||
<div class="col-8 col-md-9">
|
||||
<div class="tab-content" id="nav-vertical-tab-bgContent">
|
||||
<?php foreach ($elements as $index => $element) : ?>
|
||||
<div class="tab-pane p-3 fade <?php echo $index === 0 ? 'active show' : ''; ?>" id="nav-vertical-tab-<?php echo $index; ?>" role="tabpanel" aria-labelledby="nav-vertical-tab-<?php echo $index; ?>-tab">
|
||||
<div><?php echo $element->titolo; ?></div>
|
||||
<div><?php echo $element->sottotitolo; ?></div>
|
||||
<div><?php echo $element->descrizione; ?></div>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
<div class="<?= $params->get('moduleclass_sfx') ?>">
|
||||
<div class="position-relative">
|
||||
<div class="swiper sliderfull sliderfull<?= $module->id ?>">
|
||||
<div class="swiper-wrapper">
|
||||
<?php foreach ($elements as $index => $element) : ?>
|
||||
<div class="swiper-slide">
|
||||
<?php // Layout 50% test0 e 50% foto ?>
|
||||
<?php if ($element->classe == 'larghezza50') : ?>
|
||||
<div class="swiper-content <?= $element->classe; ?>">
|
||||
<div class="wrap-slide">
|
||||
<div class="container-lg px-0">
|
||||
<div class="caption-slide">
|
||||
<p class="title-slider">
|
||||
<?= $element->titolo; ?>
|
||||
</p>
|
||||
<p class="text-slider">
|
||||
<?= $element->sottotitolo; ?>
|
||||
</p>
|
||||
<a href="<?= $element->link_pulsante; ?>" class="btn btn-slide" title="<?= $element->testo_pulsante; ?>"><?= $element->testo_pulsante; ?></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row m-0">
|
||||
<div class="col-12 col-lg-6 order-lg-1 order-2">
|
||||
|
||||
</div>
|
||||
<div class="col-12 col-lg-6 order-lg-2 order-1 p-0">
|
||||
<div class="image-container" style="background-image: url(<?= $element->immagine_main; ?>)"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<?php // Layout 100% foto ?>
|
||||
<?php elseif ($element->classe == 'larghezza100') : ?>
|
||||
<div class="swiper-content <?= $element->classe; ?>">
|
||||
<div class="image-container" style="background-image: url(<?= $element->immagine_main; ?>)"></div>
|
||||
<div class="wrap-slide ">
|
||||
<div class="container-lg px-0">
|
||||
<div class="caption-slide">
|
||||
<?php if (!empty($element->immagine_secondaria)) : ?>
|
||||
<img src="<?= $element->immagine_secondaria; ?>" class="img-caption" />
|
||||
<?php endif; ?>
|
||||
<p class="title-slider">
|
||||
<?= $element->titolo; ?>
|
||||
</p>
|
||||
<p class="text-slider">
|
||||
<?= $element->sottotitolo; ?>
|
||||
</p>
|
||||
<a href="<?= $element->link_pulsante; ?>" class="btn btn-slide" title="<?= $element->testo_pulsante; ?>"><?= $element->testo_pulsante; ?></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php else: ?>
|
||||
<?php // Layout 100% foto testp boxed ?>
|
||||
<div class="swiper-content <?= $element->classe; ?>">
|
||||
<div class="image-container" style="background-image: url(<?= $element->immagine_main; ?>)">
|
||||
<div class="wrap-slide">
|
||||
<div class="container-lg px-0">
|
||||
<div class="caption-slide">
|
||||
<?php if (!empty($element->immagine_secondaria)) : ?>
|
||||
<img src="<?= $element->immagine_secondaria; ?>" class="img-caption" />
|
||||
<?php endif; ?>
|
||||
<p class="title-slider">
|
||||
<?= $element->titolo; ?>
|
||||
</p>
|
||||
<p class="text-slider">
|
||||
<?= $element->sottotitolo; ?>
|
||||
</p>
|
||||
<a href="<?= $element->link_pulsante; ?>" class="btn btn-slide" title="<?= $element->testo_pulsante; ?>"><?= $element->testo_pulsante; ?></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php endforeach; ?>
|
||||
</div>
|
||||
<div class="swiper-pagination"></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
@ -84,7 +84,10 @@
|
||||
}
|
||||
|
||||
if ($item->deeper){
|
||||
echo '<span>' . $linktype . '</span>';
|
||||
echo '<span>' . $linktype . '
|
||||
<svg class="icon icon-xs">
|
||||
<use href="' . $baseImagePath . 'sprites.svg#it-expand"></use>
|
||||
</svg></span>';
|
||||
}elseif ($item->level >= 2){
|
||||
echo '<span>' . $linktype . '</span>';
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user