示例#1
0
 public static function getTableInstance()
 {
     if (!self::$_table) {
         self::$_table = new Model_Table_EpcgExportInfo();
     }
     return self::$_table;
 }
示例#2
0
 public function getAllEpcgAction()
 {
     $response = array();
     $this->_helper->viewRenderer->setNoRender(true);
     $this->_helper->layout->disableLayout();
     if ($this->getRequest()->getParam('iec_id') != null) {
         $iec_id = $this->getRequest()->getParam('iec_id');
         $epcg_list = Model_EpcgExportInfo::getAllEpcgByIecNo($iec_id);
         if (!empty($epcg_list)) {
             $response['status'] = 1;
             $response['message'] = $epcg_list;
         } else {
             $response['status'] = 2;
             $response['message'] = 'No data found';
         }
     } else {
         $response['status'] = 0;
         $response['message'] = 'No parameters passed';
     }
     echo json_encode($response);
 }