?
Current Path : /home1/savoy/public_html/savoyglobal.net/koaladraft/application/views/inventory/ |
Linux gator3171.hostgator.com 4.19.286-203.ELK.el7.x86_64 #1 SMP Wed Jun 14 04:33:55 CDT 2023 x86_64 |
Current File : /home1/savoy/public_html/savoyglobal.net/koaladraft/application/views/inventory/single_sale.php |
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); $this->load->view('documentreadyfunctions'); ?> <div class="icons_main"> <div class="icons"> <img src="<?= base_url() ?>assets/images/back.png" title="Back" class="clickimage" onclick="viewdata('inventory','viewininventorysearch','search_sale','view_sale','<?= $_SESSION['pagenum']; ?>')" alt="Back" align = "center" width="32" height="32" /> </div> <div class="icons_caption"> <h4> Stock Utilization Details</h4> </div> </div> <?php $inventory = $this->mastermodel->get_single_field_value('inventory','inventory_type' ,'inventory_id',$inventory_type); $batch_no = $this->mastermodel->get_single_field_value('batch','batch_no' ,'batch_id',$batch); $attributes = array('id' => 'validateform', 'class' => 'validate'); echo form_open('', $attributes); ?> <div class="grid_12" > <div class="box"style="width: 60%;float: none;margin: 0 auto;"> <div class="header main">Stock Utilization Details </div> <div class="content no-padding"> <div class="section _100"> <label>Batch</label> <div class="single_page"> <?=$batch_no?> <input type="hidden" name="batch_id" id="batch_id" value="<?= $batch; ?>"/> </div> </div> <div class="section _100"> <label>Inventory Type</label> <div class="single_page"> <?=$inventory?> <input type="hidden" name="inventory_id" id="inventory_id" value="<?= $inventory_type; ?>"/> </div> </div> </div> </div> </div> <?php if(count($students)>0) { $k=1; ?> <div id="load_student_div" > <div class="grid_12" > <div class="box"> <div class="content no-padding"> <div class="header main"> Stock Utilization Details of students</div> <table class="table" id="stud_sub"> <thead id="stud_sub_head"> <tr> <th>Sl No</th> <th>Student</th> <th>Reg No</th> <th>Gender</th> <th>Nationality</th> <th>Status</th> <th>Allotted Date</th> <th>Alloted Qty</th> </tr> </thead> <tbody> <?php $total_qty=0; // $html1 = ''; $html = ''; $active = count($students) - (count($cancelled_student) + count($deactivate_student)); $slno1 = $active + 1; $slno2 = $active + count($cancelled_student) + 1; $i = 1; $stud = array(); foreach ($students as $list) { $allocated_date=$this->inventorymodel->get_allotted_date($list['student_id'],$inventory_type); $stud[] = $list['student_id']; if (in_array($list['student_id'], $cancelled_student)) { $allocate_qty = 0; if (isset($inventodry_alloted[$inventory_type][$list['student_id']])) $allocate_qty = $inventodry_alloted[$inventory_type][$list['student_id']]; $status = 'Cancelled'; $html = '<tr class="cancelled_tr"> <td>' . $slno2++ . '</td> <td>' . $list['first_name'] . " " . $list['last_name'] . ' <input type="hidden" value="' . $list['student_id'] . '" name="student_id' . $list['student_id']. '" id="student_id' . $list['student_id'] . '"/> </td> <td>' . $list['reg_no'] . '</td> <td>' . $list['gender'] . '</td> <td>' . $list['nationality'] . '</td> <td>' . $status . '</td> <td>' . $this->mastermodel->convertdatenormalformat($allocated_date) . '</td> <td>' . $allocate_qty . '</td> </tr>' . $html; $slno2++; } elseif (in_array($list['student_id'], $deactivate_student)) { $status = 'Deactivated'; $allocate_qty = 0; if (isset($inventodry_alloted[$inventory_type][$list['student_id']])) $allocate_qty = $inventodry_alloted[$inventory_type][$list['student_id']]; $html1 = '<tr class="deactivated_tr"> <td>' . $slno1++ . '</td> <td>' . $list['first_name'] . " " . $list['last_name'] . ' <input type="hidden" value="' . $list['student_id'] . '" name="student_id' . $list['student_id'] . '" id="student_id' . $list['student_id'] . '"/> </td> <td>' . $list['reg_no'] . '</td> <td>' . $list['gender'] . '</td> <td>' . $list['nationality'] . '</td> <td>' . $status . '</td> <td>' . $this->mastermodel->convertdatenormalformat($allocated_date) . '</td> <td>' . $allocate_qty . '</td> </tr>' . $html1; $slno1++; ; } else { $allocate_qty = 0; if (isset($inventodry_alloted[$inventory_type][$list['student_id']])) $allocate_qty = $inventodry_alloted[$inventory_type][$list['student_id']]; $status = 'Active'; ?> <tr> <td><?= $i ?></td> <td> <?= $list['first_name'] . " " . $list['last_name'] ?> <input type="hidden" value="<?= $list['student_id'] ?>" name="student_id<?= $list['student_id']?>" id="student_id<?= $list['student_id'] ?>"/> </td> <td><?= $list['reg_no'] ?></td> <td><?= $list['gender'] ?></td> <td><?= $list['nationality'] ?></td> <td><?= $status ?></td> <td><?=$this->mastermodel->convertdatenormalformat($allocated_date);?></td> <td> <?= $allocate_qty?> </td> </tr> <?php $i++; } $total_qty+=$allocate_qty; } echo $html1; echo $html; ?> <tr> <td colspan="7"><b>Total</b></td> <td><b><?=$total_qty;?></b></td> </tr> </tbody> </table> </div> </div> </div> </div> <?php $k++; echo form_close(); } ?>