started with template fixes

This commit is contained in:
Dennis Eichhorn 2024-03-29 15:26:00 +00:00
parent ab0950ce72
commit 407af87b45
2 changed files with 10 additions and 9 deletions

View File

@ -33,16 +33,17 @@ echo $this->data['nav']->render(); ?>
<td><?= $this->getHtml('Start'); ?>
<td><?= $this->getHtml('Due'); ?>
<tbody>
<?php $count = 0; foreach ($list as $key => $value) : ++$count;
$url = \phpOMS\Uri\UriFactory::build('marketing/promotion/view?{?}&id=' . $value->id); ?>
<?php $count = 0;
foreach ($list as $key => $value) : ++$count;
$url = \phpOMS\Uri\UriFactory::build('marketing/promotion/view?{?}&id=' . $value->id); ?>
<tr tabindex="0" data-href="<?= $url; ?>">
<td data-label="<?= $this->getHtml('Title'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->name); ?></a>
<td data-label="<?= $this->getHtml('Start'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->getStart()->format('Y-m-d')); ?></a>
<td data-label="<?= $this->getHtml('Due'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->getEnd()->format('Y-m-d')); ?></a>
<td data-label="<?= $this->getHtml('Start'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->start?->format('Y-m-d')); ?></a>
<td data-label="<?= $this->getHtml('Due'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->end?->format('Y-m-d')); ?></a>
<?php endforeach; ?>
<?php if ($count === 0) : ?>
<tr><td colspan="5" class="empty"><?= $this->getHtml('Empty', '0', '0'); ?>
<?php endif; ?>
<?php endif; ?>
</table>
</div>
</div>

View File

@ -21,7 +21,7 @@ echo $this->data['nav']->render(); ?>
<div class="row">
<div class="col-xs-12 col-md-6">
<section class="portlet">
<form action="<?= \phpOMS\Uri\UriFactory::build('{/api}marketing/promotion'); ?>" method="post">
<form action="<?= \phpOMS\Uri\UriFactory::build('{/api}marketing/promotion?csrf={$CSRF}'); ?>" method="post">
<div class="portlet-head"><?= $this->getHtml('Promotion'); ?></div>
<div class="portlet-body">
<div class="form-group">
@ -39,11 +39,11 @@ echo $this->data['nav']->render(); ?>
<textarea id="iDescription" name="description"></textarea>
</div>
<div class="line-flex">
<div class="flex-line">
<div>
<div class="form-group">
<label for="iStart"><?= $this->getHtml('Start'); ?></label>
<input id="iSTart" type="datetime-local">
<input id="iStart" type="datetime-local">
</div>
</div>
@ -57,7 +57,7 @@ echo $this->data['nav']->render(); ?>
<div class="form-group">
<label for="iBudget"><?= $this->getHtml('Budget'); ?></label>
<input type="text" id="iBudget" name="budget" placeholder="">
<input type="text" id="iBudget" name="budget">
</div>
</div>
<div class="portlet-foot">