tpl fixes, dont use printHtml for none-string types

This commit is contained in:
Dennis Eichhorn 2020-12-06 11:13:19 +01:00
parent 890b60d421
commit 63b8016d65
2 changed files with 10 additions and 10 deletions

View File

@ -40,10 +40,10 @@ echo $this->getData('nav')->render(); ?>
<td data-label="<?= $this->getHtml('ID', '0', '0'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->number); ?></a>
<td data-label="<?= $this->getHtml('Name1'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->profile->account->name1); ?></a>
<td data-label="<?= $this->getHtml('Name2'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->profile->account->name2); ?></a>
<td data-label="<?= $this->getHtml('City'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->getMainAddress()->city); ?></a>
<td data-label="<?= $this->getHtml('Zip'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->getMainAddress()->postal); ?></a>
<td data-label="<?= $this->getHtml('Address'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->getMainAddress()->address); ?></a>
<td data-label="<?= $this->getHtml('Country'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->getMainAddress()->getCountry()); ?></a>
<td data-label="<?= $this->getHtml('City'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->mainAddress->city); ?></a>
<td data-label="<?= $this->getHtml('Zip'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->mainAddress->postal); ?></a>
<td data-label="<?= $this->getHtml('Address'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->mainAddress->address); ?></a>
<td data-label="<?= $this->getHtml('Country'); ?>"><a href="<?= $url; ?>"><?= $this->printHtml($value->mainAddress->getCountry()); ?></a>
<?php endforeach; ?>
<?php if ($count === 0) : ?>
<tr><td colspan="8" class="empty"><?= $this->getHtml('Empty', '0', '0'); ?>

View File

@ -67,20 +67,20 @@ echo $this->getData('nav')->render();
<tr><td><label for="iName3"><?= $this->getHtml('Name3'); ?></label>
<tr><td><input type="text" id="iName3" name="name3" value="<?= $this->printHtml($supplier->profile->account->name3); ?>">
<tr><td><h3><?= $this->getHtml('Address'); ?></h3>
<?php if (!empty($supplier->getMainAddress()->addition)) : ?>
<?php if (!empty($supplier->mainAddress->addition)) : ?>
<tr><td><label for="iName1"><?= $this->getHtml('Addition'); ?></label>
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->getMainAddress()->addition); ?>">
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->mainAddress->addition); ?>">
<?php endif; ?>
<tr><td><label for="iName1"><?= $this->getHtml('Address'); ?></label>
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->getMainAddress()->address); ?>" required>
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->mainAddress->address); ?>" required>
<tr><td><label for="iName1"><?= $this->getHtml('Postal'); ?></label>
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->getMainAddress()->postal); ?>" required>
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->mainAddress->postal); ?>" required>
<tr><td><label for="iName1"><?= $this->getHtml('City'); ?></label>
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->getMainAddress()->city); ?>" required>
<tr><td><input type="text" id="iName1" name="name1" value="<?= $this->printHtml($supplier->mainAddress->city); ?>" required>
<tr><td><label for="iName1"><?= $this->getHtml('Country'); ?></label>
<tr><td><select>
<?php foreach ($countryCodes as $code3 => $code2) : ?>
<option value="<?= $this->printHtml($code2); ?>"<?= $this->printHtml($code2 === $supplier->getMainAddress()->getCountry() ? ' selected' : ''); ?>><?= $this->printHtml($countries[$code3]); ?>
<option value="<?= $this->printHtml($code2); ?>"<?= $this->printHtml($code2 === $supplier->mainAddress->getCountry() ? ' selected' : ''); ?>><?= $this->printHtml($countries[$code3]); ?>
<?php endforeach; ?>
</select>
</table>