1 line
6.3 KiB
JavaScript
1 line
6.3 KiB
JavaScript
|
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-9c7cf71a"],{"7e3b":function(e,t,a){},"86b3":function(e,t,a){"use strict";a.r(t);var i=function(){var e=this,t=e.$createElement,a=e._self._c||t;return a("div",{staticClass:"divBox"},[a("el-card",{staticClass:"box-card"},[a("div",{staticClass:"clearfix",attrs:{slot:"header"},slot:"header"},[a("div",{staticClass:"container"},[a("el-form",{attrs:{inline:"",size:"small"}},[a("el-form-item",{attrs:{label:"规格搜索:"}},[a("el-input",{staticClass:"selWidth",attrs:{placeholder:"请输入商品规格",clearable:""},model:{value:e.tableFrom.keywords,callback:function(t){e.$set(e.tableFrom,"keywords",t)},expression:"tableFrom.keywords"}},[a("el-button",{attrs:{slot:"append",icon:"el-icon-search"},on:{click:e.seachList},slot:"append"})],1)],1)],1)],1),e._v(" "),a("div",{staticClass:"acea-row"},[a("el-button",{directives:[{name:"hasPermi",rawName:"v-hasPermi",value:["admin:product:rule:save"],expression:"['admin:product:rule:save']"}],attrs:{size:"small",type:"primary"},on:{click:e.handleAdd}},[e._v("添加商品规格")]),e._v(" "),a("el-button",{directives:[{name:"hasPermi",rawName:"v-hasPermi",value:["admin:product:rule:delete"],expression:"['admin:product:rule:delete']"}],attrs:{size:"small"},on:{click:e.handleDeleteAll}},[e._v("批量删除")])],1)]),e._v(" "),a("el-table",{directives:[{name:"loading",rawName:"v-loading",value:e.listLoading,expression:"listLoading"}],ref:"table",staticStyle:{width:"100%"},attrs:{data:e.tableData.data,size:"mini","highlight-current-row":""},on:{"selection-change":e.handleSelectionChange}},[a("el-table-column",{attrs:{type:"selection",width:"55"}}),e._v(" "),a("el-table-column",{attrs:{prop:"id",label:"ID","min-width":"60"}}),e._v(" "),a("el-table-column",{attrs:{prop:"ruleName",label:"规格名称","min-width":"150"}}),e._v(" "),a("el-table-column",{attrs:{label:"商品规格","min-width":"150"},scopedSlots:e._u([{key:"default",fn:function(t){return e._l(t.row.ruleValue,(function(t,i){return a("span",{key:i,staticClass:"mr10",domProps:{textContent:e._s(t.value)}})}))}}])}),e._v(" "),a("el-table-column",{attrs:{label:"商品属性","min-width":"300"},scopedSlots:e._u([{key:"default",fn:function(t){return e._l(t.row.ruleValue,(function(t,i){return a("div",{key:i,domProps:{textContent:e._s(t.detail.join(","))}})}))}}])}),e._v(" "),a("el-table-column",{attrs:{label:"操作","min-width":"120",fixed:"right",align:"center"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-button",{directives:[{name:"hasPermi",rawName:"v-hasPermi",value:["admin:product:rule:update","admin:product:rule:info"],expression:"['admin:product:rule:update', 'admin:product:rule:info']"}],staticClass:"mr10",attrs:{type:"text",size:"small"},on:{click:function(a){return e.handleEdit(t.row)}}},[e._v("编辑")]),e._v(" "),a("el-button",{directives:[{name:"hasPermi",rawName:"v-hasPermi",value:["admin:product:rule:delete"],expression:"['admin:product:rule:delete']"}],attrs:{type:"text",size:"small"},on:{click:function(a){return e.handleDelete(t.row.id,t.$index)}}},[e._v("删除")])]}}])})],1),e._v(" "),a("div",{staticClass:"block"},[a("el-pagination",{attrs:{"page-sizes":[20,40,60,80],"page-size":e.tableFrom.limit,"current-page":e.tableFrom.page,layout:"total, sizes, prev, pager, next, jumper",total:e.tableData.total},on:{"size-change":e.handleSizeChange,"current-change":e.pageChange}})],1)],1)],1)},l=[],n=a("73f5"),s={name:"StoreAttr",data:function(){return{formDynamic:{ruleName:"",ruleValue:[]},tableFrom:{page:1,limit:20,keywords:""},tableData:{data:[],loading:!1,total:0},listLoading:!0,selectionList:[],multipleSelectionAll:[],idKey:"id",nextPageFlag:!1,keyNum:0}},mounted:function(){this.getList()},methods:{seachList:function(){this.tableFrom.page=1,this.getList()},handleSelectionChange:function(e){var t=this;this.selectionList=e,setTimeout((function(){t.changePageCoreRecordData()}),50)},setSelectRow:function(){if(this.multipleSelectionAll&&!(this.multipleSelectionAll.length<=0)){var e=this.idKey,t=[];this.multipleSelectionAll.forEach((function(a){t.pu
|