Index: pro-violet-viettel/sourcecode/application/modules/admin/controllers/report.php
===================================================================
--- pro-violet-viettel/sourcecode/application/modules/admin/controllers/report.php	(revision 443)
+++ pro-violet-viettel/sourcecode/application/modules/admin/controllers/report.php	(revision 444)
@@ -6,5 +6,6 @@
 class Report extends MX_Controller {
 
-    const TOKENPW = 'violet';
+const TOKENPW = 'violet';
+
     public function __construct() {
         parent::__construct();
@@ -16,5 +17,5 @@
         $admin_info = $this->session->userdata('adminInfo');
         if ($admin_info) {
-            $data['statistics'] = $this->getStatistics();           
+            $data['statistics'] = $this->getStatistics();
             $data['content'] = $this->getPaidlogs();
             $this->load->view('report/index', $data);
@@ -23,84 +24,128 @@
         }
     }
-    public function getStatistics()
-    {
-        $data=array();
-        
-        $last_month['start']= strtotime(date("Y-m-d", strtotime("first day of previous month"))." 00:00:00");
-        $last_month['end']= strtotime(date("Y-m-d", strtotime("last day of previous month"))." 23:59:59");
-        
-        $last_week['start']= strtotime(date("Y-m-d", strtotime("first day of previous week"))." 00:00:00");
-        $last_week['end']= strtotime(date("Y-m-d", strtotime("last day of previous week"))." 23:59:59");
-        
-        $last_week['end']=strtotime('last sunday')+(24*60*60-1);
-        $last_week['start']=($last_week['end']-7*24*60*60+1);
-        
-        $last_year['start']=  strtotime((date("Y")-1)."-01-01 00:00:00");
-        $last_year['end']=  strtotime((date("Y")-1)."-12-31 23:59:59");
-        
-        
-        
-        $last_quarter=$this->getLastquarter();
-        $last_quarter['start']=  $last_quarter['start'];
-        $last_quarter['end']=  $last_quarter['end'];
-        
-        
+
+    public function getStatistics() {
+        $data = array();
+
+        $last_month['start'] = strtotime(date("Y-m-d", strtotime("first day of previous month")) . " 00:00:00");
+        $last_month['end'] = strtotime(date("Y-m-d", strtotime("last day of previous month")) . " 23:59:59");
+
+        $last_week['start'] = strtotime(date("Y-m-d", strtotime("first day of previous week")) . " 00:00:00");
+        $last_week['end'] = strtotime(date("Y-m-d", strtotime("last day of previous week")) . " 23:59:59");
+
+        $last_week['end'] = strtotime('last sunday') + (24 * 60 * 60 - 1);
+        $last_week['start'] = ($last_week['end'] - 7 * 24 * 60 * 60 + 1);
+
+        $last_year['start'] = strtotime((date("Y") - 1) . "-01-01 00:00:00");
+        $last_year['end'] = strtotime((date("Y") - 1) . "-12-31 23:59:59");
+
+
+
+        $last_quarter = $this->getLastquarter();
+        $last_quarter['start'] = $last_quarter['start'];
+        $last_quarter['end'] = $last_quarter['end'];
+
+
         $this->load->model('paidlog_model');
         $paidlogs = $this->paidlog_model->getAllPaidlogs($last_year['start']);
-        
-        $revenue['last_week']=0;
-        $revenue['last_month']=0;
-        $revenue['last_quarter']=0;
-        $revenue['last_year']=0;
-        foreach ($paidlogs as $paidlog)
-        {
-            
-            if (($paidlog['time'] < $last_week['end'])&&($paidlog['time'] > $last_week['start']))
-            {
+
+        $revenue['last_week'] = 0;
+        $revenue['last_month'] = 0;
+        $revenue['last_quarter'] = 0;
+        $revenue['last_year'] = 0;
+
+        $lastmonth = strtotime("first day of previous month");
+        $thismonth = strtotime("first day of this month");
+        $charts['last_month'] = array(0 => 0, 1 => 0, 2 => 0, 3 => 0, 4 => 0);
+        $charts['this_month'] = array(0 => 0, 1 => 0, 2 => 0, 3 => 0, 4 => 0);
+        foreach ($paidlogs as $paidlog) {
+
+            if (($paidlog['time'] < $last_week['end']) && ($paidlog['time'] > $last_week['start'])) {
                 $revenue['last_week']+=$paidlog['amount'];
             }
-            if (($paidlog['time'] < $last_month['end'])&&($paidlog['time'] > $last_month['start']))
-            {
+            if (($paidlog['time'] < $last_month['end']) && ($paidlog['time'] > $last_month['start'])) {
                 $revenue['last_month']+=$paidlog['amount'];
             }
-            if (($paidlog['time'] < $last_quarter['end'])&&($paidlog['time'] > $last_quarter['start']))
-            {
+            if (($paidlog['time'] < $last_quarter['end']) && ($paidlog['time'] > $last_quarter['start'])) {
                 $revenue['last_quarter']+=$paidlog['amount'];
             }
-            if (($paidlog['time'] < $last_year['end'])&&($paidlog['time'] > $last_year['start']))
-            {
+            if (($paidlog['time'] < $last_year['end']) && ($paidlog['time'] > $last_year['start'])) {
                 $revenue['last_year']+=$paidlog['amount'];
             }
-        }
-        $data['revenue']=$revenue;
+            if (($paidlog['time'] < $lastmonth + (7 * 24 * 60 * 60)) && ($paidlog['time'] > $lastmonth)) {
+                $charts['last_month'][0]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $lastmonth + (14 * 24 * 60 * 60)) && ($paidlog['time'] > $lastmonth + (7 * 24 * 60 * 60))) {
+                $charts['last_month'][1]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $lastmonth + (21 * 24 * 60 * 60)) && ($paidlog['time'] > $lastmonth + (14 * 24 * 60 * 60))) {
+                $charts['last_month'][2]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $lastmonth + (28 * 24 * 60 * 60)) && ($paidlog['time'] > $lastmonth + (21 * 24 * 60 * 60))) {
+                $charts['last_month'][3]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $thismonth) && ($paidlog['time'] > $lastmonth + (28 * 24 * 60 * 60))) {
+                $charts['last_month'][3]+=$paidlog['amount'];
+            }
+
+            if (($paidlog['time'] < $thismonth + (7 * 24 * 60 * 60)) && ($paidlog['time'] > $thismonth)) {
+                $charts['this_month'][0]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $thismonth + (14 * 24 * 60 * 60)) && ($paidlog['time'] > $thismonth + (7 * 24 * 60 * 60))) {
+                $charts['this_month'][1]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $thismonth + (21 * 24 * 60 * 60)) && ($paidlog['time'] > $thismonth + (14 * 24 * 60 * 60))) {
+                $charts['this_month'][2]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $thismonth + (28 * 24 * 60 * 60)) && ($paidlog['time'] > $thismonth + (21 * 24 * 60 * 60))) {
+                $charts['this_month'][3]+=$paidlog['amount'];
+            }
+            if (($paidlog['time'] < $thismonth + (31 * 24 * 60 * 60)) && ($paidlog['time'] > $thismonth + (28 * 24 * 60 * 60))) {
+                $charts['this_month'][3]+=$paidlog['amount'];
+            }
+        }
+        $max = 0;
+        foreach ($charts['last_month'] as $index => $total) {
+            if ($total > $max) {
+                $max = $total;
+            }
+            $chart_last_month[] = array($index, $total);
+        }
+        foreach ($charts['this_month'] as $index => $total) {
+            if ($total > $max) {
+                $max = $total;
+            }
+            $chart_this_month[] = array($index, $total);
+        }
+
+        $data['revenue'] = $revenue;
+        $data['max'] = $max;
+        $chard[] = array("color" => "#1abc9c", "label" => "ThÃ¡ng hiá»n táº¡i", "data" => $chart_this_month);
+        $chard[] = array("color" => "#3498db", "label" => "ThÃ¡ng trÆ°á»c", "data" => $chart_last_month);
+        $data['chard'] = $chard;
+
         return $this->load->view('report/statistics', $data, true);
     }
