Beispiel #1
0
    $blindIndex++;
}
?>
           <td class='count_row_total' id='<?php 
echo carTotalId();
?>
'></td>
        </tr>
        <!-- ########################### Hunt Hours ###################### -->
        <tr>
            <td class="count_first_column">No. Hours on Refuge</td>
            <?php 
$blindIndex = 0;
foreach ($blindList as $oneBlind) {
    $oldId = generateOldIdAtBlind("NUM_HOURS", $blindIndex);
    $newId = generateNewIdAtBlind("NUM_HOURS", $blindIndex);
    $value = $oneBlind->getNumHours();
    ?>
			<td class='count'>
            	<input type='hidden' name="<?php 
    echo $oldId;
    ?>
" value='<?php 
    echo $value;
    ?>
' />
                <input class="count_input" type='text' name='<?php 
    echo $newId;
    ?>
' id='<?php 
    echo $newId;
function bagCheckUpdateHuntInformation($bagCheckInfo)
{
    $blindList = $bagCheckInfo->getBlindList();
    $blindIndex = 0;
    foreach ($blindList as $oneBlind) {
        // Blind Number
        $oldBlindNumLabel = generateOldIdAtBlind("BLIND_NUMBER", $blindIndex);
        $oldBlindNum = $_POST[$oldBlindNumLabel];
        $newBlindNumLabel = generateNewIdAtBlind("BLIND_NUMBER", $blindIndex);
        $newBlindNum = $_POST[$newBlindNumLabel];
        $oldBlindNum = blankToZero($oldBlindNum);
        $newBlindNum = blankToZero($newBlindNum);
        if ($oldBlindNum != $newBlindNum) {
            $oneBlind->setBlindNumber($newBlindNum);
        }
        // Number of Hunters
        $oldNumHuntersLabel = generateOldIdAtBlind("HUNTER_COUNT", $blindIndex);
        $oldNumHunters = $_POST[$oldNumHuntersLabel];
        $newNumHuntersLabel = generateNewIdAtBlind("HUNTER_COUNT", $blindIndex);
        $newNumHunters = $_POST[$newNumHuntersLabel];
        $oldNumHunters = blankToZero($oldNumHunters);
        $newNumHunters = blankToZero($newNumHunters);
        if ($oldNumHunters != $newNumHunters) {
            $oneBlind->setNumHunters($newNumHunters);
        }
        // Number of Cars
        $oldNumCarsLabel = generateOldIdAtBlind("CAR_COUNT", $blindIndex);
        $oldNumCars = $_POST[$oldNumCarsLabel];
        $newNumCarsLabel = generateNewIdAtBlind("CAR_COUNT", $blindIndex);
        $newNumCars = $_POST[$newNumCarsLabel];
        $oldNumCars = blankToZero($oldNumCars);
        $newNumCars = blankToZero($newNumCars);
        if ($oldNumCars != $newNumCars) {
            $oneBlind->setNumCars($newNumCars);
        }
        // Number of Hours
        $oldNumHoursLabel = generateOldIdAtBlind("NUM_HOURS", $blindIndex);
        $oldNumHours = $_POST[$oldNumHoursLabel];
        $newNumHoursLabel = generateNewIdAtBlind("NUM_HOURS", $blindIndex);
        $newNumHours = $_POST[$newNumHoursLabel];
        $oldNumHours = blankToZero($oldNumHours);
        $newNumHours = blankToZero($newNumHours);
        if ($oldNumHours != $newNumHours) {
            $oneBlind->setNumHours($newNumHours);
        }
        $blindIndex++;
    }
}