From 629abbd70c66ff42fc19bb30858d8d80c384bf87 Mon Sep 17 00:00:00 2001 From: tczjx58520 <2283600185@qq.com> Date: Mon, 11 May 2020 16:57:44 +0800 Subject: [PATCH 1/2] =?UTF-8?q?5.11=20=E4=BF=AE=E6=94=B9=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/lang/en.js | 1 + src/lang/zh.js | 1 + src/views/SaleOrder/SaleOrderList.vue | 4 + src/views/StockApply/AddStockApply.vue | 5 +- src/views/StockApply/components/MyDialog.vue | 5 +- src/views/StockCount/orderImplDetail.vue | 174 +++++++++++---- src/views/StockCount/orderReport.vue | 2 +- src/views/StockCount/purchaseCount.vue | 18 +- src/views/StockCount/stockOrderCount.vue | 16 +- src/views/StockCount/stockOrderExecute.vue | 18 +- src/views/StockCount/stockOrderlist.vue | 222 ++++++++++++++----- src/views/StockCount/supplierOnTimeABC.vue | 19 +- src/views/StockOrder/StockOrderList.vue | 28 ++- src/views/Supplier/SupplierList.vue | 2 +- test.zip | Bin 0 -> 14990498 bytes 15 files changed, 398 insertions(+), 117 deletions(-) create mode 100644 test.zip diff --git a/src/lang/en.js b/src/lang/en.js index 4cf7a3d7..132c88c6 100644 --- a/src/lang/en.js +++ b/src/lang/en.js @@ -3353,6 +3353,7 @@ export default { cwxx: 'finance info.', fzxx: 'other info.', gyskh: 'supplier evaluation', + gyscf: 'supplier punish', sctjd: 'generate price adjustment form', tzdmx: 'adjustment form detail', cgdyj: 'purchase order original price', diff --git a/src/lang/zh.js b/src/lang/zh.js index 733e14cd..f47419eb 100644 --- a/src/lang/zh.js +++ b/src/lang/zh.js @@ -3373,6 +3373,7 @@ export default { cwxx: '财务信息', fzxx: '辅助信息', gyskh: '供应商考核', + gyscf: '供应商惩罚', sctjd: '生成调价单', tzdmx: '调整单明细', cgdyj: '采购单原价', diff --git a/src/views/SaleOrder/SaleOrderList.vue b/src/views/SaleOrder/SaleOrderList.vue index 45bd162b..35038623 100644 --- a/src/views/SaleOrder/SaleOrderList.vue +++ b/src/views/SaleOrder/SaleOrderList.vue @@ -435,6 +435,10 @@ export default { getlist() { // 物料需求计划列表数据 this.listLoading = true + if (this.countquery) { + console.log('this.countquery====', this.countquery) + this.getemplist.supplierId = this.countquery + } searchsaleOrder(this.getemplist).then(res => { if (res.data.ret === 200) { this.list = res.data.data.content.list diff --git a/src/views/StockApply/AddStockApply.vue b/src/views/StockApply/AddStockApply.vue index 4da7128b..fac8c408 100644 --- a/src/views/StockApply/AddStockApply.vue +++ b/src/views/StockApply/AddStockApply.vue @@ -14,7 +14,7 @@ - + @@ -303,6 +303,9 @@ export default { }, // 采购申请单规则数据 personalrules: { + title: [ + { required: true, message: '请填写采购主题', trigger: 'change' } + ], applyRepositoryId: [ { required: true, validator: validatePass6, trigger: 'change' } ], diff --git a/src/views/StockApply/components/MyDialog.vue b/src/views/StockApply/components/MyDialog.vue index 8ce540fd..0c2eb6cc 100644 --- a/src/views/StockApply/components/MyDialog.vue +++ b/src/views/StockApply/components/MyDialog.vue @@ -7,7 +7,7 @@ - + @@ -222,6 +222,9 @@ export default { control: false, // 采购申请单规则数据 personalrules: { + title: [ + { required: true, message: '请填写采购主题', trigger: 'change' } + ], applyPersonId: [ { required: true, validator: validatePass, trigger: 'change' } ], diff --git a/src/views/StockCount/orderImplDetail.vue b/src/views/StockCount/orderImplDetail.vue index f321af7e..9322c611 100644 --- a/src/views/StockCount/orderImplDetail.vue +++ b/src/views/StockCount/orderImplDetail.vue @@ -26,33 +26,47 @@ ref="table" :height="tableHeight" :data="list" + :span-method="arraySpanMethod" size="small" border style="width: 100%" @row-click="clickRow"> + + - - @@ -90,7 +94,7 @@ import waves from '@/directive/waves' // Waves directive import Pagination from '@/components/Pagination' import permission from '@/directive/permission/index.js' // 权限判断指令 import permission2 from '@/directive/permission2/index.js' // 权限判断指令 -import checkPermission from '@/utils/permission' // 权限判断函数 +import checkPermission from '@/utils/permission' // 权限判断函数11 import MyEmp from './components/MyEmp' import DetailList from './components/DetailList' import MyDialog from './components/MyDialog' @@ -139,7 +143,6 @@ export default { data() { return { tableHeight: 200, - first: '', step1: '', step2: '', @@ -286,16 +289,110 @@ export default { updatecountry() { this.getlist() }, + getSpanArr(data) { + this.spanArr = [] + for (var i = 0; i < data.length; i++) { + if (i === 0) { + this.spanArr.push(1) + this.pos = 0 + } else { + // 判断当前元素与上一个元素是否相同 + if (data[i].orderId === data[i - 1].orderId) { + this.spanArr[this.pos] += 1 + this.spanArr.push(0) + } else { + this.spanArr.push(1) + this.pos = i + } + } + } + console.log('this.spanArr=================', this.spanArr) + }, + arraySpanMethod({ row, column, rowIndex, columnIndex }) { + const _row = this.spanArr[rowIndex] + const _col = _row > 0 ? 1 : 0 + if (columnIndex !== 2 && columnIndex !== 3 && columnIndex !== 4 && columnIndex !== 5 && columnIndex !== 6 && columnIndex !== 7 && columnIndex !== 8) { + return { + rowspan: _row, + colspan: _col + } + } + }, getlist() { // 物料需求计划列表数据 this.listLoading = true orderImplDetail(this.getemplist).then(res => { if (res.data.ret === 200) { - this.list = res.data.data.content.list - for (let i = 0; i < this.list.length; i++) { - this.list[i].heji = this.list[i].totalMoney + this.list[i].taxMoney + const list = res.data.data.content.list + for (let i = 0; i < list.length; i++) { + list[i].heji = list[i].totalMoney + list[i].taxMoney } - // this.total = res.data.data.content.totalCount + const needlist = list + const newarr = list.map(item => { + return item.stockOrderDetailVos + }) + const newarr2 = [].concat.apply([], newarr) + const processarr = this._.cloneDeep(newarr2) + for (const i in needlist) { + for (const j in processarr) { + if (needlist[i].id === processarr[j].orderId) { + processarr[j].id = needlist[i].id + processarr[j].allDiscountMoney = needlist[i].allDiscountMoney + processarr[j].allIncludeTaxDiscountMoney = needlist[i].allIncludeTaxDiscountMoney + processarr[j].allIncludeTaxMoney = needlist[i].allIncludeTaxMoney + processarr[j].allMoney = needlist[i].allMoney + processarr[j].allQuantity = needlist[i].allQuantity + processarr[j].allTaxMoney = needlist[i].allTaxMoney + processarr[j].approvalUseVos = needlist[i].approvalUseVos + processarr[j].arrivalDate = needlist[i].arrivalDate + processarr[j].countryId = needlist[i].countryId + processarr[j].countryName = needlist[i].countryName + processarr[j].createDate = needlist[i].createDate + processarr[j].createPersonId = needlist[i].createPersonId + processarr[j].createPersonName = needlist[i].createPersonName + processarr[j].currency = needlist[i].currency + processarr[j].deliveryMode = needlist[i].deliveryMode + processarr[j].deliveryModeName = needlist[i].deliveryModeName + processarr[j].deptId = needlist[i].deptId + processarr[j].deptName = needlist[i].deptName + processarr[j].endDate = needlist[i].endDate + processarr[j].endPersonId = needlist[i].endPersonId + processarr[j].endPersonName = needlist[i].endPersonName + processarr[j].isVat = needlist[i].isVat + processarr[j].judgeDate = needlist[i].judgeDate + processarr[j].judgePersonId = needlist[i].judgePersonId + processarr[j].judgePersonName = needlist[i].judgePersonName + processarr[j].judgeStat = needlist[i].judgeStat + processarr[j].modifyDate = needlist[i].modifyDate + processarr[j].modifyPersonId = needlist[i].modifyPersonId + processarr[j].modifyPersonName = needlist[i].modifyPersonName + processarr[j].orderDate = needlist[i].orderDate + processarr[j].orderNumber = needlist[i].orderNumber + processarr[j].otherMoney = needlist[i].otherMoney + processarr[j].payMode = needlist[i].payMode + processarr[j].payModeName = needlist[i].payModeName + processarr[j].receiptStat = needlist[i].receiptStat + processarr[j].settleMode = needlist[i].settleMode + processarr[j].settleModeName = needlist[i].settleModeName + processarr[j].signPersonId = needlist[i].signPersonId + processarr[j].signPersonName = needlist[i].signPersonName + processarr[j].sourceType = needlist[i].sourceType + processarr[j].stockPersonId = needlist[i].stockPersonId + processarr[j].stockPersonName = needlist[i].stockPersonName + processarr[j].stockRepositoryId = needlist[i].stockRepositoryId + processarr[j].stockRepositoryName = needlist[i].stockRepositoryName + processarr[j].stockType = needlist[i].stockType + processarr[j].stockTypeId = needlist[i].stockTypeId + processarr[j].supplierId = needlist[i].supplierId + processarr[j].supplierName = needlist[i].supplierName + processarr[j].supplierNumber = needlist[i].supplierNumber + processarr[j].title = needlist[i].title + // processarr[j].stockOrderDetailVos = needlist[i].stockOrderDetailVos + } + } + } + this.list = processarr + this.getSpanArr(processarr) } setTimeout(() => { this.listLoading = false @@ -327,18 +424,19 @@ export default { this.getemplist.beginTime = this.date[0] this.getemplist.endTime = this.date[1] } - orderImplDetail(this.getemplist).then(res => { - if (res.data.ret === 200) { - this.list = res.data.data.content.list - for (let i = 0; i < this.list.length; i++) { - this.list[i].heji = this.list[i].totalMoney + this.list[i].taxMoney - } - // this.total = res.data.data.content.totalCount - // this.restFilter() - } else { - // this.restFilter() - } - }) + this.getlist() + // orderImplDetail(this.getemplist).then(res => { + // if (res.data.ret === 200) { + // this.list = res.data.data.content.list + // for (let i = 0; i < this.list.length; i++) { + // this.list[i].heji = this.list[i].totalMoney + this.list[i].taxMoney + // } + // // this.total = res.data.data.content.totalCount + // // this.restFilter() + // } else { + // // this.restFilter() + // } + // }) }, // 采购人focus事件 handlechooseStock() { diff --git a/src/views/StockCount/orderReport.vue b/src/views/StockCount/orderReport.vue index 293e4da2..3b05b83b 100644 --- a/src/views/StockCount/orderReport.vue +++ b/src/views/StockCount/orderReport.vue @@ -385,7 +385,7 @@ export default { this.getlist() } }, - // 详情操作 + // 详情操作111 handleDetail(row) { console.log('row', row) const param = {} diff --git a/src/views/StockCount/purchaseCount.vue b/src/views/StockCount/purchaseCount.vue index 3db3b0b4..5c5778a0 100644 --- a/src/views/StockCount/purchaseCount.vue +++ b/src/views/StockCount/purchaseCount.vue @@ -30,11 +30,16 @@ border style="width: 100%" @row-click="clickRow"> - + align="center"/> --> + + + - + align="center"/> --> + + + - + align="center"/> --> + + + + + - - - - - - - + + + + + + @@ -90,7 +108,7 @@ + + diff --git a/src/views/payment/paymentList.vue b/src/views/payment/paymentList.vue index 0c087ff2..b674e3c6 100644 --- a/src/views/payment/paymentList.vue +++ b/src/views/payment/paymentList.vue @@ -136,9 +136,9 @@