?
Current Path : /home1/savoy/www/savoyglobal.net/drafthr/system/application/views/Settings/ |
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/drafthr/system/application/views/Settings/settingsheader.php |
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');?> <script type="text/javascript" src="<?=base_url()?>/assets/js/jquery.form.js"></script> <script> function loaduserlist() { document.getElementById('addmenu').style.display="block"; document.getElementById('backmenu').style.display="none"; $('#Main-content').html('<CENTER><img src="<?=base_url()?>/assets/images/loading.gif" class="loading"/></CENTER>'); $('#Main-content').load("<?php echo site_url('settings/ListUsers/'); ?>", function(data) { //alert(data); }); } function show_add_new_user(rwd) { $("#ck_permission").load("<?= site_url('master/check_permissions/') ?>"+"/"+rwd,function(data) { if(data==1) { document.getElementById('addmenu').style.display="none"; document.getElementById('backmenu').style.display="block"; $('#Main-content').load("<?php echo site_url('settings/show_add_user_form/'); ?>"); } }); } function showEmpPick() { $(".pickEmp").colorbox({width:"50%",height:"70%", inline:true, href:"#PickEmployee"}); } function ListSelectedRole(role_id) { $('#PermissionDiv').load("<?php echo site_url('settings/ListUserPermissionControler/'); ?>" +"/" + role_id); } function searchUser() { var SerachText=document.getElementById('searchtext').value; var SearchOption=document.getElementById('selectoption').value; document.getElementById('addmenu').style.display="block"; document.getElementById('backmenu').style.display="none"; $('#Main-content').html('<CENTER><img src="<?=base_url()?>/assets/images/loading.gif" class="loading"/></CENTER>'); $('#Main-content').load("<?php echo site_url('settings/ListUsersSearch/'); ?>/" + SearchOption + "/" + SerachText , function(data) { //alert(data); }); } function ValidatePassword() { var pass1=document.getElementById('pword').value; var pass2=document.getElementById('repassword').value; if(pass1!=pass2) { document.getElementById('repassword').className="error"; } else { document.getElementById('repassword').className=""; } } function checkexistence(table,field,value) { $("#userchecdiv").load("<?= site_url('settings/checkexistence/') ?>/" +table+'/'+field+'/'+value,function(data){ if(data==1) { $("input#uname").val(""); $("#uname").css('border','solid 1px red'); $("#uname").focus(); $("#userchecdiv").fadeIn(900,0); $("#userchecdiv").html("<div style=\"border:1px solid #BE7832; width:170px;height:20px;\" ><font color=\"#AA6B2C\" >Duplicate Entry Recorded</font></div>"); $("#userchecdiv").fadeOut(2000,0); } }); } function Insert_User() { /* FUNCTION TO SUBMIT THE USER DETAILS FORM USING AJAX FORM SUBMIT */ if(validateform('uname','pword','EmpName')) { $('#InsertUserForm').ajaxForm(function(data) { alert(data); loaduserlist(); }); } else { return false; } } function Update_User() { /* FUNCTION TO SUBMIT THE USER DETAILS FORM USING AJAX FORM SUBMIT */ $('#UpdateUserForm').ajaxForm(function(data) { alert(data); if(data=="Updated Sucessfully") { loaduserlist(); } }); } function DeleteUser(user_id) { $('#Main-content').load("<?php echo site_url('settings/delete_user_controler/'); ?>" +"/" + user_id , function(data){ // alert(data); }); } function EditUser(rwd,user_id) { $("#ck_permission").load("<?= site_url('master/check_permissions/') ?>"+"/"+rwd,function(data) { if(data==1) { document.getElementById('addmenu').style.display="none"; document.getElementById('backmenu').style.display="block"; $('#Main-content').load("<?php echo site_url('settings/GetSingleUserControler/'); ?>" +"/" + user_id); } }); } function Insert_Corprate_customer_details() { /* FUNCTION TO SUBMIT THE INSERT CORPRATE CUSTOMER DETAILS FORM USING AJAX FORM SUBMIT */ $('#CorpCustForm').ajaxForm(function(data) { alert(data); loadcustomerList(); }); } $(window).load( function() { loaduserlist(); }); </script>