?
Current Path : /home1/savoy/www/savoyglobal.net/eduplus2/application/views/sms/ |
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/eduplus2/application/views/sms/smslist.php |
<?php if (!defined('BASEPATH')) exit('No direct script access allowed'); $this->load->view('documentreadyfunctions'); $this->load->view('commonfunctions'); $template_details = $this->mastermodel->getdatas('template'); ?> <script type="text/javascript"> $(document).ready(function(){ $('#message').keyup(function(){ var limit = $(this).attr('maxlength'); ($(this).val().length < limit) ? $('.charsLeft').html(limit-$(this).val().length) : $(this).val($(this).val().substr(0,limit)) + $('.charsLeft').html('<span style="color:#ff0000;">0</span>');}); $("#preloader").hide(); }); function usetemplate(status) { var template_id=status.value; if(template_id!=""){ $.ajax({ type: "POST", url: "<?= site_url('sms/gettemplate') ?>/" +template_id, success: function(msg) { $("textarea#message").val(msg); } }); } else{ $("textarea#message").val(""); } } </script> <!-- BEGIN PAGE LEVEL STYLES --> <link rel="stylesheet" href="<?= base_url(); ?>assets/plugins/data-tables/DT_bootstrap.css" /> <!-- END PAGE LEVEL STYLES --> <div class="row-fluid"> <div class="span12"> <!-- BEGIN EXAMPLE TABLE PORTLET--> <div class="portlet box blue"> <div class="portlet-title"> <div class="caption" ><i class="icon-cogs"></i>Send Email</div> <div class="actions"> <a href="#" onclick="addformdisplay('view_bulk_sms','sms')" class="btn green"><i class="icon-plus"></i> Add</a> </div> </div> <div class="portlet-body"> <?php $attributes = array('class' => 'validate', 'id' => 'validateform'); echo form_open('sms/addinsms/insertbulksms/view_bulk_sms/1/', $attributes); ?> <table class="table table-striped table-hover table-bordered" > <thead> <tr> <th style="width: 17px;">Sl No.</th> <th>Name</th> <th>Nationality</th> <th>Gender</th> <th>Student Reg No</th> <th>Batch Code</th> <th>Mobile Number</th> <th style="width: 135px;">Type</th> <th style="width: 70px;"> <input checked name="checkall" id="checkall" type="checkbox" onchange="checkallsms()"/> </th> </tr> </thead> <tbody> <?php $slno = 0; if ($viewinfo->num_rows() > 0) { $sorLst1 = array(); $list = $viewinfo->result(); foreach ($list as $user) { $sorLst[] = $user->master_id; } array_multisort($sorLst, SORT_ASC, $list); $list1 = array(); foreach ($list as $row) { if ($row->type == 'Father' || $row->type == 'Mother' || $row->type == 'Student') { $std_id = $this->mastermodel->get_single_field_value('student', 'student_id', 'reg_no', $row->reg); $date = date("d-m-Y"); $class = $this->mastermodel->get_single_field_value('class_name', 'class_name_id', 'class_name_code', $row->class_name_code); $deactivate = $this->studentmodel->check_deactivate($class, $std_id, $date); if ($deactivate == 0) { $list1[] = $row; } } else { $list1[] = $row; } } $temp=""; foreach ($list1 as $row) { ?> <tr <?php if ($slno % 2 == 0) { ?>class="first" <?php } else { ?> class="second" <?php } ?>> <td><?php if($temp!=$row->sort_id) { echo ++$slno; } $temp=$row->sort_id; ?> </td> <td><?= $row->name; ?></td> <td><?= $row->nationality; ?></td> <td><?= $row->gender; ?></td> <?php if ($row->type == 'Father' || $row->type == 'Mother' || $row->type == 'Student') { ?> <td><?= $row->reg; ?></td> <?php } else { ?> <td></td> <?php } ?> <td><?= $row->class_name_code; ?></td> <td><?= $row->mobile_no; ?></td> <td><?= $row->type; ?></td> <td> <div class="actions_menu"> <input type="hidden" name="<?php echo "receipent_name_" . $slno; ?>" value="<?= $row->name; ?>"/> <input type="hidden" name="<?php echo "receipent_type_" . $slno; ?>" value="<?= $row->type; ?>"/> <input name="<?php echo "check_mobile_" . $slno; ?>" checked value="<?= $row->mobile_no; ?>" id="check_mobile" class="smscheck" type="checkbox"/> </div> </td> </tr> <?php } } ?> <input name="moblen" value="<?= $slno; ?>" type="hidden"> </tbody> </table> <div class="portlet box blue"> <div class="portlet-title"> <div class="caption"><i class="icon-reorder"></i>SMS Information</div> </div> <div class="portlet-body form"> <div class="row-fluid"> <div class="control-group"> <label class="control-label">Sender ID</label> <div class="controls"> <input class="required span12" maxlength="8" name="sender_id" value="Nursery" id="sender_id" type="text" /> </div> </div> </div> <div class="row-fluid"> <div class="control-group"> <label class="control-label">Use Template</label> <div class="controls"> <select name="template_id" id="template_id" onchange="usetemplate(this)" class="span12" > <option value="" selected>Select Template</option> <?php foreach ($template_details as $row) { ?> <option value="<?= $row['template_id'] ?>"><?= $row['template_title'] ?></option> <?php } ?> </select> </div> </div> </div> <div class="row-fluid"> <div class="control-group"> <label class="control-label">Message</label> <div class="controls"> <textarea name="message" class="required span12" id="message" style="height:80px;" maxlength="140" ></textarea> </div> </div> </div> <div class="row-fluid"> <div class="control-group"> <label class="control-label">Options</label> <div class="controls"> <input class="radio" name="status" id="status" type="radio" value="Sent" onchange="hideclassdiv('schedule',this)" checked />Send Now <input class="radio" name="status" id="status" type="radio" value="Saved" onchange="hideclassdiv('schedule',this)" /> Save as Draft </div> </div> </div> </div> </div> <div class="form-actions"> <input type="hidden" name="resfunction" value="search_bulk_sms"/> <button type="submit" onclick="addformdata('validateform')" class="btn blue"><i class="icon-ok"></i> Send</button> </div> <?php echo form_close(); ?> </div> </div> </div> </div> <span class="section_content_bottom"></span> <div style='display:none'> <div id="uploaddiv"></div> </div> <div id="ajax-modal" class="modal hide fade" tabindex="-1"></div> <script> jQuery(document).ready(function() { UIModals.init(); TableManaged.init(); }); </script>