| | |
| | | direction: "rtl", |
| | | drawer: false, |
| | | testList: [], |
| | | uploadUrl: "/api/blade-cps/employee/import-employee", |
| | | exportUrl: "/api/blade-cps/employee/export-template", |
| | | uploadUrl: "/api/smis/employee/import-employee", |
| | | exportUrl: "/api/smis/employee/export-template", |
| | | activeName: 'first', |
| | | selection0: [], |
| | | selection1: [], |
| | |
| | | methods: { |
| | | tableLoad(row,treeNode,resolve) { |
| | | this.searchData.parentId= row.id; |
| | | this.$HTTP.post(`/api/blade-cps/product/lazy/tree?current=1&size=-1&id=${row.id}`).then(res=> { |
| | | this.$HTTP.post(`/api/smis/product/lazy/tree?current=1&size=-1&id=${row.id}`).then(res=> { |
| | | if(res.code == 200) { |
| | | resolve(res.data.records); |
| | | } |
| | |
| | | }, |
| | | delTypeDataSingle(type) { |
| | | if(this.delTypeNum == 0) { //删除产品 |
| | | var url = "/api/blade-cps/product/remove"; |
| | | var stopUrl = "/api/blade-cps/product/change-status"; |
| | | var url = "/api/smis/product/remove"; |
| | | var stopUrl = "/api/smis/product/change-status"; |
| | | }else if(this.delTypeNum == 1) { //删除产品类型 |
| | | var url = "/api/blade-cps/product-type/remove"; |
| | | var stopUrl = "/api/blade-cps/product-type/change-status"; |
| | | var url = "/api/smis/product-type/remove"; |
| | | var stopUrl = "/api/smis/product-type/change-status"; |
| | | } |
| | | if(type == 0) { //删除 |
| | | this.$HTTP.delete(url,[this.id]).then(res=> { |
| | |
| | | this.getProductTypeSelect(); |
| | | }, |
| | | addTypeDataSubmit() { |
| | | this.$HTTP.post(`/api/blade-cps/product-type/saveOrUpdate`,this.typeData).then(res => { |
| | | this.$HTTP.post(`/api/smis/product-type/saveOrUpdate`,this.typeData).then(res => { |
| | | if (res.code == 200) { |
| | | this.getProductType(); |
| | | this.clearTypeData(); |
| | |
| | | } |
| | | }, |
| | | getProductType() { |
| | | this.$HTTP.get(`/api/blade-cps/product-type/page?current=1&size=10`).then(res => { |
| | | this.$HTTP.get(`/api/smis/product-type/page?current=1&size=10`).then(res => { |
| | | if (res.code == 200) { |
| | | this.productTypeTableData = res.data.records; |
| | | } |
| | |
| | | this.delTypeModel = true; |
| | | }, |
| | | getProductTypeSelect() { |
| | | this.$HTTP.get(`/api/blade-cps/product-type/page?size=-1`).then(res => { |
| | | this.$HTTP.get(`/api/smis/product-type/page?size=-1`).then(res => { |
| | | if (res.code == 200) { |
| | | this.typeIdList = res.data.records; |
| | | } |
| | |
| | | done(); |
| | | }, |
| | | getExport() { |
| | | this.$HTTP.post(`/api/blade-cps/product/export-product`,this.searchData).then(res => { |
| | | this.$HTTP.post(`/api/smis/product/export-product`,this.searchData).then(res => { |
| | | if (res.code == 200) { |
| | | window.open(res.data.link); |
| | | } |
| | |
| | | this.searchBtn0(); |
| | | }, |
| | | searchBtn0() { |
| | | this.$HTTP.post("/api/blade-cps/product/lazy/tree?current=1&size=15&id=0",this.searchData).then(res=> { |
| | | this.$HTTP.post("/api/smis/product/lazy/tree?current=1&size=15&id=0",this.searchData).then(res=> { |
| | | if(res.code == 200) { |
| | | this.productTableData = res.data.records; |
| | | this.total0 = res.data.total; |
| | |
| | | }, |
| | | table_edit(row){ |
| | | this.dialog.save = true |
| | | this.$HTTP.get(`/api/blade-cps/product/get/${row.id}`).then(res=> { |
| | | this.$HTTP.get(`/api/smis/product/get/${row.id}`).then(res=> { |
| | | if(res.code == 200) { |
| | | this.dialog.save = true; |
| | | this.$nextTick(() => { |