webpackJsonp([56],{"03Sq":function(e,t,a){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=a("4YfN"),l=a.n(r),o=a("9rMa"),i={data:function(){return{dataForm:{title:"",date:null},dataFormText:{id:0,cname:"",ename:"",domain:"",remark:"",desc:"",enable:"1"},props:{label:"name",children:"children",isLeaf:"isLeaf"}}},computed:l()({},Object(o.c)({parentTree:function(e){return e.shopProduct.parentTree},childrenTree:function(e){return e.shopProduct.childrenTree}})),created:function(){this.getTreeData()},methods:{getTreeData:function(){this.$store.dispatch("shop/product/sortlist",{id:0})},handleNodeClick:function(e){this.$store.dispatch("shop/product/sortlist",{id:e.id}),console.log(e)},loadNode:function(e,t){if(console.log(e),0===e.level)return t(this.parentTree);for(var a in e.parent.childNodes){var r=e.parent.childNodes[a].data.id;e.data.id==r&&this.$store.dispatch("shop/product/sortlist",{id:e.data.id}).then(function(e){t(e)})}}},components:{}},n={render:function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"mod-orderlist__moudle"},[a("div",{staticClass:"side-tree",staticStyle:{width:"15%",float:"left","margin-right":"20px"}},[a("el-tree",{attrs:{"highlight-current":"",data:e.parentTree,props:e.props,lazy:"",load:e.loadNode},on:{"node-click":e.handleNodeClick}})],1),e._v(" "),a("el-form",{attrs:{inline:!0,model:e.dataForm}},[a("el-form-item",[a("el-button",{attrs:{type:"danger"}},[e._v("删除所选分类")])],1),e._v(" "),a("el-form-item",[a("el-button",{attrs:{type:"primary"}},[e._v("添加子级分类")])],1),e._v(" "),a("el-form-item",[a("el-button",{attrs:{type:"primary"}},[e._v("添加根节点分类")])],1)],1),e._v(" "),a("el-form",{ref:"dataForm",staticStyle:{width:"80%",float:"left"},attrs:{model:e.dataFormText,"label-width":"120px"}},[a("el-form-item",{attrs:{label:"分类名称",prop:"cname"}},[a("el-input",{attrs:{placeholder:"请输入中文名"},model:{value:e.dataForm.cname,callback:function(t){e.$set(e.dataForm,"cname",t)},expression:"dataForm.cname"}})],1),e._v(" "),a("el-form-item",{attrs:{label:"是否为父节点",size:"mini",prop:"enable"}},[a("el-radio-group",{model:{value:e.dataForm.enable,callback:function(t){e.$set(e.dataForm,"enable",t)},expression:"dataForm.enable"}},[a("el-radio",{attrs:{label:"0"}},[e._v("否")]),e._v(" "),a("el-radio",{attrs:{label:"1"}},[e._v("是")])],1)],1),e._v(" "),a("el-form-item",{attrs:{label:"选择父节点",prop:"ename"}},[a("el-input",{staticStyle:{width:"260px"},attrs:{placeholder:"请输入英文名"},model:{value:e.dataForm.ename,callback:function(t){e.$set(e.dataForm,"ename",t)},expression:"dataForm.ename"}}),e._v(" "),a("el-button",{staticStyle:{width:"160px"},attrs:{type:"primary"},on:{click:function(t){e.dataFormSubmit()}}},[e._v("选择父节点分类")])],1),e._v(" "),a("el-form-item",{attrs:{label:"排序优先值",prop:"domain"}},[a("el-input",{attrs:{placeholder:"请输入可正常使用的域名"},model:{value:e.dataForm.domain,callback:function(t){e.$set(e.dataForm,"domain",t)},expression:"dataForm.domain"}})],1),e._v(" "),a("el-form-item",{attrs:{label:"是否启用",size:"mini",prop:"enable"}},[a("el-radio-group",{model:{value:e.dataForm.enable,callback:function(t){e.$set(e.dataForm,"enable",t)},expression:"dataForm.enable"}},[a("el-radio",{attrs:{label:"0"}},[e._v("启用")]),e._v(" "),a("el-radio",{attrs:{label:"1"}},[e._v("禁用")])],1)],1),e._v(" "),a("el-form-item",{attrs:{label:"备注",prop:"remark"}},[a("el-input",{attrs:{placeholder:"选填"},model:{value:e.dataForm.remark,callback:function(t){e.$set(e.dataForm,"remark",t)},expression:"dataForm.remark"}})],1),e._v(" "),a("el-form-item",[a("el-button",{staticStyle:{width:"200px"},attrs:{type:"primary"},on:{click:function(t){e.dataFormSubmit()}}},[e._v("提交")])],1)],1)],1)},staticRenderFns:[]},d=a("C7Lr")(i,n,!1,null,null,null);t.default=d.exports}});