public function before() { parent::before(); $action = $this->request->action(); if ($action == 'index') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('advertise', $user_action); } } if ($action == 'add') { Common::getUserRight('advertise', 'sadd'); } if ($action == 'edit') { Common::getUserRight('advertise', 'smodify'); } if ($action == 'ajax_save') { Common::getUserRight('advertise', 'smodify'); } $this->assign('cmsurl', URL::site()); $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'index') { Common::getUserRight('footernav', 'slook'); } if ($action == 'addnav') { Common::getUserRight('footernav', 'sadd'); } if ($action == 'editnav') { Common::getUserRight('footernav', 'smodify'); } if ($action == 'ajax_del') { Common::getUserRight('footernav', 'sdelete'); } if ($action == 'ajax_savefooternav') { Common::getUserRight('footernav', 'sdelete'); } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->parentkey = $this->params['parentkey']; $this->itemid = $this->params['itemid']; $weblist = Common::getWebList(); $this->assign('weblist', $weblist); $this->assign('helpico', Common::getIco('help')); $this->model = new Model_FooterNav(); }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'store') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('module', $user_action); } } if ($action == 'index') { Common::getUserRight('module', 'slook'); } if ($action == 'list') { Common::getUserRight('module', 'slook'); } if ($action == 'add') { Common::getUserRight('module', 'smodify'); } if ($action == 'ajax_add_save' || $action == 'ajax_edit_save') { Common::getUserRight('module', 'smodify'); } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $weblist = Common::getWebList(); $this->assign('weblist', $weblist); }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'index') { Common::getUserRight('site', 'slook'); } if ($action == 'add') { Common::getUserRight('site', 'sadd'); } if ($action == 'ajax_addsave') { Common::getUserRight('site', 'smodify'); } if ($action == 'ajax_editsave') { Common::getUserRight('site', 'smodify'); } if ($action == 'ajax_del') { Common::getUserRight('site', 'smodify'); } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->parentkey = $this->params['parentkey']; $this->itemid = $this->params['itemid']; $weblist = Common::getWebList(); $this->assign('weblist', $weblist); $this->assign('helpico', Common::getIco('help')); }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'article') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('article', $user_action); } } else { if ($action == 'add') { Common::getUserRight('article', 'sadd'); } else { if ($action == 'edit') { Common::getUserRight('article', 'smodify'); } else { if ($action == 'ajax_save') { Common::getUserRight('article', 'smodify'); } } } } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); $this->assign('templetlist', Common::getUserTemplteList('article_show')); //获取上传的用户模板 }
public function before() { parent::before(); //$this->request->controller, $action = $this->request->action(); if ($action == 'line') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('line', $user_action); } } else { if ($action == 'add') { Common::getUserRight('line', 'sadd'); } else { if ($action == 'edit') { Common::getUserRight('line', 'smodify'); } else { if ($action == 'day') { $param = $this->params['action']; $right = array('add' => 'slook', 'save' => 'smodify', 'del' => 'sdelete'); $user_action = $right[$param] ? $right[$param] : 'slook'; if (!empty($user_action)) { Common::getUserRight('lineday', $user_action); } } else { if ($action == 'price') { $param = $this->params['action']; $right = array('add' => 'slook', 'save' => 'smodify', 'del' => 'sdelete'); $user_action = $right[$param] ? $right[$param] : 'slook'; if (!empty($user_action)) { Common::getUserRight('lineprice', $user_action); } } else { if ($action == 'content') { $param = $this->params['action']; $right = array('save' => 'smodify'); $user_action = $right[$param] ? $right[$param] : 'slook'; if (!empty($user_action)) { Common::getUserRight('linejieshao', $user_action); } } else { if ($action == 'ajax_linesave') { Common::getUserRight('line', 'smodify'); } } } } } } } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); $this->assign('sysjiaotong', $this->jiaotong); //交通 $this->assign('templetlist', Common::getUserTemplteList('line_show')); }
public function before() { parent::before(); $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); $this->basefolder = BASEPATH . '/templets/smore/uploadtemplets/'; }
public function before() { parent::before(); Common::getUserRight('exchange', 'smodify'); $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); }
public function before() { parent::before(); Common::getUserRight('databack', 'smodify'); $this->assign('cmsurl', URL::site()); $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); }
/** * 图片首页 */ public function action_index() { global $cfg_public_url; $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->parentkey = $this->params['parentkey']; $this->itemid = $this->params['itemid']; $weblist = Common::getWebList(); $this->assign('weblist', $weblist); $this->assign('pulic', $cfg_public_url); $this->display('stourtravel/image/index'); }
public function before() { parent::before(); $session = Session::instance(); $roleid = $session->get('roleid'); if ($roleid != 1) { exit(__('onlysys')); } $this->assign('cmsurl', URL::site()); $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); }
public function before() { parent::before(); $action = $this->request->action(); Common::getUserRight('kefu', 'smodify'); $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->parentkey = $this->params['parentkey']; $this->itemid = $this->params['itemid']; $weblist = Common::getWebList(); $this->assign('weblist', $weblist); $this->assign('helpico', Common::getIco('help')); }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'car') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('car', $user_action); } } else { if ($action == 'add') { Common::getUserRight('car', 'sadd'); } else { if ($action == 'edit') { Common::getUserRight('car', 'smodify'); } else { if ($action == 'kind') { $param = $this->params['action']; $right = array('add' => 'sadd', 'save' => 'smodify', 'del' => 'sdelete'); $user_action = $right[$param] ? $right[$param] : 'slook'; if (!empty($user_action)) { Common::getUserRight('cartype', $user_action); } } else { if ($action == 'price') { $param = $this->params['action']; $right = array('add' => 'sadd', 'save' => 'smodify', 'del' => 'sdelete'); $user_action = $right[$param] ? $right[$param] : 'slook'; if (!empty($user_action)) { Common::getUserRight('carprice', $user_action); } } else { if ($action == 'ajax_carsave') { Common::getUserRight('car', 'smodify'); } } } } } } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); $this->assign('carkindidlist', ORM::factory('car_kind')->where('webid=0')->get_all()); $this->assign('templetlist', Common::getUserTemplteList('car_show')); //获取上传的用户模板 }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'list') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('help', $user_action); } } else { if ($action == 'add') { Common::getUserRight('help', 'sadd'); } else { if ($action == 'edit') { Common::getUserRight('help', 'smodify'); } else { if ($action == 'ajax_save') { Common::getUserRight('help', 'smodify'); } else { if ($action == 'kind') { $op = $this->params['action']; if ($op == 'add') { Common::getUserRight('helpattr', 'sadd'); } else { if ($op == 'save') { Common::getUserRight('helpattr', 'smodify'); } else { if ($op == 'del') { Common::getUserRight('helpattr', 'sdelete'); } else { Common::getUserRight('helpattr', 'slook'); } } } } } } } } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); $allmodule = ORM::factory('Model')->get_all(); foreach ($allmodule as $item) { $this->type_arr[$item['id']] = $item['modulename']; } }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'list') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('ticket', $user_action); } } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); }
public function before() { parent::before(); $action = $this->request->action(); /*if($action == 'article') { $param = $this->params['action']; $right = array( 'read'=>'slook', 'save'=>'smodify', 'delete'=>'sdelete', 'update'=>'smodify' ); $user_action = $right[$param]; if(!empty($user_action)) Common::getUserRight('article',$user_action); } else if($action == 'add') { Common::getUserRight('article','sadd'); } else if($action == 'edit') { Common::getUserRight('article','smodify'); } else if($action == 'ajax_save') { Common::getUserRight('article','smodify'); }*/ $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); $this->addmodule = ORM::factory('model')->where("id>13")->get_all(); $this->typeid = $this->params['typeid']; $this->modulename = Model_Model::getModuleName($this->typeid); $this->assign('typeid', $this->typeid); $this->assign('modulename', $this->modulename); foreach (self::$kind as $key => $row) { self::$kind[$key]['url'] = str_replace('{#typeid#}', $this->typeid, $row['url']); self::$kind[$key]['itemid'] = str_replace('{#typeid#}', $this->typeid, $row['itemid']); } }
public function action_index() { $type = $this->params['type']; //站点 if ($type == 'weblist') { $this->assign('weblist', Common::getWebList()); } //出发地 if ($type == 'startplace') { $this->assign('startplace', ORM::factory('startplace')->where('pid=0 and isopen=1')->get_all()); } //目的地 if ($type == 'destlist') { $this->assign('destlist', ORM::factory('destinations')->where('pid=0 and isopen=1')->get_all()); } //属性 if ($type == 'attrlist') { $typeid = $this->params['typeid']; $this->assign('typeid', $typeid); $this->assign('attrlist', Model_Attrlist::getAttr($typeid)); } //车辆类型 if ($type == 'carkind') { $this->assign('carkindlist', ORM::factory('car_kind')->get_all()); } //车辆品牌 if ($type == 'carbrand') { $this->assign('carbrandlist', ORM::factory('car_brand')->get_all()); } //签证类型 if ($type == 'visatype') { $this->assign('visakindlist', ORM::factory('visa_kind')->get_all()); } //签发城市 if ($type == 'visacity') { $this->assign('visacitylist', ORM::factory('visa_city')->get_all()); } //帮助分类 if ($type == 'helpkind') { $this->assign('helpkindlist', ORM::factory('help_kind')->get_all()); } $this->assign('type', $type); $this->display('stourtravel/box/index'); }
{php echo Common::getScript('jquery-1.8.3.min.js,common.js,jquery.hotkeys.js,msgbox/msgbox.js,extjs/ext-all.js,extjs/locale/ext-lang-zh_CN.js'); } {php echo Common::getCss('msgbox.css','js/msgbox'); } {php echo Common::getCss('common.css')} {php echo Common::getCss('ext-theme-neptune-all-debug.css','js/extjs/resources/ext-theme-neptune'); } <script> window.SITEURL = "{php echo URL::site();}"; window.PUBLICURL ="{$GLOBALS['cfg_public_url']}"; window.BASEHOST="{$GLOBALS['cfg_basehost']}"; window.WEBLIST = <?php echo json_encode(array_merge(array(array('webid' => 0, 'webname' => '主站')), Common::getWebList())); ?> //网站信息数组 $(function(){ $.hotkeys.add('f', function(){parent.window.showIndex(); }); $(document).click(function(e) { try{ parent.barmenu.close(); }catch(e) { } }); }) </script>
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'visa') { $param = $this->params['action']; $right = array('read' => 'slook', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('visa', $user_action); } } else { if ($action == 'add') { Common::getUserRight('visa', 'sadd'); } else { if ($action == 'edit') { Common::getUserRight('visa', 'smodify'); } else { if ($action == 'ajax_save') { Common::getUserRight('visa', 'smodify'); } else { if ($action == 'ajax_visatype_list') { Common::getUserRight('visatype', 'slook'); } else { if ($action == 'ajax_visatype_save') { Common::getUserRight('visatype', 'smodify'); } else { if ($action == 'ajax_visatype_del') { Common::getUserRight('visatype', 'sdelete'); } else { if ($action == 'ajax_visacity_list') { Common::getUserRight('visacity', 'slook'); } else { if ($action == 'ajax_visacity_save') { Common::getUserRight('visacity', 'smodify'); } else { if ($action == 'ajax_visacity_del') { Common::getUserRight('visacity', 'sdelete'); } else { if ($action == 'ajax_visacity_add') { Common::getUserRight('visacity', 'sadd'); } else { if ($action == 'visaarea') { $param = $this->params['action']; $right = array('read' => 'slook', 'addsub' => 'sadd', 'save' => 'smodify', 'delete' => 'sdelete', 'update' => 'smodify'); $user_action = $right[$param]; if (!empty($user_action)) { Common::getUserRight('visaarea', $user_action); } } } } } } } } } } } } } $arealist = ORM::factory('visa_area')->where('pid', '=', 0)->get_all(); $visatypelist = ORM::factory('visa_kind')->get_all(); $citylist = ORM::factory('visa_city')->get_all(); $this->assign('arealist', $arealist); $this->assign('visatypelist', $visatypelist); $this->assign('citylist', $citylist); $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->assign('weblist', Common::getWebList()); $this->assign('templetlist', Common::getUserTemplteList('visa_show')); //获取上传的用户模板 }
public function action_dialog_addlink() { $weblist = Common::getWebList(); $this->assign('weblist', $weblist); $this->display('stourtravel/friendlink/dialog_addlink'); }
public function before() { parent::before(); $action = $this->request->action(); if ($action == 'base') { Common::getUserRight('index', 'smodify'); } if ($action == 'mainnav') { Common::getUserRight('nav', 'slook'); } if ($action == 'addnav') { Common::getUserRight('nav', 'sadd'); } if ($action == 'ajax_addnavsave') { Common::getUserRight('nav', 'smodify'); } if ($action == 'ajax_delnav') { Common::getUserRight('nav', 'sdelete'); } if ($action == 'footer') { Common::getUserRight('nav', 'smodify'); } if ($action == 'logo') { Common::getUserRight('logo', 'smodify'); } if ($action == 'nopic') { Common::getUserRight('nophoto', 'smodify'); } if ($action == 'wx') { Common::getUserRight('weibo', 'smodify'); } if ($action == 'payment') { Common::getUserRight('payment', 'smodify'); } if ($action == 'payment') { Common::getUserRight('payment', 'smodify'); } if ($action == 'ordermail') { Common::getUserRight('ordermail', 'smodify'); } if ($action == 'thirdpart') { Common::getUserRight('thirdpart', 'smodify'); } if ($action == 'watermark') { Common::getUserRight('water', 'smodify'); } if ($action == 'tongji') { Common::getUserRight('tongji', 'smodify'); } if ($action == 'robots') { Common::getUserRight('robots', 'smodify'); } if ($action == 'gonggao') { Common::getUserRight('gonggao', 'smodify'); } if ($action == 'syspara') { Common::getUserRight('sys', 'smodify'); } if ($action == 'payset') { Common::getUserRight('pay', 'smodify'); } if ($action == 'ucenter') { Common::getUserRight('ucenter', 'smodify'); } if ($action == 'webico') { Common::getUserRight('webico', 'smodify'); } if ($action == 'mailport') { Common::getUserRight('mailport', 'smodify'); } $this->assign('parentkey', $this->params['parentkey']); $this->assign('itemid', $this->params['itemid']); $this->parentkey = $this->params['parentkey']; $this->itemid = $this->params['itemid']; $weblist = Common::getWebList(); $this->assign('weblist', $weblist); $this->assign('helpico', Common::getIco('help')); }