コード例 #1
0
 function __construct()
 {
     global $lC_Language, $lC_MessageStack;
     $this->_page_title = $lC_Language->get('heading_title');
     if (!isset($_GET['action'])) {
         $_GET['action'] = '';
     }
     // check if the graphs directory exists
     $_SESSION['errArr'] = array();
     if (!empty($_GET['action']) && !$_SESSION['error']) {
         switch ($_GET['action']) {
             case 'save':
                 //echo '<pre>';print_r($_POST);exit;
                 $shipping_name = serialize($_POST['ups']);
                 $data = array('title' => $_POST['title'], 'shipping_name' => $shipping_name);
                 /*
                  * Save the banner information
                  *
                  * @param integer $_GET['bid'] The banner id
                  * @param array $data The banner information
                  * @access public
                  * @return boolean
                  */
                 if (lC_Restrict_shipping_Admin::save(isset($_GET['bid']) && is_numeric($_GET['bid']) ? $_GET['bid'] : null, $data)) {
                     lc_redirect_admin(lc_href_link_admin(FILENAME_DEFAULT, $this->_module));
                 } else {
                     $_SESSION['error'] = true;
                     $_SESSION['errmsg'] = $lC_Language->get('ms_error_action_not_performed');
                 }
                 break;
         }
     }
 }
コード例 #2
0
ファイル: rpc.php プロジェクト: rajeshb001/itpl_loaded7
 public static function getStats()
 {
     $result = lC_Restrict_shipping_Admin::stats($_GET['bid'], $_GET['type'], $_GET['month'], $_GET['year']);
     $result['rpcStatus'] = RPC_STATUS_SUCCESS;
     echo json_encode($result);
 }
コード例 #3
0
 public static function batchDelete($batch)
 {
     foreach ($batch as $id) {
         lC_Restrict_shipping_Admin::delete($id);
     }
     return true;
 }