UseTemplate.php 49 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165
  1. <?php
  2. /**
  3. * Niushop商城系统 - 团队十年电商经验汇集巨献!
  4. * =========================================================
  5. * Copy right 2019-2029 杭州牛之云科技有限公司, 保留所有权利。
  6. * ----------------------------------------------
  7. * 官方网址=> https=>//www.niushop.com
  8. * =========================================================
  9. */
  10. namespace addon\diy_default2\event;
  11. use app\model\web\DiyView as DiyViewModel;
  12. /**
  13. * 自定义模板
  14. */
  15. class UseTemplate
  16. {
  17. /**
  18. * 模板数据
  19. * @param $params
  20. * @return array
  21. */
  22. public function handle($params)
  23. {
  24. if ($params[ 'name' ] == 'official_default_plane') {
  25. $diy_view = new DiyViewModel();
  26. // 添加模板页面
  27. $res = $diy_view->addTemplatePage([
  28. 'site_id' => $params[ 'site_id' ],
  29. 'name' => $params[ 'name' ],
  30. 'page' => [ $this->index_page, $this->goods_category_page ], // 自定义页面集合
  31. ]);
  32. return $res;
  33. }
  34. }
  35. // 【首页】自定义页面数据
  36. private $index_page = [
  37. 'title' => '官方模板二',
  38. 'name' => "DIY_VIEW_INDEX",
  39. 'type' => "shop",
  40. 'value' => [
  41. "global" => [
  42. "title" => "官方模板二",
  43. "pageBgColor" => "#F3F3F3",
  44. "topNavColor" => "#FFFFFF",
  45. "topNavBg" => false,
  46. "navBarSwitch" => true,
  47. "textNavColor" => "#333333",
  48. "topNavImg" => "",
  49. "moreLink" => [
  50. "name" => ""
  51. ],
  52. "openBottomNav" => true,
  53. "navStyle" => 1,
  54. "textImgPosLink" => "center",
  55. "mpCollect" => false,
  56. "popWindow" => [
  57. "imageUrl" => "",
  58. "count" => -1,
  59. "show" => 0,
  60. "link" => [
  61. "name" => ""
  62. ],
  63. "imgWidth" => "",
  64. "imgHeight" => ""
  65. ],
  66. "bgUrl" => "",
  67. "imgWidth" => "",
  68. "imgHeight" => "",
  69. "template" => [
  70. "pageBgColor" => "",
  71. "textColor" => "#303133",
  72. "componentBgColor" => "",
  73. "componentAngle" => "round",
  74. "topAroundRadius" => 0,
  75. "bottomAroundRadius" => 0,
  76. "elementBgColor" => "",
  77. "elementAngle" => "round",
  78. "topElementAroundRadius" => 0,
  79. "bottomElementAroundRadius" => 0,
  80. "margin" => [
  81. "top" => 0,
  82. "bottom" => 0,
  83. "both" => 0
  84. ]
  85. ]
  86. ],
  87. "value" => [
  88. [
  89. "id" => "5wtw72w1wj80",
  90. "componentName" => "Search",
  91. "componentTitle" => "搜索框",
  92. "isDelete" => 0,
  93. "topAroundRadius" => 0,
  94. "bottomAroundRadius" => 0,
  95. "topElementAroundRadius" => 0,
  96. "bottomElementAroundRadius" => 0,
  97. "margin" => [
  98. "top" => 10,
  99. "bottom" => 10,
  100. "both" => 12
  101. ],
  102. "title" => "请输入搜索关键词",
  103. "textAlign" => "left",
  104. "borderType" => 2,
  105. "searchImg" => "",
  106. "searchStyle" => 1,
  107. "pageBgColor" => "#FFFFFF",
  108. "textColor" => "#303133",
  109. "componentBgColor" => "",
  110. "elementBgColor" => "#F6F9FF",
  111. "iconType" => "img",
  112. "icon" => "",
  113. "style" => [
  114. "fontSize" => "60",
  115. "iconBgColor" => [],
  116. "iconBgColorDeg" => 0,
  117. "iconBgImg" => "",
  118. "bgRadius" => 0,
  119. "iconColor" => [
  120. "#000000"
  121. ],
  122. "iconColorDeg" => 0
  123. ],
  124. "imageUrl" => ""
  125. ],
  126. [
  127. "id" => "2o7za2qmi900",
  128. "list" => [
  129. [
  130. "link" => [
  131. "name" => ""
  132. ],
  133. "imageUrl" => __ROOT__ . '/addon/diy_default2/shop/view/public/img/banner.png',
  134. "imgWidth" => "750",
  135. "imgHeight" => "320",
  136. "id" => "17vtbffhsvsw0"
  137. ],
  138. [
  139. "link" => [
  140. "name" => ""
  141. ],
  142. "imageUrl" => __ROOT__ . '/addon/diy_default2/shop/view/public/img/banner2.png',
  143. "imgWidth" => "750",
  144. "imgHeight" => "320",
  145. "id" => "zcrfm65uiu8"
  146. ]
  147. ],
  148. "indicatorColor" => "#ffffff",
  149. "carouselStyle" => "circle",
  150. "indicatorLocation" => "center",
  151. "componentName" => "ImageAds",
  152. "componentTitle" => "图片广告",
  153. "isDelete" => 0,
  154. "pageBgColor" => "",
  155. "componentBgColor" => "",
  156. "componentAngle" => "round",
  157. "topAroundRadius" => 0,
  158. "bottomAroundRadius" => 0,
  159. "topElementAroundRadius" => 0,
  160. "bottomElementAroundRadius" => 0,
  161. "margin" => [
  162. "top" => 0,
  163. "bottom" => 0,
  164. "both" => 0
  165. ]
  166. ],
  167. [
  168. "id" => "113ohzka4n40",
  169. "mode" => "graphic",
  170. "type" => "img",
  171. "showStyle" => "fixed",
  172. "ornament" => [
  173. "type" => "default",
  174. "color" => "#EDEDED"
  175. ],
  176. "rowCount" => 5,
  177. "pageCount" => 2,
  178. "carousel" => [
  179. "type" => "circle",
  180. "color" => "#FFFFFF"
  181. ],
  182. "imageSize" => 40,
  183. "aroundRadius" => 25,
  184. "font" => [
  185. "size" => 14,
  186. "weight" => 500,
  187. "color" => "#303133"
  188. ],
  189. "list" => [
  190. [
  191. "title" => "团购",
  192. "icon" => "icondiy icon-system-groupbuy-nav",
  193. "imageUrl" => "",
  194. "iconType" => "icon",
  195. "style" => [
  196. "fontSize" => 50,
  197. "iconBgColor" => [
  198. "#FF5715",
  199. "#FF4116"
  200. ],
  201. "iconBgColorDeg" => 90,
  202. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  203. "bgRadius" => 19,
  204. "iconColor" => [
  205. "#FFFFFF"
  206. ],
  207. "iconColorDeg" => 0
  208. ],
  209. "link" => [
  210. "name" => "GROUPBUY_PREFECTURE",
  211. "title" => "团购专区",
  212. "wap_url" => "/pages_promotion/groupbuy/list",
  213. "parent" => "MARKETING_LINK"
  214. ],
  215. "label" => [
  216. "control" => false,
  217. "text" => "热门",
  218. "textColor" => "#FFFFFF",
  219. "bgColorStart" => "#F83287",
  220. "bgColorEnd" => "#FE3423"
  221. ],
  222. "id" => "1e67vek25rhc0"
  223. ],
  224. [
  225. "title" => "拼团",
  226. "icon" => "icondiy icon-system-pintuan-nav",
  227. "imageUrl" => "",
  228. "iconType" => "icon",
  229. "style" => [
  230. "fontSize" => 50,
  231. "iconBgColor" => [
  232. "#58BCFF",
  233. "#1379FF"
  234. ],
  235. "iconBgColorDeg" => 90,
  236. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  237. "bgRadius" => 19,
  238. "iconColor" => [
  239. "#FFFFFF"
  240. ],
  241. "iconColorDeg" => 0
  242. ],
  243. "link" => [
  244. "name" => "PINTUAN_PREFECTURE",
  245. "title" => "拼团专区",
  246. "wap_url" => "/pages_promotion/pintuan/list",
  247. "parent" => "MARKETING_LINK"
  248. ],
  249. "label" => [
  250. "control" => false,
  251. "text" => "热门",
  252. "textColor" => "#FFFFFF",
  253. "bgColorStart" => "#F83287",
  254. "bgColorEnd" => "#FE3423"
  255. ],
  256. "id" => "b1kn8ktvs440"
  257. ],
  258. [
  259. "title" => "秒杀",
  260. "icon" => "icondiy icon-system-seckill-time",
  261. "imageUrl" => "",
  262. "iconType" => "icon",
  263. "style" => [
  264. "fontSize" => 50,
  265. "iconBgColor" => [
  266. "#FF9100"
  267. ],
  268. "iconBgColorDeg" => 0,
  269. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  270. "bgRadius" => 19,
  271. "iconColor" => [
  272. "#FFFFFF"
  273. ],
  274. "iconColorDeg" => 0
  275. ],
  276. "link" => [
  277. "name" => "SECKILL_PREFECTURE",
  278. "title" => "秒杀专区",
  279. "wap_url" => "/pages_promotion/seckill/list",
  280. "parent" => "MARKETING_LINK"
  281. ],
  282. "label" => [
  283. "control" => true,
  284. "text" => "热门",
  285. "textColor" => "#FFFFFF",
  286. "bgColorStart" => "#F83288",
  287. "bgColorEnd" => "#FE3523"
  288. ],
  289. "id" => "1cgq3tjxkc800"
  290. ],
  291. [
  292. "title" => " 积分",
  293. "icon" => "icondiy icon-system-point-nav",
  294. "imageUrl" => "",
  295. "iconType" => "icon",
  296. "style" => [
  297. "fontSize" => 50,
  298. "iconBgColor" => [
  299. "#02CC96",
  300. "#43EEC9"
  301. ],
  302. "iconBgColorDeg" => 90,
  303. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  304. "bgRadius" => 19,
  305. "iconColor" => [
  306. "#FFFFFF"
  307. ],
  308. "iconColorDeg" => 0
  309. ],
  310. "link" => [
  311. "name" => "INTEGRAL_STORE",
  312. "title" => "积分商城",
  313. "wap_url" => "/pages_promotion/point/list",
  314. "parent" => "MARKETING_LINK"
  315. ],
  316. "label" => [
  317. "control" => false,
  318. "text" => "热门",
  319. "textColor" => "#FFFFFF",
  320. "bgColorStart" => "#F83287",
  321. "bgColorEnd" => "#FE3423"
  322. ],
  323. "id" => "1v6a5arxdyqo0"
  324. ],
  325. [
  326. "title" => "专题活动",
  327. "icon" => "icondiy icon-system-topic-nav",
  328. "imageUrl" => "",
  329. "iconType" => "icon",
  330. "style" => [
  331. "fontSize" => 50,
  332. "iconBgColor" => [
  333. "#BE79FF",
  334. "#7B00FF"
  335. ],
  336. "iconBgColorDeg" => 90,
  337. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  338. "bgRadius" => 19,
  339. "iconColor" => [
  340. "#FFFFFF"
  341. ],
  342. "iconColorDeg" => 0
  343. ],
  344. "link" => [
  345. "name" => "THEMATIC_ACTIVITIES_LIST",
  346. "title" => "专题活动列表",
  347. "wap_url" => "/pages_promotion/topics/list",
  348. "parent" => "MARKETING_LINK"
  349. ],
  350. "label" => [
  351. "control" => false,
  352. "text" => "热门",
  353. "textColor" => "#FFFFFF",
  354. "bgColorStart" => "#F83287",
  355. "bgColorEnd" => "#FE3423"
  356. ],
  357. "id" => "x7bqn51r8hs0"
  358. ],
  359. [
  360. "title" => "砍价",
  361. "icon" => "icondiy icon-system-bargain-nav",
  362. "imageUrl" => "",
  363. "iconType" => "icon",
  364. "style" => [
  365. "fontSize" => 50,
  366. "iconBgColor" => [
  367. "#5BBDFF",
  368. "#2E87FD"
  369. ],
  370. "iconBgColorDeg" => 90,
  371. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  372. "bgRadius" => 19,
  373. "iconColor" => [
  374. "#FFFFFF"
  375. ],
  376. "iconColorDeg" => 0
  377. ],
  378. "link" => [
  379. "name" => "BARGAIN_PREFECTURE",
  380. "title" => "砍价专区",
  381. "wap_url" => "/pages_promotion/bargain/list",
  382. "parent" => "MARKETING_LINK"
  383. ],
  384. "label" => [
  385. "control" => false,
  386. "text" => "热门",
  387. "textColor" => "#FFFFFF",
  388. "bgColorStart" => "#F83287",
  389. "bgColorEnd" => "#FE3423"
  390. ],
  391. "id" => "140zkvoseuw00"
  392. ],
  393. [
  394. "title" => "领券",
  395. "icon" => "icondiy icon-system-get-coupon",
  396. "imageUrl" => "",
  397. "iconType" => "icon",
  398. "style" => [
  399. "fontSize" => 50,
  400. "iconBgColor" => [
  401. "#BE79FF",
  402. "#7B00FF"
  403. ],
  404. "iconBgColorDeg" => 90,
  405. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  406. "bgRadius" => 19,
  407. "iconColor" => [
  408. "#FFFFFF"
  409. ],
  410. "iconColorDeg" => 0
  411. ],
  412. "link" => [
  413. "name" => "COUPON_PREFECTURE",
  414. "title" => "优惠券专区",
  415. "wap_url" => "/pages_tool/goods/coupon",
  416. "parent" => "MARKETING_LINK"
  417. ],
  418. "label" => [
  419. "control" => false,
  420. "text" => "热门",
  421. "textColor" => "#FFFFFF",
  422. "bgColorStart" => "#F83287",
  423. "bgColorEnd" => "#FE3423"
  424. ],
  425. "id" => "5sjwa1q2t5k0"
  426. ],
  427. [
  428. "title" => "文章",
  429. "icon" => "icondiy icon-system-article-nav",
  430. "imageUrl" => "",
  431. "iconType" => "icon",
  432. "style" => [
  433. "fontSize" => 50,
  434. "iconBgColor" => [
  435. "#FF8052",
  436. "#FF4830"
  437. ],
  438. "iconBgColorDeg" => 90,
  439. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  440. "bgRadius" => 19,
  441. "iconColor" => [
  442. "#FFFFFF"
  443. ],
  444. "iconColorDeg" => 0
  445. ],
  446. "link" => [
  447. "name" => "SHOPPING_ARTICLE",
  448. "title" => "文章",
  449. "wap_url" => "/pages_tool/article/list",
  450. "parent" => "MALL_LINK"
  451. ],
  452. "label" => [
  453. "control" => false,
  454. "text" => "热门",
  455. "textColor" => "#FFFFFF",
  456. "bgColorStart" => "#F83287",
  457. "bgColorEnd" => "#FE3423"
  458. ],
  459. "id" => "4aforgjwmdw0"
  460. ],
  461. [
  462. "title" => "公告",
  463. "icon" => "icondiy icon-system-notice-nav",
  464. "imageUrl" => "",
  465. "iconType" => "icon",
  466. "style" => [
  467. "fontSize" => 50,
  468. "iconBgColor" => [
  469. "#FFCC26",
  470. "#FF9F29"
  471. ],
  472. "iconBgColorDeg" => 90,
  473. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  474. "bgRadius" => 19,
  475. "iconColor" => [
  476. "#FFFFFF"
  477. ],
  478. "iconColorDeg" => 0
  479. ],
  480. "link" => [
  481. "name" => "SHOPPING_NOTICE",
  482. "title" => "公告",
  483. "wap_url" => "/pages_tool/notice/list",
  484. "parent" => "MALL_LINK"
  485. ],
  486. "label" => [
  487. "control" => false,
  488. "text" => "热门",
  489. "textColor" => "#FFFFFF",
  490. "bgColorStart" => "#F83287",
  491. "bgColorEnd" => "#FE3423"
  492. ],
  493. "id" => "myo9oz46yj40"
  494. ],
  495. [
  496. "title" => "帮助",
  497. "icon" => "icondiy icon-system-help",
  498. "imageUrl" => "",
  499. "iconType" => "icon",
  500. "style" => [
  501. "fontSize" => 50,
  502. "iconBgColor" => [
  503. "#02CC96",
  504. "#43EEC9"
  505. ],
  506. "iconBgColorDeg" => 90,
  507. "iconBgImg" => "public/static/ext/diyview/img/icon_bg/bg_04.png",
  508. "bgRadius" => 19,
  509. "iconColor" => [
  510. "#FFFFFF"
  511. ],
  512. "iconColorDeg" => 0
  513. ],
  514. "link" => [
  515. "name" => "SHOPPING_HELP",
  516. "title" => "帮助",
  517. "wap_url" => "/pages_tool/help/list",
  518. "parent" => "MALL_LINK"
  519. ],
  520. "label" => [
  521. "control" => false,
  522. "text" => "热门",
  523. "textColor" => "#FFFFFF",
  524. "bgColorStart" => "#F83287",
  525. "bgColorEnd" => "#FE3423"
  526. ],
  527. "id" => "h4nt4orc9i80"
  528. ]
  529. ],
  530. "componentName" => "GraphicNav",
  531. "componentTitle" => "图文导航",
  532. "isDelete" => 0,
  533. "pageBgColor" => "#FFFFFF",
  534. "componentBgColor" => "",
  535. "componentAngle" => "round",
  536. "topAroundRadius" => 0,
  537. "bottomAroundRadius" => 0,
  538. "topElementAroundRadius" => 0,
  539. "bottomElementAroundRadius" => 0,
  540. "margin" => [
  541. "top" => 0,
  542. "bottom" => 0,
  543. "both" => 12
  544. ]
  545. ],
  546. [
  547. "id" => "3tegcfvyijk0",
  548. "style" => "5",
  549. "sources" => "initial",
  550. "styleName" => "风格五",
  551. "couponIds" => [],
  552. "count" => 6,
  553. "previewList" => [],
  554. "nameColor" => "#303133",
  555. "moneyColor" => "#FF0000",
  556. "limitColor" => "#999999",
  557. "btnStyle" => [
  558. "textColor" => "#FFFFFF",
  559. "bgColor" => "#303133",
  560. "text" => "立即领取",
  561. "aroundRadius" => 5,
  562. "isBgColor" => true,
  563. "isAroundRadius" => true
  564. ],
  565. "bgColor" => "",
  566. "isName" => true,
  567. "couponBgColor" => "",
  568. "couponBgUrl" => "",
  569. "couponType" => "img",
  570. "ifNeedBg" => true,
  571. "componentName" => "Coupon",
  572. "componentTitle" => "优惠券",
  573. "isDelete" => 0,
  574. "pageBgColor" => "",
  575. "topAroundRadius" => 0,
  576. "bottomAroundRadius" => 0,
  577. "elementBgColor" => "",
  578. "topElementAroundRadius" => 0,
  579. "bottomElementAroundRadius" => 0,
  580. "margin" => [
  581. "top" => 10,
  582. "bottom" => 10,
  583. "both" => 12
  584. ]
  585. ],
  586. [
  587. "id" => "3acr0xjm1c80",
  588. "componentName" => "RubikCube",
  589. "componentTitle" => "魔方",
  590. "isDelete" => 0,
  591. "pageBgColor" => "",
  592. "componentBgColor" => "",
  593. "componentAngle" => "round",
  594. "topAroundRadius" => 10,
  595. "bottomAroundRadius" => 10,
  596. "topElementAroundRadius" => 0,
  597. "bottomElementAroundRadius" => 0,
  598. "margin" => [
  599. "top" => 0,
  600. "bottom" => 10,
  601. "both" => 12
  602. ],
  603. "list" => [
  604. [
  605. "imageUrl" => __ROOT__ . '/addon/diy_default2/shop/view/public/img/mf_left.png',
  606. "imgWidth" => "338",
  607. "imgHeight" => "450",
  608. "previewWidth" => 187.5,
  609. "previewHeight" => "249.63px",
  610. "link" => [
  611. "name" => ""
  612. ]
  613. ],
  614. [
  615. "imageUrl" => __ROOT__ . '/addon/diy_default2/shop/view/public/img/mf_right1.png',
  616. "imgWidth" => "354",
  617. "imgHeight" => "220",
  618. "previewWidth" => 187.5,
  619. "previewHeight" => "124.82px",
  620. "link" => [
  621. "name" => ""
  622. ]
  623. ],
  624. [
  625. "imageUrl" => __ROOT__ . '/addon/diy_default2/shop/view/public/img/mf_right2.png',
  626. "imgWidth" => "354",
  627. "imgHeight" => "22",
  628. "previewWidth" => 187.5,
  629. "previewHeight" => "124.82px",
  630. "link" => [
  631. "name" => ""
  632. ]
  633. ]
  634. ],
  635. "mode" => "row1-lt-of2-rt",
  636. "imageGap" => 10,
  637. "elementAngle" => "round"
  638. ],
  639. [
  640. "id" => "68p4o1plca80",
  641. "style" => "style-1",
  642. "sources" => "initial",
  643. "styleName" => "风格1",
  644. "count" => 6,
  645. "componentName" => "GoodsRecommend",
  646. "componentTitle" => "商品推荐",
  647. "isDelete" => 0,
  648. "topAroundRadius" => 0,
  649. "bottomAroundRadius" => 0,
  650. "topElementAroundRadius" => 10,
  651. "bottomElementAroundRadius" => 10,
  652. "margin" => [
  653. "top" => 0,
  654. "bottom" => 10,
  655. "both" => 12
  656. ],
  657. "nameLineMode" => "single",
  658. "sortWay" => "default",
  659. "ornament" => [
  660. "type" => "default",
  661. "color" => "#EDEDED"
  662. ],
  663. "imgAroundRadius" => 0,
  664. "goodsNameStyle" => [
  665. "color" => "#303133",
  666. "control" => true,
  667. "fontWeight" => false
  668. ],
  669. "saleStyle" => [
  670. "color" => "#999CA7",
  671. "control" => true,
  672. "support" => true
  673. ],
  674. "theme" => "default",
  675. "priceStyle" => [
  676. "mainColor" => "#FF1544",
  677. "mainControl" => true,
  678. "lineColor" => "#999CA7",
  679. "lineControl" => false,
  680. "lineSupport" => false
  681. ],
  682. "goodsId" => [],
  683. "categoryId" => 0,
  684. "categoryName" => "请选择",
  685. "topStyle" => [
  686. "title" => "今日推荐",
  687. "subTitle" => "大家都在买",
  688. "icon" => [
  689. "value" => "icondiy icon-system-tuijian",
  690. "color" => "#FF3D3D",
  691. "bgColor" => ""
  692. ],
  693. "color" => "#303133",
  694. "subColor" => "#999CA7"
  695. ],
  696. "bgUrl" => "",
  697. "pageBgColor" => "",
  698. "componentBgColor" => "",
  699. "componentAngle" => "round",
  700. "elementBgColor" => "#FFFFFF",
  701. "elementAngle" => "round"
  702. ],
  703. [
  704. "id" => "3moj09pl5c20",
  705. "style" => "style-1",
  706. "sources" => "initial",
  707. "count" => 6,
  708. "goodsId" => [],
  709. "ornament" => [
  710. "type" => "default",
  711. "color" => "#EDEDED"
  712. ],
  713. "nameLineMode" => "single",
  714. "template" => "row1-of1",
  715. "goodsMarginType" => "default",
  716. "goodsMarginNum" => 10,
  717. "btnStyle" => [
  718. "text" => "去秒杀",
  719. "textColor" => "#FFFFFF",
  720. "theme" => "default",
  721. "aroundRadius" => 25,
  722. "control" => true,
  723. "support" => true,
  724. "bgColorStart" => "#FF7B1D",
  725. "bgColorEnd" => "#FF1544"
  726. ],
  727. "imgAroundRadius" => 10,
  728. "saleStyle" => [
  729. "color" => "#999CA7",
  730. "control" => true,
  731. "support" => true
  732. ],
  733. "progressStyle" => [
  734. "control" => true,
  735. "support" => true,
  736. "currColor" => "#FDBE6C",
  737. "bgColor" => "#FCECD7"
  738. ],
  739. "titleStyle" => [
  740. "backgroundImage" => "addon/seckill/component/view/seckill/img/style_title_3_bg.png",
  741. "isShow" => true,
  742. "leftStyle" => "img",
  743. "leftImg" => "addon/seckill/component/view/seckill/img/style_title_3_name.png",
  744. "style" => "style-3",
  745. "styleName" => "风格3",
  746. "leftText" => "限时秒杀",
  747. "fontSize" => 16,
  748. "fontWeight" => true,
  749. "textColor" => "#FFFFFF",
  750. "bgColorStart" => "#FA6400",
  751. "bgColorEnd" => "#FF287A",
  752. "more" => "更多",
  753. "moreColor" => "#FFFFFF",
  754. "moreFontSize" => 12,
  755. "timeTextColor" => "#FD3B54",
  756. "timeBgColor" => "#FFFFFF",
  757. "timeImageUrl" => ""
  758. ],
  759. "slideMode" => "scroll",
  760. "theme" => "default",
  761. "priceStyle" => [
  762. "mainColor" => "#FF1745",
  763. "mainControl" => true,
  764. "lineColor" => "#999CA7",
  765. "lineControl" => true,
  766. "lineSupport" => true
  767. ],
  768. "goodsNameStyle" => [
  769. "color" => "#303133",
  770. "control" => true,
  771. "fontWeight" => false
  772. ],
  773. "componentName" => "Seckill",
  774. "componentTitle" => "秒杀",
  775. "isDelete" => 0,
  776. "pageBgColor" => "",
  777. "componentBgColor" => "",
  778. "componentAngle" => "round",
  779. "topAroundRadius" => 0,
  780. "bottomAroundRadius" => 0,
  781. "elementBgColor" => "#FFFFFF",
  782. "elementAngle" => "round",
  783. "topElementAroundRadius" => 0,
  784. "bottomElementAroundRadius" => 0,
  785. "margin" => [
  786. "top" => 0,
  787. "bottom" => 10,
  788. "both" => 12
  789. ]
  790. ],
  791. [
  792. "id" => "z9bdab3tm34",
  793. "style" => "style-1",
  794. "sources" => "initial",
  795. "count" => 6,
  796. "goodsId" => [],
  797. "ornament" => [
  798. "type" => "default",
  799. "color" => "#EDEDED"
  800. ],
  801. "nameLineMode" => "single",
  802. "template" => "horizontal-slide",
  803. "goodsMarginType" => "default",
  804. "goodsMarginNum" => 10,
  805. "btnStyle" => [
  806. "text" => "去拼团",
  807. "textColor" => "#FFFFFF",
  808. "theme" => "default",
  809. "aroundRadius" => 25,
  810. "control" => false,
  811. "support" => false,
  812. "bgColorStart" => "#FF1544",
  813. "bgColorEnd" => "#FF1544"
  814. ],
  815. "imgAroundRadius" => 10,
  816. "saleStyle" => [
  817. "color" => "#FF1544",
  818. "control" => false,
  819. "support" => false
  820. ],
  821. "groupStyle" => [
  822. "color" => "#FFFFFF",
  823. "control" => true,
  824. "support" => true,
  825. "bgColorStart" => "#FA2379",
  826. "bgColorEnd" => "#FF4F61"
  827. ],
  828. "priceStyle" => [
  829. "mainColor" => "#FF1544",
  830. "mainControl" => true,
  831. "lineColor" => "#999CA7",
  832. "lineControl" => true,
  833. "lineSupport" => true
  834. ],
  835. "slideMode" => "scroll",
  836. "theme" => "default",
  837. "goodsNameStyle" => [
  838. "color" => "#303133",
  839. "control" => true,
  840. "fontWeight" => false
  841. ],
  842. "titleStyle" => [
  843. "bgColorStart" => "#6236FF",
  844. "bgColorEnd" => "#0091FF",
  845. "isShow" => true,
  846. "leftStyle" => "img",
  847. "leftImg" => "addon/pintuan/component/view/pintuan/img/horizontal_slide_name.png",
  848. "style" => "style-1",
  849. "styleName" => "风格1",
  850. "leftText" => "超值拼团",
  851. "fontSize" => 16,
  852. "fontWeight" => true,
  853. "textColor" => "#FFFFFF",
  854. "more" => "查看更多",
  855. "moreColor" => "#FFFFFF",
  856. "moreFontSize" => 12,
  857. "backgroundImage" => "addon/pintuan/component/view/pintuan/img/horizontal_slide_bg.png"
  858. ],
  859. "componentName" => "Pintuan",
  860. "componentTitle" => "拼团",
  861. "isDelete" => 0,
  862. "pageBgColor" => "",
  863. "componentBgColor" => "#FFFFFF",
  864. "componentAngle" => "round",
  865. "topAroundRadius" => 0,
  866. "bottomAroundRadius" => 10,
  867. "elementBgColor" => "",
  868. "elementAngle" => "round",
  869. "topElementAroundRadius" => 0,
  870. "bottomElementAroundRadius" => 0,
  871. "margin" => [
  872. "top" => 0,
  873. "bottom" => 10,
  874. "both" => 12
  875. ]
  876. ],
  877. [
  878. "id" => "xwdnfttfj7k",
  879. "style" => "style-1",
  880. "sources" => "initial",
  881. "count" => 6,
  882. "goodsId" => [],
  883. "ornament" => [
  884. "type" => "default",
  885. "color" => "#EDEDED"
  886. ],
  887. "nameLineMode" => "single",
  888. "template" => "horizontal-slide",
  889. "goodsMarginType" => "default",
  890. "goodsMarginNum" => 10,
  891. "btnStyle" => [
  892. "text" => "立即抢购",
  893. "textColor" => "#FFFFFF",
  894. "theme" => "default",
  895. "aroundRadius" => 25,
  896. "control" => false,
  897. "support" => false,
  898. "bgColorStart" => "#FF7B1D",
  899. "bgColorEnd" => "#FF1544"
  900. ],
  901. "imgAroundRadius" => 5,
  902. "saleStyle" => [
  903. "color" => "#FFFFFF",
  904. "control" => true,
  905. "support" => true
  906. ],
  907. "slideMode" => "scroll",
  908. "theme" => "default",
  909. "goodsNameStyle" => [
  910. "color" => "#303133",
  911. "control" => true,
  912. "fontWeight" => false
  913. ],
  914. "priceStyle" => [
  915. "mainColor" => "#FF1745",
  916. "mainControl" => true,
  917. "lineColor" => "#999CA7",
  918. "lineControl" => true,
  919. "lineSupport" => true
  920. ],
  921. "titleStyle" => [
  922. "bgColorStart" => "#FF209D",
  923. "bgColorEnd" => "#B620E0",
  924. "isShow" => true,
  925. "leftStyle" => "img",
  926. "leftImg" => "",
  927. "style" => "style-1",
  928. "styleName" => "风格1",
  929. "leftText" => "疯狂砍价",
  930. "fontSize" => 16,
  931. "fontWeight" => true,
  932. "textColor" => "#FFFFFF",
  933. "more" => "更多",
  934. "moreColor" => "#FFFFFF",
  935. "moreFontSize" => 12,
  936. "backgroundImage" => ""
  937. ],
  938. "componentName" => "Bargain",
  939. "componentTitle" => "砍价",
  940. "isDelete" => 0,
  941. "pageBgColor" => "",
  942. "componentBgColor" => "#FFFFFF",
  943. "componentAngle" => "round",
  944. "topAroundRadius" => 0,
  945. "bottomAroundRadius" => 10,
  946. "elementBgColor" => "",
  947. "elementAngle" => "round",
  948. "topElementAroundRadius" => 0,
  949. "bottomElementAroundRadius" => 0,
  950. "margin" => [
  951. "top" => 0,
  952. "bottom" => 10,
  953. "both" => 12
  954. ]
  955. ],
  956. [
  957. "id" => "5zj6d48bxks0",
  958. "componentName" => "ImageAds",
  959. "componentTitle" => "图片广告",
  960. "isDelete" => 0,
  961. "pageBgColor" => "",
  962. "componentBgColor" => "",
  963. "componentAngle" => "round",
  964. "topAroundRadius" => 5,
  965. "bottomAroundRadius" => 5,
  966. "topElementAroundRadius" => 0,
  967. "bottomElementAroundRadius" => 0,
  968. "margin" => [
  969. "top" => 0,
  970. "bottom" => 10,
  971. "both" => 12
  972. ],
  973. "list" => [
  974. [
  975. "link" => [
  976. "name" => ""
  977. ],
  978. "imageUrl" => __ROOT__ . '/addon/diy_default2/shop/view/public/img/gg.png',
  979. "imgWidth" => "702",
  980. "imgHeight" => "252",
  981. "id" => "ccnb530uc5k0"
  982. ]
  983. ],
  984. "indicatorColor" => "#ffffff",
  985. "carouselStyle" => "circle",
  986. "indicatorLocation" => "center"
  987. ],
  988. [
  989. "id" => "xwdnfttfj7k",
  990. "style" => "style-3",
  991. "sources" => "initial",
  992. "count" => 6,
  993. "goodsId" => [],
  994. "ornament" => [
  995. "type" => "default",
  996. "color" => "#EDEDED"
  997. ],
  998. "nameLineMode" => "multiple",
  999. "template" => "row1-of2",
  1000. "goodsMarginType" => "default",
  1001. "goodsMarginNum" => 6,
  1002. "btnStyle" => [
  1003. "text" => "购买",
  1004. "textColor" => "#FFFFFF",
  1005. "theme" => "default",
  1006. "aroundRadius" => 25,
  1007. "control" => false,
  1008. "support" => false,
  1009. "bgColor" => "#FF6A00",
  1010. "style" => "button",
  1011. "iconDiy" => [
  1012. "iconType" => "icon",
  1013. "icon" => "",
  1014. "style" => [
  1015. "fontSize" => "60",
  1016. "iconBgColor" => [],
  1017. "iconBgColorDeg" => 0,
  1018. "iconBgImg" => "",
  1019. "bgRadius" => 0,
  1020. "iconColor" => [
  1021. "#000000"
  1022. ],
  1023. "iconColorDeg" => 0
  1024. ]
  1025. ]
  1026. ],
  1027. "imgAroundRadius" => 0,
  1028. "saleStyle" => [
  1029. "color" => "#999CA7",
  1030. "control" => true,
  1031. "support" => true
  1032. ],
  1033. "slideMode" => "slide",
  1034. "theme" => "default",
  1035. "goodsNameStyle" => [
  1036. "color" => "#303133",
  1037. "control" => true,
  1038. "fontWeight" => false
  1039. ],
  1040. "priceStyle" => [
  1041. "mainColor" => "#FF6A00",
  1042. "mainControl" => true,
  1043. "lineColor" => "#999CA7",
  1044. "lineControl" => false,
  1045. "lineSupport" => false
  1046. ],
  1047. "componentName" => "GoodsList",
  1048. "componentTitle" => "商品列表",
  1049. "isDelete" => 0,
  1050. "pageBgColor" => "",
  1051. "componentBgColor" => "",
  1052. "componentAngle" => "round",
  1053. "topAroundRadius" => 10,
  1054. "bottomAroundRadius" => 10,
  1055. "elementBgColor" => "#FFFFFF",
  1056. "elementAngle" => "round",
  1057. "topElementAroundRadius" => 10,
  1058. "bottomElementAroundRadius" => 10,
  1059. "margin" => [
  1060. "top" => 0,
  1061. "bottom" => 0,
  1062. "both" => 12
  1063. ],
  1064. "categoryId" => 0,
  1065. "categoryName" => "请选择",
  1066. "sortWay" => "default",
  1067. "tag" => [
  1068. "text" => "隐藏",
  1069. "value" => "hidden"
  1070. ],
  1071. "cartEvent" => "detail"
  1072. ]
  1073. ]
  1074. ]
  1075. ];
  1076. // 获取首页数据
  1077. public function getIndexPage()
  1078. {
  1079. return $this->index_page;
  1080. }
  1081. // 【商品分类】自定义页面数据
  1082. private $goods_category_page = [
  1083. 'title' => '商品分类',
  1084. 'name' => "DIY_VIEW_GOODS_CATEGORY",
  1085. 'type' => "shop",
  1086. 'value' =>
  1087. [
  1088. "global" => [
  1089. "title" => "商品分类",
  1090. "pageBgColor" => "#FFFFFF",
  1091. "topNavColor" => "#FFFFFF",
  1092. "topNavBg" => false,
  1093. "navBarSwitch" => true,
  1094. "textNavColor" => "#333333",
  1095. "topNavImg" => "",
  1096. "moreLink" => [
  1097. "name" => ""
  1098. ],
  1099. "openBottomNav" => true,
  1100. "navStyle" => 1,
  1101. "textImgPosLink" => "left",
  1102. "mpCollect" => false,
  1103. "popWindow" => [
  1104. "imageUrl" => "",
  1105. "count" => -1,
  1106. "show" => 0,
  1107. "link" => [
  1108. "name" => ""
  1109. ],
  1110. "imgWidth" => "",
  1111. "imgHeight" => ""
  1112. ],
  1113. "bgUrl" => "",
  1114. "imgWidth" => "",
  1115. "imgHeight" => "",
  1116. "template" => [
  1117. "pageBgColor" => "",
  1118. "textColor" => "#303133",
  1119. "componentBgColor" => "",
  1120. "componentAngle" => "round",
  1121. "topAroundRadius" => 0,
  1122. "bottomAroundRadius" => 0,
  1123. "elementBgColor" => "",
  1124. "elementAngle" => "round",
  1125. "topElementAroundRadius" => 0,
  1126. "bottomElementAroundRadius" => 0,
  1127. "margin" => [
  1128. "top" => 0,
  1129. "bottom" => 0,
  1130. "both" => 0
  1131. ]
  1132. ]
  1133. ],
  1134. "value" => [
  1135. [
  1136. "level" => "2",
  1137. "template" => "2",
  1138. "quickBuy" => 1,
  1139. "search" => 1,
  1140. "componentName" => "GoodsCategory",
  1141. "componentTitle" => "商品分类",
  1142. "isDelete" => 1,
  1143. "topAroundRadius" => 0,
  1144. "bottomAroundRadius" => 0,
  1145. "topElementAroundRadius" => 0,
  1146. "bottomElementAroundRadius" => 0,
  1147. "margin" => [],
  1148. "goodsLevel" => 1,
  1149. "loadType" => "part"
  1150. ]
  1151. ]
  1152. ]
  1153. ];
  1154. }