-    public function getLastquarter()
-    {
+
+    public function getLastquarter() {
         $current_month = date('m');
-          $current_year = date('Y');
-
-          if($current_month>=1 && $current_month<=3)
-          {
-            $start_date = strtotime('1-October-'.($current_year-1));  // timestamp or 1-October Last Year 12:00:00 AM
-            $end_date = strtotime('1-Janauary-'.$current_year);  // // timestamp or 1-January  12:00:00 AM means end of 31 December Last year
-          } 
-          else if($current_month>=4 && $current_month<=6)
-          {
-            $start_date = strtotime('1-January-'.$current_year);  // timestamp or 1-Janauray 12:00:00 AM
-            $end_date = strtotime('1-April-'.$current_year);  // timestamp or 1-April 12:00:00 AM means end of 31 March
-          }
-          else  if($current_month>=7 && $current_month<=9)
-          {
-            $start_date = strtotime('1-April-'.$current_year);  // timestamp or 1-April 12:00:00 AM
-            $end_date = strtotime('1-July-'.$current_year);  // timestamp or 1-July 12:00:00 AM means end of 30 June
-          }
-          else  if($current_month>=10 && $current_month<=12)
-          {
-            $start_date = strtotime('1-July-'.$current_year);  // timestamp or 1-July 12:00:00 AM
-            $end_date = strtotime('1-October-'.$current_year);  // timestamp or 1-October 12:00:00 AM means end of 30 September
-          }
-          return array("start"=>$start_date,"end"=>$end_date);
-    }
+        $current_year = date('Y');
+
+        if ($current_month >= 1 && $current_month <= 3) {
+            $start_date = strtotime('1-October-' . ($current_year - 1));  // timestamp or 1-October Last Year 12:00:00 AM
+            $end_date = strtotime('1-Janauary-' . $current_year);  // // timestamp or 1-January  12:00:00 AM means end of 31 December Last year
+        } else if ($current_month >= 4 && $current_month <= 6) {
+            $start_date = strtotime('1-January-' . $current_year);  // timestamp or 1-Janauray 12:00:00 AM
+            $end_date = strtotime('1-April-' . $current_year);  // timestamp or 1-April 12:00:00 AM means end of 31 March
+        } else if ($current_month >= 7 && $current_month <= 9) {
+            $start_date = strtotime('1-April-' . $current_year);  // timestamp or 1-April 12:00:00 AM
+            $end_date = strtotime('1-July-' . $current_year);  // timestamp or 1-July 12:00:00 AM means end of 30 June
+        } else if ($current_month >= 10 && $current_month <= 12) {
+            $start_date = strtotime('1-July-' . $current_year);  // timestamp or 1-July 12:00:00 AM
+            $end_date = strtotime('1-October-' . $current_year);  // timestamp or 1-October 12:00:00 AM means end of 30 September
+        }
+        return array("start" => $start_date, "end" => $end_date);
+    }
+
     public function getPaidlogs($filters = array()) {
         $this->load->helper('pagging');
@@ -110,12 +155,11 @@
         $data['perpage'] = 10;
         $data['keyword'] = "";
-        $data['sorting_order']="sorting_desc";
-        $data['sorting_field']="paid_id";
-        
+        $data['sorting_order'] = "sorting_desc";
+        $data['sorting_field'] = "paid_id";
+
         if ($this->input->post('sorting_order')) {
-            if ($this->input->post('sorting_order') != "sorting")
-            {
-               $data['sorting_order']=$this->input->post('sorting_order');
-               $data['sorting_field']=$this->input->post('sorting_field'); 
+            if ($this->input->post('sorting_order') != "sorting") {
+                $data['sorting_order'] = $this->input->post('sorting_order');
+                $data['sorting_field'] = $this->input->post('sorting_field');
             }
         }
@@ -124,16 +168,14 @@
         }
         if ($this->input->post('keyword')) {
-            $data['search_field']="";
+            $data['search_field'] = "";
             $data['keyword'] = $this->input->post('keyword');
-            
-            if (preg_match("/[0-9]/", $data['keyword']))
-            {
-               $data['search_field']="cellphone"; 
-            }
-            
-        }
-        
-        $data['start'] = ($data['current_page'] - 1) * $data['perpage'];    
-        $data['total'] = $this->paidlog_model->countPaidlog($data);  
+
+            if (preg_match("/[0-9]/", $data['keyword'])) {
+                $data['search_field'] = "cellphone";
+            }
+        }
+
+        $data['start'] = ($data['current_page'] - 1) * $data['perpage'];
+        $data['total'] = $this->paidlog_model->countPaidlog($data);
         $data['paidlogs'] = $this->paidlog_model->getPaidlogs($data);
 
