Beispiel #1
0
 public function view_batchCountriesSmallImport()
 {
     $data = CountriesSmallAct::actBatchCountriesSmallImport();
     $this->smarty->assign('title', '小语种国家批量导入');
     $this->smarty->assign('errMsg', $data['res']);
     $this->smarty->display('countriesSmallImport.htm');
 }
 /**
  * CountriesSmallAct::act_delCountriesSmall()
  * 删除小语种国家
  * @param int $id 小语种国家ID
  * @return  bool
  */
 public function act_delCountriesSmall()
 {
     $id = isset($_POST["id"]) ? intval(trim($_POST["id"])) : 0;
     $act = isset($_REQUEST["act"]) ? post_check($_REQUEST["act"]) : "";
     $mod = isset($_REQUEST["mod"]) ? post_check($_REQUEST["mod"]) : "";
     if (!AuthUser::checkLogin($mod, $act)) {
         self::$errCode = 10001;
         self::$errMsg = "对不起,您无数据删除权限!";
         return false;
     }
     if (empty($id) || !is_numeric($id)) {
         self::$errCode = 10000;
         self::$errMsg = "小语种国家ID有误!" . $id;
         return false;
     }
     $res = CountriesSmallModel::delCountriesSmall($id);
     self::$errCode = CountriesSmallModel::$errCode;
     self::$errMsg = CountriesSmallModel::$errMsg;
     return $res;
 }