SellerEditablePage.php 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541
  1. <?php
  2. namespace app\home\controller;
  3. use think\facade\View;
  4. use think\facade\Lang;
  5. use think\facade\Db;
  6. /**
  7. * ============================================================================
  8. *
  9. * ============================================================================
  10. * 版权所有 2014-2028 浙江惠利玛产业互联网有限公司,并保留所有权利。
  11. * 网站地址: https://www.valimart.net/
  12. * ----------------------------------------------------------------------------
  13. *
  14. * ============================================================================
  15. * 控制器
  16. */
  17. class SellerEditablePage extends BaseSeller {
  18. var $type = 'pc';
  19. var $model_dir = 'home@default/base/editable_page_model/';
  20. public function initialize() {
  21. parent::initialize();
  22. Lang::load(base_path() . 'home/lang/' . config('lang.default_lang') . '/seller_editable_page.lang.php');
  23. Lang::load(base_path() . 'admin/lang/' . config('lang.default_lang') . '.php');
  24. }
  25. public function page_list($type = 'pc') {
  26. $this->type = $type;
  27. $keyword = input('param.editable_page_name');
  28. $condition = array();
  29. if ($keyword) {
  30. $condition[]=array('editable_page_name','like', '%' . $keyword . '%');
  31. }
  32. View::assign('filtered', empty($condition) ? 0 : 1);
  33. if (!in_array($type, array('pc', 'h5'))) {
  34. $type = 'pc';
  35. }
  36. $editable_page_model = model('editable_page');
  37. $condition = array_merge(array(array('store_id' ,'=', $this->store_info['store_id']), array('editable_page_client' ,'=', $type)), $condition);
  38. $editable_page_list = $editable_page_model->getEditablePageList($condition, 10);
  39. foreach ($editable_page_list as $key => $val) {
  40. if ($val['editable_page_client'] == 'pc') {
  41. $editable_page_list[$key]['edit_url'] = (string)url('SellerEditablePage/page_setting', ['store_id' => $this->store_info['store_id'], 'editable_page_id' => $val['editable_page_id']]);
  42. $editable_page_list[$key]['view_url'] = (string)url('StoreSpecial/index', ['store_id' => $this->store_info['store_id'], 'special_id' => $val['editable_page_id']]);
  43. } else {
  44. $editable_page_list[$key]['edit_url'] = (string)url('SellerEditablePage/mobile_page_setting', array('store_id' => $this->store_info['store_id'], 'editable_page_id' => $val['editable_page_id']));
  45. $editable_page_list[$key]['view_url'] = config('ds_config.h5_site_url') . '/' . 'pages/home/storespecial/Index' . '?' . http_build_query(['id' => $this->store_info['store_id'], 'special_id' => $val['editable_page_id']]);
  46. }
  47. }
  48. View::assign('show_page', $editable_page_model->page_info->render());
  49. View::assign('editable_page_list', $editable_page_list);
  50. View::assign('type', $type);
  51. /* 设置卖家当前菜单 */
  52. $this->setSellerCurMenu($type == 'h5' ? 'seller_editable_page_h5' : 'seller_editable_page_pc');
  53. /* 设置卖家当前栏目 */
  54. $this->setSellerCurItem('page_list');
  55. return View::fetch($this->template_dir . 'page_list');
  56. }
  57. public function h5_page_list() {
  58. return $this->page_list('h5');
  59. }
  60. /**
  61. * 新增页面
  62. */
  63. public function page_add() {
  64. $editable_page_path = input('param.editable_page_path');
  65. $editable_page_item_id = intval(input('param.editable_page_item_id'));
  66. $editable_page_model = model('editable_page');
  67. if (!request()->isPost()) {
  68. return View::fetch($this->template_dir . 'page_form');
  69. } else {
  70. $data = array(
  71. 'store_id' => $this->store_info['store_id'],
  72. 'editable_page_name' => input('post.editable_page_name'),
  73. 'editable_page_path' => $editable_page_path,
  74. 'editable_page_item_id' => $editable_page_item_id,
  75. 'editable_page_client' => input('param.type', 'pc'),
  76. 'editable_page_theme' => 'style_1',
  77. 'editable_page_edit_time' => TIMESTAMP,
  78. 'editable_page_theme_config' => json_encode(array(
  79. 'back_color' => input('param.back_color')
  80. ))
  81. );
  82. $result = $editable_page_model->addEditablePage($data);
  83. $condition = array();
  84. $condition[] = array('store_id','=',$data['store_id']);
  85. $condition[] = array('editable_page_id','<>',$result);
  86. $condition[] = array('editable_page_path','=',$data['editable_page_path']);
  87. $condition[] = array('editable_page_client','=',$data['editable_page_client']);
  88. if (!in_array($data['editable_page_path'], array('store/index'))) {
  89. $condition[] = array('editable_page_item_id','=',$data['editable_page_item_id']);
  90. }
  91. $editable_page_model->editEditablePage($condition, array('editable_page_path' => '', 'editable_page_item_id' => 0));
  92. if ($result) {
  93. $this->recordSellerlog(lang('ds_add') . ($data['editable_page_client'] == 'h5' ? lang('editable_page_h5') : lang('editable_page_pc')) . '[flex_' . $result . ':' . input('post.editable_page_name') . ']');
  94. ds_json_encode(10000, lang('ds_common_op_succ'));
  95. } else {
  96. ds_json_encode(10001, lang('ds_common_op_fail'));
  97. }
  98. }
  99. }
  100. public function page_setting(){
  101. $editable_page_id = intval(input('param.editable_page_id'));
  102. $editable_page_model = model('editable_page');
  103. $editable_page_info = $editable_page_model->getOneEditablePage(array('editable_page_id' => $editable_page_id));
  104. if (!$editable_page_info) {
  105. $this->error(lang('param_error'));
  106. }
  107. $editable_page_info['editable_page_theme_config'] = json_decode($editable_page_info['editable_page_theme_config'], true);
  108. View::assign('editable_page', $editable_page_info);
  109. $editable_page_config_model = model('editable_page_config');
  110. $editable_page_config_list=$editable_page_config_model->getEditablePageConfigList(array(array('editable_page_id', '=', $editable_page_id)));
  111. $config_list=array();
  112. foreach($editable_page_config_list as $key => $val){
  113. $config_info=json_decode($val['editable_page_config_content'], true);
  114. $model_id=$val['editable_page_model_id'];
  115. $var_html=array();
  116. $var_config=array();
  117. if(!empty($config_info)){
  118. require_once PLUGINS_PATH.'/editable_page_model/'.$model_id.'/config.php';
  119. $model_name='Model'.$model_id;
  120. $model=new $model_name();
  121. $res=$model->filterData($config_info);
  122. if($res['code']){
  123. $var_config['config_info']=$res['data'];
  124. $res=$model->formatData(json_encode($res['data']),$this->store_info['store_id']);
  125. if($res['code']){
  126. $var_html['config_info']=$res['data'];
  127. }
  128. }
  129. }
  130. $html=View::fetch('../../../plugins/editable_page_model/'.$model_id.'/index',$var_html);
  131. $config=View::fetch('../../../plugins/editable_page_model/'.$model_id.'/config',$var_config);
  132. $config_list[]=array(
  133. 'val'=>$val,
  134. 'html'=>$html,
  135. 'config'=>$config
  136. );
  137. }
  138. View::assign('config_list', $config_list);
  139. return View::fetch($this->template_dir . 'page_setting');
  140. }
  141. /**
  142. * 设置手机端页面
  143. */
  144. public function mobile_page_setting() {
  145. $this->type = 'h5';
  146. $editable_page_id = intval(input('param.editable_page_id'));
  147. $editable_page_model = model('editable_page');
  148. $editable_page_info = $editable_page_model->getOneEditablePage(array('editable_page_id' => $editable_page_id));
  149. if (!$editable_page_info) {
  150. $this->error(lang('param_error'));
  151. }
  152. $editable_page_info['editable_page_theme_config'] = json_decode($editable_page_info['editable_page_theme_config'], true);
  153. View::assign('editable_page', $editable_page_info);
  154. $editable_page_config_model = model('editable_page_config');
  155. $editable_page_config_list=$editable_page_config_model->getEditablePageConfigList(array(array('editable_page_id', '=', $editable_page_id)));
  156. $config_list=array();
  157. foreach($editable_page_config_list as $key => $val){
  158. $config_info=json_decode($val['editable_page_config_content'], true);
  159. $model_id=$val['editable_page_model_id'];
  160. $var_html=array();
  161. $var_config=array();
  162. if(!empty($config_info)){
  163. require_once PLUGINS_PATH.'/editable_page_model/h5_'.$model_id.'/config.php';
  164. $model_name='Model'.$model_id;
  165. $model=new $model_name();
  166. $res=$model->filterData($config_info);
  167. if($res['code']){
  168. $var_config['config_info']=$res['data'];
  169. $res=$model->formatData(json_encode($res['data']),$this->store_info['store_id']);
  170. if($res['code']){
  171. $var_html['config_info']=$res['data'];
  172. }
  173. }
  174. }
  175. $html=View::fetch('../../../plugins/editable_page_model/h5_'.$model_id.'/index',$var_html);
  176. $config=View::fetch('../../../plugins/editable_page_model/h5_'.$model_id.'/config',$var_config);
  177. $config_list[]=array(
  178. 'val'=>$val,
  179. 'html'=>$html,
  180. 'config'=>$config
  181. );
  182. }
  183. View::assign('store_info', $this->store_info);
  184. View::assign('config_list', $config_list);
  185. /* 设置卖家当前菜单 */
  186. $this->setSellerCurMenu($this->type == 'h5' ? 'seller_editable_page_h5' : 'seller_editable_page_pc');
  187. /* 设置卖家当前栏目 */
  188. $this->setSellerCurItem('mobile_page_setting');
  189. return View::fetch($this->template_dir . 'mobile_page_setting');
  190. }
  191. /**
  192. * 编辑页面
  193. */
  194. public function page_edit() {
  195. $editable_page_id = intval(input('param.editable_page_id'));
  196. $editable_page_model = model('editable_page');
  197. $editable_page_info = $editable_page_model->getOneEditablePage(array('store_id' => $this->store_info['store_id'], 'editable_page_id' => $editable_page_id));
  198. if (!$editable_page_info) {
  199. ds_json_encode(10001, lang('param_error'));
  200. }
  201. $editable_page_info['editable_page_theme_config'] = json_decode($editable_page_info['editable_page_theme_config'], true);
  202. if (!request()->isPost()) {
  203. View::assign('editable_page', $editable_page_info);
  204. return View::fetch($this->template_dir . 'page_form');
  205. } else {
  206. $data = array(
  207. 'editable_page_path' => input('post.editable_page_path'),
  208. 'editable_page_item_id' => intval(input('post.editable_page_item_id')),
  209. 'editable_page_name' => input('post.editable_page_name'),
  210. 'editable_page_theme_config' => json_encode(array(
  211. 'back_color' => input('param.back_color')
  212. ))
  213. );
  214. $result = $editable_page_model->editEditablePage(array('editable_page_id' => $editable_page_id), $data);
  215. $condition = array();
  216. $condition[] = array('store_id','=',$this->store_info['store_id']);
  217. $condition[] = array('editable_page_id','<>',$editable_page_id);
  218. $condition[] = array('editable_page_path','=',$data['editable_page_path']);
  219. $condition[] = array('editable_page_client','=',$editable_page_info['editable_page_client']);
  220. if (!in_array($data['editable_page_path'], array('store/index'))) {
  221. $condition[] = array('editable_page_item_id','=',$data['editable_page_item_id']);
  222. }
  223. $editable_page_model->editEditablePage($condition, array('editable_page_path' => '', 'editable_page_item_id' => 0));
  224. if ($result) {
  225. $this->recordSellerlog(lang('ds_edit') . ($editable_page_info['editable_page_client'] == 'h5' ? lang('editable_page_h5') : lang('editable_page_pc')) . '[' . $editable_page_info['editable_page_name'] . ']');
  226. ds_json_encode(10000, lang('ds_common_op_succ'));
  227. } else {
  228. ds_json_encode(10000, lang('ds_common_op_fail'));
  229. }
  230. }
  231. }
  232. /**
  233. * 删除页面
  234. */
  235. public function page_del() {
  236. $editable_page_id = intval(input('param.editable_page_id'));
  237. $editable_page_model = model('editable_page');
  238. $editable_page_info = $editable_page_model->getOneEditablePage(array('store_id' => $this->store_info['store_id'], 'editable_page_id' => $editable_page_id));
  239. if (!$editable_page_info) {
  240. ds_json_encode(10001, lang('param_error'));
  241. }
  242. if (!$editable_page_model->delEditablePage($editable_page_id)) {
  243. ds_json_encode(10001, lang('ds_common_op_fail'));
  244. }
  245. $this->recordSellerlog(lang('ds_del') . ($editable_page_info['editable_page_client'] == 'h5' ? lang('editable_page_h5') : lang('editable_page_pc')) . '[ID:' . $editable_page_info['editable_page_id'] . ':' . $editable_page_info['editable_page_name'] . ']');
  246. ds_json_encode(10000, lang('ds_common_del_succ'));
  247. }
  248. /**
  249. * 搜索店铺
  250. */
  251. public function search_store() {
  252. $store_model = model('store');
  253. /**
  254. * 查询条件
  255. */
  256. $where = array();
  257. $search_store_name = trim(input('param.keyword'));
  258. if ($search_store_name != '') {
  259. $where[]=array('store_name','like', '%' . $search_store_name . '%');
  260. }
  261. $store_list = $store_model->getStoreOnlineList($where, 12);
  262. View::assign('store_list', $store_list);
  263. View::assign('show_page', $store_model->page_info->render());
  264. echo View::fetch($this->model_dir . 'search_store');
  265. exit;
  266. }
  267. /**
  268. * 搜索商品
  269. */
  270. public function search_goods() {
  271. $goods_model = model('goods');
  272. /**
  273. * 查询条件
  274. */
  275. $where = array();
  276. $where[]=array('store_id','=',$this->store_info['store_id']);
  277. $search_goods_name = trim(input('param.keyword'));
  278. $type = trim(input('param.type'));
  279. if ($search_goods_name != '') {
  280. $where[]=array('goods_name|store_name','like', '%' . $search_goods_name . '%');
  281. }
  282. switch($type){
  283. case 'bargain':
  284. $condition=array();
  285. $condition[] = array('bargain_state','=',\app\common\model\Pbargain::PINTUAN_STATE_NORMAL);
  286. $condition[] = array('bargain_endtime','>',TIMESTAMP);
  287. $subQuery=Db::name('pbargain')->field('bargain_goods_id')->where($condition)->buildSql();
  288. $where[]=array('goods_id','exp',Db::raw('in '.$subQuery));
  289. break;
  290. case 'groupbuy':
  291. $condition=array();
  292. $condition[] = array('groupbuy_state','=',\app\common\model\Groupbuy::GROUPBUY_STATE_NORMAL);
  293. $condition[] = array('groupbuy_endtime','>',TIMESTAMP);
  294. $subQuery=Db::name('groupbuy')->field('goods_commonid')->where($condition)->buildSql();
  295. $where[]=array('goods_commonid','exp',Db::raw('in '.$subQuery));
  296. break;
  297. case 'pintuan':
  298. $condition=array();
  299. $condition[] = array('pintuan_state', '=', \app\common\model\Ppintuan::PINTUAN_STATE_NORMAL);
  300. $condition[] = array('pintuan_end_time', '>', TIMESTAMP);
  301. $subQuery=Db::name('ppintuan')->field('pintuan_goods_commonid')->where($condition)->buildSql();
  302. $where[]=array('goods_commonid','exp',Db::raw('in '.$subQuery));
  303. break;
  304. case 'presell':
  305. $condition=array();
  306. $condition[] = array('presell_state','=',\app\common\model\Presell::PRESELL_STATE_NORMAL);
  307. $condition[] = array('presell_end_time','>',TIMESTAMP);
  308. $subQuery=Db::name('presell')->field('goods_id')->where($condition)->buildSql();
  309. $where[]=array('goods_id','exp',Db::raw('in '.$subQuery));
  310. break;
  311. case 'xianshi':
  312. $condition=array();
  313. $condition[] = array('xianshigoods_state','=',\app\common\model\Pxianshigoods::XIANSHI_GOODS_STATE_NORMAL);
  314. $condition[] = array('xianshigoods_end_time','>',TIMESTAMP);
  315. $subQuery=Db::name('pxianshigoods')->field('goods_id')->where($condition)->buildSql();
  316. $where[]=array('goods_id','exp',Db::raw('in '.$subQuery));
  317. break;
  318. }
  319. $goods_list = $goods_model->getGoodsOnlineList($where, '*', 12);
  320. View::assign('goods_list', $goods_list);
  321. View::assign('show_page', $goods_model->page_info->render());
  322. $goods_id=input('param.goods_id/a');
  323. if(!empty($goods_id)){
  324. $where = array();
  325. $where[]=array('goods_id','in', array_keys($goods_id));
  326. $goods_list = $goods_model->getGoodsOnlineList($where);
  327. $selected_goods=array();
  328. foreach($goods_list as $v){
  329. $selected_goods[$v['goods_id']]=array_merge($v,array('sort'=>$goods_id[$v['goods_id']]['sort']));
  330. }
  331. View::assign('goods_id', $selected_goods);
  332. }
  333. echo View::fetch($this->template_dir.'search_goods');
  334. exit;
  335. }
  336. public function image_del() {
  337. $file_id = intval(input('param.upload_id'));
  338. $res = model('editable_page_model', 'logic')->imageDel($file_id);
  339. if (!$res['code']) {
  340. ds_json_encode(10001, $res['msg']);
  341. }
  342. ds_json_encode(10000);
  343. }
  344. /**
  345. * 图片上传
  346. */
  347. public function image_upload() {
  348. $res = model('editable_page_model', 'logic')->imageUpload(input('param.name'), input('param.config_id'));
  349. if (!$res['code']) {
  350. ds_json_encode(10001, $res['msg']);
  351. }
  352. $data = $res['data'];
  353. ds_json_encode(10000, '', $data);
  354. }
  355. public function goods_class(){
  356. $id=intval(input('param.id'));
  357. $parent_id=intval(input('param.parent_id'));
  358. $goodsclass_model=model('goodsclass');
  359. if($id){
  360. $data=array('id'=>array(),'list'=>array());
  361. $goodsclass_info=$goodsclass_model->getGoodsclassInfoById($id);
  362. if($goodsclass_info){
  363. $data['id'][]=$goodsclass_info['gc_id'];
  364. $data['list'][]=$goodsclass_model->getGoodsclassListByParentId($goodsclass_info['gc_parent_id']);
  365. if($goodsclass_info['gc_parent_id']){
  366. $goodsclass_info=$goodsclass_model->getGoodsclassInfoById($goodsclass_info['gc_parent_id']);
  367. if($goodsclass_info){
  368. $data['id'][]=$goodsclass_info['gc_id'];
  369. $data['list'][]=$goodsclass_model->getGoodsclassListByParentId($goodsclass_info['gc_parent_id']);
  370. if($goodsclass_info['gc_parent_id']){
  371. $goodsclass_info=$goodsclass_model->getGoodsclassInfoById($goodsclass_info['gc_parent_id']);
  372. if($goodsclass_info){
  373. $data['id'][]=$goodsclass_info['gc_id'];
  374. $data['list'][]=$goodsclass_model->getGoodsclassListByParentId($goodsclass_info['gc_parent_id']);
  375. }
  376. }
  377. }
  378. }
  379. }
  380. $data['id']=array_reverse($data['id']);
  381. $data['list']=array_reverse($data['list']);
  382. }else{
  383. $data=$goodsclass_model->getGoodsclassListByParentId($parent_id);
  384. }
  385. ds_json_encode(10000, '', $data);
  386. }
  387. public function config_load(){
  388. $if_h5=intval(input('param.if_h5'));
  389. $model_id=intval(input('param.model_id'));
  390. $config_info=input('param.config_info/a');
  391. if(!$model_id){
  392. ds_json_encode(10001, lang('param_error'));
  393. }
  394. $var_html=array();
  395. $var_config=array();
  396. if(!empty($config_info)){
  397. require_once PLUGINS_PATH.'/editable_page_model/'.($if_h5?'h5_':'').$model_id.'/config.php';
  398. $model_name='Model'.$model_id;
  399. $model=new $model_name();
  400. $res=$model->filterData($config_info);
  401. if($res['code']){
  402. $res=$model->formatData(json_encode($res['data']),$this->store_info['store_id']);
  403. if($res['code']){
  404. $var_html['config_info']=$res['data'];
  405. }else{
  406. ds_json_encode(10001, $res['msg']);
  407. }
  408. }else{
  409. ds_json_encode(10001, $res['msg']);
  410. }
  411. }
  412. $html=View::fetch('../../../plugins/editable_page_model/'.($if_h5?'h5_':'').$model_id.'/index',$var_html);
  413. $config=View::fetch('../../../plugins/editable_page_model/'.($if_h5?'h5_':'').$model_id.'/config',$var_config);
  414. ds_json_encode(10000, '', array('html'=>$html,'config'=>$config));
  415. }
  416. public function config_edit(){
  417. $if_h5=intval(input('param.if_h5'));
  418. $config_list=input('param.config_list/a');
  419. $editable_page_id=intval(input('param.page_id'));
  420. $editable_page_model = model('editable_page');
  421. $editable_page_info = $editable_page_model->getOneEditablePage(array('editable_page_id' => $editable_page_id));
  422. if (!$editable_page_info) {
  423. ds_json_encode(10001, lang('param_error'));
  424. }
  425. try{
  426. $data=array();
  427. $new_data=array();
  428. $editable_page_theme_config=array();
  429. foreach($config_list as $sort_order => $config_info){
  430. $model_id=$config_info['model_id'];
  431. switch($model_id){
  432. case 'page':
  433. case 'jump':
  434. case 'button':
  435. if($model_id=='page'){
  436. $data['editable_page_name']=$config_info['page_title'];
  437. }
  438. $editable_page_theme_config=array_merge($editable_page_theme_config,$config_info);
  439. break;
  440. default:
  441. require_once PLUGINS_PATH.'/editable_page_model/'.($if_h5?'h5_':'').$model_id.'/config.php';
  442. $model_name='Model'.$model_id;
  443. $model=new $model_name();
  444. $res=$model->filterData($config_info);
  445. if($res['code']){
  446. $new_data[]=array(
  447. 'editable_page_id'=>$editable_page_id,
  448. 'editable_page_model_id'=>$model_id,
  449. 'editable_page_config_sort_order'=>$sort_order,
  450. 'editable_page_config_content'=>json_encode($res['data'])
  451. );
  452. }else{
  453. throw new \think\Exception($res['msg'], 10006);
  454. }
  455. }
  456. }
  457. $data['editable_page_theme_config']=json_encode($editable_page_theme_config);
  458. $data['editable_page_edit_time']=TIMESTAMP;
  459. $editable_page_config_model = model('editable_page_config');
  460. $editable_page_config_model->delEditablePageConfig(array(array('editable_page_id', '=', $editable_page_id)));
  461. if(!empty($new_data)){
  462. $editable_page_config_model->addEditablePageConfigAll($new_data);
  463. }
  464. $result = $editable_page_model->editEditablePage(array('editable_page_id' => $editable_page_id), $data);
  465. if (!$result) {
  466. throw new \think\Exception(lang('ds_common_op_fail'), 10006);
  467. }
  468. }catch(\Exception $e){
  469. ds_json_encode(10001, $e->getMessage());
  470. }
  471. $this->recordSellerlog(lang('ds_edit') . ($editable_page_info['editable_page_client'] == 'h5' ? lang('editable_page_h5') : lang('editable_page_pc')) . '[' . $editable_page_info['editable_page_name'] . ']');
  472. ds_json_encode(10000, lang('ds_common_op_succ'));
  473. }
  474. /**
  475. * 栏目菜单
  476. */
  477. function getSellerItemList() {
  478. if(request()->action()=='mobile_page_setting'){
  479. $menu_array[] = array(
  480. 'name' => 'mobile_page_setting',
  481. 'text' => lang('mobile_page_setting'),
  482. 'url' => 'javascript:void(0)',
  483. );
  484. }else{
  485. $menu_array[] = array(
  486. 'name' => 'page_list',
  487. 'text' => lang('page_list'),
  488. 'url' => 'javascript:void(0)',
  489. );
  490. }
  491. return $menu_array;
  492. }
  493. }