@@ -141,9 +183,8 @@
         $data['num_links'] = 2;
         $data['paging'] = pagging($data);
-        foreach ($data['paidlogs'] as $index=>$paidlog)
-        {
-        $data['paidlogs'][$index]['username']= @$this->get_username($paidlog['us_id']);
-        }
-      
+        foreach ($data['paidlogs'] as $index => $paidlog) {
+            $data['paidlogs'][$index]['username'] = $this->get_username($paidlog['us_id']);
+        }
+
         if ($this->input->is_ajax_request()) {
             return $this->load->view('report/listview', $data);
@@ -151,169 +192,43 @@
         return $this->load->view('report/listview', $data, true);
     }
-    public function get_username($us_id)
-	{
-        $us_id=33;
-		$src = 'violet';
-		$token = md5($us_id.self::TOKENPW);
-		$this->load->model('user_model');
-		$data = $this->user_model->get_user_info($src, $us_id, $token);
-		if (strlen($data) > 0){
-			$arr_users = explode("&", $data);
-			$str_username = $arr_users[1];
-			$arr_username = explode("=", $str_username);
-			return $arr_username[1];
-		}else
-		{
-			return "";
-		}
-
-	}
-
-    public function addPaidlog() {
-        $result['success'] = 0;
-        $result = array();
-        $input = $this->input->post();
-        $this->load->model('paidlog_model');
-        if (strlen($input['sms_content'])==0)
-        {
-            $result['errors'][]="Ná»i dung tin nháº¯n khÃŽng ÄÆ°á»£c Äá» trá»ng";
-        }
-        if (strlen($input['sms_reply'])==0)
-        {
-            $result['errors'][]="Tin nháº¯n tráº£ vá» khÃŽng ÄÆ°á»£c Äá» trá»ng";
-        }
-        else
-        {
-            /*
-            if ($this->paidlog_model->isExist(array('field'=>'login_name','value'=>$input['login_name'],'id'=>$input['id'])))
-            {
-                $result['errors'][]="TÃªn ÄÄng nháº­p ÄÃ£ ÄÆ°á»£c sá»­ dá»¥ng";
-            }
-             * 
-             */
-        }
-        if (strlen($input['service_id'])==0)
-        {
-            $result['errors'][]="MÃ£ dá»ch vá»¥ khÃŽng ÄÆ°á»£c Äá» trá»ng";
-        }
-        else
-        {
-            /*
-            if ($this->paidlog_model->isExist(array('field'=>'cellphone','value'=>$input['cellphone'],'id'=>$input['id'])))
-            {
-                $result['errors'][]="Sá» Äiá»n thoáº¡i ÄÃ£ ÄÆ°á»£c sá»­ dá»¥ng";
-            }
-             * 
-             */
-        }
-        if (!isset($result['errors']))
-        {
+
+    public function get_username($us_id) {
+        $src = 'violet';
+        $token = md5($us_id . self::TOKENPW);
+        $this->load->model('user_model');
+        $data = $this->user_model->get_user_info($src, $us_id, $token);
+        if (strlen($data) > 0) {
+            $arr_users = explode("&", $data);
+            $str_username = $arr_users[1];
+            $arr_username = explode("=", $str_username);
+            return $arr_username[1];
+        } else {
+            return "";
+        }
+    }
+
+    public function test() {
+
+
+        for ($i = 1; $i <= 5000; $i++) {
+            $input['us_id'] = rand(1, 100);
+            $input['paid_type'] = rand(1, 2);
+            $input['amount'] = rand(3, 10) * 1000;
+            $time = (rand((time() - (12 * 30 * 24 * 60 * 60)), time()));
+            $input['paid_time'] = date("Y-m-d H:i:s", $time);
             $this->load->model('paidlog_model');
             $this->paidlog_model->insert($input);
-            $result['success'] = 1;
-        }
-
-        
-        echo json_encode($result);
-    }
-    public function viewSms()
-    {
-        $id=$this->uri->segment(4);
-        $this->load->model('paidlog_model');
-        $data=$this->paidlog_model->getPaidlog($id);
-        $this->load->view('report/viewSms',$data);
-    }
-    public function editSms()
-    {
-        $id=$this->uri->segment(4);
-        $this->load->model('paidlog_model');
-        $data=$this->paidlog_model->getPaidlog($id);
-        $this->load->view('report/editSms',$data);
-    }
-    public function dodeleteSms()
-    {
-        $input=$this->input->post();
-        $id=$input['sms_id'];
-        $this->load->model('paidlog_model');
-        $data=$this->paidlog_model->delete($id);
-        $result['success']=1;
-        echo json_encode($result);
-    }
-    public function deleteSms()
-    {
-        $id=$this->uri->segment(4);
-        $this->load->model('paidlog_model');
-        $data=$this->paidlog_model->getPaidlog($id);
-        $this->load->view('report/deleteSms',$data);
-    }
-    public function updateSms()
-    {
-       
-        $input=  $this->input->post();
-        $this->load->model('paidlog_model');
-        if (strlen($input['sms_content'])==0)
-        {
-            $result['errors'][]="Ná»i dung tin nháº¯n khÃŽng ÄÆ°á»£c Äá» trá»ng";
-        }
-        if (strlen($input['sms_reply'])==0)
-        {
-            $result['errors'][]="Tin nháº¯n tráº£ vá» khÃŽng ÄÆ°á»£c Äá» trá»ng";
-        }
-        else
-        {
-            /*
-            if ($this->paidlog_model->isExist(array('field'=>'login_name','value'=>$input['login_name'],'id'=>$input['id'])))
-            {
-                $result['errors'][]="TÃªn ÄÄng nháº­p ÄÃ£ ÄÆ°á»£c sá»­ dá»¥ng";
-            }
-             * 
-             */
-        }
-        if (strlen($input['service_id'])==0)
-        {
-            $result['errors'][]="MÃ£ dá»ch vá»¥ khÃŽng ÄÆ°á»£c Äá» trá»ng";
-        }
-        else
-        {
-            /*
-            if ($this->paidlog_model->isExist(array('field'=>'cellphone','value'=>$input['cellphone'],'id'=>$input['id'])))
-            {
-                $result['errors'][]="Sá» Äiá»n thoáº¡i ÄÃ£ ÄÆ°á»£c sá»­ dá»¥ng";
-            }
-             * 
-             */
-        }
-        
-        if (!isset($result['errors']))
-        { 
-            $this->load->model('paidlog_model');
-            $this->paidlog_model->update($input['sms_id'],$input);
-            $result['success'] = 1;
-        }
-        echo json_encode($result);
-    }
-    public function test() {
-        
-      
-        for ($i = 1; $i <= 5000; $i++) {
-            $input['us_id']=rand(1,100);
-            $input['paid_type']=rand(1,2);
-            $input['amount']=rand(3,10)*1000;
-            $time=(rand((time()-(12*30*24*60*60)),time()));
-            $input['paid_time']= date("Y-m-d H:i:s",$time);
-            $this->load->model('paidlog_model');
-            $this->paidlog_model->insert($input);
-        }
-        
-       die(); 
-      
+        }
+
+        die();
+
         for ($i = 1; $i <= 100; $i++) {
-            $input['us_id']=$i;
-            $input['cellphone']="01234567".(100+$i);
-            $input['collaborator']=rand(1,100);
-            $input['acc_balanced']=rand(100000,1000000);
-            $input['expire_date']=date("Y-m-d H:i:s",time());
-            $input['created_time']=date("Y-m-d H:i:s",time());
-            $input['updated_time']=date("Y-m-d H:i:s",time());
+            $input['us_id'] = $i;
+            $input['cellphone'] = "01234567" . (100 + $i);
+            $input['collaborator'] = rand(1, 100);
+            $input['acc_balanced'] = rand(100000, 1000000);
+            $input['expire_date'] = date("Y-m-d H:i:s", time());
+            $input['created_time'] = date("Y-m-d H:i:s", time());
+            $input['updated_time'] = date("Y-m-d H:i:s", time());
             $this->load->model('user_model');
             $this->user_model->insert($input);
Index: pro-violet-viettel/sourcecode/application/modules/admin/models/paidlog_model.php
===================================================================
--- pro-violet-viettel/sourcecode/application/modules/admin/models/paidlog_model.php	(revision 443)
+++ pro-violet-viettel/sourcecode/application/modules/admin/models/paidlog_model.php	(revision 444)
@@ -34,18 +34,5 @@
     }
 
-    function isExist($data) {
-        $sql = "SELECT COUNT(id) as total FROM " . $this->table_name . " WHERE " . $data['field'] . " = '" . $data['value'] . "'";
-        if (isset($data['id']))
-        {
-            $id=$data['id'];
-            $sql.=" AND id <> ".$id." LIMIT 1";
-        }
-        $result = $this->db->query($sql)->row_array();
-        if ($result['total'] == 1) {
-            return true;
-        } else {
-            return false;
-        }
-    }
+
 
     function countPaidlog($data) {
Index: pro-violet-viettel/sourcecode/application/modules/admin/models/user_model.php
===================================================================
--- pro-violet-viettel/sourcecode/application/modules/admin/models/user_model.php	(revision 443)
+++ pro-violet-viettel/sourcecode/application/modules/admin/models/user_model.php	(revision 444)
@@ -68,5 +68,5 @@
 	{
 		$data = $this->vservices->actionExecute('getinfo', array('src' => $src, 'us_id' => $us_id, 'token'=>$token), 'user');
-		return $data;
+                return $data;
 	}
 }
Index: pro-violet-viettel/sourcecode/application/modules/admin/views/report/index.php
===================================================================
--- pro-violet-viettel/sourcecode/application/modules/admin/views/report/index.php	(revision 443)
+++ pro-violet-viettel/sourcecode/application/modules/admin/views/report/index.php	(revision 444)
@@ -76,4 +76,28 @@
 
 
+
+				$('#sales-charts').css({'width':'100%' , 'height':'200px'});
+				$.plot("#sales-charts", <?php echo json_encode($chard) ?>, {
+					hoverable: true,
+					shadowSize: 0,
+					series: {
+						lines: { show: true },
+						points: { show: true }
+					},
+					xaxis: {
+						tickLength: 0
+					},
+					yaxis: {
+						ticks: 10,
+						min: 0,
+						max:<?php echo $max;?>,
+						tickDecimals: 0
+					},
+					grid: {
+						backgroundColor: { colors: [ "#fff", "#fff" ] },
+						borderWidth: 1,
+						borderColor:'#555'
+					}
+				});
     }
 
@@ -120,4 +144,5 @@
 			}
 		</style>
