Commit 29c08486 by Lalang Trendy Buana Committed by nurchamim

modul: Library DataTable

status: selesai
keterangan:
1. upgrade library dataTable versi terbaru
2. bug fix UI dataTable
parent 64fade56
...@@ -35,19 +35,19 @@ class Data_diri_histori extends MY_Controller ...@@ -35,19 +35,19 @@ class Data_diri_histori extends MY_Controller
{ {
$list = $this->model->get_datatables(); $list = $this->model->get_datatables();
$data = array(); $data = array();
$no = $_POST['start']; $no = $_GET['start'];
foreach ($list as $field) { foreach ($list as $field) {
$no++; $no++;
$row = array(); $row = array();
$row[] = $no; $row[] = $no;
$row[] = ucwords(data_diri_action()); $row[] = ucwords(data_diri_action());
$row[] = date('d-m-Y H:i:s', strtotime($field->tgl_input)); $row[] = date('d-m-Y H:i:s', strtotime($field->tgl_input));
$row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>'; $row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>';
$data[] = $row; $data[] = $row;
} }
$output = array( $output = array(
"draw" => $_POST['draw'], "draw" => $_GET['draw'],
"recordsTotal" => $this->model->count_all(), "recordsTotal" => $this->model->count_all(),
"recordsFiltered" => $this->model->count_filtered(), "recordsFiltered" => $this->model->count_filtered(),
"data" => $data "data" => $data
......
...@@ -35,19 +35,19 @@ class Data_kelengkapan_file_histori extends MY_Controller ...@@ -35,19 +35,19 @@ class Data_kelengkapan_file_histori extends MY_Controller
{ {
$list = $this->model->get_datatables(); $list = $this->model->get_datatables();
$data = array(); $data = array();
$no = $_POST['start']; $no = $_GET['start'];
foreach ($list as $field) { foreach ($list as $field) {
$no++; $no++;
$row = array(); $row = array();
$row[] = $no; $row[] = $no;
$row[] = ucwords(keterangan_action($this->lang->line('data_kelengkapan_file'), $field->action)); $row[] = ucwords(keterangan_action($this->lang->line('data_kelengkapan_file'), $field->action));
$row[] = date('d-m-Y H:i:s', strtotime($field->tanggal_input)); $row[] = date('d-m-Y H:i:s', strtotime($field->tanggal_input));
$row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>'; $row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>';
$data[] = $row; $data[] = $row;
} }
$output = array( $output = array(
"draw" => $_POST['draw'], "draw" => $_GET['draw'],
"recordsTotal" => $this->model->count_all(), "recordsTotal" => $this->model->count_all(),
"recordsFiltered" => $this->model->count_filtered(), "recordsFiltered" => $this->model->count_filtered(),
"data" => $data "data" => $data
......
...@@ -34,7 +34,7 @@ class Data_keluarga_histori extends MY_Controller ...@@ -34,7 +34,7 @@ class Data_keluarga_histori extends MY_Controller
{ {
$list = $this->model->get_datatables(); $list = $this->model->get_datatables();
$data = array(); $data = array();
$no = $_POST['start']; $no = $_GET['start'];
foreach ($list as $field) { foreach ($list as $field) {
$no++; $no++;
$row = array(); $row = array();
...@@ -47,7 +47,7 @@ class Data_keluarga_histori extends MY_Controller ...@@ -47,7 +47,7 @@ class Data_keluarga_histori extends MY_Controller
} }
$output = array( $output = array(
"draw" => $_POST['draw'], "draw" => $_GET['draw'],
"recordsTotal" => $this->model->count_all(), "recordsTotal" => $this->model->count_all(),
"recordsFiltered" => $this->model->count_filtered(), "recordsFiltered" => $this->model->count_filtered(),
"data" => $data "data" => $data
......
...@@ -34,19 +34,19 @@ class Data_sertifikat_histori extends MY_Controller ...@@ -34,19 +34,19 @@ class Data_sertifikat_histori extends MY_Controller
{ {
$list = $this->model->get_datatables(); $list = $this->model->get_datatables();
$data = array(); $data = array();
$no = $_POST['start']; $no = $_GET['start'];
foreach ($list as $field) { foreach ($list as $field) {
$no++; $no++;
$row = array(); $row = array();
$row[] = $no; $row[] = $no;
$row[] = ucwords(keterangan_action($this->lang->line('sertifikat'), $field->action)); $row[] = ucwords(keterangan_action($this->lang->line('sertifikat'), $field->action));
$row[] = date('d-m-Y H:i:s', strtotime($field->tgl_input)); $row[] = date('d-m-Y H:i:s', strtotime($field->tgl_input));
$row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>'; $row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>';
$data[] = $row; $data[] = $row;
} }
$output = array( $output = array(
"draw" => $_POST['draw'], "draw" => $_GET['draw'],
"recordsTotal" => $this->model->count_all(), "recordsTotal" => $this->model->count_all(),
"recordsFiltered" => $this->model->count_filtered(), "recordsFiltered" => $this->model->count_filtered(),
"data" => $data "data" => $data
......
...@@ -34,22 +34,22 @@ class Pengalaman_kerja_histori extends MY_Controller ...@@ -34,22 +34,22 @@ class Pengalaman_kerja_histori extends MY_Controller
{ {
$list = $this->model->get_datatables(); $list = $this->model->get_datatables();
$data = array(); $data = array();
$no = $_POST['start']; $no = $_GET['start'];
foreach ($list as $field) { foreach ($list as $field) {
$no++; $no++;
$row = array(); $row = array();
$row[] = $no; $row[] = $no;
$row[] = ucwords(keterangan_action($this->lang->line('pengalaman_kerja'), $field->action)); $row[] = ucwords(keterangan_action($this->lang->line('pengalaman_kerja'), $field->action));
$row[] = $field->nama_perusahaan; $row[] = $field->nama_perusahaan;
$row[] = $field->jenis_perusahaan; $row[] = $field->jenis_perusahaan;
$row[] = $field->jabatan; $row[] = $field->jabatan;
$row[] = date('d-m-Y H:i:s', strtotime($field->tgl_input)); $row[] = date('d-m-Y H:i:s', strtotime($field->tgl_input));
$row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>'; $row[] = '<a onclick="detail(\'' . md5($field->id) . '\')"><i class="fa fa-file" aria-hidden="true"></i></a>';
$data[] = $row; $data[] = $row;
} }
$output = array( $output = array(
"draw" => $_POST['draw'], "draw" => $_GET['draw'],
"recordsTotal" => $this->model->count_all(), "recordsTotal" => $this->model->count_all(),
"recordsFiltered" => $this->model->count_filtered(), "recordsFiltered" => $this->model->count_filtered(),
"data" => $data "data" => $data
......
...@@ -34,7 +34,7 @@ class Riwayat_pendidikan_histori extends MY_Controller ...@@ -34,7 +34,7 @@ class Riwayat_pendidikan_histori extends MY_Controller
{ {
$list = $this->model->get_datatables(); $list = $this->model->get_datatables();
$data = array(); $data = array();
$no = $_POST['start']; $no = $_GET['start'];
foreach ($list as $field) { foreach ($list as $field) {
$no++; $no++;
$row = array(); $row = array();
...@@ -47,7 +47,7 @@ class Riwayat_pendidikan_histori extends MY_Controller ...@@ -47,7 +47,7 @@ class Riwayat_pendidikan_histori extends MY_Controller
} }
$output = array( $output = array(
"draw" => $_POST['draw'], "draw" => $_GET['draw'],
"recordsTotal" => $this->model->count_all(), "recordsTotal" => $this->model->count_all(),
"recordsFiltered" => $this->model->count_filtered(), "recordsFiltered" => $this->model->count_filtered(),
"data" => $data "data" => $data
......
<?php <?php
if ( ! defined('BASEPATH')) exit('No direct script access allowed'); if (!defined('BASEPATH')) exit('No direct script access allowed');
class Data_diri_histori_m extends CI_Model { class Data_diri_histori_m extends CI_Model
public $table = 'data_karyawan_h'; {
public $table = 'data_karyawan_h';
function get_datatables(){ function get_datatables()
$this->_get_datatables_query(); {
if($_POST['length'] != -1){ $this->_get_datatables_query();
$this->db->limit($_POST['length'], $_POST['start']); if ($_GET['length'] != -1) {
} $this->db->limit($_GET['length'], $_GET['start']);
$query = $this->db->get(); }
return $query->result(); $query = $this->db->get();
} return $query->result();
}
function count_filtered(){ function count_filtered()
$this->_get_datatables_query(); {
$query = $this->db->get(); $this->_get_datatables_query();
return $query->num_rows(); $query = $this->db->get();
} return $query->num_rows();
}
public function count_all(){ public function count_all()
$this->db->select("id")->from($this->table); {
$this->db->where("id_company",$this->session->userdata('id_company')); $this->db->select("id")->from($this->table);
$this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan')); $this->db->where("id_company", $this->session->userdata('id_company'));
return $this->db->count_all_results(); $this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan'));
} return $this->db->count_all_results();
private function _get_datatables_query(){ }
$this->db->select("id, tgl_input")->from($this->table); private function _get_datatables_query()
$this->db->where("id_company",$this->session->userdata('id_company')); {
$this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan')); $this->db->select("id, tgl_input")->from($this->table);
$column_search = array('tgl_input'); $this->db->where("id_company", $this->session->userdata('id_company'));
$i = 0; $this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan'));
$column_search = array('tgl_input');
$i = 0;
foreach ($column_search as $item){ // looping awal foreach ($column_search as $item) { // looping awal
if($_POST['search']['value']){ // jika datatable mengirimkan pencarian dengan metode POST if ($_GET['search']['value']) { // jika datatable mengirimkan pencarian dengan metode POST
if($i===0){ // looping awal if ($i === 0) { // looping awal
$this->db->group_start(); $this->db->group_start();
$this->db->like($item, $_POST['search']['value']); $this->db->like($item, $_GET['search']['value']);
}else{ } else {
$this->db->or_like($item, $_POST['search']['value']); $this->db->or_like($item, $_GET['search']['value']);
} }
if(count($column_search) - 1 == $i){ if (count($column_search) - 1 == $i) {
$this->db->group_end(); $this->db->group_end();
} }
} }
$i++; $i++;
} }
$column_order = array('','action','tgl_input','id'); $column_order = array('', 'action', 'tgl_input', 'id');
if(isset($_POST['order'])){ if (isset($_GET['order'])) {
$this->db->order_by($column_order[$_POST['order']['0']['column']], $_POST['order']['0']['dir']); $this->db->order_by($column_order[$_GET['order']['0']['column']], $_GET['order']['0']['dir']);
} } else {
else{ $order_by = array("tgl_input" => "DESC");
$order_by = array("tgl_input"=>"DESC"); $this->db->order_by(key($order_by), $order_by[key($order_by)]);
$this->db->order_by(key($order_by), $order_by[key($order_by)]); }
} }
}
function get_data($id_md5) { function get_data($id_md5)
$this->db->select('data_karyawan_h.id_karyawan, {
$this->db->select('data_karyawan_h.id_karyawan,
data_karyawan_h.nik, data_karyawan_h.nik,
data_karyawan_h.nama_lengkap, data_karyawan_h.nama_lengkap,
data_karyawan_h.gelar_depan, data_karyawan_h.gelar_depan,
...@@ -95,11 +100,11 @@ class Data_diri_histori_m extends CI_Model { ...@@ -95,11 +100,11 @@ class Data_diri_histori_m extends CI_Model {
master_kelurahan.nama as nama_kel, master_kelurahan.nama as nama_kel,
master_provinsi.id_prov, master_provinsi.id_prov,
master_provinsi.nama as nama_prov'); master_provinsi.nama as nama_prov');
$this->db->join("master_provinsi","master_provinsi.id_prov = data_karyawan_h.id_prov","LEFT"); $this->db->join("master_provinsi", "master_provinsi.id_prov = data_karyawan_h.id_prov", "LEFT");
$this->db->join("master_kota","master_kota.id_kota = data_karyawan_h.id_kab","LEFT"); $this->db->join("master_kota", "master_kota.id_kota = data_karyawan_h.id_kab", "LEFT");
$this->db->join("master_kecamatan","master_kecamatan.id_kecamatan = data_karyawan_h.id_kec","LEFT"); $this->db->join("master_kecamatan", "master_kecamatan.id_kecamatan = data_karyawan_h.id_kec", "LEFT");
$this->db->join("master_kelurahan","master_kelurahan.id_kelurahan = data_karyawan_h.id_kel","LEFT"); $this->db->join("master_kelurahan", "master_kelurahan.id_kelurahan = data_karyawan_h.id_kel", "LEFT");
$this->db->where('md5(id)', $id_md5); $this->db->where('md5(id)', $id_md5);
return $this->db->get($this->table)->row(); return $this->db->get($this->table)->row();
} }
} }
<?php <?php
defined('BASEPATH') OR exit('No direct script access allowed'); defined('BASEPATH') or exit('No direct script access allowed');
class Data_kelengkapan_file_histori_m extends CI_Model { class Data_kelengkapan_file_histori_m extends CI_Model
{
public $table = 'data_kelengkapan_file_h'; public $table = 'data_kelengkapan_file_h';
function get_datatables(){ function get_datatables()
{
$this->_get_datatables_query(); $this->_get_datatables_query();
if($_POST['length'] != -1){ if ($_GET['length'] != -1) {
$this->db->limit($_POST['length'], $_POST['start']); $this->db->limit($_GET['length'], $_GET['start']);
} }
$query = $this->db->get(); $query = $this->db->get();
return $query->result(); return $query->result();
} }
function count_filtered(){ function count_filtered()
{
$this->_get_datatables_query(); $this->_get_datatables_query();
$query = $this->db->get(); $query = $this->db->get();
return $query->num_rows(); return $query->num_rows();
} }
public function count_all(){ public function count_all()
{
$this->db->select("id")->from($this->table); $this->db->select("id")->from($this->table);
$this->db->where("id_company",$this->session->userdata('id_company')); $this->db->where("id_company", $this->session->userdata('id_company'));
return $this->db->count_all_results(); return $this->db->count_all_results();
} }
private function _get_datatables_query(){ private function _get_datatables_query()
{
$this->db->select("id, action, tanggal_input")->from($this->table); $this->db->select("id, action, tanggal_input")->from($this->table);
$this->db->where("id_company",$this->session->userdata('id_company')); $this->db->where("id_company", $this->session->userdata('id_company'));
$this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan')); $this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan'));
$column_search = array('tanggal_input'); $column_search = array('tanggal_input');
$i = 0; $i = 0;
foreach ($column_search as $item){ // looping awal foreach ($column_search as $item) { // looping awal
if($_POST['search']['value']){ // jika datatable mengirimkan pencarian dengan metode POST if ($_GET['search']['value']) { // jika datatable mengirimkan pencarian dengan metode POST
if($i===0){ // looping awal if ($i === 0) { // looping awal
$this->db->group_start(); $this->db->group_start();
$this->db->like($item, $_POST['search']['value']); $this->db->like($item, $_GET['search']['value']);
}else{ } else {
$this->db->or_like($item, $_POST['search']['value']); $this->db->or_like($item, $_GET['search']['value']);
} }
if(count($column_search) - 1 == $i){ if (count($column_search) - 1 == $i) {
$this->db->group_end(); $this->db->group_end();
} }
} }
$i++; $i++;
} }
$column_order = array('','action','tanggal_input','id'); $column_order = array('', 'action', 'tanggal_input', 'id');
if(isset($_POST['order'])){ if (isset($_GET['order'])) {
$this->db->order_by($column_order[$_POST['order']['0']['column']], $_POST['order']['0']['dir']); $this->db->order_by($column_order[$_GET['order']['0']['column']], $_GET['order']['0']['dir']);
} } else {
else{ $order_by = array("tanggal_input" => "DESC");
$order_by = array("tanggal_input"=>"DESC");
$this->db->order_by(key($order_by), $order_by[key($order_by)]); $this->db->order_by(key($order_by), $order_by[key($order_by)]);
} }
} }
function get_data($id_md5) { function get_data($id_md5)
{
$this->db->where('md5(id)', $id_md5); $this->db->where('md5(id)', $id_md5);
return $this->db->get($this->table)->row(); return $this->db->get($this->table)->row();
} }
......
<?php <?php
if ( ! defined('BASEPATH')) exit('No direct script access allowed'); if (!defined('BASEPATH')) exit('No direct script access allowed');
class Data_keluarga_histori_m extends CI_Model { class Data_keluarga_histori_m extends CI_Model
public $table = 'data_keluarga_h'; {
public $table = 'data_keluarga_h';
function get_datatables(){ function get_datatables()
{
$this->_get_datatables_query(); $this->_get_datatables_query();
if($_POST['length'] != -1){ if ($_GET['length'] != -1) {
$this->db->limit($_POST['length'], $_POST['start']); $this->db->limit($_GET['length'], $_GET['start']);
} }
$query = $this->db->get(); $query = $this->db->get();
return $query->result(); return $query->result();
} }
function count_filtered(){ function count_filtered()
{
$this->_get_datatables_query(); $this->_get_datatables_query();
$query = $this->db->get(); $query = $this->db->get();
return $query->num_rows(); return $query->num_rows();
} }
public function count_all(){ public function count_all()
{
$this->db->select("id")->from($this->table); $this->db->select("id")->from($this->table);
$this->db->where('id_karyawan', $this->input->get('id_karyawan')); $this->db->where("id_company", $this->session->userdata('id_company'));
$this->db->where("id_company",$this->session->userdata('id_company'));
return $this->db->count_all_results(); return $this->db->count_all_results();
} }
private function _get_datatables_query()
private function _get_datatables_query(){ {
$this->db->select("id, action, hub_keluarga, tgl_input")->from($this->table); $this->db->select("id, action, hub_keluarga, tgl_input")->from($this->table);
$this->db->where('id_karyawan', $this->input->get('id_karyawan')); $this->db->where('id_karyawan', $this->input->get('id_karyawan'));
$column_search = array('tgl_input'); $column_search = array('tgl_input');
$i = 0; $i = 0;
foreach ($column_search as $item){ // looping awal foreach ($column_search as $item) { // looping awal
if($_POST['search']['value']){ // jika datatable mengirimkan pencarian dengan metode POST if ($_GET['search']['value']) { // jika datatable mengirimkan pencarian dengan metode POST
if($i===0){ // looping awal if ($i === 0) { // looping awal
$this->db->group_start(); $this->db->group_start();
$this->db->like($item, $_POST['search']['value']); $this->db->like($item, $_GET['search']['value']);
}else{ } else {
$this->db->or_like($item, $_POST['search']['value']); $this->db->or_like($item, $_GET['search']['value']);
} }
if(count($column_search) - 1 == $i){ if (count($column_search) - 1 == $i) {
$this->db->group_end(); $this->db->group_end();
} }
} }
$i++; $i++;
} }
$column_order = array('', 'action','hub_keluarga','tgl_input','id'); $column_order = array('', 'action', 'hub_keluarga', 'tgl_input', 'id');
if(isset($_POST['order'])){ if (isset($_GET['order'])) {
$this->db->order_by($column_order[$_POST['order']['0']['column']], $_POST['order']['0']['dir']); $this->db->order_by($column_order[$_GET['order']['0']['column']], $_GET['order']['0']['dir']);
} } else {
else{ $order_by = array("tgl_input" => "DESC");
$order_by = array("tgl_input"=>"DESC");
$this->db->order_by(key($order_by), $order_by[key($order_by)]); $this->db->order_by(key($order_by), $order_by[key($order_by)]);
} }
} }
function get_data($id_md5) { function get_data($id_md5)
{
$this->db->where('md5(id)', $id_md5); $this->db->where('md5(id)', $id_md5);
return $this->db->get($this->table)->row(); return $this->db->get($this->table)->row();
} }
......
<?php <?php
if ( ! defined('BASEPATH')) exit('No direct script access allowed'); if (!defined('BASEPATH')) exit('No direct script access allowed');
class Data_sertifikat_histori_m extends CI_Model { class Data_sertifikat_histori_m extends CI_Model
public $table = 'data_sertifikat_h'; {
public $table = 'data_sertifikat_h';
function get_datatables(){ function get_datatables()
$this->_get_datatables_query(); {
if($_POST['length'] != -1){ $this->_get_datatables_query();
$this->db->limit($_POST['length'], $_POST['start']); if ($_GET['length'] != -1) {
} $this->db->limit($_GET['length'], $_GET['start']);
$query = $this->db->get(); }
return $query->result(); $query = $this->db->get();
} return $query->result();
}
function count_filtered(){ function count_filtered()
$this->_get_datatables_query(); {
$query = $this->db->get(); $this->_get_datatables_query();
return $query->num_rows(); $query = $this->db->get();
} return $query->num_rows();
}
public function count_all(){ public function count_all()
$this->db->select("id")->from($this->table); {
$this->db->where("id_company",$this->session->userdata('id_company')); $this->db->select("id")->from($this->table);
return $this->db->count_all_results(); $this->db->where("id_company", $this->session->userdata('id_company'));
} return $this->db->count_all_results();
private function _get_datatables_query(){ }
$this->db->select("id, action, tgl_input")->from($this->table); private function _get_datatables_query()
$this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan')); {
$column_search = array('tgl_input'); $this->db->select("id, action, tgl_input")->from($this->table);
$i = 0; $this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan'));
$column_search = array('tgl_input');
$i = 0;
foreach ($column_search as $item){ // looping awal foreach ($column_search as $item) { // looping awal
if($_POST['search']['value']){ // jika datatable mengirimkan pencarian dengan metode POST if ($_GET['search']['value']) { // jika datatable mengirimkan pencarian dengan metode POST
if($i===0){ // looping awal if ($i === 0) { // looping awal
$this->db->group_start(); $this->db->group_start();
$this->db->like($item, $_POST['search']['value']); $this->db->like($item, $_GET['search']['value']);
}else{ } else {
$this->db->or_like($item, $_POST['search']['value']); $this->db->or_like($item, $_GET['search']['value']);
} }
if(count($column_search) - 1 == $i){ if (count($column_search) - 1 == $i) {
$this->db->group_end(); $this->db->group_end();
} }
} }
$i++; $i++;
} }
$column_order = array('','action', 'tgl_input', 'id'); $column_order = array('', 'action', 'tgl_input', 'id');
if(isset($_POST['order'])){ if (isset($_GET['order'])) {
$this->db->order_by($column_order[$_POST['order']['0']['column']], $_POST['order']['0']['dir']); $this->db->order_by($column_order[$_GET['order']['0']['column']], $_GET['order']['0']['dir']);
} } else {
else{ $order_by = array("tgl_input" => "DESC");
$order_by = array("tgl_input"=>"DESC"); $this->db->order_by(key($order_by), $order_by[key($order_by)]);
$this->db->order_by(key($order_by), $order_by[key($order_by)]); }
} }
}
function get_data($id_md5) { function get_data($id_md5)
$this->db->where('md5(id)', $id_md5); {
return $this->db->get($this->table)->row(); $this->db->where('md5(id)', $id_md5);
} return $this->db->get($this->table)->row();
}
} }
<?php <?php
if ( ! defined('BASEPATH')) exit('No direct script access allowed'); if (!defined('BASEPATH')) exit('No direct script access allowed');
class Pengalaman_kerja_histori_m extends CI_Model { class Pengalaman_kerja_histori_m extends CI_Model
public $table = 'riwayat_pekerjaan_h'; {
public $table = 'riwayat_pekerjaan_h';
function get_datatables(){ function get_datatables()
$this->_get_datatables_query(); {
if($_POST['length'] != -1){ $this->_get_datatables_query();
$this->db->limit($_POST['length'], $_POST['start']); if ($_GET['length'] != -1) {
} $this->db->limit($_GET['length'], $_GET['start']);
$query = $this->db->get(); }
return $query->result(); $query = $this->db->get();
} return $query->result();
}
function count_filtered(){ function count_filtered()
$this->_get_datatables_query(); {
$query = $this->db->get(); $this->_get_datatables_query();
return $query->num_rows(); $query = $this->db->get();
} return $query->num_rows();
}
public function count_all(){ public function count_all()
$this->db->select("id")->from($this->table); {
$this->db->where("id_company",$this->session->userdata('id_company')); $this->db->select("id")->from($this->table);
return $this->db->count_all_results(); $this->db->where("id_company", $this->session->userdata('id_company'));
} return $this->db->count_all_results();
private function _get_datatables_query(){ }
$this->db->select("id, nama_perusahaan, jenis_perusahaan, jabatan, action, tgl_input")->from($this->table); private function _get_datatables_query()
$this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan')); {
$column_search = array('tgl_input'); $this->db->select("id, nama_perusahaan, jenis_perusahaan, jabatan, action, tgl_input")->from($this->table);
$i = 0; $this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan'));
$column_search = array('tgl_input');
$i = 0;
foreach ($column_search as $item){ // looping awal foreach ($column_search as $item) { // looping awal
if($_POST['search']['value']){ // jika datatable mengirimkan pencarian dengan metode POST if ($_GET['search']['value']) { // jika datatable mengirimkan pencarian dengan metode POST
if($i===0){ // looping awal if ($i === 0) { // looping awal
$this->db->group_start(); $this->db->group_start();
$this->db->like($item, $_POST['search']['value']); $this->db->like($item, $_GET['search']['value']);
}else{ } else {
$this->db->or_like($item, $_POST['search']['value']); $this->db->or_like($item, $_GET['search']['value']);
} }
if(count($column_search) - 1 == $i){ if (count($column_search) - 1 == $i) {
$this->db->group_end(); $this->db->group_end();
} }
} }
$i++; $i++;
} }
$column_order = array('','action', 'nama_perusahaan','jenis_perusahaan','jabatan', 'tgl_input', 'id'); $column_order = array('', 'action', 'nama_perusahaan', 'jenis_perusahaan', 'jabatan', 'tgl_input', 'id');
if(isset($_POST['order'])){ if (isset($_GET['order'])) {
$this->db->order_by($column_order[$_POST['order']['0']['column']], $_POST['order']['0']['dir']); $this->db->order_by($column_order[$_GET['order']['0']['column']], $_GET['order']['0']['dir']);
} } else {
else{ $order_by = array("tgl_input" => "DESC");
$order_by = array("tgl_input"=>"DESC"); $this->db->order_by(key($order_by), $order_by[key($order_by)]);
$this->db->order_by(key($order_by), $order_by[key($order_by)]); }
} }
}
function get_data($id_md5) { function get_data($id_md5)
$this->db->select('*, kota.nama as nama_kota, provinsi.nama as nama_provinsi'); {
$this->db->join('master_kota kota', 'kota.id_kota = riwayat_pekerjaan_h.kota', 'left'); $this->db->select('*, kota.nama as nama_kota, provinsi.nama as nama_provinsi');
$this->db->join('master_provinsi provinsi', 'provinsi.id_prov = riwayat_pekerjaan_h.provinsi', 'left'); $this->db->join('master_kota kota', 'kota.id_kota = riwayat_pekerjaan_h.kota', 'left');
$this->db->where('md5(id)', $id_md5); $this->db->join('master_provinsi provinsi', 'provinsi.id_prov = riwayat_pekerjaan_h.provinsi', 'left');
return $this->db->get($this->table)->row(); $this->db->where('md5(id)', $id_md5);
} return $this->db->get($this->table)->row();
}
} }
<?php <?php
if ( ! defined('BASEPATH')) exit('No direct script access allowed'); if (!defined('BASEPATH')) exit('No direct script access allowed');
class Riwayat_pendidikan_histori_m extends CI_Model { class Riwayat_pendidikan_histori_m extends CI_Model
public $table = 'riwayat_pendidikan_h'; {
public $table = 'riwayat_pendidikan_h';
function get_datatables(){ function get_datatables()
$this->_get_datatables_query(); {
if($_POST['length'] != -1){ $this->_get_datatables_query();
$this->db->limit($_POST['length'], $_POST['start']); if ($_GET['length'] != -1) {
} $this->db->limit($_GET['length'], $_GET['start']);
$query = $this->db->get(); }
return $query->result(); $query = $this->db->get();
} return $query->result();
}
function count_filtered(){ function count_filtered()
$this->_get_datatables_query(); {
$query = $this->db->get(); $this->_get_datatables_query();
return $query->num_rows(); $query = $this->db->get();
} return $query->num_rows();
}
public function count_all(){ public function count_all()
$this->db->select("id")->from($this->table); {
$this->db->where("id_company",$this->session->userdata('id_company')); $this->db->select("id")->from($this->table);
return $this->db->count_all_results(); $this->db->where("id_company", $this->session->userdata('id_company'));
} return $this->db->count_all_results();
private function _get_datatables_query(){ }
$this->db->select("id, action, jenjang, tgl_input")->from($this->table); private function _get_datatables_query()
$this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan')); {
$column_search = array('tgl_input'); $this->db->select("id, action, jenjang, tgl_input")->from($this->table);
$i = 0; $this->db->where('md5(id_karyawan)', $this->input->get('id_karyawan'));
$column_search = array('tgl_input');
$i = 0;
foreach ($column_search as $item){ // looping awal foreach ($column_search as $item) { // looping awal
if($_POST['search']['value']){ // jika datatable mengirimkan pencarian dengan metode POST if ($_GET['search']['value']) { // jika datatable mengirimkan pencarian dengan metode POST
if($i===0){ // looping awal if ($i === 0) { // looping awal
$this->db->group_start(); $this->db->group_start();
$this->db->like($item, $_POST['search']['value']); $this->db->like($item, $_GET['search']['value']);
}else{ } else {
$this->db->or_like($item, $_POST['search']['value']); $this->db->or_like($item, $_GET['search']['value']);
} }
if(count($column_search) - 1 == $i){ if (count($column_search) - 1 == $i) {
$this->db->group_end(); $this->db->group_end();
} }
} }
$i++; $i++;
} }
$column_order = array('', 'action', 'jenjang','tgl_input','id'); $column_order = array('', 'action', 'jenjang', 'tgl_input', 'id');
if(isset($_POST['order'])){ if (isset($_GET['order'])) {
$this->db->order_by($column_order[$_POST['order']['0']['column']], $_POST['order']['0']['dir']); $this->db->order_by($column_order[$_GET['order']['0']['column']], $_GET['order']['0']['dir']);
} } else {
else{ $order_by = array("tgl_input" => "DESC");
$order_by = array("tgl_input"=>"DESC"); $this->db->order_by(key($order_by), $order_by[key($order_by)]);
$this->db->order_by(key($order_by), $order_by[key($order_by)]); }
} }
}
function get_data($id_md5) { function get_data($id_md5)
$this->db->where('md5(id)', $id_md5); {
return $this->db->get($this->table)->row(); $this->db->where('md5(id)', $id_md5);
} return $this->db->get($this->table)->row();
}
} }
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function () {
$(".download").click(function() { $(".download").click(function () {
var jenis = $(this).attr('id'); var jenis = $(this).attr('id');
window.location.href = "<?= route('laporan.absensi.download').'?periode_awal='.$periode_awal.'&periode_akhir='.$periode_akhir.'&hadir='.$hadir.'&terlambat='.$terlambat.'&pc='.$pc.'&tap='.$tap.'&alpa='.$alpa.'&sakit='.$sakit.'&izin='.$izin.'&cuti='.$cuti.'&libur='.$libur.'&id_karyawan='.$id_karyawan.'&id_cabang='.$id_cabang.'&id_departemen='.$id_departemen ?>"+"&jenis="+jenis; window.location.href = "<?= route('laporan.absensi.download') . '?periode_awal=' . $periode_awal . '&periode_akhir=' . $periode_akhir . '&hadir=' . $hadir . '&terlambat=' . $terlambat . '&pc=' . $pc . '&tap=' . $tap . '&alpa=' . $alpa . '&sakit=' . $sakit . '&izin=' . $izin . '&cuti=' . $cuti . '&libur=' . $libur . '&id_karyawan=' . $id_karyawan . '&id_cabang=' . $id_cabang . '&id_departemen=' . $id_departemen ?>" + "&jenis=" + jenis;
}); });
}); });
</script> </script>
<div class="table-responsive"> <div class="table-responsive">
<div class="btn-group pull-right"> <div class="btn-group pull-right">
<?php <?php
if (in_array($this->level_user, array('3', '7'))) { ?> if (in_array($this->level_user, array('3', '7'))) { ?>
<button type="button" class="btn btn-primary download" id="pdf" aria-haspopup="true" aria-expanded="false"> <button type="button" class="btn btn-primary download" id="pdf" aria-haspopup="true" aria-expanded="false">
<i class="fa fa-download"></i> <?= $this->lang->line('button_unduh') ?> <i class="fa fa-download"></i> <?= $this->lang->line('button_unduh') ?>
</button> </button>
<?php }else{ ?> <?php } else { ?>
<button type="button" class="btn btn-primary dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> <button type="button" class="btn btn-primary dropdown-toggle" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
<i class="fa fa-download"></i> <?= $this->lang->line('button_unduh') ?> <i class="fa fa-download"></i> <?= $this->lang->line('button_unduh') ?>
</button> </button>
...@@ -50,9 +50,9 @@ ...@@ -50,9 +50,9 @@
<script type="text/javascript"> <script type="text/javascript">
var m_jam_kerja_libur = <?= $m_jam_kerja_libur ?>; var m_jam_kerja_libur = <?= $m_jam_kerja_libur ?>;
var m_libur_nasional = <?= $m_libur_nasional ?>; var m_libur_nasional = <?= $m_libur_nasional ?>;
$(function() { $(function () {
table = $('#list_data').DataTable({ table = $('#list_data').DataTable({
'searching': false, 'searching': false,
'paging': true, 'paging': true,
...@@ -61,10 +61,10 @@ ...@@ -61,10 +61,10 @@
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'language': { 'language': {
<?php if ($this->code_lang == 'id') : ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>', <?php if ($this->code_lang == 'id'): ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>',
'sEmptyTable': 'Tidak ada data untuk ditampilkan', 'sEmptyTable': 'Tidak ada data untuk ditampilkan',
'searchPlaceholder': 'Kode/Nama' 'searchPlaceholder': 'Kode/Nama'
<?php else : ?> 'searchPlaceholder': 'Code/Name' <?php else: ?> 'searchPlaceholder': 'Code/Name'
<?php endif; ?> <?php endif; ?>
}, },
"processing": true, "processing": true,
...@@ -72,25 +72,25 @@ ...@@ -72,25 +72,25 @@
"order": [], "order": [],
"ajax": { "ajax": {
"url": "<?= route('laporan.absensi.data.list').'?periode_awal='.$periode_awal.'&periode_akhir='.$periode_akhir.'&hadir='.$hadir.'&terlambat='.$terlambat.'&pc='.$pc.'&tap='.$tap.'&alpa='.$alpa.'&sakit='.$sakit.'&izin='.$izin.'&cuti='.$cuti.'&libur='.$libur.'&id_karyawan='.$id_karyawan.'&id_cabang='.$id_cabang.'&id_departemen='.$id_departemen ?>", "url": "<?= route('laporan.absensi.data.list') . '?periode_awal=' . $periode_awal . '&periode_akhir=' . $periode_akhir . '&hadir=' . $hadir . '&terlambat=' . $terlambat . '&pc=' . $pc . '&tap=' . $tap . '&alpa=' . $alpa . '&sakit=' . $sakit . '&izin=' . $izin . '&cuti=' . $cuti . '&libur=' . $libur . '&id_karyawan=' . $id_karyawan . '&id_cabang=' . $id_cabang . '&id_departemen=' . $id_departemen ?>",
"type": "GET", "type": "GET",
}, },
"aoColumnDefs": [{ "aoColumnDefs": [{
'bSortable': false, 'bSortable': false,
'aTargets': ['no-sort'] 'aTargets': ['no-sort']
}], }],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td:eq(0)', nRow).css({'width': '10px','text-align': 'center','vertical-align':'top'}); $('td:eq(0)', nRow).css({ 'width': '10px', 'text-align': 'center', 'vertical-align': 'top' });
$('td:eq(1)', nRow).css({'width': '100px','text-align': 'center','vertical-align':'top'}); $('td:eq(1)', nRow).css({ 'width': '100px', 'text-align': 'center', 'vertical-align': 'top' });
$('td:eq(2)', nRow).css({'text-align': 'left','vertical-align':'top'}); $('td:eq(2)', nRow).css({ 'text-align': 'left', 'vertical-align': 'top' });
$('td:eq(3)', nRow).css({'width': '200px','text-align': 'left','vertical-align':'top'}); $('td:eq(3)', nRow).css({ 'width': '200px', 'text-align': 'left', 'vertical-align': 'top' });
$('td:eq(4)', nRow).css({'width': '120px','text-align': 'center','vertical-align':'top'}); $('td:eq(4)', nRow).css({ 'width': '120px', 'text-align': 'center', 'vertical-align': 'top' });
$('td:eq(5)', nRow).css({'width': '120px','text-align': 'center','vertical-align':'top'}); $('td:eq(5)', nRow).css({ 'width': '120px', 'text-align': 'center', 'vertical-align': 'top' });
$('td:eq(6)', nRow).css({'width': '120px','text-align': 'center','vertical-align':'top'}); $('td:eq(6)', nRow).css({ 'width': '120px', 'text-align': 'center', 'vertical-align': 'top' });
$('td:eq(7)', nRow).css({'width': '120px','text-align': 'center','vertical-align':'top'}); $('td:eq(7)', nRow).css({ 'width': '120px', 'text-align': 'center', 'vertical-align': 'top' });
$('td:eq(8)', nRow).css({'width': '120px','text-align': 'center','vertical-align':'top'}); $('td:eq(8)', nRow).css({ 'width': '120px', 'text-align': 'center', 'vertical-align': 'top' });
<?php if ($this->level_user == 1) { ?> <?php if ($this->level_user == 1) { ?>
$('td:eq(-1)', nRow).css({'width': '10px','text-align': 'center'}); $('td:eq(-1)', nRow).css({ 'width': '10px', 'text-align': 'center' });
<?php } ?> <?php } ?>
set_background_libur(aData[1], nRow); set_background_libur(aData[1], nRow);
}, },
...@@ -98,12 +98,12 @@ ...@@ -98,12 +98,12 @@
}); });
function set_background_libur(data, row) { function set_background_libur(data, row) {
var temp = data.split("<br>"); var temp = data.split("<br>");
var tanggal = temp[1]; var tanggal = temp[1];
var week_of_day = moment(tanggal, "DD-MM-YYYY").format("E"); var week_of_day = moment(tanggal, "DD-MM-YYYY").format("E");
var y_m_d = moment(tanggal, "DD-MM-YYYY").format("YYYY-MM-DD"); var y_m_d = moment(tanggal, "DD-MM-YYYY").format("YYYY-MM-DD");
if(m_jam_kerja_libur.includes(week_of_day) || m_libur_nasional.includes(y_m_d)) { if (m_jam_kerja_libur.includes(week_of_day) || m_libur_nasional.includes(y_m_d)) {
$(row).css('background-color', '<?= $this->config->item("warna_background_libur") ?>'); $(row).css('background-color', '<?= $this->config->item("warna_background_libur") ?>');
} }
} }
......
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
</table> </table>
</div> </div>
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
// reconfigure(); // reconfigure();
list_data = $('#list_data').DataTable({ list_data = $('#list_data').DataTable({
'searching': true, 'searching': true,
...@@ -28,10 +28,10 @@ ...@@ -28,10 +28,10 @@
// 'scrollCollapse': true, // 'scrollCollapse': true,
// 'fixedColumns': true, // 'fixedColumns': true,
'language': { 'language': {
<?php if ($this->code_lang == 'id') : ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>', <?php if ($this->code_lang == 'id'): ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>',
'sEmptyTable': 'Tidak ada data untuk ditampilkan', 'sEmptyTable': 'Tidak ada data untuk ditampilkan',
'searchPlaceholder': 'Tanggal' 'searchPlaceholder': 'Tanggal'
<?php else : ?> 'searchPlaceholder': 'Date' <?php else: ?> 'searchPlaceholder': 'Date'
<?php endif; ?> <?php endif; ?>
}, },
"processing": true, "processing": true,
...@@ -41,20 +41,20 @@ ...@@ -41,20 +41,20 @@
"ajax": { "ajax": {
"url": "<?= route('master.karyawan.datadiri.histori.table') ?>", "url": "<?= route('master.karyawan.datadiri.histori.table') ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
d.id_karyawan = '<?= $id_karyawan_md5 ?>'; d.id_karyawan = '<?= $id_karyawan_md5 ?>';
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [{
"aTargets": [0,3], "aTargets": [0, 3],
"bSortable": false "bSortable": false
}], }],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td:eq(0)', nRow).css({ $('td:eq(0)', nRow).css({
'text-align': 'center', 'text-align': 'center',
'width': '10px' 'width': '10px'
...@@ -78,9 +78,9 @@ ...@@ -78,9 +78,9 @@
}); });
function detail(id) { function detail(id) {
$('#tampil_form').load("<?= route('master.karyawan.datadiri.histori.detail') ?>/" + id, function() { $('#tampil_form').load("<?= route('master.karyawan.datadiri.histori.detail') ?>/" + id, function () {
$('#modal_form').modal('show'); $('#modal_form').modal('show');
$(".title").text("Detail Data"); $(".title").text("Detail Data");
}); });
} }
</script> </script>
\ No newline at end of file
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
list_data_temp(); list_data_temp();
$(document).on('click', '#btn_import_karyawan', function() { $(document).on('click', '#btn_import_karyawan', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
$('.form_import #message').html(""); $('.form_import #message').html("");
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
contentType: false, contentType: false,
processData: false, processData: false,
dataType: "json", dataType: "json",
success: function(result) { success: function (result) {
if (result.success == true) { if (result.success == true) {
list_data_temp(); list_data_temp();
} }
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html(result.message); $('.form_import #message').html(result.message);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong><?= $this->lang->line('error') ?></strong></font>'); $('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong><?= $this->lang->line('error') ?></strong></font>');
...@@ -42,13 +42,13 @@ ...@@ -42,13 +42,13 @@
}); });
$(document).on('click', '.btn_edit', function() { $(document).on('click', '.btn_edit', function () {
var id = $(this).attr('id'); var id = $(this).attr('id');
window.location.href = "<?= route('karyawan.import.form.edit') ?>" + "/" + id window.location.href = "<?= route('karyawan.import.form.edit') ?>" + "/" + id
}); });
$(document).on('click', '.btn_form_hapus', function() { $(document).on('click', '.btn_form_hapus', function () {
var id = $(this).attr('id'); var id = $(this).attr('id');
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("<?= $this->lang->line('title_form_hapus_data') ?>"); $(".title").text("<?= $this->lang->line('title_form_hapus_data') ?>");
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
$(".tombol").append('<button class="btn_hapus btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> <?= $this->lang->line('button_form_hapus') ?></button>'); $(".tombol").append('<button class="btn_hapus btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> <?= $this->lang->line('button_form_hapus') ?></button>');
//btn_delete //btn_delete
$('.btn_hapus').on('click', function() { $('.btn_hapus').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
...@@ -66,13 +66,13 @@ ...@@ -66,13 +66,13 @@
url: "<?= route('karyawan.import.delete') ?>", url: "<?= route('karyawan.import.delete') ?>",
data: 'id_temp=' + id, data: 'id_temp=' + id,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message); $("#modal_hapus .title").html(result.message);
loading.stop(); loading.stop();
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
}); });
// # SIMPAN SEMUA DATA TEMPORARY // # SIMPAN SEMUA DATA TEMPORARY
$(document).on('click', '.btn_simpan_semua', function() { $(document).on('click', '.btn_simpan_semua', function () {
var id = $(this).attr('id'); var id = $(this).attr('id');
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("<?= $this->lang->line('title_form_simpan_data') ?>"); $(".title").text("<?= $this->lang->line('title_form_simpan_data') ?>");
...@@ -94,7 +94,7 @@ ...@@ -94,7 +94,7 @@
$(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> <?= $this->lang->line('button_form_simpan') ?></button>'); $(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> <?= $this->lang->line('button_form_simpan') ?></button>');
//btn_delete //btn_delete
$('.btn_save_semua').on('click', function() { $('.btn_save_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
...@@ -102,13 +102,13 @@ ...@@ -102,13 +102,13 @@
url: "<?= route('karyawan.import.publishall') ?>", url: "<?= route('karyawan.import.publishall') ?>",
data: 'id=' + id, data: 'id=' + id,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message); $("#modal_hapus .title").html(result.message);
loading.stop(); loading.stop();
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -118,7 +118,7 @@ ...@@ -118,7 +118,7 @@
}); });
}); });
$(document).on('click', '.btn_hapus_semua', function() { $(document).on('click', '.btn_hapus_semua', function () {
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("<?= $this->lang->line('title_form_hapus_data') ?>"); $(".title").text("<?= $this->lang->line('title_form_hapus_data') ?>");
$("#modal_hapus .card-body").show(); $("#modal_hapus .card-body").show();
...@@ -127,20 +127,20 @@ ...@@ -127,20 +127,20 @@
$(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> <?= $this->lang->line('button_form_hapus') ?></button>'); $(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> <?= $this->lang->line('button_form_hapus') ?></button>');
//btn_delete //btn_delete
$('.btn_delete_semua').on('click', function() { $('.btn_delete_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
type: 'DELETE', type: 'DELETE',
url: "<?= route('karyawan.import.deleteall') ?>", url: "<?= route('karyawan.import.deleteall') ?>",
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message); $("#modal_hapus .title").html(result.message);
loading.stop(); loading.stop();
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -233,9 +233,7 @@ ...@@ -233,9 +233,7 @@
</div> </div>
</div> </div>
<div class="row mt-2"> <div class="row mt-2">
<div id="listdata" class="col-md-12"> <div id="listdata" class="table-responsive col-md-12"></div>
</div>
</div> </div>
</div> </div>
</div> </div>
...@@ -270,4 +268,4 @@ ...@@ -270,4 +268,4 @@
</div> </div>
</div> </div>
</div> </div>
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
\ No newline at end of file
<div class="row"> <div class="row">
<div class="col-md-12"> <div class="col-md-12">
<div id="map_canvas2" style="width:100%; height:580px;"></div> <div id="map_canvas2" style="width:100%; height:580px;"></div>
...@@ -7,19 +5,21 @@ ...@@ -7,19 +5,21 @@
</div> </div>
<div class="row mt-1"> <div class="row mt-1">
<div class="col-md-12"> <div class="col-md-12">
<table id="listrekap" class="table table-striped" style="width:100%"> <div class="table-responsive">
<thead> <table id="listrekap" class="table table-striped" style="width:100%">
<tr class="bg-tr"> <thead>
<th class="text-center">NO</th> <tr class="bg-tr">
<th class="text-left text-uppercase"><?= $this->lang->line('nama'); ?></th> <th class="text-center">NO</th>
<th class="text-left text-uppercase"><?= $this->lang->line('cabang'); ?></th> <th class="text-left text-uppercase"><?= $this->lang->line('nama'); ?></th>
<th class="text-left text-uppercase"><?= $this->lang->line('departemen'); ?></th> <th class="text-left text-uppercase"><?= $this->lang->line('cabang'); ?></th>
<th class="text-center text-uppercase"><?= $this->lang->line('jumlah_aktivitas'); ?></th> <th class="text-left text-uppercase"><?= $this->lang->line('departemen'); ?></th>
</tr> <th class="text-center text-uppercase"><?= $this->lang->line('jumlah_aktivitas'); ?></th>
</thead> </tr>
<tbody> </thead>
</tbody> <tbody>
</table> </tbody>
</table>
</div>
</div> </div>
</div> </div>
...@@ -31,19 +31,19 @@ ...@@ -31,19 +31,19 @@
var beaches = []; var beaches = [];
var mapCentre; var mapCentre;
var tgl_mulai = '<?= $tgl_mulai ?>'; var tgl_mulai = '<?= $tgl_mulai ?>';
var tgl_selesai = '<?= $tgl_selesai ?>'; var tgl_selesai = '<?= $tgl_selesai ?>';
var id_karyawan = '<?= $id_karyawan ?>'; var id_karyawan = '<?= $id_karyawan ?>';
var id_cabang = '<?= $id_cabang ?>'; var id_cabang = '<?= $id_cabang ?>';
var id_departemen = '<?= $id_departemen ?>'; var id_departemen = '<?= $id_departemen ?>';
var map; var map;
var lat_longs_map = new Array(); var lat_longs_map = new Array();
var markers = []; // Create a marker array to hold your markers var markers = []; // Create a marker array to hold your markers
var beaches = []; var beaches = [];
$.get("<?= route("laporan.aktivitas.data.maps.lokasi") ?>"+"/"+tgl_mulai+"/"+tgl_selesai+"/"+id_karyawan+"/"+id_cabang+"/"+id_departemen, function(data){ $.get("<?= route("laporan.aktivitas.data.maps.lokasi") ?>" + "/" + tgl_mulai + "/" + tgl_selesai + "/" + id_karyawan + "/" + id_cabang + "/" + id_departemen, function (data) {
$.each(data, function(index, element) { $.each(data, function (index, element) {
var arr = []; var arr = [];
arr.push(element.lat); arr.push(element.lat);
arr.push(element.long); arr.push(element.long);
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
setMarkers(beaches); setMarkers(beaches);
fitMapToBounds_map(); fitMapToBounds_map();
},"json"); }, "json");
var mapCentre; var mapCentre;
...@@ -80,7 +80,7 @@ ...@@ -80,7 +80,7 @@
} }
function initialize() { function initialize() {
var varcenter = new google.maps.LatLng(-0.4183772,117.4237542); var varcenter = new google.maps.LatLng(-0.4183772, 117.4237542);
var varZoom = 5.4; var varZoom = 5.4;
var mapOptions = { var mapOptions = {
zoom: varZoom, zoom: varZoom,
...@@ -97,7 +97,7 @@ ...@@ -97,7 +97,7 @@
var bounds = new google.maps.LatLngBounds(); var bounds = new google.maps.LatLngBounds();
if (lat_longs_map.length > 0) { if (lat_longs_map.length > 0) {
for (var i=0; i<lat_longs_map.length; i++) { for (var i = 0; i < lat_longs_map.length; i++) {
bounds.extend(lat_longs_map[i]); bounds.extend(lat_longs_map[i]);
} }
map.fitBounds(bounds); map.fitBounds(bounds);
...@@ -107,53 +107,52 @@ ...@@ -107,53 +107,52 @@
initialize(); initialize();
$(function() { $(function () {
list_data = $('#listrekap').DataTable({ list_data = $('#listrekap').DataTable({
'searching' : false, 'searching': false,
'paging' : true, 'paging': true,
'lengthChange' : true, 'lengthChange': true,
'ordering' : true, 'ordering': true,
'info' : true, 'info': true,
'scrollX' :true, 'scrollX': true,
'scrollCollapse': true, 'scrollCollapse': true,
'language' :{ 'language': {
<?php if ($this->code_lang == 'id') : ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>', <?php if ($this->code_lang == 'id'): ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>',
'sEmptyTable': 'Tidak ada data untuk ditampilkan', 'sEmptyTable': 'Tidak ada data untuk ditampilkan',
'searchPlaceholder': 'Keterangan' 'searchPlaceholder': 'Keterangan'
<?php else : ?> 'searchPlaceholder': 'Description' <?php else: ?> 'searchPlaceholder': 'Description'
<?php endif; ?> <?php endif; ?>
}, },
"processing" : true, "processing": true,
"serverSide" : true, "serverSide": true,
"order" : [], "order": [],
"ajax" : { "ajax": {
"url": "<?= route('laporan.aktivitas.listrekap') ?>", "url": "<?= route('laporan.aktivitas.listrekap') ?>",
"type": "GET", "type": "GET",
"data": { "data": {
"tgl_mulai" : "<?= $tgl_mulai ?>", "tgl_mulai": "<?= $tgl_mulai ?>",
"tgl_selesai" : "<?= $tgl_selesai ?>", "tgl_selesai": "<?= $tgl_selesai ?>",
"id_karyawan" : "<?= $id_karyawan ?>", "id_karyawan": "<?= $id_karyawan ?>",
"id_cabang" : "<?= $id_cabang ?>", "id_cabang": "<?= $id_cabang ?>",
"id_departemen" : "<?= $id_departemen ?>" "id_departemen": "<?= $id_departemen ?>"
}, },
"complete" : function(data){ "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [ "aoColumnDefs": [
{ "aTargets": [0], "bSortable": false}, { "aTargets": [0], "bSortable": false },
{ "aTargets": [-1], "bSortable": false } { "aTargets": [-1], "bSortable": false }
], ],
"fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) { "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td:eq(0)', nRow).css({'text-align':'center','width':'10px'}); $('td:eq(0)', nRow).css({ 'text-align': 'center', 'width': '10px' });
$('td:eq(2)', nRow).css({'text-align':'left','width':'350px'}); $('td:eq(2)', nRow).css({ 'text-align': 'left', 'width': '350px' });
$('td:eq(3)', nRow).css({'text-align':'left','width':'350px'}); $('td:eq(3)', nRow).css({ 'text-align': 'left', 'width': '350px' });
$('td:eq(4)', nRow).css({'text-align':'center','width':'150px'}); $('td:eq(4)', nRow).css({ 'text-align': 'center', 'width': '150px' });
} }
});
})
</script>
});
})
</script>
\ No newline at end of file
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
$(document).on('click','.btn_detail',function(){ $(document).on('click', '.btn_detail', function () {
var id = $(this).attr("id"); var id = $(this).attr("id");
$('#modal_detail_sos').modal('show'); $('#modal_detail_sos').modal('show');
$('#foto').empty(); $('#foto').empty();
$.get("<?= route("sos.laporan.detail") ?>"+"/"+id, function(data){ $.get("<?= route("sos.laporan.detail") ?>" + "/" + id, function (data) {
// SET DETAIL SOS // SET DETAIL SOS
$("#nama_karyawan").text(data.nama_karyawan); $("#nama_karyawan").text(data.nama_karyawan);
$("#jabatan").text(data.jabatan); $("#jabatan").text(data.jabatan);
$("#tanggal").text(data.tanggal); $("#tanggal").text(data.tanggal);
$("#keterangan").text(data.keterangan); $("#keterangan").text(data.keterangan);
},"json"); }, "json");
$.get('<?= route("sos.laporan.detail.foto") ?>/'+id, function(data) { $.get('<?= route("sos.laporan.detail.foto") ?>/' + id, function (data) {
if(data != null) { if (data != null) {
for (const [key, value] of Object.entries(data)) { for (const [key, value] of Object.entries(data)) {
$('#foto').append('<img src="'+value+'" alt="..." class="img-thumbnail">'); $('#foto').append('<img src="' + value + '" alt="..." class="img-thumbnail">');
}
} }
}
}, 'json'); }, 'json');
}); });
}); });
...@@ -33,25 +33,27 @@ ...@@ -33,25 +33,27 @@
</div> </div>
<div class="row mt-1"> <div class="row mt-1">
<div class="col-md-12"> <div class="col-md-12">
<table id="list_data" class="table table-striped" style="width:100%"> <div class="table-responsive">
<thead> <table id="list_data" class="table table-striped" style="width:100%">
<tr class="bg-tr"> <thead>
<th class="text-center">NO</th> <tr class="bg-tr">
<th class="text-left"><?= strtoupper($this->lang->line('tgl')); ?></th> <th class="text-center">NO</th>
<th class="text-left"><?= strtoupper($this->lang->line('nama')); ?></th> <th class="text-left"><?= strtoupper($this->lang->line('tgl')); ?></th>
<th class="text-left"><?= strtoupper($this->lang->line('keterangan')); ?></th> <th class="text-left"><?= strtoupper($this->lang->line('nama')); ?></th>
<?php <th class="text-left"><?= strtoupper($this->lang->line('keterangan')); ?></th>
if(in_array($this->level_user, array("1"))) { <?php
?> if (in_array($this->level_user, array("1"))) {
<th class="text-center"><?= strtoupper($this->lang->line('aksi')); ?></th> ?>
<?php <th class="text-center"><?= strtoupper($this->lang->line('aksi')); ?></th>
<?php
} }
?> ?>
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
</tbody> </tbody>
</table> </table>
</div>
</div> </div>
</div> </div>
...@@ -105,53 +107,53 @@ ...@@ -105,53 +107,53 @@
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
list_data = $('#list_data').DataTable({ list_data = $('#list_data').DataTable({
'searching' : true, 'searching': true,
'paging' : true, 'paging': true,
'lengthChange' : true, 'lengthChange': true,
'ordering' : true, 'ordering': true,
'info' : true, 'info': true,
'scrollX' :true, 'scrollX': true,
'scrollCollapse': true, 'scrollCollapse': true,
'language' : { 'language': {
<?php if ($this->code_lang == 'id') : ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>', <?php if ($this->code_lang == 'id'): ?> 'url': '<?= base_url("assets/plugins/datatables/dataTables-language-id.json") ?>',
'sEmptyTable': 'Tidak ada data untuk ditampilkan', 'sEmptyTable': 'Tidak ada data untuk ditampilkan',
'searchPlaceholder': 'Keterangan' 'searchPlaceholder': 'Keterangan'
<?php else : ?> 'searchPlaceholder': 'Description' <?php else: ?> 'searchPlaceholder': 'Description'
<?php endif; ?> <?php endif; ?>
}, },
"processing" : true, "processing": true,
"serverSide" : true, "serverSide": true,
"order" : [], "order": [],
"ajax" : { "ajax": {
"url": "<?= route('sos.laporan.listdata')."/".$tgl_mulai."/".$tgl_selesai."/".$id_karyawan."/".$id_cabang."/".$id_departemen ?>", "url": "<?= route('sos.laporan.listdata') . "/" . $tgl_mulai . "/" . $tgl_selesai . "/" . $id_karyawan . "/" . $id_cabang . "/" . $id_departemen ?>",
"type": "GET", "type": "GET",
"complete" : function(data){ "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [ "aoColumnDefs": [
{ "aTargets": [0], "bSortable": false}<?php { "aTargets": [0], "bSortable": false }<?php
if (in_array($this->level_user, array("1"))) { if (in_array($this->level_user, array("1"))) {
?> ?>
, { "aTargets": [-1], "bSortable": false } , { "aTargets": [-1], "bSortable": false }
<?php }?> <?php } ?>
], ],
"fnRowCallback": function( nRow, aData, iDisplayIndex, iDisplayIndexFull ) { "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td:eq(0)', nRow).css({'text-align':'center','width':'10px'}); $('td:eq(0)', nRow).css({ 'text-align': 'center', 'width': '10px' });
$('td:eq(1)', nRow).css({'text-align':'left','width':'100px'}); $('td:eq(1)', nRow).css({ 'text-align': 'left', 'width': '100px' });
$('td:eq(2)', nRow).css({'text-align':'left','width':'200px'}); $('td:eq(2)', nRow).css({ 'text-align': 'left', 'width': '200px' });
<?php <?php
if (in_array($this->level_user, array("1"))) { if (in_array($this->level_user, array("1"))) {
?> ?>
$('td:eq(-1)', nRow).css({'text-align':'center','width':'50px'}); $('td:eq(-1)', nRow).css({ 'text-align': 'center', 'width': '50px' });
<?php }?> <?php } ?>
} }
}); });
}) })
</script> </script>
\ No newline at end of file
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
<button class="btn btn-danger btn-sm" title="Data tidak lengkap"></button> <span>Data tidak lengkap</span> <button class="btn btn-danger btn-sm" title="Data tidak lengkap"></button> <span>Data tidak lengkap</span>
</div> </div>
</div> </div>
<div class="row mt-2"> <div class="table-responsive mt-2">
<table id="list_data" class="table table-striped table-bordered" style="width:100%"> <table id="list_data" class="table table-striped table-bordered" style="width:100%">
<thead> <thead>
<tr> <tr>
...@@ -123,4 +123,4 @@ ...@@ -123,4 +123,4 @@
</div> </div>
</div> </div>
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
<?= $script ?> <?= $script ?>
\ No newline at end of file
<!-- BAGIN DATATABLE --> <!-- BAGIN DATATABLE -->
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
'searchDelay': 1000, 'searchDelay': 1000,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'fixedColumns': { 'fixedColumns': {
...@@ -31,18 +31,15 @@ ...@@ -31,18 +31,15 @@
"ajax": { "ajax": {
"url": "<?= route('payroll.data.komponen.datatable', ['id_karyawan' => 'all', 'id_cabang' => 'all', 'id_departemen' => 'all']) ?>", "url": "<?= route('payroll.data.komponen.datatable', ['id_karyawan' => 'all', 'id_cabang' => 'all', 'id_departemen' => 'all']) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": "_all",
"bSortable": false
},
{ {
"className": "text-center", "className": "text-center",
"targets": [0] "targets": [0]
...@@ -51,12 +48,14 @@ ...@@ -51,12 +48,14 @@
"className": "text-left", "className": "text-left",
"targets": [1, 2, 3, 4] "targets": [1, 2, 3, 4]
}, },
{
"className": "text-right",
"targets": "_all"
},
], ],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('text-right');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td', nRow).css({
'white-space': 'nowrap',
});
if (aData[5] == "-") { if (aData[5] == "-") {
$('td:eq(5)', nRow).css({ $('td:eq(5)', nRow).css({
'background-color': '#FF7588', 'background-color': '#FF7588',
...@@ -73,8 +72,8 @@ ...@@ -73,8 +72,8 @@
<!-- BEGIN FORM INPUT --> <!-- BEGIN FORM INPUT -->
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
$('#modal-nominal').on('show.bs.modal', function(event) { $('#modal-nominal').on('show.bs.modal', function (event) {
$('#message').hide(); $('#message').hide();
let button = $(event.relatedTarget); let button = $(event.relatedTarget);
...@@ -111,7 +110,7 @@ ...@@ -111,7 +110,7 @@
modal.find('#komponen').val(komponen); modal.find('#komponen').val(komponen);
modal.find('#nominal_pendapatan').focus(); modal.find('#nominal_pendapatan').focus();
$("#nominal_pendapatan").keydown(function(event) { $("#nominal_pendapatan").keydown(function (event) {
if (event.which == 13) { if (event.which == 13) {
event.preventDefault(); event.preventDefault();
$('.btn_save').click(); $('.btn_save').click();
...@@ -119,7 +118,7 @@ ...@@ -119,7 +118,7 @@
}); });
}) })
$(document).on('click', '.btn_save', function(e) { $(document).on('click', '.btn_save', function (e) {
e.preventDefault(); e.preventDefault();
var loading = Ladda.create(this); var loading = Ladda.create(this);
...@@ -135,12 +134,12 @@ ...@@ -135,12 +134,12 @@
url: "<?= route('payroll.data.komponen.update') ?>", url: "<?= route('payroll.data.komponen.update') ?>",
data: param, data: param,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
loading.stop(); loading.stop();
$('#message').show(); $('#message').show();
$('#message').html(result.message); $('#message').html(result.message);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('#message').show(); $('#message').show();
$('#message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>'); $('#message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>');
...@@ -179,7 +178,7 @@ ...@@ -179,7 +178,7 @@
<!-- BEGIN FILTER DATA --> <!-- BEGIN FILTER DATA -->
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function () {
dropdown_cabang(); dropdown_cabang();
$('#filter #id_karyawan').select2({ $('#filter #id_karyawan').select2({
...@@ -189,7 +188,7 @@ ...@@ -189,7 +188,7 @@
url: '<?= route("dropdown.karyawan.encrypt") ?>', url: '<?= route("dropdown.karyawan.encrypt") ?>',
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -199,7 +198,7 @@ ...@@ -199,7 +198,7 @@
minLength: 3 minLength: 3
}); });
$('#filter #btn_cari').click(function() { $('#filter #btn_cari').click(function () {
let loading = Ladda.create(this); let loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -211,7 +210,7 @@ ...@@ -211,7 +210,7 @@
loading.stop(); loading.stop();
}); });
$('#filter #btn_filter').click(function() { $('#filter #btn_filter').click(function () {
let loading = Ladda.create(this); let loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -232,7 +231,7 @@ ...@@ -232,7 +231,7 @@
url: '<?= route("dropdown.cabang") ?>', url: '<?= route("dropdown.cabang") ?>',
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -259,7 +258,7 @@ ...@@ -259,7 +258,7 @@
url: '<?= route("dropdown.departemen.by.cabang") ?>/' + id_cabang, url: '<?= route("dropdown.departemen.by.cabang") ?>/' + id_cabang,
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -347,7 +346,7 @@ ...@@ -347,7 +346,7 @@
$numrow = 2; $numrow = 2;
} }
?> ?>
<th rowspan="<?= $numrow ?>" class="align-middle text-center" width="30">NO</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NO</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">DEPARTEMEN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">DEPARTEMEN</th>
...@@ -419,4 +418,4 @@ ...@@ -419,4 +418,4 @@
</div> </div>
</div> </div>
</div> </div>
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
\ No newline at end of file
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
list_data_temp(); list_data_temp();
$(document).on('click', '#btn_form_template', function() { $(document).on('click', '#btn_form_template', function () {
$('#tampil_form').load("<?= route('payroll.data.komponen.import.form.templateimport') ?>", function() { $('#tampil_form').load("<?= route('payroll.data.komponen.import.form.templateimport') ?>", function () {
$('#modal_form').modal('show'); $('#modal_form').modal('show');
$(".title").text("Download Template Data Komponen"); $(".title").text("Download Template Data Komponen");
$(".btn_unduh").addClass("btn_unduh btn btn-success"); $(".btn_unduh").addClass("btn_unduh btn btn-success");
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
}); });
}); });
$(document).on('click', '#btn_import', function() { $(document).on('click', '#btn_import', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
$('.form_import #message').html(""); $('.form_import #message').html("");
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
contentType: false, contentType: false,
processData: false, processData: false,
dataType: "json", dataType: "json",
success: function(result) { success: function (result) {
if (result.success == true) { if (result.success == true) {
// list_data_temp(); // list_data_temp();
} }
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html(result.message); $('.form_import #message').html(result.message);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>'); $('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>');
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
}); });
// # SIMPAN SEMUA DATA TEMPORARY // # SIMPAN SEMUA DATA TEMPORARY
$(document).on('click', '.btn_simpan_semua', function() { $(document).on('click', '.btn_simpan_semua', function () {
var id = $(this).attr('id'); var id = $(this).attr('id');
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("Apakah anda ingin menyimpan semua data ini?"); $(".title").text("Apakah anda ingin menyimpan semua data ini?");
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
$(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>'); $(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>');
//btn_delete //btn_delete
$('.btn_save_semua').on('click', function() { $('.btn_save_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
...@@ -71,17 +71,17 @@ ...@@ -71,17 +71,17 @@
url: "<?= route('payroll.data.komponen.import.publishall') ?>", url: "<?= route('payroll.data.komponen.import.publishall') ?>",
data: 'id=' + id, data: 'id=' + id,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF")); $("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF"));
loading.stop(); loading.stop();
// Set a timeout to hide the element // Set a timeout to hide the element
setTimeout(function() { setTimeout(function () {
$("#modal_hapus").modal('hide'); $("#modal_hapus").modal('hide');
}, 1000); }, 1000);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
}); });
}); });
$(document).on('click', '.btn_hapus_semua', function() { $(document).on('click', '.btn_hapus_semua', function () {
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("Apakah anda ingin menghapus semua data ini?"); $(".title").text("Apakah anda ingin menghapus semua data ini?");
$("#modal_hapus .card-body").show(); $("#modal_hapus .card-body").show();
...@@ -100,24 +100,24 @@ ...@@ -100,24 +100,24 @@
$(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>'); $(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>');
//btn_delete //btn_delete
$('.btn_delete_semua').on('click', function() { $('.btn_delete_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
type: 'DELETE', type: 'DELETE',
url: "<?= route('payroll.data.komponen.import.deleteall') ?>", url: "<?= route('payroll.data.komponen.import.deleteall') ?>",
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF")); $("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF"));
loading.stop(); loading.stop();
// Set a timeout to hide the element // Set a timeout to hide the element
setTimeout(function() { setTimeout(function () {
$("#modal_hapus").modal('hide'); $("#modal_hapus").modal('hide');
}, 1000); }, 1000);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -203,7 +203,7 @@ ...@@ -203,7 +203,7 @@
<button class="btn btn-danger btn-sm" title="Data Kosong"></button> <span>Data tidak lengkap</span> <button class="btn btn-danger btn-sm" title="Data Kosong"></button> <span>Data tidak lengkap</span>
</div> </div>
</div> </div>
<div class="row mt-2"> <div class="table-responsive mt-2">
<div id="listdata" class="col-md-12"> <div id="listdata" class="col-md-12">
</div> </div>
...@@ -241,4 +241,4 @@ ...@@ -241,4 +241,4 @@
</div> </div>
</div> </div>
</div> </div>
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
\ No newline at end of file
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
$numrow = 2; $numrow = 2;
} }
?> ?>
<th rowspan="<?= $numrow ?>" class="align-middle text-center" width="30">NO</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NO</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">NIK</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NIK</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th>
...@@ -54,9 +54,9 @@ ...@@ -54,9 +54,9 @@
</table> </table>
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
// if(confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')){ // if(confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')){
// window.location.reload(); // window.location.reload();
// } // }
...@@ -64,7 +64,7 @@ ...@@ -64,7 +64,7 @@
'searching': true, 'searching': true,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'scrollCollapse': true, 'scrollCollapse': true,
...@@ -83,22 +83,15 @@ ...@@ -83,22 +83,15 @@
"ajax": { "ajax": {
"url": "<?= route('payroll.data.komponen.import.listdata') ?>", "url": "<?= route('payroll.data.komponen.import.listdata') ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": [1],
"bSortable": true
},
{
"aTargets": "_all",
"bSortable": false
},
{ {
"visible": false, "visible": false,
"targets": [1] "targets": [1]
...@@ -111,12 +104,11 @@ ...@@ -111,12 +104,11 @@
"className": "text-left", "className": "text-left",
"targets": [1, 2, 3, 4, 5] "targets": [1, 2, 3, 4, 5]
}, },
{
"className": "text-right",
"targets": "_all"
},
], ],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('text-right');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
for (let index = 1; index < aData.length; index++) { for (let index = 1; index < aData.length; index++) {
const col = aData[index]; const col = aData[index];
...@@ -136,4 +128,4 @@ ...@@ -136,4 +128,4 @@
}, },
}); });
}); });
</script> </script>
\ No newline at end of file
<!-- BAGIN DATATABLE --> <!-- BAGIN DATATABLE -->
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -32,18 +32,15 @@ ...@@ -32,18 +32,15 @@
"ajax": { "ajax": {
"url": "<?= route('payroll.data.komponen.kehadiran.datatable', ['id_karyawan' => 'all', 'id_cabang' => 'all', 'id_departemen' => 'all']) ?>", "url": "<?= route('payroll.data.komponen.kehadiran.datatable', ['id_karyawan' => 'all', 'id_cabang' => 'all', 'id_departemen' => 'all']) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": "_all",
"bSortable": false
},
{ {
"className": "text-center", "className": "text-center",
"targets": [0] "targets": [0]
...@@ -52,12 +49,14 @@ ...@@ -52,12 +49,14 @@
"className": "text-left", "className": "text-left",
"targets": [1, 2, 3, 4] "targets": [1, 2, 3, 4]
}, },
{
"className": "text-right",
"targets": "_all"
},
], ],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('text-right');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td', nRow).css({
'white-space': 'nowrap',
});
if (aData[5] == "-") { if (aData[5] == "-") {
$('td:eq(5)', nRow).css({ $('td:eq(5)', nRow).css({
'background-color': '#FF7588', 'background-color': '#FF7588',
...@@ -74,8 +73,8 @@ ...@@ -74,8 +73,8 @@
<!-- BEGIN FORM INPUT --> <!-- BEGIN FORM INPUT -->
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
$('#modal-nominal').on('show.bs.modal', function(event) { $('#modal-nominal').on('show.bs.modal', function (event) {
$('#message').hide(); $('#message').hide();
let button = $(event.relatedTarget); let button = $(event.relatedTarget);
...@@ -112,7 +111,7 @@ ...@@ -112,7 +111,7 @@
modal.find('#komponen').val(komponen); modal.find('#komponen').val(komponen);
modal.find('#nominal_pendapatan').focus(); modal.find('#nominal_pendapatan').focus();
$("#nominal_pendapatan").keydown(function(event) { $("#nominal_pendapatan").keydown(function (event) {
if (event.which == 13) { if (event.which == 13) {
event.preventDefault(); event.preventDefault();
$('.btn_save').click(); $('.btn_save').click();
...@@ -120,7 +119,7 @@ ...@@ -120,7 +119,7 @@
}); });
}) })
$(document).on('click', '.btn_save', function(e) { $(document).on('click', '.btn_save', function (e) {
e.preventDefault(); e.preventDefault();
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -135,12 +134,12 @@ ...@@ -135,12 +134,12 @@
url: "<?= route('payroll.data.komponen.kehadiran.update') ?>", url: "<?= route('payroll.data.komponen.kehadiran.update') ?>",
data: param, data: param,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
loading.stop(); loading.stop();
$('#message').show(); $('#message').show();
$('#message').html(result.message); $('#message').html(result.message);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('#message').show(); $('#message').show();
$('#message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>'); $('#message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>');
...@@ -179,7 +178,7 @@ ...@@ -179,7 +178,7 @@
<!-- BEGIN FILTER DATA --> <!-- BEGIN FILTER DATA -->
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function () {
dropdown_cabang(); dropdown_cabang();
$('#filter #id_karyawan').select2({ $('#filter #id_karyawan').select2({
...@@ -189,7 +188,7 @@ ...@@ -189,7 +188,7 @@
url: '<?= route("dropdown.karyawan.encrypt") ?>', url: '<?= route("dropdown.karyawan.encrypt") ?>',
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -199,7 +198,7 @@ ...@@ -199,7 +198,7 @@
minLength: 3 minLength: 3
}); });
$('#filter #btn_cari').click(function() { $('#filter #btn_cari').click(function () {
let loading = Ladda.create(this); let loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -211,7 +210,7 @@ ...@@ -211,7 +210,7 @@
loading.stop(); loading.stop();
}); });
$('#filter #btn_filter').click(function() { $('#filter #btn_filter').click(function () {
let loading = Ladda.create(this); let loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -232,7 +231,7 @@ ...@@ -232,7 +231,7 @@
url: '<?= route("dropdown.cabang") ?>', url: '<?= route("dropdown.cabang") ?>',
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -259,7 +258,7 @@ ...@@ -259,7 +258,7 @@
url: '<?= route("dropdown.departemen.by.cabang") ?>/' + id_cabang, url: '<?= route("dropdown.departemen.by.cabang") ?>/' + id_cabang,
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -347,7 +346,7 @@ ...@@ -347,7 +346,7 @@
$numrow = 2; $numrow = 2;
} }
?> ?>
<th rowspan="<?= $numrow ?>" class="align-middle text-center" width="30">NO</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NO</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">DEPARTEMEN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">DEPARTEMEN</th>
...@@ -367,6 +366,7 @@ ...@@ -367,6 +366,7 @@
echo '<th class="align-middle text-center">' . strtoupper($komponen['nm_komponen']) . (($komponen['flag_persentase_gapok'] == '1') ? ' (' . str_replace('.00', '', $komponen['gapok_persen']) . '%)' : '') . '</th>'; echo '<th class="align-middle text-center">' . strtoupper($komponen['nm_komponen']) . (($komponen['flag_persentase_gapok'] == '1') ? ' (' . str_replace('.00', '', $komponen['gapok_persen']) . '%)' : '') . '</th>';
} }
} }
echo '<th class="align-middle text-center">TOTAL</th>';
echo '</tr>'; echo '</tr>';
} }
?> ?>
...@@ -408,4 +408,4 @@ ...@@ -408,4 +408,4 @@
</div> </div>
</div> </div>
</div> </div>
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
\ No newline at end of file
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
list_data_temp(); list_data_temp();
$(document).on('click', '#btn_form_template', function() { $(document).on('click', '#btn_form_template', function () {
$('#tampil_form').load("<?= route('payroll.data.komponen.kehadiran.import.form.templateimport') ?>", function() { $('#tampil_form').load("<?= route('payroll.data.komponen.kehadiran.import.form.templateimport') ?>", function () {
$('#modal_form').modal('show'); $('#modal_form').modal('show');
$(".title").text("Download Template Data Komponen Kehadiran"); $(".title").text("Download Template Data Komponen Kehadiran");
$(".btn_unduh").addClass("btn_unduh btn btn-success"); $(".btn_unduh").addClass("btn_unduh btn btn-success");
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
}); });
}); });
$(document).on('click', '#btn_import', function() { $(document).on('click', '#btn_import', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
$('.form_import #message').html(""); $('.form_import #message').html("");
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
contentType: false, contentType: false,
processData: false, processData: false,
dataType: "json", dataType: "json",
success: function(result) { success: function (result) {
if (result.success == true) { if (result.success == true) {
// list_data_temp(); // list_data_temp();
} }
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html(result.message); $('.form_import #message').html(result.message);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>'); $('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>');
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
}); });
// # SIMPAN SEMUA DATA TEMPORARY // # SIMPAN SEMUA DATA TEMPORARY
$(document).on('click', '.btn_simpan_semua', function() { $(document).on('click', '.btn_simpan_semua', function () {
var id = $(this).attr('id'); var id = $(this).attr('id');
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("Apakah anda ingin menyimpan semua data ini?"); $(".title").text("Apakah anda ingin menyimpan semua data ini?");
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
$(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>'); $(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>');
//btn_delete //btn_delete
$('.btn_save_semua').on('click', function() { $('.btn_save_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
...@@ -71,17 +71,17 @@ ...@@ -71,17 +71,17 @@
url: "<?= route('payroll.data.komponen.kehadiran.import.publishall') ?>", url: "<?= route('payroll.data.komponen.kehadiran.import.publishall') ?>",
data: 'id=' + id, data: 'id=' + id,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF")); $("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF"));
loading.stop(); loading.stop();
// Set a timeout to hide the element // Set a timeout to hide the element
setTimeout(function() { setTimeout(function () {
$("#modal_hapus").modal('hide'); $("#modal_hapus").modal('hide');
}, 1000); }, 1000);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -91,7 +91,7 @@ ...@@ -91,7 +91,7 @@
}); });
}); });
$(document).on('click', '.btn_hapus_semua', function() { $(document).on('click', '.btn_hapus_semua', function () {
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("Apakah anda ingin menghapus semua data ini?"); $(".title").text("Apakah anda ingin menghapus semua data ini?");
$("#modal_hapus .card-body").show(); $("#modal_hapus .card-body").show();
...@@ -100,24 +100,24 @@ ...@@ -100,24 +100,24 @@
$(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>'); $(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>');
//btn_delete //btn_delete
$('.btn_delete_semua').on('click', function() { $('.btn_delete_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
type: 'DELETE', type: 'DELETE',
url: "<?= route('payroll.data.komponen.kehadiran.import.deleteall') ?>", url: "<?= route('payroll.data.komponen.kehadiran.import.deleteall') ?>",
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF")); $("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF"));
loading.stop(); loading.stop();
// Set a timeout to hide the element // Set a timeout to hide the element
setTimeout(function() { setTimeout(function () {
$("#modal_hapus").modal('hide'); $("#modal_hapus").modal('hide');
}, 1000); }, 1000);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -203,7 +203,7 @@ ...@@ -203,7 +203,7 @@
<button class="btn btn-danger btn-sm" title="Data Kosong"></button> <span>Data tidak lengkap</span> <button class="btn btn-danger btn-sm" title="Data Kosong"></button> <span>Data tidak lengkap</span>
</div> </div>
</div> </div>
<div class="row mt-2"> <div class="table-responsive mt-2">
<div id="listdata" class="col-md-12"> <div id="listdata" class="col-md-12">
</div> </div>
...@@ -241,4 +241,4 @@ ...@@ -241,4 +241,4 @@
</div> </div>
</div> </div>
</div> </div>
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
\ No newline at end of file
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
$numrow = 2; $numrow = 2;
} }
?> ?>
<th rowspan="<?= $numrow ?>" class="align-middle text-center" width="30">NO</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NO</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">NIK</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NIK</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th>
...@@ -38,6 +38,7 @@ ...@@ -38,6 +38,7 @@
echo '<th class="align-middle text-center">' . strtoupper($komponen['nm_komponen']) . (($komponen['flag_persentase_gapok'] == '1') ? ' (' . $komponen['gapok_persen'] . '%)' : '') . '</th>'; echo '<th class="align-middle text-center">' . strtoupper($komponen['nm_komponen']) . (($komponen['flag_persentase_gapok'] == '1') ? ' (' . $komponen['gapok_persen'] . '%)' : '') . '</th>';
} }
} }
echo '</tr>';
} }
?> ?>
</thead> </thead>
...@@ -46,9 +47,9 @@ ...@@ -46,9 +47,9 @@
</table> </table>
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -57,7 +58,7 @@ ...@@ -57,7 +58,7 @@
'delay': 1000, 'delay': 1000,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'stateSave': true, 'stateSave': true,
...@@ -77,22 +78,15 @@ ...@@ -77,22 +78,15 @@
"ajax": { "ajax": {
"url": "<?= route('payroll.data.komponen.kehadiran.import.listdata') ?>", "url": "<?= route('payroll.data.komponen.kehadiran.import.listdata') ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
// reconfigure(data); // reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": [1],
"bSortable": true
},
{
"aTargets": "_all",
"bSortable": false
},
{ {
"visible": false, "visible": false,
"targets": [1] "targets": [1]
...@@ -105,12 +99,11 @@ ...@@ -105,12 +99,11 @@
"className": "text-left", "className": "text-left",
"targets": [1, 2, 3, 4, 5] "targets": [1, 2, 3, 4, 5]
}, },
{
"className": "text-right",
"targets": "_all"
},
], ],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('text-right');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
for (let index = 1; index < aData.length; index++) { for (let index = 1; index < aData.length; index++) {
const col = aData[index]; const col = aData[index];
...@@ -130,4 +123,4 @@ ...@@ -130,4 +123,4 @@
}, },
}); });
}); });
</script> </script>
\ No newline at end of file
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
list_data_temp(); list_data_temp();
$(document).on('click', '#btn_form_template', function() { $(document).on('click', '#btn_form_template', function () {
$('#tampil_form').load("<?= route('payroll.data.komponen.tdk.tetap.import.form.templateimport') ?>", function() { $('#tampil_form').load("<?= route('payroll.data.komponen.tdk.tetap.import.form.templateimport') ?>", function () {
$('#modal_form').modal('show'); $('#modal_form').modal('show');
$(".title").text("Download Template Data Komponen"); $(".title").text("Download Template Data Komponen");
$(".btn_unduh").addClass("btn_unduh btn btn-success"); $(".btn_unduh").addClass("btn_unduh btn btn-success");
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
}); });
}); });
$(document).on('click', '#btn_import', function() { $(document).on('click', '#btn_import', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
$('.form_import #message').html(""); $('.form_import #message').html("");
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
contentType: false, contentType: false,
processData: false, processData: false,
dataType: "json", dataType: "json",
success: function(result) { success: function (result) {
if (result.success == true) { if (result.success == true) {
// list_data_temp(); // list_data_temp();
} }
...@@ -43,7 +43,7 @@ ...@@ -43,7 +43,7 @@
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html(result.message); $('.form_import #message').html(result.message);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>'); $('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>');
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
}); });
// # SIMPAN SEMUA DATA TEMPORARY // # SIMPAN SEMUA DATA TEMPORARY
$(document).on('click', '.btn_simpan_semua', function() { $(document).on('click', '.btn_simpan_semua', function () {
var id = $(this).attr('id'); var id = $(this).attr('id');
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("Apakah anda ingin menyimpan semua data ini?"); $(".title").text("Apakah anda ingin menyimpan semua data ini?");
...@@ -63,7 +63,7 @@ ...@@ -63,7 +63,7 @@
$(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>'); $(".tombol").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>');
//btn_delete //btn_delete
$('.btn_save_semua').on('click', function() { $('.btn_save_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
...@@ -71,16 +71,16 @@ ...@@ -71,16 +71,16 @@
url: "<?= route('payroll.data.komponen.tdk.tetap.import.publishall') ?>", url: "<?= route('payroll.data.komponen.tdk.tetap.import.publishall') ?>",
data: 'id=' + id, data: 'id=' + id,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF")); $("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF"));
loading.stop(); loading.stop();
setTimeout(function() { setTimeout(function () {
$("#modal_hapus").modal('hide'); $("#modal_hapus").modal('hide');
}, 1000); }, 1000);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -90,7 +90,7 @@ ...@@ -90,7 +90,7 @@
}); });
}); });
$(document).on('click', '.btn_hapus_semua', function() { $(document).on('click', '.btn_hapus_semua', function () {
$('#modal_hapus').modal('show'); $('#modal_hapus').modal('show');
$(".title").text("Apakah anda ingin menghapus semua data ini?"); $(".title").text("Apakah anda ingin menghapus semua data ini?");
$("#modal_hapus .card-body").show(); $("#modal_hapus .card-body").show();
...@@ -99,23 +99,23 @@ ...@@ -99,23 +99,23 @@
$(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>'); $(".tombol").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>');
//btn_delete //btn_delete
$('.btn_delete_semua').on('click', function() { $('.btn_delete_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
type: 'DELETE', type: 'DELETE',
url: "<?= route('payroll.data.komponen.tdk.tetap.import.deleteall') ?>", url: "<?= route('payroll.data.komponen.tdk.tetap.import.deleteall') ?>",
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
$("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF")); $("#modal_hapus .title").html(result.message.replace("#009900", "FFFFFF"));
loading.stop(); loading.stop();
setTimeout(function() { setTimeout(function () {
$("#modal_hapus").modal('hide'); $("#modal_hapus").modal('hide');
}, 1000); }, 1000);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$("#modal_hapus .card-body").hide(); $("#modal_hapus .card-body").hide();
$("#modal_hapus .card-footer").hide(); $("#modal_hapus .card-footer").hide();
...@@ -201,7 +201,7 @@ ...@@ -201,7 +201,7 @@
<button class="btn btn-danger btn-sm" title="Data Kosong"></button> <span>Data tidak lengkap</span> <button class="btn btn-danger btn-sm" title="Data Kosong"></button> <span>Data tidak lengkap</span>
</div> </div>
</div> </div>
<div class="row mt-2"> <div class="table-responsive mt-2">
<div id="listdata" class="col-md-12"> <div id="listdata" class="col-md-12">
</div> </div>
</div> </div>
...@@ -238,4 +238,4 @@ ...@@ -238,4 +238,4 @@
</div> </div>
</div> </div>
</div> </div>
<!-- END TAMPIL MODAL --> <!-- END TAMPIL MODAL -->
\ No newline at end of file
...@@ -54,10 +54,10 @@ ...@@ -54,10 +54,10 @@
</table> </table>
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
var paramBulan = "<?= $bulan ?>"; var paramBulan = "<?= $bulan ?>";
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
// if(confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')){ // if(confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')){
// window.location.reload(); // window.location.reload();
// } // }
...@@ -65,7 +65,7 @@ ...@@ -65,7 +65,7 @@
'searching': true, 'searching': true,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'scrollCollapse': true, 'scrollCollapse': true,
...@@ -84,22 +84,15 @@ ...@@ -84,22 +84,15 @@
"ajax": { "ajax": {
"url": "<?= route('payroll.data.komponen.tdk.tetap.import.listdata', ['bulan' => '"+paramBulan+"']) ?>", "url": "<?= route('payroll.data.komponen.tdk.tetap.import.listdata', ['bulan' => '"+paramBulan+"']) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": [1],
"bSortable": true
},
{
"aTargets": "_all",
"bSortable": false
},
{ {
"visible": false, "visible": false,
"targets": [1] "targets": [1]
...@@ -112,12 +105,11 @@ ...@@ -112,12 +105,11 @@
"className": "text-left", "className": "text-left",
"targets": [1, 2, 3, 4, 5, 6] "targets": [1, 2, 3, 4, 5, 6]
}, },
{
"className": "text-right",
"targets": "_all"
},
], ],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('text-right');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
for (let index = 1; index < aData.length; index++) { for (let index = 1; index < aData.length; index++) {
const col = aData[index]; const col = aData[index];
...@@ -137,4 +129,4 @@ ...@@ -137,4 +129,4 @@
}, },
}); });
}); });
</script> </script>
\ No newline at end of file
<!-- BAGIN DATATABLE --> <!-- BAGIN DATATABLE -->
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function () {
var bulan = ($("#filter #bulan").val()) ? $("#filter #bulan").val() : ''; var bulan = ($("#filter #bulan").val()) ? $("#filter #bulan").val() : '';
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
'searchDelay': 1000, 'searchDelay': 1000,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'fixedColumns': { 'fixedColumns': {
...@@ -32,18 +32,15 @@ ...@@ -32,18 +32,15 @@
"ajax": { "ajax": {
"url": "<?= route('payroll.data.komponen.tdk.tetap.datatable', ['bulan' => '"+bulan+"', 'id_karyawan' => $id_karyawan, 'id_cabang' => $id_cabang, 'id_departemen' => $id_departemen]) ?>", "url": "<?= route('payroll.data.komponen.tdk.tetap.datatable', ['bulan' => '"+bulan+"', 'id_karyawan' => $id_karyawan, 'id_cabang' => $id_cabang, 'id_departemen' => $id_departemen]) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": "_all",
"bSortable": false
},
{ {
"className": "text-center", "className": "text-center",
"targets": [0] "targets": [0]
...@@ -52,11 +49,10 @@ ...@@ -52,11 +49,10 @@
"className": "text-left", "className": "text-left",
"targets": [1, 2, 3, 4] "targets": [1, 2, 3, 4]
}, },
{ ],
"className": "text-right", "fnCreatedRow": function (row, data, dataIndex) {
"targets": "_all" $(row).addClass('text-right');
}, },
]
}); });
}); });
</script> </script>
...@@ -71,7 +67,7 @@ ...@@ -71,7 +67,7 @@
$numrow = 2; $numrow = 2;
} }
?> ?>
<th rowspan="<?= $numrow ?>" class="align-middle text-center" width="30">NO</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NO</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">NAMA KARYAWAN</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">CABANG</th>
<th rowspan="<?= $numrow ?>" class="align-middle text-center">DEPARTEMEN</th> <th rowspan="<?= $numrow ?>" class="align-middle text-center">DEPARTEMEN</th>
...@@ -106,4 +102,4 @@ ...@@ -106,4 +102,4 @@
</thead> </thead>
<tbody> <tbody>
</tbody> </tbody>
</table> </table>
\ No newline at end of file
<!-- BAGIN DATATABLE --> <!-- BAGIN DATATABLE -->
<script type="text/javascript"> <script type="text/javascript">
$(document).ready(function() { $(document).ready(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
'delay': 1000, 'delay': 1000,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'stateSave': true, 'stateSave': true,
...@@ -33,19 +33,16 @@ ...@@ -33,19 +33,16 @@
"ajax": { "ajax": {
"url": "<?= route('payroll.gaji.datatable', ['bulan' => $periode, 'id_cabang' => $cabang, 'id_departemen' => $departemen, 'id_karyawan' => $karyawan]) ?>", "url": "<?= route('payroll.gaji.datatable', ['bulan' => $periode, 'id_cabang' => $cabang, 'id_departemen' => $departemen, 'id_karyawan' => $karyawan]) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
$(".btn_download_excel").attr("bulande", $("#filter #bulan").val()); $(".btn_download_excel").attr("bulande", $("#filter #bulan").val());
// reconfigure(data); // reconfigure(data);
}, },
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": "_all",
"bSortable": false,
},
{ {
"targets": [1, 3, 4], "targets": [1, 3, 4],
"className": "align-top text-left" "className": "align-top text-left"
...@@ -54,12 +51,11 @@ ...@@ -54,12 +51,11 @@
"targets": [0, 2, 5, -1, -2, -3, -4], "targets": [0, 2, 5, -1, -2, -3, -4],
"className": "align-top text-center" "className": "align-top text-center"
}, },
{
"targets": "_all",
"className": "align-top text-right"
}
], ],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('align-top text-right');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td', nRow).css({ $('td', nRow).css({
'white-space': 'nowrap' 'white-space': 'nowrap'
}); });
...@@ -71,7 +67,7 @@ ...@@ -71,7 +67,7 @@
<table id="list_data" class="table table-striped table-bordered" style="width:100%"> <table id="list_data" class="table table-striped table-bordered" style="width:100%">
<thead> <thead>
<tr class="bg-tr"> <tr class="bg-tr">
<th rowspan="3" class="align-middle text-center" width="100">NO</th> <th rowspan="3" class="align-middle text-center">NO</th>
<th rowspan="3" class="align-middle text-center">NAMA KARYAWAN</th> <th rowspan="3" class="align-middle text-center">NAMA KARYAWAN</th>
<th rowspan="3" class="align-middle text-center">BULAN</th> <th rowspan="3" class="align-middle text-center">BULAN</th>
<th rowspan="3" class="align-middle text-center">CABANG</th> <th rowspan="3" class="align-middle text-center">CABANG</th>
...@@ -109,7 +105,7 @@ ...@@ -109,7 +105,7 @@
<th rowspan="3" class="align-middle text-center">THP</th> <th rowspan="3" class="align-middle text-center">THP</th>
<th colspan="3" class="align-middle text-center">TUNJ. DIBIAYAI PERUSAHAAN</th> <th colspan="3" class="align-middle text-center">TUNJ. DIBIAYAI PERUSAHAAN</th>
<th colspan="3" class="align-middle text-center">PUBLISH</th> <th colspan="3" class="align-middle text-center">PUBLISH</th>
<th rowspan="3" class="align-middle text-center" width="150px">AKSI</th> <th rowspan="3" class="align-middle text-center">AKSI</th>
</tr> </tr>
<tr class="bg-tr"> <tr class="bg-tr">
<!-- PENGHASILAN --> <!-- PENGHASILAN -->
...@@ -184,4 +180,4 @@ ...@@ -184,4 +180,4 @@
</thead> </thead>
<tbody> <tbody>
</tbody> </tbody>
</table> </table>
\ No newline at end of file
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
'searchDelay': 1000, 'searchDelay': 1000,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'stateSave': true, 'stateSave': true,
...@@ -37,19 +37,15 @@ ...@@ -37,19 +37,15 @@
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": "_all", {
"bSortable": false "className": "text-left",
}, "targets": [2]
{ },
"className": "text-left", ],
"targets": [2] "fnCreatedRow": function (row, data, dataIndex) {
}, $(row).addClass('text-center');
{
"className": "text-center",
"targets": "_all"
}, },
]
}); });
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
'searchDelay': 1000, 'searchDelay': 1000,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'stateSave': true, 'stateSave': true,
...@@ -37,19 +37,15 @@ ...@@ -37,19 +37,15 @@
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": "_all", {
"bSortable": false "className": "text-left",
}, "targets": [2, 3]
{ },
"className": "text-left", ],
"targets": [2, 3] "fnCreatedRow": function (row, data, dataIndex) {
}, $(row).addClass('text-center');
{
"className": "text-center",
"targets": "_all"
}, },
]
}); });
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
'searchDelay': 1000, 'searchDelay': 1000,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'stateSave': true, 'stateSave': true,
...@@ -37,19 +37,15 @@ ...@@ -37,19 +37,15 @@
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": "_all", {
"bSortable": false "className": "text-left",
}, "targets": [2, 3]
{ },
"className": "text-left", ],
"targets": [2, 3] "fnCreatedRow": function (row, data, dataIndex) {
}, $(row).addClass('text-center');
{
"className": "text-center",
"targets": "_all"
}, },
]
}); });
......
<script> <script>
$(function() { $(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -25,26 +25,25 @@ ...@@ -25,26 +25,25 @@
"ajax": { "ajax": {
"url": "<?= route("payroll.master.lembur.karyawan.import.data") ?>", "url": "<?= route("payroll.master.lembur.karyawan.import.data") ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
$('[data-toggle="tooltip"]').tooltip(); $('[data-toggle="tooltip"]').tooltip();
} }
}, },
"initComplete": function() { "initComplete": function () {
$("#excel").show(); $("#excel").show();
}, },
"aoColumnDefs": [{ "aoColumnDefs": [{
"className": "text-left", "className": "text-left",
"aTargets": [1, 2] "aTargets": [1, 2]
}, {
"className": "text-center",
"targets": "_all"
}], }],
"fnCreatedRow": function (row, data, dataIndex) {
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { $(row).addClass('text-center');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
let nik = $("td:eq(1) span", nRow); let nik = $("td:eq(1) span", nRow);
if (nik.text().substr(0, 1) == "#") { if (nik.text().substr(0, 1) == "#") {
nik.html(nik.text().substr(1)); nik.html(nik.text().substr(1));
...@@ -64,8 +63,8 @@ ...@@ -64,8 +63,8 @@
} }
}); });
$('#btn_form_template').on('click', function() { $('#btn_form_template').on('click', function () {
$('#tampil_form').load("<?= route('payroll.master.lembur.karyawan.import.template') ?>", function() { $('#tampil_form').load("<?= route('payroll.master.lembur.karyawan.import.template') ?>", function () {
$('#modal_form').modal('show'); $('#modal_form').modal('show');
$(".title").text("Unduh Template Master Lembur Karyawan"); $(".title").text("Unduh Template Master Lembur Karyawan");
$("#btn_submit").addClass("btn btn-success"); $("#btn_submit").addClass("btn btn-success");
...@@ -73,7 +72,7 @@ ...@@ -73,7 +72,7 @@
}); });
}); });
$('#btn_import').on('click', function() { $('#btn_import').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
$('.form_import #message').html(""); $('.form_import #message').html("");
...@@ -95,13 +94,13 @@ ...@@ -95,13 +94,13 @@
contentType: false, contentType: false,
processData: false, processData: false,
dataType: "json", dataType: "json",
success: function(result) { success: function (result) {
loading.stop(); loading.stop();
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html(result.message); $('.form_import #message').html(result.message);
list_data.ajax.reload(); list_data.ajax.reload();
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('.form_import #message').show(); $('.form_import #message').show();
$('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>'); $('.form_import #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong>Gagal : Terjadi Kesalahan</strong></font>');
...@@ -110,7 +109,7 @@ ...@@ -110,7 +109,7 @@
}); });
$('#hapus_all').on('click', function() { $('#hapus_all').on('click', function () {
$('#modal_form').modal('show'); $('#modal_form').modal('show');
$(".title").text("Apakah anda ingin menghapus semua data ini?"); $(".title").text("Apakah anda ingin menghapus semua data ini?");
$("#modal_form .card-body").hide(); $("#modal_form .card-body").hide();
...@@ -119,14 +118,14 @@ ...@@ -119,14 +118,14 @@
$("#modal_form .action").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>'); $("#modal_form .action").append('<button class="btn_delete_semua btn btn-danger ladda-button" data-style="expand-left"><i class="fa fa-trash"></i> HAPUS</button>');
//btn_delete //btn_delete
$('.btn_delete_semua').on('click', function() { $('.btn_delete_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
type: 'DELETE', type: 'DELETE',
url: "<?= route('payroll.master.lembur.karyawan.import.delete') ?>", url: "<?= route('payroll.master.lembur.karyawan.import.delete') ?>",
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
loading.stop(); loading.stop();
if (result.success == true) { if (result.success == true) {
showMsg(result.message); showMsg(result.message);
...@@ -135,7 +134,7 @@ ...@@ -135,7 +134,7 @@
showMsg(result.message.replace("#eb3a28", "#FFFFFF"), false); showMsg(result.message.replace("#eb3a28", "#FFFFFF"), false);
} }
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
showMsg('error', false); showMsg('error', false);
} }
...@@ -143,7 +142,7 @@ ...@@ -143,7 +142,7 @@
}); });
}); });
$('#simpan_all').on('click', function() { $('#simpan_all').on('click', function () {
$("#modal_form").modal("show"); $("#modal_form").modal("show");
$(".title").text("Apakah anda ingin menyimpan semua data ini?"); $(".title").text("Apakah anda ingin menyimpan semua data ini?");
$("#modal_form .card-body").hide(); $("#modal_form .card-body").hide();
...@@ -152,14 +151,14 @@ ...@@ -152,14 +151,14 @@
$("#modal_form .action").empty(); $("#modal_form .action").empty();
$("#modal_form .action").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>'); $("#modal_form .action").append('<button class="btn_save_semua btn btn-success ladda-button" data-style="expand-left"><i class="fa fa-save"></i> SIMPAN</button>');
$('.btn_save_semua').on('click', function() { $('.btn_save_semua').on('click', function () {
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
$.ajax({ $.ajax({
type: 'POST', type: 'POST',
url: "<?= route('payroll.master.lembur.karyawan.import.publish') ?>", url: "<?= route('payroll.master.lembur.karyawan.import.publish') ?>",
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
loading.stop(); loading.stop();
if (result.success == true) { if (result.success == true) {
showMsg(result.message); showMsg(result.message);
...@@ -168,7 +167,7 @@ ...@@ -168,7 +167,7 @@
showMsg(result.message.replace("#eb3a28", "#FFFFFF"), false); showMsg(result.message.replace("#eb3a28", "#FFFFFF"), false);
} }
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
showMsg('error', false); showMsg('error', false);
} }
...@@ -263,4 +262,4 @@ ...@@ -263,4 +262,4 @@
</div> </div>
</div> </div>
</div> </div>
</div> </div>
\ No newline at end of file
<script> <script>
if (location.href == "<?= route('payroll.master.lembur.karyawan') ?>") window.location.replace("<?= route('payroll.master.lembur.home') ?>"); if (location.href == "<?= route('payroll.master.lembur.karyawan') ?>") window.location.replace("<?= route('payroll.master.lembur.home') ?>");
$(function() { $(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -26,32 +26,33 @@ ...@@ -26,32 +26,33 @@
"ajax": { "ajax": {
"url": "<?= route("payroll.master.lembur.data", ["tab" => "lembur_karyawan", "params" => "1.1.1.1.all.all.all"]) ?>", "url": "<?= route("payroll.master.lembur.data", ["tab" => "lembur_karyawan", "params" => "1.1.1.1.all.all.all"]) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
$('[data-toggle="tooltip"]').tooltip(); $('[data-toggle="tooltip"]').tooltip();
} }
}, },
"initComplete": function() { "initComplete": function () {
$("#excel").show(); $("#excel").show();
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"className": "text-left", {
"aTargets": [1, 2] "className": "text-left",
}, { "aTargets": [1, 2]
"className": "text-center", }
"targets": "_all" ],
}], "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('text-center');
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { },
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$("td:eq(3), td:eq(4), td:eq(5), td:eq(6)", nRow).css("width", "150px"); $("td:eq(3), td:eq(4), td:eq(5), td:eq(6)", nRow).css("width", "150px");
$("td:eq(-1)", nRow).css("width", "20px"); $("td:eq(-1)", nRow).css("width", "20px");
} }
}); });
$(document).on('click', '#lembur_karyawan .btn_edit', function() { $(document).on('click', '#lembur_karyawan .btn_edit', function () {
var row = this.closest('tr'); var row = this.closest('tr');
for (let index = 3; index < 7; index++) { for (let index = 3; index < 7; index++) {
row.children[index].querySelector('select').className = "form-control"; row.children[index].querySelector('select').className = "form-control";
...@@ -61,7 +62,7 @@ ...@@ -61,7 +62,7 @@
this.closest('td').querySelector('#edit').className = "hidden"; this.closest('td').querySelector('#edit').className = "hidden";
}); });
$(document).on('click', '#lembur_karyawan .btn_save', function(e) { $(document).on('click', '#lembur_karyawan .btn_save', function (e) {
e.preventDefault(); e.preventDefault();
const row = this.closest('tr'); const row = this.closest('tr');
...@@ -80,10 +81,10 @@ ...@@ -80,10 +81,10 @@
url: "<?= route('payroll.master.lembur.karyawan.save') ?>", url: "<?= route('payroll.master.lembur.karyawan.save') ?>",
data: params, data: params,
dataType: 'JSON', dataType: 'JSON',
beforeSend: function() { beforeSend: function () {
loading_start(row, selects); loading_start(row, selects);
}, },
success: function(result) { success: function (result) {
loading_stop(row, selects); loading_stop(row, selects);
if (result.success == true) { if (result.success == true) {
list_data.ajax.reload(); list_data.ajax.reload();
...@@ -91,14 +92,14 @@ ...@@ -91,14 +92,14 @@
showMsg(result.message, false); showMsg(result.message, false);
} }
}, },
error: function() { error: function () {
loading_stop(row, selects); loading_stop(row, selects);
showMsg('error', false); showMsg('error', false);
} }
}); });
}); });
$(document).on('click', '#lembur_karyawan .btn_batal', function() { $(document).on('click', '#lembur_karyawan .btn_batal', function () {
var row = this.closest('tr'); var row = this.closest('tr');
for (let index = 3; index < 7; index++) { for (let index = 3; index < 7; index++) {
let selectElement = row.children[index].querySelector('select'); let selectElement = row.children[index].querySelector('select');
...@@ -110,17 +111,17 @@ ...@@ -110,17 +111,17 @@
this.closest('td').querySelector('#edit').className = ""; this.closest('td').querySelector('#edit').className = "";
}); });
$(document).on('click', '#lembur_karyawan .btn_delete', function() { $(document).on('click', '#lembur_karyawan .btn_delete', function () {
const id = $(this).attr('id'); const id = $(this).attr('id');
$("#modal_form .modal-dialog").removeClass("modal-lg"); $("#modal_form .modal-dialog").removeClass("modal-lg");
$("#modal_form .modal-dialog").addClass("modal-md"); $("#modal_form .modal-dialog").addClass("modal-md");
$("#tampil_form").load("<?= route('payroll.master.lembur.karyawan.form.delete', ['id' => '"+id+"']) ?>", function() { $("#tampil_form").load("<?= route('payroll.master.lembur.karyawan.form.delete', ['id' => '"+id+"']) ?>", function () {
$("#modal_form").modal("show"); $("#modal_form").modal("show");
$(".title").text("Hapus Data Master Lembur Karyawan"); $(".title").text("Hapus Data Master Lembur Karyawan");
$("#btn_submit").html("<i class='fa fa-trash (alias)'></i> HAPUS"); $("#btn_submit").html("<i class='fa fa-trash (alias)'></i> HAPUS");
$("#btn_submit").addClass("btn_destroy btn btn-danger"); $("#btn_submit").addClass("btn_destroy btn btn-danger");
$('.btn_destroy').on('click', function(e) { $('.btn_destroy').on('click', function (e) {
e.preventDefault(); e.preventDefault();
var loading = Ladda.create(this); var loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -133,7 +134,7 @@ ...@@ -133,7 +134,7 @@
url: "<?= route('payroll.master.lembur.karyawan.delete') ?>", url: "<?= route('payroll.master.lembur.karyawan.delete') ?>",
data: param, data: param,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
loading.stop(); loading.stop();
if (result.success == true) { if (result.success == true) {
showMsg(result.message); showMsg(result.message);
...@@ -142,7 +143,7 @@ ...@@ -142,7 +143,7 @@
showMsg(result.message, false); showMsg(result.message, false);
} }
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
showMsg('error', false); showMsg('error', false);
} }
...@@ -160,7 +161,7 @@ ...@@ -160,7 +161,7 @@
url: '<?= route("dropdown.karyawan.encrypt") ?>', url: '<?= route("dropdown.karyawan.encrypt") ?>',
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -177,7 +178,7 @@ ...@@ -177,7 +178,7 @@
url: '<?= route("dropdown.cabang") ?>', url: '<?= route("dropdown.cabang") ?>',
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -187,7 +188,7 @@ ...@@ -187,7 +188,7 @@
minLength: 3 minLength: 3
}); });
$('#filter #btn_cari').click(function() { $('#filter #btn_cari').click(function () {
let loading = Ladda.create(this); let loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -196,12 +197,12 @@ ...@@ -196,12 +197,12 @@
$("#excel").attr("data-params", params); $("#excel").attr("data-params", params);
list_data.ajax.url("<?= route('payroll.master.lembur.data', ['tab' => 'lembur_karyawan', 'params' => '"+params+"']) ?>").load(function() { list_data.ajax.url("<?= route('payroll.master.lembur.data', ['tab' => 'lembur_karyawan', 'params' => '"+params+"']) ?>").load(function () {
loading.stop(); loading.stop();
}); });
}); });
$('#filter #btn_filter').click(function() { $('#filter #btn_filter').click(function () {
let loading = Ladda.create(this); let loading = Ladda.create(this);
loading.start(); loading.start();
...@@ -215,12 +216,12 @@ ...@@ -215,12 +216,12 @@
$("#excel").attr("data-params", params); $("#excel").attr("data-params", params);
list_data.ajax.url("<?= route('payroll.master.lembur.data', ['tab' => 'lembur_karyawan', 'params' => '"+params+"']) ?>").load(function() { list_data.ajax.url("<?= route('payroll.master.lembur.data', ['tab' => 'lembur_karyawan', 'params' => '"+params+"']) ?>").load(function () {
loading.stop(); loading.stop();
}); });
}); });
$("#excel").click(function() { $("#excel").click(function () {
const params = $(this).data("params"); const params = $(this).data("params");
const urlExcel = "<?= route('payroll.master.lembur.karyawan.download', ['params' => '"+params+"']) ?>"; const urlExcel = "<?= route('payroll.master.lembur.karyawan.download', ['params' => '"+params+"']) ?>";
downloadFile(urlExcel, this); downloadFile(urlExcel, this);
...@@ -241,7 +242,7 @@ ...@@ -241,7 +242,7 @@
url: '<?= route("dropdown.departemen.by.cabang", ["cabang" => "'+id_cabang+'"]) ?>', url: '<?= route("dropdown.departemen.by.cabang", ["cabang" => "'+id_cabang+'"]) ?>',
dataType: 'json', dataType: 'json',
delay: 250, delay: 250,
processResults: function(data) { processResults: function (data) {
return { return {
results: data results: data
}; };
...@@ -384,4 +385,4 @@ ...@@ -384,4 +385,4 @@
<tbody id="lembur_karyawan"> <tbody id="lembur_karyawan">
</tbody> </tbody>
</table> </table>
</div> </div>
\ No newline at end of file
<script> <script>
if (location.href == "<?= route('payroll.master.lembur.pengaturan') ?>") window.location.replace("<?= route('payroll.master.lembur.home') ?>"); if (location.href == "<?= route('payroll.master.lembur.pengaturan') ?>") window.location.replace("<?= route('payroll.master.lembur.home') ?>");
$(function() { $(function () {
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) { if (confirm('Terjadi kesalahan saat memproses data, muat ulang halaman ?')) {
window.location.reload(); window.location.reload();
} }
...@@ -27,10 +27,10 @@ ...@@ -27,10 +27,10 @@
"ajax": { "ajax": {
"url": "<?= route("payroll.master.lembur.data", ["tab" => "pengaturan"]) ?>", "url": "<?= route("payroll.master.lembur.data", ["tab" => "pengaturan"]) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
...@@ -38,11 +38,11 @@ ...@@ -38,11 +38,11 @@
"aoColumnDefs": [{ "aoColumnDefs": [{
"className": "text-left", "className": "text-left",
"aTargets": [2] "aTargets": [2]
}, {
"className": "text-center",
"targets": "_all"
}], }],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnCreatedRow": function (row, data, dataIndex) {
$(row).addClass('text-center');
},
"fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td:eq(3), td:eq(4)', nRow).css({ $('td:eq(3), td:eq(4)', nRow).css({
'text-align': 'center', 'text-align': 'center',
'width': '100px' 'width': '100px'
...@@ -50,8 +50,8 @@ ...@@ -50,8 +50,8 @@
} }
}); });
$("#tambah_data").on("click", function() { $("#tambah_data").on("click", function () {
$("#tampil_form").load("<?= route("payroll.master.lembur.pengaturan.form", ['for' => 'tambah']) ?>", function() { $("#tampil_form").load("<?= route("payroll.master.lembur.pengaturan.form", ['for' => 'tambah']) ?>", function () {
$("#modal_form .modal-dialog").removeClass("modal-md"); $("#modal_form .modal-dialog").removeClass("modal-md");
$("#modal_form .modal-dialog").addClass("modal-lg"); $("#modal_form .modal-dialog").addClass("modal-lg");
$("#modal_form").modal("show"); $("#modal_form").modal("show");
...@@ -62,9 +62,9 @@ ...@@ -62,9 +62,9 @@
}); });
}); });
$(document).on('click', '#pengaturan .btn_edit', function() { $(document).on('click', '#pengaturan .btn_edit', function () {
var id = $(this).attr("id"); var id = $(this).attr("id");
$("#tampil_form").load("<?= route('payroll.master.lembur.pengaturan.form', ['for' => 'edit', 'id' => '"+id+"']) ?>", function() { $("#tampil_form").load("<?= route('payroll.master.lembur.pengaturan.form', ['for' => 'edit', 'id' => '"+id+"']) ?>", function () {
$("#modal_form .modal-dialog").removeClass("modal-md"); $("#modal_form .modal-dialog").removeClass("modal-md");
$("#modal_form .modal-dialog").addClass("modal-lg"); $("#modal_form .modal-dialog").addClass("modal-lg");
$("#modal_form").modal("show"); $("#modal_form").modal("show");
...@@ -75,9 +75,9 @@ ...@@ -75,9 +75,9 @@
}); });
}); });
$(document).on('click', '#pengaturan .btn_delete', function() { $(document).on('click', '#pengaturan .btn_delete', function () {
var id = $(this).attr("id"); var id = $(this).attr("id");
$("#tampil_form").load("<?= route('payroll.master.lembur.pengaturan.form', ['for' => 'delete', 'id' => '"+id+"']) ?>", function() { $("#tampil_form").load("<?= route('payroll.master.lembur.pengaturan.form', ['for' => 'delete', 'id' => '"+id+"']) ?>", function () {
$("#modal_form .modal-dialog").removeClass("modal-lg"); $("#modal_form .modal-dialog").removeClass("modal-lg");
$("#modal_form .modal-dialog").addClass("modal-md"); $("#modal_form .modal-dialog").addClass("modal-md");
$("#modal_form").modal("show"); $("#modal_form").modal("show");
...@@ -119,4 +119,4 @@ ...@@ -119,4 +119,4 @@
<tbody id="pengaturan"> <tbody id="pengaturan">
</tbody> </tbody>
</table> </table>
</div> </div>
\ No newline at end of file
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
</tr> </tr>
<?php <?php
if ($ttl_periode > 0) { if ($ttl_periode > 0) {
?> ?>
<tr class="bg-tr"> <tr class="bg-tr">
<?php <?php
$border_left = false; $border_left = false;
...@@ -28,20 +28,20 @@ ...@@ -28,20 +28,20 @@
if ($row['libur'] == true) { if ($row['libur'] == true) {
if ($border_left == false) { if ($border_left == false) {
$border_left_style = $this->config->item('border_left_libur'); $border_left_style = $this->config->item('border_left_libur');
$border_left = true; $border_left = true;
} else { } else {
$border_left_style = ''; $border_left_style = '';
} }
?> ?>
<th style="background-color: <?= $row['warna'] ?>; color: <?= $row['warna_teks'] ?>; border-color: <?= $row['warna_teks'] ?>; <?= $border_left_style ?>"><?= $row['hari'] . '<br>' . $row['tanggal']; ?></th> <th style="background-color: <?= $row['warna'] ?>; color: <?= $row['warna_teks'] ?>; border-color: <?= $row['warna_teks'] ?>; <?= $border_left_style ?>"><?= $row['hari'] . '<br>' . $row['tanggal']; ?></th>
<?php } else { <?php } else {
$border_left = false; ?> $border_left = false; ?>
<th><?= $row['hari'] . '<br>' . $row['tanggal']; ?></th> <th><?= $row['hari'] . '<br>' . $row['tanggal']; ?></th>
<?php } <?php }
} }
?> ?>
</tr> </tr>
<?php <?php
} }
?> ?>
</thead> </thead>
...@@ -50,12 +50,12 @@ ...@@ -50,12 +50,12 @@
</table> </table>
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
list_data = $('#list_data').DataTable({ list_data = $('#list_data').DataTable({
'searching': true, 'searching': true,
'paging': true, 'paging': true,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': true, 'info': true,
'scrollX': true, 'scrollX': true,
'scrollCollapse': true, 'scrollCollapse': true,
...@@ -73,36 +73,29 @@ ...@@ -73,36 +73,29 @@
"ajax": { "ajax": {
"url": "<?= route('pengaturan.shift.import.listdata') ?>", "url": "<?= route('pengaturan.shift.import.listdata') ?>",
"type": "POST", "type": "POST",
data: function(d) { data: function (d) {
d.id_cabang = "<?= $id_cabang ?>"; d.id_cabang = "<?= $id_cabang ?>";
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [
"aTargets": [0],
"bSortable": false
},
{ {
"aTargets": [1], "aTargets": [1],
"bSortable": true "bSortable": true
}, },
{ {
"aTargets": "_all", "targets": [<?= $targets_libur_sisa ?>],
"bSortable": false "className": "dt-libur"
},
{
targets: [<?= $targets_libur_sisa ?>],
className: "dt-libur"
}, },
{ {
targets: [<?= $targets_libur_left ?>], "targets": [<?= $targets_libur_left ?>],
className: "dt-libur-left" "className": "dt-libur-left"
} }
], ],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
$('td:eq(0)', nRow).css({ $('td:eq(0)', nRow).css({
'text-align': 'center' 'text-align': 'center'
...@@ -117,4 +110,4 @@ ...@@ -117,4 +110,4 @@
}, },
}); });
}); });
</script> </script>
\ No newline at end of file
<script type="text/javascript"> <script type="text/javascript">
$(function() { $(function () {
$('#filter_tahun').datepicker({ $('#filter_tahun').datepicker({
format: "yyyy", format: "yyyy",
...@@ -12,13 +12,13 @@ ...@@ -12,13 +12,13 @@
// Set nilai default tahun ke tahun saat ini // Set nilai default tahun ke tahun saat ini
$('#filter_tahun').val(new Date().getFullYear()); $('#filter_tahun').val(new Date().getFullYear());
$('#btn_filter_tahun').on('click', function() { $('#btn_filter_tahun').on('click', function () {
list_data.ajax.reload(); // Reload DataTables pertama list_data.ajax.reload(); // Reload DataTables pertama
list_data2.ajax.reload(); // Reload DataTables kedua list_data2.ajax.reload(); // Reload DataTables kedua
}); });
$.fn.dataTableExt.sErrMode = 'none'; $.fn.dataTableExt.sErrMode = 'none';
list_data = $('#list_data').on('error.dt', function(e, settings, techNote, message) { list_data = $('#list_data').on('error.dt', function (e, settings, techNote, message) {
if (confirm('<?= $this->lang->line('error_datatable') ?>')) { if (confirm('<?= $this->lang->line('error_datatable') ?>')) {
window.location.reload(); window.location.reload();
} }
...@@ -36,18 +36,19 @@ ...@@ -36,18 +36,19 @@
'url': '" . base_url("assets/plugins/datatables/dataTables-language-id.json") . "', 'url': '" . base_url("assets/plugins/datatables/dataTables-language-id.json") . "',
'sEmptyTable': 'Tidak ada data untuk ditampilkan' 'sEmptyTable': 'Tidak ada data untuk ditampilkan'
},"; },";
}; ?> "processing": true, }
; ?> "processing": true,
"serverSide": true, "serverSide": true,
"order": [], "order": [],
"ajax": { "ajax": {
"url": "<?= route('history.cuti.listdata', ['jenis' => 'tambah', 'id_karyawan' => $this->route->param('id_karyawan')]) ?>", "url": "<?= route('history.cuti.listdata', ['jenis' => 'tambah', 'id_karyawan' => $this->route->param('id_karyawan')]) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
d.tahun = $('#filter_tahun').val(); d.tahun = $('#filter_tahun').val();
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
...@@ -59,7 +60,7 @@ ...@@ -59,7 +60,7 @@
"targets": [0, 2], "targets": [0, 2],
"className": "text-center" "className": "text-center"
}], }],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
// //
$('td:eq(0)', nRow).css({ $('td:eq(0)', nRow).css({
'width': '100px' 'width': '100px'
...@@ -71,7 +72,7 @@ ...@@ -71,7 +72,7 @@
} }
}); });
list_data2 = $('#list_data2').on('error.dt', function(e, settings, techNote, message) { list_data2 = $('#list_data2').on('error.dt', function (e, settings, techNote, message) {
if (confirm('<?= $this->lang->line('error_datatable') ?>')) { if (confirm('<?= $this->lang->line('error_datatable') ?>')) {
window.location.reload(); window.location.reload();
} }
...@@ -79,7 +80,7 @@ ...@@ -79,7 +80,7 @@
'searching': false, 'searching': false,
'paging': false, 'paging': false,
'lengthChange': true, 'lengthChange': true,
'ordering': true, 'ordering': false,
'info': false, 'info': false,
'scrollX': false, 'scrollX': false,
"pageLength": 100, "pageLength": 100,
...@@ -89,30 +90,28 @@ ...@@ -89,30 +90,28 @@
'url': '" . base_url("assets/plugins/datatables/dataTables-language-id.json") . "', 'url': '" . base_url("assets/plugins/datatables/dataTables-language-id.json") . "',
'sEmptyTable': 'Tidak ada data untuk ditampilkan' 'sEmptyTable': 'Tidak ada data untuk ditampilkan'
},"; },";
}; ?> "processing": true, }
; ?> "processing": true,
"serverSide": true, "serverSide": true,
"order": [], "order": [],
"ajax": { "ajax": {
"url": "<?= route('history.cuti.listdata.terpakai', ['jenis' => 'kurang', 'id_karyawan' => $this->route->param('id_karyawan')]) ?>", "url": "<?= route('history.cuti.listdata.terpakai', ['jenis' => 'kurang', 'id_karyawan' => $this->route->param('id_karyawan')]) ?>",
"type": "GET", "type": "GET",
"data": function(d) { "data": function (d) {
delete d.columns; delete d.columns;
d.tahun = $('#filter_tahun').val(); d.tahun = $('#filter_tahun').val();
}, },
"complete": function(data) { "complete": function (data) {
reconfigure(data); reconfigure(data);
} }
}, },
"aoColumnDefs": [{ "aoColumnDefs": [{
"aTargets": "_all",
"bSortable": false
}, {
"targets": [0, 2], // Sesuaikan index kolom jika urutan berbeda "targets": [0, 2], // Sesuaikan index kolom jika urutan berbeda
"className": "text-center" "className": "text-center"
}], }],
"fnRowCallback": function(nRow, aData, iDisplayIndex, iDisplayIndexFull) { "fnRowCallback": function (nRow, aData, iDisplayIndex, iDisplayIndexFull) {
// //
$('td:eq(0)', nRow).css({ $('td:eq(0)', nRow).css({
'width': '100px' 'width': '100px'
...@@ -125,8 +124,8 @@ ...@@ -125,8 +124,8 @@
}); });
$(document).on("click", ".btn_tambah", function() { $(document).on("click", ".btn_tambah", function () {
$('#tampil_form').load("<?= route('history.cuti.form.tambah') ?>", function() { $('#tampil_form').load("<?= route('history.cuti.form.tambah') ?>", function () {
$('#modal_form').modal('show'); $('#modal_form').modal('show');
$("#modal_form .title").text("<?= $this->lang->line('title_form_tambah_data') ?>"); $("#modal_form .title").text("<?= $this->lang->line('title_form_tambah_data') ?>");
$(".btn_save").addClass("btn_save btn btn-biru"); $(".btn_save").addClass("btn_save btn btn-biru");
...@@ -136,7 +135,7 @@ ...@@ -136,7 +135,7 @@
}); });
}); });
$(document).on("click", "#btn_new_input", function() { $(document).on("click", "#btn_new_input", function () {
$('#form_tambah :input').prop("disabled", false); $('#form_tambah :input').prop("disabled", false);
$('#form_tambah #id_karyawan').val(null).trigger('change'); $('#form_tambah #id_karyawan').val(null).trigger('change');
$('#form_tambah #saldo').val(''); $('#form_tambah #saldo').val('');
...@@ -147,7 +146,7 @@ ...@@ -147,7 +146,7 @@
$('#message').hide(); $('#message').hide();
}); });
$(document).on("click", ".btn_save", function(e) { $(document).on("click", ".btn_save", function (e) {
e.preventDefault(); e.preventDefault();
$('#modal_form #message').html(""); $('#modal_form #message').html("");
const loading = Ladda.create(this); const loading = Ladda.create(this);
...@@ -172,7 +171,7 @@ ...@@ -172,7 +171,7 @@
url: "<?= route('history.cuti.save') ?>", url: "<?= route('history.cuti.save') ?>",
data: param, data: param,
dataType: 'JSON', dataType: 'JSON',
success: function(result) { success: function (result) {
if (result.success == true) { if (result.success == true) {
if (result.type == 'save') { if (result.type == 'save') {
$("#form_tambah :input").prop("disabled", true); $("#form_tambah :input").prop("disabled", true);
...@@ -188,7 +187,7 @@ ...@@ -188,7 +187,7 @@
$('#modal_form #message').show(); $('#modal_form #message').show();
$('#modal_form #message').html(result.message); $('#modal_form #message').html(result.message);
}, },
error: function() { error: function () {
loading.stop(); loading.stop();
$('#modal_form #message').show(); $('#modal_form #message').show();
$('#modal_form #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong><?= $this->lang->line('error') ?></strong></font>'); $('#modal_form #message').html('<font color="#eb3a28"><i class="fa fa-close(alias)">&nbsp;</i><strong><?= $this->lang->line('error') ?></strong></font>');
...@@ -275,23 +274,23 @@ ...@@ -275,23 +274,23 @@
<div class="card card-rounded"> <div class="card card-rounded">
<div class="card-content"> <div class="card-content">
<div class="card-body"> <div class="card-body">
<div class="table-responsive"> <div class="row">
<div class="row"> <div class="col-md-12">
<div class="col-md-12"> <div class="form-group row">
<div class="form-group row"> <label class="col-md-1 font-weight-bold text-uppercase">Tahun</label>
<label class="col-md-1 font-weight-bold text-uppercase">Tahun</label> <div class="col-md-3">
<div class="col-md-3"> <input type="text" id="filter_tahun" class="form-control">
<input type="text" id="filter_tahun" class="form-control"> </div>
</div> <div class="col-md-2">
<div class="col-md-2"> <button type="button" id="btn_filter_tahun" class="btn btn-primary btn-block ladda-button" data-style="expand-left">FILTER</button>
<button type="button" id="btn_filter_tahun" class="btn btn-primary btn-block ladda-button" data-style="expand-left">FILTER</button>
</div>
</div> </div>
</div> </div>
</div> </div>
<div class="row mt-2"> </div>
<div class="col-md-6"> <div class="row mt-2">
<h4 style="text-align: center;">PENAMBAHAN SALDO CUTI</h4> <div class="col-md-6">
<h4 style="text-align: center;">PENAMBAHAN SALDO CUTI</h4>
<div class="table-responsive">
<table id="list_data" class="table table-striped" style="width:100%"> <table id="list_data" class="table table-striped" style="width:100%">
<thead> <thead>
<tr> <tr>
...@@ -303,12 +302,12 @@ ...@@ -303,12 +302,12 @@
<tbody> <tbody>
</tbody> </tbody>
</table> </table>
</div><!-- </div>
<div class="col-md-1"> </div>
</div> --> <div class="col-md-6">
<div class="col-md-6"> <h4 style="text-align: center;">SALDO CUTI TERPAKAI</h4>
<h4 style="text-align: center;">SALDO CUTI TERPAKAI</h4> <div class="table-responsive">
<table id="list_data2" class="table table-striped" style="width:100%"> <table id="list_data2" class="table table-striped" style="width:100%">
<thead> <thead>
<tr> <tr>
...@@ -325,4 +324,4 @@ ...@@ -325,4 +324,4 @@
</div> </div>
</div> </div>
</div> </div>
</div> </div>
\ No newline at end of file
...@@ -426,10 +426,10 @@ html body .content .content-wrapper { ...@@ -426,10 +426,10 @@ html body .content .content-wrapper {
padding: 0.6rem 1rem !important; padding: 0.6rem 1rem !important;
font-size: 13px; font-size: 13px;
} }
.dataTables_filter .form-control { .dt-search .form-control {
line-height: 1.25; line-height: 1.25;
height: calc(2.4rem + 2px) !important; height: calc(2.4rem + 2px) !important;
padding: 0.6rem 1rem !important; padding: 0.6rem 1rem !important;
} }
select.form-control:not([size]):not([multiple]), select.form-control:not([size]):not([multiple]),
.select2-container .select2-selection--single .select2-selection__rendered, .select2-container .select2-selection--single .select2-selection__rendered,
...@@ -468,11 +468,11 @@ select.form-control:not([size]):not([multiple]), ...@@ -468,11 +468,11 @@ select.form-control:not([size]):not([multiple]),
/*Css Button Selesai*/ /*Css Button Selesai*/
/*CSS Table*/ /*CSS Table*/
table.dataTable thead { table.dataTable thead tr>.dtfc-fixed-start, table.dataTable thead tr>.dtfc-fixed-end, table.dataTable tfoot tr>.dtfc-fixed-start, table.dataTable tfoot tr>.dtfc-fixed-end, table.dataTable thead {
background-color: var(--warna-kustom); background-color: var(--warna-kustom) !important;
color: #fff; color: #fff;
text-align: center; text-align: center;
font-size: 13.5px; font-size: 13.5px;
} }
table.dataTable th, table.dataTable th,
table.dataTable td { table.dataTable td {
...@@ -1216,12 +1216,21 @@ select:focus { ...@@ -1216,12 +1216,21 @@ select:focus {
.datepicker { .datepicker {
z-index: 9999 !important; z-index: 9999 !important;
} }
div.dataTables_wrapper div.dataTables_filter label {
margin-top: 0; div.dt-container div.dt-search label {
margin-top: 0;
}
div.dt-container div.dt-layout-start, div.dt-container div.dt-layout-end, div.dt-container div.dt-layout-full {
padding: 4px 0px;
} }
.dataTables_length .custom-select { div.dt-container div.dt-processing > div > div {
/* background: transparent; */ background-color: var(--warna-kustom) !important;
}
.dt-length .custom-select {
/* background: transparent; */
} }
.page-link { .page-link {
font-weight: normal; font-weight: normal;
...@@ -1236,32 +1245,32 @@ div.dataTables_wrapper div.dataTables_filter label { ...@@ -1236,32 +1245,32 @@ div.dataTables_wrapper div.dataTables_filter label {
color: #333; color: #333;
} }
.page-link:hover { .page-link:hover {
background-color: var(--warna-kustom); background-color: var(--warna-kustom);
color: #fff; color: #fff;
} }
ul.pagination .page-item.active .page-link { ul.pagination .page-item.active .page-link {
-webkit-transition: color 0.15s ease, background-color 0.15s ease, -webkit-transition: color 0.15s ease, background-color 0.15s ease,
border-color 0.15s ease, -webkit-box-shadow 0.15s ease; border-color 0.15s ease, -webkit-box-shadow 0.15s ease;
transition: color 0.15s ease, background-color 0.15s ease, transition: color 0.15s ease, background-color 0.15s ease,
border-color 0.15s ease, -webkit-box-shadow 0.15s ease; border-color 0.15s ease, -webkit-box-shadow 0.15s ease;
transition: color 0.15s ease, background-color 0.15s ease, transition: color 0.15s ease, background-color 0.15s ease,
border-color 0.15s ease, box-shadow 0.15s ease; border-color 0.15s ease, box-shadow 0.15s ease;
transition: color 0.15s ease, background-color 0.15s ease, transition: color 0.15s ease, background-color 0.15s ease,
border-color 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease,
-webkit-box-shadow 0.15s ease; -webkit-box-shadow 0.15s ease;
background-color: var(--warna-kustom); background-color: var(--warna-kustom);
color: #fff; color: #fff;
align-items: center; align-items: center;
height: 2rem; height: 2rem;
min-width: 2rem; min-width: 2rem;
padding: 0.5rem; padding: 0.5rem;
text-align: center; text-align: center;
position: relative; position: relative;
font-size: 1rem; font-size: 1rem;
line-height: 1rem; line-height: 1rem;
font-weight: 500; font-weight: 500;
border-radius: 0.42rem; border-radius: 0.42rem;
border: 0; border: 0;
} }
ul.pagination li { ul.pagination li {
margin-left: 0.4rem; margin-left: 0.4rem;
...@@ -1278,11 +1287,11 @@ ul.pagination li:last-child a { ...@@ -1278,11 +1287,11 @@ ul.pagination li:last-child a {
} }
ul.pagination li:first-child a:hover, ul.pagination li:first-child a:hover,
ul.pagination li:last-child a:hover { ul.pagination li:last-child a:hover {
background-color: var(--warna-kustom) !important; background-color: var(--warna-kustom) !important;
} }
.dataTables_paginate.paging_simple_numbers { .dt-paging.paging_simple_numbers {
margin-top: 0.5em !important; margin-top: 0.5em !important;
} }
/*CSS Plugin selesai*/ /*CSS Plugin selesai*/
...@@ -1839,14 +1848,6 @@ input:checked + .slider:before { ...@@ -1839,14 +1848,6 @@ input:checked + .slider:before {
} }
/* END CSS BANTUAN LAYANAN */ /* END CSS BANTUAN LAYANAN */
table.table-bordered.dataTable th:last-child,
table.table-bordered.dataTable th:last-child,
table.table-bordered.dataTable td:last-child,
table.table-bordered.dataTable td:last-child {
border-right-width: 1px !important;
}
.badge-custom-warning { .badge-custom-warning {
padding: 10px; padding: 10px;
background-color: #f3ebdb; background-color: #f3ebdb;
......
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment