primo commit
This commit is contained in:
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
175
administrator/components/com_jem/views/attendee/tmpl/default.php
Normal file
175
administrator/components/com_jem/views/attendee/tmpl/default.php
Normal file
@ -0,0 +1,175 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Router\Route;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Session\Session;
|
||||
|
||||
HTMLHelper::_('jquery.framework');
|
||||
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$wa = $document->getWebAssetManager();
|
||||
$wa->useScript('jquery')
|
||||
->useScript('keepalive')
|
||||
->useScript('form.validate');
|
||||
|
||||
$selectuser_link = Route::_('index.php?option=com_jem&task=attendee.selectuser&tmpl=component');
|
||||
echo HTMLHelper::_(
|
||||
'bootstrap.renderModal',
|
||||
'user-modal',
|
||||
array(
|
||||
'url' => $selectuser_link.'&'.Session::getFormToken().'=1',
|
||||
'title' => Text::_('COM_JEM_SELECT'),
|
||||
'width' => '800px',
|
||||
'height' => '450px',
|
||||
'footer' => '<button type="button" class="btn btn-secondary" data-bs-dismiss="modal">' . Text::_('COM_JEM_CLOSE') . '</button>'
|
||||
)
|
||||
);
|
||||
?>
|
||||
|
||||
<script>
|
||||
function modalSelectUser(id, username)
|
||||
{
|
||||
jQuery('#uid').val(id) ;
|
||||
jQuery('#username').val(username);
|
||||
// window.parent.SqueezeBox.close();
|
||||
jQuery("#user-modal").modal("hide");
|
||||
}
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
if (task == 'attendee.cancel' || document.formvalidator.isValid(document.getElementById('adminForm'))) {
|
||||
if (task == 'attendee.cancel' || document.getElementById('adminForm').uid.value != 0) {
|
||||
Joomla.submitform(task, document.getElementById('adminForm'));
|
||||
} else {
|
||||
alert("<?php echo Text::_('COM_JEM_SELECT_AN_USER', true); ?>");
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
alert('<?php echo $this->escape(Text::_('JGLOBAL_VALIDATION_FORM_FAILED'));?>');
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=attendee'); ?>" method="post" name="adminForm" id="adminForm" class="form-validate">
|
||||
<fieldset>
|
||||
<h3><?php echo Text::_('COM_JEM_DETAILS'); ?></h3>
|
||||
<?php if (!empty($this->row->id)) : ?>
|
||||
<p>
|
||||
<?php echo Text::_('COM_JEM_EDITATTENDEE_NOTICE'); ?>
|
||||
</p>
|
||||
<?php endif; ?>
|
||||
|
||||
<table class="admintable">
|
||||
<tr>
|
||||
<td class="key">
|
||||
<label for="eventtitle" <?php echo JemOutput::tooltip(Text::_('COM_JEM_EVENT'), Text::_('COM_JEM_EVENT_DESC')); ?>>
|
||||
<?php echo Text::_('COM_JEM_EVENT').':'; ?>
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" name="eventtitle" id="eventtitle" class="form-control inputbox required valid form-control-success" readonly="readonly"
|
||||
value="<?php echo !empty($this->row->eventtitle) ? $this->row->eventtitle : '?'; ?>"
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="key">
|
||||
<label for="username" <?php echo JemOutput::tooltip(Text::_('COM_JEM_USER'), Text::_('COM_JEM_USER_DESC')); ?>>
|
||||
<?php echo Text::_('COM_JEM_USER').':'; ?>
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" name="username" id="username" class="form-control inputbox required valid form-control-success" readonly="readonly" value="<?php echo $this->row->username; ?>" />
|
||||
<input type="hidden" name="uid" id="uid" value="<?php echo $this->row->uid; ?>" />
|
||||
<a class="usermodal" href="javascript:void(0);" data-bs-toggle="modal" data-bs-target="#user-modal">
|
||||
<span class="btn btn-primary"><?php echo Text::_('COM_JEM_SELECT_USER')?></span>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="key">
|
||||
<label for="status" <?php echo JemOutput::tooltip(Text::_('COM_JEM_STATUS'), Text::_('COM_JEM_STATUS_DESC')); ?>>
|
||||
<?php echo Text::_('COM_JEM_STATUS').':'; ?>
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<?php
|
||||
$options = array(HTMLHelper::_('select.option', 0, Text::_('COM_JEM_ATTENDEES_INVITED')),
|
||||
HTMLHelper::_('select.option', -1, Text::_('COM_JEM_ATTENDEES_NOT_ATTENDING')),
|
||||
HTMLHelper::_('select.option', 1, Text::_('COM_JEM_ATTENDEES_ATTENDING')),
|
||||
HTMLHelper::_('select.option', 2, Text::_('COM_JEM_ATTENDEES_ON_WAITINGLIST'), array('disable' => empty($this->row->waitinglist))));
|
||||
|
||||
$selectOptions = array('id' => 'reg_status', 'class' => 'form-select');
|
||||
echo HTMLHelper::_('select.genericlist', $options, 'status', $selectOptions);
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="key">
|
||||
<label for="eventtitle" <?php echo JemOutput::tooltip(Text::_('COM_JEM_ATTENDEES_PLACES'), Text::_('COM_JEM_ATTENDEES_PLACES_DESC')); ?>>
|
||||
<?php echo Text::_('COM_JEM_ATTENDEES_PLACES').':'; ?>
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="number" name="places" id="places" class="form-control inputbox" min="<?php echo $this->row->minbookeduser; ?>" max="<?php echo $this->row->maxbookeduser; ?>"
|
||||
value="<?php echo !empty($this->row->places) ? $this->row->places : $this->row->minbookeduser; ?>"
|
||||
/>
|
||||
</td>
|
||||
</tr>
|
||||
<?php if (!empty($this->jemsettings->regallowcomments)): ?>
|
||||
<tr>
|
||||
<td class="key" style="vertical-align: baseline;">
|
||||
<label for="comment" <?php echo JemOutput::tooltip(Text::_('COM_JEM_COMMENT'), Text::_('COM_JEM_COMMENT_DESC')); ?>>
|
||||
<?php echo Text::_('COM_JEM_COMMENT').':'; ?>
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<textarea name="comment" id="reg_comment" rows="3" cols="30" maxlength="255"
|
||||
><?php if (!empty($this->row->comment)) { echo $this->row->comment; }
|
||||
/* looks crazy, but required to prevent unwanted white spaces within textarea content! */
|
||||
?></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<?php if ($this->row->recurrence_type && $this->row->seriesbooking): ?>
|
||||
<tr>
|
||||
<td class="key">
|
||||
<label for="seriesbooking" <?php echo JemOutput::tooltip(Text::_('COM_JEM_EDITEVENT_FIELD_BOOKED_SERIES'), Text::_('COM_JEM_EDITEVENT_FIELD_BOOKED_SERIES')); ?>>
|
||||
<?php echo Text::_('COM_JEM_EDITEVENT_FIELD_BOOKED_SERIES').':'; ?>
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="checkbox" id="seriesbooking" name="seriesbooking" value="1""/>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<tr>
|
||||
<td class="key">
|
||||
<label for="sendemail" <?php echo JemOutput::tooltip(Text::_('COM_JEM_SEND_REGISTRATION_NOTIFICATION_EMAIL'), Text::_('COM_JEM_SEND_REGISTRATION_NOTIFICATION_EMAIL_DESC')); ?>>
|
||||
<?php echo Text::_('COM_JEM_SEND_REGISTRATION_NOTIFICATION_EMAIL').':'; ?>
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="checkbox" id="sendemail" name="sendemail" value="1" checked="checked"/>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
</table>
|
||||
</fieldset>
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
<input type="hidden" name="id" value="<?php echo $this->row->id; ?>" />
|
||||
<input type="hidden" name="event" value="<?php echo ($this->row->event ? $this->row->event : $this->event); ?>" />
|
||||
<input type="hidden" name="task" value="" />
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
105
administrator/components/com_jem/views/attendee/view.html.php
Normal file
105
administrator/components/com_jem/views/attendee/view.html.php
Normal file
@ -0,0 +1,105 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\MVC\View\HtmlView;
|
||||
/**
|
||||
* View class: Attendee
|
||||
*/
|
||||
class JemViewAttendee extends HtmlView {
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
//initialise variables
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$jinput = $app->input;
|
||||
|
||||
$this->jemsettings = JemHelper::config();
|
||||
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
//get id register user for event
|
||||
$id = $jinput->getInt('id', 0);
|
||||
$this->event = $jinput->getInt('eventid', 0);
|
||||
|
||||
// Load css
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
//Get data from the model
|
||||
$row = $this->get('Data');
|
||||
|
||||
//build selectlists
|
||||
$lists = array();
|
||||
// TODO: On J! 2.5 we need last param 0 because it defaults to 1 activating a useless feature.
|
||||
// On J! 3.x this param and the useless feature has been removed so we should remove last param.
|
||||
// Such changes are of sort "grrr".
|
||||
$lists['users'] = HTMLHelper::_('list.users', 'uid', $row->uid, false, NULL, 'name', 0);
|
||||
|
||||
//assign data to template
|
||||
$this->lists = $lists;
|
||||
$this->row = $row;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
Factory::getApplication()->input->set('hidemainmenu', true);
|
||||
|
||||
//get vars
|
||||
$cid = Factory::getApplication()->input->get('cid', array(), 'array');
|
||||
$user = JemFactory::getUser();
|
||||
$checkedOut = false; // don't know, table hasn't such a field
|
||||
$canDo = JemHelperBackend::getActions();
|
||||
|
||||
if (empty($cid[0])) {
|
||||
ToolbarHelper::title(Text::_('COM_JEM_ADD_ATTENDEE'), 'users');
|
||||
} else {
|
||||
ToolbarHelper::title(Text::_('COM_JEM_EDIT_ATTENDEE'), 'users');
|
||||
}
|
||||
|
||||
// If not checked out, can save the item.
|
||||
if (!$checkedOut && ($canDo->get('core.edit')||$canDo->get('core.create'))) {
|
||||
ToolbarHelper::apply('attendee.apply');
|
||||
ToolbarHelper::save('attendee.save');
|
||||
}
|
||||
|
||||
if (!$checkedOut && $canDo->get('core.create')) {
|
||||
ToolbarHelper::save2new('attendee.save2new');
|
||||
}
|
||||
|
||||
// If an existing item, can save to a copy.
|
||||
if (!empty($cid[0]) && $canDo->get('core.create')) {
|
||||
ToolbarHelper::save2copy('attendee.save2copy');
|
||||
}
|
||||
|
||||
if (empty($cid[0])) {
|
||||
ToolbarHelper::cancel('attendee.cancel');
|
||||
} else {
|
||||
ToolbarHelper::cancel('attendee.cancel', 'JTOOLBAR_CLOSE');
|
||||
}
|
||||
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::help('editattendee', true);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,164 @@
|
||||
<?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;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
HTMLHelper::addIncludePath(JPATH_COMPONENT.'/helpers/html');
|
||||
|
||||
$user = JemFactory::getUser();
|
||||
$userId = $user->get('id');
|
||||
$listOrder = $this->escape($this->state->get('list.ordering'));
|
||||
$listDirn = $this->escape($this->state->get('list.direction'));
|
||||
$document = Factory::getApplication()->getDocument();
|
||||
$wa = $document->getWebAssetManager();
|
||||
|
||||
$wa->addInlineScript('
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
document.adminForm.task.value=task;
|
||||
if (task == "attendees.export") {
|
||||
Joomla.submitform(task, document.getElementById("adminForm"));
|
||||
document.adminForm.task.value="";
|
||||
} else {
|
||||
Joomla.submitform(task, document.getElementById("adminForm"));
|
||||
}
|
||||
};
|
||||
');
|
||||
$wa->addInlineScript('
|
||||
function submitName(node) {
|
||||
node.parentNode.previousElementSibling.childNodes[0].checked = true;
|
||||
Joomla.submitbutton("attendees.edit");
|
||||
}
|
||||
');
|
||||
?>
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=attendees&eventid='.$this->event->id); ?>" method="post" name="adminForm" id="adminForm">
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<fieldset id="filter-bar" class="mb-3">
|
||||
<div class="row">
|
||||
<div class="col-md-11">
|
||||
<div class="row mb-12">
|
||||
<div class="col-md-2">
|
||||
<strong><?php echo Text::_('COM_JEM_DATE').':'; ?></strong> <?php echo $this->event->dates; ?><br />
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<strong><?php echo Text::_('COM_JEM_EVENT_TITLE').':'; ?></strong> <?php echo $this->escape($this->event->title); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="row">
|
||||
<div class="wauto-minwmax">
|
||||
<div class="float-end">
|
||||
<?php echo $this->pagination->getLimitBox(); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
<table class="adminform">
|
||||
<tr>
|
||||
<td width="100%">
|
||||
<?php echo Text::_('COM_JEM_SEARCH').' '.$this->lists['filter']; ?>
|
||||
<input type="text" name="filter_search" id="filter_search" value="<?php echo $this->lists['search']; ?>" class="text_area" onChange="document.adminForm.submit();" />
|
||||
<button class="buttonfilter" type="submit"><?php echo Text::_('JSEARCH_FILTER_SUBMIT'); ?></button>
|
||||
<button class="buttonfilter" type="button" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
</td>
|
||||
<td style="text-align:right; white-space:nowrap;">
|
||||
<?php echo Text::_('COM_JEM_STATUS').' '.$this->lists['status']; ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<table class="table table-striped" id="attendeeList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="1%" class="center"><input type="checkbox" name="checkall-toggle" value="" title="<?php echo Text::_('JGLOBAL_CHECK_ALL'); ?>" onclick="Joomla.checkAll(this)" /></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_NAME', 'u.name', $listDirn, $listOrder); ?></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_USERNAME', 'u.username', $listDirn, $listOrder); ?></th>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_EMAIL'); ?></th>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_IP_ADDRESS'); ?></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_REGDATE', 'r.uregdate', $listDirn, $listOrder); ?></th>
|
||||
<th class="title center"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_USER_ID', 'r.uid', $listDirn, $listOrder); ?></th>
|
||||
<th class="title center"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_HEADER_WAITINGLIST_STATUS', 'r.waiting',$listDirn, $listOrder); ?></th>
|
||||
<th class="title center"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_ATTENDEES_PLACES', 'r.waiting',$listDirn, $listOrder); ?></th>
|
||||
<?php if (!empty($this->jemsettings->regallowcomments)) : ?>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_COMMENT'); ?></th>
|
||||
<?php endif;?>
|
||||
<th class="title center"><?php echo Text::_('COM_JEM_REMOVE_USER'); ?></th>
|
||||
<th width="1%" class="center nowrap"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_ATTENDEES_REGID', 'r.id', $listDirn, $listOrder ); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
<?php
|
||||
$canChange = $user->authorise('core.edit.state');
|
||||
|
||||
foreach ($this->items as $i => $row) :
|
||||
?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td class="center"><?php echo HTMLHelper::_('grid.id', $i, $row->id); ?></td> <?php // Die ID kann man doch auch als Parameter für "submitName()" nehmen. Dann muss ich nicht erst den Baum entlang hangeln ?>
|
||||
<td><a href="<?php echo Route::_('index.php?option=com_jem&view=attendee&event='.$row->event . '&id='.$row->id);?>"><?php echo $row->name; ?></a></td>
|
||||
<td><?php echo $row->username; ?></td>
|
||||
<td class="email"><a href="mailto:<?php echo $row->email; ?>"><?php echo $row->email; ?></a></td>
|
||||
<td><?php echo $row->uip == 'DISABLED' ? Text::_('COM_JEM_DISABLED') : $row->uip; ?></td>
|
||||
<td><?php if (!empty($row->uregdate)) { echo HTMLHelper::_('date', $row->uregdate, Text::_('DATE_FORMAT_LC2')); } ?></td>
|
||||
<td class="center">
|
||||
<a href="<?php echo Route::_('index.php?option=com_users&task=user.edit&id='.$row->uid); ?>"><?php echo $row->uid; ?></a>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php
|
||||
$status = (int)$row->status;
|
||||
if($this->event->waitinglist) {
|
||||
if ($status === 1 && $row->waiting == 1) {
|
||||
$status = 2;
|
||||
}
|
||||
echo jemhtml::toggleAttendanceStatus($i, $status, $canChange);
|
||||
} else {
|
||||
echo jemhtml::toggleAttendanceStatus($i, $status, false);
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo $row->places; ?>
|
||||
</td>
|
||||
<?php if (!empty($this->jemsettings->regallowcomments)) : ?>
|
||||
<?php $cmnt = (\Joomla\String\StringHelper::strlen($row->comment) > 16) ? (rtrim(\Joomla\String\StringHelper::substr($row->comment, 0, 14)).'…') : $row->comment; ?>
|
||||
<td><?php if (!empty($cmnt)) { echo HTMLHelper::_('tooltip', $row->comment, null, null, $cmnt, null, null); } ?></td>
|
||||
<?php endif; ?>
|
||||
<td class="center">
|
||||
<a href="javascript: void(0);" onclick="return Joomla.listItemTask('cb<?php echo $i;?>','attendees.remove')">
|
||||
<?php echo HTMLHelper::_('image','com_jem/publish_r.png',Text::_('COM_JEM_REMOVE'),NULL,true); ?>
|
||||
</a>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo $this->escape($row->id); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div class="ms-auto mb-4 me-0">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks(null) : $this->pagination->getListFooter()); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<input type="hidden" name="task" value=""/>
|
||||
<input type="hidden" name="boxchecked" value="0"/>
|
||||
<input type="hidden" name="filter_order" value="<?php echo $listOrder; ?>"/>
|
||||
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn; ?>"/>
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</div>
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,78 @@
|
||||
<?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;
|
||||
?>
|
||||
<table style="width:100%" class="adminlist">
|
||||
<tr>
|
||||
<td class="sectionname" width="100%" style="color: #C24733; font-size: 18px; font-weight: bold;"><?php echo Text::_('COM_JEM_REGISTERED_USER'); ?></td>
|
||||
<td><div class="button2-left"><div class="blank"><a href="#" onclick="window.print();return false;"><?php echo Text::_('COM_JEM_PRINT'); ?></a></div></div></td>
|
||||
</tr>
|
||||
</table>
|
||||
<br />
|
||||
<table class="adminlist" style="width:100%">
|
||||
<tr>
|
||||
<td align="left">
|
||||
<b><?php echo Text::_('COM_JEM_DATE').':'; ?></b> <?php echo $this->event->dates; ?><br />
|
||||
<b><?php echo Text::_('COM_JEM_EVENT_TITLE').':'; ?></b> <?php echo $this->escape($this->event->title); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<br />
|
||||
<table class="table table-striped" id="attendeesList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_NAME'); ?></th>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_USERNAME'); ?></th>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_EMAIL'); ?></th>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_REGDATE'); ?></th>
|
||||
<?php if ($this->event->waitinglist): ?>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_HEADER_WAITINGLIST_STATUS' ); ?></th>
|
||||
<?php endif; ?>
|
||||
<?php if (!empty($this->jemsettings->regallowcomments)) : ?>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_COMMENT'); ?></th>
|
||||
<?php endif; ?>
|
||||
<th class="title center"><?php echo Text::_('COM_JEM_USER_ID'); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<?php
|
||||
foreach ($this->rows as $i => $row) :
|
||||
?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td><?php echo $row->name; ?></td>
|
||||
<td><?php echo $row->username; ?></td>
|
||||
<td><?php echo $row->email; ?></td>
|
||||
<td><?php if (!empty($row->uregdate)) { echo HTMLHelper::_('date', $row->uregdate, Text::_('DATE_FORMAT_LC2')); } ?></td>
|
||||
<?php
|
||||
switch ($row->status) {
|
||||
case -1: // explicitely unregistered
|
||||
$text = 'COM_JEM_ATTENDEES_NOT_ATTENDING';
|
||||
break;
|
||||
case 0: // invited, not answered yet
|
||||
$text = 'COM_JEM_ATTENDEES_INVITED';
|
||||
break;
|
||||
case 1: // registered
|
||||
$text = $row->waiting ? 'COM_JEM_ATTENDEES_ON_WAITINGLIST' : 'COM_JEM_ATTENDEES_ATTENDING';
|
||||
break;
|
||||
default: // oops...
|
||||
$text = 'COM_JEM_ATTENDEES_STATUS_UNKNOWN';
|
||||
break;
|
||||
} ?>
|
||||
<td><?php echo Text::_($text); ?></td>
|
||||
<?php if (!empty($this->jemsettings->regallowcomments)) : ?>
|
||||
<td><?php echo $row->comment; ?></td>
|
||||
<?php endif; ?>
|
||||
<td class="center"><?php echo $row->uid; ?></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
150
administrator/components/com_jem/views/attendees/view.html.php
Normal file
150
administrator/components/com_jem/views/attendees/view.html.php
Normal file
@ -0,0 +1,150 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\Toolbar;
|
||||
|
||||
/**
|
||||
* View class: Attendees
|
||||
*/
|
||||
class JemViewAttendees extends JemAdminView
|
||||
{
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$app = Factory::getApplication();
|
||||
$db = Factory::getContainer()->get('DatabaseDriver');
|
||||
|
||||
$this->jemsettings = JemHelper::config();
|
||||
|
||||
if($this->getLayout() == 'print') {
|
||||
$this->_displayprint($tpl);
|
||||
return;
|
||||
}
|
||||
|
||||
$filter_status = $app->getUserStateFromRequest('com_jem.attendees.filter_status', 'filter_status', -2, 'int');
|
||||
$filter_type = $app->getUserStateFromRequest('com_jem.attendees.filter_type', 'filter_type', 0, 'int');
|
||||
$filter_search = $app->getUserStateFromRequest('com_jem.attendees.filter_search', 'filter_search', '', 'string');
|
||||
$filter_search = $db->escape(trim(\Joomla\String\StringHelper::strtolower($filter_search)));
|
||||
|
||||
// Load css
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// Get data from the model
|
||||
$event = $this->get('Event');
|
||||
|
||||
$this->items = $this->get('Items');
|
||||
$this->pagination = $this->get('Pagination');
|
||||
$this->state = $this->get('State');
|
||||
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
Factory::getApplication()->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
// check for data error
|
||||
if (empty($event)) {
|
||||
$app->enqueueMessage(Text::_('JERROR_AN_ERROR_HAS_OCCURRED'), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
if (JemHelper::isValidDate($event->dates)) {
|
||||
$event->dates = JemOutput::formatdate($event->dates);
|
||||
} else {
|
||||
$event->dates = Text::_('COM_JEM_OPEN_DATE');
|
||||
}
|
||||
|
||||
//build filter selectlist
|
||||
$filters = array();
|
||||
$filters[] = HTMLHelper::_('select.option', '1', Text::_('COM_JEM_NAME'));
|
||||
$filters[] = HTMLHelper::_('select.option', '2', Text::_('COM_JEM_USERNAME'));
|
||||
$lists['filter'] = HTMLHelper::_('select.genericlist', $filters, 'filter_type', array('size'=>'1','class'=>'inputbox'), 'value', 'text', $filter_type);
|
||||
|
||||
// search filter
|
||||
$lists['search'] = $filter_search;
|
||||
|
||||
// registration status
|
||||
$options = array(HTMLHelper::_('select.option', -2, Text::_('COM_JEM_ATT_FILTER_ALL')),
|
||||
HTMLHelper::_('select.option', 0, Text::_('COM_JEM_ATT_FILTER_INVITED')),
|
||||
HTMLHelper::_('select.option', -1, Text::_('COM_JEM_ATT_FILTER_NOT_ATTENDING')),
|
||||
HTMLHelper::_('select.option', 1, Text::_('COM_JEM_ATT_FILTER_ATTENDING')),
|
||||
HTMLHelper::_('select.option', 2, Text::_('COM_JEM_ATT_FILTER_WAITING')));
|
||||
$lists['status'] = HTMLHelper::_('select.genericlist', $options, 'filter_status', array('onChange'=>'this.form.submit();'), 'value', 'text', $filter_status);
|
||||
|
||||
//assign to template
|
||||
$this->lists = $lists;
|
||||
$this->event = $event;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Prepares the print screen
|
||||
*/
|
||||
protected function _displayprint($tpl = null)
|
||||
{
|
||||
// Load css
|
||||
HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
|
||||
$rows = $this->get('Items');
|
||||
$event = $this->get('Event');
|
||||
|
||||
if (JemHelper::isValidDate($event->dates)) {
|
||||
$event->dates = JemOutput::formatdate($event->dates);
|
||||
} else {
|
||||
$event->dates = Text::_('COM_JEM_OPEN_DATE');
|
||||
}
|
||||
|
||||
//assign data to template
|
||||
$this->rows = $rows;
|
||||
$this->event = $event;
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_REGISTERED_USERS'), 'users');
|
||||
|
||||
ToolbarHelper::addNew('attendees.add');
|
||||
ToolbarHelper::editList('attendees.edit');
|
||||
ToolbarHelper::custom('attendees.setNotAttending', 'loop', 'loop', Text::_('COM_JEM_ATTENDEES_SETNOTATTENDING'), true);
|
||||
ToolbarHelper::custom('attendees.setAttending', 'loop', 'loop', Text::_('COM_JEM_ATTENDEES_SETATTENDING'), true);
|
||||
if ($this->event->waitinglist) {
|
||||
ToolbarHelper::custom('attendees.setWaitinglist', 'loop', 'loop', Text::_('COM_JEM_ATTENDEES_SETWAITINGLIST'), true);
|
||||
}
|
||||
ToolbarHelper::spacer();
|
||||
ToolbarHelper::custom('attendees.export', 'download', 'download', Text::_('COM_JEM_EXPORT'), false);
|
||||
|
||||
$eventid = $this->event->id;
|
||||
$link_print = 'index.php?option=com_jem&view=attendees&layout=print&tmpl=component&eventid='.$eventid;
|
||||
|
||||
$bar = ToolBar::getInstance('toolbar');
|
||||
$bar->appendButton('Popup', 'print', 'COM_JEM_PRINT', $link_print, 600, 300);
|
||||
|
||||
ToolbarHelper::deleteList('COM_JEM_CONFIRM_DELETE', 'attendees.remove', 'COM_JEM_ATTENDEES_DELETE');
|
||||
ToolbarHelper::spacer();
|
||||
ToolbarHelper::custom('attendees.back', 'back', 'back', Text::_('COM_JEM_ATT_BACK'), false);
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::help('registereduser', true);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,238 @@
|
||||
<?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;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
$user = JemFactory::getUser();
|
||||
$userId = $user->get('id');
|
||||
$listOrder = $this->escape($this->state->get('list.ordering'));
|
||||
$listDirn = $this->escape($this->state->get('list.direction'));
|
||||
$canOrder = $user->authorise('core.edit.state', 'com_jem.category');
|
||||
$saveOrder = $listOrder == 'a.lft';
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
$wa->useScript('table.columns');
|
||||
?>
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=categories'); ?>" method="post" name="adminForm" id="adminForm">
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<fieldset id="filter-bar" class="mb-3">
|
||||
<div class="row">
|
||||
<div class="col-md-11">
|
||||
<div class="row mb-12">
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<input type="text" name="filter_search" id="filter_search" class="form-control" aria-describedby="filter_search-desc" placeholder="<?php echo Text::_('COM_JEM_SEARCH'); ?>" value="<?php echo $this->escape($this->state->get('filter_search')); ?>" inputmode="search" onChange="document.adminForm.submit();">
|
||||
|
||||
<button type="submit" class="filter-search-bar__button btn btn-primary" aria-label="Search">
|
||||
<span class="filter-search-bar__button-icon icon-search" aria-hidden="true"></span>
|
||||
</button>
|
||||
<button type="button" class="btn btn-primary" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<select name="filter_level" class="inputbox form-select wauto-minwmax m-0" onchange="this.form.submit()">
|
||||
<option value=""><?php echo Text::_('JOPTION_SELECT_MAX_LEVELS'); ?></option>
|
||||
<?php echo HTMLHelper::_('select.options', $this->f_levels, 'value', 'text', $this->state->get('filter.level')); ?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<select name="filter_published" class="inputbox form-select wauto-minwmax m-0" onchange="this.form.submit()">
|
||||
<option value=""><?php echo Text::_('JOPTION_SELECT_PUBLISHED'); ?></option>
|
||||
<?php echo HTMLHelper::_('select.options', HTMLHelper::_('jgrid.publishedOptions'), 'value', 'text', $this->state->get('filter.published'), true); ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="row">
|
||||
<div class="wauto-minwmax">
|
||||
<div class="float-end">
|
||||
<?php echo $this->pagination->getLimitBox(); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
|
||||
<div class="clr"></div>
|
||||
|
||||
<table class="table table-striped" id="articleList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width:1%" class="center">
|
||||
<input type="checkbox" name="checkall-toggle" value=""
|
||||
title="<?php echo Text::_('JGLOBAL_CHECK_ALL'); ?>" onclick="Joomla.checkAll(this)"/>
|
||||
</th>
|
||||
<th>
|
||||
<?php echo HTMLHelper::_('grid.sort', 'JGLOBAL_TITLE', 'a.catname', $listDirn, $listOrder); ?>
|
||||
</th>
|
||||
<th style="width:5%" class="center" nowrap="nowrap">
|
||||
<?php echo Text::_('COM_JEM_COLOR'); ?>
|
||||
</th>
|
||||
<th style="width:15%"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_GROUP', 'gr.name', $listDirn, $listOrder); ?></th>
|
||||
<th style="width:1%" class="center" nowrap="nowrap"><?php echo Text::_('COM_JEM_EVENTS'); ?></th>
|
||||
<th style="width:5%" class="center">
|
||||
<?php echo HTMLHelper::_('grid.sort', 'JSTATUS', 'a.published', $listDirn, $listOrder); ?>
|
||||
</th>
|
||||
<th style="width:5px%" class="center">
|
||||
<?php echo HTMLHelper::_('grid.sort', 'JGRID_HEADING_ORDERING', 'a.lft', $listDirn, $listOrder); ?>
|
||||
<?php if ($saveOrder) : ?>
|
||||
<?php //echo HTMLHelper::_('grid.order', $this->items, 'filesave.png', 'categories.saveorder'); ?>
|
||||
<?php endif; ?>
|
||||
</th>
|
||||
<th style="width:10%" class="center" nowrap="nowrap">
|
||||
<?php echo HTMLHelper::_('grid.sort', 'JGRID_HEADING_ACCESS', 'a.access', $listDirn, $listOrder); ?>
|
||||
</th>
|
||||
<th style="width:1%" class="center nowrap">
|
||||
<?php echo HTMLHelper::_('grid.sort', 'JGRID_HEADING_ID', 'a.id', $listDirn, $listOrder); ?>
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
<?php
|
||||
$originalOrders = array();
|
||||
$countItems = count($this->items);
|
||||
|
||||
foreach ($this->items as $i => $item) :
|
||||
$ordering = ($listOrder == 'a.lft');
|
||||
$canCreate = $user->authorise('core.create');
|
||||
$orderkey = array_search($item->id, $this->ordering[$item->parent_id]);
|
||||
$canEdit = $user->authorise('core.edit');
|
||||
$canCheckin = $user->authorise('core.manage', 'com_checkin') || $item->checked_out == $userId || $item->checked_out == 0;
|
||||
$canEditOwn = $user->authorise('core.edit.own') && $item->created_user_id == $userId;
|
||||
$canChange = $user->authorise('core.edit.state') && $canCheckin;
|
||||
$grouplink = 'index.php?option=com_jem&task=group.edit&id=' . $item->groupid;
|
||||
|
||||
if ($item->level > 0) {
|
||||
$repeat = $item->level - 1;
|
||||
} else {
|
||||
$repeat = 0;
|
||||
}
|
||||
?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td class="center">
|
||||
<?php echo HTMLHelper::_('grid.id', $i, $item->id); ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php echo str_repeat('<span class="gi">|—</span>', $repeat) ?>
|
||||
<?php if ($item->checked_out) : ?>
|
||||
<?php echo HTMLHelper::_('jgrid.checkedout', $i, $item->editor, $item->checked_out_time, 'categories.', $canCheckin); ?>
|
||||
<?php endif; ?>
|
||||
<?php if ($canEdit || $canEditOwn) : ?>
|
||||
<a href="<?php echo Route::_('index.php?option=com_jem&task=category.edit&id=' . $item->id); ?>">
|
||||
<?php echo $this->escape($item->catname); ?></a>
|
||||
<?php else : ?>
|
||||
<?php echo $this->escape($item->catname); ?>
|
||||
<?php endif; ?>
|
||||
<p class="smallsub" title="<?php echo $this->escape($item->path); ?>">
|
||||
<?php echo str_repeat('<span class="gtr">|—</span>', $repeat) ?>
|
||||
<?php if (empty($item->note)) : ?>
|
||||
<?php echo Text::sprintf('JGLOBAL_LIST_ALIAS', $this->escape($item->alias)); ?>
|
||||
<?php else : ?>
|
||||
<?php echo Text::sprintf('JGLOBAL_LIST_ALIAS_NOTE', $this->escape($item->alias), $this->escape($item->note)); ?>
|
||||
<?php endif; ?></p>
|
||||
</td>
|
||||
<td class="center">
|
||||
<div class="colorpreview<?php echo ($item->color == '') ? ' transparent-color" title="transparent"' : '" style="background-color:' . $item->color . '"' ?> aria-labelledby="
|
||||
color-desc-<?php echo $item->id; ?>">
|
||||
</div>
|
||||
<div role="tooltip"
|
||||
id="color-desc-<?php echo $item->id; ?>"><?php echo ($item->color == '') ? 'transparent' : $item->color ?>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<?php if ($item->catgroup) : ?>
|
||||
<span <?php echo JEMOutput::tooltip(Text::_('COM_JEM_GROUP_EDIT'), $item->catgroup, 'editlinktip'); ?>>
|
||||
<a href="<?php echo $grouplink; ?>">
|
||||
<?php echo $this->escape($item->catgroup); ?>
|
||||
</a></span>
|
||||
<?php elseif ($item->groupid) : ?>
|
||||
<?php echo Text::sprintf('COM_JEM_CATEGORY_UNKNOWN_GROUP', $item->groupid); ?>
|
||||
<?php else : ?>
|
||||
<?php echo '-'; ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo $item->assignedevents; ?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo HTMLHelper::_('jgrid.published', $item->published, $i, 'categories.', $canChange); ?>
|
||||
</td>
|
||||
<td class="order">
|
||||
<?php if ($canChange) : ?>
|
||||
<?php $disabled = $saveOrder ? '' : 'disabled="disabled"'; ?>
|
||||
<div style="display:-webkit-box">
|
||||
<div><input type="text" style="text-align: center; margin: auto 0; min-width: 50px;" name="order[]"
|
||||
size="5" value="<?php echo $orderkey + 1; ?>" <?php echo $disabled ?>
|
||||
class="text-area-order"/></div>
|
||||
|
||||
<?php if ($saveOrder) :
|
||||
if ($listDirn == 'asc') : ?>
|
||||
<div><?php if ($i) : ?>
|
||||
<span><?php echo $this->pagination->orderUpIcon($i, true, 'categories.orderup', 'JLIB_HTML_MOVE_UP', $ordering); ?></span>
|
||||
<?php else : ?>
|
||||
<div style='width:32px;'> </div>
|
||||
<?php endif; ?></div>
|
||||
<div><?php if ($countItems != $i + 1) : ?>
|
||||
<span><?php echo $this->pagination->orderDownIcon($i, $this->pagination->total, true, 'categories.orderdown', 'JLIB_HTML_MOVE_DOWN', $ordering); ?></span>
|
||||
<?php else : ?>
|
||||
<div style='width:32px;'> </div>
|
||||
<?php endif; ?></div>
|
||||
<?php elseif ($listDirn == 'desc') : ?>
|
||||
<div><?php if ($i) : ?>
|
||||
<span><?php echo $this->pagination->orderUpIcon($i, true, 'categories.orderdown', 'JLIB_HTML_MOVE_UP', $ordering); ?></span>
|
||||
<?php else : ?>
|
||||
<div style='width:32px;'> </div>
|
||||
<?php endif; ?></div>
|
||||
<div><?php if ($countItems != $i + 1) : ?>
|
||||
<span><?php echo $this->pagination->orderDownIcon($i, $this->pagination->total, true, 'categories.orderup', 'JLIB_HTML_MOVE_DOWN', $ordering); ?></span>
|
||||
<?php else : ?>
|
||||
<div style='width:32px;'> </div>
|
||||
<?php endif; ?></div>
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<?php else : ?>
|
||||
<?php echo $item->ordering; ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo $this->escape($item->access_level); ?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<span title="<?php echo sprintf('%d-%d', $item->lft, $item->rgt); ?>">
|
||||
<?php echo (int)$item->id; ?>
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div class="ms-auto mb-4 me-0">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks(null) : $this->pagination->getListFooter()); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<input type="hidden" name="task" value=""/>
|
||||
<input type="hidden" name="boxchecked" value="0"/>
|
||||
<input type="hidden" name="filter_order" value="<?php echo $listOrder; ?>"/>
|
||||
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn; ?>"/>
|
||||
<input type="hidden" name="original_order_values" value="<?php echo implode(',', $originalOrders); ?>"/>
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</div>
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
122
administrator/components/com_jem/views/categories/view.html.php
Normal file
122
administrator/components/com_jem/views/categories/view.html.php
Normal file
@ -0,0 +1,122 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
/**
|
||||
* View class for the JEM Categories screen
|
||||
*/
|
||||
class JemViewCategories extends JemAdminView
|
||||
{
|
||||
protected $items;
|
||||
protected $pagination;
|
||||
protected $state;
|
||||
|
||||
/**
|
||||
* Display the view
|
||||
*/
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$this->state = $this->get('State');
|
||||
$this->items = $this->get('Items');
|
||||
$this->pagination = $this->get('Pagination');
|
||||
$this->app = Factory::getApplication();
|
||||
$this->document = $this->app->getDocument();
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
$this->app->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
$wa = $this->app->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
|
||||
// Preprocess the list of items to find ordering divisions.
|
||||
foreach ($this->items as &$item) {
|
||||
$this->ordering[$item->parent_id][] = $item->id;
|
||||
}
|
||||
|
||||
// Levels filter.
|
||||
$options = array();
|
||||
$options[] = HTMLHelper::_('select.option', '1', Text::_('J1'));
|
||||
$options[] = HTMLHelper::_('select.option', '2', Text::_('J2'));
|
||||
$options[] = HTMLHelper::_('select.option', '3', Text::_('J3'));
|
||||
$options[] = HTMLHelper::_('select.option', '4', Text::_('J4'));
|
||||
$options[] = HTMLHelper::_('select.option', '5', Text::_('J5'));
|
||||
$options[] = HTMLHelper::_('select.option', '6', Text::_('J6'));
|
||||
$options[] = HTMLHelper::_('select.option', '7', Text::_('J7'));
|
||||
$options[] = HTMLHelper::_('select.option', '8', Text::_('J8'));
|
||||
$options[] = HTMLHelper::_('select.option', '9', Text::_('J9'));
|
||||
$options[] = HTMLHelper::_('select.option', '10', Text::_('J10'));
|
||||
|
||||
$this->f_levels = $options;
|
||||
|
||||
$this->addToolbar();
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
|
||||
// Initialise variables.
|
||||
$canDo = null;
|
||||
$user = JemFactory::getUser();
|
||||
|
||||
// Get the results for each action.
|
||||
$canDo = JemHelperBackend::getActions(0);
|
||||
|
||||
ToolbarHelper::title(Text::_('COM_JEM_CATEGORIES'), 'elcategories');
|
||||
|
||||
if ($canDo->get('core.create')) {
|
||||
ToolbarHelper::addNew('category.add');
|
||||
}
|
||||
|
||||
if ($canDo->get('core.edit' ) || $canDo->get('core.edit.own')) {
|
||||
ToolbarHelper::editList('category.edit');
|
||||
ToolbarHelper::divider();
|
||||
}
|
||||
|
||||
if ($canDo->get('core.edit.state')) {
|
||||
ToolbarHelper::publish('categories.publish', 'JTOOLBAR_PUBLISH', true);
|
||||
ToolbarHelper::unpublish('categories.unpublish', 'JTOOLBAR_UNPUBLISH', true);
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::archiveList('categories.archive');
|
||||
}
|
||||
|
||||
if ($user->authorise('core.admin')) { // todo: is that correct?
|
||||
ToolbarHelper::checkin('categories.checkin');
|
||||
}
|
||||
|
||||
if ($this->state->get('filter.published') == -2 && $canDo->get('core.delete')) {
|
||||
ToolbarHelper::deleteList('COM_JEM_CONFIRM_DELETE', 'categories.remove', 'JTOOLBAR_EMPTY_TRASH');
|
||||
}
|
||||
elseif ($canDo->get('core.edit.state')) {
|
||||
ToolbarHelper::trash('categories.trash');
|
||||
}
|
||||
|
||||
if ($canDo->get('core.admin')) {
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::custom('categories.rebuild', 'refresh.png', 'refresh_f2.png', 'JTOOLBAR_REBUILD', false);
|
||||
}
|
||||
|
||||
ToolbarHelper::divider();
|
||||
ToolBarHelper::help('listcategories', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/categories');
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
183
administrator/components/com_jem/views/category/tmpl/edit.php
Normal file
183
administrator/components/com_jem/views/category/tmpl/edit.php
Normal file
@ -0,0 +1,183 @@
|
||||
<?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
|
||||
*
|
||||
* @todo make custom colorfield so it can be used within xml
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Router\Route;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
|
||||
// Include the component HTML helpers.
|
||||
HTMLHelper::addIncludePath(JPATH_COMPONENT.'/helpers/html');
|
||||
|
||||
$wa = $this->document->getWebAssetManager();
|
||||
$wa->useStyle('jem.colorpicker')
|
||||
->useScript('keepalive')
|
||||
->useScript('inlinehelp')
|
||||
->useScript('form.validate');
|
||||
?>
|
||||
|
||||
<script>
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
if (task == 'category.cancel' || document.formvalidator.isValid(document.getElementById('item-form'))) {
|
||||
<?php
|
||||
//echo $this->form->getField('description')->save();
|
||||
?>
|
||||
Joomla.submitform(task, document.getElementById('item-form'));
|
||||
} else {
|
||||
alert('<?php echo $this->escape(Text::_('JGLOBAL_VALIDATION_FORM_FAILED'));?>');
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&layout=edit&id='.(int) $this->item->id); ?>" method="post" name="adminForm" id="item-form" class="form-validate">
|
||||
<div class="row">
|
||||
<div class="col-md-7">
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_CATEGORY_FIELDSET_DETAILS');?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('catname'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('alias'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('extension'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('parent_id'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('published'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('access'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('color'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('id'); ?></div></li>
|
||||
</ul>
|
||||
<div class="clr"></div>
|
||||
<?php echo $this->form->getLabel('description'); ?>
|
||||
<div class="clr"></div>
|
||||
<?php echo $this->form->getInput('description'); ?>
|
||||
</fieldset>
|
||||
</div>
|
||||
|
||||
<div class="col-md-5">
|
||||
<?php //echo HTMLHelper::_('sliders.start', 'categories-sliders-'.$this->item->id, array('useCookie'=>1)); ?>
|
||||
<div class="accordion" id="accordionCategoriesForm">
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="publishing-details-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#publishing-details" aria-expanded="true" aria-controls="publishing-details">
|
||||
<?php echo Text::_('COM_JEM_FIELDSET_PUBLISHING'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="publishing-details" class="accordion-collapse collapse show" aria-labelledby="publishing-details-header" data-bs-parent="#accordionCategoriesForm">
|
||||
<div class="accordion-body">
|
||||
<?php echo $this->loadTemplate('options'); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="confemail-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#confemail" aria-expanded="true" aria-controls="confemail">
|
||||
<?php echo Text::_('COM_JEM_CATEGORY_FIELDSET_EMAIL'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="confemail" class="accordion-collapse collapse" aria-labelledby="confemail-header" data-bs-parent="#accordionCategoriesForm">
|
||||
<div class="accordion-body">
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
<li>
|
||||
<div class="label-form"><?php echo $this->form->renderfield('email'); ?></div>
|
||||
</li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
|
||||
<div class="accordion-body">
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
<li>
|
||||
<div class="label-form"><?php echo $this->form->renderfield('emailacljl'); ?></div>
|
||||
</li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="group-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#group" aria-expanded="true" aria-controls="group">
|
||||
<?php echo Text::_('COM_JEM_GROUP'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="group" class="accordion-collapse collapse" aria-labelledby="group-header" data-bs-parent="#accordionCategoriesForm">
|
||||
<div class="accordion-body">
|
||||
<ul class="adminformlist">
|
||||
<li><label for="groups"> <?php echo Text::_('COM_JEM_GROUP').':'; ?></label>
|
||||
<?php echo $this->Lists['groups']; ?></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- START OF PANEL IMAGE -->
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="category-image-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#category-image" aria-expanded="true" aria-controls="category-image">
|
||||
<?php echo Text::_('COM_JEM_IMAGE'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="category-image" class="accordion-collapse collapse" aria-labelledby="category-image-header" data-bs-parent="#accordionCategoriesForm">
|
||||
<div class="accordion-body">
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('image'); ?></div>
|
||||
</li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="meta-options-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#meta-options" aria-expanded="true" aria-controls="meta-options">
|
||||
<?php echo Text::_('JGLOBAL_FIELDSET_METADATA_OPTIONS'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="meta-options" class="accordion-collapse collapse" aria-labelledby="meta-options-header" data-bs-parent="#accordionCategoriesForm">
|
||||
<div class="accordion-body">
|
||||
<fieldset class="panelform">
|
||||
<?php echo $this->loadTemplate('metadata'); ?>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<?php $fieldSets = $this->form->getFieldsets('attribs'); ?>
|
||||
<?php foreach ($fieldSets as $name => $fieldSet) : ?>
|
||||
<?php $label = !empty($fieldSet->label) ? $fieldSet->label : 'COM_JEM_'.$name.'_FIELDSET_LABEL'; ?>
|
||||
<?php if ($name != 'editorConfig' && $name != 'basic-limited') : ?>
|
||||
<?php echo HTMLHelper::_('sliders.panel', Text::_($label), $name.'-options'); ?>
|
||||
<?php if (isset($fieldSet->description) && trim($fieldSet->description)) : ?>
|
||||
<p class="tip"><?php echo $this->escape(Text::_($fieldSet->description));?></p>
|
||||
<?php endif; ?>
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset($name) as $field) : ?>
|
||||
<li><?php echo $field->label; ?>
|
||||
<?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
<?php endif ?>
|
||||
<?php endforeach; ?>
|
||||
<?php //echo HTMLHelper::_('sliders.end'); ?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clr"></div>
|
||||
<div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</div>
|
||||
</form>
|
||||
@ -0,0 +1,27 @@
|
||||
<?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;
|
||||
|
||||
?>
|
||||
<ul class="adminformlist">
|
||||
<li><?php echo $this->form->getLabel('meta_description'); ?>
|
||||
<?php echo $this->form->getInput('meta_description'); ?></li>
|
||||
|
||||
<li><?php echo $this->form->getLabel('meta_keywords'); ?>
|
||||
<?php echo $this->form->getInput('meta_keywords'); ?></li>
|
||||
|
||||
<?php foreach($this->form->getGroup('metadata') as $field): ?>
|
||||
<?php if ($field->hidden): ?>
|
||||
<li><?php echo $field->input; ?></li>
|
||||
<?php else: ?>
|
||||
<li><?php echo $field->label; ?>
|
||||
<?php echo $field->input; ?></li>
|
||||
<?php endif; ?>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
@ -0,0 +1,56 @@
|
||||
<?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;
|
||||
?>
|
||||
|
||||
<?php //echo HTMLHelper::_('sliders.panel', Text::_('JGLOBAL_FIELDSET_PUBLISHING'), 'publishing-details'); ?>
|
||||
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('created_user_id'); ?></div></li>
|
||||
|
||||
<?php if (intval($this->item->created_time)) : ?>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('created_time'); ?></div></li>
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if ($this->item->modified_user_id) : ?>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('modified_user_id'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('modified_time'); ?></div></li>
|
||||
<?php endif; ?>
|
||||
|
||||
</ul>
|
||||
</fieldset>
|
||||
|
||||
<?php $fieldSets = $this->form->getFieldsets('params');
|
||||
|
||||
foreach ($fieldSets as $name => $fieldSet) :
|
||||
$label = !empty($fieldSet->label) ? $fieldSet->label : 'COM_CATEGORIES_'.$name.'_FIELDSET_LABEL';
|
||||
echo HTMLHelper::_('sliders.panel', Text::_($label), $name.'-options');
|
||||
if (isset($fieldSet->description) && trim($fieldSet->description)) :
|
||||
echo '<p class="tip">'.$this->escape(Text::_($fieldSet->description)).'</p>';
|
||||
endif;
|
||||
?>
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset($name) as $field) : ?>
|
||||
<li><?php echo $field->label; ?>
|
||||
<?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
|
||||
<?php if ($name=='basic'):?>
|
||||
<li><?php echo $this->form->getLabel('note'); ?>
|
||||
<?php echo $this->form->getInput('note'); ?></li>
|
||||
<?php endif;?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
<?php endforeach; ?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
124
administrator/components/com_jem/views/category/view.html.php
Normal file
124
administrator/components/com_jem/views/category/view.html.php
Normal file
@ -0,0 +1,124 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
|
||||
/**
|
||||
* Category View
|
||||
*/
|
||||
class JemViewCategory extends JemAdminView
|
||||
{
|
||||
protected $form;
|
||||
protected $item;
|
||||
protected $state;
|
||||
|
||||
/**
|
||||
* Display the view
|
||||
*/
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$this->form = $this->get('Form');
|
||||
$this->item = $this->get('Item');
|
||||
$this->state = $this->get('State');
|
||||
$this->canDo = JemHelperBackend::getActions($this->state->get('category.component'));
|
||||
|
||||
$app = Factory::getApplication();
|
||||
$this->document = $app->getDocument();
|
||||
$uri = Uri::getInstance();
|
||||
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
Factory::getApplication()->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
// Load css
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
$wa->registerStyle('jem.colorpicker', 'com_jem/colorpicker.css');
|
||||
|
||||
// Load Script
|
||||
$this->document->addScript($uri->root().'media/com_jem/js/colorpicker.js');
|
||||
|
||||
// build grouplist
|
||||
// @todo: make a form-field for this one
|
||||
$groups = $this->get('Groups');
|
||||
|
||||
$grouplist = array();
|
||||
if (!empty($this->item->groupid) && !array_key_exists($this->item->groupid, $groups)) {
|
||||
$grouplist[] = HTMLHelper::_('select.option', $this->item->groupid, Text::sprintf('COM_JEM_CATEGORY_UNKNOWN_GROUP', $this->item->groupid));
|
||||
}
|
||||
$grouplist[] = HTMLHelper::_('select.option', '0', Text::_('COM_JEM_CATEGORY_NO_GROUP'));
|
||||
$grouplist = array_merge($grouplist, $groups);
|
||||
|
||||
$Lists['groups'] = HTMLHelper::_('select.genericlist', $grouplist, 'groupid', array('size'=>'1','class'=>'inputbox form-select m-0'), 'value', 'text', $this->item->groupid);
|
||||
$this->Lists = $Lists;
|
||||
|
||||
parent::display($tpl);
|
||||
|
||||
$app->input->set('hidemainmenu', true);
|
||||
$this->addToolbar();
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
// Initialise variables.
|
||||
$user = JemFactory::getUser();
|
||||
$userId = $user->get('id');
|
||||
|
||||
$isNew = ($this->item->id == 0);
|
||||
$checkedOut = !($this->item->checked_out == 0 || $this->item->checked_out == $userId);
|
||||
|
||||
// Get the results for each action.
|
||||
$canDo = JemHelperBackend::getActions();
|
||||
|
||||
$title = Text::_('COM_JEM_CATEGORY_BASE_'.($isNew?'ADD':'EDIT').'_TITLE');
|
||||
// Prepare the toolbar.
|
||||
ToolbarHelper::title($title, 'category-'.($isNew?'add':'edit').' -category-'.($isNew?'add':'edit'));
|
||||
|
||||
// For new records, check the create permission.
|
||||
if ($isNew && (count($user->getAuthorisedCategories('com_jem', 'core.create')) > 0)) {
|
||||
ToolbarHelper::apply('category.apply');
|
||||
ToolbarHelper::save('category.save');
|
||||
ToolbarHelper::save2new('category.save2new');
|
||||
}
|
||||
|
||||
// If not checked out, can save the item.
|
||||
elseif (!$checkedOut && ($canDo->get('core.edit') || ($canDo->get('core.edit.own') && $this->item->created_user_id == $userId))) {
|
||||
ToolbarHelper::apply('category.apply');
|
||||
ToolbarHelper::save('category.save');
|
||||
if ($canDo->get('core.create')) {
|
||||
ToolbarHelper::save2new('category.save2new');
|
||||
}
|
||||
}
|
||||
|
||||
// If an existing item, can save to a copy.
|
||||
if (!$isNew && $canDo->get('core.create')) {
|
||||
ToolbarHelper::save2copy('category.save2copy');
|
||||
}
|
||||
|
||||
if (empty($this->item->id)) {
|
||||
ToolbarHelper::cancel('category.cancel');
|
||||
} else {
|
||||
ToolbarHelper::cancel('category.cancel', 'JTOOLBAR_CLOSE');
|
||||
}
|
||||
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::inlinehelp();
|
||||
ToolBarHelper::help('editcategories', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/categories/add-category');
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,84 @@
|
||||
<?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\Factory;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
|
||||
$function = Factory::getApplication()->input->getCmd('function', 'jSelectCategory');
|
||||
?>
|
||||
|
||||
<form action="index.php?option=com_jem&view=categoryelement&tmpl=component" method="post" name="adminForm" id="adminForm">
|
||||
|
||||
<table class="adminform">
|
||||
<tr>
|
||||
<td width="100%">
|
||||
<input type="text" name="filter_search" id="filter_search" placeholder="<?php echo Text::_('COM_JEM_SEARCH');?>" value="<?php echo $this->lists['search']; ?>" class="text_area" onChange="document.adminForm.submit();" />
|
||||
<button type="submit"><?php echo Text::_('JSEARCH_FILTER_SUBMIT'); ?></button>
|
||||
<button type="button" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
<button type="button" onclick="if (window.parent) window.parent.<?php echo $this->escape($function);?>('', '<?php echo Text::_('COM_JEM_SELECT_CATEGORY') ?>');"><?php echo Text::_('COM_JEM_GLOBAL_NOCATEGORY')?></button>
|
||||
</td>
|
||||
<td nowrap="nowrap">
|
||||
<select name="filter_state" class="inputbox" onchange="this.form.submit()">
|
||||
<option value=""><?php echo Text::_('JOPTION_SELECT_PUBLISHED');?></option>
|
||||
<?php echo HTMLHelper::_('select.options', HTMLHelper::_('jgrid.publishedOptions',array('all' => 0, 'unpublished' => 0,'archived' => 0, 'trash' => 0)), 'value', 'text', $this->filter_state, true);?>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table class="table table-striped" id="articleList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="7" class="center"><?php echo Text::_('COM_JEM_NUM'); ?></th>
|
||||
<th align="left" class="title"><?php echo HTMLHelper::_('grid.sort','COM_JEM_CATEGORY','c.catname',$this->lists['order_Dir'],$this->lists['order']); ?></th>
|
||||
<th width="1%" nowrap="nowrap"><?php echo Text::_('COM_JEM_ACCESS'); ?></th>
|
||||
<th width="1%" nowrap="nowrap"><?php echo Text::_('JSTATUS'); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="4">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks() : $this->pagination->getListFooter()); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
|
||||
<tbody>
|
||||
<?php
|
||||
foreach ($this->rows as $i => $row) :
|
||||
$access = $row->groupname;
|
||||
?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td class="center" width="7"><?php echo $this->pagination->getRowOffset( $i ); ?></td>
|
||||
<td align="left">
|
||||
<a class="pointer" onclick="if (window.parent) window.parent.<?php echo $this->escape($function);?>('<?php echo $row->id; ?>', '<?php echo $this->escape(addslashes($row->catname)); ?>');"><?php echo htmlspecialchars_decode($this->escape($row->treename)); ?></a>
|
||||
</td>
|
||||
<td class="center"><?php echo $access; ?></td>
|
||||
<td class="center">
|
||||
<?php echo HTMLHelper::_('jgrid.published', $row->published, $i,'',false); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
|
||||
<div class="copyright">
|
||||
<?php echo JemAdmin::footer( ); ?>
|
||||
</div>
|
||||
|
||||
<input type="hidden" name="task" value="">
|
||||
<input type="hidden" name="tmpl" value="component">
|
||||
<input type="hidden" name="function" value="<?php echo $this->escape($function); ?>" />
|
||||
<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']; ?>" />
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,69 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\MVC\View\HtmlView;
|
||||
|
||||
/**
|
||||
* Categoryelement-View
|
||||
*/
|
||||
class JemViewCategoryelement extends HtmlView {
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
//initialise variables
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$db = Factory::getContainer()->get('DatabaseDriver');
|
||||
$itemid = $app->input->getInt('id', 0) . ':' . $app->input->getInt('Itemid', 0);
|
||||
|
||||
//get vars
|
||||
$filter_order = $app->getUserStateFromRequest('com_jem.categoryelement.filter_order', 'filter_order', 'c.lft', 'cmd');
|
||||
$filter_order_Dir = $app->getUserStateFromRequest('com_jem.categoryelement.filter_order_Dir', 'filter_order_Dir', '', 'word');
|
||||
$filter_state = $app->getUserStateFromRequest('com_jem.categoryelement.'.$itemid.'.filter_state', 'filter_state', '', 'string');
|
||||
$search = $app->getUserStateFromRequest('com_jem.categoryelement.'.$itemid.'.filter_search', 'filter_search', '', 'string');
|
||||
$search = $db->escape(trim(\Joomla\String\StringHelper::strtolower($search)));
|
||||
|
||||
//prepare document
|
||||
$document->setTitle(Text::_('COM_JEM_SELECT_CATEGORY'));
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// Get data from the model
|
||||
$rows = $this->get('Data');
|
||||
$pagination = $this->get('Pagination');
|
||||
|
||||
//publish unpublished filter
|
||||
$lists['state'] = HTMLHelper::_('grid.state', $filter_state);
|
||||
|
||||
// table ordering
|
||||
$lists['order_Dir'] = $filter_order_Dir;
|
||||
$lists['order'] = $filter_order;
|
||||
|
||||
// search filter
|
||||
$lists['search']= $search;
|
||||
|
||||
//assign data to template
|
||||
$this->lists = $lists;
|
||||
$this->filter_state = $filter_state;
|
||||
$this->rows = $rows;
|
||||
$this->pagination = $pagination;
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,75 @@
|
||||
<?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\Factory;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
$function = Factory::getApplication()->input->getCmd('function', 'jSelectContact');
|
||||
?>
|
||||
|
||||
<form action="index.php?option=com_jem&view=contactelement&tmpl=component" method="post" name="adminForm" id="adminForm">
|
||||
|
||||
<table class="adminform">
|
||||
<tr>
|
||||
<td width="100%">
|
||||
<?php echo Text::_('COM_JEM_SEARCH').' '.$this->lists['filter']; ?>
|
||||
<input type="text" name="filter_search" id="filter_search" value="<?php echo $this->lists['search']; ?>" class="text_area" onChange="document.adminForm.submit();" />
|
||||
<button class="buttonfilter" type="submit"><?php echo Text::_('JSEARCH_FILTER_SUBMIT'); ?></button>
|
||||
<button class="buttonfilter" type="button" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
<button class="buttonfilter" type="button" onclick="if (window.parent) window.parent.<?php echo $this->escape($function);?>('', '<?php echo Text::_('COM_JEM_SELECTCONTACT') ?>');"><?php echo Text::_('COM_JEM_NOCONTACT')?></button>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table class="table table-striped" id="articleList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="7" class="center"><?php echo Text::_('COM_JEM_NUM'); ?></th>
|
||||
<th align="left" class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_NAME', 'con.name', $this->lists['order_Dir'], $this->lists['order'] ); ?></th>
|
||||
<th align="left" class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_ADDRESS', 'con.address', $this->lists['order_Dir'], $this->lists['order'] ); ?></th>
|
||||
<th align="left" class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_CITY', 'con.suburb', $this->lists['order_Dir'], $this->lists['order'] ); ?></th>
|
||||
<th align="left" class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_STATE', 'con.state', $this->lists['order_Dir'], $this->lists['order'] ); ?></th>
|
||||
<th align="left" class="title"><?php echo Text::_('COM_JEM_EMAIL'); ?></th>
|
||||
<th align="left" class="title"><?php echo Text::_('COM_JEM_TELEPHONE'); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="12">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks() : $this->pagination->getListFooter()); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
|
||||
<tbody>
|
||||
<?php foreach ($this->rows as $i => $row) : ?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td class="center"><?php echo $this->pagination->getRowOffset( $i ); ?></td>
|
||||
<td align="left">
|
||||
<span <?php echo JEMOutput::tooltip(Text::_('COM_JEM_SELECT'), $row->name, 'editlinktip'); ?>>
|
||||
<a style="cursor:pointer;" onclick="if (window.parent) window.parent.<?php echo $this->escape($function);?>('<?php echo $row->id; ?>', '<?php echo $this->escape(addslashes($row->name)); ?>');"><?php echo $this->escape($row->name); ?></a>
|
||||
</span>
|
||||
</td>
|
||||
<td align="left"><?php echo $this->escape($row->address); ?></td>
|
||||
<td align="left"><?php echo $this->escape($row->suburb); ?></td>
|
||||
<td align="left"><?php echo $this->escape($row->state); ?></td>
|
||||
<td align="left"><?php echo $this->escape($row->email_to); ?></td>
|
||||
<td align="left"><?php echo $this->escape($row->telephone); ?></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<input type="hidden" name="task" value="" />
|
||||
<input type="hidden" name="function" value="<?php echo $this->escape($function); ?>" />
|
||||
<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']; ?>" />
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,73 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\MVC\View\HtmlView;
|
||||
/**
|
||||
* View class for the JEM Contactelement screen
|
||||
*
|
||||
* @package JEM
|
||||
*
|
||||
*/
|
||||
class JEMViewContactelement extends HtmlView {
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
//initialise variables
|
||||
$app = Factory::getApplication();
|
||||
$db = Factory::getContainer()->get('DatabaseDriver');
|
||||
$document = $app->getDocument();
|
||||
|
||||
//get vars
|
||||
$filter_order = $app->getUserStateFromRequest('com_jem.contactelement.filter_order', 'filter_order', 'con.name', 'cmd');
|
||||
$filter_order_Dir = $app->getUserStateFromRequest('com_jem.contactelement.filter_order_Dir', 'filter_order_Dir', '', 'word');
|
||||
$filter_type = $app->getUserStateFromRequest('com_jem.contactelement.filter_type', 'filter_type', 0, 'int');
|
||||
$search = $app->getUserStateFromRequest('com_jem.contactelement.filter_search', 'filter_search', '', 'string');
|
||||
$search = $db->escape(trim(\Joomla\String\StringHelper::strtolower($search)));
|
||||
|
||||
//prepare document
|
||||
$document->setTitle(Text::_('COM_JEM_SELECTVENUE'));
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// Get data from the model
|
||||
$rows = $this->get('Data');
|
||||
$pagination = $this->get('Pagination');
|
||||
|
||||
// table ordering
|
||||
$lists['order_Dir'] = $filter_order_Dir;
|
||||
$lists['order'] = $filter_order;
|
||||
|
||||
//Build search filter
|
||||
$filters = array();
|
||||
$filters[] = HTMLHelper::_('select.option', '1', Text::_('COM_JEM_NAME'));
|
||||
$filters[] = HTMLHelper::_('select.option', '2', Text::_('COM_JEM_ADDRESS'));
|
||||
$filters[] = HTMLHelper::_('select.option', '3', Text::_('COM_JEM_CITY'));
|
||||
$filters[] = HTMLHelper::_('select.option', '4', Text::_('COM_JEM_STATE'));
|
||||
$lists['filter'] = HTMLHelper::_('select.genericlist', $filters, 'filter_type', array('size'=>'1','class'=>'inputbox'), 'value', 'text', $filter_type);
|
||||
|
||||
// search filter
|
||||
$lists['search']= $search;
|
||||
|
||||
//assign data to template
|
||||
$this->lists = $lists;
|
||||
$this->rows = $rows;
|
||||
$this->pagination = $pagination;
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
}
|
||||
?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,80 @@
|
||||
<?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;
|
||||
|
||||
$wa = $this->document->getWebAssetManager();
|
||||
$wa->useScript('keepalive');
|
||||
|
||||
|
||||
$canDo = JEMHelperBackend::getActions();
|
||||
?>
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=cssmanager'); ?>" method="post" name="adminForm" id="adminForm">
|
||||
<?php if (isset($this->sidebar)) : ?>
|
||||
<!-- <div id="j-sidebar-container" class="span2">
|
||||
<?php //echo $this->sidebar; ?>
|
||||
</div> -->
|
||||
<?php endif; ?>
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_CSSMANAGER_DESCRIPTION_LEGEND');?></legend>
|
||||
<p><?php echo Text::_('COM_JEM_CSSMANAGER_DESCRIPTION');?></p>
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_CSSMANAGER_FILENAMES');?></legend>
|
||||
<?php if (!empty($this->files['css'])) : ?>
|
||||
<ul>
|
||||
<?php foreach ($this->files['css'] as $file) : ?>
|
||||
<li>
|
||||
<?php if ($canDo->get('core.edit')) : ?>
|
||||
<a href="<?php echo Route::_('index.php?option=com_jem&task=source.edit&id='.$file->id);?>">
|
||||
<?php endif; ?>
|
||||
<?php echo Text::sprintf('COM_JEM_CSSMANAGER_EDIT_CSS', $file->name);?>
|
||||
<?php if ($canDo->get('core.edit')) : ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_CSSMANAGER_FILENAMES_CUSTOM');?></legend>
|
||||
<?php if (!empty($this->files['custom'])) : ?>
|
||||
<ul>
|
||||
<?php foreach ($this->files['custom'] as $file) : ?>
|
||||
<li>
|
||||
<?php if ($canDo->get('core.edit')) : ?>
|
||||
<a href="<?php echo Route::_('index.php?option=com_jem&task=source.edit&id='.$file->id);?>">
|
||||
<?php endif; ?>
|
||||
<?php echo Text::sprintf('COM_JEM_CSSMANAGER_EDIT_CSS', $file->name);?>
|
||||
<?php if ($canDo->get('core.edit')) : ?>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
</fieldset>
|
||||
<div class="clr"></div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
<?php //if (isset($this->sidebar)) : ?>
|
||||
<?php //endif; ?>
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,66 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
/**
|
||||
* View class for the Css-manager screen
|
||||
*/
|
||||
class JemViewCssmanager extends JemAdminView
|
||||
{
|
||||
|
||||
protected $files;
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$this->files = $this->get('Files');
|
||||
$this->statusLinenumber = $this->get('StatusLinenumber');
|
||||
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
Factory::getApplication()->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
$app = Factory::getApplication();
|
||||
|
||||
// initialise variables
|
||||
$this->document = $app->getDocument();
|
||||
$user = JemFactory::getUser();
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_CSSMANAGER_TITLE'), 'thememanager');
|
||||
|
||||
// ToolbarHelper::back();
|
||||
ToolbarHelper::custom('cssmanager.back', 'back', 'back', Text::_('COM_JEM_ATT_BACK'), false);
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::inlinehelp();
|
||||
ToolBarHelper::help('editcss', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/control-panel/css-manager');
|
||||
}
|
||||
}
|
||||
1
administrator/components/com_jem/views/event/index.html
Normal file
1
administrator/components/com_jem/views/event/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
601
administrator/components/com_jem/views/event/tmpl/edit.php
Normal file
601
administrator/components/com_jem/views/event/tmpl/edit.php
Normal file
@ -0,0 +1,601 @@
|
||||
<?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
|
||||
*
|
||||
* @todo: move js to a file
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Router\Route;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Date\Date;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
|
||||
$this->document->addScript(Uri::root(true) . 'media/com_jem/js/recurrence.js');
|
||||
|
||||
$options = array(
|
||||
'onActive' => 'function(title, description){
|
||||
description.setStyle("display", "block");
|
||||
title.addClass("open").removeClass("closed");
|
||||
}',
|
||||
'onBackground' => 'function(title, description){
|
||||
description.setStyle("display", "none");
|
||||
title.addClass("closed").removeClass("open");
|
||||
}',
|
||||
'opacityTransition' => true,
|
||||
'startOffset' => 0, // 0 starts on the first tab, 1 starts the second, etc...
|
||||
'useCookie' => true, // this must not be a string. Don't use quotes.
|
||||
);
|
||||
|
||||
$wa = $this->document->getWebAssetManager();
|
||||
$wa->useScript('keepalive')
|
||||
->useScript('form.validate')
|
||||
->useScript('inlinehelp')
|
||||
->useScript('multiselect');
|
||||
|
||||
// Create shortcut to parameters.
|
||||
$params = $this->state->get('params');
|
||||
$params = $params->toArray();
|
||||
|
||||
?>
|
||||
|
||||
<script>
|
||||
function checkmaxplaces()
|
||||
{
|
||||
$('#jform_maxplaces').on('change', function(){
|
||||
if ($('#event-available')) {
|
||||
var val = parseInt($('#jform_maxplaces').val());
|
||||
var booked = parseInt($('#event-booked').val());
|
||||
$('#event-available').val((val-booked));
|
||||
}
|
||||
});
|
||||
|
||||
$('#jform_maxplaces').on('keyup', function(){
|
||||
if ($('#event-available')) {
|
||||
var val = parseInt($('#jform_maxplaces').val());
|
||||
var booked = parseInt($('#event-booked').val());
|
||||
$('#event-available').val((val-booked));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function testcomm()
|
||||
{
|
||||
var commhandler = $("#jform_attribs_event_comunsolution");
|
||||
var nrcommhandler = commhandler.options[commhandler.selectedIndex].value;
|
||||
|
||||
if (nrcommhandler == 1) {
|
||||
common();
|
||||
} else {
|
||||
commoff();
|
||||
}
|
||||
}
|
||||
|
||||
function testmap()
|
||||
{
|
||||
var mapserv = $("#jform_attribs_event_show_mapserv");
|
||||
var nrmapserv = mapserv.options[mapserv.selectedIndex].value;
|
||||
|
||||
if (nrmapserv == 1 || nrmapserv == 2) {
|
||||
eventmapon();
|
||||
} else {
|
||||
eventmapoff();
|
||||
}
|
||||
}
|
||||
|
||||
function eventmapon()
|
||||
{
|
||||
document.getElementById('eventmap1').style.display = '';
|
||||
document.getElementById('eventmap2').style.display = '';
|
||||
}
|
||||
|
||||
function eventmapoff()
|
||||
{
|
||||
document.getElementById('eventmap1').style.display = 'none';
|
||||
document.getElementById('eventmap2').style.display = 'none';
|
||||
}
|
||||
|
||||
function common()
|
||||
{
|
||||
document.getElementById('comm1').style.display = '';
|
||||
}
|
||||
|
||||
function commoff()
|
||||
{
|
||||
document.getElementById('comm1').style.display = 'none';
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
if (task == 'event.cancel' || document.formvalidator.isValid(document.getElementById('event-form'))) {
|
||||
Joomla.submitform(task, document.getElementById('event-form'));
|
||||
|
||||
<?php //echo $this->form->getField('articletext')->save(); ?>
|
||||
|
||||
document.getElementById("meta_keywords").value = $keywords;
|
||||
document.getElementById("meta_description").value = $description;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
$(document).ready(function () {
|
||||
var $registraSelect = $("#jform_registra");
|
||||
var $restOfList = $registraSelect.closest(".adminformlist").find("li:not(:first-child)");
|
||||
$registraSelect.on("change", function () {
|
||||
var selectedValue = parseInt($(this).val());
|
||||
if (selectedValue === 0) {
|
||||
$restOfList.hide();
|
||||
} else {
|
||||
$restOfList.show();
|
||||
}
|
||||
});
|
||||
var $minBookedUserInput = $("#jform_minbookeduser");
|
||||
var $maxBookedUserInput = $("#jform_maxbookeduser");
|
||||
var $maxPlacesInput = $("#jform_maxplaces");
|
||||
var $reservedPlacesInput = $("#jform_reservedplaces");
|
||||
|
||||
$minBookedUserInput
|
||||
.add($maxBookedUserInput)
|
||||
.add($maxPlacesInput)
|
||||
.add($reservedPlacesInput)
|
||||
.on("change", function () {
|
||||
var minBookedUserValue = parseInt($minBookedUserInput.val());
|
||||
var maxBookedUserValue = parseInt($maxBookedUserInput.val());
|
||||
var maxPlacesValue = parseInt($maxPlacesInput.val());
|
||||
var reservedPlacesValue = parseInt($reservedPlacesInput.val());
|
||||
if (minBookedUserValue > maxPlacesValue && maxPlacesValue != 0) {
|
||||
$minBookedUserInput.val(maxPlacesValue);
|
||||
}
|
||||
if (maxBookedUserValue > maxPlacesValue && maxPlacesValue != 0) {
|
||||
$maxBookedUserInput.val(maxPlacesValue);
|
||||
}
|
||||
if (minBookedUserValue > maxBookedUserValue) {
|
||||
$minBookedUserInput.val(maxBookedUserValue);
|
||||
}
|
||||
if (reservedPlacesValue > maxPlacesValue && maxPlacesValue != 0) {
|
||||
$reservedPlacesInput.val(maxPlacesValue);
|
||||
}
|
||||
});
|
||||
// Trigger the change event on page load to initialize the state
|
||||
$registraSelect.change();
|
||||
$minBookedUserInput.change();
|
||||
});
|
||||
</script>
|
||||
<form
|
||||
action="<?php echo Route::_('index.php?option=com_jem&layout=edit&id='.(int) $this->item->id); ?>"
|
||||
class="form-validate" method="post" name="adminForm" id="event-form" enctype="multipart/form-data">
|
||||
|
||||
<?php $recurr = empty($this->item->recurr_bak) ? $this->item : $this->item->recurr_bak; ?>
|
||||
<?php if (!empty($recurr->recurrence_number) || !empty($recurr->recurrence_type)) : ?>
|
||||
<div class="description">
|
||||
<div style="float:left;">
|
||||
<?php echo JemOutput::recurrenceicon($recurr, false, false); ?>
|
||||
</div>
|
||||
<div class="floattext" style="margin-left:36px;">
|
||||
<strong><?php echo Text::_('COM_JEM_EDITEVENT_WARN_RECURRENCE_TITLE'); ?></strong>
|
||||
<br>
|
||||
<?php
|
||||
if (!empty($recurr->recurrence_type) && empty($recurr->recurrence_first_id)) {
|
||||
echo nl2br(Text::_('COM_JEM_EDITEVENT_WARN_RECURRENCE_FIRST_TEXT'));
|
||||
} else {
|
||||
echo nl2br(Text::_('COM_JEM_EDITEVENT_WARN_RECURRENCE_TEXT'));
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clear"></div>
|
||||
<?php endif; ?>
|
||||
|
||||
<!-- START OF LEFT DIV -->
|
||||
<div class="row">
|
||||
<div class="col-md-7">
|
||||
|
||||
<?php echo HTMLHelper::_('uitab.startTabSet', 'myTab', ['active' => 'info', 'recall' => true, 'breakpoint' => 768]); ?>
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'myTab', 'info', Text::_('COM_JEM_EVENT_INFO_TAB')); ?>
|
||||
|
||||
<!-- START OF LEFT FIELDSET -->
|
||||
<fieldset class="adminform">
|
||||
<legend>
|
||||
<?php echo empty($this->item->id) ? Text::_('COM_JEM_NEW_EVENT') : Text::sprintf('COM_JEM_EVENT_DETAILS', $this->item->id); ?>
|
||||
</legend>
|
||||
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('title'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('alias'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('dates'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('enddates'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('times'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('endtimes'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('cats'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
|
||||
<fieldset class="adminform">
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('locid'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('contactid'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('published'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('featured'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('access'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
|
||||
<fieldset class="adminform">
|
||||
<div class="clr"></div>
|
||||
<?php echo $this->form->getLabel('articletext'); ?>
|
||||
<div class="clr"></div>
|
||||
<?php echo $this->form->getInput('articletext'); ?>
|
||||
<!-- END OF FIELDSET -->
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'myTab', 'attachments', Text::_('COM_JEM_EVENT_ATTACHMENTS_TAB')); ?>
|
||||
<?php //echo HTMLHelper::_('tabs.panel',Text::_('COM_JEM_EVENT_ATTACHMENTS_TAB'), 'attachments' ); ?>
|
||||
<?php echo $this->loadTemplate('attachments'); ?>
|
||||
|
||||
<?php //echo HTMLHelper::_('tabs.panel',Text::_('COM_JEM_EVENT_SETTINGS_TAB'), 'event-settings' ); ?>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'myTab', 'event-settings', Text::_('COM_JEM_EVENT_SETTINGS_TAB')); ?>
|
||||
<?php echo $this->loadTemplate('settings'); ?>
|
||||
|
||||
<?php //echo HTMLHelper::_('tabs.end'); ?>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<!-- END OF LEFT DIV -->
|
||||
</div>
|
||||
|
||||
<!-- START RIGHT DIV -->
|
||||
<div class="col-md-5">
|
||||
|
||||
<!-- START OF SLIDERS -->
|
||||
<?php //echo HTMLHelper::_('sliders.start', 'event-sliders-'.$this->item->id, $options); ?>
|
||||
|
||||
<!-- START OF PANEL PUBLISHING -->
|
||||
<?php //echo HTMLHelper::_('sliders.panel', Text::_('COM_JEM_FIELDSET_PUBLISHING'), 'publishing-details'); ?>
|
||||
|
||||
<!-- RETRIEVING OF FIELDSET PUBLISHING -->
|
||||
<div class="accordion" id="accordionEventForm">
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="publishing-details-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#publishing-details" aria-expanded="true" aria-controls="publishing-details">
|
||||
<?php echo Text::_('COM_JEM_FIELDSET_PUBLISHING'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="publishing-details" class="accordion-collapse collapse show" aria-labelledby="publishing-details-header" data-bs-parent="#accordionEventForm">
|
||||
<div class="accordion-body">
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('id'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('created_by'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('hits'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('created'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('modified'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('version'); ?></div></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="custom-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#custom" aria-expanded="true" aria-controls="custom">
|
||||
<?php echo Text::_('COM_JEM_CUSTOMFIELDS'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="custom" class="accordion-collapse collapse" aria-labelledby="custom-header" data-bs-parent="#accordionEventForm">
|
||||
<div class="accordion-body">
|
||||
<ul class="adminformlist">
|
||||
<?php foreach($this->form->getFieldset('custom') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="registra-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#registra" aria-expanded="true" aria-controls="registra">
|
||||
<?php echo Text::_('COM_JEM_REGISTRATION'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="registra" class="accordion-collapse collapse" aria-labelledby="registra-header" data-bs-parent="#accordionEventForm">
|
||||
<div class="accordion-body">
|
||||
<ul class="adminformlist" style="margin-bottom: 60px;">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('registra'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('registra_from'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('registra_until'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('unregistra'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('unregistra_until'); ?></div></li>
|
||||
<?php if($this->jemsettings->regallowinvitation) { ?>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('reginvitedonly'); ?></div></li>
|
||||
<?php } ?>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('maxplaces'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('minbookeduser'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('maxbookeduser'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('reservedplaces'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('waitinglist'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('requestanswer'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('seriesbooking'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('singlebooking'); ?></div></li>
|
||||
<li>
|
||||
<div class="label-form"><div class="control-group">
|
||||
<div class="control-label">
|
||||
<label id="availableplaces-lbl"><?php echo Text::_ ('COM_JEM_AVAILABLE_PLACES') . ':';?></label>
|
||||
</div>
|
||||
<div class="controls">
|
||||
<input type="number" name="availableplaces" id="availableplaces" value=<?php echo ($this->item->maxplaces? ($this->item->maxplaces-$this->item->booked-$this->item->reservedplaces):'0'); ?> class="form-control inputbox" size="4" aria-describedby="jform_reservedplaces-desc" readonly>
|
||||
<div id="availableplaces-desc" class="hide-aware-inline-help d-none">
|
||||
<small class="form-text">
|
||||
<?php echo Text::_ ('COM_JEM_AVAILABLE_PLACES_DESC') ;?></small>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- START OF PANEL IMAGE -->
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="image-event-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#image-event" aria-expanded="true" aria-controls="image-event">
|
||||
<?php echo Text::_('COM_JEM_IMAGE'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
|
||||
<div id="image-event" class="accordion-collapse collapse" aria-labelledby="image-event-header" data-bs-parent="#accordionEventForm">
|
||||
<div class="accordion-body">
|
||||
<ul class="adminformlist" style="margin-bottom: 130px;">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('datimage'); ?></div></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="recurrence-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#recurrence" aria-expanded="true" aria-controls="recurrence">
|
||||
<?php echo Text::_('COM_JEM_RECURRING_EVENTS'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
|
||||
<div id="recurrence" class="accordion-collapse collapse" aria-labelledby="recurrence-header" data-bs-parent="#accordionEventForm">
|
||||
<div class="accordion-body">
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('recurrence_type', null, $recurr->recurrence_type); ?></div></li>
|
||||
<li id="recurrence_output" class="m-3">
|
||||
<?php if ($recurr->recurrence_number){ ?>
|
||||
<input type="hidden" name="recurrence_number" id="recurrence_number" value="<?php echo $recurr->recurrence_number;?>"></input>
|
||||
<?php } ?>
|
||||
<label></label>
|
||||
</li>
|
||||
<?php
|
||||
switch ($recurr->recurrence_type) {
|
||||
case 1:
|
||||
$anticipation = $this->jemsettings->recurrence_anticipation_day;
|
||||
break;
|
||||
case 2:
|
||||
$anticipation = $this->jemsettings->recurrence_anticipation_week;
|
||||
break;
|
||||
case 3:
|
||||
$anticipation = $this->jemsettings->recurrence_anticipation_month;
|
||||
break;
|
||||
case 4:
|
||||
$anticipation = $this->jemsettings->recurrence_anticipation_week;
|
||||
break;
|
||||
case 5:
|
||||
$anticipation = $this->jemsettings->recurrence_anticipation_year;
|
||||
break;
|
||||
default:
|
||||
$anticipation = $this->jemsettings->recurrence_anticipation_day;
|
||||
break;
|
||||
|
||||
}
|
||||
$limitdate = new Date('now + '.$anticipation.' month');
|
||||
$limitdate = $limitdate->format('d-m-Y');
|
||||
?>
|
||||
<li id="counter_row" style="display: none;">
|
||||
<div class="label-form"><?php echo $this->form->renderfield('recurrence_limit_date', null, $recurr->recurrence_limit_date ?? $recurr->recurrence_limit_date); ?></div>
|
||||
<br><div><small>
|
||||
<?php
|
||||
echo Text::sprintf(Text::_('COM_JEM_EVENT_NOTICE_GENSHIELD'),$limitdate);
|
||||
?></small></div>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<input type="hidden" name="recurrence_number" id="recurrence_number" value="<?php echo $this->item->recurrence_number;?>" />
|
||||
<input type="hidden" name="recurrence_number_saved" id="recurrence_number_saved" value="<?php echo $this->item->recurrence_number;?>" />
|
||||
<input type="hidden" name="recurrence_byday" id="recurrence_byday" value="<?php echo $this->item->recurrence_byday;?>" />
|
||||
|
||||
<script
|
||||
type="text/javascript">
|
||||
<!--
|
||||
var $select_output = new Array();
|
||||
$select_output[1] = "<?php echo Text::_ ('COM_JEM_OUTPUT_DAY'); ?>";
|
||||
$select_output[2] = "<?php echo Text::_ ('COM_JEM_OUTPUT_WEEK'); ?>";
|
||||
$select_output[3] = "<?php echo Text::_ ('COM_JEM_OUTPUT_MONTH'); ?>";
|
||||
$select_output[4] = "<?php echo Text::_ ('COM_JEM_OUTPUT_WEEKDAY'); ?>";
|
||||
$select_output[5] = "<?php echo Text::_ ('COM_JEM_OUTPUT_YEAR'); ?>";
|
||||
|
||||
var $weekday = new Array();
|
||||
$weekday[0] = new Array("MO", "<?php echo Text::_ ('COM_JEM_MONDAY'); ?>");
|
||||
$weekday[1] = new Array("TU", "<?php echo Text::_ ('COM_JEM_TUESDAY'); ?>");
|
||||
$weekday[2] = new Array("WE", "<?php echo Text::_ ('COM_JEM_WEDNESDAY'); ?>");
|
||||
$weekday[3] = new Array("TH", "<?php echo Text::_ ('COM_JEM_THURSDAY'); ?>");
|
||||
$weekday[4] = new Array("FR", "<?php echo Text::_ ('COM_JEM_FRIDAY'); ?>");
|
||||
$weekday[5] = new Array("SA", "<?php echo Text::_ ('COM_JEM_SATURDAY'); ?>");
|
||||
$weekday[6] = new Array("SU", "<?php echo Text::_ ('COM_JEM_SUNDAY'); ?>");
|
||||
|
||||
var $before_last = "<?php echo Text::_ ('COM_JEM_BEFORE_LAST'); ?>";
|
||||
var $last = "<?php echo Text::_ ('COM_JEM_LAST'); ?>";
|
||||
start_recurrencescript("jform_recurrence_type");
|
||||
-->
|
||||
</script>
|
||||
<?php /* show "old" recurrence settings for information */
|
||||
if (!empty($this->item->recurr_bak->recurrence_type)) {
|
||||
$recurr_type = '';
|
||||
$recurrence_first_id = $this->item->recurr_bak->recurrence_first_id;
|
||||
$rlDate = $this->item->recurr_bak->recurrence_limit_date;
|
||||
if (!empty($rlDate)) {
|
||||
$recurr_limit_date = JemOutput::formatdate($rlDate);
|
||||
} else {
|
||||
$recurr_limit_date = Text::_('COM_JEM_UNLIMITED');
|
||||
}
|
||||
|
||||
switch ($this->item->recurr_bak->recurrence_type) {
|
||||
case 1:
|
||||
$recurr_type = Text::_('COM_JEM_DAILY');
|
||||
$recurr_info = str_ireplace('[placeholder]',
|
||||
$this->item->recurr_bak->recurrence_number,
|
||||
Text::_('COM_JEM_OUTPUT_DAY'));
|
||||
break;
|
||||
case 2:
|
||||
$recurr_type = Text::_('COM_JEM_WEEKLY');
|
||||
$recurr_info = str_ireplace('[placeholder]',
|
||||
$this->item->recurr_bak->recurrence_number,
|
||||
Text::_('COM_JEM_OUTPUT_WEEK'));
|
||||
break;
|
||||
case 3:
|
||||
$recurr_type = Text::_('COM_JEM_MONTHLY');
|
||||
$recurr_info = str_ireplace('[placeholder]',
|
||||
$this->item->recurr_bak->recurrence_number,
|
||||
Text::_('COM_JEM_OUTPUT_MONTH'));
|
||||
break;
|
||||
case 4:
|
||||
$recurr_type = Text::_('COM_JEM_WEEKDAY');
|
||||
$recurr_byday = preg_replace('/(,)([^ ,]+)/', '$1 $2', $this->item->recurr_bak->recurrence_byday);
|
||||
$recurr_days = str_ireplace(array('MO', 'TU', 'WE', 'TH', 'FR', 'SA', 'SO'),
|
||||
array(Text::_('COM_JEM_MONDAY'), Text::_('COM_JEM_TUESDAY'),
|
||||
Text::_('COM_JEM_WEDNESDAY'), Text::_('COM_JEM_THURSDAY'),
|
||||
Text::_('COM_JEM_FRIDAY'), Text::_('COM_JEM_SATURDAY'),
|
||||
Text::_('COM_JEM_SUNDAY')),
|
||||
$recurr_byday);
|
||||
$recurr_num = str_ireplace(array('5', '6'),
|
||||
array(Text::_('COM_JEM_LAST'), Text::_('COM_JEM_BEFORE_LAST')),
|
||||
$this->item->recurr_bak->recurrence_number);
|
||||
$recurr_info = str_ireplace(array('[placeholder]', '[placeholder_weekday]'),
|
||||
array($recurr_num, $recurr_days),
|
||||
Text::_('COM_JEM_OUTPUT_WEEKDAY'));
|
||||
break;
|
||||
case 5:
|
||||
$recurr_type = Text::_('COM_JEM_YEARLY');
|
||||
$recurr_info = str_ireplace('[placeholder]',
|
||||
$this->item->recurr_bak->recurrence_number,
|
||||
Text::_('COM_JEM_OUTPUT_YEAR'));
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (!empty($recurr_type)) {
|
||||
?>
|
||||
<hr />
|
||||
<fieldset class="panelform">
|
||||
<p><strong><?php echo Text::_('COM_JEM_RECURRING_INFO_TITLE'); ?></strong></p>
|
||||
<ul class="adminformlist">
|
||||
<li class="has-success"><label><?php echo Text::_('COM_JEM_RECURRING_FIRST_EVENT_ID'); ?></label>
|
||||
<input type="text" value="<?php echo $recurrence_first_id; ?>" class="form-control readonly inputbox valid form-control-success" readonly="">
|
||||
</li>
|
||||
<li class="has-success"><label><?php echo Text::_('COM_JEM_RECURRENCE'); ?></label>
|
||||
<input type="text" value="<?php echo $recurr_type; ?>, <?php echo $recurr_info; ?>" class="form-control readonly inputbox valid form-control-success" readonly="">
|
||||
</li>
|
||||
<li><label><?php echo Text::_('COM_JEM_RECURRENCE_COUNTER'); ?></label>
|
||||
<input type="text" value="<?php echo $recurr_limit_date; ?>" class="form-control readonly inputbox valid form-control-success" readonly="">
|
||||
</li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- START OF PANEL META -->
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="meta-event-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#meta-event" aria-expanded="true" aria-controls="meta-event">
|
||||
<?php echo Text::_('COM_JEM_METADATA_INFORMATION'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
|
||||
<div id="meta-event" class="accordion-collapse collapse" aria-labelledby="meta-event-header" data-bs-parent="#accordionEventForm">
|
||||
<div class="accordion-body">
|
||||
<fieldset class="panelform">
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[title]')" value="<?php echo Text::_ ( 'COM_JEM_EVENT_TITLE' ); ?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[a_name]')" value="<?php echo Text::_ ( 'COM_JEM_VENUE' );?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[categories]')" value="<?php echo Text::_ ( 'COM_JEM_CATEGORIES' );?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[dates]')" value="<?php echo Text::_ ( 'COM_JEM_STARTDATE' );?>" />
|
||||
|
||||
<p>
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[times]')" value="<?php echo Text::_ ( 'COM_JEM_STARTTIME' );?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[enddates]')" value="<?php echo Text::_ ( 'COM_JEM_ENDDATE' );?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[endtimes]')" value="<?php echo Text::_ ( 'COM_JEM_ENDTIME' );?>" />
|
||||
</p>
|
||||
<br />
|
||||
|
||||
<br />
|
||||
<label for="meta_keywords"><?php echo Text::_ ('COM_JEM_META_KEYWORDS') . ':';?></label>
|
||||
<br />
|
||||
|
||||
<?php
|
||||
if (! empty ( $this->item->meta_keywords )) {
|
||||
$meta_keywords = $this->item->meta_keywords;
|
||||
} else {
|
||||
$meta_keywords = $this->jemsettings->meta_keywords;
|
||||
}
|
||||
?>
|
||||
<textarea class="inputbox form-control" name="meta_keywords" id="meta_keywords" rows="6" cols="40" maxlength="150" onfocus="get_inputbox('meta_keywords')" onblur="change_metatags()"><?php echo $meta_keywords; ?></textarea>
|
||||
|
||||
<label for="meta_description"><?php echo Text::_ ('COM_JEM_META_DESCRIPTION') . ':';?></label>
|
||||
<br />
|
||||
|
||||
<?php
|
||||
if (! empty ( $this->item->meta_description )) {
|
||||
$meta_description = $this->item->meta_description;
|
||||
} else {
|
||||
$meta_description = $this->jemsettings->meta_description;
|
||||
}
|
||||
?>
|
||||
<textarea class="inputbox form-control" name="meta_description" id="meta_description" rows="6" cols="40" maxlength="200" onfocus="get_inputbox('meta_description')" onblur="change_metatags()"><?php echo $meta_description;?></textarea>
|
||||
</fieldset>
|
||||
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
<?php foreach($this->form->getGroup('metadata') as $field): ?>
|
||||
<li>
|
||||
<?php if (!$field->hidden): ?>
|
||||
<?php echo $field->label; ?>
|
||||
<?php endif; ?>
|
||||
<?php echo $field->input; ?>
|
||||
</li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
|
||||
<script>
|
||||
<!--
|
||||
starter("<?php
|
||||
echo Text::_ ( 'COM_JEM_META_ERROR' );
|
||||
?>"); // window.onload is already in use, call the function manualy instead
|
||||
-->
|
||||
</script>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<input type="hidden" name="task" value="" />
|
||||
<input type="hidden" name="author_ip" value="<?php echo $this->item->author_ip; ?>" />
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
<!-- END RIGHT DIV -->
|
||||
</div>
|
||||
<div class="clr"></div>
|
||||
</form>
|
||||
<script>
|
||||
output_recurrencescript();
|
||||
</script>
|
||||
@ -0,0 +1,75 @@
|
||||
<?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\Session\Session;
|
||||
?>
|
||||
|
||||
<table class="adminform" id="el-attachments">
|
||||
<tbody>
|
||||
<?php foreach ($this->item->attachments as $file): ?>
|
||||
<tr>
|
||||
<td>
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_FILE');?></div>
|
||||
<input class="form-control readonly valid form-control-success w-75" type="text" readonly="readonly" value="<?php echo $file->file; ?>"></input>
|
||||
<input type="hidden" name="attached-id[]" value="<?php echo $file->id; ?>"/>
|
||||
</div>
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_NAME'); ?></div>
|
||||
<input type="text" name="attached-name[]" class="form-control valid form-control-success w-75" value="<?php echo $file->name; ?>" />
|
||||
</div>
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_DESCRIPTION'); ?></div>
|
||||
<input type="text" name="attached-desc[]" class="form-control valid form-control-success w-75" value="<?php echo $file->description; ?>" />
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_ACCESS'); ?></div>
|
||||
<?php echo HTMLHelper::_('select.genericlist', $this->access, 'attached-access[]', array('class'=>'inputbox form-control','size'=>'7'), 'value', 'text', $file->access); ?>
|
||||
</div>
|
||||
</td>
|
||||
<td class="center">
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_REMOVE'); ?></div>
|
||||
<?php echo HTMLHelper::_('image','com_jem/publish_r.png', Text::_('COM_JEM_REMOVE_ATTACHEMENT'), array('id' => 'attach-remove'.$file->id.':'.Session::getFormToken(), 'class' => 'attach-remove', 'title'=>Text::_('COM_JEM_REMOVE_ATTACHEMENT')), true); ?>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
<tr>
|
||||
<td width="100%">
|
||||
<div style="display: inline-block; text-wrap: none;">
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_FILE'); ?></div>
|
||||
<input type="file" name="attach[]" class="attach-field"></input>
|
||||
<input type="reset" value="<?php echo Text::_('JSEARCH_FILTER_CLEAR') ?>" class="btn btn-primary">
|
||||
</div>
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_NAME'); ?></div>
|
||||
<input type="text" name="attach-name[]" value="" class="form-control valid form-control-success w-75" />
|
||||
</div>
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_DESCRIPTION'); ?></div>
|
||||
<input type="text" name="attach-desc[]" value="" class="form-control valid form-control-success w-75" />
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<div>
|
||||
<div class="title"><?php echo Text::_('COM_JEM_ATTACHMENT_ACCESS'); ?></div>
|
||||
<?php echo HTMLHelper::_('select.genericlist', $this->access, 'attach-access[]', array('class'=>'inputbox form-control','size'=>'7'), 'value', 'text', 1); ?>
|
||||
</div>
|
||||
</td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
@ -0,0 +1,66 @@
|
||||
<?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;
|
||||
|
||||
// Create shortcut to parameters.
|
||||
$params = $this->state->get('params');
|
||||
|
||||
$params = $params->toArray();
|
||||
|
||||
// This checks if the config options have ever been saved. If they haven't they will fall back to the original settings.
|
||||
$editoroptions = isset($params['show_publishing_options']);
|
||||
|
||||
if (!$editoroptions):
|
||||
$params['show_publishing_options'] = '1';
|
||||
$params['show_article_options'] = '1';
|
||||
$params['show_urls_images_backend'] = '0';
|
||||
$params['show_urls_images_frontend'] = '0';
|
||||
endif;
|
||||
|
||||
$group = 'attribs';
|
||||
|
||||
?>
|
||||
|
||||
<div class="width-100">
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_EVENT'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('basic') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('evevents',$group) as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_VENUE'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><?php echo $this->form->getLabel('event_show_locdescription',$group); ?> <?php echo $this->form->getInput('event_show_locdescription',$group); ?></li>
|
||||
<li><?php echo $this->form->getLabel('event_show_detailsadress',$group); ?> <?php echo $this->form->getInput('event_show_detailsadress',$group); ?></li>
|
||||
<li><?php echo $this->form->getLabel('event_show_detlinkvenue',$group); ?> <?php echo $this->form->getInput('event_show_detlinkvenue',$group); ?></li>
|
||||
<li><?php echo $this->form->getLabel('event_show_mapserv',$group); ?> <?php echo $this->form->getInput('event_show_mapserv',$group); ?></li>
|
||||
<li id="eventmap1" style="display:none"><?php echo $this->form->getLabel('event_tld',$group); ?> <?php echo $this->form->getInput('event_tld',$group); ?></li>
|
||||
<li id="eventmap2" style="display:none"><?php echo $this->form->getLabel('event_lg',$group); ?> <?php echo $this->form->getInput('event_lg',$group); ?></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
<div class="width-100">
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_REGISTRATION'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><?php echo $this->form->getLabel('event_comunsolution',$group); ?> <?php echo $this->form->getInput('event_comunsolution',$group); ?></li>
|
||||
<li id="comm1" style="display:none"><?php echo $this->form->getLabel('event_comunoption',$group); ?> <?php echo $this->form->getInput('event_comunoption',$group); ?></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
122
administrator/components/com_jem/views/event/view.html.php
Normal file
122
administrator/components/com_jem/views/event/view.html.php
Normal file
@ -0,0 +1,122 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
|
||||
/**
|
||||
* Event View
|
||||
*/
|
||||
class JemViewEvent extends JemAdminView
|
||||
{
|
||||
protected $form;
|
||||
protected $item;
|
||||
protected $state;
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
// Initialise variables.
|
||||
$this->form = $this->get('Form');
|
||||
$this->item = $this->get('Item');
|
||||
$this->state = $this->get('State');
|
||||
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
Factory::getApplication()->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
//initialise variables
|
||||
$jemsettings = JemHelper::config();
|
||||
$app = Factory::getApplication();
|
||||
$this->document = $app->getDocument();
|
||||
$user = JemFactory::getUser();
|
||||
$this->settings = JemAdmin::config();
|
||||
$task = $app->input->get('task', '');
|
||||
$this->task = $task;
|
||||
$uri = Uri::getInstance();
|
||||
$url = $uri->root();
|
||||
|
||||
$categories = JemCategories::getCategoriesTree(1);
|
||||
$selectedcats = $this->get('Catsselected');
|
||||
|
||||
$Lists = array();
|
||||
$Lists['category'] = JemCategories::buildcatselect($categories, 'cid[]', $selectedcats, 0, 'multiple="multiple" size="8"');
|
||||
|
||||
// Load css
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// Load scripts
|
||||
$wa->useScript('jquery');
|
||||
$wa->registerScript('jem.attachments', 'com_jem/attachments.js')->useScript('jem.attachments');
|
||||
$wa->registerScript('jem.recurrence', 'com_jem/recurrence.js')->useScript('jem.recurrence');
|
||||
$wa->registerScript('jem.unlimited', 'com_jem/unlimited.js')->useScript('jem.unlimited');
|
||||
$wa->registerScript('jem.seo', 'com_jem/seo.js')->useScript('jem.seo');
|
||||
|
||||
|
||||
// JQuery noConflict
|
||||
//$document->addCustomTag('<script>jQuery.noConflict();</script>');
|
||||
//$document->addScript('https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js');
|
||||
//$document->addScript('https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.3/jquery-ui.min.js');
|
||||
|
||||
$access2 = JemHelper::getAccesslevelOptions();
|
||||
$this->access = $access2;
|
||||
$this->jemsettings = $jemsettings;
|
||||
$this->Lists = $Lists;
|
||||
|
||||
$this->addToolbar();
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
Factory::getApplication()->input->set('hidemainmenu', true);
|
||||
|
||||
$user = JemFactory::getUser();
|
||||
$isNew = ($this->item->id == 0);
|
||||
$checkedOut = !($this->item->checked_out == 0 || $this->item->checked_out == $user->get('id'));
|
||||
$canDo = JemHelperBackend::getActions();
|
||||
|
||||
ToolBarHelper::title($isNew ? Text::_('COM_JEM_ADD_EVENT') : Text::_('COM_JEM_EDIT_EVENT'), 'eventedit');
|
||||
|
||||
// If not checked out, can save the item.
|
||||
if (!$checkedOut && ($canDo->get('core.edit')||$canDo->get('core.create'))) {
|
||||
ToolBarHelper::apply('event.apply');
|
||||
ToolBarHelper::save('event.save');
|
||||
}
|
||||
if (!$checkedOut && $canDo->get('core.create')) {
|
||||
ToolBarHelper::save2new('event.save2new');
|
||||
}
|
||||
// If an existing item, can save to a copy.
|
||||
if (!$isNew && $canDo->get('core.create')) {
|
||||
ToolBarHelper::save2copy('event.save2copy');
|
||||
}
|
||||
|
||||
if (empty($this->item->id)) {
|
||||
ToolBarHelper::cancel('event.cancel');
|
||||
} else {
|
||||
ToolBarHelper::cancel('event.cancel', 'JTOOLBAR_CLOSE');
|
||||
}
|
||||
|
||||
ToolBarHelper::divider();
|
||||
ToolbarHelper::inlinehelp();
|
||||
ToolBarHelper::help('editevents', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/events/add-event');
|
||||
}
|
||||
}
|
||||
?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,108 @@
|
||||
<?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;
|
||||
?>
|
||||
|
||||
<form action="index.php?option=com_jem&view=eventelement&tmpl=component" method="post" name="adminForm" id="adminForm">
|
||||
|
||||
<table class="adminform">
|
||||
<tr>
|
||||
<td width="100%">
|
||||
<?php echo Text::_('COM_JEM_SEARCH').' '.$this->lists['filter']; ?>
|
||||
<input type="text" name="filter_search" id="filter_search" value="<?php echo $this->lists['search']; ?>" class="text_area" onChange="document.adminForm.submit();" />
|
||||
<button class="buttonfilter" type="submit"><?php echo Text::_('JSEARCH_FILTER_SUBMIT'); ?></button>
|
||||
<button class="buttonfilter" type="button" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
</td>
|
||||
<td nowrap="nowrap">
|
||||
<select name="filter_state" class="inputbox" onchange="this.form.submit()">
|
||||
<option value=""><?php echo Text::_('JOPTION_SELECT_PUBLISHED');?></option>
|
||||
<?php echo HTMLHelper::_('select.options', HTMLHelper::_('jgrid.publishedOptions',array('all' => 0, 'trash' => 0)), 'value', 'text', $this->filter_state, true);?>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<table class="table table-striped" id="articleList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="center" width="5"><?php echo Text::_('COM_JEM_NUM'); ?></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_EVENT_TITLE', 'a.title', $this->lists['order_Dir'], $this->lists['order'], 'eventelement' ); ?></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_DATE', 'a.dates', $this->lists['order_Dir'], $this->lists['order'], 'eventelement' ); ?></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_START', 'a.times', $this->lists['order_Dir'], $this->lists['order'], 'eventelement' ); ?></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_VENUE', 'loc.venue', $this->lists['order_Dir'], $this->lists['order'], 'eventelement' ); ?></th>
|
||||
<th class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_CITY', 'loc.city', $this->lists['order_Dir'], $this->lists['order'], 'eventelement' ); ?></th>
|
||||
<th class="title"><?php echo Text::_('COM_JEM_CATEGORY'); ?></th>
|
||||
<th class="center" width="1%" nowrap="nowrap"><?php echo Text::_('JSTATUS'); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tfoot>
|
||||
<tr>
|
||||
<td colspan="8">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks() : $this->pagination->getListFooter()); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</tfoot>
|
||||
|
||||
<tbody>
|
||||
<?php foreach ($this->rows as $i => $row) : ?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td class="center"><?php echo $this->pagination->getRowOffset( $i ); ?></td>
|
||||
<td>
|
||||
<span <?php echo JEMOutput::tooltip(Text::_('COM_JEM_SELECT'), $row->title, 'editlinktip'); ?>>
|
||||
<a style="cursor:pointer" onclick="window.parent.elSelectEvent('<?php echo $row->id; ?>', '<?php echo str_replace( array("'", "\""), array("\\'", ""), $row->title ); ?>');">
|
||||
<?php echo $this->escape($row->title); ?>
|
||||
</a></span>
|
||||
</td>
|
||||
<td>
|
||||
<?php
|
||||
//Format date
|
||||
echo JemOutput::formatLongDateTime($row->dates, null, $row->enddates, null);
|
||||
?>
|
||||
</td>
|
||||
<td>
|
||||
<?php
|
||||
//Prepare time
|
||||
if (!$row->times) {
|
||||
$displaytime = '-';
|
||||
} else {
|
||||
$time = date( $this->jemsettings->formattime, strtotime( $row->times ));
|
||||
$displaytime = $time.' '.$this->jemsettings->timename;
|
||||
}
|
||||
echo $displaytime;
|
||||
?>
|
||||
</td>
|
||||
<td><?php echo $row->venue ? $this->escape($row->venue) : '-'; ?></td>
|
||||
<td><?php echo $row->city ? $this->escape($row->city) : '-'; ?></td>
|
||||
<td>
|
||||
<?php
|
||||
# we're referring to the helper due to the multi-cat feature
|
||||
echo implode(", ",JemOutput::getCategoryList($row->categories, false));
|
||||
?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo HTMLHelper::_('jgrid.published', $row->published, $i,'',false); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
|
||||
</table>
|
||||
|
||||
<p class="copyright">
|
||||
<?php echo JemAdmin::footer( ); ?>
|
||||
</p>
|
||||
|
||||
<input type="hidden" name="task" value="" />
|
||||
<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']; ?>" />
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,82 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\MVC\View\HtmlView;
|
||||
|
||||
/**
|
||||
* Eventelement-View
|
||||
*/
|
||||
class JemViewEventelement extends Htmlview {
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$app = Factory::getApplication();
|
||||
|
||||
//initialise variables
|
||||
$user = JemFactory::getUser();
|
||||
$db = Factory::getContainer()->get('DatabaseDriver');
|
||||
$jemsettings = JEMAdmin::config();
|
||||
$document = $app->getDocument();
|
||||
$itemid = $app->input->getInt('id', 0) . ':' . $app->input->getInt('Itemid', 0);
|
||||
|
||||
//get var
|
||||
$filter_order = $app->getUserStateFromRequest('com_jem.eventelement.filter_order', 'filter_order', 'a.dates', 'cmd');
|
||||
$filter_order_Dir = $app->getUserStateFromRequest('com_jem.eventelement.filter_order_Dir', 'filter_order_Dir', '', 'word');
|
||||
$filter_type = $app->getUserStateFromRequest('com_jem.eventelement.'.$itemid.'.filter_type', 'filter_type', 0, 'int');
|
||||
$filter_state = $app->getUserStateFromRequest('com_jem.eventelement.'.$itemid.'.filter_state', 'filter_state', '', 'string');
|
||||
$filter_search = $app->getUserStateFromRequest('com_jem.eventelement.'.$itemid.'.filter_search', 'filter_search', '', 'string');
|
||||
$filter_search = $db->escape(trim(\Joomla\String\StringHelper::strtolower($filter_search)));
|
||||
|
||||
//prepare the document
|
||||
$document->setTitle(Text::_('COM_JEM_SELECTEVENT'));
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
//Get data from the model
|
||||
$rows = $this->get('Data');
|
||||
$pagination = $this->get('Pagination');
|
||||
|
||||
//publish unpublished filter
|
||||
//$lists['state'] = HTMLHelper::_('grid.state', $filter_state);
|
||||
|
||||
// table ordering
|
||||
$lists['order_Dir'] = $filter_order_Dir;
|
||||
$lists['order'] = $filter_order;
|
||||
|
||||
//Create the filter selectlist
|
||||
$filters = array();
|
||||
$filters[] = HTMLHelper::_('select.option', '1', Text::_('COM_JEM_EVENT_TITLE'));
|
||||
$filters[] = HTMLHelper::_('select.option', '2', Text::_('COM_JEM_VENUE'));
|
||||
$filters[] = HTMLHelper::_('select.option', '3', Text::_('COM_JEM_CITY'));
|
||||
//$filters[] = HTMLHelper::_('select.option', '4', Text::_('COM_JEM_CATEGORY'));
|
||||
$lists['filter'] = HTMLHelper::_('select.genericlist', $filters, 'filter_type', array('size'=>'1','class'=>'inputbox'), 'value', 'text', $filter_type);
|
||||
|
||||
// search filter
|
||||
$lists['search']= $filter_search;
|
||||
|
||||
//assign data to template
|
||||
$this->lists = $lists;
|
||||
$this->filter_state = $filter_state;
|
||||
$this->rows = $rows;
|
||||
$this->pagination = $pagination;
|
||||
$this->jemsettings = $jemsettings;
|
||||
$this->user = $user;
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
}
|
||||
?>
|
||||
1
administrator/components/com_jem/views/events/index.html
Normal file
1
administrator/components/com_jem/views/events/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
282
administrator/components/com_jem/views/events/tmpl/default.php
Normal file
282
administrator/components/com_jem/views/events/tmpl/default.php
Normal file
@ -0,0 +1,282 @@
|
||||
<?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\Button\FeaturedButton;
|
||||
use Joomla\CMS\Router\Route;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Object\CMSObject;
|
||||
|
||||
HTMLHelper::addIncludePath(JPATH_COMPONENT.'/helpers/html');
|
||||
$user = JemFactory::getUser();
|
||||
$userId = $user->get('id');
|
||||
$listOrder = $this->escape($this->state->get('list.ordering'));
|
||||
$listDirn = $this->escape($this->state->get('list.direction'));
|
||||
$canOrder = $user->authorise('core.edit.state', 'com_jem.category');
|
||||
$saveOrder = $listOrder=='a.ordering';
|
||||
|
||||
$params = (isset($this->state->params)) ? $this->state->params : new CMSObject();
|
||||
$settings = $this->settings;
|
||||
$wa = $this->document->getWebAssetManager();
|
||||
$wa->useScript('table.columns');
|
||||
?>
|
||||
<script>
|
||||
$(document).ready(function() {
|
||||
var h = <?php echo $settings->get('highlight','0'); ?>;
|
||||
|
||||
switch(h)
|
||||
{
|
||||
case 0:
|
||||
break;
|
||||
case 1:
|
||||
highlightevents();
|
||||
break;
|
||||
}
|
||||
});
|
||||
</script>
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=events'); ?>" method="post" name="adminForm" id="adminForm">
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<fieldset id="filter-bar" class=" mb-3">
|
||||
<div class="row">
|
||||
<div class="col-md-1">
|
||||
<div class="row">
|
||||
<div class="wauto-minwmax">
|
||||
<div class="input-group">
|
||||
<?php echo $this->lists['filter']; ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-10">
|
||||
<div class="row mb-12">
|
||||
<div class="col-md-3">
|
||||
<div class="input-group">
|
||||
<input type="text" name="filter_search" id="filter_search" class="form-control" aria-describedby="filter_search-desc" placeholder="<?php echo Text::_('COM_JEM_SEARCH');?>" value="<?php echo $this->escape($this->state->get('filter_search')); ?>" inputmode="search" onChange="document.adminForm.submit();" >
|
||||
|
||||
<button type="submit" class="filter-search-bar__button btn btn-primary" aria-label="Search">
|
||||
<span class="filter-search-bar__button-icon icon-search" aria-hidden="true"></span>
|
||||
</button>
|
||||
<button type="button" class="btn btn-primary" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
<?php echo HTMLHelper::_('calendar', $this->state->get('filter_begin'), 'filter_begin', 'filter_begin', '%Y-%m-%d' , array('size'=>10, 'onchange'=>"this.form.fireEvent('submit');this.form.submit()",'placeholder'=>Text::_('COM_JEM_EVENTS_FILTER_STARTDATE')));?>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
|
||||
<?php echo HTMLHelper::_('calendar', $this->state->get('filter_end'), 'filter_end', 'filter_end', '%Y-%m-%d' , array('size'=>10, 'onchange'=>"this.form.fireEvent('submit');this.form.submit()",'placeholder'=>Text::_('COM_JEM_EVENTS_FILTER_ENDDATE') ));?>
|
||||
</div>
|
||||
<div class="col-md-1 wauto-minwmax">
|
||||
<select name="filter_state" class="inputbox form-select wauto-minwmax" onchange="this.form.submit()">
|
||||
<option value=""><?php echo Text::_('JOPTION_SELECT_PUBLISHED');?></option>
|
||||
<?php echo HTMLHelper::_('select.options', HTMLHelper::_('jgrid.publishedOptions'), 'value', 'text', $this->state->get('filter_state'), true);?>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-md-2 wauto-minwmax">
|
||||
<select name="filter_access" class="inputbox form-select wauto-minwmax" onchange="this.form.submit()">
|
||||
<option value=""><?php echo Text::_('JOPTION_SELECT_ACCESS');?></option>
|
||||
<?php echo HTMLHelper::_('select.options', HTMLHelper::_('access.assetgroups'), 'value', 'text', $this->state->get('filter.access'));?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="row">
|
||||
<div class="wauto-minwmax">
|
||||
<div class=" float-end">
|
||||
<?php echo $this->pagination->getLimitBox(); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
<div class="clr"> </div>
|
||||
<div class="table">
|
||||
<table class="table table-striped itemList" id="eventList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="1%" class="center"><input type="checkbox" name="checkall-toggle" value="" title="<?php echo Text::_('JGLOBAL_CHECK_ALL'); ?>" onclick="Joomla.checkAll(this)" /></th>
|
||||
<th class="nowrap"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_DATE', 'a.dates', $listDirn, $listOrder ); ?></th>
|
||||
<th><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_STARTTIME_SHORT', 'a.times', $listDirn, $listOrder ); ?></th>
|
||||
<th class="nowrap"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_EVENT_TITLE', 'a.title', $listDirn, $listOrder ); ?></th>
|
||||
<th><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_VENUE', 'loc.venue', $listDirn, $listOrder ); ?></th>
|
||||
<th><?php echo Text::_('COM_JEM_CATEGORIES'); ?></th>
|
||||
<th width="1%"><?php echo HTMLHelper::_('grid.sort', 'JFEATURED', 'a.featured', $listDirn, $listOrder, NULL, 'desc'); ?></th>
|
||||
<th width="1%" class="center nowrap"><?php echo Text::_('JSTATUS'); ?></th>
|
||||
<th class="nowrap"><?php echo Text::_('COM_JEM_AUTHOR'); ?></th>
|
||||
<th class="center"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_HITS', 'a.hits', $listDirn, $listOrder ); ?></th>
|
||||
<th width="1%" class="center nowrap"><?php echo Text::_('COM_JEM_REGISTERED_USERS_SHORT'); ?></th>
|
||||
<th width="9%" class="center"><?php echo HTMLHelper::_('grid.sort', 'JGRID_HEADING_ACCESS', 'a.access', $listDirn, $listOrder); ?></th>
|
||||
<th width="1%" class="center nowrap"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_ID', 'a.id', $listDirn, $listOrder ); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody id="search_in_here">
|
||||
<?php
|
||||
foreach ($this->items as $i => $row) :
|
||||
//Prepare date
|
||||
$displaydate = JemOutput::formatShortDateTime($row->dates, null, $row->enddates, null, $this->jemsettings->showtime);
|
||||
// Insert a break between date and enddate if possible
|
||||
$displaydate = str_replace(" - ", " -<br />", $displaydate);
|
||||
|
||||
//Prepare time
|
||||
if (!$row->times) {
|
||||
$displaytime = '-';
|
||||
} else {
|
||||
$displaytime = JemOutput::formattime($row->times);
|
||||
}
|
||||
|
||||
$ordering = ($listOrder == 'ordering');
|
||||
$canCreate = $user->authorise('core.create');
|
||||
$canEdit = $user->authorise('core.edit');
|
||||
$canCheckin = $user->authorise('core.manage', 'com_checkin') || $row->checked_out == $userId || $row->checked_out == 0;
|
||||
$canChange = $user->authorise('core.edit.state') && $canCheckin;
|
||||
|
||||
$venuelink = 'index.php?option=com_jem&task=venue.edit&id='.$row->locid;
|
||||
$published = HTMLHelper::_('jgrid.published', $row->published, $i, 'events.');
|
||||
?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td class="center"><?php echo HTMLHelper::_('grid.id', $i, $row->id); ?></td>
|
||||
<td class="startdate">
|
||||
<?php if ($row->checked_out) : ?>
|
||||
<?php echo HTMLHelper::_('jgrid.checkedout', $i, $row->editor, $row->checked_out_time, 'events.', $canCheckin); ?>
|
||||
<?php endif; ?>
|
||||
<?php if ($canEdit) : ?>
|
||||
<a href="<?php echo Route::_('index.php?option=com_jem&task=event.edit&id='.(int) $row->id); ?>">
|
||||
<?php echo $displaydate; ?>
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<?php echo $displaydate; ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td class="starttime"><?php echo $displaytime; ?></td>
|
||||
<td class="eventtitle">
|
||||
<?php if ($canEdit) : ?>
|
||||
<a href="<?php echo Route::_('index.php?option=com_jem&task=event.edit&id='.(int) $row->id); ?>">
|
||||
<?php echo $this->escape($row->title) . JemOutput::recurrenceicon($row); ?>
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<?php echo $this->escape($row->title) . JemOutput::recurrenceicon($row); ?>
|
||||
<?php endif; ?>
|
||||
<br />
|
||||
<?php if (\Joomla\String\StringHelper::strlen($row->alias) > 25) : ?>
|
||||
<?php echo \Joomla\String\StringHelper::substr( $this->escape($row->alias), 0 , 25).'...'; ?>
|
||||
<?php else : ?>
|
||||
<?php echo $this->escape($row->alias); ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td class="venue">
|
||||
<?php if ($row->venue) : ?>
|
||||
<?php if ( $row->vchecked_out && ( $row->vchecked_out != $this->user->get('id') ) ) : ?>
|
||||
<?php echo $this->escape($row->venue); ?>
|
||||
<?php else : ?>
|
||||
<span <?php echo JEMOutput::tooltip(Text::_('COM_JEM_EDIT_VENUE'), $row->venue, 'editlinktip'); ?>>
|
||||
<a href="<?php echo $venuelink; ?>">
|
||||
<?php echo $this->escape($row->venue); ?>
|
||||
</a>
|
||||
</span>
|
||||
<?php endif; ?>
|
||||
<?php else : ?>
|
||||
<?php echo '-'; ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td class="category">
|
||||
<?php echo implode(", ", JemOutput::getCategoryList($row->categories, $this->jemsettings->catlinklist,true)); ?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php //echo HTMLHelper::_('jemhtml.featured', $i, $row->featured, $canChange);
|
||||
$options = [
|
||||
'task_prefix' => 'events.',
|
||||
'disabled' => !$canChange,
|
||||
'id' => 'featured-' . $row->id
|
||||
];
|
||||
echo (new FeaturedButton())
|
||||
->render((int) $row->featured, $i, $options);
|
||||
?>
|
||||
</td>
|
||||
<td class="center"><?php echo $published; ?></td>
|
||||
<td>
|
||||
<?php
|
||||
$created = HTMLHelper::_('date',$row->created,Text::_('DATE_FORMAT_LC5'));
|
||||
$image = HTMLHelper::_('image','com_jem/icon-16-info.png',NULL,NULL,true );
|
||||
$overlib = Text::_('COM_JEM_CREATED_AT').': '.$created.'<br />';
|
||||
$overlib .= Text::_('COM_JEM_AUTHOR').'</strong>: ' . $row->author.'<br />';
|
||||
$overlib .= Text::_('COM_JEM_EMAIL').'</strong>: ' . $row->email.'<br />';
|
||||
if ($row->author_ip != '') {
|
||||
$overlib .= Text::_('COM_JEM_WITH_IP').': '.$row->author_ip.'<br />';
|
||||
}
|
||||
if (!empty($row->modified)) {
|
||||
$overlib .= '<br />'.Text::_('COM_JEM_EDITED_AT').': '. HTMLHelper::_('date',$row->modified,Text::_('DATE_FORMAT_LC5') ) .'<br />'. Text::_('COM_JEM_GLOBAL_MODIFIEDBY').': '.$row->modified_by;
|
||||
}
|
||||
?>
|
||||
<span <?php echo JEMOutput::tooltip(Text::_('COM_JEM_EVENTS_STATS'), $overlib, 'editlinktip'); ?>
|
||||
|
||||
<a href="<?php echo 'index.php?option=com_users&task=edit&hidemainmenu=1&cid[]='.$row->created_by; ?>"><?php echo $row->author; ?></a></span>
|
||||
|
||||
|
||||
</td>
|
||||
<td class="center"><?php echo $row->hits; ?></td>
|
||||
|
||||
<td class="center">
|
||||
<?php
|
||||
if ($this->jemsettings->showfroregistra || ($row->registra & 1)) {
|
||||
$linkreg = 'index.php?option=com_jem&view=attendees&eventid='.$row->id;
|
||||
$count = $row->regCount+$row->reserved;
|
||||
if ($row->maxplaces)
|
||||
{
|
||||
$count .= '/'.$row->maxplaces;
|
||||
if ($row->waitinglist && $row->waiting) {
|
||||
$count .= '+'.$row->waiting;
|
||||
}
|
||||
}
|
||||
if (!empty($row->unregCount)) {
|
||||
$count .= '-'.(int)$row->unregCount;
|
||||
}
|
||||
if (!empty($row->invited)) {
|
||||
$count .= ','.(int)$row->invited .'?';
|
||||
}
|
||||
?>
|
||||
<a href="<?php echo $linkreg; ?>" title="<?php echo Text::_('COM_JEM_EVENTS_MANAGEATTENDEES'); ?>">
|
||||
<?php echo $count; ?>
|
||||
</a>
|
||||
<?php } else { ?>
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/publish_r.png', NULL, NULL, true); ?>
|
||||
<?php } ?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo $this->escape($row->access_level); ?>
|
||||
</td>
|
||||
<td class="center">
|
||||
<?php echo (int) $row->id; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div class="ms-auto mb-4 me-0">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks(null) : $this->pagination->getListFooter()); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php //if (isset($this->sidebar)) : ?>
|
||||
<?php //endif; ?>
|
||||
|
||||
<div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<input type="hidden" name="boxchecked" value="0" />
|
||||
<input type="hidden" name="filter_order" value="<?php echo $listOrder; ?>" />
|
||||
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn; ?>" />
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</div>
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
151
administrator/components/com_jem/views/events/view.html.php
Normal file
151
administrator/components/com_jem/views/events/view.html.php
Normal file
@ -0,0 +1,151 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
|
||||
|
||||
/**
|
||||
* Events-View
|
||||
*/
|
||||
|
||||
class JemViewEvents extends JemAdminView
|
||||
{
|
||||
protected $items;
|
||||
protected $pagination;
|
||||
protected $state;
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$user = JemFactory::getUser();
|
||||
$settings = JemHelper::globalattribs();
|
||||
$jemsettings = JemAdmin::config();
|
||||
$uri = Uri::getInstance();
|
||||
$url = $uri->root();
|
||||
|
||||
// Initialise variables.
|
||||
$this->items = $this->get('Items');
|
||||
$this->pagination = $this->get('Pagination');
|
||||
$this->state = $this->get('State');
|
||||
|
||||
// Retrieving params
|
||||
$params = $this->state->get('params');
|
||||
|
||||
// highlighter
|
||||
$highlighter = $settings->get('highlight','0');
|
||||
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
Factory::getApplication()->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// Load Scripts
|
||||
$this->document->addScript('https://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js');
|
||||
|
||||
if ($highlighter) {
|
||||
$this->document->addScript($url.'media/com_jem/js/highlighter.js');
|
||||
$style = '
|
||||
.red, .red a {
|
||||
color:red;}
|
||||
';
|
||||
$this->document->addStyleDeclaration($style);
|
||||
}
|
||||
|
||||
// add filter selection for the search
|
||||
$filters = array();
|
||||
$filters[] = HTMLHelper::_('select.option', '1', Text::_('COM_JEM_EVENT_TITLE'));
|
||||
$filters[] = HTMLHelper::_('select.option', '2', Text::_('COM_JEM_VENUE'));
|
||||
$filters[] = HTMLHelper::_('select.option', '3', Text::_('COM_JEM_CITY'));
|
||||
$filters[] = HTMLHelper::_('select.option', '4', Text::_('COM_JEM_CATEGORY'));
|
||||
$filters[] = HTMLHelper::_('select.option', '5', Text::_('COM_JEM_STATE'));
|
||||
$filters[] = HTMLHelper::_('select.option', '6', Text::_('COM_JEM_COUNTRY'));
|
||||
$filters[] = HTMLHelper::_('select.option', '7', Text::_('JALL'));
|
||||
$lists['filter'] = HTMLHelper::_('select.genericlist', $filters, 'filter_type', array('size'=>'1','class'=>'inputbox form-select m-0','onChange'=>"this.form.submit()"), 'value', 'text', $this->state->get('filter_type'));
|
||||
|
||||
//assign data to template
|
||||
$this->lists = $lists;
|
||||
$this->user = $user;
|
||||
$this->jemsettings = $jemsettings;
|
||||
$this->settings = $settings;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolBarHelper::title(Text::_('COM_JEM_EVENTS'), 'events');
|
||||
|
||||
/* retrieving the allowed actions for the user */
|
||||
$canDo = JemHelperBackend::getActions(0);
|
||||
|
||||
/* create */
|
||||
if (($canDo->get('core.create'))) {
|
||||
ToolBarHelper::addNew('event.add');
|
||||
}
|
||||
|
||||
/* edit */
|
||||
if (($canDo->get('core.edit'))) {
|
||||
ToolBarHelper::editList('event.edit');
|
||||
ToolBarHelper::divider();
|
||||
}
|
||||
|
||||
/* state */
|
||||
if ($canDo->get('core.edit.state')) {
|
||||
if ($this->state->get('filter_state') != 2) {
|
||||
ToolBarHelper::publishList('events.publish', 'JTOOLBAR_PUBLISH', true);
|
||||
ToolBarHelper::unpublishList('events.unpublish', 'JTOOLBAR_UNPUBLISH', true);
|
||||
ToolBarHelper::custom('events.featured', 'featured.png', 'featured_f2.png', 'JFEATURED', true);
|
||||
}
|
||||
|
||||
if ($this->state->get('filter_state') != -1) {
|
||||
ToolBarHelper::divider();
|
||||
if ($this->state->get('filter_state') != 2) {
|
||||
ToolBarHelper::archiveList('events.archive');
|
||||
} elseif ($this->state->get('filter_state') == 2) {
|
||||
ToolBarHelper::unarchiveList('events.publish');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ($canDo->get('core.edit.state')) {
|
||||
ToolBarHelper::checkin('events.checkin');
|
||||
}
|
||||
|
||||
if ($this->state->get('filter_state') == -2 && $canDo->get('core.delete')) {
|
||||
ToolBarHelper::deleteList('COM_JEM_CONFIRM_DELETE', 'events.delete', 'JTOOLBAR_EMPTY_TRASH');
|
||||
} elseif ($canDo->get('core.edit.state')) {
|
||||
ToolBarHelper::trash('events.trash');
|
||||
}
|
||||
|
||||
ToolBarHelper::divider();
|
||||
ToolBarHelper::help('listevents', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/events');
|
||||
}
|
||||
}
|
||||
?>
|
||||
1
administrator/components/com_jem/views/export/index.html
Normal file
1
administrator/components/com_jem/views/export/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
117
administrator/components/com_jem/views/export/tmpl/default.php
Normal file
117
administrator/components/com_jem/views/export/tmpl/default.php
Normal file
@ -0,0 +1,117 @@
|
||||
<?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;
|
||||
|
||||
// JEMHelper::headerDeclarations();
|
||||
?>
|
||||
<script>
|
||||
function selectAll()
|
||||
{
|
||||
selectBox = document.getElementById("cid");
|
||||
|
||||
for (var i = 0; i < selectBox.options.length; i++){
|
||||
selectBox.options[i].selected = true;
|
||||
}
|
||||
}
|
||||
|
||||
function unselectAll()
|
||||
{
|
||||
selectBox = document.getElementById("cid");
|
||||
|
||||
for (var i = 0; i < selectBox.options.length; i++){
|
||||
selectBox.options[i].selected = false;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<div id="jem" class="jem_jem">
|
||||
<form action="index.php" method="post" name="adminForm" enctype="multipart/form-data" id="adminForm">
|
||||
<?php if (isset($this->sidebar)) : ?>
|
||||
<!-- <div id="j-sidebar-container" class="span2">
|
||||
<?php //echo $this->sidebar; ?>
|
||||
</div> -->
|
||||
<?php endif; ?>
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<div class="row">
|
||||
<div class="col-md-9">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_EXPORT_EVENTS_LEGEND');?></legend>
|
||||
<div class="width-50 fltlft" style="padding: 0 1vw;">
|
||||
<ul class="adminformlist">
|
||||
<li>
|
||||
<label class="top" <?php echo JEMOutput::tooltip(Text::_('COM_JEM_EXPORT_ADD_CATEGORYCOLUMN'), Text::_('COM_JEM_EXPORT_ADD_CATEGORYCOLUMN'), 'editlinktip'); ?>>
|
||||
<?php echo Text::_('COM_JEM_EXPORT_ADD_CATEGORYCOLUMN'); ?></label>
|
||||
<?php
|
||||
$categorycolumn = array();
|
||||
$categorycolumn[] = HTMLHelper::_('select.option', '0', Text::_('JNO'));
|
||||
$categorycolumn[] = HTMLHelper::_('select.option', '1', Text::_('JYES'));
|
||||
$categorycolumn = HTMLHelper::_('select.genericlist', $categorycolumn, 'categorycolumn', array('size'=>'1','class'=>'inputbox form-select'), 'value', 'text', '1');
|
||||
echo $categorycolumn;?>
|
||||
</li>
|
||||
<li>
|
||||
<label for="dates"><?php echo Text::_('COM_JEM_EXPORT_FROM_DATE').':'; ?></label>
|
||||
<?php echo HTMLHelper::_('calendar', date('Y-m-d',strtotime("-12 months")), 'dates', 'dates', '%Y-%m-%d', array('class' => 'inputbox validate-date', 'showTime' => false)); ?>
|
||||
</li>
|
||||
<li>
|
||||
<label for="enddates"><?php echo Text::_('COM_JEM_EXPORT_TO_DATE').':'; ?></label>
|
||||
<?php echo HTMLHelper::_('calendar', date('Y-m-d',strtotime("+12 months")), 'enddates', 'enddates', '%Y-%m-%d', array('class' => 'inputbox validate-date', 'showTime' => false)); ?>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="width-50 fltrt" style="padding: 0 1vw;">
|
||||
<div>
|
||||
<label for="cid"><?php echo Text::_('COM_JEM_CATEGORY').':'; ?></label>
|
||||
<?php echo $this->categories; ?>
|
||||
<div style="clear: both"></div>
|
||||
<input class="btn btn-primary selectcat" type="button" name="selectall" value="<?php echo Text::_('COM_JEM_EXPORT_SELECT_ALL_CATEGORIES'); ?>" onclick="selectAll();">
|
||||
<input class="btn btn-primary selectcat" type="button" name="unselectall" value="<?php echo Text::_('COM_JEM_EXPORT_UNSELECT_ALL_CATEGORIES'); ?>" onclick="unselectAll();">
|
||||
<input id="csvexport" class="btn btn-success" type="submit" value="<?php echo Text::_('COM_JEM_EXPORT_FILE'); ?>" onclick="document.getElementsByName('task')[0].value='export.export';return true;"></input>
|
||||
</div>
|
||||
</fieldset>
|
||||
|
||||
<div class="clr"></div>
|
||||
</div>
|
||||
|
||||
<div class="col-md-3">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_EXPORT_OTHER_LEGEND');?></legend>
|
||||
|
||||
<ul class="adminformlist">
|
||||
<li>
|
||||
<label class="labelexport"><?php echo Text::_('COM_JEM_EXPORT_CATEGORIES'); ?></label>
|
||||
<input type="submit" id="csvexport" class="btn btn-success" value="<?php echo Text::_('COM_JEM_EXPORT_FILE'); ?>" onclick="document.getElementsByName('task')[0].value='export.exportcats';return true;"></input>
|
||||
</li>
|
||||
<li>
|
||||
<label class="labelexport"><?php echo Text::_('COM_JEM_EXPORT_VENUES'); ?></label>
|
||||
<input type="submit" id="csvexport" class="btn btn-success" value="<?php echo Text::_('COM_JEM_EXPORT_FILE'); ?>" onclick="document.getElementsByName('task')[0].value='export.exportvenues';return true;"></input>
|
||||
</li>
|
||||
<li>
|
||||
<label class="labelexport"><?php echo Text::_('COM_JEM_EXPORT_CAT_EVENTS'); ?></label>
|
||||
<input type="submit" id="csvexport" class="btn btn-success" value="<?php echo Text::_('COM_JEM_EXPORT_FILE'); ?>" onclick="document.getElementsByName('task')[0].value='export.exportcatevents';return true;"></input>
|
||||
</li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
<div class="clr"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php //if (isset($this->sidebar)) : ?>
|
||||
<?php //endif; ?>
|
||||
|
||||
<?php echo HTMLHelper::_( 'form.token' ); ?>
|
||||
<input type="hidden" name="option" value="com_jem" />
|
||||
<input type="hidden" name="view" value="export" />
|
||||
<input type="hidden" name="controller" value="export" />
|
||||
<input type="hidden" name="task" value="" />
|
||||
</form>
|
||||
</div>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
65
administrator/components/com_jem/views/export/view.html.php
Normal file
65
administrator/components/com_jem/views/export/view.html.php
Normal file
@ -0,0 +1,65 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
|
||||
/**
|
||||
* View class Export
|
||||
*
|
||||
* @package JEM
|
||||
*
|
||||
*/
|
||||
class JemViewExport extends JemAdminView
|
||||
{
|
||||
|
||||
public function display($tpl = null) {
|
||||
//Load pane behavior
|
||||
jimport('joomla.html.pane');
|
||||
|
||||
//initialise variables
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
//Cause of group limits we can't use class here to build the categories tree
|
||||
$categories = $this->get('Categories');
|
||||
|
||||
//build selectlists
|
||||
$categories = JEMCategories::buildcatselect($categories, 'cid[]', null, 0, 'multiple="multiple" size="8" class="inputbox form-control"');
|
||||
|
||||
$this->categories = $categories;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_EXPORT'), 'tableexport');
|
||||
|
||||
ToolbarHelper::back();
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::inlinehelp();
|
||||
ToolBarHelper::help('export', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/control-panel/export-data');
|
||||
}
|
||||
}
|
||||
?>
|
||||
1
administrator/components/com_jem/views/group/index.html
Normal file
1
administrator/components/com_jem/views/group/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
153
administrator/components/com_jem/views/group/tmpl/edit.php
Normal file
153
administrator/components/com_jem/views/group/tmpl/edit.php
Normal file
@ -0,0 +1,153 @@
|
||||
<?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;
|
||||
|
||||
$wa = $this->document->getWebAssetManager();
|
||||
$wa->useScript('keepalive')
|
||||
->useScript('inlinehelp')
|
||||
->useScript('form.validate');
|
||||
|
||||
// Create shortcut to parameters.
|
||||
$params = $this->state->get('params');
|
||||
$params = $params->toArray();
|
||||
|
||||
?>
|
||||
<script>
|
||||
window.addEvent('domready', function(){
|
||||
});
|
||||
|
||||
// moves elements from one select box to another one
|
||||
function moveOptions(from,to) {
|
||||
// Move them over
|
||||
for (var i=0; i<from.options.length; i++) {
|
||||
var o = from.options[i];
|
||||
if (o.selected) {
|
||||
to.options[to.options.length] = new Option( o.text, o.value, false, false);
|
||||
}
|
||||
}
|
||||
|
||||
// Delete them from original
|
||||
for (var i=(from.options.length-1); i>=0; i--) {
|
||||
var o = from.options[i];
|
||||
if (o.selected) {
|
||||
from.options[i] = null;
|
||||
}
|
||||
}
|
||||
from.selectedIndex = -1;
|
||||
to.selectedIndex = -1;
|
||||
}
|
||||
|
||||
function selectAll()
|
||||
{
|
||||
selectBox = document.getElementById("maintainers");
|
||||
|
||||
for (var i = 0; i < selectBox.options.length; i++)
|
||||
{
|
||||
selectBox.options[i].selected = true;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<script>
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
selectAll();
|
||||
if (task == 'group.cancel' || document.formvalidator.isValid(document.getElementById('adminForm'))) {
|
||||
Joomla.submitform(task, document.getElementById('adminForm'));
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
|
||||
<form
|
||||
action="<?php echo Route::_('index.php?option=com_jem&layout=edit&id='.(int) $this->item->id); ?>"
|
||||
class="form-validate" method="post" name="adminForm" id="adminForm" enctype="multipart/form-data">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-7">
|
||||
<!-- <div class="width-55 fltlft"> -->
|
||||
<?php echo HTMLHelper::_('uitab.startTabSet', 'myTab', ['active' => 'group-info', 'recall' => true, 'breakpoint' => 768]); ?>
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'myTab', 'group-info', Text::_('COM_JEM_GROUP_INFO_TAB')); ?>
|
||||
<fieldset class="adminform">
|
||||
<legend>
|
||||
<?php echo empty($this->item->id) ? Text::_('COM_JEM_NEW_GROUP') : Text::sprintf('COM_JEM_GROUP_DETAILS', $this->item->id); ?>
|
||||
</legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('name'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('id'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('maintainers2'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
<fieldset class="adminform">
|
||||
<table class="adminform" style="width: 100%">
|
||||
<tr>
|
||||
<td><b><?php echo Text::_('COM_JEM_GROUP_AVAILABLE_USERS').':'; ?></b></td>
|
||||
<td> </td>
|
||||
<td><b><?php echo Text::_('COM_JEM_GROUP_MAINTAINERS').':'; ?></b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="44%"><?php echo $this->lists['available_users']; ?></td>
|
||||
<td width="10%">
|
||||
<input style="width: 90%" type="button" name="right" value=">" onClick="moveOptions(document.adminForm['available_users'], document.adminForm['maintainers[]'])" />
|
||||
<br /><br />
|
||||
<input style="width: 90%" type="button" name="left" value="<" onClick="moveOptions(document.adminForm['maintainers[]'], document.adminForm['available_users'])" />
|
||||
</td>
|
||||
<td width="44%"><?php echo $this->lists['maintainers']; ?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
<fieldset class="adminform">
|
||||
<div>
|
||||
<?php echo $this->form->getLabel('description'); ?>
|
||||
<div class="clr"></div>
|
||||
<?php echo $this->form->getInput('description'); ?>
|
||||
</div>
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<!-- </div> -->
|
||||
</div>
|
||||
<div class="col-md-5">
|
||||
<!-- <div class="width-40 fltrt"> -->
|
||||
<div class="accordion" id="accordionGroupForm">
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="group-permission-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#group-permission" aria-expanded="true" aria-controls="group-permission">
|
||||
<?php echo Text::_('COM_JEM_GROUP_PERMISSIONS'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="group-permission" class="accordion-collapse collapse show" aria-labelledby="group-permission-header" data-bs-parent="#accordionGroupForm">
|
||||
<div class="accordion-body">
|
||||
<fieldset class="panelform">
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('addvenue'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('publishvenue'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('editvenue'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('addevent'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('publishevent'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('editevent'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- </div> -->
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="clr"></div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo HTMLHelper::_( 'form.token' ); ?>
|
||||
</form>
|
||||
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
117
administrator/components/com_jem/views/group/view.html.php
Normal file
117
administrator/components/com_jem/views/group/view.html.php
Normal file
@ -0,0 +1,117 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
use Joomla\CMS\Filter\OutputFilter;
|
||||
|
||||
/**
|
||||
* View class Group
|
||||
*
|
||||
* @package Joomla
|
||||
* @subpackage JEM
|
||||
*
|
||||
*/
|
||||
class JemViewGroup extends JemAdminView
|
||||
{
|
||||
protected $form;
|
||||
protected $item;
|
||||
protected $state;
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
// Initialise variables.
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$this->form = $this->get('Form');
|
||||
$this->item = $this->get('Item');
|
||||
$this->state = $this->get('State');
|
||||
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
$app->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
//initialise variables
|
||||
$jemsettings = JemHelper::config();
|
||||
$this->settings = JemAdmin::config();
|
||||
$task = $app->input->get('task', '');
|
||||
$this->task = $task;
|
||||
$url = Uri::root();
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
$maintainers = $this->get('Members');
|
||||
$available_users = $this->get('Available');
|
||||
|
||||
//make data safe
|
||||
OutputFilter::objectHTMLSafe($this->item);
|
||||
|
||||
//create selectlists
|
||||
$lists = array();
|
||||
$lists['maintainers'] = HTMLHelper::_('select.genericlist', $maintainers, 'maintainers[]', array('class'=>'inputbox','size'=>'20','onDblClick'=>'moveOptions(document.adminForm[\'maintainers[]\'], document.adminForm[\'available_users\'])', 'multiple'=>'multiple', 'style'=>'padding: 6px; width: 98%;'), 'value', 'text');
|
||||
$lists['available_users'] = HTMLHelper::_('select.genericlist', $available_users, 'available_users', array('class'=>'inputbox','size'=>'20','onDblClick'=>'moveOptions(document.adminForm[\'available_users\'], document.adminForm[\'maintainers[]\'])', 'multiple'=>'multiple','style'=>'padding: 6px; width: 98%;'), 'value', 'text');
|
||||
|
||||
$this->jemsettings = $jemsettings;
|
||||
$this->lists = $lists;
|
||||
|
||||
$this->addToolbar();
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
Factory::getApplication()->input->set('hidemainmenu', true);
|
||||
|
||||
$user = JemFactory::getUser();
|
||||
$isNew = ($this->item->id == 0);
|
||||
$checkedOut = !($this->item->checked_out == 0 || $this->item->checked_out == $user->get('id'));
|
||||
$canDo = JemHelperBackend::getActions();
|
||||
|
||||
ToolbarHelper::title($isNew ? Text::_('COM_JEM_GROUP_ADD') : Text::_('COM_JEM_GROUP_EDIT'), 'groupedit');
|
||||
|
||||
// If not checked out, can save the item.
|
||||
if (!$checkedOut && ($canDo->get('core.edit')||$canDo->get('core.create'))) {
|
||||
ToolbarHelper::apply('group.apply');
|
||||
ToolbarHelper::save('group.save');
|
||||
}
|
||||
if (!$checkedOut && $canDo->get('core.create')) {
|
||||
ToolbarHelper::save2new('group.save2new');
|
||||
}
|
||||
// If an existing item, can save to a copy.
|
||||
if (!$isNew && $canDo->get('core.create')) {
|
||||
ToolbarHelper::save2copy('group.save2copy');
|
||||
}
|
||||
|
||||
if (empty($this->item->id)) {
|
||||
ToolbarHelper::cancel('group.cancel');
|
||||
} else {
|
||||
ToolbarHelper::cancel('group.cancel', 'JTOOLBAR_CLOSE');
|
||||
}
|
||||
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::inlinehelp();
|
||||
ToolBarHelper::help('editgroup', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/groups/add-group');
|
||||
}
|
||||
}
|
||||
?>
|
||||
1
administrator/components/com_jem/views/groups/index.html
Normal file
1
administrator/components/com_jem/views/groups/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
117
administrator/components/com_jem/views/groups/tmpl/default.php
Normal file
117
administrator/components/com_jem/views/groups/tmpl/default.php
Normal file
@ -0,0 +1,117 @@
|
||||
<?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;
|
||||
use Joomla\CMS\Object\CMSObject;
|
||||
|
||||
$user = JemFactory::getUser();
|
||||
$userId = $user->get('id');
|
||||
$listOrder = $this->escape($this->state->get('list.ordering'));
|
||||
$listDirn = $this->escape($this->state->get('list.direction'));
|
||||
$canOrder = $user->authorise('core.edit.state', 'com_jem.category');
|
||||
$saveOrder = $listOrder=='ordering';
|
||||
|
||||
$params = (isset($this->state->params)) ? $this->state->params : new CMSObject();
|
||||
?>
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=groups'); ?>" method="post" name="adminForm" id="adminForm">
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<fieldset id="filter-bar" class=" mb-3">
|
||||
<div class="row">
|
||||
<div class="col-md-11">
|
||||
<div class="row mb-12">
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<input type="text" name="filter_search" id="filter_search" class="form-control" aria-describedby="filter_search-desc" placeholder="<?php echo Text::_('COM_JEM_SEARCH');?>" value="<?php echo $this->escape($this->state->get('filter_search')); ?>" inputmode="search" onChange="document.adminForm.submit();" >
|
||||
|
||||
<button type="submit" class="filter-search-bar__button btn btn-primary" aria-label="Search">
|
||||
<span class="filter-search-bar__button-icon icon-search" aria-hidden="true"></span>
|
||||
</button>
|
||||
<button type="button" class="btn btn-primary" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-1">
|
||||
<div class="row">
|
||||
<div class="wauto-minwmax">
|
||||
<div class="float-end">
|
||||
<?php echo $this->pagination->getLimitBox(); ?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
<div class="clr"> </div>
|
||||
|
||||
<table class="table table-striped" id="articleList">
|
||||
<thead>
|
||||
<tr>
|
||||
<th width="5" class="center"><input type="checkbox" name="checkall-toggle" value="" title="<?php echo Text::_('JGLOBAL_CHECK_ALL'); ?>" onclick="Joomla.checkAll(this)" /></th>
|
||||
<th width="30%" class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_GROUP_NAME', 'name', $listDirn, $listOrder ); ?></th>
|
||||
<th><?php echo Text::_( 'COM_JEM_DESCRIPTION' ); ?></th>
|
||||
<th width="1%" class="title"><?php echo HTMLHelper::_('grid.sort', 'COM_JEM_ID', 'id', $listDirn, $listOrder ); ?></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
<tbody>
|
||||
<?php foreach ($this->items as $i => $row) :
|
||||
$ordering = ($listOrder == 'ordering');
|
||||
$canCreate = $user->authorise('core.create');
|
||||
$canEdit = $user->authorise('core.edit');
|
||||
$canCheckin = $user->authorise('core.manage', 'com_checkin') || $row->checked_out == $userId || $row->checked_out == 0;
|
||||
$canChange = $user->authorise('core.edit.state') && $canCheckin;
|
||||
|
||||
$link = 'index.php?option=com_jem&task=group.edit&id='.$row->id;
|
||||
?>
|
||||
<tr class="row<?php echo $i % 2; ?>">
|
||||
<td class="center"><?php echo HTMLHelper::_('grid.id', $i, $row->id); ?></td>
|
||||
<td>
|
||||
<?php if ($row->checked_out) : ?>
|
||||
<?php echo HTMLHelper::_('jgrid.checkedout', $i, $row->editor, $row->checked_out_time, 'groups.', $canCheckin); ?>
|
||||
<?php endif; ?>
|
||||
<?php if ($canEdit) : ?>
|
||||
<a href="<?php echo $link; ?>">
|
||||
<?php echo $this->escape($row->name); ?>
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<?php echo $this->escape($row->name); ?>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td>
|
||||
<?php
|
||||
$desc = $row->description;
|
||||
$descoutput = strip_tags($desc);
|
||||
echo $this->escape($descoutput);
|
||||
?>
|
||||
</td>
|
||||
<td class="center"><?php echo $row->id; ?></td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<div class="ms-auto mb-4 me-0">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks(null) : $this->pagination->getListFooter()); ?>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<input type="hidden" name="boxchecked" value="0" />
|
||||
<input type="hidden" name="filter_order" value="<?php echo $listOrder; ?>" />
|
||||
<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn; ?>" />
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</div>
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
88
administrator/components/com_jem/views/groups/view.html.php
Normal file
88
administrator/components/com_jem/views/groups/view.html.php
Normal file
@ -0,0 +1,88 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
/**
|
||||
* View class for the JEM Groups screen
|
||||
*
|
||||
* @package Joomla
|
||||
* @subpackage JEM
|
||||
*
|
||||
*/
|
||||
|
||||
class JemViewGroups extends JemAdminView
|
||||
{
|
||||
protected $items;
|
||||
protected $pagination;
|
||||
protected $state;
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$user = JemFactory::getUser();
|
||||
$jemsettings = JEMAdmin::config();
|
||||
|
||||
// Initialise variables.
|
||||
$this->items = $this->get('Items');
|
||||
$this->pagination = $this->get('Pagination');
|
||||
$this->state = $this->get('State');
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// assign data to template
|
||||
$this->user = $user;
|
||||
$this->jemsettings = $jemsettings;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_GROUPS'), 'groups');
|
||||
|
||||
/* retrieving the allowed actions for the user */
|
||||
$canDo = JEMHelperBackend::getActions(0);
|
||||
|
||||
/* create */
|
||||
if (($canDo->get('core.create'))) {
|
||||
ToolbarHelper::addNew('group.add');
|
||||
}
|
||||
|
||||
/* edit */
|
||||
if (($canDo->get('core.edit'))) {
|
||||
ToolbarHelper::editList('group.edit');
|
||||
ToolbarHelper::divider();
|
||||
}
|
||||
|
||||
if ($canDo->get('core.edit.state')) {
|
||||
ToolbarHelper::checkin('groups.checkin');
|
||||
}
|
||||
|
||||
ToolbarHelper::deleteList('COM_JEM_CONFIRM_DELETE', 'groups.remove', 'JACTION_DELETE');
|
||||
|
||||
ToolbarHelper::divider();
|
||||
ToolBarHelper::help('listgroups', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/groups');
|
||||
}
|
||||
}
|
||||
?>
|
||||
1
administrator/components/com_jem/views/help/index.html
Normal file
1
administrator/components/com_jem/views/help/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
115
administrator/components/com_jem/views/help/tmpl/default.php
Normal file
115
administrator/components/com_jem/views/help/tmpl/default.php
Normal file
@ -0,0 +1,115 @@
|
||||
<?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;
|
||||
|
||||
|
||||
$options = array(
|
||||
'onActive' => 'function(title, description){
|
||||
description.setStyle("display", "block");
|
||||
title.addClass("open").removeClass("closed");
|
||||
}',
|
||||
'onBackground' => 'function(title, description){
|
||||
description.setStyle("display", "none");
|
||||
title.addClass("closed").removeClass("open");
|
||||
}',
|
||||
'opacityTransition' => true,
|
||||
'startOffset' => 0, // 0 starts on the first tab, 1 starts the second, etc...
|
||||
'useCookie' => true, // this must not be a string. Don't use quotes.
|
||||
);
|
||||
?>
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=help'); ?>" method="post" name="adminForm" id="adminForm">
|
||||
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<div class="row mb-3">
|
||||
<div class="col-md-12">
|
||||
<fieldset id="filter-bar" class=" mb-3">
|
||||
<div class="row mb-3">
|
||||
<div class="col-md-4">
|
||||
<div class="input-group">
|
||||
<input type="text" name="filter_search" id="filter_search" class="form-control" aria-describedby="filter_search-desc" placeholder="<?php echo Text::_('COM_JEM_SEARCH');?>" value="<?php echo $this->helpsearch;?>" inputmode="search" onChange="document.adminForm.submit();" >
|
||||
|
||||
<button type="submit" class="filter-search-bar__button btn btn-primary" aria-label="Search">
|
||||
<span class="filter-search-bar__button-icon icon-search" aria-hidden="true"></span>
|
||||
</button>
|
||||
<button type="button" class="btn btn-primary" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<div class="filter-select fltrt">
|
||||
<a href="<?php echo 'components/com_jem/help/'.$this->langTag.'/intro.html'; ?>" target='helpFrame'><?php echo Text::_('COM_JEM_HOME'); ?></a>
|
||||
|
|
||||
<a href="<?php echo 'components/com_jem/help/'.$this->langTag.'/helpsite/gethelp.html'; ?>" target='helpFrame'><?php echo Text::_('COM_JEM_GET_HELP'); ?></a>
|
||||
|
|
||||
<a href="<?php echo 'components/com_jem/help/'.$this->langTag.'/helpsite/contribute.html'; ?>" target='helpFrame'><?php echo Text::_('COM_JEM_CONTRIBUTE'); ?></a>
|
||||
|
|
||||
<a href="<?php echo 'components/com_jem/help/'.$this->langTag.'/helpsite/credits.html'; ?>" target='helpFrame'><?php echo Text::_('COM_JEM_CREDITS'); ?></a>
|
||||
|
|
||||
<?php echo HTMLHelper::_('link', 'https://www.gnu.org/licenses/gpl-3.0', Text::_('COM_JEM_LICENSE'), array('target' => '_blank')) ?>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4">
|
||||
<div id="treecellhelp" class="w-100">
|
||||
<div class="accordion" id="accordionHelpForm">
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="det-pane-header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#det-pane-details" aria-expanded="true" aria-controls="det-pane-details">
|
||||
<?php echo Text::_('COM_JEM_SCREEN_HELP'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="det-pane-details" class="accordion-collapse collapse show" aria-labelledby="det-pane-header" data-bs-parent="#accordionHelpForm">
|
||||
<div class="accordion-body">
|
||||
<fieldset class="panelform">
|
||||
<table class="adminlist help-toc">
|
||||
<?php
|
||||
foreach ($this->toc as $k=>$v) {
|
||||
echo '<tr>';
|
||||
echo '<td>';
|
||||
echo HTMLHelper::Link('components/com_jem/help/'.$this->langTag.'/'.$k, $v, array('target' => 'helpFrame'));
|
||||
echo '</td>';
|
||||
echo '</tr>';
|
||||
}
|
||||
?>
|
||||
</table>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-8">
|
||||
<div id="datacellhelp" class="w-100">
|
||||
<iframe name="helpFrame" src="<?php echo 'components/com_jem/help/'.$this->langTag.'/intro.html'; ?>" class="helpFrame w-100" height="600px"></iframe>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clr"> </div>
|
||||
</div>
|
||||
|
||||
<input type="hidden" name="option" value="com_jem" />
|
||||
<input type="hidden" name="view" value="help" />
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</form>
|
||||
|
||||
<?php
|
||||
$wa = $this->document->getWebAssetManager();
|
||||
$wa->useScript('keepalive');
|
||||
|
||||
?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
114
administrator/components/com_jem/views/help/view.html.php
Normal file
114
administrator/components/com_jem/views/help/view.html.php
Normal file
@ -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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
use Joomla\CMS\Filesystem\Folder;
|
||||
|
||||
jimport('joomla.html.pane');
|
||||
|
||||
|
||||
/**
|
||||
* View class for the JEM Help screen
|
||||
*
|
||||
* @package JEM
|
||||
*/
|
||||
class JemViewHelp extends JemAdminView
|
||||
{
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
//initialise variables
|
||||
$lang = Factory::getApplication()->getLanguage();
|
||||
$app = Factory::getApplication();
|
||||
$this->document = $app->getDocument();
|
||||
|
||||
//get vars
|
||||
$helpsearch = Factory::getApplication()->input->getString('filter_search', '');
|
||||
|
||||
// // Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
// Check for files in the actual language
|
||||
$langTag = $lang->getTag();
|
||||
|
||||
if (!Folder::exists(JPATH_SITE .'/administrator/components/com_jem/help/'.$langTag)) {
|
||||
$langTag = 'en-GB'; // use english as fallback
|
||||
}
|
||||
|
||||
//search the keyword in the files
|
||||
$toc = JemViewHelp::getHelpToc($helpsearch);
|
||||
|
||||
//assign data to template
|
||||
$this->langTag = $langTag;
|
||||
$this->helpsearch = $helpsearch;
|
||||
$this->toc = $toc;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Compiles the help table of contents
|
||||
* Based on the Joomla admin component
|
||||
*
|
||||
* @param string A specific keyword on which to filter the resulting list
|
||||
*/
|
||||
public function getHelpTOC($helpsearch)
|
||||
{
|
||||
$lang = Factory::getApplication()->getLanguage();
|
||||
|
||||
// Check for files in the actual language
|
||||
$langTag = $lang->getTag();
|
||||
|
||||
if (!Folder::exists(JPATH_SITE .'/administrator/components/com_jem/help/'.$langTag)) {
|
||||
$langTag = 'en-GB'; // use english as fallback
|
||||
}
|
||||
$files = Folder::files(JPATH_SITE .'/administrator/components/com_jem/help/'.$langTag, '\.xml$|\.html$');
|
||||
|
||||
$toc = array();
|
||||
foreach ($files as $file) {
|
||||
$buffer = file_get_contents(JPATH_SITE .'/administrator/components/com_jem/help/'.$langTag.'/'.$file);
|
||||
if (preg_match('#<title>(.*?)</title>#', $buffer, $m)) {
|
||||
$title = trim($m[1]);
|
||||
if ($title) {
|
||||
if ($helpsearch) {
|
||||
if (\Joomla\String\StringHelper::strpos(strip_tags($buffer), $helpsearch) !== false) {
|
||||
$toc[$file] = $title;
|
||||
}
|
||||
} else {
|
||||
$toc[$file] = $title;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
asort($toc);
|
||||
return $toc;
|
||||
}
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
//create the toolbar
|
||||
ToolbarHelper::title(Text::_('COM_JEM_HELP'), 'help');
|
||||
ToolBarHelper::divider();
|
||||
ToolBarHelper::help('help', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/control-panel/help');
|
||||
}
|
||||
}
|
||||
?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -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;
|
||||
use Joomla\CMS\Session\Session;
|
||||
?>
|
||||
<form name="adminForm" method="post" id="adminForm">
|
||||
<?php if (isset($this->sidebar)) : ?>
|
||||
<div id="j-sidebar-container" class="span2">
|
||||
<?php echo $this->sidebar; ?>
|
||||
</div>
|
||||
<div id="j-main-container" class="span10">
|
||||
<?php endif; ?>
|
||||
<table class="table table-striped">
|
||||
<tbody>
|
||||
<!-- CLEAN EVENT IMG -->
|
||||
<tr>
|
||||
<td width="60px;">
|
||||
<div class="linkicon">
|
||||
<a href="index.php?option=com_jem&task=housekeeping.cleaneventimg&<?php echo Session::getFormToken(); ?>=1">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/icon-48-cleaneventimg.png', Text::_('COM_JEM_HOUSEKEEPING_EVENT_IMG'), NULL, true); ?>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<h3><?php echo Text::_('COM_JEM_HOUSEKEEPING_EVENT_IMG'); ?></h3>
|
||||
<?php echo Text::_('COM_JEM_HOUSEKEEPING_EVENT_IMG_DESC'); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- CLEAN VENUE IMG -->
|
||||
<tr>
|
||||
<td width="60px;">
|
||||
<div class="linkicon">
|
||||
<a href="index.php?option=com_jem&task=housekeeping.cleanvenueimg&<?php echo Session::getFormToken(); ?>=1">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/icon-48-cleanvenueimg.png', Text::_('COM_JEM_HOUSEKEEPING_VENUE_IMG'), NULL, true); ?>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<h3><?php echo Text::_('COM_JEM_HOUSEKEEPING_VENUE_IMG'); ?></h3>
|
||||
<?php echo Text::_('COM_JEM_HOUSEKEEPING_VENUE_IMG_DESC'); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- CLEAN CATEGORY IMG -->
|
||||
<tr>
|
||||
<td width="60px;">
|
||||
<div class="linkicon">
|
||||
<a href="index.php?option=com_jem&task=housekeeping.cleancategoryimg&<?php echo Session::getFormToken(); ?>=1">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/icon-48-cleancategoryimg.png', Text::_('COM_JEM_HOUSEKEEPING_CATEGORY_IMG'), NULL, true); ?>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<h3><?php echo Text::_('COM_JEM_HOUSEKEEPING_CATEGORY_IMG'); ?></h3>
|
||||
<?php echo Text::_('COM_JEM_HOUSEKEEPING_CATEGORY_IMG_DESC'); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- CLEAN TRIGGER ARCHIVE -->
|
||||
<tr>
|
||||
<td width="60px;">
|
||||
<div class="linkicon">
|
||||
<a href="index.php?option=com_jem&task=housekeeping.triggerarchive&<?php echo Session::getFormToken(); ?>=1">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/icon-48-archive.png', Text::_('COM_JEM_HOUSEKEEPING_TRIGGER_AUTOARCHIVE'), NULL, true); ?>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<h3><?php echo Text::_('COM_JEM_HOUSEKEEPING_TRIGGER_AUTOARCHIVE'); ?></h3>
|
||||
<?php echo Text::_('COM_JEM_HOUSEKEEPING_TRIGGER_AUTOARCHIVE_DESC'); ?>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- TRUNCATE CATEGORY/EVENT REFERENCES -->
|
||||
<tr>
|
||||
<td width="60px;">
|
||||
<div class="linkicon">
|
||||
<a href="index.php?option=com_jem&task=housekeeping.cleanupCatsEventRelations&<?php echo Session::getFormToken(); ?>=1">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/icon-48-cleancategoryimg.png', Text::_('COM_JEM_HOUSEKEEPING_CATSEVENT_RELS'), NULL, true); ?>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<h3><?php echo Text::_('COM_JEM_HOUSEKEEPING_CLEANUP_CATSEVENT_RELS'); ?></h3>
|
||||
<?php echo Text::_('COM_JEM_HOUSEKEEPING_CLEANUP_CATSEVENT_RELS_DESC'); ?><br/>
|
||||
<?php echo Text::sprintf('COM_JEM_HOUSEKEEPING_TOTAL_CATSEVENT_RELS', $this->totalcats) ?>
|
||||
</td>
|
||||
</tr>
|
||||
<!-- TRUNCATE ALL DATA -->
|
||||
<tr>
|
||||
<td width="60px;">
|
||||
<div class="linkicon">
|
||||
<a href="index.php?option=com_jem&task=housekeeping.truncateAllData&<?php echo Session::getFormToken(); ?>=1" onclick="javascript:return confirm('<?php echo Text::_('COM_JEM_HOUSEKEEPING_TRUNCATE_ALL_DATA_CONFIRM'); ?>');">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/icon-48-truncatealldata.png', Text::_('COM_JEM_HOUSEKEEPING_TRUNCATE_ALL_DATA'), NULL, true); ?>
|
||||
</a>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<h3><?php echo Text::_('COM_JEM_HOUSEKEEPING_TRUNCATE_ALL_DATA'); ?></h3>
|
||||
<?php echo Text::_('COM_JEM_HOUSEKEEPING_TRUNCATE_ALL_DATA_DESC'); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<?php if (isset($this->sidebar)) : ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,60 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
/**
|
||||
* Housekeeping-View
|
||||
*/
|
||||
class JemViewHousekeeping extends JemAdminView
|
||||
{
|
||||
|
||||
public function display($tpl = null) {
|
||||
|
||||
$app = Factory::getApplication();
|
||||
$user = $app->getIdentity();
|
||||
|
||||
$this->totalcats = $this->get('Countcats');
|
||||
|
||||
//only admins have access to this view
|
||||
if (!$user->authorise('core.manage', 'com_jem')) {
|
||||
$app->enqueueMessage(Text::_('JERROR_ALERTNOAUTHOR'), 'warning');
|
||||
$app->redirect('index.php?option=com_jem&view=main');
|
||||
}
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_HOUSEKEEPING'), 'housekeeping');
|
||||
|
||||
ToolbarHelper::back();
|
||||
ToolbarHelper::divider();
|
||||
ToolBarHelper::help('housekeeping', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/control-panel/housekeeping');
|
||||
}
|
||||
}
|
||||
?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,43 @@
|
||||
<?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;
|
||||
?>
|
||||
<form action="index.php" method="post" name="adminForm" id="adminForm">
|
||||
<div class="imghead">
|
||||
<?php echo Text::_('COM_JEM_SEARCH').' '; ?>
|
||||
<input type="text" name="filter_search" id="filter_search" value="<?php echo $this->search; ?>" class="text_area form-control inputbox required valid form-control-success w-50" style="display:inline-block;" onChange="document.adminForm.submit();" />
|
||||
<button class="buttonfilter btn btn-primary" type="submit"><?php echo Text::_('JSEARCH_FILTER_SUBMIT'); ?></button>
|
||||
<button class="buttonfilter btn btn-primary" type="button" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo Text::_('JSEARCH_FILTER_CLEAR'); ?></button>
|
||||
</div>
|
||||
|
||||
<div class="imglist">
|
||||
<?php
|
||||
$n = is_array($this->images) ? count($this->images) : 0;
|
||||
for ($i = 0; $i < $n; $i++) :
|
||||
$this->setImage($i);
|
||||
echo $this->loadTemplate('image');
|
||||
endfor;
|
||||
?>
|
||||
</div>
|
||||
|
||||
<div class="clear"></div>
|
||||
|
||||
<div class="pnav">
|
||||
<?php echo (method_exists($this->pagination, 'getPaginationLinks') ? $this->pagination->getPaginationLinks() : $this->pagination->getListFooter()); ?>
|
||||
</div>
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
<input type="hidden" name="option" value="com_jem" />
|
||||
<input type="hidden" name="view" value="imagehandler" />
|
||||
<input type="hidden" name="tmpl" value="component" />
|
||||
<input type="hidden" name="task" value="<?php echo $this->task; ?>" />
|
||||
</form>
|
||||
@ -0,0 +1,32 @@
|
||||
<?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\Session\Session;
|
||||
?>
|
||||
<div class="item-image">
|
||||
<div class="imgBorder center">
|
||||
<a onclick="window.parent.SelectImage('<?php echo $this->_tmp_img->name; ?>', '<?php echo $this->_tmp_img->name; ?>');">
|
||||
<div class="image">
|
||||
<img src="../images/jem/<?php echo $this->folder; ?>/<?php echo $this->_tmp_img->name; ?>" width="<?php echo $this->_tmp_img->width_60; ?>" height="<?php echo $this->_tmp_img->height_60; ?>" alt="<?php echo $this->_tmp_img->name; ?> - <?php echo $this->_tmp_img->size; ?>" />
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
<div class="controls">
|
||||
<?php echo $this->_tmp_img->size; ?> -
|
||||
<a class="delete-item" href="index.php?option=com_jem&task=imagehandler.delete&tmpl=component&folder=<?php echo $this->folder; ?>&rm[]=<?php echo $this->_tmp_img->name; ?>&<?php echo Session::getFormToken(); ?>=1">
|
||||
<?php echo HTMLHelper::_('image','/media/com_jem/images/publish_r.png',Text::_('COM_JEM_DELETE_IMAGE'),array('title' => Text::_('COM_JEM_DELETE_IMAGE')),true); ?>
|
||||
</a>
|
||||
</div>
|
||||
<div class="imageinfo">
|
||||
<?php echo $this->escape(\Joomla\String\StringHelper::substr($this->_tmp_img->name, 0, 10) . (\Joomla\String\StringHelper::strlen($this->_tmp_img->name) > 10 ? '...' : '')); ?>
|
||||
</div>
|
||||
</div>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
@ -0,0 +1,158 @@
|
||||
<?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;
|
||||
?>
|
||||
|
||||
<form method="post" action="<?php echo htmlspecialchars($this->request_url); ?>" enctype="multipart/form-data" name="adminForm" id="adminForm">
|
||||
|
||||
<table class="noshow">
|
||||
<tr>
|
||||
<td width="50%" valign="top">
|
||||
|
||||
<?php if($this->ftp): ?>
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_FTP_TITLE'); ?></legend>
|
||||
|
||||
<?php echo Text::_('COM_JEM_FTP_DESC'); ?>
|
||||
|
||||
<?php if($this->ftp INSTANCEOF Exception): ?>
|
||||
<p><?php echo Text::_($this->ftp->message); ?></p>
|
||||
<?php endif; ?>
|
||||
|
||||
<table class="adminform nospace">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td width="120">
|
||||
<label for="username"><?php echo Text::_('COM_JEM_USERNAME'); ?>:</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" id="username" name="username" class="input_box" size="70" value="" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="120">
|
||||
<label for="password"><?php echo Text::_('COM_JEM_PASSWORD'); ?>:</label>
|
||||
</td>
|
||||
<td>
|
||||
<input type="password" id="password" name="password" class="input_box" size="70" value="" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</fieldset>
|
||||
<?php endif; ?>
|
||||
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_SELECT_IMAGE_UPLOAD'); ?></legend>
|
||||
<table class="admintable">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<input class="inputbox" name="userfile" id="userfile" type="file" />
|
||||
<br /><br />
|
||||
<input class="btn btn-primary" type="submit" value="<?php echo Text::_('COM_JEM_UPLOAD') ?>" name="adminForm" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</fieldset>
|
||||
|
||||
</td>
|
||||
<td width="50%" valign="top">
|
||||
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_ATTENTION'); ?></legend>
|
||||
<table class="admintable">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<b><?php echo Text::_('COM_JEM_TARGET_DIRECTORY').':'; ?></b>
|
||||
<?php
|
||||
if($this->task == 'venueimg') {
|
||||
echo "/images/jem/venues/";
|
||||
$this->task = 'imagehandler.venueimgup';
|
||||
} else if($this->task == 'eventimg') {
|
||||
echo "/images/jem/events/";
|
||||
$this->task = 'imagehandler.eventimgup';
|
||||
} else if($this->task == 'categoriesimg') {
|
||||
echo "/images/jem/categories/";
|
||||
$this->task = 'imagehandler.categoriesimgup';
|
||||
}
|
||||
?>
|
||||
<br />
|
||||
<b><?php echo Text::_('COM_JEM_IMAGE_FILESIZE').':'; ?></b> <?php echo $this->jemsettings->sizelimit; ?> kb<br />
|
||||
|
||||
<?php
|
||||
if($this->jemsettings->gddisabled == 0 || (imagetypes() & IMG_PNG)) {
|
||||
echo "<br /><span style='color:green'>".Text::_('COM_JEM_PNG_SUPPORT')."</span>";
|
||||
} else {
|
||||
echo "<br /><span style='color:red'>".Text::_('COM_JEM_NO_PNG_SUPPORT')."</span>";
|
||||
}
|
||||
if($this->jemsettings->gddisabled == 0 || (imagetypes() & IMG_JPEG)) {
|
||||
echo "<br /><span style='color:green'>".Text::_('COM_JEM_JPG_SUPPORT')."</span>";
|
||||
} else {
|
||||
echo "<br /><span style='color:red'>".Text::_('COM_JEM_NO_JPG_SUPPORT')."</span>";
|
||||
}
|
||||
if($this->jemsettings->gddisabled == 0 || (imagetypes() & IMG_GIF)) {
|
||||
echo "<br /><span style='color:green'>".Text::_('COM_JEM_GIF_SUPPORT')."</span>";
|
||||
} else {
|
||||
echo "<br /><span style='color:red'>".Text::_('COM_JEM_NO_GIF_SUPPORT')."</span>";
|
||||
}
|
||||
if($this->jemsettings->gddisabled == 0 || (imagetypes() & IMG_WEBP)) {
|
||||
echo "<br /><span style='color:green'>".Text::_('COM_JEM_WEBP_SUPPORT')."</span>";
|
||||
} else {
|
||||
echo "<br /><span style='color:red'>".Text::_('COM_JEM_NO_WEBP_SUPPORT')."</span>";
|
||||
}
|
||||
?>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</fieldset>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<?php if($this->jemsettings->gddisabled) { ?>
|
||||
|
||||
<table class="noshow">
|
||||
<tr>
|
||||
<td>
|
||||
|
||||
<fieldset class="adminform">
|
||||
<legend><?php echo Text::_('COM_JEM_ATTENTION'); ?></legend>
|
||||
<table class="admintable">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td class="center">
|
||||
<?php echo Text::_('COM_JEM_GD_WARNING'); ?>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</fieldset>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<?php } ?>
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
<input type="hidden" name="option" value="com_jem" />
|
||||
<input type="hidden" name="task" value="<?php echo $this->task;?>" />
|
||||
</form>
|
||||
|
||||
<p class="copyright">
|
||||
<?php echo JEMAdmin::footer(); ?>
|
||||
</p>
|
||||
@ -0,0 +1,137 @@
|
||||
<?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\Uri\Uri;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Client\ClientHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\MVC\View\HtmlView;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Object\CMSObject;
|
||||
|
||||
/**
|
||||
* View class for the JEM imageselect screen
|
||||
* Based on the Joomla! media component
|
||||
*
|
||||
* @package JEM
|
||||
*
|
||||
*/
|
||||
class JemViewImagehandler extends HtmlView
|
||||
{
|
||||
|
||||
/**
|
||||
* Image selection List
|
||||
*/
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$app = Factory::getApplication();
|
||||
$option = $app->input->getString('option', 'com_jem');
|
||||
|
||||
if ($this->getLayout() == 'uploadimage') {
|
||||
$this->_displayuploadimage($tpl);
|
||||
return;
|
||||
}
|
||||
|
||||
//get vars
|
||||
$task = $app->input->get('task', '');
|
||||
$search = $app->getUserStateFromRequest($option.'.filter_search', 'filter_search', '', 'string');
|
||||
$search = trim(\Joomla\String\StringHelper::strtolower($search));
|
||||
|
||||
//set variables
|
||||
if ($task == 'selecteventimg') {
|
||||
$folder = 'events';
|
||||
$task = 'eventimg';
|
||||
$redi = 'selecteventimg';
|
||||
} elseif ($task == 'selectvenueimg') {
|
||||
$folder = 'venues';
|
||||
$task = 'venueimg';
|
||||
$redi = 'selectvenueimg';
|
||||
} elseif ($task == 'selectcategoriesimg') {
|
||||
$folder = 'categories';
|
||||
$task = 'categoriesimg';
|
||||
$redi = 'selectcategoriesimg';
|
||||
}
|
||||
|
||||
$app->input->set('folder', $folder);
|
||||
|
||||
// Do not allow cache
|
||||
$app->allowCache(false);
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
//get images
|
||||
$images = $this->get('images');
|
||||
$pagination = $this->get('Pagination');
|
||||
|
||||
if ($search || (is_array($images) && (count($images) > 0))) {
|
||||
$this->images = $images;
|
||||
$this->folder = $folder;
|
||||
$this->task = $redi;
|
||||
$this->search = $search;
|
||||
$this->state = $this->get('state');
|
||||
$this->pagination = $pagination;
|
||||
parent::display($tpl);
|
||||
} else {
|
||||
//no images in the folder, redirect to uploadscreen and raise notice
|
||||
Factory::getApplication()->enqueueMessage(Text::_('COM_JEM_NO_IMAGES_AVAILABLE'), 'notice');
|
||||
$this->setLayout('uploadimage');
|
||||
$app->input->set('task', $task);
|
||||
$this->_displayuploadimage($tpl);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
public function setImage($index = 0)
|
||||
{
|
||||
if (isset($this->images[$index])) {
|
||||
$this->_tmp_img = $this->images[$index];
|
||||
} else {
|
||||
$this->_tmp_img = new CMSObject;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Prepares the upload image screen
|
||||
*
|
||||
* @param $tpl
|
||||
*
|
||||
*/
|
||||
protected function _displayuploadimage($tpl = null)
|
||||
{
|
||||
//initialise variables
|
||||
$uri =Uri::getInstance();
|
||||
$uri = $uri->toString();
|
||||
$jemsettings = JemAdmin::config();
|
||||
|
||||
//get vars
|
||||
$task = Factory::getApplication()->input->get('task', '');
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
$ftp = ClientHelper::setCredentialsFromRequest('ftp');
|
||||
|
||||
//assign data to template
|
||||
$this->task = $task;
|
||||
$this->jemsettings = $jemsettings;
|
||||
$this->request_url = $uri;
|
||||
$this->ftp = $ftp;
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
}
|
||||
?>
|
||||
1
administrator/components/com_jem/views/import/index.html
Normal file
1
administrator/components/com_jem/views/import/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
121
administrator/components/com_jem/views/import/tmpl/default.php
Normal file
121
administrator/components/com_jem/views/import/tmpl/default.php
Normal file
@ -0,0 +1,121 @@
|
||||
<?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;
|
||||
|
||||
?>
|
||||
<?php if($this->progress->step > 1) : ?>
|
||||
<meta http-equiv="refresh" content="1; url=index.php?option=com_jem&view=import&task=import.eventlistimport&step=<?php
|
||||
echo $this->progress->step; ?>&table=<?php echo $this->progress->table; ?>&current=<?php
|
||||
echo $this->progress->current; ?>&total=<?php echo $this->progress->total; ?>" />
|
||||
<?php endif; ?>
|
||||
|
||||
<?php if (isset($this->sidebar)) : ?>
|
||||
<div id="j-sidebar-container" class="span2">
|
||||
<?php echo $this->sidebar; ?>
|
||||
</div>
|
||||
<div id="j-main-container" class="span10">
|
||||
<?php endif; ?>
|
||||
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<form action="index.php" method="post" name="adminForm" enctype="multipart/form-data" id="adminForm">
|
||||
<div>
|
||||
<strong><?php echo Text::_('COM_JEM_IMPORT_INSTRUCTIONS') ?></strong><br /><br />
|
||||
<?php echo Text::_("COM_JEM_IMPORT_INSTRUCTIONS_DESC"); ?><br />
|
||||
<?php echo Text::_("COM_JEM_IMPORT_COLUMNNAMESVENUES"); ?><br />
|
||||
<?php echo Text::_("COM_JEM_IMPORT_FIRSTROW"); ?><br />
|
||||
</div>
|
||||
<hr />
|
||||
<div>
|
||||
<fieldset class="adminform">
|
||||
<legend><strong><?php echo mb_strtoupper(Text::_('COM_JEM_IMPORT_VENUES'));?></strong></legend>
|
||||
<?php echo Text::_("COM_JEM_IMPORT_VENUES_DESC"); ?><br />
|
||||
<a onclick="return showblock(this);" class="import-fieldinfo"> <?php echo Text::_("COM_JEM_IMPORT_SHOW_VENUE_COLUMNS");?></a><div style="display: none;"><div style="background-color:silver;border:1px solid #808080"><?php echo implode(", ",$this->venuefields); ?></div></div><br />
|
||||
|
||||
<div style="display:inline-block"><label for="replace_venues"><?php echo Text::_('COM_JEM_IMPORT_REPLACEIFEXISTS').':'; ?></label></div>
|
||||
<div style="display:inline-block"><?php echo HTMLHelper::_('select.booleanlist', 'replace_venues', 'class="inputbox"', 0); ?></div><br/><br />
|
||||
|
||||
<label for="file"><?php echo Text::_('COM_JEM_IMPORT_SELECTCSV').':'; ?></label>
|
||||
<input type="file" id="venue-file-upload" accept="text/*" name="Filevenues" />
|
||||
<input type="submit" id="venue-file-upload-submit" value="<?php echo Text::_('COM_JEM_IMPORT_START'); ?>" onclick="document.getElementById('task1').value='import.csvvenuesimport';return true;"/>
|
||||
</fieldset>
|
||||
</div>
|
||||
<hr />
|
||||
<div>
|
||||
<fieldset class="adminform">
|
||||
<legend><strong><?php echo mb_strtoupper(Text::_('COM_JEM_IMPORT_CATEGORIES'));?></strong></legend>
|
||||
<?php echo Text::_("COM_JEM_IMPORT_CATEGORIES_DESC"); ?><br />
|
||||
<a onclick="return showblock(this);" class="import-fieldinfo"> <?php echo Text::_("COM_JEM_IMPORT_SHOW_CATEGORY_COLUMNS");?></a><div style="display: none;"><div style="background-color:silver;border:1px solid #808080"><?php echo implode(", ",$this->catfields); ?></div></div><br />
|
||||
|
||||
<div style="display:inline-block"><label for="replace_categories"><?php echo Text::_('COM_JEM_IMPORT_REPLACEIFEXISTS').':'; ?></label></div>
|
||||
<div style="display:inline-block"><?php echo HTMLHelper::_('select.booleanlist', 'replace_categories', 'class="inputbox"', 0); ?></div><br/><br />
|
||||
|
||||
<label for="file"><?php echo Text::_('COM_JEM_IMPORT_SELECTCSV').':'; ?></label>
|
||||
<input type="file" id="cat-file-upload" accept="text/*" name="Filecategories" />
|
||||
<input type="submit" id="cat-file-upload-submit" value="<?php echo Text::_('COM_JEM_IMPORT_START'); ?>" onclick="document.getElementById('task1').value='import.csvcategoriesimport';return true;"/>
|
||||
|
||||
</fieldset>
|
||||
<div class="clr"></div>
|
||||
</div>
|
||||
<hr />
|
||||
<div>
|
||||
<fieldset class="adminform">
|
||||
<legend><strong><?php echo mb_strtoupper(Text::_('COM_JEM_IMPORT_EVENTS'));?></strong></legend>
|
||||
<?php echo Text::_("COM_JEM_IMPORT_EVENTS_DESC"); ?><br />
|
||||
<a onclick="return showblock(this);" class="import-fieldinfo"> <?php echo Text::_("COM_JEM_IMPORT_SHOW_EVENT_COLUMNS");?></a><div style="display: none;"><div style="background-color:silver;border:1px solid #808080"><?php echo implode(", ",$this->eventfields) . ',categories'; ?></div></div><br />
|
||||
|
||||
<div style="display:inline-block"><label for="replace_events"><?php echo Text::_('COM_JEM_IMPORT_REPLACEIFEXISTS').':'; ?></label></div>
|
||||
<div style="display:inline-block"><?php echo HTMLHelper::_('select.booleanlist', 'replace_events', 'class="inputbox"', 0); ?></div><br /><br/>
|
||||
|
||||
<label for="file"><?php echo Text::_('COM_JEM_IMPORT_SELECTCSV').':'; ?></label>
|
||||
<input type="file" id="event-file-upload" accept="text/*" name="Fileevents" />
|
||||
<input type="submit" id="event-file-upload-submit" value="<?php echo Text::_('COM_JEM_IMPORT_START'); ?>" onclick="document.getElementById('task1').value='import.csveventimport';return true;"/>
|
||||
</fieldset>
|
||||
<div class="clr"></div>
|
||||
</div>
|
||||
<hr />
|
||||
<div>
|
||||
<fieldset class="adminform">
|
||||
<legend><strong><?php echo mb_strtoupper(Text::_('COM_JEM_IMPORT_CAT_EVENTS'));?></strong></legend>
|
||||
<?php echo Text::_("COM_JEM_IMPORT_CAT_EVENTS_DESC"); ?><br />
|
||||
<a onclick="return showblock(this);" class="import-fieldinfo"> <?php echo Text::_("COM_JEM_IMPORT_SHOW_CATEVENT_COLUMNS");?></a><div style="display: none;"><div style="background-color:silver;border:1px solid #808080"><?php echo implode(", ",$this->cateventsfields); ?></div></div><br />
|
||||
|
||||
<div style="display:inline-block"><label for="replace_catevents"><?php echo Text::_('COM_JEM_IMPORT_REPLACEIFEXISTS').':'; ?></label></div>
|
||||
<div style="display:inline-block"><?php echo HTMLHelper::_('select.booleanlist', 'replace_catevents', 'class="inputbox"', 0); ?></div><br /><br/>
|
||||
|
||||
<label for="file"><?php echo Text::_('COM_JEM_IMPORT_SELECTCSV').':'; ?></label>
|
||||
<input type="file" id="catevents-file-upload" accept="text/*" name="Filecatevents" />
|
||||
<input type="submit" id="catevents-file-upload-submit" value="<?php echo Text::_('COM_JEM_IMPORT_START'); ?>" onclick="document.getElementById('task1').value='import.csvcateventsimport';return true;"/>
|
||||
</fieldset>
|
||||
<div class="clr"></div>
|
||||
</div>
|
||||
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
<input type="hidden" name="option" value="com_jem" />
|
||||
<input type="hidden" name="view" value="import" />
|
||||
<input type="hidden" name="controller" value="import" />
|
||||
<input type="hidden" name="task" id="task1" value="" />
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type='text/JavaScript'>
|
||||
function showblock(blockcontent) {
|
||||
var c=blockcontent.nextSibling;
|
||||
if(c.style.display=='none') {
|
||||
c.style.display='block';
|
||||
} else {
|
||||
c.style.display='none';
|
||||
}
|
||||
return false;
|
||||
}
|
||||
</script>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
92
administrator/components/com_jem/views/import/view.html.php
Normal file
92
administrator/components/com_jem/views/import/view.html.php
Normal file
@ -0,0 +1,92 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Factory;
|
||||
/**
|
||||
* View class for the JEM import screen
|
||||
*
|
||||
* @package JEM
|
||||
*
|
||||
*/
|
||||
|
||||
//Load pane behavior
|
||||
jimport('joomla.html.pane');
|
||||
|
||||
class JemViewImport extends JemAdminView
|
||||
{
|
||||
|
||||
public function display($tpl = null) {
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
// Get data from the model
|
||||
$eventfields = $this->get('EventFields');
|
||||
$catfields = $this->get('CategoryFields');
|
||||
$venuefields = $this->get('VenueFields');
|
||||
$cateventsfields = $this->get('CateventsFields');
|
||||
|
||||
//assign vars to the template
|
||||
$this->eventfields = $eventfields;
|
||||
$this->catfields = $catfields;
|
||||
$this->venuefields = $venuefields;
|
||||
$this->cateventsfields = $cateventsfields;
|
||||
|
||||
$this->eventlistVersion = $this->get('EventlistVersion');
|
||||
$this->eventlistTables = $this->get('EventlistTablesCount');
|
||||
$this->jemTables = $this->get('JemTablesCount');
|
||||
$this->existingJemData = $this->get('ExistingJemData');
|
||||
|
||||
$app = Factory::getApplication();
|
||||
$jinput = $app->input;
|
||||
$progress = new stdClass();
|
||||
$progress->step = $jinput->get('step', 0, 'INT');
|
||||
$progress->current = $jinput->get('current', 0, 'INT');
|
||||
$progress->total = $jinput->get('total', 0, 'INT');
|
||||
$progress->table = $jinput->get('table', '', 'INT');
|
||||
$progress->prefix = $jinput->get('prefix', null, 'CMD');
|
||||
$progress->copyImages = $jinput->get('copyImages', null, 'INT');
|
||||
$progress->copyAttachments = $jinput->get('copyAttachments', null, 'INT');
|
||||
$progress->fromJ15 = $jinput->get('fromJ15', null, 'INT');
|
||||
$this->progress = $progress;
|
||||
$this->attachmentsPossible = !empty($this->eventlistTables['eventlist_attachments']);
|
||||
|
||||
// Do not show default prefix #__ but its replacement value
|
||||
$this->prefixToShow = $progress->prefix;
|
||||
if (empty($this->prefixToShow) || $this->prefixToShow == "#__") {
|
||||
$this->prefixToShow = $app->get('dbprefix');
|
||||
}
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_IMPORT'), 'tableimport');
|
||||
|
||||
ToolbarHelper::back();
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::inlinehelp();
|
||||
ToolBarHelper::help('import', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/control-panel/import-data');
|
||||
}
|
||||
}
|
||||
?>
|
||||
1
administrator/components/com_jem/views/index.html
Normal file
1
administrator/components/com_jem/views/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
BIN
administrator/components/com_jem/views/main/07affiche_A3.pdf
Normal file
BIN
administrator/components/com_jem/views/main/07affiche_A3.pdf
Normal file
Binary file not shown.
1
administrator/components/com_jem/views/main/index.html
Normal file
1
administrator/components/com_jem/views/main/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
226
administrator/components/com_jem/views/main/tmpl/default.php
Normal file
226
administrator/components/com_jem/views/main/tmpl/default.php
Normal file
@ -0,0 +1,226 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Router\Route;
|
||||
|
||||
$options = array(
|
||||
'onActive' => 'function(title, description){
|
||||
description.setStyle("display", "block");
|
||||
title.addClass("open").removeClass("closed");
|
||||
}',
|
||||
'onBackground' => 'function(title, description){
|
||||
description.setStyle("display", "none");
|
||||
title.addClass("closed").removeClass("open");
|
||||
}',
|
||||
'startOffset' => 0, // 0 starts on the first tab, 1 starts the second, etc...
|
||||
'useCookie' => true, // this must not be a string. Don't use quotes.
|
||||
);
|
||||
|
||||
?>
|
||||
<style>
|
||||
.jem-wei-menus .card{
|
||||
min-height: 126px;
|
||||
}
|
||||
.jem-wei-menus .card-body div:first-child{
|
||||
float:none !important;
|
||||
}
|
||||
.jem-wei-menus .icon{
|
||||
text-align:center;
|
||||
}
|
||||
.jem-wei-menus .icon a{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
</style>
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem');?>" id="application-form" method="post" name="adminForm" class="form-validate">
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
<table style="width:100%">
|
||||
<tr>
|
||||
<td valign="top">
|
||||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
<div class="cpanel jem-wei-menus">
|
||||
<?php
|
||||
$link = 'index.php?option=com_jem&view=events';
|
||||
$this->quickiconButton($link, 'icon-48-events.png', Text::_('COM_JEM_EVENTS'));
|
||||
|
||||
$link = 'index.php?option=com_jem&task=event.add';
|
||||
$this->quickiconButton($link, 'icon-48-eventedit.png', Text::_('COM_JEM_ADD_EVENT'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=venues';
|
||||
$this->quickiconButton($link, 'icon-48-venues.png', Text::_('COM_JEM_VENUES'));
|
||||
|
||||
$link = 'index.php?option=com_jem&task=venue.add';
|
||||
$this->quickiconButton($link, 'icon-48-venuesedit.png', Text::_('COM_JEM_ADD_VENUE'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=categories';
|
||||
$this->quickiconButton($link, 'icon-48-categories.png', Text::_('COM_JEM_CATEGORIES'));
|
||||
|
||||
$link = 'index.php?option=com_jem&task=category.add';
|
||||
$this->quickiconButton($link, 'icon-48-categoriesedit.png', Text::_('COM_JEM_ADD_CATEGORY'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=groups';
|
||||
$this->quickiconButton($link, 'icon-48-groups.png', Text::_('COM_JEM_GROUPS'));
|
||||
|
||||
$link = 'index.php?option=com_jem&task=group.add';
|
||||
$this->quickiconButton($link, 'icon-48-groupedit.png', Text::_('COM_JEM_GROUP_ADD'));
|
||||
|
||||
$link = 'index.php?option=com_jem&task=plugins.plugins';
|
||||
$this->quickiconButton($link, 'icon-48-plugins.png', Text::_('COM_JEM_MANAGE_PLUGINS'));
|
||||
|
||||
//only admins should be able to see these items
|
||||
if (JemFactory::getUser()->authorise('core.manage', 'com_jem')) {
|
||||
$link = 'index.php?option=com_jem&view=settings';
|
||||
$this->quickiconButton($link, 'icon-48-settings.png', Text::_('COM_JEM_SETTINGS_TITLE'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=housekeeping';
|
||||
$this->quickiconButton($link, 'icon-48-housekeeping.png', Text::_('COM_JEM_HOUSEKEEPING'));
|
||||
|
||||
$link = 'index.php?option=com_jem&task=sampledata.load';
|
||||
$this->quickiconButton($link, 'icon-48-sampledata.png', Text::_('COM_JEM_MAIN_LOAD_SAMPLE_DATA'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=updatecheck';
|
||||
$this->quickiconButton($link, 'icon-48-update.png', Text::_('COM_JEM_UPDATECHECK_TITLE'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=import';
|
||||
$this->quickiconButton($link, 'icon-48-tableimport.png', Text::_('COM_JEM_IMPORT_DATA'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=export';
|
||||
$this->quickiconButton($link, 'icon-48-tableexport.png', Text::_('COM_JEM_EXPORT_DATA'));
|
||||
|
||||
$link = 'index.php?option=com_jem&view=cssmanager';
|
||||
$this->quickiconButton( $link, 'icon-48-cssmanager.png', Text::_( 'COM_JEM_CSSMANAGER_TITLE' ) );
|
||||
}
|
||||
|
||||
$link = 'index.php?option=com_jem&view=help';
|
||||
$this->quickiconButton($link, 'icon-48-help.png', Text::_('COM_JEM_HELP'));
|
||||
?>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</td>
|
||||
<td valign="top" width="320px" style="padding: 7px 0 0 18px">
|
||||
|
||||
<div class="accordion" id="accordion_jem">
|
||||
<?php //echo HTMLHelper::_('sliders.start','stat-pane',$options); ?>
|
||||
<?php //echo HTMLHelper::_('sliders.panel', Text::_('COM_JEM_MAIN_EVENT_STATS'),'events'); ?>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="clsp_events_header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#clsp_events" aria-expanded="true" aria-controls="clsp_events">
|
||||
<?php echo Text::_('COM_JEM_MAIN_EVENT_STATS'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="clsp_events" class="accordion-collapse collapse show" aria-labelledby="clsp_events_header" data-bs-parent="#accordion_jem">
|
||||
<div class="accordion-body">
|
||||
<table class="adminlist">
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_EVENTS_PUBLISHED').': '; ?></td>
|
||||
<td><b><?php echo $this->events->published; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_EVENTS_UNPUBLISHED').': '; ?></td>
|
||||
<td><b><?php echo $this->events->unpublished; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_EVENTS_ARCHIVED').': '; ?> </td>
|
||||
<td><b><?php echo $this->events->archived; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_EVENTS_TRASHED').': '; ?></td>
|
||||
<td><b><?php echo $this->events->trashed; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_EVENTS_TOTAL').': '; ?></td>
|
||||
<td><b><?php echo $this->events->total; ?> </b></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="clsp_venues_header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#clsp_venues" aria-expanded="true" aria-controls="clsp_venues">
|
||||
<?php echo Text::_('COM_JEM_MAIN_VENUE_STATS'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="clsp_venues" class="accordion-collapse collapse" aria-labelledby="clsp_venues_header" data-bs-parent="#accordion_jem">
|
||||
<div class="accordion-body">
|
||||
<table class="adminlist">
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_VENUES_PUBLISHED').': '; ?></td>
|
||||
<td><b><?php echo $this->venue->published; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_VENUES_UNPUBLISHED').': '; ?></td>
|
||||
<td><b><?php echo $this->venue->unpublished; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_VENUES_TOTAL').': '; ?></td>
|
||||
<td><b><?php echo $this->venue->total; ?> </b></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="accordion-item">
|
||||
<h2 class="accordion-header" id="clsp_categories_header">
|
||||
<button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#clsp_categories" aria-expanded="true" aria-controls="clsp_categories">
|
||||
<?php echo Text::_('COM_JEM_MAIN_CATEGORY_STATS'); ?>
|
||||
</button>
|
||||
</h2>
|
||||
<div id="clsp_categories" class="accordion-collapse collapse" aria-labelledby="clsp_categories_header" data-bs-parent="#accordion_jem">
|
||||
<div class="accordion-body">
|
||||
<table class="adminlist" >
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CATEGORIES_PUBLISHED').': '; ?></td>
|
||||
<td><b><?php echo $this->category->published; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CATEGORIES_UNPUBLISHED').': '; ?></td>
|
||||
<td><b><?php echo $this->category->unpublished; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CATEGORIES_ARCHIVED').': '; ?></td>
|
||||
<td><b><?php echo $this->category->archived; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CATEGORIES_TRASHED').': '; ?></td>
|
||||
<td><b><?php echo $this->category->trashed; ?> </b></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CATEGORIES_TOTAL').': '; ?></td>
|
||||
<td><b><?php echo $this->category->total; ?> </b></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php //echo HTMLHelper::_('sliders.end'); ?>
|
||||
<h3 class="title mt-4"><?php echo Text::_('COM_JEM_MAIN_DONATE'); ?></h3>
|
||||
<div class="content">
|
||||
<?php echo Text::_('COM_JEM_MAIN_DONATE_TEXT'); ?> <br><br>
|
||||
<div class="center">
|
||||
<a href="https://www.joomlaeventmanager.net/project/donate" target="_blank">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/PayPal_DonateButton.png', Text::_('COM_JEM_MAIN_DONATE'), NULL, true); ?>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</form>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
104
administrator/components/com_jem/views/main/view.html.php
Normal file
104
administrator/components/com_jem/views/main/view.html.php
Normal file
@ -0,0 +1,104 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
|
||||
/**
|
||||
* View class for the JEM home screen
|
||||
*
|
||||
* @package JEM
|
||||
*/
|
||||
class JemViewMain extends JemAdminView
|
||||
{
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
//Load pane behavior
|
||||
jimport('joomla.html.pane');
|
||||
|
||||
//initialise variables
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$user = JemFactory::getUser();
|
||||
|
||||
// Get data from the model
|
||||
$events = $this->get('EventsData');
|
||||
$venue = $this->get('VenuesData');
|
||||
$category = $this->get('CategoriesData');
|
||||
|
||||
// Load css
|
||||
// HTMLHelper::_('stylesheet', 'com_jem/backend.css', array(), true);
|
||||
$wa = Factory::getApplication()->getDocument()->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
|
||||
//assign vars to the template
|
||||
$this->events = $events;
|
||||
$this->venue = $venue;
|
||||
$this->category = $category;
|
||||
$this->user = $user;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add Toolbar
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_MAIN_TITLE'), 'home');
|
||||
|
||||
if (JemFactory::getUser()->authorise('core.manage', 'com_jem')) {
|
||||
ToolbarHelper::preferences('com_jem');
|
||||
}
|
||||
|
||||
ToolBarHelper::divider();
|
||||
ToolBarHelper::help('listevents', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/control-panel');
|
||||
}
|
||||
|
||||
/**
|
||||
* Creates the buttons view
|
||||
*
|
||||
* @param string $link targeturl
|
||||
* @param string $image path to image
|
||||
* @param string $text image description
|
||||
* @param boolean $modal 1 for loading in modal
|
||||
*/
|
||||
protected function quickiconButton($link, $image, $text, $modal = 0)
|
||||
{
|
||||
// Initialise variables
|
||||
$lang = Factory::getApplication()->getLanguage();
|
||||
?>
|
||||
<div style="float:<?php echo ($lang->isRTL()) ? 'right' : 'left'; ?>;">
|
||||
<div class="icon">
|
||||
<?php if ($modal == 1) : ?>
|
||||
<a href="<?php echo $link.'&tmpl=component'; ?>" style="cursor:pointer" class="modal"
|
||||
rel="{handler: 'iframe', size: {x: 650, y: 400}}">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/'.$image, $text, NULL, true); ?>
|
||||
<span><?php echo $text; ?></span>
|
||||
</a>
|
||||
<?php else : ?>
|
||||
<a href="<?php echo $link; ?>">
|
||||
<?php echo HTMLHelper::_('image', 'com_jem/'.$image, $text, NULL, true); ?>
|
||||
<span><?php echo $text; ?></span>
|
||||
</a>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
</div>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
497
administrator/components/com_jem/views/settings/tmpl/default.php
Normal file
497
administrator/components/com_jem/views/settings/tmpl/default.php
Normal file
@ -0,0 +1,497 @@
|
||||
<?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
|
||||
*
|
||||
* * @todo: move js to a file
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
use Joomla\CMS\Router\Route;
|
||||
use Joomla\CMS\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
$wa = $this->document->getWebAssetManager();
|
||||
$wa
|
||||
->useScript('keepalive')
|
||||
->useStyle('jem.colorpicker')
|
||||
->useScript('inlinehelp')
|
||||
->useScript('form.validate');
|
||||
?>
|
||||
|
||||
<script>
|
||||
jQuery(document).ready(function($){
|
||||
$('#jform_showcity0').bind('click', cityon);
|
||||
$('#jform_showcity1').bind('click', cityoff);
|
||||
|
||||
if($('#jform_showcity0').checked) {
|
||||
cityon();
|
||||
}
|
||||
|
||||
$('#jform_showatte0').bind('click', atteon);
|
||||
$('#jform_showatte1').bind('click', atteoff);
|
||||
|
||||
if($('#jform_showatte0').checked) {
|
||||
atteon();
|
||||
}
|
||||
|
||||
$('#jform_showtitle0').bind('click', titleon);
|
||||
$('#jform_showtitle1').bind('click', titleoff);
|
||||
|
||||
if(document.getElementById('jform_showtitle0').checked) {
|
||||
titleon();
|
||||
}
|
||||
|
||||
$('#jform_showlocate0').bind('click', locon);
|
||||
$('#jform_showlocate1').bind('click', locoff);
|
||||
|
||||
if(document.getElementById('jform_showlocate0').checked) {
|
||||
locon();
|
||||
}
|
||||
|
||||
$('#jform_showstate0').bind('click', stateon);
|
||||
$('#jform_showstate1').bind('click', stateoff);
|
||||
|
||||
if(document.getElementById('jform_showstate0').checked) {
|
||||
stateon();
|
||||
}
|
||||
|
||||
$('#jform_showcat0').bind('click', caton);
|
||||
$('#jform_showcat1').bind('click', catoff);
|
||||
|
||||
if(document.getElementById('jform_showcat0').checked) {
|
||||
caton();
|
||||
}
|
||||
|
||||
$('#jform_showeventimage0').bind('click', evimageon);
|
||||
$('#jform_showeventimage1').bind('click', evimageoff);
|
||||
|
||||
if(document.getElementById('jform_showeventimage0').checked) {
|
||||
evimageon();
|
||||
}
|
||||
|
||||
$('#jform_gddisabled0').bind('click', lbon);
|
||||
$('#jform_gddisabled1').bind('click', lboff);
|
||||
|
||||
if(document.getElementById('jform_gddisabled0').checked) {
|
||||
lbon();
|
||||
}
|
||||
|
||||
$("#jform_globalattribs_event_show_mapserv").bind('change', testmap);
|
||||
|
||||
var mapserv = document.getElementById("jform_globalattribs_event_show_mapserv");
|
||||
var nrmapserv = mapserv.options[mapserv.selectedIndex].value;
|
||||
|
||||
if (nrmapserv == 1 || nrmapserv == 2) {
|
||||
eventmapon();
|
||||
} else {
|
||||
eventmapoff();
|
||||
}
|
||||
|
||||
|
||||
$("#jform_globalattribs_global_show_mapserv").bind('change', testmap);
|
||||
|
||||
var mapserv = document.getElementById("jform_globalattribs_global_show_mapserv");
|
||||
var nrmapserv = mapserv.options[mapserv.selectedIndex].value;
|
||||
|
||||
if (nrmapserv == 1 || nrmapserv == 2) {
|
||||
globalmapon();
|
||||
} else {
|
||||
globalmapoff();
|
||||
}
|
||||
|
||||
$("#jform_oldevent").bind('change', testevhandler);
|
||||
|
||||
var evhandler = document.getElementById("jform_oldevent");
|
||||
var nrevhandler = evhandler.options[evhandler.selectedIndex].value;
|
||||
|
||||
if (nrevhandler > 0) {
|
||||
evhandleron();
|
||||
} else {
|
||||
evhandleroff();
|
||||
}
|
||||
|
||||
$('#jform_globalattribs_event_comunsolution').bind('change', testcomm);
|
||||
|
||||
var commhandler = document.getElementById("jform_globalattribs_event_comunsolution");
|
||||
var nrcommhandler = commhandler.options[commhandler.selectedIndex].value;
|
||||
|
||||
if (nrcommhandler == 1) {
|
||||
common();
|
||||
} else {
|
||||
commoff();
|
||||
}
|
||||
|
||||
var ObjArray = $('input.colorpicker').get('id').sort();
|
||||
|
||||
var arrayLength = ObjArray.length;
|
||||
for (var i = 0; i < arrayLength; i++) {
|
||||
var Obj = $(ObjArray[i]);
|
||||
var color = testcolor(Obj.value);
|
||||
if (color) {
|
||||
Obj.style.color = color;
|
||||
}
|
||||
}
|
||||
|
||||
$("#jform_showfroregistra").bind('change', testregistra);
|
||||
|
||||
var registra = document.getElementById("jform_showfroregistra");
|
||||
var nrregistra = registra.options[registra.selectedIndex].value;
|
||||
|
||||
if (nrregistra >= 1) {
|
||||
registraon();
|
||||
} else {
|
||||
registraoff();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
function testcolor(color) {
|
||||
if(color.length==7)
|
||||
{
|
||||
color=color.substring(1);
|
||||
}
|
||||
var R = parseInt(color.substring(0,2),16);
|
||||
var G = parseInt(color.substring(2,4),16);
|
||||
var B = parseInt(color.substring(4,6),16);
|
||||
var x = Math.sqrt(R * R * .299 + G * G * .587 + B * B * .114);
|
||||
|
||||
var sColorText = x < 130 ? '#FFFFFF' : '#000000';
|
||||
|
||||
return sColorText;
|
||||
}
|
||||
|
||||
function testcomm()
|
||||
{
|
||||
var commhandler = document.getElementById("jform_globalattribs_event_comunsolution");
|
||||
var nrcommhandler = commhandler.options[commhandler.selectedIndex].value;
|
||||
|
||||
if (nrcommhandler == 1) {
|
||||
common();
|
||||
} else {
|
||||
commoff();
|
||||
}
|
||||
}
|
||||
|
||||
function testmap()
|
||||
{
|
||||
var mapserv = document.getElementById("jform_globalattribs_event_show_mapserv");
|
||||
var nrmapserv = mapserv.options[mapserv.selectedIndex].value;
|
||||
|
||||
if (nrmapserv == 1 || nrmapserv == 2) {
|
||||
eventmapon();
|
||||
} else {
|
||||
eventmapoff();
|
||||
}
|
||||
|
||||
var mapserv2 = document.getElementById("jform_globalattribs_global_show_mapserv");
|
||||
var nrmapserv2 = mapserv2.options[mapserv2.selectedIndex].value;
|
||||
|
||||
if (nrmapserv2 == 1 || nrmapserv2 == 2) {
|
||||
globalmapon();
|
||||
} else {
|
||||
globalmapoff();
|
||||
}
|
||||
}
|
||||
|
||||
function testevhandler()
|
||||
{
|
||||
var evhandler = document.getElementById("jform_oldevent");
|
||||
var nrevhandler = evhandler.options[evhandler.selectedIndex].value;
|
||||
|
||||
if (nrevhandler > 0) {
|
||||
evhandleron();
|
||||
} else {
|
||||
evhandleroff();
|
||||
}
|
||||
}
|
||||
|
||||
function testregistra()
|
||||
{
|
||||
var registra = document.getElementById("jform_showfroregistra");
|
||||
var nrregistra = registra.options[registra.selectedIndex].value;
|
||||
|
||||
if (nrregistra >= 1) {
|
||||
registraon();
|
||||
} else {
|
||||
registraoff();
|
||||
}
|
||||
}
|
||||
|
||||
function cityon()
|
||||
{
|
||||
document.getElementById('city1').style.display = '';
|
||||
}
|
||||
|
||||
function cityoff()
|
||||
{
|
||||
var citywidth = document.getElementById('jform_citywidth');
|
||||
document.getElementById('city1').style.display = 'none';
|
||||
citywidth.value='';
|
||||
}
|
||||
|
||||
function atteon()
|
||||
{
|
||||
document.getElementById('atte1').style.display = '';
|
||||
}
|
||||
|
||||
function atteoff()
|
||||
{
|
||||
var attewidth = document.getElementById('jform_attewidth');
|
||||
document.getElementById('atte1').style.display = 'none';
|
||||
attewidth.value='';
|
||||
}
|
||||
|
||||
function titleon()
|
||||
{
|
||||
document.getElementById('title1').style.display = '';
|
||||
}
|
||||
|
||||
function titleoff()
|
||||
{
|
||||
var titlewidth = document.getElementById('jform_titlewidth');
|
||||
document.getElementById('title1').style.display = 'none';
|
||||
titlewidth.value='';
|
||||
}
|
||||
|
||||
function locon()
|
||||
{
|
||||
document.getElementById('loc1').style.display = '';
|
||||
document.getElementById('loc2').style.display = '';
|
||||
}
|
||||
|
||||
function locoff()
|
||||
{
|
||||
var locatewidth = document.getElementById('jform_locationwidth');
|
||||
document.getElementById('loc1').style.display = 'none';
|
||||
locatewidth.value='';
|
||||
document.getElementById('loc2').style.display = 'none';
|
||||
}
|
||||
|
||||
function stateon()
|
||||
{
|
||||
document.getElementById('state1').style.display = '';
|
||||
}
|
||||
|
||||
function stateoff()
|
||||
{
|
||||
var statewidth = document.getElementById('jform_statewidth');
|
||||
document.getElementById('state1').style.display = 'none';
|
||||
statewidth.value='';
|
||||
}
|
||||
|
||||
function caton()
|
||||
{
|
||||
document.getElementById('cat1').style.display = '';
|
||||
document.getElementById('cat2').style.display = '';
|
||||
}
|
||||
|
||||
function catoff()
|
||||
{
|
||||
var catwidth = document.getElementById('jform_catfrowidth');
|
||||
document.getElementById('cat1').style.display = 'none';
|
||||
catwidth.value='';
|
||||
document.getElementById('cat2').style.display = 'none';
|
||||
}
|
||||
|
||||
function evimageon()
|
||||
{
|
||||
document.getElementById('evimage1').style.display = '';
|
||||
}
|
||||
|
||||
function evimageoff()
|
||||
{
|
||||
var evimagewidth = document.getElementById('jform_tableeventimagewidth');
|
||||
document.getElementById('evimage1').style.display = 'none';
|
||||
evimagewidth.value='';
|
||||
}
|
||||
|
||||
function lbon()
|
||||
{
|
||||
document.getElementById('lb1').style.display = '';
|
||||
}
|
||||
|
||||
function lboff()
|
||||
{
|
||||
document.getElementById('lb1').style.display = 'none';
|
||||
}
|
||||
|
||||
function eventmapon()
|
||||
{
|
||||
document.getElementById('eventmap1').style.display = '';
|
||||
document.getElementById('eventmap2').style.display = '';
|
||||
}
|
||||
|
||||
function eventmapoff()
|
||||
{
|
||||
document.getElementById('eventmap1').style.display = 'none';
|
||||
document.getElementById('eventmap2').style.display = 'none';
|
||||
document.getElementById('jform_globalattribs_event_tld').value = '';
|
||||
document.getElementById('jform_globalattribs_event_lg').value = '';
|
||||
}
|
||||
|
||||
function globalmapon()
|
||||
{
|
||||
document.getElementById('globalmap1').style.display = '';
|
||||
document.getElementById('globalmap2').style.display = '';
|
||||
}
|
||||
|
||||
function globalmapoff()
|
||||
{
|
||||
document.getElementById('globalmap1').style.display = 'none';
|
||||
document.getElementById('globalmap2').style.display = 'none';
|
||||
document.getElementById('jform_globalattribs_global_tld').value = '';
|
||||
document.getElementById('jform_globalattribs_global_lg').value = '';
|
||||
}
|
||||
|
||||
|
||||
function evhandleron()
|
||||
{
|
||||
document.getElementById('evhandler1').style.display = '';
|
||||
}
|
||||
|
||||
function evhandleroff()
|
||||
{
|
||||
document.getElementById('evhandler1').style.display = 'none';
|
||||
}
|
||||
|
||||
function common()
|
||||
{
|
||||
document.getElementById('comm1').style.display = '';
|
||||
}
|
||||
|
||||
function commoff()
|
||||
{
|
||||
document.getElementById('comm1').style.display = 'none';
|
||||
}
|
||||
|
||||
function registraon()
|
||||
{
|
||||
document.getElementById('froreg1').style.display = '';
|
||||
document.getElementById('froreg2').style.display = '';
|
||||
}
|
||||
|
||||
function registraoff()
|
||||
{Route
|
||||
document.getElementById('froreg1').style.display = 'none';
|
||||
document.getElementById('froreg2').style.display = 'none';
|
||||
}
|
||||
|
||||
$(document).ready(function() {
|
||||
function updateLightboxVisibility() {
|
||||
if ($('input[name="jform[gddisabled]"]:checked').val() === '0') {
|
||||
$('input[name="jform[lightbox]"]').val(['0']);
|
||||
$('#jform_lightbox, #jform_lightbox-lbl').css('display', 'none');
|
||||
} else {
|
||||
$('#jform_lightbox, #jform_lightbox-lbl').css('display', '');
|
||||
}
|
||||
}
|
||||
|
||||
updateLightboxVisibility();
|
||||
|
||||
$('input[name="jform[gddisabled]"]').on('change', function() {
|
||||
updateLightboxVisibility();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<script>
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
if (task == 'settings.cancel' || document.formvalidator.isValid(document.getElementById('settings-form'))) {
|
||||
Joomla.submitform(task, document.getElementById('settings-form'));
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&view=settings'); ?>" method="post" id="settings-form" name="adminForm" class="form-validate">
|
||||
|
||||
<div id="j-main-container" class="j-main-container">
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<?php echo HTMLHelper::_('uitab.startTabSet', 'settings-pane', ['active' => 'settings-basic', 'recall' => true, 'breakpoint' => 768]); ?>
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'settings-pane', 'settings-basic', Text::_('COM_JEM_BASIC_SETTINGS')); ?>
|
||||
<fieldset class="adminform">
|
||||
|
||||
<div class="w-50 fltlft">
|
||||
<?php echo $this->loadTemplate('basicdisplay'); ?>
|
||||
<?php echo $this->loadTemplate('basiclayout'); ?>
|
||||
<?php echo $this->loadTemplate('basiceventhandling'); ?>
|
||||
</div>
|
||||
<div class="w-50 fltrt">
|
||||
<?php echo $this->loadTemplate('basicimagehandling'); ?>
|
||||
<?php echo $this->loadTemplate('basicmetahandling'); ?>
|
||||
</div>
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<div class="clr"></div>
|
||||
|
||||
|
||||
|
||||
<?php echo HTMLHelper::_('uitab.addTab','settings-pane', 'settings-pane-2', Text::_('COM_JEM_EVENT_PAGE')); ?>
|
||||
<fieldset class="adminform">
|
||||
<div class="width-50 fltlft">
|
||||
<?php echo $this->loadTemplate('evevents'); ?>
|
||||
</div>
|
||||
<div class="width-50 fltrt">
|
||||
<?php echo $this->loadTemplate('evvenues'); ?>
|
||||
<?php echo $this->loadTemplate('evregistration'); ?>
|
||||
</div>
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<div class="clr"></div>
|
||||
|
||||
|
||||
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'settings-pane', 'layout', Text::_('COM_JEM_LAYOUT')); ?>
|
||||
<fieldset class="adminform">
|
||||
<?php echo $this->loadTemplate('layout'); ?>
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<div class="clr"></div>
|
||||
|
||||
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'settings-pane', 'parameters', Text::_('COM_JEM_GLOBAL_PARAMETERS')); ?>
|
||||
<fieldset class="adminform">
|
||||
<?php echo $this->loadTemplate('parameters'); ?>
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<div class="clr"></div>
|
||||
|
||||
|
||||
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'settings-pane', 'usercontrol', Text::_('COM_JEM_USER_CONTROL')); ?>
|
||||
<fieldset class="adminform">
|
||||
<?php echo $this->loadTemplate('usercontrol'); ?>
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<div class="clr"></div>
|
||||
|
||||
|
||||
|
||||
<?php echo HTMLHelper::_('uitab.addTab', 'settings-pane', 'configinfo', Text::_('COM_JEM_SETTINGS_TAB_CONFIGINFO')); ?>
|
||||
<fieldset class="adminform">
|
||||
<?php echo $this->loadTemplate('configinfo'); ?>
|
||||
</fieldset>
|
||||
<?php echo HTMLHelper::_('uitab.endTab'); ?>
|
||||
<div class="clr"></div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<input type="hidden" name="task" value="">
|
||||
<input type="hidden" name="id" value="1">
|
||||
<input type="hidden" name="lastupdate" value="<?php $this->jemsettings->lastupdate; ?>">
|
||||
<input type="hidden" name="option" value="com_jem">
|
||||
<input type="hidden" name="controller" value="settings">
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</form>
|
||||
@ -0,0 +1,464 @@
|
||||
<?php
|
||||
/**
|
||||
* @version 2.1.7
|
||||
* @package JEM
|
||||
* @copyright (C) 2013-2016 joomlaeventmanager.net
|
||||
* @copyright (C) 2005-2009 Christoph Lukes
|
||||
* @license http://www.gnu.org/licenses/gpl-2.0.html GNU/GPL
|
||||
*
|
||||
* * @todo: move js to a file
|
||||
*/
|
||||
|
||||
defined('_JEXEC') or die;
|
||||
|
||||
// Load tooltips behavior
|
||||
JHtml::_('behavior.formvalidation');
|
||||
JHtml::_('behavior.switcher');
|
||||
JHtml::_('behavior.tooltip');
|
||||
|
||||
|
||||
?>
|
||||
|
||||
<script>
|
||||
window.addEvent('domready', function(){
|
||||
|
||||
$('jform_showcity0').addEvent('click', cityon);
|
||||
$('jform_showcity1').addEvent('click', cityoff);
|
||||
|
||||
if($('jform_showcity0').checked) {
|
||||
cityon();
|
||||
}
|
||||
|
||||
$('jform_showatte0').addEvent('click', atteon);
|
||||
$('jform_showatte1').addEvent('click', atteoff);
|
||||
|
||||
if($('jform_showatte0').checked) {
|
||||
atteon();
|
||||
}
|
||||
|
||||
$('jform_showtitle0').addEvent('click', titleon);
|
||||
$('jform_showtitle1').addEvent('click', titleoff);
|
||||
|
||||
if($('jform_showtitle0').checked) {
|
||||
titleon();
|
||||
}
|
||||
|
||||
$('jform_showlocate0').addEvent('click', locon);
|
||||
$('jform_showlocate1').addEvent('click', locoff);
|
||||
|
||||
if($('jform_showlocate0').checked) {
|
||||
locon();
|
||||
}
|
||||
|
||||
$('jform_showstate0').addEvent('click', stateon);
|
||||
$('jform_showstate1').addEvent('click', stateoff);
|
||||
|
||||
if($('jform_showstate0').checked) {
|
||||
stateon();
|
||||
}
|
||||
|
||||
$('jform_showcat0').addEvent('click', caton);
|
||||
$('jform_showcat1').addEvent('click', catoff);
|
||||
|
||||
if($('jform_showcat0').checked) {
|
||||
caton();
|
||||
}
|
||||
|
||||
$('jform_showeventimage0').addEvent('click', evimageon);
|
||||
$('jform_showeventimage1').addEvent('click', evimageoff);
|
||||
|
||||
if($('jform_showeventimage0').checked) {
|
||||
evimageon();
|
||||
}
|
||||
|
||||
$('jform_gddisabled0').addEvent('click', lbon);
|
||||
$('jform_gddisabled1').addEvent('click', lboff);
|
||||
|
||||
if($('jform_gddisabled0').checked) {
|
||||
lbon();
|
||||
}
|
||||
|
||||
$("jform_globalattribs_event_show_mapserv").addEvent('change', testmap);
|
||||
|
||||
var mapserv = $("jform_globalattribs_event_show_mapserv");
|
||||
var nrmapserv = mapserv.options[mapserv.selectedIndex].value;
|
||||
|
||||
if (nrmapserv == 1 || nrmapserv == 2) {
|
||||
eventmapon();
|
||||
} else {
|
||||
eventmapoff();
|
||||
}
|
||||
|
||||
|
||||
$("jform_globalattribs_global_show_mapserv").addEvent('change', testmap);
|
||||
|
||||
var mapserv = $("jform_globalattribs_global_show_mapserv");
|
||||
var nrmapserv = mapserv.options[mapserv.selectedIndex].value;
|
||||
|
||||
if (nrmapserv == 1 || nrmapserv == 2) {
|
||||
globalmapon();
|
||||
} else {
|
||||
globalmapoff();
|
||||
}
|
||||
|
||||
$("jform_oldevent").addEvent('change', testevhandler);
|
||||
|
||||
var evhandler = $("jform_oldevent");
|
||||
var nrevhandler = evhandler.options[evhandler.selectedIndex].value;
|
||||
|
||||
if (nrevhandler == 1 || nrevhandler == 2 || nrevhandler == 3) {
|
||||
evhandleron();
|
||||
} else {
|
||||
evhandleroff();
|
||||
}
|
||||
|
||||
$('jform_globalattribs_event_comunsolution').addEvent('change', testcomm);
|
||||
|
||||
var commhandler = $("jform_globalattribs_event_comunsolution");
|
||||
var nrcommhandler = commhandler.options[commhandler.selectedIndex].value;
|
||||
|
||||
if (nrcommhandler == 1) {
|
||||
common();
|
||||
} else {
|
||||
commoff();
|
||||
}
|
||||
|
||||
|
||||
var ObjArray = $$('input.colorpicker').get('id').sort();
|
||||
|
||||
var arrayLength = ObjArray.length;
|
||||
for (var i = 0; i < arrayLength; i++) {
|
||||
var Obj = $(ObjArray[i]);
|
||||
var color = testcolor(Obj.value);
|
||||
if (color) {
|
||||
Obj.style.color = color;
|
||||
}
|
||||
}
|
||||
|
||||
$("jform_showfroregistra").addEvent('change', testregistra);
|
||||
|
||||
var registra = $("jform_showfroregistra");
|
||||
var nrregistra = registra.options[registra.selectedIndex].value;
|
||||
|
||||
if (nrregistra >= 1) {
|
||||
registraon();
|
||||
} else {
|
||||
registraoff();
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
function testcolor(color) {
|
||||
if(color.length==7)
|
||||
{
|
||||
color=color.substring(1);
|
||||
}
|
||||
var R = parseInt(color.substring(0,2),16);
|
||||
var G = parseInt(color.substring(2,4),16);
|
||||
var B = parseInt(color.substring(4,6),16);
|
||||
var x = Math.sqrt(R * R * .299 + G * G * .587 + B * B * .114);
|
||||
|
||||
var sColorText = x < 130 ? '#FFFFFF' : '#000000';
|
||||
|
||||
return sColorText;
|
||||
}
|
||||
|
||||
function testcomm()
|
||||
{
|
||||
var commhandler = $("jform_globalattribs_event_comunsolution");
|
||||
var nrcommhandler = commhandler.options[commhandler.selectedIndex].value;
|
||||
|
||||
if (nrcommhandler == 1) {
|
||||
common();
|
||||
} else {
|
||||
commoff();
|
||||
}
|
||||
}
|
||||
|
||||
function testmap()
|
||||
{
|
||||
var mapserv = $("jform_globalattribs_event_show_mapserv");
|
||||
var nrmapserv = mapserv.options[mapserv.selectedIndex].value;
|
||||
|
||||
if (nrmapserv == 1 || nrmapserv == 2) {
|
||||
eventmapon();
|
||||
} else {
|
||||
eventmapoff();
|
||||
}
|
||||
|
||||
var mapserv2 = $("jform_globalattribs_global_show_mapserv");
|
||||
var nrmapserv2 = mapserv2.options[mapserv2.selectedIndex].value;
|
||||
|
||||
if (nrmapserv2 == 1 || nrmapserv2 == 2) {
|
||||
globalmapon();
|
||||
} else {
|
||||
globalmapoff();
|
||||
}
|
||||
}
|
||||
|
||||
function testevhandler()
|
||||
{
|
||||
var evhandler = $("jform_oldevent");
|
||||
var nrevhandler = evhandler.options[evhandler.selectedIndex].value;
|
||||
|
||||
if (nrevhandler == 1 || nrevhandler == 2 || nrevhandler == 3) {
|
||||
evhandleron();
|
||||
} else {
|
||||
evhandleroff();
|
||||
}
|
||||
}
|
||||
|
||||
function testregistra()
|
||||
{
|
||||
var registra = $("jform_showfroregistra");
|
||||
var nrregistra = registra.options[registra.selectedIndex].value;
|
||||
|
||||
if (nrregistra >= 1) {
|
||||
registraon();
|
||||
} else {
|
||||
registraoff();
|
||||
}
|
||||
}
|
||||
|
||||
function cityon()
|
||||
{
|
||||
document.getElementById('city1').style.display = '';
|
||||
}
|
||||
|
||||
function cityoff()
|
||||
{
|
||||
var citywidth = document.getElementById('jform_citywidth');
|
||||
document.getElementById('city1').style.display = 'none';
|
||||
citywidth.value='';
|
||||
}
|
||||
|
||||
function atteon()
|
||||
{
|
||||
document.getElementById('atte1').style.display = '';
|
||||
}
|
||||
|
||||
function atteoff()
|
||||
{
|
||||
var attewidth = document.getElementById('jform_attewidth');
|
||||
document.getElementById('atte1').style.display = 'none';
|
||||
attewidth.value='';
|
||||
}
|
||||
|
||||
function titleon()
|
||||
{
|
||||
document.getElementById('title1').style.display = '';
|
||||
}
|
||||
|
||||
function titleoff()
|
||||
{
|
||||
var titlewidth = document.getElementById('jform_titlewidth');
|
||||
document.getElementById('title1').style.display = 'none';
|
||||
titlewidth.value='';
|
||||
}
|
||||
|
||||
function locon()
|
||||
{
|
||||
document.getElementById('loc1').style.display = '';
|
||||
document.getElementById('loc2').style.display = '';
|
||||
}
|
||||
|
||||
function locoff()
|
||||
{
|
||||
var locatewidth = document.getElementById('jform_locationwidth');
|
||||
document.getElementById('loc1').style.display = 'none';
|
||||
locatewidth.value='';
|
||||
document.getElementById('loc2').style.display = 'none';
|
||||
}
|
||||
|
||||
function stateon()
|
||||
{
|
||||
document.getElementById('state1').style.display = '';
|
||||
}
|
||||
|
||||
function stateoff()
|
||||
{
|
||||
var statewidth = document.getElementById('jform_statewidth');
|
||||
document.getElementById('state1').style.display = 'none';
|
||||
statewidth.value='';
|
||||
}
|
||||
|
||||
function caton()
|
||||
{
|
||||
document.getElementById('cat1').style.display = '';
|
||||
document.getElementById('cat2').style.display = '';
|
||||
}
|
||||
|
||||
function catoff()
|
||||
{
|
||||
var catwidth = document.getElementById('jform_catfrowidth');
|
||||
document.getElementById('cat1').style.display = 'none';
|
||||
catwidth.value='';
|
||||
document.getElementById('cat2').style.display = 'none';
|
||||
}
|
||||
|
||||
function evimageon()
|
||||
{
|
||||
document.getElementById('evimage1').style.display = '';
|
||||
}
|
||||
|
||||
function evimageoff()
|
||||
{
|
||||
var evimagewidth = document.getElementById('jform_tableeventimagewidth');
|
||||
document.getElementById('evimage1').style.display = 'none';
|
||||
evimagewidth.value='';
|
||||
}
|
||||
|
||||
function lbon()
|
||||
{
|
||||
document.getElementById('lb1').style.display = '';
|
||||
}
|
||||
|
||||
function lboff()
|
||||
{
|
||||
document.getElementById('lb1').style.display = 'none';
|
||||
}
|
||||
|
||||
function eventmapon()
|
||||
{
|
||||
document.getElementById('eventmap1').style.display = '';
|
||||
document.getElementById('eventmap2').style.display = '';
|
||||
}
|
||||
|
||||
function eventmapoff()
|
||||
{
|
||||
document.getElementById('eventmap1').style.display = 'none';
|
||||
document.getElementById('eventmap2').style.display = 'none';
|
||||
document.getElementById('jform_globalattribs_event_tld').value = '';
|
||||
document.getElementById('jform_globalattribs_event_lg').value = '';
|
||||
}
|
||||
|
||||
function globalmapon()
|
||||
{
|
||||
document.getElementById('globalmap1').style.display = '';
|
||||
document.getElementById('globalmap2').style.display = '';
|
||||
}
|
||||
|
||||
function globalmapoff()
|
||||
{
|
||||
document.getElementById('globalmap1').style.display = 'none';
|
||||
document.getElementById('globalmap2').style.display = 'none';
|
||||
document.getElementById('jform_globalattribs_global_tld').value = '';
|
||||
document.getElementById('jform_globalattribs_global_lg').value = '';
|
||||
}
|
||||
|
||||
|
||||
function evhandleron()
|
||||
{
|
||||
document.getElementById('evhandler1').style.display = '';
|
||||
}
|
||||
|
||||
function evhandleroff()
|
||||
{
|
||||
document.getElementById('evhandler1').style.display = 'none';
|
||||
}
|
||||
|
||||
function common()
|
||||
{
|
||||
document.getElementById('comm1').style.display = '';
|
||||
}
|
||||
|
||||
function commoff()
|
||||
{
|
||||
document.getElementById('comm1').style.display = 'none';
|
||||
}
|
||||
|
||||
function registraon()
|
||||
{
|
||||
document.getElementById('froreg1').style.display = '';
|
||||
document.getElementById('froreg2').style.display = '';
|
||||
}
|
||||
|
||||
function registraoff()
|
||||
{
|
||||
document.getElementById('froreg1').style.display = 'none';
|
||||
document.getElementById('froreg2').style.display = 'none';
|
||||
}
|
||||
</script>
|
||||
|
||||
<script type="text/javascript">
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
if (task == 'settings.cancel' || document.formvalidator.isValid(document.id('settings-form'))) {
|
||||
Joomla.submitform(task, document.getElementById('settings-form'));
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<form action="<?php echo JRoute::_('index.php?option=com_jem&view=settings'); ?>" method="post" id="settings-form" name="adminForm" class="form-validate">
|
||||
<?php if (isset($this->sidebar)) : ?>
|
||||
<div id="j-sidebar-container" class="span2">
|
||||
<?php echo $this->sidebar; ?>
|
||||
</div>
|
||||
<div id="j-main-container" class="span10">
|
||||
<?php endif; ?>
|
||||
<?php echo JHtml::_('bootstrap.startTabSet', 'myTab', array('active' => 'settings-basic')); ?>
|
||||
<!-- DETAILS TAB -->
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'settings-basic', JText::_('COM_JEM_BASIC_SETTINGS', true)); ?>
|
||||
|
||||
|
||||
<?php// echo JHtml::_('tabs.start', 'settings-pane', array('useCookie'=>1)); ?>
|
||||
<?php// echo JHtml::_('tabs.panel', JText::_( 'COM_JEM_BASIC_SETTINGS' ), 'settings-basic'); ?>
|
||||
|
||||
<div class="span4">
|
||||
<?php echo $this->loadTemplate('basicdisplay'); ?>
|
||||
<?php echo $this->loadTemplate('basiceventhandling'); ?>
|
||||
</div>
|
||||
<div class="span4">
|
||||
<?php echo $this->loadTemplate('basicimagehandling'); ?>
|
||||
<?php echo $this->loadTemplate('basicmetahandling'); ?>
|
||||
</div>
|
||||
<div class="clr"></div>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'layout2', JText::_('COM_JEM_EVENT_PAGE', true)); ?>
|
||||
|
||||
<?php// echo JHtml::_('tabs.panel', JText::_( 'COM_JEM_EVENT_PAGE' ), 'layout2'); ?>
|
||||
|
||||
<div class="span4">
|
||||
<?php echo $this->loadTemplate('evevents'); ?>
|
||||
</div>
|
||||
<div class="span4">
|
||||
<?php echo $this->loadTemplate('evvenues'); ?>
|
||||
<?php echo $this->loadTemplate('evregistration'); ?>
|
||||
</div>
|
||||
<div class="clr"></div>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'layout', JText::_('COM_JEM_LAYOUT', true)); ?>
|
||||
|
||||
<?php// echo JHtml::_('tabs.panel', JText::_( 'COM_JEM_LAYOUT' ), 'layout'); ?>
|
||||
<?php echo $this->loadTemplate('layout'); ?>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'parameters', JText::_('COM_JEM_GLOBAL_PARAMETERS', true)); ?>
|
||||
|
||||
<?php// echo JHtml::_('tabs.panel', JText::_( 'COM_JEM_GLOBAL_PARAMETERS' ), 'parameters'); ?>
|
||||
<?php echo $this->loadTemplate('parameters'); ?>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'usercontrol', JText::_('COM_JEM_USER_CONTROL', true)); ?>
|
||||
|
||||
<?php// echo JHtml::_('tabs.panel', JText::_( 'COM_JEM_USER_CONTROL' ), 'usercontrol'); ?>
|
||||
<?php echo $this->loadTemplate('usercontrol'); ?>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'configinfo', JText::_('COM_JEM_GLOBAL_PARAMETERS', true)); ?>
|
||||
|
||||
<?php echo JHtml::_('tabs.panel', JText::_( 'COM_JEM_SETTINGS_TAB_CONFIGINFO' ), 'configinfo'); ?>
|
||||
<?php echo $this->loadTemplate('configinfo'); ?>
|
||||
<?php echo JHtml::_('bootstrap.endTab'); ?>
|
||||
<?php echo JHtml::_('bootstrap.endTabSet');?>
|
||||
<?php// echo JHtml::_('tabs.end'); ?>
|
||||
|
||||
<div class="clr"></div>
|
||||
<?php if (isset($this->sidebar)) : ?>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<input type="hidden" name="task" value="">
|
||||
<input type="hidden" name="id" value="1">
|
||||
<input type="hidden" name="lastupdate" value="<?php $this->jemsettings->lastupdate; ?>">
|
||||
<input type="hidden" name="option" value="com_jem">
|
||||
<input type="hidden" name="controller" value="settings">
|
||||
<?php echo JHtml::_('form.token'); ?>
|
||||
</form>
|
||||
@ -0,0 +1,26 @@
|
||||
<?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;
|
||||
?>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_( 'COM_JEM_DISPLAY_SETTINGS' ); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showdetails'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('formatShortDate'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('formatdate'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('formattime'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('timename'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('formathour'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('storeip'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,21 @@
|
||||
<?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;
|
||||
?>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_( 'COM_JEM_EVENT_HANDLING' ); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('oldevent'); ?></div></li>
|
||||
<li id="evhandler1"><div class="label-form"><?php echo $this->form->renderfield('minus'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,31 @@
|
||||
<?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;
|
||||
|
||||
$gdv = JEMImage::gdVersion();
|
||||
?>
|
||||
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_( 'COM_JEM_IMAGE_HANDLING' ); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('image_filetypes'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('sizelimit'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('imagehight'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('imagewidth'); ?></div></li>
|
||||
<?php if ($gdv && $gdv >= 2) : //is the gd library installed on the server and its version > 2? ?>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('gddisabled'); ?></div></li>
|
||||
<?php endif; ?>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('lightbox'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('flyer'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,21 @@
|
||||
<?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;
|
||||
?>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_( 'COM_JEM_LAYOUT_STYLE_SETTINGS' ); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('layoutstyle'); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('useiconfont'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,78 @@
|
||||
<?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;
|
||||
?>
|
||||
|
||||
<script>
|
||||
<!--
|
||||
function insert_keyword($keyword) {
|
||||
document.getElementById("jform_meta_description").value += " " + $keyword;
|
||||
}
|
||||
|
||||
function include_description() {
|
||||
document.getElementById("jform_meta_description").value = "<?php echo Text::_( 'COM_JEM_META_DESCRIPTION_STANDARD' ); ?>";
|
||||
}
|
||||
-->
|
||||
</script>
|
||||
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_( 'COM_JEM_META_HANDLING' ); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><label id="jform_meta_keywords-lbl" <?php echo JEMOutput::tooltip(Text::_('COM_JEM_META_KEYWORDS'), Text::_('COM_JEM_META_KEYWORDS_DESC')); ?>>
|
||||
<?php echo Text::_( 'COM_JEM_META_KEYWORDS' ); ?>
|
||||
</label>
|
||||
<div style="display: block;">
|
||||
<?php
|
||||
// TODO use jforms here
|
||||
$meta_key = explode(", ", $this->data->meta_keywords);
|
||||
?>
|
||||
<select name="meta_keywords[]" multiple="multiple" size="6" class="inputbox form-control" id="jform_meta_keywords">
|
||||
<option value="[title]" <?php if(in_array("[title]",$meta_key)) { echo "selected=\"selected\""; } ?>>
|
||||
<?php echo Text::_( 'COM_JEM_EVENT_TITLE' ); ?></option>
|
||||
<option value="[a_name]" <?php if(in_array("[a_name]",$meta_key)) { echo "selected=\"selected\""; } ?>>
|
||||
<?php echo Text::_( 'COM_JEM_VENUE' ); ?></option>
|
||||
<!-- <option value="[locid]" <?php if(in_array("[locid]",$meta_key)) { echo "selected=\"selected\""; } ?>>
|
||||
<?php echo Text::_( 'COM_JEM_CITY' ); ?></option> -->
|
||||
<option value="[dates]" <?php if(in_array("[dates]",$meta_key)) { echo "selected=\"selected\""; } ?>>
|
||||
<?php echo Text::_( 'COM_JEM_STARTDATE' ); ?></option>
|
||||
<option value="[times]" <?php if(in_array("[times]",$meta_key)) { echo "selected=\"selected\""; } ?>>
|
||||
<?php echo Text::_( 'COM_JEM_STARTTIME' ); ?></option>
|
||||
<option value="[enddates]" <?php if(in_array("[enddates]",$meta_key)) { echo "selected=\"selected\""; } ?>>
|
||||
<?php echo Text::_( 'COM_JEM_ENDDATE' ); ?></option>
|
||||
<option value="[endtimes]" <?php if(in_array("[endtimes]",$meta_key)) { echo "selected=\"selected\""; } ?>>
|
||||
<?php echo Text::_( 'COM_JEM_ENDTIME' ); ?></option>
|
||||
</select>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
<li><?php echo $this->form->getLabel('meta_description'); ?>
|
||||
<div style="display: block;">
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[title]')" value="<?php echo Text::_( 'COM_JEM_EVENT_TITLE' ); ?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[a_name]')" value="<?php echo Text::_( 'COM_JEM_VENUE' ); ?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[dates]')" value="<?php echo Text::_( 'COM_JEM_STARTDATE' ); ?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[times]')" value="<?php echo Text::_( 'COM_JEM_STARTTIME' ); ?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[enddates]')" value="<?php echo Text::_( 'COM_JEM_ENDDATE' ); ?>" />
|
||||
<input class="inputbox" type="button" onclick="insert_keyword('[endtimes]')" value="<?php echo Text::_( 'COM_JEM_ENDTIME' ); ?>" />
|
||||
<br/>
|
||||
<?php echo $this->form->getInput('meta_description'); ?>
|
||||
<br/>
|
||||
<input type="button" value="<?php echo Text::_( 'COM_JEM_META_DESCRIPTION_BUTTON' ); ?>" onclick="include_description()" />
|
||||
|
||||
<span <?php echo JEMOutput::tooltip(Text::_('COM_JEM_WARNING'), Text::_('COM_JEM_META_DESCRIPTION_WARN'), 'error'); ?>>
|
||||
<?php echo $this->WarningIcon(); ?>
|
||||
</span>
|
||||
</div>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,84 @@
|
||||
<?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;
|
||||
|
||||
?>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETTINGS_LEGEND_CONFIGINFO'); ?></legend>
|
||||
<br>
|
||||
<table class="adminlist table">
|
||||
<?php
|
||||
$known_extensions = array('pkg_jem' => 'COM_JEM_MAIN_CONFIG_VS_PACKAGE'
|
||||
,'com_jem' => 'COM_JEM_MAIN_CONFIG_VS_COMPONENT'
|
||||
,'mod_jem' => 'COM_JEM_MAIN_CONFIG_VS_MOD_JEM'
|
||||
,'mod_jem_cal' => 'COM_JEM_MAIN_CONFIG_VS_MOD_JEM_CAL'
|
||||
,'mod_jem_calajax' => 'COM_JEM_MAIN_CONFIG_VS_MOD_JEM_CALAJAX'
|
||||
,'mod_jem_banner' => 'COM_JEM_MAIN_CONFIG_VS_MOD_JEM_BANNER'
|
||||
,'mod_jem_jubilee' => 'COM_JEM_MAIN_CONFIG_VS_MOD_JEM_JUBILEE'
|
||||
,'mod_jem_teaser' => 'COM_JEM_MAIN_CONFIG_VS_MOD_JEM_TEASER'
|
||||
,'mod_jem_wide' => 'COM_JEM_MAIN_CONFIG_VS_MOD_JEM_WIDE'
|
||||
,'plg_content_jem' => 'COM_JEM_MAIN_CONFIG_VS_PLG_CONTENT'
|
||||
,'plg_content_jemlistevents' => 'COM_JEM_MAIN_CONFIG_VS_PLG_CONTENT_LISTEVENTS'
|
||||
,'plg_finder_jem' => 'COM_JEM_MAIN_CONFIG_VS_PLG_FINDER'
|
||||
,'plg_search_jem' => 'COM_JEM_MAIN_CONFIG_VS_PLG_SEARCH'
|
||||
,'plg_jem_comments' => 'COM_JEM_MAIN_CONFIG_VS_PLG_COMMENTS'
|
||||
,'plg_jem_mailer' => 'COM_JEM_MAIN_CONFIG_VS_PLG_MAILER'
|
||||
,'plg_jem_demo' => 'COM_JEM_MAIN_CONFIG_VS_PLG_DEMO'
|
||||
,'plg_quickicon_jemquickicon' => 'COM_JEM_MAIN_CONFIG_VS_PLG_QUICKICON'
|
||||
,'AcyMailing Tag : insert events from JEM 2.1+'
|
||||
=> 'COM_JEM_MAIN_CONFIG_VS_PLG_ACYMAILING_TAGJEM'
|
||||
);
|
||||
?>
|
||||
<tr>
|
||||
<th><u><?php echo Text::_('COM_JEM_NAME'); ?></u></th>
|
||||
<th><u><?php echo Text::_('COM_JEM_MAIN_CONFIG_VS'); ?></u></th>
|
||||
<th><u><?php echo Text::_('COM_JEM_DATE'); ?></u></th>
|
||||
<th><u><?php echo Text::_('JSTATUS'); ?></u></th>
|
||||
</tr>
|
||||
<?php
|
||||
foreach ($known_extensions as $name => $label) {
|
||||
if (!empty($this->config->$name)) { ?>
|
||||
<tr>
|
||||
<td><?php echo Text::_($label).': '; ?></td>
|
||||
<td><b><?php echo $this->config->$name->version; ?></b></td>
|
||||
<td><?php echo $this->config->$name->creationDate; ?></td>
|
||||
<td><?php echo empty($this->config->$name->enabled) ? Text::_('COM_JEM_DISABLED') : ''; ?></td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
}
|
||||
?>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CONFIG_VS_PHP').': '; ?></td>
|
||||
<td colspan="3"><b><?php echo $this->config->vs_php; ?> </b></td>
|
||||
</tr>
|
||||
<?php if (!empty($this->config->vs_php_magicquotes)) : ?>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CONFIG_VS_PHP_MAGICQUOTES').': '; ?></td>
|
||||
<td colspan="3"><b><?php echo $this->config->vs_php_magicquotes; ?> </b></td>
|
||||
</tr>
|
||||
<?php endif; ?>
|
||||
<tr>
|
||||
<td><?php echo Text::_('COM_JEM_MAIN_CONFIG_VS_GD').': '; ?></td>
|
||||
<td colspan="3"><b><?php echo $this->config->vs_gd; ?> </b></td>
|
||||
</tr>
|
||||
</table>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="width-50 fltrt">
|
||||
|
||||
</div>
|
||||
|
||||
<div class="clr"></div>
|
||||
@ -0,0 +1,42 @@
|
||||
<?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;
|
||||
|
||||
// Create shortcut to parameters.
|
||||
$params = $this->state->get('params');
|
||||
$params = $params->toArray();
|
||||
|
||||
// This checks if the config options have ever been saved. If they haven't they will fall back to the original settings.
|
||||
$editoroptions = isset($params['show_publishing_options']);
|
||||
|
||||
if (!$editoroptions):
|
||||
$params['show_publishing_options'] = '1';
|
||||
$params['show_article_options'] = '1';
|
||||
$params['show_urls_images_backend'] = '0';
|
||||
$params['show_urls_images_frontend'] = '0';
|
||||
endif;
|
||||
?>
|
||||
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_EVENTS'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('evevents') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('basic') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,28 @@
|
||||
<?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;
|
||||
|
||||
$group = 'globalattribs';
|
||||
?>
|
||||
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_REGISTRATION'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_registration',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_registration_counters',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_attendeenames',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_more_attendeedetails',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_comunsolution',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_comunoption',$group); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,28 @@
|
||||
<?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;
|
||||
$group = 'globalattribs';
|
||||
?>
|
||||
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_VENUES'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_venue',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_locdescription',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_detailsadress',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_detlinkvenue',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_show_mapserv',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_tld',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('event_lg',$group); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
@ -0,0 +1,140 @@
|
||||
<?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;
|
||||
?>
|
||||
<div class="width-50 fltlft">
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_GENERAL_LAYOUT_SETTINGS'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('layoutgenerallayoutsetting') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_CITY_COLUMN'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showcity'); ?></div></li>
|
||||
|
||||
<li id="city1" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('citywidth'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_ATTENDEE_COLUMN'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showatte'); ?></div></li>
|
||||
|
||||
<li id="atte1" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('attewidth'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_TITLE_COLUMN'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showtitle'); ?></div></li>
|
||||
<li id="title1" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('titlewidth'); ?></div>
|
||||
</li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_VENUE_COLUMN'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showlocate'); ?></div></li>
|
||||
|
||||
<li id="loc1" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('locationwidth'); ?></div></li>
|
||||
|
||||
<li id="loc2" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('showlinkvenue'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_STATE_COLUMN'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showstate'); ?></div></li>
|
||||
<li id="state1" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('statewidth'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_CATEGORY_COLUMN'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showcat'); ?></div></li>
|
||||
|
||||
<li id="cat1" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('catfrowidth'); ?></div></li>
|
||||
|
||||
<li id="cat2" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('catlinklist'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_LAYOUT_TABLE_EVENTIMAGE'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('showeventimage'); ?></div></li>
|
||||
|
||||
<li id="evimage1" style="display:none"><div class="label-form"><?php echo $this->form->renderfield('tableeventimagewidth'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="width-50 fltrt">
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETTINGS_LEGEND_CSS'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('stylesheet') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETTINGS_LEGEND_CSS_COLOR_BACKGROUND'); ?></legend>
|
||||
<ul class="adminformlist label-button-line">
|
||||
<?php foreach ($this->form->getFieldset('css_color') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETTINGS_LEGEND_CSS_COLOR_BORDER'); ?></legend>
|
||||
<ul class="adminformlist label-button-line">
|
||||
<?php foreach ($this->form->getFieldset('css_color_border') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETTINGS_LEGEND_CSS_COLOR_FONT'); ?></legend>
|
||||
<ul class="adminformlist label-button-line">
|
||||
<?php foreach ($this->form->getFieldset('css_color_font') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div><div class="clr"></div>
|
||||
@ -0,0 +1,81 @@
|
||||
<?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;
|
||||
|
||||
$group = 'globalattribs';
|
||||
|
||||
?>
|
||||
<div class="width-50 fltlft">
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_GLOBAL_PARAMETERS'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('globalparam') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETTINGS_LEGEND_VIEW_EDITEVENT'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_show_ownedvenuesonly',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_editevent_maxnumcustomfields',$group); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETIINGS_GLOBAL_RECURRENCE'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('globalparam_recurrence') as $field): ?>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield($field->fieldname); ?></div></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
<div class="width-50 fltrt">
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_GLOBAL_PARAMETERS_ADVANCED'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('globalparam2') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_VENUES'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_show_locdescription',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_show_detailsadress',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_show_detlinkvenue',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_show_listevents',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_show_mapserv',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_tld',$group); ?></div></li>
|
||||
<li><div class="label-form"><?php echo $this->form->renderfield('global_lg',$group); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_SETTINGS_LEGEND_VIEW_EDITVENUE'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><?php echo $this->form->getLabel('global_editvenue_maxnumcustomfields',$group); ?> <?php echo $this->form->getInput('global_editvenue_maxnumcustomfields',$group); ?></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clr"></div>
|
||||
@ -0,0 +1,56 @@
|
||||
<?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;
|
||||
|
||||
?>
|
||||
<div class="width-50 fltlft">
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_USER_CONTROL'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('usercontrol') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_AC_EVENTS'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('usercontrolacevent') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div><div class="width-50 fltrt">
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_REGISTRATION'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<li><?php echo $this->form->getLabel('showfroregistra'); ?> <?php echo $this->form->getInput('showfroregistra'); ?> </li>
|
||||
<li id="froreg1"><div class="label-form"><?php echo $this->form->renderfield('regallowinvitation'); ?></div></li>
|
||||
<li id="froreg2"><div class="label-form"><?php echo $this->form->renderfield('regallowcomments'); ?></div></li>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="width-100" style="padding: 10px 1vw;">
|
||||
<fieldset class="options-form">
|
||||
<legend><?php echo Text::_('COM_JEM_AC_VENUES'); ?></legend>
|
||||
<ul class="adminformlist">
|
||||
<?php foreach ($this->form->getFieldset('usercontrolacvenue') as $field): ?>
|
||||
<li><?php echo $field->label; ?> <?php echo $field->input; ?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
</fieldset>
|
||||
</div>
|
||||
</div><div class="clr"></div>
|
||||
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
117
administrator/components/com_jem/views/settings/view.html.php
Normal file
117
administrator/components/com_jem/views/settings/view.html.php
Normal file
@ -0,0 +1,117 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Toolbar\ToolbarHelper;
|
||||
use Joomla\CMS\Uri\Uri;
|
||||
use Joomla\CMS\Factory;
|
||||
|
||||
/**
|
||||
* View class for the JEM Settings screen
|
||||
*
|
||||
* @package JEM
|
||||
*/
|
||||
class JemViewSettings extends JemAdminView
|
||||
{
|
||||
protected $form;
|
||||
protected $data;
|
||||
protected $state;
|
||||
|
||||
public function display($tpl = null)
|
||||
{
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$form = $this->get('Form');
|
||||
$data = $this->get('Data');
|
||||
$state = $this->get('State');
|
||||
$config = $this->get('ConfigInfo');
|
||||
$jemsettings = $this->get('Data');
|
||||
$this->document = $document;
|
||||
|
||||
// Load css
|
||||
$wa = $document->getWebAssetManager();
|
||||
|
||||
$wa->registerStyle('jem.backend', 'com_jem/backend.css')->useStyle('jem.backend');
|
||||
$wa->registerStyle('jem.colorpicker', 'com_jem/colorpicker.css')->useStyle('jem.colorpicker');
|
||||
|
||||
$style = '
|
||||
div.current fieldset.radio input {
|
||||
cursor: pointer;
|
||||
}';
|
||||
$document->addStyleDeclaration($style);
|
||||
|
||||
// Check for model errors.
|
||||
if ($errors = $this->get('Errors')) {
|
||||
$app->enqueueMessage(implode('<br />', $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
// Bind the form to the data.
|
||||
if ($form && $data) {
|
||||
$form->bind($data);
|
||||
}
|
||||
|
||||
// Check for errors.
|
||||
$errors = $this->get('Errors');
|
||||
if (is_array($errors) && count($errors)) {
|
||||
$app->enqueueMessage(implode("\n", $errors), 'error');
|
||||
return false;
|
||||
}
|
||||
|
||||
// Load Script
|
||||
$wa = $app->getDocument()->getWebAssetManager();
|
||||
$wa->useScript('jquery');
|
||||
$wa->registerScript('jem.colorpicker_js', 'com_jem/colorpicker.js')->useScript('jem.colorpicker_js');
|
||||
|
||||
if (!JemFactory::getUser()->authorise('core.manage', 'com_jem')) {
|
||||
$app->enqueueMessage(Text::_('JERROR_ALERTNOAUTHOR'), 'warning');
|
||||
$app->redirect('index.php?option=com_jem&view=main');
|
||||
}
|
||||
|
||||
// mapping variables
|
||||
$this->form = $form;
|
||||
$this->data = $data;
|
||||
$this->state = $state;
|
||||
$this->jemsettings = $jemsettings;
|
||||
$this->config = $config;
|
||||
|
||||
// add toolbar
|
||||
$this->addToolbar();
|
||||
|
||||
parent::display($tpl);
|
||||
}
|
||||
|
||||
/**
|
||||
* Add the page title and toolbar.
|
||||
*
|
||||
* @since 1.6
|
||||
*/
|
||||
protected function addToolbar()
|
||||
{
|
||||
ToolbarHelper::title(Text::_('COM_JEM_SETTINGS_TITLE'), 'settings');
|
||||
ToolbarHelper::apply('settings.apply');
|
||||
ToolbarHelper::save('settings.save');
|
||||
ToolbarHelper::cancel('settings.cancel');
|
||||
|
||||
ToolbarHelper::divider();
|
||||
ToolbarHelper::inlinehelp();
|
||||
ToolBarHelper::help('settings', true, 'https://www.joomlaeventmanager.net/documentation/manual/backend/settings');
|
||||
}
|
||||
|
||||
protected function WarningIcon()
|
||||
{
|
||||
$url = Uri::root();
|
||||
// $tip = '<img src="'.$url.'media/system/images/tooltip.png" border="0" alt="" />';
|
||||
$tip = '<span class="icon-info-circle" aria-hidden="true"></span>';
|
||||
|
||||
return $tip;
|
||||
}
|
||||
}
|
||||
1
administrator/components/com_jem/views/source/index.html
Normal file
1
administrator/components/com_jem/views/source/index.html
Normal file
@ -0,0 +1 @@
|
||||
<!DOCTYPE html><title></title>
|
||||
58
administrator/components/com_jem/views/source/tmpl/edit.php
Normal file
58
administrator/components/com_jem/views/source/tmpl/edit.php
Normal file
@ -0,0 +1,58 @@
|
||||
<?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\HTML\HTMLHelper;
|
||||
use Joomla\CMS\Language\Text;
|
||||
use Joomla\CMS\Factory;
|
||||
use Joomla\CMS\Router\Route;
|
||||
|
||||
HTMLHelper::addIncludePath(JPATH_COMPONENT.'/helpers/html');
|
||||
$app = Factory::getApplication();
|
||||
$document = $app->getDocument();
|
||||
$wa = $document->getWebAssetManager();
|
||||
$wa->useScript('keepalive')
|
||||
->useScript('form.validate')
|
||||
?>
|
||||
<script>
|
||||
Joomla.submitbutton = function(task)
|
||||
{
|
||||
if (task == 'source.cancel' || document.formvalidator.isValid(document.getElementById('source-form'))) {
|
||||
<?php //echo $this->form->getField('source')->save(); ?>
|
||||
Joomla.submitform(task, document.getElementById('source-form'));
|
||||
} else {
|
||||
alert('<?php echo $this->escape(Text::_('JGLOBAL_VALIDATION_FORM_FAILED'));?>');
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<form action="<?php echo Route::_('index.php?option=com_jem&layout=edit'); ?>" method="post" name="adminForm" id="source-form" class="form-validate">
|
||||
<?php if ($this->ftp) : ?>
|
||||
<?php echo $this->loadTemplate('ftp'); ?>
|
||||
<?php endif; ?>
|
||||
<fieldset class="adminform">
|
||||
<legend><?php
|
||||
if ($this->source->custom) {
|
||||
echo Text::sprintf('COM_JEM_CSSMANAGER_FILENAME_CUSTOM', $this->source->filename);
|
||||
} else {
|
||||
echo Text::sprintf('COM_JEM_CSSMANAGER_FILENAME', $this->source->filename);
|
||||
}
|
||||
?></legend>
|
||||
|
||||
<?php echo $this->form->getLabel('source'); ?>
|
||||
<div class="clr"></div>
|
||||
<div class="editor-border">
|
||||
<?php echo $this->form->getInput('source'); ?>
|
||||
</div>
|
||||
<input type="hidden" name="task" value="" />
|
||||
<?php echo HTMLHelper::_('form.token'); ?>
|
||||
</fieldset>
|
||||
|
||||
<?php echo $this->form->getInput('filename'); ?>
|
||||
</form>
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user