+             
 <div class="main-content" >
     <div id="breadcrumbs" class="breadcrumbs">
@@ -268,4 +293,4 @@
 </div><!-- /.modal-dialog -->
 <?php
-$this->load->view('layout/admin/footer', array('base_url' => $base_url, 'adminjs' => array('assets/js/admin/smstemplate.js')));
+$this->load->view('layout/admin/footer', array('base_url' => $base_url, 'adminjs' => array('assets/js/admin/report.js')));
 ?>
Index: pro-violet-viettel/sourcecode/application/modules/admin/views/report/listview.php
===================================================================
--- pro-violet-viettel/sourcecode/application/modules/admin/views/report/listview.php	(revision 443)
+++ pro-violet-viettel/sourcecode/application/modules/admin/views/report/listview.php	(revision 444)
@@ -5,10 +5,7 @@
             <!-- PAGE CONTENT BEGINS -->
             <div style="padding-bottom:4px" class="table-header">
-                Tin nháº¯n
+                Thá»ng kÃª
 
-                <button href="#addSms" data-toggle="modal" class="btn btn-success pull-right">
-                    <i class="icon-plus"></i>
-                    ThÃªm tin nháº¯n
-                </button>
+              
 
             </div>
@@ -75,5 +72,5 @@
                                 <td class=" "><?php echo $paidlog['cellphone']?></td>
                                 
