diff --git a/src/components/echart/barChart/MixChart.vue b/src/components/echart/barChart/MixChart.vue index c47e798..2b1d478 100644 --- a/src/components/echart/barChart/MixChart.vue +++ b/src/components/echart/barChart/MixChart.vue @@ -2,7 +2,7 @@
@@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/barChart/MixChart.vue b/src/components/echart/barChart/MixChart.vue index c47e798..2b1d478 100644 --- a/src/components/echart/barChart/MixChart.vue +++ b/src/components/echart/barChart/MixChart.vue @@ -2,7 +2,7 @@
@@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/lineChart/gradientLineChart.vue b/src/components/echart/lineChart/gradientLineChart.vue index 0078deb..945f9af 100644 --- a/src/components/echart/lineChart/gradientLineChart.vue +++ b/src/components/echart/lineChart/gradientLineChart.vue @@ -68,7 +68,7 @@ option: { grid: { left: 10, - right: 5, + right: 10, bottom: 30, top: 10, containLabel: true, diff --git a/src/components/echart/barChart/MixChart.vue b/src/components/echart/barChart/MixChart.vue index c47e798..2b1d478 100644 --- a/src/components/echart/barChart/MixChart.vue +++ b/src/components/echart/barChart/MixChart.vue @@ -2,7 +2,7 @@
@@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/lineChart/gradientLineChart.vue b/src/components/echart/lineChart/gradientLineChart.vue index 0078deb..945f9af 100644 --- a/src/components/echart/lineChart/gradientLineChart.vue +++ b/src/components/echart/lineChart/gradientLineChart.vue @@ -68,7 +68,7 @@ option: { grid: { left: 10, - right: 5, + right: 10, bottom: 30, top: 10, containLabel: true, diff --git a/src/components/mycomponent/dialog/productBindDialog.vue b/src/components/mycomponent/dialog/productBindDialog.vue index d387996..abc0d56 100644 --- a/src/components/mycomponent/dialog/productBindDialog.vue +++ b/src/components/mycomponent/dialog/productBindDialog.vue @@ -17,7 +17,7 @@ 添加服务
- + - + @@ -60,7 +60,7 @@ }, data() { return { - loading: ture, + loading: true, tableData: [], isShowInfo: false, serviceList: [], @@ -74,53 +74,56 @@ }, methods: { close() { + this.isShowInfo = false this.$emit('close') }, - initDialog(row){ + initDialog(row) { this.isShowInfo = true - if(this.dataInfo){ + if (this.dataInfo) { this.fetchBindList(row.id) } }, - fetchBindList(id){ + fetchBindList(id) { this.loading = true - listBindService({id:id}).then(res=>{ + listBindService({ id: id }).then(res => { this.tableData = res this.loading = false }) }, bindServeClick() { const obj = { - id:'', + id: '', serviceCode: '', serviceName: '', typeCode: '', + typeCodeName: '', description: '', serviceTime: '', remark: '' } this.tableData.push(obj) }, - changeService(val, index){ - const service = this.serviceList.filter(item=>item.id==val)[0] + changeService(val, index) { + const service = this.serviceList.filter(item => item.id == val)[0] this.tableData[index].id = service.id this.tableData[index].serviceCode = service.serviceCode this.tableData[index].serviceName = service.serviceName this.tableData[index].typeCode = service.typeCode + this.tableData[index].typeCodeName = service.typeCodeName this.tableData[index].description = service.description this.tableData[index].serviceTime = service.serviceTime this.tableData[index].remark = service.remark }, - bindService(){ - for(const item of this.tableData){ - const data = { - serviceId: item.id, - productId: this.dataInfo.id - } - bindServ(data).then(res=>{ - // this.$message.success('绑定成功') - }) + bindService() { + const serviceIds = this.tableData.map(item => item.id) + const data = { + serviceIds: serviceIds, + productId: this.dataInfo.id } + bindServ(data).then(res => { + this.$message.success('绑定成功') + this.close() + }) } } } diff --git a/src/components/echart/barChart/MixChart.vue b/src/components/echart/barChart/MixChart.vue index c47e798..2b1d478 100644 --- a/src/components/echart/barChart/MixChart.vue +++ b/src/components/echart/barChart/MixChart.vue @@ -2,7 +2,7 @@
@@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/lineChart/gradientLineChart.vue b/src/components/echart/lineChart/gradientLineChart.vue index 0078deb..945f9af 100644 --- a/src/components/echart/lineChart/gradientLineChart.vue +++ b/src/components/echart/lineChart/gradientLineChart.vue @@ -68,7 +68,7 @@ option: { grid: { left: 10, - right: 5, + right: 10, bottom: 30, top: 10, containLabel: true, diff --git a/src/components/mycomponent/dialog/productBindDialog.vue b/src/components/mycomponent/dialog/productBindDialog.vue index d387996..abc0d56 100644 --- a/src/components/mycomponent/dialog/productBindDialog.vue +++ b/src/components/mycomponent/dialog/productBindDialog.vue @@ -17,7 +17,7 @@ 添加服务
- + - + @@ -60,7 +60,7 @@ }, data() { return { - loading: ture, + loading: true, tableData: [], isShowInfo: false, serviceList: [], @@ -74,53 +74,56 @@ }, methods: { close() { + this.isShowInfo = false this.$emit('close') }, - initDialog(row){ + initDialog(row) { this.isShowInfo = true - if(this.dataInfo){ + if (this.dataInfo) { this.fetchBindList(row.id) } }, - fetchBindList(id){ + fetchBindList(id) { this.loading = true - listBindService({id:id}).then(res=>{ + listBindService({ id: id }).then(res => { this.tableData = res this.loading = false }) }, bindServeClick() { const obj = { - id:'', + id: '', serviceCode: '', serviceName: '', typeCode: '', + typeCodeName: '', description: '', serviceTime: '', remark: '' } this.tableData.push(obj) }, - changeService(val, index){ - const service = this.serviceList.filter(item=>item.id==val)[0] + changeService(val, index) { + const service = this.serviceList.filter(item => item.id == val)[0] this.tableData[index].id = service.id this.tableData[index].serviceCode = service.serviceCode this.tableData[index].serviceName = service.serviceName this.tableData[index].typeCode = service.typeCode + this.tableData[index].typeCodeName = service.typeCodeName this.tableData[index].description = service.description this.tableData[index].serviceTime = service.serviceTime this.tableData[index].remark = service.remark }, - bindService(){ - for(const item of this.tableData){ - const data = { - serviceId: item.id, - productId: this.dataInfo.id - } - bindServ(data).then(res=>{ - // this.$message.success('绑定成功') - }) + bindService() { + const serviceIds = this.tableData.map(item => item.id) + const data = { + serviceIds: serviceIds, + productId: this.dataInfo.id } + bindServ(data).then(res => { + this.$message.success('绑定成功') + this.close() + }) } } } diff --git a/src/components/mycomponent/dialog/productListAddDialog.vue b/src/components/mycomponent/dialog/productListAddDialog.vue index d438b89..a449c8b 100644 --- a/src/components/mycomponent/dialog/productListAddDialog.vue +++ b/src/components/mycomponent/dialog/productListAddDialog.vue @@ -124,7 +124,7 @@ -
+
{{ param.paramName }}
diff --git a/src/components/echart/barChart/MixChart.vue b/src/components/echart/barChart/MixChart.vue index c47e798..2b1d478 100644 --- a/src/components/echart/barChart/MixChart.vue +++ b/src/components/echart/barChart/MixChart.vue @@ -2,7 +2,7 @@
@@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/lineChart/gradientLineChart.vue b/src/components/echart/lineChart/gradientLineChart.vue index 0078deb..945f9af 100644 --- a/src/components/echart/lineChart/gradientLineChart.vue +++ b/src/components/echart/lineChart/gradientLineChart.vue @@ -68,7 +68,7 @@ option: { grid: { left: 10, - right: 5, + right: 10, bottom: 30, top: 10, containLabel: true, diff --git a/src/components/mycomponent/dialog/productBindDialog.vue b/src/components/mycomponent/dialog/productBindDialog.vue index d387996..abc0d56 100644 --- a/src/components/mycomponent/dialog/productBindDialog.vue +++ b/src/components/mycomponent/dialog/productBindDialog.vue @@ -17,7 +17,7 @@ 添加服务
- + - + @@ -60,7 +60,7 @@ }, data() { return { - loading: ture, + loading: true, tableData: [], isShowInfo: false, serviceList: [], @@ -74,53 +74,56 @@ }, methods: { close() { + this.isShowInfo = false this.$emit('close') }, - initDialog(row){ + initDialog(row) { this.isShowInfo = true - if(this.dataInfo){ + if (this.dataInfo) { this.fetchBindList(row.id) } }, - fetchBindList(id){ + fetchBindList(id) { this.loading = true - listBindService({id:id}).then(res=>{ + listBindService({ id: id }).then(res => { this.tableData = res this.loading = false }) }, bindServeClick() { const obj = { - id:'', + id: '', serviceCode: '', serviceName: '', typeCode: '', + typeCodeName: '', description: '', serviceTime: '', remark: '' } this.tableData.push(obj) }, - changeService(val, index){ - const service = this.serviceList.filter(item=>item.id==val)[0] + changeService(val, index) { + const service = this.serviceList.filter(item => item.id == val)[0] this.tableData[index].id = service.id this.tableData[index].serviceCode = service.serviceCode this.tableData[index].serviceName = service.serviceName this.tableData[index].typeCode = service.typeCode + this.tableData[index].typeCodeName = service.typeCodeName this.tableData[index].description = service.description this.tableData[index].serviceTime = service.serviceTime this.tableData[index].remark = service.remark }, - bindService(){ - for(const item of this.tableData){ - const data = { - serviceId: item.id, - productId: this.dataInfo.id - } - bindServ(data).then(res=>{ - // this.$message.success('绑定成功') - }) + bindService() { + const serviceIds = this.tableData.map(item => item.id) + const data = { + serviceIds: serviceIds, + productId: this.dataInfo.id } + bindServ(data).then(res => { + this.$message.success('绑定成功') + this.close() + }) } } } diff --git a/src/components/mycomponent/dialog/productListAddDialog.vue b/src/components/mycomponent/dialog/productListAddDialog.vue index d438b89..a449c8b 100644 --- a/src/components/mycomponent/dialog/productListAddDialog.vue +++ b/src/components/mycomponent/dialog/productListAddDialog.vue @@ -124,7 +124,7 @@ -
+
{{ param.paramName }}
diff --git a/src/components/mycomponent/dialog/snCodeRulsDialog.vue b/src/components/mycomponent/dialog/snCodeRulsDialog.vue index dc6cf3f..eba7f1a 100644 --- a/src/components/mycomponent/dialog/snCodeRulsDialog.vue +++ b/src/components/mycomponent/dialog/snCodeRulsDialog.vue @@ -165,7 +165,7 @@ return aryTemp }) // 提交数据 - S_add({ snQuantity: this.addInfo.snQuantity, ruleList: subData }).then(resp => { + S_add({ snQuantity: this.codeLength, ruleList: subData }).then(resp => { this.$message.success('添加成功') this.close() this.reset() diff --git a/src/components/echart/barChart/MixChart.vue b/src/components/echart/barChart/MixChart.vue index c47e798..2b1d478 100644 --- a/src/components/echart/barChart/MixChart.vue +++ b/src/components/echart/barChart/MixChart.vue @@ -2,7 +2,7 @@
@@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/lineChart/gradientLineChart.vue b/src/components/echart/lineChart/gradientLineChart.vue index 0078deb..945f9af 100644 --- a/src/components/echart/lineChart/gradientLineChart.vue +++ b/src/components/echart/lineChart/gradientLineChart.vue @@ -68,7 +68,7 @@ option: { grid: { left: 10, - right: 5, + right: 10, bottom: 30, top: 10, containLabel: true, diff --git a/src/components/mycomponent/dialog/productBindDialog.vue b/src/components/mycomponent/dialog/productBindDialog.vue index d387996..abc0d56 100644 --- a/src/components/mycomponent/dialog/productBindDialog.vue +++ b/src/components/mycomponent/dialog/productBindDialog.vue @@ -17,7 +17,7 @@ 添加服务
- + - + @@ -60,7 +60,7 @@ }, data() { return { - loading: ture, + loading: true, tableData: [], isShowInfo: false, serviceList: [], @@ -74,53 +74,56 @@ }, methods: { close() { + this.isShowInfo = false this.$emit('close') }, - initDialog(row){ + initDialog(row) { this.isShowInfo = true - if(this.dataInfo){ + if (this.dataInfo) { this.fetchBindList(row.id) } }, - fetchBindList(id){ + fetchBindList(id) { this.loading = true - listBindService({id:id}).then(res=>{ + listBindService({ id: id }).then(res => { this.tableData = res this.loading = false }) }, bindServeClick() { const obj = { - id:'', + id: '', serviceCode: '', serviceName: '', typeCode: '', + typeCodeName: '', description: '', serviceTime: '', remark: '' } this.tableData.push(obj) }, - changeService(val, index){ - const service = this.serviceList.filter(item=>item.id==val)[0] + changeService(val, index) { + const service = this.serviceList.filter(item => item.id == val)[0] this.tableData[index].id = service.id this.tableData[index].serviceCode = service.serviceCode this.tableData[index].serviceName = service.serviceName this.tableData[index].typeCode = service.typeCode + this.tableData[index].typeCodeName = service.typeCodeName this.tableData[index].description = service.description this.tableData[index].serviceTime = service.serviceTime this.tableData[index].remark = service.remark }, - bindService(){ - for(const item of this.tableData){ - const data = { - serviceId: item.id, - productId: this.dataInfo.id - } - bindServ(data).then(res=>{ - // this.$message.success('绑定成功') - }) + bindService() { + const serviceIds = this.tableData.map(item => item.id) + const data = { + serviceIds: serviceIds, + productId: this.dataInfo.id } + bindServ(data).then(res => { + this.$message.success('绑定成功') + this.close() + }) } } } diff --git a/src/components/mycomponent/dialog/productListAddDialog.vue b/src/components/mycomponent/dialog/productListAddDialog.vue index d438b89..a449c8b 100644 --- a/src/components/mycomponent/dialog/productListAddDialog.vue +++ b/src/components/mycomponent/dialog/productListAddDialog.vue @@ -124,7 +124,7 @@ -
+
{{ param.paramName }}
diff --git a/src/components/mycomponent/dialog/snCodeRulsDialog.vue b/src/components/mycomponent/dialog/snCodeRulsDialog.vue index dc6cf3f..eba7f1a 100644 --- a/src/components/mycomponent/dialog/snCodeRulsDialog.vue +++ b/src/components/mycomponent/dialog/snCodeRulsDialog.vue @@ -165,7 +165,7 @@ return aryTemp }) // 提交数据 - S_add({ snQuantity: this.addInfo.snQuantity, ruleList: subData }).then(resp => { + S_add({ snQuantity: this.codeLength, ruleList: subData }).then(resp => { this.$message.success('添加成功') this.close() this.reset() diff --git a/src/views/dashboard/components/commonSelectChart.vue b/src/views/dashboard/components/commonSelectChart.vue index d9e611f..ffdfb1c 100644 --- a/src/views/dashboard/components/commonSelectChart.vue +++ b/src/views/dashboard/components/commonSelectChart.vue @@ -1,5 +1,5 @@ @@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/lineChart/gradientLineChart.vue b/src/components/echart/lineChart/gradientLineChart.vue index 0078deb..945f9af 100644 --- a/src/components/echart/lineChart/gradientLineChart.vue +++ b/src/components/echart/lineChart/gradientLineChart.vue @@ -68,7 +68,7 @@ option: { grid: { left: 10, - right: 5, + right: 10, bottom: 30, top: 10, containLabel: true, diff --git a/src/components/mycomponent/dialog/productBindDialog.vue b/src/components/mycomponent/dialog/productBindDialog.vue index d387996..abc0d56 100644 --- a/src/components/mycomponent/dialog/productBindDialog.vue +++ b/src/components/mycomponent/dialog/productBindDialog.vue @@ -17,7 +17,7 @@ 添加服务
- + - + @@ -60,7 +60,7 @@ }, data() { return { - loading: ture, + loading: true, tableData: [], isShowInfo: false, serviceList: [], @@ -74,53 +74,56 @@ }, methods: { close() { + this.isShowInfo = false this.$emit('close') }, - initDialog(row){ + initDialog(row) { this.isShowInfo = true - if(this.dataInfo){ + if (this.dataInfo) { this.fetchBindList(row.id) } }, - fetchBindList(id){ + fetchBindList(id) { this.loading = true - listBindService({id:id}).then(res=>{ + listBindService({ id: id }).then(res => { this.tableData = res this.loading = false }) }, bindServeClick() { const obj = { - id:'', + id: '', serviceCode: '', serviceName: '', typeCode: '', + typeCodeName: '', description: '', serviceTime: '', remark: '' } this.tableData.push(obj) }, - changeService(val, index){ - const service = this.serviceList.filter(item=>item.id==val)[0] + changeService(val, index) { + const service = this.serviceList.filter(item => item.id == val)[0] this.tableData[index].id = service.id this.tableData[index].serviceCode = service.serviceCode this.tableData[index].serviceName = service.serviceName this.tableData[index].typeCode = service.typeCode + this.tableData[index].typeCodeName = service.typeCodeName this.tableData[index].description = service.description this.tableData[index].serviceTime = service.serviceTime this.tableData[index].remark = service.remark }, - bindService(){ - for(const item of this.tableData){ - const data = { - serviceId: item.id, - productId: this.dataInfo.id - } - bindServ(data).then(res=>{ - // this.$message.success('绑定成功') - }) + bindService() { + const serviceIds = this.tableData.map(item => item.id) + const data = { + serviceIds: serviceIds, + productId: this.dataInfo.id } + bindServ(data).then(res => { + this.$message.success('绑定成功') + this.close() + }) } } } diff --git a/src/components/mycomponent/dialog/productListAddDialog.vue b/src/components/mycomponent/dialog/productListAddDialog.vue index d438b89..a449c8b 100644 --- a/src/components/mycomponent/dialog/productListAddDialog.vue +++ b/src/components/mycomponent/dialog/productListAddDialog.vue @@ -124,7 +124,7 @@ -
+
{{ param.paramName }}
diff --git a/src/components/mycomponent/dialog/snCodeRulsDialog.vue b/src/components/mycomponent/dialog/snCodeRulsDialog.vue index dc6cf3f..eba7f1a 100644 --- a/src/components/mycomponent/dialog/snCodeRulsDialog.vue +++ b/src/components/mycomponent/dialog/snCodeRulsDialog.vue @@ -165,7 +165,7 @@ return aryTemp }) // 提交数据 - S_add({ snQuantity: this.addInfo.snQuantity, ruleList: subData }).then(resp => { + S_add({ snQuantity: this.codeLength, ruleList: subData }).then(resp => { this.$message.success('添加成功') this.close() this.reset() diff --git a/src/views/dashboard/components/commonSelectChart.vue b/src/views/dashboard/components/commonSelectChart.vue index d9e611f..ffdfb1c 100644 --- a/src/views/dashboard/components/commonSelectChart.vue +++ b/src/views/dashboard/components/commonSelectChart.vue @@ -1,5 +1,5 @@ @@ -23,7 +23,7 @@ }, width: { type: String, - default: "500px", + default: "100%", }, height: { type: String, diff --git a/src/components/echart/lineChart/gradientLineChart.vue b/src/components/echart/lineChart/gradientLineChart.vue index 0078deb..945f9af 100644 --- a/src/components/echart/lineChart/gradientLineChart.vue +++ b/src/components/echart/lineChart/gradientLineChart.vue @@ -68,7 +68,7 @@ option: { grid: { left: 10, - right: 5, + right: 10, bottom: 30, top: 10, containLabel: true, diff --git a/src/components/mycomponent/dialog/productBindDialog.vue b/src/components/mycomponent/dialog/productBindDialog.vue index d387996..abc0d56 100644 --- a/src/components/mycomponent/dialog/productBindDialog.vue +++ b/src/components/mycomponent/dialog/productBindDialog.vue @@ -17,7 +17,7 @@ 添加服务
- + - + @@ -60,7 +60,7 @@ }, data() { return { - loading: ture, + loading: true, tableData: [], isShowInfo: false, serviceList: [], @@ -74,53 +74,56 @@ }, methods: { close() { + this.isShowInfo = false this.$emit('close') }, - initDialog(row){ + initDialog(row) { this.isShowInfo = true - if(this.dataInfo){ + if (this.dataInfo) { this.fetchBindList(row.id) } }, - fetchBindList(id){ + fetchBindList(id) { this.loading = true - listBindService({id:id}).then(res=>{ + listBindService({ id: id }).then(res => { this.tableData = res this.loading = false }) }, bindServeClick() { const obj = { - id:'', + id: '', serviceCode: '', serviceName: '', typeCode: '', + typeCodeName: '', description: '', serviceTime: '', remark: '' } this.tableData.push(obj) }, - changeService(val, index){ - const service = this.serviceList.filter(item=>item.id==val)[0] + changeService(val, index) { + const service = this.serviceList.filter(item => item.id == val)[0] this.tableData[index].id = service.id this.tableData[index].serviceCode = service.serviceCode this.tableData[index].serviceName = service.serviceName this.tableData[index].typeCode = service.typeCode + this.tableData[index].typeCodeName = service.typeCodeName this.tableData[index].description = service.description this.tableData[index].serviceTime = service.serviceTime this.tableData[index].remark = service.remark }, - bindService(){ - for(const item of this.tableData){ - const data = { - serviceId: item.id, - productId: this.dataInfo.id - } - bindServ(data).then(res=>{ - // this.$message.success('绑定成功') - }) + bindService() { + const serviceIds = this.tableData.map(item => item.id) + const data = { + serviceIds: serviceIds, + productId: this.dataInfo.id } + bindServ(data).then(res => { + this.$message.success('绑定成功') + this.close() + }) } } } diff --git a/src/components/mycomponent/dialog/productListAddDialog.vue b/src/components/mycomponent/dialog/productListAddDialog.vue index d438b89..a449c8b 100644 --- a/src/components/mycomponent/dialog/productListAddDialog.vue +++ b/src/components/mycomponent/dialog/productListAddDialog.vue @@ -124,7 +124,7 @@ -
+
{{ param.paramName }}
diff --git a/src/components/mycomponent/dialog/snCodeRulsDialog.vue b/src/components/mycomponent/dialog/snCodeRulsDialog.vue index dc6cf3f..eba7f1a 100644 --- a/src/components/mycomponent/dialog/snCodeRulsDialog.vue +++ b/src/components/mycomponent/dialog/snCodeRulsDialog.vue @@ -165,7 +165,7 @@ return aryTemp }) // 提交数据 - S_add({ snQuantity: this.addInfo.snQuantity, ruleList: subData }).then(resp => { + S_add({ snQuantity: this.codeLength, ruleList: subData }).then(resp => { this.$message.success('添加成功') this.close() this.reset() diff --git a/src/views/dashboard/components/commonSelectChart.vue b/src/views/dashboard/components/commonSelectChart.vue index d9e611f..ffdfb1c 100644 --- a/src/views/dashboard/components/commonSelectChart.vue +++ b/src/views/dashboard/components/commonSelectChart.vue @@ -1,5 +1,5 @@