| Server IP : 188.114.96.2 / Your IP : 104.23.243.201 Web Server : Apache/2.4.59 (Debian) System : Linux EDL-STRETCH 4.19.0-27-amd64 #1 SMP Debian 4.19.316-1 (2024-06-25) x86_64 User : edlftp ( 1002) PHP Version : 7.4.33 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/git/sms.edl.codes.solutions/application/views/backend/admin/ |
Upload File : |
<?php
/*********************
*********************
Indian Controller : "Teacher_old_old.php"
Indian Template : "teacher_old_old.php"
controller fix 8 may 2019
Aernout Guillaume
http://codes.solutions
*********************
*********************/
?>
<hr />
<div class="row">
<div class="col-md-12">
<!------CONTROL TABS START------>
<ul class="nav nav-tabs bordered">
<li class="active" id="tabList">
<a href="#list" onclick="window.location.replace('/teacher');" data-toggle="tab"><i class="entypo-menu"></i>
<?php echo get_phrase('teacher_list');?>
</a></li>
<li id="tabAdd">
<a href="#add" data-toggle="tab"><i class="entypo-plus-circled"></i>
<?php echo get_phrase('add_teacher');?>
</a></li>
<li id="tabEdit">
<a href="#edit" data-toggle="tab" onclick="checkUrlArg('edit');"><i class="entypo-feather"></i>
<?php echo get_phrase('edit_teacher');?>
</a></li>
<li id="tabConfirm">
<a href="#confirm" data-toggle="tab" onclick="checkUrlArg('assign');"><i class="entypo-user-add"></i>
<?php echo get_phrase('assign_teachers');?>
</a>
</li>
<li id="tabPresence">
<a href="#presence" data-toggle="tab" onclick="checkUrlArg('pres');"><i class="entypo-check"></i>
<?php echo get_phrase('teachers_presence');?>
</a>
</li>
</ul>
<!------CONTROL TABS END------>
<div class="tab-content">
<br>
<!----TABLE LISTING STARTS---->
<?php include 'teacher/listing.php'; ?>
<!----TABLE LISTING ENDS---->
<!----CREATION FORM STARTS---->
<?php include 'teacher/add.php'; ?>
<!----CREATION FORM ENDS---->
<!----EDITION FORM STARTS---->
<?php include 'teacher/edit.php'; ?>
<!----EDITION FORM ENDS---->
<!----CONFIRM FORM STARTS---->
<?php include 'teacher/assign.php'; ?>
<!----CONFIRM FORM ENDS---->
<!----PRESENCE FORM STARTS---->
<?php include 'teacher/presence.php'; ?>
<!----PRESENCE FORM ENDS---->
<!----- DATA TABLE EXPORT CONFIGURATIONS ---->
<!-- assets -->
<link rel="stylesheet" href="/assets/css/csstyle/backend/teacher.css">
<link href="https://gitcdn.github.io/bootstrap-toggle/2.2.2/css/bootstrap-toggle.min.css" rel="stylesheet">
<script src="https://gitcdn.github.io/bootstrap-toggle/2.2.2/js/bootstrap-toggle.min.js"></script>
<script type="text/javascript" src="/assets/js/csajax/backend/teacher.js"></script>
<!-- Initialize the scripts-->
<script type="text/javascript">
jQuery(document).ready(function($)
{
$("#teacher_edit").select2();
$("#teacher_assgin").select2();
$("#teacher_presence").select2();
$(".select2-chosen").addClass("text-left");
//order the select
$("#teacher_edit").append($("#teacher_edit option").remove().sort(function(a, b) {
var at = $(a).text(), bt = $(b).text();
return (at > bt)?1:((at < bt)?-1:0);
}));
$("#teacher_edit").prepend(new Option("-- Select Teacher --",'9999'));
$("#teacher_edit").val('9999');
//teacher_assgin
$("#teacher_assgin").append($("#teacher_assgin option").remove().sort(function(a, b) {
var at = $(a).text(), bt = $(b).text();
return (at > bt)?1:((at < bt)?-1:0);
}));
$("#teacher_assgin").prepend(new Option("-- Select Teacher --",0));
$("#teacher_assgin").val(0);
$("#teacher_presence").append($("#teacher_presence option").remove().sort(function(a, b) {
var at = $(a).text(), bt = $(b).text();
return (at > bt)?1:((at < bt)?-1:0);
}));
$("#teacher_presence").prepend(new Option("-- Select Teacher --",0));
$("#teacher_presence").val(0);
<?php
if(isset($edit)){
echo "ajaxLoad($edit);";
}
if(isset($presence)){
echo "displayPresence($presence);";
}
?>
//order the select
$("#teacher_edit").append($("#teacher_edit option").remove().sort(function(a, b) {
var at = $(a).text(), bt = $(b).text();
return (at > bt)?1:((at < bt)?-1:0);
}));
var datatable = $("#table_export").dataTable();
$(".dataTables_wrapper select").select2({
minimumResultsForSearch: -1
});
//ajax action
$("#saveTeacher").click(function(){ajaxSave();});
$("#editTeacher").click(function(){ajaxEdit();});
$("#deleteTeacher").click(function(){ajaxDelete();});
$("#assignTeacher").click(function(){ajaxAssign();});
//$("#presenceTeacher").click(function(){ajaxPresence();});
//dynamic interactions
$('#course_name').change(function() {
var id = $('#course_name').val();
showLesson(id);
});
$('#teacher_assgin').change(function(e) {
console.log($(event.target));
if ($(event.target) !== undefined)
{
console.log('target');
var id = $('#teacher_assgin').val();
window.history.replaceState(null, null, "/teacher/index/"+id);
showAssigned(id);
}
});
$('#teacher_presence').change(function(e) {
if ($(event.target) !== undefined)
{
var id = $('#teacher_presence').val();
window.history.replaceState(null, null, "/teacher/index/"+id);
showPresence(id);
}
});
$('#teacher_edit').change(function(e) {
if ($(event.target) !== undefined)
{
var id = $('#teacher_edit').val();
window.history.replaceState(null, null, "/teacher/index/"+id);
ajaxLoad(id);
}
});
$('.datePick').datepicker({dateFormat: 'yyyy-mm-dd'});
});
</script>