-                                <td class="hidden-480 "><?php echo $paidlog['amount']?></td>
+                                <td class="hidden-480 "><?php echo number_format($paidlog['amount'],0);?></td>
                                 <td class="hidden-480 "><?php if ($paidlog['paid_type']==1) {echo "SMS";} else { echo "Card";}?></td>
                                 <td class=" "><?php echo $paidlog['paid_time']?></td>
Index: pro-violet-viettel/sourcecode/application/modules/admin/views/report/statistics.php
===================================================================
--- pro-violet-viettel/sourcecode/application/modules/admin/views/report/statistics.php	(revision 443)
+++ pro-violet-viettel/sourcecode/application/modules/admin/views/report/statistics.php	(revision 444)
@@ -29,5 +29,5 @@
                                 <td>Tuáº§n trÆ°á»c</td>
                                 <td>
-                                    <?php echo $revenue['last_week'];?>
+                                    <?php echo number_format($revenue['last_week'],0); ?>
                                 </td>
                             </tr>
@@ -35,5 +35,5 @@
                                 <td>ThÃ¡ng trÆ°á»c</td>
                                 <td>
-                                    <?php echo $revenue['last_month'];?>
+                                    <?php echo number_format($revenue['last_month'],0); ?>
                                 </td>
                             </tr>
