(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-86cf771e"],{"062c":function(t,e,n){"use strict";n("5e84")},"0926":function(t,e,n){"use strict";n("3fa6")},"0f55":function(t,e,n){"use strict";n("3807")},1601:function(t,e,n){},"1c4a":function(t,e,n){"use strict";n("85ce")},"1df1":function(t,e,n){"use strict";n.r(e);var i=n("fd0b"),o=n("befa");function r(t){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function c(t){for(var e=1;e650?650:e;var n=t;window.onresize=function(){n.clientHeight="".concat(document.documentElement.clientHeight)-65.81;var t="".concat(document.documentElement.clientHeight)-180;n.rollHeight=t>650?650:t}}))},methods:{cancel:function(){this.visible=!1},determine:function(){var t=this;return""==this.storeName.trim()?this.$Message.error("请输入模板名称"):0==this.pageId?(this.$Message.success("修改成功"),!1):(Object(o.m)(this.pageId,{name:this.storeName}).then((function(e){t.$Message.success(e.msg)})).catch((function(e){t.$Message.error(e.msg)})),void(this.visible=!1))},returnTap:function(){var t=this;this.$Modal.confirm({title:"温馨提示",content:"确定离开此页面?系统可能不会保存您所做的更改。",onOk:function(){t.$router.push("/admin/setting/system_form")},onCancel:function(){t.$Message.info("已取消")}})},leftRemove:function(t){t.to,t.from;var e=t.item,n=(t.clone,t.oldIndex,t.newIndex);this.isSearch&&0==n&&("z_wechat_attention"==e._underlying_vm_.name?this.isFllow=!0:(this.$store.commit("admin/mobildConfig/ARRAYREAST",this.mConfig[0].num),this.mConfig.splice(0,1))),(this.isFllow=n>=1)&&this.$store.commit("admin/mobildConfig/ARRAYREAST",this.mConfig[0].num)},onMove:function(t){return"search_box"!=t.relatedContext.element.name&&"nav_bar"!=t.relatedContext.element.name&&"home_comb"!=t.relatedContext.element.name},onCopy:function(){this.$Message.success("复制成功")},onError:function(){this.$Message.error("复制失败")},getUrlList:function(){var t=this;Object(i.o)().then((function(e){t.urlList=e.data.url}))},bindTab:function(t){this.tabCur=t},objToArr:function(t){return Object.keys(t).map((function(e){return t[e]}))},log:function(t){if(t.moved){if("search_box"==t.moved.element.name)return this.$Message.warning("该组件禁止拖拽");t.moved.oldNum=this.mConfig[t.moved.oldIndex].num,t.moved.newNum=this.mConfig[t.moved.newIndex].num,t.moved.status=t.moved.oldIndex>t.moved.newIndex,this.mConfig.forEach((function(t,e){t.num=1e3*(new Date).getTime()+e})),t.moved.list=this.mConfig,this.rConfig=[];var e=t.moved.element,n=JSON.parse(JSON.stringify(e));this.rConfig.push(n),this.activeIndex=t.moved.newIndex,this.$store.commit("admin/mobildConfig/SETCONFIGNAME",e.name),this.$store.commit("admin/mobildConfig/defaultArraySort",t.moved)}if(t.added){var i=t.added.element,o=1e3*(new Date).getTime();i.num=o,this.activeConfigName=i.name;var r=JSON.parse(JSON.stringify(i));r.id="id"+r.num,this.mConfig[t.added.newIndex]=r,this.rConfig=[],this.rConfig.push(r),this.mConfig.forEach((function(t,e){t.num=1e3*(new Date).getTime()+e})),t.added.list=this.mConfig,this.activeIndex=t.added.newIndex,this.$store.commit("admin/mobildConfig/SETCONFIGNAME",i.name),this.$store.commit("admin/mobildConfig/defaultArraySort",t.added)}},cloneDog:function(t){return O({},t)},swapArray:function(t,e,n){return t[e]=t.splice(n,1,t[e])[0],t},movePage:function(t,e,n){if(n){if(0==e)return}else if(e==this.mConfig.length-1)return;if("search_box"==t.name||"nav_bar"==t.name||"home_comb"==t.name)return this.$Message.warning("该组件禁止移动");if(n){if("search_box"==this.mConfig[e-1].name||"nav_bar"==this.mConfig[e-1].name||"home_comb"==this.mConfig[e-1].name)return this.$Message.warning("搜索框或分类或组合组件必须为顶部");this.swapArray(this.mConfig,e-1,e)}else this.swapArray(this.mConfig,e,e+1);var i={};this.rConfig=[],i.oldIndex=e,i.newIndex=n?e-1:e+1,this.mConfig.forEach((function(t,e){t.num=1e3*(new Date).getTime()+e}));var o=JSON.parse(JSON.stringify(t));this.rConfig.push(o),i.element=t,i.list=this.mConfig,this.activeIndex=n?e-1:e+1,this.$store.commit("admin/mobildConfig/SETCONFIGNAME",t.name),this.$store.commit("admin/mobildConfig/defaultArraySort",i)},addDomCon:function(t,e,n){if("search_box"==t.name){if(this.isSearch)return this.$Message.error("该组件只能添加一次");if(this.isComb)return this.$Message.error("组合组件不能和搜索组件与商品分类组件同时存在");this.isSearch=!0}if("nav_bar"==t.name){if(this.isTab)return this.$Message.error("该组件只能添加一次");if(this.isComb)return this.$Message.error("组合组件不能和搜索组件与商品分类组件同时存在");this.isTab=!0}if("home_comb"==t.name){if(this.isComb)return this.$Message.error("该组件只能添加一次");if(this.isSearch||this.isTab)return this.$Message.error("组合组件不能和搜索组件与商品分类组件同时存在");this.isComb=!0}if("home_service"==t.name){if(this.isService)return this.$Message.error("该组件只能添加一次");this.isService=!0}var i={},o=1e3*(new Date).getTime();t.num="".concat(o),t.id="id".concat(o),this.activeConfigName=t.name;var r=JSON.parse(JSON.stringify(t));"home_comb"==t.name||"search_box"==t.name?(this.rConfig=[],this.mConfig.unshift(r),this.activeIndex=0,this.rConfig.push(r)):"nav_bar"==t.name?(this.rConfig=[],this.mConfig[0]&&"search_box"===this.mConfig[0].name?(this.mConfig.splice(1,0,r),this.activeIndex=1):(this.mConfig.splice(0,0,r),this.activeIndex=0),this.rConfig.push(r)):e?(this.rConfig=[],this.mConfig.push(r),this.activeIndex=this.mConfig.length-1,this.rConfig.push(r)):(this.mConfig.splice(n+1,0,r),this.activeIndex=n),this.mConfig.forEach((function(t,e){t.num=1e3*(new Date).getTime()+e})),i.element=t,i.list=this.mConfig,this.$store.commit("admin/mobildConfig/SETCONFIGNAME",t.name),this.$store.commit("admin/mobildConfig/defaultArraySort",i)},bindAddDom:function(t,e,n){var i=t;this.lConfig.forEach((function(e){t.name==e.name&&(i=e)})),this.addDomCon(i,e,n)},addDom:function(t,e){this.addDomCon(t,e)},bindconfig:function(t,e){this.rConfig=[];var n=JSON.parse(JSON.stringify(t));this.rConfig.push(n),this.activeIndex=e,this.$store.commit("admin/mobildConfig/SETCONFIGNAME",t.name)},bindDelete:function(t,e){"search_box"==t.name&&(this.isSearch=!1),"nav_bar"==t.name&&(this.isTab=!1),"home_comb"==t.name&&(this.isComb=!1),"home_service"==t.name&&(this.isService=!1),this.mConfig.splice(e,1),this.rConfig.splice(0,1),this.mConfig.length!=e?this.rConfig.push(this.mConfig[e]):this.mConfig.length&&(this.activeIndex=e-1,this.rConfig.push(this.mConfig[e-1])),this.$store.commit("admin/mobildConfig/DELETEARRAY",t)},config:function(t){var e=this.propsObj;e.data=t,e.name=this.activeConfigName},addSort:function(t,e,n){return t[e]=t.splice(n,1,t[e])[0],t},arraySort:function(){var t=[],e={title:"组件",list:[],isOpen:!0};this.lConfig.map((function(t,n){0==t.type&&e.list.push(t)})),t.push(e),this.leftMenu=t},diySaveDate:function(t,e){var n=this;Object(o.sb)(this.pageId,{value:t,name:this.storeName}).then((function(t){n.pageId=t.data.id,n.$Message.success(t.msg);var i=n;2==e?(n.relLoading=!1,setTimeout((function(){i.$router.push("/admin/setting/system_form")}),2e3)):n.loading=!1})).catch((function(t){n.loading=!1,n.relLoading=!1,n.$Message.error(t.msg)}))},saveConfig:function(t){if(0==this.mConfig.length)return this.$Message.error("暂未添加任何组件,保存失败!");1==t?this.loading=!0:this.relLoading=!0;var e=this.$store.state.admin.mobildConfig.defaultArray;this.$nextTick((function(){this.diySaveDate(e,t)}))},getDefaultConfig:function(){var t=this;Object(o.tb)(this.pageId).then((function(e){var n=e.data;t.storeName=n.info.name;var i={},o=[],r=t.objToArr(n.info.value);r.sort((function(t,e){return t.timestamp-e.timestamp})),r.map((function(e,n){e.id="id"+e.timestamp,t.lConfig.map((function(n,r){if(e.name==n.defaultName){n.num=e.timestamp,n.id="id"+e.timestamp;var a=JSON.parse(JSON.stringify(n));o.push(a),i[e.timestamp]=e,t.mConfig.push(a),t.$store.commit("admin/mobildConfig/ADDARRAY",{num:e.timestamp,val:e})}}))})),t.rConfig=[],t.activeIndex=0,t.rConfig.push(t.mConfig[0])}))},reast:function(){var t=this;0==this.pageId?this.$Message.error("新增页面,无法重置"):this.$Modal.confirm({title:"提示",content:"

是否重置当前页面数据

",onOk:function(){t.mConfig=[],t.rConfig=[],t.activeIndex=-99,t.getDefaultConfig()},onCancel:function(){}})}},beforeDestroy:function(){this.$store.commit("admin/mobildConfig/titleUpdata",""),this.$store.commit("admin/mobildConfig/nameUpdata",""),this.$store.commit("admin/mobildConfig/showUpdata",1),this.$store.commit("admin/mobildConfig/colorUpdata",0),this.$store.commit("admin/mobildConfig/picUpdata",0),this.$store.commit("admin/mobildConfig/pickerUpdata","#f5f5f5"),this.$store.commit("admin/mobildConfig/radioUpdata",0),this.$store.commit("admin/mobildConfig/picurlUpdata",""),this.$store.commit("admin/mobildConfig/SETEMPTY")},destroyed:function(){this.$store.commit("admin/mobildConfig/titleUpdata",""),this.$store.commit("admin/mobildConfig/nameUpdata",""),this.$store.commit("admin/mobildConfig/showUpdata",1),this.$store.commit("admin/mobildConfig/colorUpdata",0),this.$store.commit("admin/mobildConfig/picUpdata",0),this.$store.commit("admin/mobildConfig/pickerUpdata","#f5f5f5"),this.$store.commit("admin/mobildConfig/radioUpdata",0),this.$store.commit("admin/mobildConfig/picurlUpdata",""),this.$store.commit("admin/mobildConfig/SETEMPTY")}},w=(n("43cd"),n("2877")),_=Object(w.a)(j,(function(){var t=this,e=t._self._c;return e("div",{staticClass:"diy-page"},[e("PageHeader",{staticClass:"product_tabs",attrs:{title:t.$route.meta.title,"hidden-breadcrumb":""}},[e("div",{staticClass:"f_return acea-row row-between-wrapper",attrs:{slot:"title"},slot:"title"},[e("div",{staticClass:"f_title acea-row row-middle"},[e("div",{staticClass:"title acea-row row-middle",on:{click:t.returnTap}},[e("div",{staticClass:"iconfont iconfanhui"}),e("div",{staticClass:"return"},[t._v("返回")])]),e("div",{staticClass:"mr20"},[e("span",{staticClass:"name"},[t._v("当前页面:"+t._s(t.storeName))]),e("Poptip",{attrs:{width:"347"},scopedSlots:t._u([{key:"content",fn:function(){return[e("div",[e("Input",{staticStyle:{width:"200px"},attrs:{placeholder:"必填不超过15个字"},model:{value:t.storeName,callback:function(e){t.storeName=e},expression:"storeName"}}),e("Button",{attrs:{type:"text"},on:{click:t.cancel}},[t._v("取消")]),e("Button",{attrs:{type:"primary"},on:{click:t.determine}},[t._v("确定")])],1)]},proxy:!0}]),model:{value:t.visible,callback:function(e){t.visible=e},expression:"visible"}},[e("span",{staticClass:"iconfont iconzidingyicaidan"})])],1)]),e("div",[e("Button",{staticClass:"bnt",attrs:{ghost:""},on:{click:t.reast}},[t._v("重置")]),e("Button",{staticClass:"bnt ml20 w-80",attrs:{ghost:"",loading:t.loading},on:{click:function(e){return t.saveConfig(1)}}},[t._v("保存")]),e("Button",{staticClass:"release ml20 w-80",attrs:{loading:t.relLoading},on:{click:function(e){return t.saveConfig(2)}}},[t._v("立即发布")])],1)])]),e("Card",{staticClass:"ivu-mt",staticStyle:{margin:"0 10px"},attrs:{bordered:!1,"dis-hover":""}},[e("div",{staticClass:"diy-wrapper",style:"height:"+t.clientHeight+"px;"},[e("div",{staticClass:"left"},[0==t.tabCur?e("div",{staticClass:"wrapper",style:"height:"+(t.clientHeight-96)+"px;"},t._l(t.leftMenu,(function(n,i){return e("div",{key:i},[e("div",{staticClass:"tips",on:{click:function(t){n.isOpen=!n.isOpen}}},[t._v("\n "+t._s(n.title)+"\n "),n.isOpen?e("Icon",{attrs:{type:"ios-arrow-down",size:"16"}}):e("Icon",{attrs:{type:"ios-arrow-forward",size:"16"}})],1),e("draggable",{staticClass:"dragArea list-group",attrs:{list:n.list,group:{name:"people",pull:"clone",put:!1},clone:t.cloneDog,dragClass:"dragClass",filter:".search , .navbar , .homeComb , .service"}},t._l(n.list,(function(i,o){return e("div",{directives:[{name:"show",rawName:"v-show",value:n.isOpen,expression:"item.isOpen"}],key:i.id,staticClass:"list-group-item",class:{search:"搜索框"==i.cname,navbar:"商品分类"==i.cname,homeComb:"组合组件"==i.cname,service:"在线客服"==i.cname},on:{click:function(e){return t.addDom(i,1)}}},[e("div",[e("div",{staticClass:"position",staticStyle:{display:"none"}},[t._v("释放鼠标将组建添加到此处")]),e("span",{staticClass:"conter iconfont-diy",class:i.icon}),e("p",{staticClass:"conter"},[t._v(t._s(i.cname))])])])})),0)],1)})),0):e("div",{staticClass:"wrapper",style:"height:"+(t.clientHeight-46)+"px;"},t._l(t.urlList,(function(n,i){return e("div",{key:i,staticClass:"link-item"},[e("div",{staticClass:"name"},[t._v(t._s(n.name))]),e("div",{staticClass:"link-txt"},[t._v("地址:"+t._s(n.url))]),e("div",{staticClass:"params"},[e("span",{staticClass:"txt"},[t._v("参数:")]),e("span",[t._v(t._s(n.parameter))])]),e("div",{staticClass:"lable"},[e("p",{staticClass:"txt"},[t._v("例如:"+t._s(n.example))]),e("Button",{directives:[{name:"clipboard",rawName:"v-clipboard:copy",value:n.example,expression:"item.example",arg:"copy"},{name:"clipboard",rawName:"v-clipboard:success",value:t.onCopy,expression:"onCopy",arg:"success"},{name:"clipboard",rawName:"v-clipboard:error",value:t.onError,expression:"onError",arg:"error"}],attrs:{size:"small"}},[t._v("复制\n ")])],1)])})),0)]),e("div",{staticClass:"wrapper-con",staticStyle:{flex:"1",background:"#f0f2f5",display:"flex","justify-content":"center","padding-top":"20px",height:"100%"}},[e("div",{staticClass:"content"},[e("div",{staticClass:"contxt",staticStyle:{display:"flex","flex-direction":"column",overflow:"hidden",height:"100%"}},[e("div",{staticClass:"overflowy"},[e("div",{staticClass:"picture"},[e("img",{attrs:{src:n("2d44")}})]),e("div",{staticClass:"page-title"},[t._v("\n 表单\n ")])]),e("div",{staticClass:"scrollCon"},[e("div",{staticStyle:{width:"460px",margin:"0 auto"}},[e("div",{ref:"imgContainer",staticClass:"scroll-box",class:t.picTxt&&2==t.tabValTxt?"fullsize noRepeat":t.picTxt&&1==t.tabValTxt?"repeat ysize":"noRepeat ysize",style:"background-color:"+(t.colorTxt?t.colorPickerTxt:"")+";background-image: url("+(t.picTxt?t.picUrlTxt:"")+");height:"+t.rollHeight+"px;"},[e("draggable",{staticClass:"dragArea list-group",attrs:{list:t.mConfig,group:"people",filter:".top",move:t.onMove,animation:"300"},on:{change:t.log}},t._l(t.mConfig,(function(n,i){return e("div",{key:i,staticClass:"mConfig-item",class:{on:t.activeIndex==i,top:"search_box"==n.name||"nav_bar"==n.name},style:t.colorTxt?"background-color:"+t.colorPickerTxt+";":"background-color:#fff;",on:{click:function(e){return e.stopPropagation(),t.bindconfig(n,i)}}},[e(n.name,{ref:"getComponentData",refInFor:!0,tag:"component",attrs:{configData:t.propsObj,index:i,num:n.num}}),e("div",{staticClass:"delete-box"},[e("div",{staticClass:"handleType"},[e("div",{staticClass:"iconfont iconshanchu2",on:{click:function(e){return e.stopPropagation(),t.bindDelete(n,i)}}}),e("div",{staticClass:"iconfont iconfuzhi",on:{click:function(e){return e.stopPropagation(),t.bindAddDom(n,0,i)}}}),e("div",{staticClass:"iconfont iconshangyi",class:0===i?"on":"",on:{click:function(e){return e.stopPropagation(),t.movePage(n,i,1)}}}),e("div",{staticClass:"iconfont iconxiayi",class:i===t.mConfig.length-1?"on":"",on:{click:function(e){return e.stopPropagation(),t.movePage(n,i,0)}}})])]),e("div",{staticClass:"handle"})],1)})),0)],1)])])])])]),e("div",{staticClass:"right-box"},t._l(t.rConfig,(function(n,i){return e("div",{key:i,staticClass:"mConfig-item",staticStyle:{"background-color":"#fff"}},[e("div",{staticClass:"title-bar"},[t._v(t._s(n.cname))]),e(n.configName,{tag:"component",attrs:{activeIndex:t.activeIndex,num:n.num,index:i},on:{config:t.config}})],1)})),0)])])],1)}),[],!1,null,"32a85c08",null);e.default=_.exports},3028:function(t,e,n){"use strict";n("b1cc")},3807:function(t,e,n){},"3f86":function(t,e,n){"use strict";n("47f1")},"3fa6":function(t,e,n){},"43cd":function(t,e,n){"use strict";n("c6e3")},4657:function(t,e,n){},"46b1":function(t,e,n){"use strict";n("72b5")},"46dd":function(t,e,n){t.exports=n.p+"view_admin/img/formImg.f0b358fe.png"},"47f1":function(t,e,n){},"51d7":function(t,e,n){},"538a":function(t,e,n){},5448:function(t,e,n){var i={"./c_home_checkbox.vue":"d49a","./c_home_city.vue":"772c","./c_home_date.vue":"57b4","./c_home_daterange.vue":"fc90","./c_home_radio.vue":"a0cd","./c_home_select.vue":"1df1","./c_home_text.vue":"68a3","./c_home_time.vue":"a3fe7","./c_home_timerange.vue":"a9af","./c_upload_picture.vue":"657a"};function o(t){var e=r(t);return n(e)}function r(t){if(!n.o(i,t)){var e=new Error("Cannot find module '"+t+"'");throw e.code="MODULE_NOT_FOUND",e}return i[t]}o.keys=function(){return Object.keys(i)},o.resolve=r,t.exports=o,o.id="5448"},"57b4":function(t,e,n){"use strict";n.r(e);var i=n("61f7"),o=n("fd0b"),r=n("befa");function a(t){return(a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function c(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(t);e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,i)}return n}function s(t){for(var e=1;e=8?8:t.numConfig.val;this.picList=[];for(var n=0;n