|
@@ -27,7 +27,7 @@
|
|
id="purchaseOrderEdit-edit-circle-btn"
|
|
id="purchaseOrderEdit-edit-circle-btn"
|
|
@click.stop="handleEditInfo" />
|
|
@click.stop="handleEditInfo" />
|
|
</template>
|
|
</template>
|
|
- <a-descriptions :column="3">
|
|
|
|
|
|
+ <a-descriptions :column="2">
|
|
<a-descriptions-item label="供应商">{{ detail&&detail.dealerName }}</a-descriptions-item>
|
|
<a-descriptions-item label="供应商">{{ detail&&detail.dealerName }}</a-descriptions-item>
|
|
<a-descriptions-item label="支付方式">{{ detail&&detail.settleStyleEntity.name }}</a-descriptions-item>
|
|
<a-descriptions-item label="支付方式">{{ detail&&detail.settleStyleEntity.name }}</a-descriptions-item>
|
|
<a-descriptions-item label="收货人">{{ detail&&detail.consigneeName }}({{ detail&&detail.consigneeTel }})</a-descriptions-item>
|
|
<a-descriptions-item label="收货人">{{ detail&&detail.consigneeName }}({{ detail&&detail.consigneeTel }})</a-descriptions-item>
|
|
@@ -97,6 +97,7 @@
|
|
:columns="columns"
|
|
:columns="columns"
|
|
:data="loadData"
|
|
:data="loadData"
|
|
:scroll="{ x: 1370, y:300 }"
|
|
:scroll="{ x: 1370, y:300 }"
|
|
|
|
+ :defaultLoadData="false"
|
|
bordered>
|
|
bordered>
|
|
<!-- 采购数量 -->
|
|
<!-- 采购数量 -->
|
|
<template slot="storageQuantity" slot-scope="text, record">
|
|
<template slot="storageQuantity" slot-scope="text, record">
|
|
@@ -128,9 +129,9 @@
|
|
<div>
|
|
<div>
|
|
<!-- 总计 -->
|
|
<!-- 总计 -->
|
|
<a-alert type="info" showIcon style="margin-bottom:15px">
|
|
<a-alert type="info" showIcon style="margin-bottom:15px">
|
|
- <div slot="message">产品款数 <strong>{{ detail&&detail.totalCategory }}</strong> ,
|
|
|
|
- 采购数量合计 <strong>{{ detail&&detail.totalQty }}</strong> ,
|
|
|
|
- 采购金额合计¥<strong>{{ detail&&detail.totalAmount }}</strong></div>
|
|
|
|
|
|
+ <div slot="message">产品款数 <strong>{{ orderCountData&&orderCountData.totalCategory }}</strong> ,
|
|
|
|
+ 采购数量合计 <strong>{{ orderCountData&&orderCountData.totalQty }}</strong> ,
|
|
|
|
+ 采购金额合计¥<strong>{{ orderCountData&&orderCountData.totalAmount }}</strong></div>
|
|
</a-alert>
|
|
</a-alert>
|
|
<!-- 列表 -->
|
|
<!-- 列表 -->
|
|
<s-table
|
|
<s-table
|
|
@@ -190,7 +191,7 @@ import basicInfoModal from './basicInfoModal.vue'
|
|
import ProductType from '../../common/productType.js'
|
|
import ProductType from '../../common/productType.js'
|
|
import ProductBrand from '../../common/productBrand.js'
|
|
import ProductBrand from '../../common/productBrand.js'
|
|
import { purchaseDetailBySn, purchaseWriteSubmit } from '@/api/purchase'
|
|
import { purchaseDetailBySn, purchaseWriteSubmit } from '@/api/purchase'
|
|
-import { purchaseDetailList, purchaseDetailSave, purchaseDetailDel } from '@/api/purchaseDetail'
|
|
|
|
|
|
+import { purchaseDetailList, purchaseDetailSave, purchaseDetailDel, purchaseDetailCount } from '@/api/purchaseDetail'
|
|
import { productList } from '@/api/product'
|
|
import { productList } from '@/api/product'
|
|
export default {
|
|
export default {
|
|
components: { STable, VSelect, basicInfoModal, ProductType, ProductBrand },
|
|
components: { STable, VSelect, basicInfoModal, ProductType, ProductBrand },
|
|
@@ -239,6 +240,7 @@ export default {
|
|
})
|
|
})
|
|
},
|
|
},
|
|
// -------已选产品-------------
|
|
// -------已选产品-------------
|
|
|
|
+ orderCountData: null,
|
|
delLoading: false,
|
|
delLoading: false,
|
|
// 表头
|
|
// 表头
|
|
chooseColumns: [
|
|
chooseColumns: [
|
|
@@ -254,7 +256,10 @@ export default {
|
|
// 加载数据方法 必须为 Promise 对象
|
|
// 加载数据方法 必须为 Promise 对象
|
|
chooseLoadData: parameter => {
|
|
chooseLoadData: parameter => {
|
|
this.disabled = true
|
|
this.disabled = true
|
|
- return purchaseDetailList(Object.assign(parameter, this.queryParam)).then(res => {
|
|
|
|
|
|
+ // 查询总计
|
|
|
|
+ const params = Object.assign(parameter, { purchaseBillSn: this.$route.params.sn })
|
|
|
|
+ this.getCountQuery(params)
|
|
|
|
+ return purchaseDetailList(params).then(res => {
|
|
const data = res.data
|
|
const data = res.data
|
|
const no = (data.pageNo - 1) * data.pageSize
|
|
const no = (data.pageNo - 1) * data.pageSize
|
|
for (var i = 0; i < data.list.length; i++) {
|
|
for (var i = 0; i < data.list.length; i++) {
|
|
@@ -267,18 +272,24 @@ export default {
|
|
}
|
|
}
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ // 获取采购单明细统计
|
|
|
|
+ getCountQuery (params) {
|
|
|
|
+ purchaseDetailCount(params).then(res => {
|
|
|
|
+ this.orderCountData = res.data || null
|
|
|
|
+ })
|
|
|
|
+ },
|
|
// 获取采购单基本信息
|
|
// 获取采购单基本信息
|
|
getOrderDetail () {
|
|
getOrderDetail () {
|
|
purchaseDetailBySn({ sn: this.$route.params.sn }).then(res => {
|
|
purchaseDetailBySn({ sn: this.$route.params.sn }).then(res => {
|
|
if (res.status == 200) {
|
|
if (res.status == 200) {
|
|
this.detail = res.data
|
|
this.detail = res.data
|
|
}
|
|
}
|
|
- this.$message.info(res.message)
|
|
|
|
})
|
|
})
|
|
},
|
|
},
|
|
// 基本信息编辑成功
|
|
// 基本信息编辑成功
|
|
handleOk (data) {
|
|
handleOk (data) {
|
|
- // this.getOrderDetail()
|
|
|
|
|
|
+ this.openModal = false
|
|
|
|
+ this.getOrderDetail()
|
|
},
|
|
},
|
|
// 编辑基本信息
|
|
// 编辑基本信息
|
|
handleEditInfo () {
|
|
handleEditInfo () {
|
|
@@ -396,12 +407,12 @@ export default {
|
|
<style lang="less">
|
|
<style lang="less">
|
|
.purchaseOrderEdit-wrap{
|
|
.purchaseOrderEdit-wrap{
|
|
.billno{
|
|
.billno{
|
|
- margin: 0 0 0 60px;
|
|
|
|
- font-size: 20px;
|
|
|
|
|
|
+ margin: 0 0 0 30px;
|
|
|
|
+ font-size: 18px;
|
|
font-weight: 600;
|
|
font-weight: 600;
|
|
display: inline-block;
|
|
display: inline-block;
|
|
vertical-align: top;
|
|
vertical-align: top;
|
|
- color: rgba(0, 0, 0, 0.85);
|
|
|
|
|
|
+ color: #666;
|
|
}
|
|
}
|
|
.purchaseOrderEdit-cont{
|
|
.purchaseOrderEdit-cont{
|
|
margin-bottom: 15px;
|
|
margin-bottom: 15px;
|