@@ -41,5 +41,5 @@
                                 <td>QuÃœ trÆ°á»c</td>
                                 <td>
-                                    <?php echo $revenue['last_quarter'];?>
+                                    <?php echo number_format($revenue['last_quarter'],0); ?>
                                 </td>
                             </tr>
@@ -47,5 +47,5 @@
                                 <td>NÄm trÆ°á»c</td>
                                 <td>
-                                    <?php echo $revenue['last_year'];?>
+                                    <?php  echo number_format($revenue['last_year'],0); ?>
                                 </td>
                             </tr>
@@ -71,10 +71,11 @@
                 </div>
             </div>
-
+            
             <div class="widget-body">
                 <div class="widget-main padding-4">
-                    <div id="sales-charts" style="width: 100%; height: 200px; padding: 0px; position: relative;"><canvas class="flot-base" style="direction: ltr; position: absolute; left: 0px; top: 0px; width: 534px; height: 200px;" width="534" height="200"></canvas><div class="flot-text" style="position: absolute; top: 0px; left: 0px; bottom: 0px; right: 0px; font-size: smaller; color: rgb(84, 84, 84);"><div class="flot-x-axis flot-x1-axis xAxis x1Axis" style="position: absolute; top: 0px; left: 0px; bottom: 0px; right: 0px; display: block;"><div style="position: absolute; max-width: 76px; top: 184px; left: 29px; text-align: center;" class="flot-tick-label tickLabel">0.0</div><div style="position: absolute; max-width: 76px; top: 184px; left: 110px; text-align: center;" class="flot-tick-label tickLabel">1.0</div><div style="position: absolute; max-width: 76px; top: 184px; left: 192px; text-align: center;" class="flot-tick-label tickLabel">2.0</div><div style="position: absolute; max-width: 76px; top: 184px; left: 274px; text-align: center;" class="flot-tick-label tickLabel">3.0</div><div style="position: absolute; max-width: 76px; top: 184px; left: 355px; text-align: center;" class="flot-tick-label tickLabel">4.0</div><div style="position: absolute; max-width: 76px; top: 184px; left: 437px; text-align: center;" class="flot-tick-label tickLabel">5.0</div><div style="position: absolute; max-width: 76px; top: 184px; left: 519px; text-align: center;" class="flot-tick-label tickLabel">6.0</div></div><div class="flot-y-axis flot-y1-axis yAxis y1Axis" style="position: absolute; top: 0px; left: 0px; bottom: 0px; right: 0px; display: block;"><div style="position: absolute; top: 172px; left: 1px; text-align: right;" class="flot-tick-label tickLabel">-2.000</div><div style="position: absolute; top: 150px; left: 1px; text-align: right;" class="flot-tick-label tickLabel">-1.500</div><div style="position: absolute; top: 129px; left: 1px; text-align: right;" class="flot-tick-label tickLabel">-1.000</div><div style="position: absolute; top: 107px; left: 1px; text-align: right;" class="flot-tick-label tickLabel">-0.500</div><div style="position: absolute; top: 86px; left: 4px; text-align: right;" class="flot-tick-label tickLabel">0.000</div><div style="position: absolute; top: 65px; left: 4px; text-align: right;" class="flot-tick-label tickLabel">0.500</div><div style="position: absolute; top: 43px; left: 4px; text-align: right;" class="flot-tick-label tickLabel">1.000</div><div style="position: absolute; top: 22px; left: 4px; text-align: right;" class="flot-tick-label tickLabel">1.500</div><div style="position: absolute; top: 1px; left: 4px; text-align: right;" class="flot-tick-label tickLabel">2.000</div></div></div><canvas class="flot-overlay" style="direction: ltr; position: absolute; left: 0px; top: 0px; width: 534px; height: 200px;" width="534" height="200"></canvas><div class="legend"><div style="position: absolute; width: 86px; height: 66px; top: 13px; right: 13px; background-color: rgb(255, 255, 255); opacity: 0.85;"> </div><table style="position:absolute;top:13px;right:13px;;font-size:smaller;color:#545454"><tbody><tr><td class="legendColorBox"><div style="border:1px solid #ccc;padding:1px"><div style="width:4px;height:0;border:5px solid #1abc9c;overflow:hidden"></div></div></td><td class="legendLabel">SMS</td></tr><tr><td class="legendColorBox"><div style="border:1px solid #ccc;padding:1px"><div style="width:4px;height:0;border:5px solid #e67e22;overflow:hidden"></div></div></td><td class="legendLabel">Tháº» cÃ o</td></tr><tr><td class="legendColorBox"><div style="border:1px solid #ccc;padding:1px"><div style="width:4px;height:0;border:5px solid #3498db;overflow:hidden"></div></div></td><td class="legendLabel">Cá»ng tÃ¡c viÃªn</td></tr></tbody></table></div></div>
+                    <div id="sales-charts"></div>
                 </div><!-- /widget-main -->
-            </div><!-- /widget-body -->
+            </div>
+            
         </div><!-- /widget-box -->
     </div>
@@ -86,2 +87,6 @@
     <!-- PAGE CONTENT ENDS -->
 </div>
+<script type="text/javascript">
+
+
+</script>
