tpl_page_category = 'postage'; $this->tpl_title = '配送業者の送料詳細'; } /** * Page のプロセス. * * @return void */ function process() { parent::process(); $this->action(); $this->sendResponse(); } /** * Page のアクション. * * @return void */ function action() { $this->setTemplate($this->tpl_mainpage = 'postage/postage.tpl'); $objQuery =SC_Query_Ex::getSingletonInstance(); $this->arrRet = array(); $this->arrRetPref1 = array(); $this->arrRetFee1 = array(); $this->arrRetPref2 = array(); $this->arrRetFee2 = array(); $this->arrRetPref3 = array(); $this->arrRetFee3 = array(); // $devname = $_GET['devname']; //配送業者を取得 $arrRet = $objQuery->select("*", "dtb_deliv", "deliv_id = $devname"); //データベースからデータの取得ができたか if(isset($arrRet)){ $this->arrRet = $arrRet[0]; } //県名を取得 $arrRetPref1 = $objQuery->select("*", "mtb_pref", "id between 1 and 14"); $arrRetPref2 = $objQuery->select("*", "mtb_pref", "id between 15 and 30"); $arrRetPref3 = $objQuery->select("*", "mtb_pref", "id between 31 and 47"); //データベースからデータの取得ができたか if(isset($arrRet)){ $this->arrRetPref1 = $arrRetPref1; } if(isset($arrRet)){ $this->arrRetPref2 = $arrRetPref2; } if(isset($arrRet)){ $this->arrRetPref3 = $arrRetPref3; } //送料を取得 $arrRetFee1 = $objQuery->select("*", "dtb_delivfee", "deliv_id = $devname and pref between 1 and 14"); $arrRetFee2 = $objQuery->select("*", "dtb_delivfee", "deliv_id = $devname and pref between 15 and 30"); $arrRetFee3 = $objQuery->select("*", "dtb_delivfee", "deliv_id = $devname and pref between 31 and 47"); //データベースからデータの取得ができたか if(isset($arrRet)){ $this->arrRetFee1 = $arrRetFee1; } if(isset($arrRet)){ $this->arrRetFee2 = $arrRetFee2; } if(isset($arrRet)){ $this->arrRetFee3 = $arrRetFee3; } } /** * デストラクタ. * * @return void */ function destroy() { parent::destroy(); } } ?>