public function process() { parent::process(); $type = $this->type; $swhere = parent::getSearchWhere(); //if not admin, add date condition /* if(self::$cookie -> RoleID <= 3 ){ $swhere.= ($swhere=='')?'':" AND "; $swhere.= " (CURDATE() BETWEEN A.`StaDate` AND A.`EndDate`) "; }*/ $promotionCount = Promotion::getPromotionCount($type, $swhere); $this->pagination($promotionCount); $promotionList = Promotion::getPromotionList($type, $swhere, $this->p, $this->n); self::$smarty->assign("listData", $promotionList); self::$smarty->assign("areaList", Tools::getJapanAreas()); self::$smarty->assign("count", $promotionCount); }