แจกระบบแจ้งซ่อม, Helpdesk System สำหรับศึกษาและพัฒนาต่อยอด v0.5
Features
-พัฒนาด้วย CodeIgniter framework + Mysql + AdminLTE + Bootstrap4
เงื่อนไขการแจก
-แจก Source code ให้ไปศึกษาและพัฒนาต่อยอด แจกเป็นเวอร์ชั่น มีการอัพเดทเรื่อยๆ
v0.5
Release Date: May 10, 2020.
Features updates
Actors
– Admin => Add CRUD tbl_admin
Controllers
– Admin => add Fn. index, add, adding, edit, editdata, pwd, editpwd, del
Models
– Admin_model => add Fn. list_all, insert_admin, read, update_admin, update_pwd_admin, del_admin
Views
– update template/header.php, footer.php
– add backend/admin_list.php ,admin_form_add.php, admin_form_edit.php, admin_edit_pwd.php
โค้ดต้นฉบับ *จำเป็นต้องโหลดครับ
v0.2 https://devbanban.com/?p=3325
v0.3 https://devbanban.com/?p=3381
v0.4 https://devbanban.com/?p=3479
คลิปแนะนำการอัพเดทระบบ
https://www.youtube.com/watch?v=TynMfxkKyfs
Code Update
controllers/admin (Admin.php)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 |
<?php defined('BASEPATH') OR exit('No direct script access allowed'); class Admin extends CI_Controller { public function __construct() { parent::__construct(); //chk admin status if($this->session->userdata('admin_status') !=1){ redirect('login/logout','refresh'); } $this->load->model('admin_model'); } public function index() { $data['query']=$this->admin_model->list_all(); $this->load->view('template/header'); $this->load->view('backend/admin_list',$data); $this->load->view('template/footer'); } public function add() { $this->load->view('template/header'); $this->load->view('backend/admin_form_add' , array('error' => ' ' )); $this->load->view('template/footer'); } public function adding() { // echo '<pre>'; // print_r($_POST); // echo '</pre>'; // exit; $this->form_validation->set_rules('admin_name', 'ชื่อช่าง', 'trim|required|min_length[4]', array('required' => 'กรุณากรอกข้อมูล %s.', 'min_length' => 'กรุณากรอกข้อมูลขั้นต่ำ 4 ตัว')); $this->form_validation->set_rules('admin_pwd', 'password', 'trim|required|min_length[4]', array('required' => 'กรุณากรอกข้อมูล %s.', 'min_length' => 'กรุณากรอกข้อมูลขั้นต่ำ 4 ตัว')); $this->form_validation->set_rules('admin_email', 'อีเมล', 'trim|required|valid_email', array('required' => 'กรุณากรอกข้อมูล %s.', 'valid_email' => 'รูปแบบอีเมลไม่ถูกต้อง')); if ($this->form_validation->run() == FALSE) { $this->load->view('template/header'); $this->load->view('backend/admin_form_add' , array('error' => ' ' )); $this->load->view('template/footer'); }else{ //check duplicate admin_email $admin_email = $this->input->post('admin_email'); $this->db->select('admin_email'); $this->db->where('admin_email',$admin_email); $query = $this->db->get('tbl_admin'); $num = $query->num_rows(); if($num > 0) { $this->session->set_flashdata('check_duplicate', TRUE); redirect('admin','refresh'); }else{ $this->admin_model->insert_admin(); $this->session->set_flashdata('save_success', TRUE); redirect('admin','refresh'); }//check duplicate }//form vali } public function edit($id) { $data['rsedit']=$this->admin_model->read($id); // echo '<pre>'; // print_r($data['rsedit']); // echo '</pre>'; // exit(); $this->load->view('template/header'); $this->load->view('backend/admin_form_edit',$data); $this->load->view('template/footer'); } public function editdata() { // echo '<pre>'; // print_r($_POST); // echo '</pre>'; //exit; $this->form_validation->set_rules('id', 'id', 'trim|required|min_length[1]'); $this->form_validation->set_rules('admin_name', 'ชื่อช่าง', 'trim|required|min_length[4]', array('required' => 'กรุณากรอกข้อมูล %s.', 'min_length' => 'กรุณากรอกข้อมูลขั้นต่ำ 4 ตัว')); $this->form_validation->set_rules('admin_status', 'สถานะช่าง', 'trim|required|min_length[1]', array('required' => 'กรุณาเลือกสถานะ %s.', 'min_length' => 'กรุณาเลือกสถานะ')); if ($this->form_validation->run() == FALSE) { $id = $this->input->post('id'); $data['rsedit']=$this->admin_model->read($id); $this->load->view('template/header'); $this->load->view('backend/admin_form_edit',$data); $this->load->view('template/footer'); }else{ //exit; $this->admin_model->update_admin(); $this->session->set_flashdata('save_success', TRUE); redirect('admin','refresh'); } } public function pwd($id) { $data['rsedit']=$this->admin_model->read($id); $this->load->view('template/header'); $this->load->view('backend/admin_form_edit_pwd',$data); $this->load->view('template/footer'); } public function editpwd() { // echo '<pre>'; // print_r($_POST); // echo '</pre>'; // exit; $this->form_validation->set_rules('id', 'id', 'trim|required|min_length[1]'); $this->form_validation->set_rules('admin_pwd1', 'Password', 'trim|required|min_length[4]'); $this->form_validation->set_rules('admin_pwd2', 'Password Confirmation', 'trim|required|matches[admin_pwd1]'); if ($this->form_validation->run() == FALSE) { $id = $this->input->post('id'); $data['rsedit']=$this->admin_model->read($id); $this->load->view('template/header'); $this->load->view('backend/admin_form_edit_pwd',$data); $this->load->view('template/footer'); } else { $this->admin_model->update_pwd_admin(); $this->session->set_flashdata('save_success', TRUE); redirect('admin','refresh'); } } public function del($id) { $this->admin_model->del_admin($id); $this->session->set_flashdata('del_success', TRUE); redirect('admin','refresh'); } } |
models/admin_model (Admin_model.php)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 |
<?php defined('BASEPATH') OR exit('No direct script access allowed'); class Admin_model extends CI_Model { public function fetch_user_login($username,$password) { $this->db->where('admin_email',$username); $this->db->where('admin_pwd',$password); $query = $this->db->get('tbl_admin'); return $query->row(); } public function list_all() { $query = $this->db->get('tbl_admin'); return $query->result(); } public function insert_admin() { $data = array( 'admin_name' => $this->input->post('admin_name'), 'admin_email' => $this->input->post('admin_email'), 'admin_pwd' => sha1($this->input->post('admin_pwd')) ); $query=$this->db->insert('tbl_admin',$data); } //show form edit public function read($id){ $this->db->where('id',$id); $query = $this->db->get('tbl_admin'); if($query->num_rows() > 0){ $data = $query->row(); return $data; } return FALSE; } public function update_admin() { $data = array( 'admin_name' => $this->input->post('admin_name'), 'admin_status' => $this->input->post('admin_status') ); $this->db->where('id', $this->input->post('id')); $query=$this->db->update('tbl_admin',$data); } public function update_pwd_admin() { $data = array( 'admin_pwd' => sha1($this->input->post('admin_pwd1')) ); $this->db->where('id', $this->input->post('id')); $query=$this->db->update('tbl_admin',$data); } public function del_admin($id) { $this->db->delete('tbl_admin',array('id'=>$id)); } } |
Views/backend/
admin_list.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
<div class="content-wrapper"> <!-- Content Header (Page header) --> <section class="content-header"> <h1> จัดการ Admin/ช่าง </h1> </section> <!-- Top menu --> <?php // echo $this->session->flashdata('msginfo'); ?> <!-- Main content --> <section class="content"> <!-- Your Page Content Here --> <div class="box"> <div class="box-header"> <h3 class="box-title">ตารางข้อมูล</h3> </div><!-- /.box-header --> <div class="box-body"> <div id="example1_wrapper" class="dataTables_wrapper form-inline dt-bootstrap"> <div class="row"> <div class="col-sm-6"> <a class="btn btn-success" href="<?= site_url('admin/add'); ?>" role="button"><i class="fa fa-fw fa-plus-circle"></i> เพิ่มข้อมูล</a> <a class="btn btn-default" href="<?= site_url('admin'); ?>" role="button"><i class="fa fa-fw fa-refresh"></i> Refresh Data</a> </div> <div class="col-sm-6"> </div> </div> <div class="row"> <div class="col-sm-12"> <br /> <table id="example1" class="table table-bordered table-striped dataTable" role="grid" aria-describedby="example1_info"> <thead> <tr role="row" class="info"> <th tabindex="0" rowspan="1" colspan="1" style="width: 5%;">id</th> <th tabindex="0" rowspan="1" colspan="1" style="width: 40%;">ชื่อ-สกุล</th> <th tabindex="0" rowspan="1" colspan="1" style="width: 25%;">Email</th> <th tabindex="0" rowspan="1" colspan="1" style="width: 15%;">stauts</th> <th tabindex="0" rowspan="1" colspan="1" style="width: 5%;">pwd</th> <th tabindex="0" rowspan="1" colspan="1" style="width: 5%;">แก้ไข</th> <th tabindex="0" rowspan="1" colspan="1" style="width: 5%;">ลบ</th> </tr> </thead> <tbody> <?php foreach ($query as $rs) { ?> <tr role="row"> <td align="center"><?= $rs->id;?></td> <td><?= $rs->admin_name;?></td> <td><?= $rs->admin_email;?></td> <td> <?php if($rs->admin_status==1){ echo 'Online'; }else{ echo 'Ban'; } ?> </td> <td> <a href="<?php echo site_url('admin/pwd/'.$rs->id); ?>" class="btn btn-info btn-xs"> pwd </a> </td> <td> <a href="<?php echo site_url('admin/edit/'.$rs->id); ?>" class="btn btn-warning btn-xs"> แก้ไข </a> </td> <td> <a class="btn btn-danger btn-xs" href="<?= site_url('admin/del/'.$rs->id); ?>" role="button" onclick="return confirm('ยืนยันการลบข้อมูล??');"><i class="fa fa-fw fa-trash" ></i> ลบ</a> </td> </tr> <?php } ?> </tbody> </table> </div> </div> </div> </div><!-- /.box-body --> </div> </section><!-- /.content --> </div><!-- /.content-wrapper --> |
admin_form_add.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 |
<div class="content-wrapper"> <!-- Content Header (Page header) --> <section class="content-header"> <h1> ฟอร์มเพิ่มข้อมูล Admin/ช่าง </h1> </section> <!-- Main content --> <section class="content"> <div class="container"> <div class="row"> <div class="col-sm-12"> <!-- Your Page Content Here --> <div class="box box-primary"> <div class="box-header with-border"> <!-- <h3 class="box-title"> +ข่าวใหม่ </h3> --> </div><!-- /.box-header --> <!-- form start --> <form role="form" action="<?= site_url('admin/adding'); ?>" method="post" class="form-horizontal"> <div class="box-body"> <div class="form-group"> <div class="col-sm-2 control-label"> Email </div> <div class="col-sm-3"> <input type="email" name="admin_email" class="form-control" required placeholder="email" value="<?= set_value('admin_email'); ?>"> <span class="fr"><?= form_error('admin_email'); ?></span> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> Password </div> <div class="col-sm-3"> <input type="password" name="admin_pwd" class="form-control" required placeholder="ภาษาอังกฤษ/ตัวเลข/ขั้นต่ำ 4 ตัว" minlength="4" value="<?= set_value('admin_pwd'); ?>" pattern="^[a-zA-Z0-9]+$" title="ภาษาอังกฤษหรือตัวเลขเท่านั้น"> <span class="fr"><?= form_error('admin_pwd'); ?></span> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> ชื่อ </div> <div class="col-sm-4"> <input type="text" name="admin_name" class="form-control" required placeholder="ชื่อ ขั้นต่ำ 4 ตัว" value="<?= set_value('admin_name'); ?>" minlength="4"> <span class="fr"><?= form_error('admin_name'); ?></span> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> </div> <div class="col-sm-3"> <button class="btn btn-primary" type="submit"> <i class="fa fa-fw fa-save"></i> บันทึกข้อมูล</button> <a class="btn btn-danger" href="<?php echo site_url('admin'); ?>" role="button"><i class="fa fa-fw fa-close"></i> ยกเลิก</a> </div> </div> </div><!-- /.box-body --> </form> </div> </div> </div> </div> </section><!-- /.content --> </div><!-- /.content-wrapper --> |
admin_form_edit.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 |
<div class="content-wrapper"> <!-- Content Header (Page header) --> <section class="content-header"> <h1> ฟอร์มแก้ไขข้อมูล Admin/ช่าง </h1> </section> <!-- Main content --> <section class="content"> <div class="container"> <div class="row"> <div class="col-sm-12"> <!-- Your Page Content Here --> <div class="box box-primary"> <div class="box-header with-border"> <!-- <h3 class="box-title"> +ข่าวใหม่ </h3> --> </div><!-- /.box-header --> <!-- form start --> <form role="form" action="<?= site_url('admin/editdata'); ?>" method="post" class="form-horizontal"> <div class="box-body"> <div class="form-group"> <div class="col-sm-2 control-label"> Email </div> <div class="col-sm-3"> <input type="email" name="admin_email" class="form-control" required placeholder="email" value="<?= $rsedit->admin_email; ?>" disabled> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> ชื่อ </div> <div class="col-sm-4"> <input type="text" name="admin_name" class="form-control" required placeholder="ชื่อ ขั้นต่ำ 4 ตัว" value="<?= $rsedit->admin_name; ?>" minlength="4"> <span class="fr"><?= form_error('admin_name'); ?></span> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> status </div> <div class="col-sm-3"> <select name="admin_status" required class="form-control"> <span class="fr"><?= form_error('admin_status'); ?></span> <option value="<?= $rsedit->admin_status;?>"> <?php if($rsedit->admin_status==1){echo 'Online';}else{echo 'Ban';}?> </option> <option value="">--เปลี่ยน---</option> <option value="1">-Online</option> <option value="0">-Ban</option> </select> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> </div> <div class="col-sm-3"> <input type="hidden" name="id" value="<?= $rsedit->id;?>"> <span class="fr"><?= form_error('id'); ?></span> <button class="btn btn-primary" type="submit"> <i class="fa fa-fw fa-save"></i> บันทึกข้อมูล</button> <a class="btn btn-danger" href="<?= site_url('admin'); ?>" role="button"><i class="fa fa-fw fa-close"></i> ยกเลิก</a> </div> </div> </div><!-- /.box-body --> </form> </div> </div> </div> </div> </section><!-- /.content --> </div><!-- /.content-wrapper --> |
admin_form_edit_pwd.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 |
<div class="content-wrapper"> <!-- Content Header (Page header) --> <section class="content-header"> <h1> ฟอร์ม Reset Password Admin/ช่าง </h1> </section> <!-- Main content --> <section class="content"> <div class="container"> <div class="row"> <div class="col-sm-12"> <!-- Your Page Content Here --> <div class="box box-primary"> <div class="box-header with-border"> <!-- <h3 class="box-title"> +ข่าวใหม่ </h3> --> </div><!-- /.box-header --> <!-- form start --> <form role="form" action="<?= site_url('admin/editpwd'); ?>" method="post" class="form-horizontal"> <div class="box-body"> <div class="form-group"> <div class="col-sm-2 control-label"> Email </div> <div class="col-sm-3"> <input type="email" name="admin_email" class="form-control" required placeholder="email" value="<?= $rsedit->admin_email; ?>" disabled> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> ชื่อ </div> <div class="col-sm-4"> <input type="text" name="admin_name" class="form-control" required placeholder="ชื่อ ขั้นต่ำ 4 ตัว" value="<?= $rsedit->admin_name; ?>" minlength="4" disabled> <span class="fr"><?= form_error('admin_name'); ?></span> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> New Password </div> <div class="col-sm-3"> <input type="password" name="admin_pwd1" class="form-control" required placeholder="ภาษาอังกฤษ/ตัวเลข/ขั้นต่ำ 4 ตัว" minlength="4" value="<?= set_value('admin_pwd'); ?>" pattern="^[a-zA-Z0-9]+$" title="ภาษาอังกฤษหรือตัวเลขเท่านั้น"> <span class="fr"><?= form_error('admin_pwd1'); ?></span> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> Confirm Password </div> <div class="col-sm-3"> <input type="password" name="admin_pwd2" class="form-control" required placeholder="ภาษาอังกฤษ/ตัวเลข/ขั้นต่ำ 4 ตัว" minlength="4" value="<?= set_value('admin_pwd'); ?>" pattern="^[a-zA-Z0-9]+$" title="ภาษาอังกฤษหรือตัวเลขเท่านั้น"> <span class="fr"><?= form_error('admin_pwd2'); ?></span> </div> </div> <div class="form-group"> <div class="col-sm-2 control-label"> </div> <div class="col-sm-3"> <input type="hidden" name="id" value="<?= $rsedit->id;?>"> <span class="fr"><?= form_error('id'); ?></span> <button class="btn btn-primary" type="submit"> <i class="fa fa-fw fa-save"></i> บันทึกข้อมูล</button> <a class="btn btn-danger" href="<?= site_url('admin'); ?>" role="button"><i class="fa fa-fw fa-close"></i> ยกเลิก</a> </div> </div> </div><!-- /.box-body --> </form> </div> </div> </div> </div> </section><!-- /.content --> </div><!-- /.content-wrapper --> |
View/template/
header.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 |
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?> <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=edge"> <title>My Backend</title> <!-- Tell the browser to be responsive to screen width --> <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport"> <!-- Bootstrap 3.3.7 --> <?php echo link_tag('asset/bower_components/bootstrap/dist/css/bootstrap.min.css'); ?> <!-- Font Awesome --> <?php echo link_tag('asset/bower_components/font-awesome/css/font-awesome.min.css'); ?> <!-- Ionicons --> <?php echo link_tag('asset/bower_components/Ionicons/css/ionicons.min.css'); ?> <!-- DataTables --> <?php echo link_tag('asset/bower_components/datatables.net-bs/css/dataTables.bootstrap.min.css'); ?> <!-- Theme style --> <?php echo link_tag('asset/dist/css/AdminLTE.min.css'); ?> <!-- AdminLTE Skins. Choose a skin from the css/skins folder instead of downloading all of them to reduce the load. --> <?php echo link_tag('asset/dist/css/skins/_all-skins.min.css'); ?> <!-- AdminLTE App --> <script src="<?php echo base_url(); ?>asset/dist/js/app.min.js" type="text/javascript"> </script> <!-- Google Font --> <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,600,700,300italic,400italic,600italic"> <!-- ckeditor--> <script src="//cdn.ckeditor.com/4.6.2/standard/ckeditor.js"></script> <script src="https://unpkg.com/sweetalert/dist/sweetalert.min.js"></script> <style type="text/css"> .fr{color: red;} </style> </head> <body class="hold-transition skin-red sidebar-mini"> <div class="wrapper"> <header class="main-header"> <!-- Logo --> <a href="<?php //echo $mylink;?>" class="logo"> <!-- mini logo for sidebar mini 50x50 pixels --> <span class="logo-mini"><b>My</b>Backend</span> <!-- logo for regular state and mobile devices --> <span class="logo-lg"><b>My</b>Backend</span> </a> <!-- Header Navbar: style can be found in header.less --> <nav class="navbar navbar-static-top"> <!-- Sidebar toggle button--> <a href="#" class="sidebar-toggle" data-toggle="push-menu" role="button"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </a> <div class="navbar-custom-menu"> <ul class="nav navbar-nav"> <!-- User Account: style can be found in dropdown.less --> <li class="dropdown user user-menu"> <a href="#" class="dropdown-toggle" data-toggle="dropdown"> <span class="glyphicon glyphicon-user"></span> <span class="hidden-xs"><?php echo $_SESSION['admin_name'];?></span> </a> <ul class="dropdown-menu"> <!-- User image --> <li class="user-header"> <span class="glyphicon glyphicon-user"></span> <p> <?php echo $_SESSION['admin_name'];?> </p> </li> <!-- Menu Footer--> <li class="user-footer"> <div class="pull-left"> <a href="<?php // echo site_url('');?>" class="btn btn-primary btn-flat">Profile</a> </div> <div class="pull-right"> <a href="<?php echo site_url('login/logout');?>" onclick="return confirm('คุณต้องการออกจากระบบหรือไม่??');" class="btn btn-danger btn-flat">Sign out</a> </div> </li> </ul> </li> </ul> </div> </nav> </header> <!-- Left side column. contains the logo and sidebar --> <aside class="main-sidebar"> <!-- sidebar: style can be found in sidebar.less --> <section class="sidebar"> <!-- Sidebar user panel --> <div class="user-panel"> <div class="pull-left image"> <br><br> </div> <div class="pull-left info"> <p><span class="glyphicon glyphicon-user"></span><?php echo $_SESSION['admin_name'];?></p> <a href="#"><i class="fa fa-circle text-success"></i> Online</a> </div> </div> <!-- sidebar menu: : style can be found in sidebar.less --> <ul class="sidebar-menu" data-widget="tree"> <li class="header">MAIN NAVIGATION</li> <li><a href="<?= site_url('admin');?>"><i class="fa fa-home"></i> <span>HOME</span></a></li> <li><a href="https://devbanban.com/?p=2867" target="_blank"><i class="fa fa-globe"></i> <span>สอน CodeIgniter</span></a></li> <li><a href="<?= site_url('login/logout');?>" onclick="return confirm('do you want to logout ?');"><i class="fa fa-edit"></i> <span>Logout</span></a></li> </ul> </section> <!-- /.sidebar --> </aside> |
footer.php
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 |
<footer class="main-footer"> <div class="pull-right hidden-xs"> <b>Helpdesk System by devbanban.com 2020</b> </div> <strong> <a href="https://devbanban.com/?p=2867" target="_blank">คอร์สออนไลน์สอน CodeIgniter เข้าเรียนได้ตลอดชีพ คลิก </a>.</strong> </footer> <!-- Add the sidebar's background. This div must be placed immediately after the control sidebar --> <div class="control-sidebar-bg"></div> </div> <!-- ./wrapper --> <!-- jQuery 3 --> <script src="<?php echo base_url(); ?>asset/bower_components/jquery/dist/jquery.min.js"></script> <!-- Bootstrap 3.3.7 --> <script src="<?php echo base_url(); ?>asset/bower_components/bootstrap/dist/js/bootstrap.min.js"></script> <!-- DataTables --> <script src="<?php echo base_url(); ?>asset/bower_components/datatables.net/js/jquery.dataTables.min.js"></script> <script src="<?php echo base_url(); ?>asset/bower_components/datatables.net-bs/js/dataTables.bootstrap.min.js"></script> <!-- AdminLTE App --> <script src="<?php echo base_url(); ?>asset/dist/js/adminlte.min.js"></script> <script src="<?php echo base_url(); ?>asset/dist/js/demo.js"></script> </body> </html> <script> $(document).ready(function() { $('#example1').DataTable( { "aaSorting" :[[0,'desc']], //"lengthMenu":[[20,50, 100, -1], [20,50, 100,"All"]] }); } ); </script> <script> $(function () { $('#example1').DataTable() $('#example2').DataTable({ 'paging' : true, 'lengthChange': false, 'searching' : false, 'ordering' : true, 'info' : true, 'autoWidth' : false }) }) </script> <script type="text/javascript"> <?php if ($this->session->flashdata('save_success')): ?> swal("", "บันทึกข้อมูลเรียบร้อยแล้ว", "success"); <?php endif; ?> <?php if ($this->session->flashdata('check_duplicate')): ?> swal("", "ข้อมูลซ้ำ!!!", "warning"); <?php endif; ?> <?php if ($this->session->flashdata('wrong_alert')): ?> swal("", "เกิดข้อผิดพลาด!!!", "warning"); <?php endif; ?> <?php if ($this->session->flashdata('del_success')): ?> swal("", "ลบข้อมูลเรียบร้อยแล้ว", "success"); <?php endif; ?> </script> |
*คอร์สออนไลน์สอน CodeIgniter แบบละเอียดทุกขั้นตอนคลิก
ร่วมสนับสนุน ค่ากาแฟ ค่าโฮส devbanban.com ได้ที่
ธนาคารกรุงไทย สาขาเดอะมอลล์ท่าพระ
ชื่อบัญชี นายพิศิษฐ์ บวรเลิศสุธี เลขที่ 878-0-17747-6
————————————————————————————
ธนาคารไทยพาณิชย์ สาขามหาวิทยาลัยราชภัฏธนบุรี
ชื่อบัญชี นายพิศิษฐ์ บวรเลิศสุธี เลขที่ 406-359094-1
————————————————————————————
ธนาคารกสิกร สาขาเออร์เบิร์น สแควร์ ประชาชื่น
ชื่อบัญชี นายพิศิษฐ์บวรเลิศสุธี เลขที่ 048-1-17571-2
แฟนเพจ : https://www.facebook.com/sornwebsites/
–