Created
June 23, 2017 19:09
-
-
Save mvnp/eface2a5024f22cd30c00bcc2bc99726 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
foreach ($planilha as $info) : ?> | |
<?php $count = 0; $total = 0; $remove = 0; ?> | |
<?php if($count == 0 OR ($count % 13 == 0)) : $count++; ?> | |
<tr> | |
<?php for ($i = 0; $i < 13; $i++) : ?> | |
<?php $remove = $info[0]['ORCD_VLR']; ?> | |
<?php if($i == 0) : ?> | |
<td><?php echo $info[$i]['PCT_DESCRICAO'] ?></td> | |
<td><?php echo $info[$i]['NAT_DESCRICAO'] ?></td> | |
<?php else : ?> | |
<td> | |
<?php echo "<input type='text' value='".currencye($info[$i-1]['ORCD_VLR'])."' class='valor' />" ?> | |
</td> | |
<?php endif; ?> | |
<?php $total += $info[$i]['ORCD_VLR']; ?> | |
<?php endfor; ?> | |
<td class="valor retornatotal blue"> | |
<?php echo "<input type='text' value='".currencye((($total-$remove)/12))."' class='valor blue' />" ?> | |
</td> | |
<td class="valor retornamedia"> | |
<?php echo "<input type='text' value='".currencye(($total-$remove))."' class='valor laranja' />" ?> | |
</td> | |
</tr> | |
<?php endif; ?> | |
<?php endforeach; ?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment