Files
2019-05-25 23:11:05 -04:00

84 lines
2.0 KiB
PHP

<?php
defined('BASEPATH') OR exit('No direct script access allowed');
class Report extends Agent_Controller {
/**
* Index Page for this controller.
*
* Maps to the following URL
* http://example.com/index.php/welcome
* - or -
* http://example.com/index.php/welcome/index
* - or -
* Since this controller is set as the default controller in
* config/routes.php, it's displayed at http://example.com/
*
* So any other public methods not prefixed with an underscore will
* map to /index.php/welcome/<method_name>
* @see https://codeigniter.com/user_guide/general/urls.html
*/
function __construct() {
parent::__construct();
}
public function index() {
$data = array();
$in['agent_id'] = $_SESSION['agent_id'];
$in['limit'] = 10;
$in['action'] = MEDTRANS_USER_GET_TRANSLIST;
$out = array();
$ret = $this->medtrans_call_api(MEDTRANS_TRANSP_GET_TRANSLIST, $in, $out);
$data['result_list'] = $out['result_list'];
$in['limit'] = 5;
$ret = $this->medtrans_call_api(MEDTRANS_TRANSP_GET_TRANSLIST, $in, $out);
$data['today_list'] = $out['result_list'];
//echo $out['status'];
//print_r($out);
$this->renderAgentPage('view_agent_dash', $data);
}
public function calendar() {
$data = array();
$in['agent_id'] = $_SESSION['agent_id'];
$in['limit'] = 10;
$this->renderAgentPage('view_agent_calendar', $data);
}
public function profile() {
$data = array();
$in['agent_id'] = $_SESSION['agent_id'];
$in['limit'] = 10;
$this->renderAgentPage('view_agent_profile', $data);
}
public function mylog()
{
$data = array();
$in['agent_id'] = $_SESSION['agent_id'];
$in['limit'] = 10;
$this->renderAgentPage('view_agent_mylog', $data);
}
}