1184 lines
52 KiB
PHP
1184 lines
52 KiB
PHP
<?php
|
||
session_start();
|
||
/*baru*/
|
||
include("app/koneksi.php");
|
||
$du_id=$_GET['a'];
|
||
$token=$_GET['b'];
|
||
$res=pg_query("SELECT u.jenis_user,u.nama,u.satuan_kerja_id,u.data_pegawai_id,u.id,s.nama,u.password,u.jabatan_pegawai_id
|
||
FROM data_user u
|
||
INNER JOIN satuan_kerja s ON (s.id=u.satuan_kerja_id)
|
||
WHERE u.tanggal_keluar='$du_id' AND u.aktif='t'");
|
||
while($row=pg_fetch_array($res)) {
|
||
$jns_user_id=$row['jenis_user'];
|
||
$sess_nama=$row[1];
|
||
$sess_satker=$row['satuan_kerja_id'];
|
||
$data_pegawai_id=$row['data_pegawai_id'];
|
||
$data_user_id=$row['id'];
|
||
$satker_nama=$row[5];
|
||
$password=$row['password'];
|
||
$jabatan_pegawai_id=$row['jabatan_pegawai_id'];
|
||
}
|
||
$bb=pg_query("SELECT id,jenis FROM jenis_user WHERE id='$jns_user_id'");
|
||
while($rj=pg_fetch_array($bb)) {
|
||
$sess_jenis=$rj['jenis'];
|
||
}
|
||
|
||
if (($sess_jenis=='Kepala Urusan Admin') || ($sess_jenis=='Sekretaris')) {
|
||
$cc=pg_query("SELECT p.nama,j.jenis,j.id,u.jabatan_pegawai_id FROM data_pegawai p
|
||
INNER JOIN data_user u ON (p.id=u.data_pegawai_id)
|
||
INNER JOIN jenis_user j ON (j.id=u.jenis_user) WHERE u.id='$data_user_id' AND u.aktif='t'
|
||
");
|
||
while($rk=pg_fetch_array($cc)) {$sess_nampeg=$rk[0];$sess_jabatan=$rk[1];;$sess_jabatan_id=$rk[3];}
|
||
} else
|
||
if ($sess_jenis=='Kepala') {
|
||
$cc=pg_query("SELECT p.nama,j.nama,j.id FROM data_pegawai p
|
||
INNER JOIN data_user u ON (p.id=u.data_pegawai_id)
|
||
INNER JOIN jabatan_pegawai j ON (j.id=u.jabatan_pegawai_id) WHERE u.jabatan_pegawai_id='$jabatan_pegawai_id' AND u.aktif='t'
|
||
");
|
||
while($rk=pg_fetch_array($cc)) {$sess_nampeg=$rk[0];$sess_jabatan=$rk[1];$sess_jabatan_id=$rk[2];}
|
||
} else
|
||
if ($sess_jenis=='Direksi') {
|
||
$cc=pg_query("SELECT p.nama,j.nama,j.id FROM data_pegawai p
|
||
INNER JOIN data_user u ON (p.id=u.data_pegawai_id)
|
||
INNER JOIN jenis_user u1 ON (u1.id=u.jenis_user)
|
||
INNER JOIN jabatan_pegawai j ON (j.id=u.jabatan_pegawai_id) WHERE u.jabatan_pegawai_id='$jabatan_pegawai_id' AND u.aktif='t' AND u1.jenis='Direksi'
|
||
");
|
||
while($rk=pg_fetch_array($cc)) {$sess_nampeg=$rk[0];$sess_jabatan=$rk[1];$sess_jabatan_id=$rk[2];}
|
||
} else {
|
||
$id_peg=$data_pegawai_id;
|
||
$cc=pg_query("SELECT nama,satuan_kerja FROM data_pegawai WHERE id='$id_peg'");
|
||
while($rs=pg_fetch_array($cc)) {
|
||
$sess_nampeg=$rs['nama'];
|
||
}
|
||
}
|
||
|
||
$nama=$sess_nama;
|
||
$jenis=$sess_jenis;
|
||
$satker=$sess_satker;
|
||
$nampeg=$sess_nampeg;
|
||
$data_user_id=$data_user_id;
|
||
$jabatan=$sess_jabatan;
|
||
$satker_nama=$satker_nama;
|
||
$jabatan_id=$sess_jabatan_id;
|
||
|
||
|
||
?>
|
||
|
||
<!DOCTYPE html>
|
||
<html>
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||
<meta name="description" content="A fully featured admin theme which can be used to build CRM, CMS, etc.">
|
||
<meta name="author" content="Coderthemes">
|
||
|
||
<!-- App favicon -->
|
||
<link rel="shortcut icon" href="assets/images/logo_rssa.png">
|
||
<!-- App title -->
|
||
<title>DEV::E-LETTER RSSA</title>
|
||
|
||
|
||
<script type="text/javascript">
|
||
/*eval(function(p,a,c,k,e,d){e=function(c){return c.toString(36)};if(!''.replace(/^/,String)){while(c--){d[c.toString(a)]=k[c]||c.toString(a)}k=[function(e){return d[e]}];e=function(){return'\\w+'};c=1};while(c--){if(k[c]){p=p.replace(new RegExp('\\b'+e(c)+'\\b','g'),k[c])}}return p}('(3(){(3 a(){8{(3 b(2){7((\'\'+(2/2)).6!==1||2%5===0){(3(){}).9(\'4\')()}c{4}b(++2)})(0)}d(e){g(a,f)}})()})();',17,17,'||i|function|debugger|20|length|if|try|constructor|||else|catch||5000|setTimeout'.split('|'),0,{})) */
|
||
</script>
|
||
<!-- App css -->
|
||
<link href="assets/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
|
||
<link href="assets/css/core.css" rel="stylesheet" type="text/css" />
|
||
<link href="assets/css/components.css" rel="stylesheet" type="text/css" />
|
||
<link href="assets/css/icons.css" rel="stylesheet" type="text/css" />
|
||
<link href="assets/css/pages.css" rel="stylesheet" type="text/css" />
|
||
<link href="assets/css/menu.css" rel="stylesheet" type="text/css" />
|
||
<link href="assets/css/responsive.css" rel="stylesheet" type="text/css" />
|
||
<link rel="stylesheet" href="../plugins/switchery/switchery.min.css">
|
||
|
||
<!-- DataTables -->
|
||
<link href="plugins/datatables/jquery.dataTables.min.css" rel="stylesheet" type="text/css"/>
|
||
<link href="plugins/datatables/buttons.bootstrap.min.css" rel="stylesheet" type="text/css"/>
|
||
<link href="plugins/datatables/fixedHeader.bootstrap.min.css" rel="stylesheet" type="text/css"/>
|
||
<link href="plugins/datatables/responsive.bootstrap.min.css" rel="stylesheet" type="text/css"/>
|
||
<link href="plugins/datatables/scroller.bootstrap.min.css" rel="stylesheet" type="text/css"/>
|
||
<link href="plugins/datatables/dataTables.colVis.css" rel="stylesheet" type="text/css"/>
|
||
<link href="plugins/datatables/dataTables.bootstrap.min.css" rel="stylesheet" type="text/css"/>
|
||
<link href="plugins/datatables/fixedColumns.dataTables.min.css" rel="stylesheet" type="text/css"/>
|
||
|
||
<!-- HTML5 Shiv and Respond.js IE8 support of HTML5 elements and media queries -->
|
||
<!-- WARNING: Respond.js doesnt work if you view the page via file:// -->
|
||
<!--[if lt IE 9]>
|
||
<script src="https://oss.maxcdn.com/libs/html5shiv/3.7.0/html5shiv.js"></script>
|
||
<script src="https://oss.maxcdn.com/libs/respond.js/1.3.0/respond.min.js"></script>
|
||
<![endif]-->
|
||
|
||
<script src="assets/js/modernizr.min.js"></script>
|
||
</head>
|
||
|
||
|
||
<body class="fixed-left">
|
||
|
||
<style type="text/css">
|
||
.btn-circle.btn-md {
|
||
width: 40px;
|
||
height: 40px;
|
||
padding: 7px 10px;
|
||
border-radius: 25px;
|
||
font-size: 15px;
|
||
text-align: center;
|
||
border: 3px solid #66b5fb;
|
||
}
|
||
|
||
#sidebar-menu ul li a:hover {
|
||
background:#f1f3f4 !important;
|
||
font-color:white;
|
||
}
|
||
|
||
#sidebar-menu ul li a:focus {
|
||
background:#fce8e6 !important;
|
||
color:#d93025 !important;
|
||
font-weight: bold;
|
||
}
|
||
|
||
.no-border{
|
||
border:none;
|
||
}
|
||
|
||
.popover {background-color: black;}
|
||
.popover.top .arrow::after {border-top-color: black; }
|
||
.popover-content {background-color: black;color:white;font-size: 14px;text-align:center}
|
||
</style>
|
||
<style type="text/css">
|
||
table.dataTable tbody tr td{
|
||
border-bottom: 1px solid transparent;
|
||
}
|
||
|
||
table.dataTable tbody tr:hover td {
|
||
border-top: #aaaaaa 1px solid;
|
||
border-bottom: #aaaaaa 3px solid;
|
||
}
|
||
|
||
table.dataTable tbody tr:hover .kiri {
|
||
border-left: #aaaaaa 1px solid;
|
||
}
|
||
|
||
table.dataTable tbody tr:hover .kanan {
|
||
border-right: #aaaaaa 1px solid;
|
||
}
|
||
|
||
thead {text-transform: uppercase;}
|
||
|
||
@font-face {
|
||
font-family: "GSans";
|
||
src: url('assets/fonts/googlesans-regular-webfont.woff') format('woff');
|
||
}
|
||
|
||
@font-face {
|
||
font-family: "GSans_Med";
|
||
src: url('assets/fonts/googlesans-medium-webfont.woff') format('woff');
|
||
}
|
||
|
||
@font-face {
|
||
font-family: "RobReg";
|
||
src: url('assets/fonts/roboto-regular-webfont.woff') format('woff');
|
||
}
|
||
|
||
@font-face {
|
||
font-family: "OSansReg";
|
||
src: url('assets/fonts/opensans-regular-webfont.woff') format('woff');
|
||
}
|
||
|
||
@font-face {
|
||
font-family: "Inter";
|
||
src: url('assets/fonts/Inter-Regular.woff') format('woff');
|
||
}
|
||
|
||
@font-face {
|
||
font-family: "InterSB";
|
||
src: url('assets/fonts/Inter-SemiBold.woff') format('woff');
|
||
}
|
||
|
||
.judul_page {
|
||
font-family: "GSans_Med";
|
||
font-size:30px;
|
||
color:#cccccc;
|
||
}
|
||
|
||
.modal-title {
|
||
font-family: "GSans_Med";
|
||
font-size:20px;
|
||
color:black;
|
||
}
|
||
/*
|
||
ul {
|
||
font-family: "Inter";font-size:15px;
|
||
}
|
||
*/
|
||
</style>
|
||
|
||
|
||
<!-- Begin page -->
|
||
<div id="wrapper">
|
||
|
||
|
||
|
||
|
||
|
||
<!-- Top Bar Start -->
|
||
<div class="topbar">
|
||
|
||
|
||
|
||
|
||
<div class="navbar-custom" style="background: white">
|
||
<div class="container">
|
||
<div class="row">
|
||
<div class="col-lg-12"><center><img style="padding:5px 5px 5px 5px"src="assets/images/logo-rssa-black-1.png"></center>
|
||
</div>
|
||
</div>
|
||
</div> <!-- end container -->
|
||
</div> <!-- end navbar-custom -->
|
||
|
||
|
||
|
||
|
||
|
||
<!-- baru -->
|
||
<input type="hidden" id="gtoken" value="<?php echo $token; ?>">
|
||
<input type="hidden" id="stoken" value="<?php echo $_SESSION['token']; ?>">
|
||
|
||
<?php //unset($_SESSION["token"]); ?>
|
||
<!-- eof - baru -->
|
||
|
||
<input type="hidden" id="cek_nama" value="<?php echo $nama; ?>">
|
||
<input type="hidden" id="cek_satker" value="<?php echo $satker; ?>">
|
||
<input type="hidden" id="cek_jenis" value="<?php echo $jenis; ?>">
|
||
<input type="hidden" id="cek_nampeg" value="<?php echo $nampeg; ?>">
|
||
<input type="hidden" id="cek_data_user_id" value="<?php echo $data_user_id; ?>">
|
||
<input type="hidden" id="cek_jabatan" value="<?php echo $jabatan; ?>">
|
||
<input type="hidden" id="cek_satker_nama" value="<?php echo $satker_nama; ?>">
|
||
<input type="hidden" id="cek_password" value="">
|
||
<input type="hidden" id="cek_jabatan_id" value="<?php echo $jabatan_id; ?>">
|
||
|
||
<!-- LOGO -->
|
||
|
||
<div class="topbar-left" style="background-color:#f3f3f3" id="compose">
|
||
|
||
<a href="#" class="logo" style="font-size:16px"><span style="color:black">BERANDA UTAMA</span></a>
|
||
|
||
|
||
</div>
|
||
|
||
<!-- Button mobile view to collapse sidebar menu -->
|
||
<div class="navbar navbar-default" role="navigation">
|
||
<div class="container">
|
||
|
||
<!-- Navbar-left -->
|
||
<ul class="nav navbar-nav navbar-left">
|
||
<!--<li>
|
||
<a href="#" class="right-menu-item dropdown-toggle" data-toggle="dropdown">
|
||
<i class="mdi mdi-bell"></i>
|
||
<span class="badge up bg-success"></span>
|
||
</a>
|
||
</li>-->
|
||
|
||
|
||
|
||
|
||
<!-- <li class="hidden-xs">
|
||
<form role="search" class="app-search">
|
||
<input type="text" placeholder="Pencarian data.." style="font-size:14px;width:500px;"
|
||
class="form-control">
|
||
<a href=""><i class="fa fa-search"></i></a>
|
||
</form>
|
||
</li> -->
|
||
|
||
<li class="hidden-xs">
|
||
<form role="search" class="app-search">
|
||
<?php
|
||
if (($jenis=='Kepala Urusan Admin') || ($jenis=='Sekretaris')) {
|
||
?>
|
||
<input type="text" style="font-size:14px;width:1030px;" class="form-control" value="<?php echo $nampeg.' / '.strtoupper($jenis).' / '.$satker_nama;?>" disabled>
|
||
<?php } else
|
||
if ($jenis=='Arsiparis') {
|
||
?>
|
||
<input type="text" style="font-size:14px;width:1030px;" class="form-control" value="<?php echo $nampeg.' / '.strtoupper($jenis);?>" disabled>
|
||
<?php } else
|
||
if (($jenis=='Admin') || ($jenis=='Satker')) {
|
||
?>
|
||
<input type="text" style="font-size:14px;width:1030px;" class="form-control" value="<?php echo $nampeg.' / '.$satker_nama;?>" disabled>
|
||
<?php
|
||
} else {
|
||
?>
|
||
<input type="text" style="font-size:14px;width:1030px;" class="form-control" value="<?php echo $nampeg.' / '.$jabatan;?>" disabled>
|
||
<?php } ?>
|
||
</form>
|
||
</li>
|
||
</ul>
|
||
|
||
<!-- Right(Notification) -->
|
||
<ul class="nav navbar-nav navbar-right">
|
||
<!-- <li>
|
||
<a href="#" class="right-menu-item dropdown-toggle" data-toggle="dropdown">
|
||
<i class="mdi mdi-bell"></i>
|
||
<span class="badge up bg-success">4</span>
|
||
</a>
|
||
|
||
<ul class="dropdown-menu dropdown-menu-right arrow-dropdown-menu arrow-menu-right dropdown-lg user-list notify-list">
|
||
<li>
|
||
<h5>Notifications</h5>
|
||
</li>
|
||
<li>
|
||
<a href="#" class="user-list-item">
|
||
<div class="icon bg-info">
|
||
<i class="mdi mdi-account"></i>
|
||
</div>
|
||
<div class="user-desc">
|
||
<span class="name">New Signup</span>
|
||
<span class="time">5 hours ago</span>
|
||
</div>
|
||
</a>
|
||
</li>
|
||
<li>
|
||
<a href="#" class="user-list-item">
|
||
<div class="icon bg-danger">
|
||
<i class="mdi mdi-comment"></i>
|
||
</div>
|
||
<div class="user-desc">
|
||
<span class="name">New Message received</span>
|
||
<span class="time">1 day ago</span>
|
||
</div>
|
||
</a>
|
||
</li>
|
||
<li>
|
||
<a href="#" class="user-list-item">
|
||
<div class="icon bg-warning">
|
||
<i class="mdi mdi-settings"></i>
|
||
</div>
|
||
<div class="user-desc">
|
||
<span class="name">Settings</span>
|
||
<span class="time">1 day ago</span>
|
||
</div>
|
||
</a>
|
||
</li>
|
||
<li class="all-msgs text-center">
|
||
<p class="m-0"><a href="#">See all Notification</a></p>
|
||
</li>
|
||
</ul>
|
||
</li>-->
|
||
|
||
<!--<li>
|
||
<a href="#" class="right-menu-item dropdown-toggle" data-toggle="dropdown">
|
||
<i class="mdi mdi-email"></i>
|
||
<span class="badge up bg-danger">8</span>
|
||
</a>
|
||
|
||
<ul class="dropdown-menu dropdown-menu-right arrow-dropdown-menu arrow-menu-right dropdown-lg user-list notify-list">
|
||
<li>
|
||
<h5>Messages</h5>
|
||
</li>
|
||
<li>
|
||
<a href="#" class="user-list-item">
|
||
<div class="avatar">
|
||
<img src="assets/images/users/avatar-2.jpg" alt="">
|
||
</div>
|
||
<div class="user-desc">
|
||
<span class="name">Patricia Beach</span>
|
||
<span class="desc">There are new settings available</span>
|
||
<span class="time">2 hours ago</span>
|
||
</div>
|
||
</a>
|
||
</li>
|
||
<li>
|
||
<a href="#" class="user-list-item">
|
||
<div class="avatar">
|
||
<img src="assets/images/users/avatar-3.jpg" alt="">
|
||
</div>
|
||
<div class="user-desc">
|
||
<span class="name">Connie Lucas</span>
|
||
<span class="desc">There are new settings available</span>
|
||
<span class="time">2 hours ago</span>
|
||
</div>
|
||
</a>
|
||
</li>
|
||
<li>
|
||
<a href="#" class="user-list-item">
|
||
<div class="avatar">
|
||
<img src="assets/images/users/avatar-4.jpg" alt="">
|
||
</div>
|
||
<div class="user-desc">
|
||
<span class="name">Margaret Becker</span>
|
||
<span class="desc">There are new settings available</span>
|
||
<span class="time">2 hours ago</span>
|
||
</div>
|
||
</a>
|
||
</li>
|
||
<li class="all-msgs text-center">
|
||
<p class="m-0"><a href="#">See all Messages</a></p>
|
||
</li>
|
||
</ul>
|
||
</li> -->
|
||
|
||
<!-- <li>
|
||
<a href="javascript:void(0);" class="right-bar-toggle right-menu-item">
|
||
<i class="mdi mdi-settings"></i>
|
||
</a>
|
||
</li> -->
|
||
|
||
<li class="dropdown user-box">
|
||
<a href="#" class="right-menu-item dropdown-toggle" data-toggle="dropdown">
|
||
<i class="mdi mdi-account"></i>
|
||
</a>
|
||
|
||
<ul class="dropdown-menu dropdown-menu-right arrow-dropdown-menu arrow-menu-right user-list notify-list">
|
||
<li>
|
||
<h5>Hi, <?php echo $nama; ?></h5>
|
||
</li>
|
||
<!--<li><a href="#" id="ganti_password"><i class="ti-user m-r-5"></i> Ubah Userlogin dan Password</a></li>-->
|
||
<!--<li><a href="javascript:void(0)"><i class="ti-settings m-r-5"></i> Settings</a></li>
|
||
<li><a href="javascript:void(0)"><i class="ti-lock m-r-5"></i> Lock screen</a></li>-->
|
||
<li><a href="#" id="logout"><i class="ti-power-off m-r-5"></i> Logout</a></li>
|
||
</ul>
|
||
</li>
|
||
|
||
</ul> <!-- end navbar-right -->
|
||
|
||
</div><!-- end container -->
|
||
</div><!-- end navbar -->
|
||
</div>
|
||
<!-- Top Bar End -->
|
||
|
||
|
||
<!-- ========== Left Sidebar Start ========== -->
|
||
<div class="left side-menu" style="background-color:white;">
|
||
<div class="sidebar-inner slimscrollleft">
|
||
|
||
<!--- Sidemenu -->
|
||
<div id="sidebar-menu"><br><br><br><br><br><br><br>
|
||
<ul>
|
||
|
||
<?php if ($jenis=='Admin') { ?>
|
||
<li class="menu-title" style="color:red">BAGIAN UMUM</li>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="kirimbu"><i class="mdi mdi-arrange-send-backward"></i>
|
||
<span> Kirim Surat</span> </a>
|
||
</li>
|
||
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="inboxbu"><i class="mdi mdi-email"></i>
|
||
<span class="label label-danger pull-right" id="not_inboxbu"></span><span> Surat Masuk </span> </a>
|
||
</li>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="kendalibu"><i class="mdi mdi-account-box-outline"></i>
|
||
<span class="label label-danger pull-right" id="not_kendali_bu"></span><span>Kendali BU</span> </a>
|
||
</li>
|
||
<?php } else {} ?>
|
||
|
||
|
||
<li class="menu-title" style="color:green"><?php if ($jenis=='Admin') {echo "TATA USAHA";} else {echo "Main Menu";} ?></li>
|
||
<!-- <li class="has_sub">
|
||
<a href="javascript:void(0);" class="waves-effect" style="color:#707071"><i class="mdi mdi-email-outline"></i> <span>Inbox </span> </a>
|
||
</li>-->
|
||
<?php
|
||
if (($jenis=='Kepala') || ($jenis=='Satker') || ($jenis=='Direksi') || ($jenis=='Sekretaris')) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="uparaf"><i class="mdi mdi-tooltip-image"></i>
|
||
<span> Upload Paraf </span> </a>
|
||
</li>
|
||
<?php }
|
||
|
||
if (($jenis=='Direksi') || ($jenis=='Sekretaris')) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="monitoring"><i class="mdi mdi-recycle"></i>
|
||
<span> Monitoring</span> </a>
|
||
</li>
|
||
<?php } ?>
|
||
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="kode_surat"><i class="mdi mdi-library-books"></i>
|
||
<span> Kode Surat</span> </a>
|
||
</li>
|
||
|
||
<?php
|
||
if ($jenis!='Arsiparis') {
|
||
?>
|
||
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="kirim"><i class="mdi mdi-lead-pencil"></i>
|
||
<span> Kirim Surat</span> </a>
|
||
</li>
|
||
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="inbox"><i class="mdi mdi-email-outline"></i>
|
||
<span class="label label-danger pull-right" id="not_inbox"></span><span> Surat Masuk </span> </a>
|
||
</li>
|
||
<?php
|
||
} else {}
|
||
?>
|
||
|
||
<?php
|
||
if (($jenis=='Admin') || ($nama=='farmasi')) {
|
||
?>
|
||
<li class="has_sub" style="display:none">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="smasuk"><i class="mdi mdi-download"></i>
|
||
<span> Input Surat </span> </a>
|
||
</li>
|
||
<?php }
|
||
if (($jenis=='Admin') || ($jenis=='Kepala') || ($jenis=='Arsiparis') || ($jenis=='Direksi') || ($jenis=='Kepala Urusan Admin') || ($jenis=='Sekretaris')) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="disposisi"><i class="mdi mdi-file-document"></i>
|
||
<span class="label label-danger pull-right" id="not_disposisi"></span> <span>Disposisi </span> </a>
|
||
</li>
|
||
<?php
|
||
}
|
||
if (($jenis=='Kepala') || ($jenis=='Direksi') || ($jenis=='Kepala Urusan Admin') || ($jenis=='Sekretaris')) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="riwayat_disposisi"><i class="mdi mdi-recycle"></i>
|
||
<span>Arsip Disposisi </span> </a>
|
||
</li>
|
||
|
||
<?php
|
||
}
|
||
if (($jenis=='Admin') || ($jenis=='Direksi') || ($jenis=='Sekretaris')) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="kendali"><i class="mdi mdi-file-outline"></i>
|
||
<?php if ($jenis=='Admin') {} else { ?>
|
||
<span class="label label-danger pull-right" id="not_kendali">
|
||
<?php } ?>
|
||
</span><span>Lembar Kendali </span> </a>
|
||
</li>
|
||
<?php }
|
||
if ($jenis=='Admin') {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="kendalitu"><i class="mdi mdi-account-location"></i>
|
||
<span class="label label-danger pull-right" id="not_kendali"></span><span>Kendali TU</span> </a>
|
||
</li>
|
||
<?php }
|
||
if (($jenis=='Admin') || ($satker==15)) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="skeluar"><i class="mdi mdi-send"></i> <span>Surat Keluar </span> </a>
|
||
</li>
|
||
<?php }
|
||
if (($jenis=='Admin') || ($jenis=='Direksi') || ($jenis=='Sekretaris')) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="pencarian"><i class="mdi mdi-magnify"></i> <span>Pencarian </span> </a>
|
||
</li>
|
||
<?php
|
||
}
|
||
|
||
?>
|
||
|
||
<?php
|
||
if (($jenis=='Admin') || ($jenis=='Arsiparis')) {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="arsip"><i class="mdi mdi-archive"></i> <span>Arsip </span> </a>
|
||
</li>
|
||
<?php } ?>
|
||
<?php
|
||
if ($jenis=='Admin') {
|
||
?>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="laporan"><i class="mdi mdi-buffer"></i> <span>Laporan </span> </a>
|
||
</li>
|
||
|
||
<li class="menu-title" style="color:#707071">Master</li>
|
||
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="master"><i class="mdi mdi-settings"></i> <span>Master Data </span> </a>
|
||
</li>
|
||
<!--
|
||
<li class="menu-title" style="color:#707071">Ujicoba</li>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="inbox_u"><i class="mdi mdi-email-outline"></i>
|
||
<span class="label label-danger pull-right" id="not_inbox_u"></span><span> Surat Masuk </span> </a>
|
||
</li>
|
||
<li class="has_sub">
|
||
<a href="#" class="waves-effect" style="color:#707071" id="kirim_u"><i class="mdi mdi-lead-pencil"></i>
|
||
<span> Kirim Surat</span> </a>
|
||
</li>
|
||
-->
|
||
<?php } ?>
|
||
|
||
|
||
</ul>
|
||
</div>
|
||
<!-- Sidebar -->
|
||
<div class="clearfix"></div>
|
||
|
||
</div>
|
||
<!-- Sidebar -left -->
|
||
|
||
</div>
|
||
<!-- Left Sidebar End -->
|
||
|
||
|
||
|
||
<!-- ============================================================== -->
|
||
<!-- Start right Content here -->
|
||
<!-- ============================================================== -->
|
||
<div class="content-page">
|
||
<div class="content">
|
||
|
||
<div class="container" id="main_tag"></div> <!-- container -->
|
||
</div> <!-- content -->
|
||
<!--
|
||
<footer class="footer text-right">
|
||
© 2019 dynandsoftware
|
||
</footer> -->
|
||
|
||
<footer class="main-footer navbar-fixed-bottom" style="background-color:#36404e;color:white;px;padding:10px;" align="center">
|
||
© 2020 dynandsoftware
|
||
</footer>
|
||
</div>
|
||
|
||
|
||
<!-- ============================================================== -->
|
||
<!-- End Right content here -->
|
||
<!-- ============================================================== -->
|
||
|
||
|
||
<!-- Right Sidebar -->
|
||
<div class="side-bar right-bar">
|
||
<a href="javascript:void(0);" class="right-bar-toggle">
|
||
<i class="mdi mdi-close-circle-outline"></i>
|
||
</a>
|
||
<h4 class="">Settings</h4>
|
||
<div class="setting-list nicescroll">
|
||
<div class="row m-t-20">
|
||
<div class="col-xs-8">
|
||
<h5 class="m-0">Notifications</h5>
|
||
<p class="text-muted m-b-0"><small>Do you need them?</small></p>
|
||
</div>
|
||
<div class="col-xs-4 text-right">
|
||
<input type="checkbox" checked data-plugin="switchery" data-color="#7fc1fc" data-size="small"/>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="row m-t-20">
|
||
<div class="col-xs-8">
|
||
<h5 class="m-0">API Access</h5>
|
||
<p class="m-b-0 text-muted"><small>Enable/Disable access</small></p>
|
||
</div>
|
||
<div class="col-xs-4 text-right">
|
||
<input type="checkbox" checked data-plugin="switchery" data-color="#7fc1fc" data-size="small"/>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="row m-t-20">
|
||
<div class="col-xs-8">
|
||
<h5 class="m-0">Auto Updates</h5>
|
||
<p class="m-b-0 text-muted"><small>Keep up to date</small></p>
|
||
</div>
|
||
<div class="col-xs-4 text-right">
|
||
<input type="checkbox" checked data-plugin="switchery" data-color="#7fc1fc" data-size="small"/>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="row m-t-20">
|
||
<div class="col-xs-8">
|
||
<h5 class="m-0">Online Status</h5>
|
||
<p class="m-b-0 text-muted"><small>Show your status to all</small></p>
|
||
</div>
|
||
<div class="col-xs-4 text-right">
|
||
<input type="checkbox" checked data-plugin="switchery" data-color="#7fc1fc" data-size="small"/>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<!-- /Right-bar -->
|
||
|
||
</div>
|
||
<!-- END wrapper -->
|
||
|
||
|
||
|
||
<div id="modal_kode" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
|
||
<div class="modal-dialog modal-lg">
|
||
<div class="modal-content">
|
||
<div class="modal-header no-border">
|
||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||
<h4 class="modal-title" id="myModalLabel">List Kode Surat</h4>
|
||
</div>
|
||
<div class="modal-body" id="modal_body_kode"></div>
|
||
<div class="modal-footer no-border">
|
||
<button type="button" class="btn btn-default waves-effect" data-dismiss="modal" id="keluar_kode">Keluar</button>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<script>
|
||
var resizefunc = [];
|
||
</script>
|
||
|
||
<!-- jQuery -->
|
||
<script src="assets/js/jquery.min.js"></script>
|
||
<script src="assets/js/bootstrap.min.js"></script>
|
||
<script src="assets/js/detect.js"></script>
|
||
<script src="assets/js/fastclick.js"></script>
|
||
<script src="assets/js/jquery.blockUI.js"></script>
|
||
<script src="assets/js/waves.js"></script>
|
||
<script src="assets/js/jquery.slimscroll.js"></script>
|
||
<script src="assets/js/jquery.scrollTo.min.js"></script>
|
||
<script src="plugins/switchery/switchery.min.js"></script>
|
||
|
||
<!-- Counter js -->
|
||
<script src="plugins/waypoints/jquery.waypoints.min.js"></script>
|
||
<script src="plugins/counterup/jquery.counterup.min.js"></script>
|
||
|
||
<!--Morris Chart-->
|
||
<script src="plugins/morris/morris.min.js"></script>
|
||
<script src="plugins/raphael/raphael-min.js"></script>
|
||
|
||
<!-- Dashboard init -->
|
||
<script src="assets/pages/jquery.dashboard.js"></script>
|
||
|
||
<!-- App js -->
|
||
<script src="assets/js/jquery.core.js"></script>
|
||
<script src="assets/js/jquery.app.js"></script>
|
||
|
||
|
||
<script src="plugins/datatables/jquery.dataTables.min.js"></script>
|
||
<script src="plugins/datatables/dataTables.bootstrap.js"></script>
|
||
|
||
<script src="plugins/datatables/dataTables.buttons.min.js"></script>
|
||
<script src="plugins/datatables/buttons.bootstrap.min.js"></script>
|
||
<script src="plugins/datatables/jszip.min.js"></script>
|
||
<script src="plugins/datatables/pdfmake.min.js"></script>
|
||
<script src="plugins/datatables/vfs_fonts.js"></script>
|
||
<script src="plugins/datatables/buttons.html5.min.js"></script>
|
||
<script src="plugins/datatables/buttons.print.min.js"></script>
|
||
<script src="plugins/datatables/dataTables.fixedHeader.min.js"></script>
|
||
<script src="plugins/datatables/dataTables.keyTable.min.js"></script>
|
||
<script src="plugins/datatables/dataTables.responsive.min.js"></script>
|
||
<script src="plugins/datatables/responsive.bootstrap.min.js"></script>
|
||
<script src="plugins/datatables/dataTables.scroller.min.js"></script>
|
||
<script src="plugins/datatables/dataTables.colVis.js"></script>
|
||
<script src="plugins/datatables/dataTables.fixedColumns.min.js"></script>
|
||
<script src="plugins/bootstrap-datepicker/js/bootstrap-datepicker.min.js"></script>
|
||
|
||
<!-- init -->
|
||
<script src="assets/pages/jquery.datatables.init.js"></script>
|
||
<script src="assets/pages/jquery.form-pickers.init.js"></script>
|
||
|
||
<!-- Chart -->
|
||
<script src="plugins/highcharts/highcharts.js"></script>
|
||
<script src="plugins/highcharts/jquery.highchartTable.js"></script>
|
||
|
||
<script src="assets/js/md5.js"></script>
|
||
<script src="assets/js/aes.js"></script>
|
||
|
||
<script type="text/javascript">
|
||
|
||
|
||
|
||
|
||
var sess_nampeg = $('#cek_nampeg').val();
|
||
var cek_jenis = $('#cek_jenis').val();
|
||
var cek_data_user_id = $('#cek_data_user_id').val();
|
||
|
||
$.post('app/home/main.php',{cek_jenis:cek_jenis},function(html){
|
||
$("#main_tag").html('<br><br><br><br><br>'+html);
|
||
});
|
||
|
||
$('#compose').click(function(){
|
||
var cek_jenis = $('#cek_jenis').val();
|
||
$.post('app/home/main.php',{cek_jenis:cek_jenis},function(html){
|
||
$("#main_tag").html('<br><br><br><br><br>'+html);
|
||
});
|
||
});
|
||
|
||
$('#smasuk').click(function(){
|
||
$.post('app/smasuk/main.php',{sess_nampeg:sess_nampeg},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#disposisi').click(function(){
|
||
$.post('app/disposisi/main.php',{cek_data_user_id:cek_data_user_id, jenis:cek_jenis},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#riwayat_disposisi').click(function(){
|
||
$.post('app/riwayat/main.php',{cek_data_user_id:cek_data_user_id, jenis:cek_jenis},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
|
||
$('#monitoring').click(function(){
|
||
$.post('app/monitoring/main.php',{cek_data_user_id:cek_data_user_id, jenis:cek_jenis},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#kendali').click(function(){
|
||
$.post('app/kendali/main.php',{sess_nampeg:sess_nampeg, jenis:cek_jenis},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#kendalitu').click(function(){
|
||
$.post('app/kendalitu/main.php',{sess_nampeg:sess_nampeg, jenis:cek_jenis},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#kendalibu').click(function(){
|
||
$.post('app/kendalibu/main.php',{sess_nampeg:sess_nampeg, jenis:cek_jenis},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#skeluar').click(function(){
|
||
$.post('app/skeluar/main.php',function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#kode_surat').click(function(){
|
||
var id = 0;
|
||
$('#modal_kode').modal('show');
|
||
$('#modal_body_kode').html("");
|
||
$.ajax({
|
||
type: "POST",
|
||
url: "app/kode/main.php",
|
||
data: 'id='+id,
|
||
success: function(data){
|
||
$('#modal_body_kode').html(data);
|
||
}
|
||
});
|
||
//$.post('app/kendali/main.php',{sess_nampeg:sess_nampeg, jenis:cek_jenis},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#kirim').click(function(){
|
||
$.post('app/kirim/main.php',function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#inbox').click(function(){
|
||
$.post('app/inbox/main.php',function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#kirimbu').click(function(){
|
||
$.post('app/kirim/main.php',{/*sat:'3'*/ sat:172},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#inboxbu').click(function(){
|
||
$.post('app/inbox/main.php',{/*sat:'3'*/ sat:172},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#pencarian').click(function(){
|
||
$.post('app/pencarian/main.php',function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#arsip').click(function(){
|
||
$.post('app/arsip/main.php',{},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#laporan').click(function(){
|
||
$.post('app/laporan/main.php',{},function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#master').click(function(){
|
||
$.post('app/master/main.php',function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#kirim_u').click(function(){
|
||
$.post('app/kirim_u/main.php',function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#inbox_u').click(function(){
|
||
$.post('app/inbox_u/main.php',function(html){$("#main_tag").html(html)});
|
||
});
|
||
|
||
$('#uparaf').click(function(){
|
||
var cek_data_user_id = $('#cek_data_user_id').val();
|
||
var cek_jenis = $('#cek_jenis').val();
|
||
$.post('app/master/pejabat/paraf.php',{cek_data_user_id:cek_data_user_id, cek_jenis:cek_jenis},function(html){
|
||
$("#main_tag").html('<br><br><br><br><br>'+html);
|
||
$('#btn_baru_pejabat').hide();
|
||
});
|
||
});
|
||
|
||
//window.history.pushState(null, null, window.location.pathname);
|
||
|
||
var sess_satker = $('#cek_satker').val();
|
||
var sess_jenis = $('#cek_jenis').val();
|
||
|
||
$('#logout').click(function(){
|
||
var d = 'Logout';
|
||
$.ajax({
|
||
type: "POST",
|
||
url: "logout.php",
|
||
data: 'd='+d,
|
||
success: function(data){
|
||
window.location.href='index.php';
|
||
}
|
||
});
|
||
});
|
||
|
||
/*baru*/
|
||
var gtoken=$('#gtoken').val();
|
||
var stoken=$('#stoken').val();
|
||
if (gtoken==stoken) {
|
||
var cek_nama = $('#cek_nama').val();
|
||
if(cek_nama=='') {alert('Silakan login dulu..');$('#logout').trigger('click');} else {}
|
||
} else {
|
||
alert('Session expired');window.location.href='index.php';
|
||
}
|
||
|
||
var cek_data_user_id = $('#cek_data_user_id').val();
|
||
var stoken = $('#stoken').val();
|
||
var cek_token = function(){
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/cek_token.php',
|
||
data: 'data_user_id='+cek_data_user_id
|
||
+'&stoken='+stoken,
|
||
success: function(data){
|
||
if (data==0) {window.location.href='index.php';} else {}
|
||
}
|
||
});
|
||
}
|
||
setInterval(cek_token,15000);
|
||
|
||
var timeout = null;
|
||
var timee = '600000';
|
||
$(document).bind('click keyup mousemove', function(event) {
|
||
if (timeout !== null) {
|
||
clearTimeout(timeout);
|
||
}
|
||
timeout = setTimeout(function() {
|
||
timeout = null;
|
||
console.log('Document Idle since '+timee+' ms');
|
||
window.location.href='index.php';
|
||
}, timee);
|
||
});
|
||
/*eof - baru*/
|
||
|
||
|
||
/*notif*/
|
||
|
||
if (cek_jenis=='Admin') {
|
||
$('#not_disposisi').hide();
|
||
} else {
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/disposisi_notif.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_disposisi').hide();} else {
|
||
$('#not_disposisi').show();
|
||
$('#not_disposisi').html(data);
|
||
}
|
||
}
|
||
});
|
||
|
||
var callAjax_notif_disposisi = function(){
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/disposisi_notif.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_disposisi').hide();} else {
|
||
$('#not_disposisi').show();
|
||
$('#not_disposisi').html(data);
|
||
}
|
||
}
|
||
});
|
||
}
|
||
setInterval(callAjax_notif_disposisi,15000);
|
||
}
|
||
|
||
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/kendali_notif.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_kendali').hide();} else {
|
||
$('#not_kendali').show();
|
||
$('#not_kendali').html(data);
|
||
}
|
||
}
|
||
});
|
||
|
||
var callAjax_notif_kendali = function(){
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/kendali_notif.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_kendali').hide();} else {
|
||
$('#not_kendali').show();
|
||
$('#not_kendali').html(data);
|
||
}
|
||
}
|
||
});
|
||
}
|
||
setInterval(callAjax_notif_kendali,15000);
|
||
|
||
|
||
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/kendali_notif_bu.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_kendali_bu').hide();} else {
|
||
$('#not_kendali_bu').show();
|
||
$('#not_kendali_bu').html(data);
|
||
}
|
||
}
|
||
});
|
||
|
||
var callAjax_notif_kendali_bu = function(){
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/kendali_notif_bu.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_kendali_bu').hide();} else {
|
||
$('#not_kendali_bu').show();
|
||
$('#not_kendali_bu').html(data);
|
||
}
|
||
}
|
||
});
|
||
}
|
||
setInterval(callAjax_notif_kendali_bu,15000);
|
||
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/inbox_notif.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_inbox').hide();} else {
|
||
$('#not_inbox').show();
|
||
$('#not_inbox').html(data);
|
||
}
|
||
}
|
||
});
|
||
|
||
var callAjax_inbox_notif = function(){
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/inbox_notif.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_inbox').hide();} else {
|
||
$('#not_inbox').show();
|
||
$('#not_inbox').html(data);
|
||
}
|
||
}
|
||
});
|
||
}
|
||
setInterval(callAjax_inbox_notif,15000);
|
||
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/inbox_notifbu.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_inboxbu').hide();} else {
|
||
$('#not_inboxbu').show();
|
||
$('#not_inboxbu').html(data);
|
||
}
|
||
}
|
||
});
|
||
|
||
var callAjax_inbox_notifbu = function(){
|
||
$.ajax({
|
||
type: "POST",
|
||
url:'app/notif/inbox_notifbu.php',
|
||
data: 'satker='+sess_satker,
|
||
success: function(data){
|
||
if (data==0) {$('#not_inboxbu').hide();} else {
|
||
$('#not_inboxbu').show();
|
||
$('#not_inboxbu').html(data);
|
||
}
|
||
}
|
||
});
|
||
}
|
||
setInterval(callAjax_inbox_notifbu,15000);
|
||
|
||
$('#ganti_password').click(function(){
|
||
var nm_lama = $('#cek_nama').val();
|
||
var pwd_lama = $('#cek_password').val();
|
||
//var baru = window.prompt("Ganti Password",pwd_lama);
|
||
/*if (!baru) {} else {
|
||
var cek_data_user_id = $('#cek_data_user_id').val();
|
||
var key = 'ganti_password';
|
||
$.ajax({
|
||
type: "POST",
|
||
url: "app/master/user/crud.php",
|
||
data: 'id='+cek_data_user_id
|
||
+'&baru='+baru
|
||
+'&key='+key,
|
||
success: function(data){
|
||
alert('Password terupdate..');
|
||
}
|
||
});
|
||
}*/
|
||
var nm_baru1 = prompt("Userlogin:",nm_lama)
|
||
var pwd_baru = prompt("Password:",pwd_lama)
|
||
if (!nm_baru1) {} else {
|
||
if (nm_baru1==nm_lama) {} else {
|
||
var c = $.trim(nm_baru1);
|
||
var nm_baru = c;
|
||
var key1='cek_nama';
|
||
$.ajax({
|
||
type: "POST",
|
||
url: "app/master/user/crud.php",
|
||
data: 'nama='+nm_baru
|
||
+'&key='+key1,
|
||
success: function(data){
|
||
if (data==0) {
|
||
var cek_data_user_id = $('#cek_data_user_id').val();
|
||
var key = 'ganti_userlogin';
|
||
$.ajax({
|
||
type: "POST",
|
||
url: "app/master/user/crud.php",
|
||
data: 'id='+cek_data_user_id
|
||
+'&baru='+nm_baru
|
||
+'&key='+key,
|
||
success: function(data){
|
||
alert('Userlogin terupdate..');
|
||
}
|
||
});
|
||
} else {alert('Username sudah dipakai..\nGunakan nama yang lain');$('#username').val('');$('#username').focus();}
|
||
}
|
||
});
|
||
}
|
||
}
|
||
if (!pwd_baru) {} else {
|
||
if (pwd_baru==pwd_lama) {} else {
|
||
var cek_data_user_id = $('#cek_data_user_id').val();
|
||
var key = 'ganti_password';
|
||
$.ajax({
|
||
type: "POST",
|
||
url: "app/master/user/crud.php",
|
||
data: 'id='+cek_data_user_id
|
||
+'&baru='+pwd_baru
|
||
+'&key='+key,
|
||
success: function(data){
|
||
alert('Password terupdate..');
|
||
}
|
||
});
|
||
}
|
||
}
|
||
});
|
||
|
||
$("#modal_kode").on("hidden.bs.modal", function () {
|
||
$(this).off('hidden.bs.modal');
|
||
|
||
});
|
||
|
||
$('body').on('keyup', 'input, select, textarea', function() {
|
||
this.value = this.value.replace(/[^0-9A-Za-z()/%@+-.,\b ]/g, '')
|
||
});
|
||
|
||
/*
|
||
function HtmlEncode(s)
|
||
{
|
||
var el = document.createElement("div");
|
||
el.innerText = el.textContent = s;
|
||
s = el.innerHTML;
|
||
return s;
|
||
}
|
||
|
||
alert(HtmlEncode('&;\'><"'));
|
||
*/
|
||
</script>
|
||
<script src="assets/js/enter.js"></script>
|
||
</body>
|
||
</html>
|