depot/admin/tmpl/part/edit.php

62 lines
1.8 KiB
PHP
Raw Permalink Normal View History

2023-10-05 02:28:17 +02:00
<?php
/**
* @package Depot.Administrator
* @subpackage com_depot
* @author Thomas Kuschel <thomas@kuschel.at>
* @copyright (C) 2023 KW4NZ, <https://www.kuschel.at>
* @license GNU General Public License version 2 or later; see LICENSE.md
* @since 0.9.2
2023-10-05 02:28:17 +02:00
*/
use Joomla\CMS\HTML\HTMLHelper;
2023-10-14 21:15:09 +02:00
use Joomla\CMS\Language\Text;
2023-10-05 11:45:44 +02:00
use Joomla\CMS\Router\Route;
2023-10-05 02:28:17 +02:00
2023-10-06 04:47:51 +02:00
/** @var Joomla\CMS\WebAsset\WebAssetManager $wa */
$wa = $this->document->getWebAssetManager();
$wa->useScript('form.validate')
->useScript('keepalive');
2023-10-05 02:28:17 +02:00
?>
2023-10-07 23:33:29 +02:00
<form action="<?= Route::_('index.php?option=com_depot&view=part&layout=edit&id=' . (int) $this->item->id); ?>"
2023-10-05 02:28:17 +02:00
method="post" name="adminForm" id="item-form" class="form-validate">
2023-10-15 11:40:55 +02:00
<?= HtmlHelper::_('uitab.startTabSet', 'myTab', ['active' => 'details']); ?>
<?= HTMLHelper::_(
'uitab.addTab',
'myTab',
'details',
empty($this->item->id) ? Text::_('COM_DEPOT_TAB_NEW_PART') :
Text::_('COM_DEPOT_TAB_EDIT_PART')
); ?>
<fieldset id="fieldset-details" class="options-form">
<legend>
<?= Text::_('COM_DEPOT_LEGEND_PART_DETAILS') ?>
2023-10-15 11:40:55 +02:00
</legend>
<div class="row">
<div class="col-12 col-lg-6">
<?= $this->form->renderFieldset('details'); ?>
</div>
<div class="col-12 col-lg-6">
<?= $this->form->getInput('description'); ?>
</div>
</div>
</fieldset>
<?= HtmlHelper::_('uitab.endTab'); ?>
2023-10-05 02:28:17 +02:00
2023-10-15 11:40:55 +02:00
<?= HTMLHelper::_('uitab.addTab', 'myTab', 'statistics', Text::_('COM_DEPOT_TAB_STATISTICS')); ?>
<fieldset class="options-form">
<legend>
<?= Text::_('COM_DEPOT_LEGEND_STATISTICS') ?>
</legend>
<div class="row">
<div class="col-12 col-lg-9">
<?= $this->form->renderFieldset('statistics'); ?>
2023-10-14 21:15:09 +02:00
</div>
2023-10-15 11:40:55 +02:00
</div>
</fieldset>
<?= HTMLHelper::_('uitab.endTab'); ?>
<?= HtmlHelper::_('uitab.endTabSet'); ?>
2023-10-05 02:28:17 +02:00
<input type="hidden" name="task" value="part.edit" />
2023-10-07 23:33:29 +02:00
<?= HTMLHelper::_('form.token'); ?>
2023-10-05 14:56:39 +02:00
</form>