ok
Direktori : /proc/thread-self/root/proc/self/root/home2/selectio/www/subamangala/admin/ |
Current File : //proc/thread-self/root/proc/self/root/home2/selectio/www/subamangala/admin/profiles-admin-list.php |
<?php include "header.php"; $ids=$_GET['id']; error_log($ids); $statement = $pdo->prepare("SELECT e.* FROM `admin_preference` e INNER JOIN profiles ON e.Profileid=profiles.id INNER JOIN caste ON profiles.caste=caste.id where e.Profileid=".$ids); //error_log("SELECT e.* FROM `admin_preference` e INNER JOIN profiles ON e.Profileid=profiles.id INNER JOIN caste ON profiles.caste=caste.id where e.Profileid=".$ids); $statement->execute(); $datas = $statement->fetchAll(PDO::FETCH_ASSOC); $totalData = $statement->rowCount(); if(!empty($datas)){ $caste_idss = explode(',', $datas[0]['Pref_Caste']); $star_idss = explode(',', $datas[0]['Pref_Star']); $thosam_idss = explode(',', $datas[0]['Pref_Dhosam']); $edu_idss = explode(',', $datas[0]['Pref_Edu']); $height_idss = explode(',', $datas[0]['Pref_Height']); $marriage_idss = explode(',', $datas[0]['Pref_Marriage']); error_log("admin_preference to get pref_cast".$datas[0]['Pref_Caste']); }else{ return 0; } if($totalData>0){ ?> <div class="content-wrapper" style="background:#ecf0f5;"> <div class="col-lg-12 alerts"> <div id="custom-alerts" style="display:none;"> <div class="alert alert-dismissable"> <div class="custom-msg"></div> </div> </div> <?php if ($error) { ?> <div class="alert alert-danger alert-dismissable"> <button aria-hidden="true" data-dismiss="alert" class="close" type="button">×</button> <h4><i class="icon fa fa-ban"></i> Error</h4> <?= $error; ?> </div> <?php } if ($warning) { ?> <div class="alert alert-warning alert-dismissable"> <button aria-hidden="true" data-dismiss="alert" class="close" type="button">×</button> <h4><i class="icon fa fa-warning"></i> Warning</h4> <?= $warning; ?> </div> <?php } if ($message) { ?> <div class="alert alert-success alert-dismissable"> <button aria-hidden="true" data-dismiss="alert" class="close" type="button">×</button> <h4> <i class="icon fa fa-check"></i> Success</h4> <?= $site_name; ?> </div> <?php } ?> </div> <div class="clearfix"></div> <?php $data =" var search_table =$('#search_table').val(); var caste =$('#caste').val(); var star = $('#natchatram').val(); var height = $('#height_cat').val(); var education = $('#edu').val(); var thosam = $('#thosam').val(); var marriage = $('#marriage').val(); var miny = $('#miny').val(); var maxy = $('#maxy').val(); var table = $('#StData').DataTable({ 'ajax' : { url: 'data-tables/profiles-admin-data-table.php', data:{search:search_table,table:table,caste:caste,star:star,height:height,education:education,marriage:marriage,thosam:thosam,miny:miny,maxy:maxy}, type: 'POST'}, bFilter: true, bDestroy: true, searching: true,pageLength: 10, 'buttons': [ { extend: 'copyHtml5', 'footer': false, exportOptions: { columns: [ 0, 1, 2, 3, 4, 5 ,6, 7, 8, 9, 10,11, 12, 13, 14, 15, 16, 17] } }, { extend: 'excelHtml5', 'footer': false, exportOptions: { columns: [0, 1, 2, 3, 4, 5 ,6, 7, 8, 9, 10,11, 12, 13, 14, 15, 16, 17] } }, { extend: 'csvHtml5', 'footer': false, exportOptions: { columns: [0, 1, 2, 3, 4, 5 ,6, 7, 8, 9, 10,11, 12, 13, 14, 15, 16, 17] } }, { extend: 'pdfHtml5', orientation: 'landscape', pageSize: 'A4', 'footer': false, exportOptions: { columns: [ 0, 1, 2, 3, 4, 5 ,6, 7, 8, 9, 10,11, 12, 13, 14, 15, 16, 17] } }, { extend: 'colvis', text: 'Columns'}, ] });"; ?> <style> table.dataTable th:nth-child(23), table.dataTable th:nth-child(25) { width: 70px; max-width: 70px; } table.dataTable td:nth-child(23), table.dataTable td:nth-child(25){ width: 70px; max-width: 70px; word-break: break-all; white-space: pre-line; } </style> <script type="text/javascript"> $(document).ready(function() { emp_data(); function emp_data(){ <?=$data?> } $('#caste,#height_cat,#edu,#marriage,#natchatram,#thosam,#miny,#maxy').change(function() { emp_data(); }); $('#search_table').keyup(function() { <?=$data?> document.getElementById("search_table").focus(); }); }); function delete_employee(id){ var result = confirm("Confirm want to delete this Holiday?"); if (result) { $.ajax({ type: 'POST', url: 'api/delete.php', data: {type:'employee_delete',delete_id:id,table_name:'tbl_user'}, success: function(response) { //console.log(response); emp_datas(); } }); } } function emp_datas(){ <?=$data?> } </script> <section class="content"> <!-- Header Section Starts Here --> <!-- <div class="row" style=""> <div class="col-md-10 col-sm-10 col-xs-8"> <div style="list-style: none; padding-inline-start: 0px; padding: 5px 0px 5px 0px;"> <?php include "header/caste_sub_header.php"; ?> </div> </div> </div> --> <!-- Header Section Endsss Here --> <!-- Data Tables Starts Here --> <div class="row" style="padding-top: 15px;"> <div class="col-xs-12"> <div class="box box-warning"> <div class="box-body" style="box-shadow: rgba(60, 64, 67, 0.3) 0px 1px 2px 0px, rgba(60, 64, 67, 0.15) 0px 2px 6px 2px;"> <div class="clearfix"></div> <form enctype="multipart/form-data" method="post" id="preferance_add_update_form"> <div class="row"> <div class="col-md-6"> <div class="form-group"> <?php error_log("SELECT * FROM `admin_preference` where Profileid='".$_GET['id']."'"); $statement2 = $pdo->prepare("SELECT * FROM `admin_preference` where Profileid='".$_GET['id']."'"); $statement2->execute(); $preferance_result = $statement2->fetchAll(PDO::FETCH_ASSOC); $pre_totalData = $statement2->rowCount(); if($pre_totalData>0){ error_log($pre_totalData);?> <input type="hidden" name="insertstatus" value="Updatevalue"/> <?php }else{ ?> <input type="hidden" name="insertstatus" value="Addvalue"/> <?php } ?> <label class="required" for="role">ஜாதி</label> <select name="caste[]" class="form-control select2" onchange="castechange()" id="caste" required="required" multiple> <option value="">Select ஜாதி</option> <?php $statement = $pdo->prepare("SELECT * FROM `caste`"); $statement->execute(); $location_result = $statement->fetchAll(PDO::FETCH_ASSOC); foreach ($location_result as $result) { ?> <option value="<?=$result['id']?>" <?php if(in_array($result['id'], $caste_idss)){ echo "selected";} ?>><?=$result['name']?></option> <?php } ?> </select> </div> </div> <div class="col-md-6"> <div class="form-group"> <label class="required" for="role">நட்சத்திரம்</label> <select name="natchatram[]" class="form-control select2" onchange="selectstar()" id="natchatram" required="required" multiple> <option value="">Select நட்சத்திரம்</option> <?php $statement = $pdo->prepare("SELECT * FROM `natchatram`"); $statement->execute(); $location_result = $statement->fetchAll(PDO::FETCH_ASSOC); foreach ($location_result as $result) { ?> <option value="<?=$result['id']?>" <?php if(in_array($result['id'], $star_idss)){ echo "selected";} ?>><?=$result['natchatram']?></option> <?php } ?> </select> </div> </div> <div class="col-md-6"> <div class="form-group"> <label class="required" for="role">Min Year</label> <select name = "miny" id = "miny" class="form-control select2" style="width:100%"> <option value="">Select Min Year</option> <?php $y = date("Y", strtotime("+8 HOURS")); for($year = 1947; $year <= 2029; $year++){ ?> <option value="<?=$year?>" <?php if($datas[0]['From_Year']==$year){ echo "selected";}?>><?=$year?></option> <?php } ?> </select> </div> </div> <div class="col-md-6"> <div class="form-group"> <label class="required" for="role">Max Year</label> <select name = "maxy" id = "maxy" class="form-control select2" style="width:100%"> <option value="">Select Max Year</option> <?php $y = date("Y", strtotime("+8 HOURS")); for($year = 1947; $year <= 2029; $year++){ ?> <option value="<?=$year?>" <?php if($datas[0]['To_Year']==$year){ echo "selected";}?>><?=$year?></option> <?php } ?> </select> </div> </div> </div> <div class="row"> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">தோஷம்</label> <select name="thosam[]" onclick="select_thosam()" class="form-control select2" id="thosam" required="required" multiple> <!-- prf --> <?php $pred='L,B,M'; ?> <option value="">Select தோஷம்</ooption> <option value="A" <?php if(in_array('A', $thosam_idss)){ echo "selected";} ?>>A</option> <option value="B" <?php if(in_array('B', $thosam_idss)){ echo "selected";} ?>>B</option> <option value="C" <?php if(in_array('C', $thosam_idss)){ echo "selected";} ?>>C</option> <option value="D" <?php if(in_array('D', $thosam_idss)){ echo "selected";} ?>>D</option> <option value="E" <?php if(in_array('E', $thosam_idss)){ echo "selected";} ?>>E</option> <option value="F" <?php if(in_array('F', $thosam_idss)){ echo "selected";} ?>>F</option> </select> </div> </div> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">உயரம் வகை </label> <select name="height_cat[]" onclick="selectheight()" class="form-control select2" id="height_cat" required="required" multiple> <option value="">Select உயரம் வகை </ooption> <option value="1" <?php if(in_array('1', $height_idss)){ echo "selected";} ?>>உயரம் குறைவானவர்</option> <option value="2" <?php if(in_array('2', $height_idss)){ echo "selected";} ?>>சரியான உயரம்</option> <option value="3" <?php if(in_array('3', $height_idss)){ echo "selected";} ?>>மிகவும் உயரமானவர்</option> </select> </div> </div> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">படிப்பு </label> <select name="edu[]" class="form-control select2" id="edu" required="required" multiple> <?php $statement = $pdo->prepare("SELECT * FROM `profiles` where edu_cat!='' GROUP BY edu_cat"); $statement->execute(); $location_result = $statement->fetchAll(PDO::FETCH_ASSOC); foreach ($location_result as $result) { ?> <option value="<?=$result['edu_cat']?>" <?php if(in_array($result['edu_cat'], $edu_idss)){ echo "selected";} ?>><?=$result['edu_cat']?></option> <?php } ?> </select> </div> </div> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">மணமானவரா?</label> <select name="marriage[]" class="form-control select2" id="marriage" required="required" multiple> <option value="">Select மணமானவரா?</opti</ooption> <option value="first" <?php if(in_array('first', $marriage_idss)){ echo "selected";} ?>>முதல் மனம்</option> <option value="non-first" <?php if(in_array('non-first', $marriage_idss)){ echo "selected";} ?>>மறு மனம் </option> </select> </div> </div> </div> <div class="row"> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">Limit</label> <div class="form-group"> <input type="text" id="limit" name="limit" value="<?=$datas[0]['Pref_Limit']?>" class="form-control tip" required="required" /> </div> </div> </div> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">Days</label> <div class="form-group"> <input type="text" id="days" name="days" value="<?=$datas[0]['Pref_Days']?>" class="form-control tip" required="required" /> </div> </div> </div> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">Expired Date</label> <div class="form-group"> <input type="text" id="ser" name="ser" class="form-control tip" value="<?=$datas[0]['Entry_Date']?>" required="required" readonly/> </div> </div> </div> <div class="col-md-3" hidden> <div class="form-group"> <label class="required" for="role">Login Status</label> <select name="login" class="form-control select2" id="login" required="required"> <option value="Enable" <?php if($datas[0]['loginstatus']=='Enable'){ echo "selected";}?>>Enable</option> <option value="Disable" <?php if($datas[0]['loginstatus']=='Disable'){ echo "selected";}?>>Disable</option> </select> </div> </div> </div> <div class="row"> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">Limit Status</label> <select name="limit_sta" class="form-control select2" id="limit_sta" required="required"> <option value="Manual" <?php if($datas[0]['Limit_Status']=='Manual'){ echo "selected";}?>>Manual</option> <option value="Automatic" <?php if($datas[0]['Limit_Status']=='Automatic'){ echo "selected";}?>>Automatic</option> </select> </div> </div> <div class="col-md-3"> <div class="form-group"> <label class="required" for="role">Service Date</label> <input type="date" id="date" name="date" class="form-control tip" value="<?=$datas[0]['Service_Date']?>" required="required" /> <input type="hidden" id="ids" name="ids" class="form-control tip" value="<?=$_GET['id']?>" required="required" /> </div> </div> <div class="col-md-3"> <div class="form-group"> <!--<label class="required" for="role">Upload Horoscope Image</label>--> <!--<input type="file" id="files" name="files" class="form-control tip" />--> </div> </div> </div> <div style="padding-top: 10px;" id="filter_search"> <input type="text" name="search_table" id="search_table" placeholder="Search Here" class="form-control tamil" style="background: darkturquoise; width: 100%; padding: 0px 10px 0px 10px; font-size: 16px; height: 58px; font-weight: 700; font-size:22px;color: white; -webkit-text-fill-color: white;"> </div> <div class="table-responsive"> <table id="StData" class="table table-striped table-bordered table-condensed table-hover display" style="width:100%; margin-bottom:5px;font-size: 12px;"> <thead> <tr class="active"> <th style="text-align:center;background-color:darkcyan;color:white;font-size:20px;"><strong>ப.மு.</strong></th> <th style="text-align:center;background-color:darkcyan;color:white;font-size:20px;"><strong>பதிவு எண்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>பெயர்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>டம்மி பெயர் </strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>செல்போன் எண்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>பிறந்த தேதி</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>பாலினம்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>ஜாதி</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>உட் பிரிவு</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>ராசி</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>நட்சத்திரம்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>படிப்பு</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>அப்பா பெயர்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>அப்பா டம்மி பெயர் </strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>இருப்பிடம்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>குடும்ப அடையாளம் </strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>பதிவு தேதி</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>புரோக்கர் பெயர்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>பதிவிட்டவர் பெயர்</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>Login Status</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>Total Matches</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>Limit Count</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>Days Limit</strong></th> <th style="text-align:left;background-color:darkcyan;color:white;font-size:20px;"><strong>மனமானவரா </strong></th> </tr> </thead> <tbody style="font-size: larger;font-weight:bold"> <tr> <td colspan="10" class="dataTables_empty"><center> Loading Pls Wait Data</center></td> </tr> </tbody> </table> <div class="col-md-12" style="text-align:center;"> <a href="#" class="btn btn-warning btn-sm" id="print_lable"><i class="fa fa-tags"></i> ஆச்சு நகல் எடு </a> </div> </div> <center> <div class="form-group" style="text-align:center;"> <input type="submit" name="add_user" value="Update Admin Preferance" class="btn btn-success" /> </div> </center> </form> <div class="clearfix"></div> </div> </div> </div> </div> <!-- Data Tables Endsss Here --> </section> <script> $(document).ready(function() { $('#checkAll').click(function () { var d=$('#d').text(); if(d==''){ $('#d').text('checked'); $('.s').prop('checked',true); }else{ $('#d').text(''); console.log('un checked'); $('.s').prop('checked',false); } }); $('.checkboxs').on('click',function(){ console.log('clicked'); }); $('#print_lable').on('click',function(){ var checkValues = $('input[name=assign_ids]:checked').map(function(){ return $(this).val(); }).get(); if(checkValues != '' ){ var result = confirm("Conform Do You Want Print This id"); if (result) { window.open('profile-print.php?id='+checkValues, '_blank'); // window.location.href ="profile-print.php?id="+checkValues; //Logic to delete the item //console.log(checkValues); /* var ids=[]; ids = checkValues; $.ajax({ type: 'POST', url: 'story-details-soft-delete.php', data: {ids:ids}, success: function(response) { window.location.href ="story-details.php"; } });*/ } }else{ alert("Please Select Minimum One Product Lable"); } }); }); </script> <?php } ?> <?php include "footer.php";?> <script> $(document).ready(function(){ $('#filter_section').hide(); $('#show_filter').click(function(){ $("#filter_section").slideToggle(); return false; }); $('#filter_search').show(); $('#show_search').click(function(){ $("#filter_search").slideToggle(); return false; }); // $('.select2').select2({ // closeOnSelect: false, // }); }); </script> <script language=JavaScript src="tamil/utf.js"> </SCRIPT> <SCRIPT language=JavaScript src="tamil/tamil.js"></SCRIPT> <script> $(document).ready(function(){ $('input,textarea').on('keydown',function(event){ if(event.which==121){ $(this).toggleClass('tamil'); return false; } if($(this).hasClass('tamil')){ toggleKBMode(event); }else{ return true; } }); $('input,textarea').on('keypress',function(event){ if($(this).hasClass('tamil')){ convertThis(event); } }); }); </script> <link href="https://cdn.jsdelivr.net/npm/select2@4.1.0-rc.0/dist/css/select2.min.css" rel="stylesheet" /> <script src="https://cdn.jsdelivr.net/npm/select2@4.1.0-rc.0/dist/js/select2.min.js"></script> <style> .select2-container--default .select2-selection--multiple .select2-selection__choice { background-color: rgb(228, 228, 228); box-sizing: border-box; display: inline-block; margin-left: 5px; margin-top: 5px; position: relative; max-width: 100%; text-overflow: ellipsis; vertical-align: bottom; white-space-collapse: collapse; text-wrap: nowrap; border-width: 1px; border-style: solid; border-color: rgb(170, 170, 170); border-image: initial; border-radius: 4px; padding: 0px 10px 0px 20px; overflow: hidden; color: black; font-weight: 800; } .select2-container--default .select2-selection--multiple { background-color: white; border: 1px solid #aaa; border-radius: 4px; cursor: text; /* height:100px;*/ padding-bottom: 5px; padding-right: 5px; position: relative; } </style> <script> $(document).ready(function(){ bus_code(); }); $("#role").change(function () { bus_code(); }); function bus_code(){ var role = $("#role").val(); // Role (2=Agent, 3=Driver) if(role==2){ $("#bus_code_section").hide(); }else if(role==3){ $("#bus_code_section").show(); }else{ $("#bus_code_section").hide(); } } </script> <script> $(document).ready(function(){ upload_image(); }); function upload_image(){ $image_crop = $('#image_demo').croppie({ enableExif: true, viewport: { width:500, height:700, type:'square' //circle }, boundary:{ width:500, height:700 } }); $('#upload_image').on('change', function(){ console.log('testing upload image file'); var reader = new FileReader(); reader.onload = function (event) { $image_crop.croppie('bind', { url: event.target.result }).then(function(){ console.log('jQuery bind complete'); }); } reader.readAsDataURL(this.files[0]); $('#uploadimageModal').modal('show'); console.log('testing upload image'); }); $('.crop_image').click(function(event){ $image_crop.croppie('result', { type: 'canvas', size: 'viewport' }).then(function(response){ $.ajax({ url:"img-upload/upload.php", type: "POST", data:{"image": response}, success:function(data) { $('#uploadimageModal').modal('hide'); $('#uploaded_image').html(data); } }); }) }); } </script> <!-- Preference Update Ajax Starts Here --> <script> $('#preferance_add_update_form').on('submit', function(e){ // console.log("Click And Form Working"); e.preventDefault(); var formData = new FormData(this); formData.append('type', 'create_update_admin_preferance'); $.ajax({ url: 'apis/preferance-admin-create-update-api.php', type: 'post', dataType: 'json', data: formData, cache: false, contentType: false, processData: false, enctype: 'multipart/form-data', success: function (response) { if(response['status']==200){ alert(response['message']); // window.location.href="http://fmsbilling.xyz/subamangala/register.php"; $('#preferance_add_update_form').trigger("reset"); }else{ alert(response['message']); } } }); }); </script> <!-- Preference Update Ajax Ends Here -->