fix tests

This commit is contained in:
Dennis Eichhorn 2022-10-08 21:35:00 +02:00
parent ccd9a5bf80
commit 10d202a900
5 changed files with 9 additions and 7 deletions

View File

@ -100,4 +100,5 @@ return ['SupplierManagement' => [
'Wire' => 'Wire',
'YTDSales' => 'YTD Sales',
'Zip' => 'Zip',
'IMG_alt_map' => 'Map',
]];

View File

@ -45,7 +45,7 @@ echo $this->getData('nav')->render(); ?>
<tr><td><input type="text" id="iName2" name="name2" placeholder="&#xf040;">
<tr><td><label for="iName3"><?= $this->getHtml('Name3'); ?></label>
<tr><td><input type="text" id="iName3" name="name3" placeholder="&#xf040;">
<tr><td colspan="2"><input type="submit" value="<?= $this->getHtml('Create', '0', '0'); ?>">
<tr><td colspan="2"><input type="submit" value="<?= $this->getHtml('Create', '0', '0'); ?>" name="create-supplier">
</table>
</form>
</div>

View File

@ -106,7 +106,7 @@ echo $this->getData('nav')->render(); ?>
$url = UriFactory::build('{/prefix}purchase/supplier/profile?{?}&id=' . $value->getId());
$image = $value->getFileByType(0); ?>
<tr data-href="<?= $url; ?>">
<td><a href="<?= $url; ?>"><img width="30" loading="lazy" class="item-image"
<td><a href="<?= $url; ?>"><img alt="<?= $this->getHtml('IMG_alt_supplier'); ?>" width="30" loading="lazy" class="item-image"
src="<?= $image instanceof NullMedia ?
UriFactory::build('Web/Backend/img/user_default_' . \mt_rand(1, 6) .'.png') :
UriFactory::build('{/prefix}' . $image->getPath()); ?>"></a>

View File

@ -77,7 +77,7 @@ echo $this->getData('nav')->render();
</table>
</div>
<div class="portlet-foot">
<input type="submit" value="<?= $this->getHtml('Save', '0', '0'); ?>"> <input type="submit" value="<?= $this->getHtml('Delete', '0', '0'); ?>">
<input type="submit" value="<?= $this->getHtml('Save', '0', '0'); ?>" name="save-supplier-profile"> <input type="submit" value="<?= $this->getHtml('Delete', '0', '0'); ?>" name="delete-supplier-profile">
</div>
</form>
</section>
@ -135,15 +135,15 @@ echo $this->getData('nav')->render();
<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->mainAddress->city); ?>" required>
<tr><td><label for="iName1"><?= $this->getHtml('Country'); ?></label>
<tr><td><select>
<tr><td><label for="iCountry"><?= $this->getHtml('Country'); ?></label>
<tr><td><select id="iCountry" name="country">
<?php foreach ($countryCodes as $code3 => $code2) : ?>
<option value="<?= $this->printHtml($code2); ?>"<?= $this->printHtml($code2 === $supplier->mainAddress->getCountry() ? ' selected' : ''); ?>><?= $this->printHtml($countries[$code3]); ?>
<?php endforeach; ?>
</select>
<tr><td>
<?php if (\is_file(__DIR__ . '/../../../../phpOMS/Localization/Maps/svg/' . \strtolower($supplier->mainAddress->getCountry()) . '.svg')) : ?>
<img id="iMap" style="width: 100%;" src="<?= UriFactory::build('phpOMS/Localization/Maps/svg/' . \strtolower($supplier->mainAddress->getCountry()) . '.svg'); ?>">
<img alt="<?= $this->getHtml('IMG_alt_map'); ?>" id="iMap" style="width: 100%;" src="<?= UriFactory::build('phpOMS/Localization/Maps/svg/' . \strtolower($supplier->mainAddress->getCountry()) . '.svg'); ?>">
<?php endif; ?>
</table>
</div>

View File

@ -1,4 +1,5 @@
<?php declare(strict_types=1);
<?php
declare(strict_types=1);
// Modules/tests