This commit is contained in:
Dennis Eichhorn 2024-03-10 02:24:56 +00:00
parent 8ed9b9b7ef
commit 48efd5cdc4
3 changed files with 37 additions and 22 deletions

View File

@ -107,7 +107,10 @@ echo $this->data['nav']->render(); ?>
<td data-label="<?= $this->getHtml('Tag'); ?>"> <td data-label="<?= $this->getHtml('Tag'); ?>">
<?php <?php
foreach ($template->tags as $tag) : ?> foreach ($template->tags as $tag) : ?>
<span class="tag" style="background: <?= $this->printHtml($tag->color); ?>"><?= empty($tag->icon) ? '' : ''; ?><?= $this->printHtml($tag->getL11n()); ?></span> <span class="tag" style="background: <?= $this->printHtml($tag->color); ?>">
<?= empty($tag->icon) ? '' : '<i class="g-icon">' . $this->printHtml($tag->icon) . '</i>'; ?>
<?= $this->printHtml($tag->getL11n()); ?>
</span>
<?php endforeach; ?> <?php endforeach; ?>
<td data-label="<?= $this->getHtml('Creator'); ?>"><a class="content" href="<?= UriFactory::build('{/base}/profile/view?{?}&for=' . $template->createdBy->id); ?>"><?= $this->printHtml($this->renderUserName('%3$s %2$s %1$s', [$template->createdBy->name1, $template->createdBy->name2, $template->createdBy->name3, $template->createdBy->login ?? ''])); ?></a> <td data-label="<?= $this->getHtml('Creator'); ?>"><a class="content" href="<?= UriFactory::build('{/base}/profile/view?{?}&for=' . $template->createdBy->id); ?>"><?= $this->printHtml($this->renderUserName('%3$s %2$s %1$s', [$template->createdBy->name1, $template->createdBy->name2, $template->createdBy->name3, $template->createdBy->login ?? ''])); ?></a>
<td data-label="<?= $this->getHtml('Updated'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($template->createdAt->format('Y-m-d')); ?></a> <td data-label="<?= $this->getHtml('Updated'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($template->createdAt->format('Y-m-d')); ?></a>

View File

@ -21,26 +21,35 @@ echo $this->data['nav']->render(); ?>
<form id="helper-template-create" action="<?= \phpOMS\Uri\UriFactory::build('{/api}helper/report/template'); ?>" method="post"> <form id="helper-template-create" action="<?= \phpOMS\Uri\UriFactory::build('{/api}helper/report/template'); ?>" method="post">
<div class="portlet-head"><?= $this->getHtml('Template'); ?></div> <div class="portlet-head"><?= $this->getHtml('Template'); ?></div>
<div class="portlet-body"> <div class="portlet-body">
<table class="layout wf-100" style="table-layout: fixed"> <div class="form-group">
<tbody> <label for="iTitle"><?= $this->getHtml('Title'); ?></label>
<tr><td><label for="iTitle"><?= $this->getHtml('Title'); ?></label> <input id="iTitle" name="name" type="text" placeholder="P&L Reporting" required>
<tr><td><input id="iTitle" name="name" type="text" placeholder="P&L Reporting" required> </div>
<tr><td><label for="iDescription"><?= $this->getHtml('Description'); ?></label>
<tr><td><?= $this->getData('editor')->render('report-editor'); ?> <div class="form-group">
<tr><td><?= $this->getData('editor')->getData('text')->render('report-editor', 'description', 'helper-template-create'); ?> <label for="iDescription"><?= $this->getHtml('Description'); ?></label>
<tr><td> <?= $this->getData('editor')->render('report-editor'); ?>
<label class="checkbox" for="iStandalone"> </div>
<input type="checkbox" name="standalone" id="iStandalone" value="1" checked>
<span class="checkmark"></span> <div class="form-group">
<?= $this->getHtml('Standalone'); ?> <?= $this->getData('editor')->getData('text')->render('report-editor', 'description', 'helper-template-create'); ?>
</label> </div>
<tr><td><label for="iExpected"><?= $this->getHtml('Expected'); ?></label>
<tr><td> <div class="form-group">
<div class="ipt-wrap"> <label class="checkbox" for="iStandalone">
<div class="ipt-first"><input id="iExpected" type="text" placeholder="file.csv"><input name="expected" type="hidden"></div> <input type="checkbox" name="standalone" id="iStandalone" value="1" checked>
<div class="ipt-second"><button><?= $this->getHtml('Add', '0', '0'); ?></button></div> <span class="checkmark"></span>
</div> <?= $this->getHtml('Standalone'); ?>
</table> </label>
</div>
<div class="form-group">
<label for="iExpected"><?= $this->getHtml('Expected'); ?></label>
<div class="ipt-wrap">
<div class="ipt-first"><input id="iExpected" type="text" placeholder="file.csv"><input name="expected" type="hidden"></div>
<div class="ipt-second"><button><?= $this->getHtml('Add', '0', '0'); ?></button></div>
</div>
</div>
</div> </div>
<div class="portlet-foot"> <div class="portlet-foot">
<input type="submit" id="iReportTemplateCreateButton" name="reportTemplateCreateButton" value="<?= $this->getHtml('Create', '0', '0'); ?>"> <input type="submit" id="iReportTemplateCreateButton" name="reportTemplateCreateButton" value="<?= $this->getHtml('Create', '0', '0'); ?>">

View File

@ -162,7 +162,10 @@ echo $this->data['nav']->render(); ?>
<td><?= $this->getHtml('Tags'); ?> <td><?= $this->getHtml('Tags'); ?>
<td><?php <td><?php
foreach ($template->tags as $tag) : ?> foreach ($template->tags as $tag) : ?>
<span class="tag" style="background: <?= $this->printHtml($tag->color); ?>"><?= empty($tag->icon) ? '' : ''; ?><?= $this->printHtml($tag->getL11n()); ?></span> <span class="tag" style="background: <?= $this->printHtml($tag->color); ?>">
<?= empty($tag->icon) ? '' : '<i class="g-icon">' . $this->printHtml($tag->icon) . '</i>'; ?>
<?= $this->printHtml($tag->getL11n()); ?>
</span>
<?php endforeach; ?> <?php endforeach; ?>
</table> </table>
</div> </div>