Fix increment to pre-increment

This commit is contained in:
Dennis Eichhorn 2019-05-19 19:08:35 +02:00
parent 49a3f1a03c
commit 6ef5eb3a3e
4 changed files with 7 additions and 7 deletions

View File

@ -33,7 +33,7 @@ echo $this->getData('nav')->render(); ?>
<tfoot>
<tr><td colspan="5">
<tbody>
<?php $c = 0; foreach ($this->getData('list:elements') as $key => $value) : $c++;
<?php $c = 0; foreach ($this->getData('list:elements') as $key => $value) : ++$c;
$url = \phpOMS\Uri\UriFactory::build('{/prefix}admin/account/settings?{?}&id=' . $value->getId());
$color = 'darkred';
if ($value->getStatus() === AccountStatus::ACTIVE) { $color = 'green'; }

View File

@ -113,7 +113,7 @@ echo $this->getData('nav')->render(); ?>
<td><?= $this->getHtml('ID', '0', '0'); ?><i class="sort-asc fa fa-chevron-up"></i><i class="sort-desc fa fa-chevron-down"></i>
<td class="wf-100"><?= $this->getHtml('Name') ?><i class="sort-asc fa fa-chevron-up"></i><i class="sort-desc fa fa-chevron-down"></i>
<tbody>
<?php $c = 0; $groups = $account->getGroups(); foreach ($groups as $key => $value) : $c++;
<?php $c = 0; $groups = $account->getGroups(); foreach ($groups as $key => $value) : ++$c;
$url = \phpOMS\Uri\UriFactory::build('{/prefix}admin/group/settings?{?}&id=' . $value->getId()); ?>
<tr data-href="<?= $url; ?>">
<td><a href="#"><i class="fa fa-times"></i></a>
@ -158,7 +158,7 @@ echo $this->getData('nav')->render(); ?>
<td><?= $this->getHtml('Comp'); ?>
<td class="wf-100"><?= $this->getHtml('Perm'); ?>
<tbody>
<?php $c = 0; foreach ($permissions as $key => $value) : $c++; $permission = $value->getPermission(); ?>
<?php $c = 0; foreach ($permissions as $key => $value) : ++$c; $permission = $value->getPermission(); ?>
<tr>
<td><a href="#"><i class="fa fa-times"></i></a>
<td><a href="#"><i class="fa fa-cogs"></i></a>

View File

@ -29,7 +29,7 @@ echo $this->getData('nav')->render(); ?>
<tfoot>
<tr><td colspan="5">
<tbody>
<?php $c = 0; foreach ($this->getData('list:elements') as $key => $value) : $c++;
<?php $c = 0; foreach ($this->getData('list:elements') as $key => $value) : ++$c;
$url = \phpOMS\Uri\UriFactory::build('{/prefix}admin/group/settings?{?}&id=' . $value->getId());
$color = 'darkred';
if ($value->getStatus() === \phpOMS\Account\GroupStatus::ACTIVE) { $color = 'green'; }

View File

@ -68,7 +68,7 @@ echo $this->getData('nav')->render(); ?>
<td><?= $this->getHtml('ID', '0', '0'); ?><i class="sort-asc fa fa-chevron-up"></i><i class="sort-desc fa fa-chevron-down"></i>
<td class="wf-100"><?= $this->getHtml('Name'); ?><i class="sort-asc fa fa-chevron-up"></i><i class="sort-desc fa fa-chevron-down"></i>
<tbody>
<?php $c = 0; foreach ($accounts as $key => $value) : $c++; ?>
<?php $c = 0; foreach ($accounts as $key => $value) : ++$c; ?>
<tr>
<td><a href="#"><i class="fa fa-times"></i></a>
<td><a href="<?= \phpOMS\Uri\UriFactory::build('{/prefix}admin/account/settings?{?}&id=' . $value->getId()) ?>"><?= $value->getName1(); ?></a>
@ -126,7 +126,7 @@ echo $this->getData('nav')->render(); ?>
</td>
</tr>
</template>
<?php $c = 0; foreach ($permissions as $key => $value) : $c++; $permission = $value->getPermission(); ?>
<?php $c = 0; foreach ($permissions as $key => $value) : ++$c; $permission = $value->getPermission(); ?>
<tr>
<td><a href="#"><i class="fa fa-times"></i></a>
<td><a href="#"><i class="fa fa-cogs"></i></a>
@ -212,7 +212,7 @@ echo $this->getData('nav')->render(); ?>
<td><?= $this->getHtml('ID', '0', '0'); ?>
<td class="wf-100">Name
<tbody>
<?php $c = 0; foreach ([] as $key => $value) : $c++; ?>
<?php $c = 0; foreach ([] as $key => $value) : ++$c; ?>
<tr>
<td><a href="#"><i class="fa fa-times"></i></a>
<td>