Guest User

Untitled

a guest
Apr 3rd, 2020
186
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.55 KB | None | 0 0
  1. <?php
  2. Class Report extends CI_Controller{
  3.     function index(){
  4.         $this->load->view('admin/report');
  5.     }
  6.  
  7.     function post_report(){
  8.         $this->load->model("crud_model");
  9.         $where['date >='] = $this->input->post('startdate');
  10.         $where['date <='] = $this->input->post('enddate');
  11.         $data['total'] = $this->crud_model->total('transaction', 'total', $where)->row();
  12.         $data['report'] = $this->crud_model->tampil_id('transaction', $where)->result();
  13.         $this->load->view('admin/report', $data);
  14.  
  15.     }
  16. }
  17. ?>
Advertisement
Add Comment
Please, Sign In to add comment