You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
crmeb_php/public/system/js/chunk-00fd6f6e.00673a00.js

1 line
4.2 KiB

12 months ago
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-00fd6f6e"],{"32a1":function(e,t,a){},"4a54":function(e,t,a){"use strict";a("32a1")},cb21: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("div",{staticClass:"header clearfix"},[a("div",{staticClass:"filter-container"},[a("div",{staticClass:"demo-input-suffix acea-row"},[a("el-form",{attrs:{inline:"",size:"small"}},[a("el-form-item",{attrs:{label:"商品分类:"}},[a("el-cascader",{staticClass:"selWidth",attrs:{options:e.merCateList,props:e.props,clearable:""},on:{change:function(t){return e.getList(1)}},model:{value:e.tableFrom.cate_id,callback:function(t){e.$set(e.tableFrom,"cate_id",t)},expression:"tableFrom.cate_id"}})],1),e._v(" "),a("el-form-item",{attrs:{label:"商品搜索:"}},[a("el-input",{staticClass:"selWidth",attrs:{placeholder:"请输入商品名称,关键字,产品编号"},model:{value:e.tableFrom.store_name,callback:function(t){e.$set(e.tableFrom,"store_name",t)},expression:"tableFrom.store_name"}},[a("el-button",{attrs:{slot:"append",icon:"el-icon-search"},nativeOn:{keyup:function(t){return!t.type.indexOf("key")&&e._k(t.keyCode,"enter",13,t.key,"Enter")?null:e.getList(1)}},slot:"append"})],1)],1)],1)],1)])]),e._v(" "),a("el-table",{directives:[{name:"loading",rawName:"v-loading",value:e.listLoading,expression:"listLoading"}],staticStyle:{width:"100%"},attrs:{data:e.tableData.data,size:"mini"}},[a("el-table-column",{attrs:{width:"55"},scopedSlots:e._u([{key:"default",fn:function(t){return[a("el-radio",{attrs:{label:t.row.product_id},nativeOn:{change:function(a){return e.getTemplateRow(t.row)}},model:{value:e.templateRadio,callback:function(t){e.templateRadio=t},expression:"templateRadio"}},[e._v(" ")])]}}])}),e._v(" "),a("el-table-column",{attrs:{prop:"product_id",label:"ID","min-width":"50"}}),e._v(" "),a("el-table-column",{attrs:{label:"商品图","min-width":"80"},scopedSlots:e._u([{key:"default",fn:function(e){return[a("div",{staticClass:"demo-image__preview"},[a("el-image",{staticStyle:{width:"36px",height:"36px"},attrs:{src:e.row.image,"preview-src-list":[e.row.image]}})],1)]}}])}),e._v(" "),a("el-table-column",{attrs:{prop:"store_name",label:"商品名称","min-width":"200"}})],1),e._v(" "),a("div",{staticClass:"block mb20"},[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)},l=[],n=(a("c5f6"),a("ac6a"),a("c4c8")),o=a("83d6"),s={name:"GoodList",data:function(){return{props:{emitPath:!1},templateRadio:0,merCateList:[],merSelect:[],roterPre:o["roterPre"],listLoading:!0,tableData:{data:[],total:0},tableFrom:{page:1,limit:20,cate_id:""},multipleSelection:{},checked:[]}},mounted:function(){this.getList(""),this.getCategorySelect(),form_create_helper.onOk(this.unloadHandler)},methods:{unloadHandler:function(){this.multipleSelection?this.$route.query.field&&this.multipleSelection.src&&this.multipleSelection.id&&form_create_helper.set(this.$route.query.field,this.multipleSelection):this.$message.warning("请先选择商品")},getTemplateRow:function(e){this.multipleSelection={src:e.image,id:e.product_id}},getCategorySelect:function(){var e=this;Object(n["w"])().then((function(t){e.merCateList=t.data})).catch((function(t){e.$message.error(t.message)}))},getList:function(e){var t=this;this.listLoading=!0,this.tableFrom.page=e||this.tableFrom.page,Object(n["B"])(this.tableFrom).then((function(e){t.tableData.data=e.data.list,t.tableData.total=e.data.count,t.checked=window.form_create_helper.get(t.$route.query.field)||[],t.tableData.data.forEach((function(e){t.checked.forEach((function(a){Number(e.product_id)===Number(a.id)&&t.$nextTick((function(){t.$refs.multipleTable.toggleRowSelection(e,!0)}))}))})),t.listLoading=!1})).catch((function(e){t.listLoading=!1,t.$message.error(e.message)}))},pageChange:function(e){this.tableFrom.page=e,t