[ Index ] |
PHP Cross Reference of Joomla 4.2.2 documentation |
[Summary view] [Print] [Text view]
1 <?php 2 3 /** 4 * @package Joomla.Site 5 * @subpackage Layout 6 * 7 * @copyright (C) 2018 Open Source Matters, Inc. <https://www.joomla.org> 8 * @license GNU General Public License version 2 or later; see LICENSE.txt 9 */ 10 11 use Joomla\CMS\HTML\HTMLHelper; 12 use Joomla\CMS\Language\Text; 13 14 // phpcs:disable PSR1.Files.SideEffects 15 \defined('_JEXEC') or die; 16 // phpcs:enable PSR1.Files.SideEffects 17 18 extract($displayData, EXTR_OVERWRITE); 19 20 /** 21 * Layout variables 22 * ----------------- 23 * @var string $icon 24 * @var string $title 25 * @var string $value 26 * @var string $task 27 * @var array $options 28 */ 29 30 $disabled = empty($options['transitions']) || !empty($options['disabled']); 31 $id = $options['id']; 32 $tipTitle = $options['tip_title']; 33 $tipContent = $options['tip_content']; 34 $checkboxName = $options['checkbox_name']; 35 $task = $options['task']; 36 37 ?> 38 <button type="button" class="tbody-icon data-state-<?php echo $this->escape($value ?? ''); ?>" 39 aria-labelledby="<?php echo $id; ?>" 40 <?php echo $disabled ? 'disabled' : ''; ?> 41 <?php if (!$disabled) : ?> 42 onclick="Joomla.toggleAllNextElements(this, 'd-none')" 43 <?php endif; ?> 44 > 45 <span class="<?php echo $this->escape($icon ?? ''); ?>" aria-hidden="true"></span> 46 </button> 47 <div id="<?php echo $id; ?>" role="tooltip"> 48 <?php echo HTMLHelper::_('tooltipText', $tipTitle ?: $title, $tipContent, 0, false); ?> 49 </div> 50 51 <?php if (!$disabled) : ?> 52 <div class="d-none"> 53 <span class="visually-hidden"> 54 <label for="transition-select_<?php echo (int) $row ?? ''; ?>"> 55 <?php echo Text::_('JWORKFLOW_EXECUTE_TRANSITION'); ?> 56 </label> 57 </span> 58 <?php 59 $default = [ 60 HTMLHelper::_('select.option', '', $this->escape($options['title'])), 61 HTMLHelper::_('select.option', '-1', '--------', ['disable' => true]) 62 ]; 63 64 $transitions = array_merge($default, $options['transitions']); 65 66 $attribs = [ 67 'id' => 'transition-select_' . (int) $row ?? '', 68 'list.attr' => [ 69 'class' => 'form-select form-select-sm w-auto', 70 'onchange' => "this.form.transition_id.value=this.value;Joomla.listItemTask('" . $checkboxName . $this->escape($row ?? '') . "', '" . $task . "')"] 71 ]; 72 73 echo HTMLHelper::_('select.genericlist', $transitions, '', $attribs); 74 ?> 75 </div> 76 <?php endif; ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Wed Sep 7 05:41:13 2022 | Chilli.vc Blog - For Webmaster,Blog-Writer,System Admin and Domainer |