?
Current Path : /home1/savoy/www/savoyglobal.net/sec_old/application/views/student/ |
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/www/savoyglobal.net/sec_old/application/views/student/add_student_batch_1.php |
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); $this->load->view('documentreadyfunctions'); $student = $this->mastermodel->getdatas('student', 'student_id', '', 'student_id'); ?> <script type="text/javascript"> function getSessionAmount(session,divid){ var res = session.split("~"); $('#'+divid).val(res[1]); } function load_student_details() { var student_id = $('#student').val(); if(student_id == "") { alert("Please select Student First"); } else { // $('#stud,#salary_box').css('display','block'); var flag=0; var index=$('#add_student tr').length+1; var i=1; for(i=1;i<index;i++) { var std_id=$('#student_id'+i).val(); if(std_id==student_id) { flag=1; } } if(flag==0) { $.ajax({ type: "POST", url: "<?= site_url() ?>/student/load_students/"+student_id+"/"+index+"/"+<?= $viewinfo->course_id ?>, success: function(data) { // $("#add_student").append(data); $("#add_student").html($("#add_student").html()+data) }}); } else { alert('Already Added'); } } } function checkallstd(status) { $('#salary_box1 input').each(function(index,obj){ if(obj.type === 'checkbox') { obj.checked = !status; } }); } </script> <?php $attributes = array('id' => 'validateform', 'class' => 'validate'); echo form_open('student/addinstudent/insert_student_batch/view_student_batch/1', $attributes); ?> <div class="icons_main"> <div class="icons"> <img src="<?= base_url() ?>assets/images/back.png" title="Back" class="clickimage" onclick="viewdata('student','viewinstudentsearch','search_student_batch','view_student_batch','<?= $_SESSION['pagenum']; ?>')" alt="Back" align = "center" width="32" height="32" /> </div> <div class="icons_caption"> <h4>Batch Allocation</h4> </div> </div> <div style="margin: 0 auto;width:50%;"> <div class="grid_12"> <div class="box"> <div class="header"></div> <div class="content no-padding"> <table class="table" > <tr> <td style="width:50%;">Batch Code</td> <td><?= $viewinfo->batch_no; ?></td> </tr> <tr> <td style="width:50%;">Course Name</td> <td> <?= $viewinfo->course_name . '--' . $viewinfo->course_code; ?> </td> </tr> <tr> <td style="width:50%;">Teacher</td> <td><?= $this->mastermodel->get_single_field_value('employee', 'employee_name', 'employee_id', $viewinfo->teacher_id); ?></td> </tr> <tr> <td style="width:50%;">Date of Allotment</td> <td><input class="w_90 required" type="dateonly" name="date" id="date"/></td> </tr> <input type="hidden" name="batch_id" id="batch_id" value="<?= $viewinfo->batch_id; ?>"/> <input type="hidden" name="course_id" id="course_id" value="<?= $viewinfo->course_id ?>"/> </table> <table class="table" > <tr> <th colspan="2">Student Name</th></tr> <tr> <td width="50%"> <div style="height:10px"></div> <select name="student" id="student" style="width: 287px"> <option value="">--Select--</option> <?php foreach ($student as $row) { ?> <option value="<?= $row['student_id'] ?>"><?= $row['first_name'] . ' ' . $row['last_name'] . '-' . $row['reg_no'] ?> </option> <?php } ?> </select> </h> <td width="50%"> <input type="button" onclick="load_student_details()" value="Load Student Details"/> </h> </tr> </table> </div> </div> </div> </div> <div id="sl"></div> <!--<div class="grid_12" > <div class="box"> <div class="header main">Student Details</div> <div class="content no-padding" > <table class="table" cellpadding="0" cellspacing="0" id="tbl1"> <tr> <th width="10%"> <input style="width:15px;" type="checkbox" id="check_all" name="check_all" checked onclick="checkallstd(this.checked)"/>Mark </th> <th width="30">Student Name</th> <th width="15%">Student No.</th> <th width="15%">Course Fess</th> <th width="15%">Sessions</th> <th width="15%">Monthly Payment</th> </tr> <tbody> <?php $index = 1; foreach ($batch_students as $value) { ?> <tr> <td> <input style="width:15px;" type="checkbox" id="select_student<?= $index ?>" name="select_student<?= $index ?>" checked /> <input name="student_batch_id<?= $index ?>" id="student_batch_id<?= $index ?>" value="<?= $value['student_batch_id'] ?>" type="hidden"/> </td> <td> <?= $value['first_name'] . $value['last_name'] ?> <input type="hidden" id="student_id<?= $index ?>" name="student_id<?= $index ?>" value="<?= $value['student_id'] ?>"/> </td> <td> <?= $value['reg_no']; ?> </td> <td> <input type="text" style="width: 200px;float: right;" class="required auto text_r" name="course_fee<?= $index ?>" id="course_fee<?= $index ?>" value="<?= $value['course_fee'] ?>" /> </td> <td> <div style="height:10px"></div> <select name="session<?= $index ?>" id="session<?= $index ?>" onchange="getSessionAmount(this.value,'session_amount<?= $index ?>')" class="chzn-done"> <option value="">Select</option> <?php if (isset($sections)) { foreach ($sections as $list) { echo '<option value="' . $list['no_sessions_id'] . '~' . $list['monthly_fee'] . '"'; if ($list['no_sessions_id'] == $value['no_sessions']) echo "selected"; echo'>' . $list['no_sessions'] . '</option>'; } } ?> </select> </td> <td> <input class="required auto text_r" type="text" name="session_amount<?= $index ?>" id="session_amount<?= $index ?>" value="<?= $value['session_amount'] ?>"/> </td> </tr> <? $index++; } ?> </tbody> </table> </div> </div> </div>--> <div class="grid_12" > <div class="box"> <div class="header main">Student Details</div> <div class="content no-padding" > <table class="table" cellpadding="0" cellspacing="0" id="tbl1"> <tr> <th width="10%"> <input style="width:15px;" type="checkbox" id="check_all" name="check_all" checked onclick="checkallstd(this.checked)"/>Mark </th> <th width="30">Student Name</th> <th width="15%">Student No.</th> <th width="15%">Course Fess</th> <th width="15%">Sessions</th> <th width="15%">Monthly Payment</th> </tr> <tbody id="add_student"> </tbody> </table> </div> </div> </div> <div class="grid_12 " id="stud" style="width: 100%;" style="display:none"> <div class="box"> <div class="actions"> <div class="actions-left"> <div > <div id="empdiv"></div> </div> </div> <div class="actions-right"> <button type="submit" class="clickimage" onclick="addformdata('validateform')">Process</button> </div> </div> </div> </div> <?php echo form_close(); ?>