<?php foreach ($applicableMonths as $year => $detail) { foreach ($detail as $detail => $detail1) { foreach ($allForestPoints as $pointId => $name) { $timberInoutDetail = array(); $pending[$pointId]; ?> <tr> <td> <?php if ($pointId == -1 || $pointId == 0) { $timberInoutDetail = $markDetail->getForestInOut($markDetailId, $detail1['vc_month'], $detail1['vc_year']); } else { $timberInoutDetail = $markDetail->getPointInOut($markDetailId, $detail1['vc_month'], $detail1['vc_year'], $pointId); } echo $arrMonths[$detail1['vc_month']] . '-' . $detail1['vc_year']; ?> </td> <td> <?php echo $name; ?> </td> <?php if ($timberInoutDetail != null && count($timberInoutDetail) > 0) { ?> <?php foreach ($timberInoutDetail as $treeId => $InOutDetail) {
if ($previousCount == 1) { if ($id == '-1' || $id == '0') { $previousDetailYear1 = $markDetail->getForestPrevInOutY($key, $month, $year, $treeId); } else { $previousDetailYear1 = $markDetail->getPointPrevInOutY($key, $month, $year, $id, $treeId); } $previousDetailYearResult[$treeId][$id] = $previousDetailYear1; } $previousDetailYear = $previousDetailYearResult[$treeId][$id]; $previousYearTotal = display_float(display_float($previousDetailYear[$treeId]['InVolume'], 3) - display_float($previousDetailYear[$treeId]['OutVolume'], 3)); $previousYearTotalCount = display_float(display_float($previousDetailYear[$treeId]['InCount'], 3) - display_float($previousDetailYear[$treeId]['OutCount'], 3)); //*/ if ($id == '-1' || $id == '0') { $timberInoutDetail = $markDetail->getForestInOut($key, $month, $year); } else { $timberInoutDetail = $markDetail->getPointInOut($key, $month, $year, $id); } $previousDetail = array(); if ($id == '-1' || $id == '0') { $previousDetail = $markDetail->getForestPrevInOut($key, $month, $year, $treeId); } else { $previousDetail = $markDetail->getPointPrevInOut($key, $month, $year, $id, $treeId); } ?> <tr> <td><?php echo $name; ?> </td> <td >