|
@@ -10,31 +10,33 @@
|
|
|
<el-row :gutter="0">
|
|
|
<el-col :span="8" class="item">
|
|
|
<div class="label">出库单号</div>
|
|
|
- <div class="value">{{detailData.id}}</div>
|
|
|
+ <div class="value">{{ detailData.id }}</div>
|
|
|
</el-col>
|
|
|
<el-col :span="8" class="item">
|
|
|
<div class="label">单据日期</div>
|
|
|
- <div class="value">{{detailData.orderTime}}</div>
|
|
|
+ <div class="value">{{ detailData.orderTime }}</div>
|
|
|
</el-col>
|
|
|
<el-col :span="8" class="item">
|
|
|
<div class="label">单据状态</div>
|
|
|
- <div class="value">{{detailData.examineStatus | statusFilter}}</div>
|
|
|
+ <div class="value">
|
|
|
+ {{ detailData.examineStatus | statusFilter }}
|
|
|
+ </div>
|
|
|
</el-col>
|
|
|
<el-col :span="8" class="item">
|
|
|
<div class="label">发货单号</div>
|
|
|
- <div class="value">{{detailData.orderNo}}</div>
|
|
|
+ <div class="value">{{ detailData.orderNo }}</div>
|
|
|
</el-col>
|
|
|
<el-col :span="16" class="item">
|
|
|
<div class="label">经销商</div>
|
|
|
- <div class="value">{{detailData.customerName}}</div>
|
|
|
+ <div class="value">{{ detailData.customerName }}</div>
|
|
|
</el-col>
|
|
|
<el-col :span="8" class="item">
|
|
|
<div class="label">仓库</div>
|
|
|
- <div class="value">{{detailData.correspondName}}</div>
|
|
|
+ <div class="value">{{ detailData.correspondName }}</div>
|
|
|
</el-col>
|
|
|
<el-col :span="16" class="item">
|
|
|
<div class="label">备注</div>
|
|
|
- <div class="value">{{detailData.remark}}</div>
|
|
|
+ <div class="value">{{ detailData.remark }}</div>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</div>
|
|
@@ -52,34 +54,84 @@
|
|
|
stripe
|
|
|
max-height="400"
|
|
|
show-summary
|
|
|
- :summary-method="$getSummaries">
|
|
|
- <el-table-column align="center" label="序号" type="index" width="50"></el-table-column>
|
|
|
- <el-table-column align="center" label="销售订单号" prop="mainOrderId" min-width="180" show-overflow-tooltip>
|
|
|
+ :summary-method="$getSummaries"
|
|
|
+ >
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="序号"
|
|
|
+ type="index"
|
|
|
+ width="50"
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="销售订单号"
|
|
|
+ prop="mainOrderId"
|
|
|
+ min-width="180"
|
|
|
+ show-overflow-tooltip
|
|
|
+ >
|
|
|
<template slot-scope="scope">
|
|
|
- {{ (scope.row.orderType == 'TRADE' || scope.row.orderType == 'HOME') ? scope.row.enginOrderNo : scope.row.mainOrderId }}
|
|
|
+ {{
|
|
|
+ scope.row.orderType == "TRADE" || scope.row.orderType == "HOME"
|
|
|
+ ? scope.row.enginOrderNo
|
|
|
+ : scope.row.mainOrderId
|
|
|
+ }}
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
- <el-table-column align="center" label="物料编码" prop="materialCode" min-width="120" show-overflow-tooltip></el-table-column>
|
|
|
- <el-table-column align="center" label="产品编码" prop="materialOldNumber" min-width="120" show-overflow-tooltip></el-table-column>
|
|
|
- <el-table-column align="center" label="产品名称" prop="materialName" min-width="160" show-overflow-tooltip></el-table-column>
|
|
|
- <el-table-column align="center" label="规格型号" prop="specification" min-width="160" show-overflow-tooltip></el-table-column>
|
|
|
- <el-table-column align="center" label="单位" prop="unit" min-width="100" show-overflow-tooltip></el-table-column>
|
|
|
- <el-table-column align="right" label="数量" prop="refundableQty" min-width="100" show-overflow-tooltip>
|
|
|
-
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="物料编码"
|
|
|
+ prop="materialCode"
|
|
|
+ min-width="120"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="产品编码"
|
|
|
+ prop="materialOldNumber"
|
|
|
+ min-width="120"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="产品名称"
|
|
|
+ prop="materialName"
|
|
|
+ min-width="160"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="规格型号"
|
|
|
+ prop="specification"
|
|
|
+ min-width="160"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="center"
|
|
|
+ label="单位"
|
|
|
+ prop="unit"
|
|
|
+ min-width="100"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="right"
|
|
|
+ label="数量"
|
|
|
+ prop="refundableQty"
|
|
|
+ min-width="100"
|
|
|
+ show-overflow-tooltip
|
|
|
+ >
|
|
|
<template slot-scope="scope">
|
|
|
- <template v-if="edit">
|
|
|
- <el-input
|
|
|
- size="mini"
|
|
|
- class="input"
|
|
|
- v-model="scope.row.refundableQty"
|
|
|
- placeholder="请输入数量"
|
|
|
- ></el-input>
|
|
|
+ <template v-if="edit">
|
|
|
+ <el-input
|
|
|
+ size="mini"
|
|
|
+ class="input"
|
|
|
+ v-model="scope.row.refundableQty"
|
|
|
+ placeholder="请输入数量"
|
|
|
+ ></el-input>
|
|
|
+ </template>
|
|
|
+ <template v-else>
|
|
|
+ {{ scope.row.refundableQty }}
|
|
|
</template>
|
|
|
- <template v-else>
|
|
|
- {{scope.row.refundableQty}}
|
|
|
- </template>
|
|
|
</template>
|
|
|
-
|
|
|
</el-table-column>
|
|
|
<!-- <el-table-column align="right" label="单价" prop="price" min-width="100" show-overflow-tooltip>
|
|
|
<template slot-scope="scope">
|
|
@@ -91,13 +143,37 @@
|
|
|
{{ scope.row.payAmount | numToFixed }}
|
|
|
</template>
|
|
|
</el-table-column> -->
|
|
|
- <el-table-column align="left" label="表头备注" prop="headerRemark" min-width="160" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="left"
|
|
|
+ label="表头备注"
|
|
|
+ prop="headerRemark"
|
|
|
+ min-width="160"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
<!-- <el-table-column align="left" label="发货申请备注" prop="remark" min-width="160" show-overflow-tooltip></el-table-column> -->
|
|
|
- <el-table-column align="left" label="表体备注" prop="invoiceRemark" min-width="160" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="left"
|
|
|
+ label="表体备注"
|
|
|
+ prop="invoiceRemark"
|
|
|
+ min-width="160"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
|
|
|
- <el-table-column align="left" label="表头业务员" prop="k3ServiceName" min-width="100" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="left"
|
|
|
+ label="表头业务员"
|
|
|
+ prop="k3ServiceName"
|
|
|
+ min-width="100"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
|
|
|
- <el-table-column align="left" label="表体业务员" prop="serviceName" min-width="100" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column
|
|
|
+ align="left"
|
|
|
+ label="表体业务员"
|
|
|
+ prop="serviceName"
|
|
|
+ min-width="100"
|
|
|
+ show-overflow-tooltip
|
|
|
+ ></el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
|
|
@@ -108,64 +184,66 @@
|
|
|
<el-row :gutter="0">
|
|
|
<el-col :xs="12" :sm="12" :lg="12" class="item">
|
|
|
<div class="label">审批人</div>
|
|
|
- <div class="value">{{detailData.approvalName}}</div>
|
|
|
+ <div class="value">{{ detailData.approvalName }}</div>
|
|
|
</el-col>
|
|
|
<el-col :xs="12" :sm="12" :lg="12" class="item">
|
|
|
<div class="label">制单人</div>
|
|
|
- <div class="value">{{detailData.createBy}}</div>
|
|
|
+ <div class="value">{{ detailData.createBy }}</div>
|
|
|
</el-col>
|
|
|
<el-col :xs="12" :sm="12" :lg="12" class="item">
|
|
|
<div class="label">审批结果</div>
|
|
|
- <div class="value">{{detailData.examineStatus | statusFilter}}</div>
|
|
|
+ <div class="value">
|
|
|
+ {{ detailData.examineStatus | statusFilter }}
|
|
|
+ </div>
|
|
|
</el-col>
|
|
|
<el-col :xs="12" :sm="12" :lg="12" class="item">
|
|
|
<div class="label">审批时间</div>
|
|
|
- <div class="value">{{detailData.approvalTime}}</div>
|
|
|
+ <div class="value">{{ detailData.approvalTime }}</div>
|
|
|
</el-col>
|
|
|
<el-col :xs="24" :sm="24" :lg="24" class="item">
|
|
|
<div class="label">审批说明</div>
|
|
|
- <div class="value">{{detailData.approvalRemark}}</div>
|
|
|
+ <div class="value">{{ detailData.approvalRemark }}</div>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <div style="margin:10px" v-if="edit">
|
|
|
- <el-button type="primary" @click="updateNum">保存</el-button>
|
|
|
-</div>
|
|
|
+ <div style="margin: 10px" v-if="edit">
|
|
|
+ <el-button type="primary" @click="updateNum">保存</el-button>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import print from 'vue-print-nb'
|
|
|
-import { getDetail ,updateNum} from "@/api/supply/sales";
|
|
|
+import print from "vue-print-nb";
|
|
|
+import { getDetail, updateNum } from "@/api/supply/sales";
|
|
|
|
|
|
export default {
|
|
|
- name: 'SalesDetail',
|
|
|
- componentName: 'SalesDetail',
|
|
|
- props: ['listItem','edit'],
|
|
|
+ name: "SalesDetail",
|
|
|
+ componentName: "SalesDetail",
|
|
|
+ props: ["listItem", "edit"],
|
|
|
directives: {
|
|
|
- print
|
|
|
+ print,
|
|
|
},
|
|
|
filters: {
|
|
|
statusFilter(val) {
|
|
|
const statusList = [
|
|
|
- { label: '已保存', value: 'SAVE' },
|
|
|
- { label: '待审核', value: 'WAIT' },
|
|
|
- { label: '审核通过', value: 'OK' },
|
|
|
- // { label: '审核驳回', value: 'FAIL' },,
|
|
|
+ { label: "已保存", value: "SAVE" },
|
|
|
+ { label: "待审核", value: "WAIT" },
|
|
|
+ { label: "审核通过", value: "OK" },
|
|
|
+ // { label: '审核驳回', value: 'FAIL' },,
|
|
|
];
|
|
|
- let obj = statusList.find(o => o.value == val);
|
|
|
- return obj ? obj.label : ''
|
|
|
- }
|
|
|
+ let obj = statusList.find((o) => o.value == val);
|
|
|
+ return obj ? obj.label : "";
|
|
|
+ },
|
|
|
},
|
|
|
data() {
|
|
|
return {
|
|
|
printObj: {
|
|
|
- id: 'printMe'
|
|
|
+ id: "printMe",
|
|
|
},
|
|
|
detailData: {},
|
|
|
- }
|
|
|
+ };
|
|
|
},
|
|
|
|
|
|
created() {
|
|
@@ -175,51 +253,46 @@ export default {
|
|
|
methods: {
|
|
|
// 返回列表
|
|
|
goBack() {
|
|
|
- this.$emit('backListFormDetail');
|
|
|
- this.$parent.edit = false
|
|
|
+ this.$emit("backListFormDetail");
|
|
|
+ this.$parent.edit = false;
|
|
|
},
|
|
|
- updateNum(){
|
|
|
- this.detailData.saleOrderData.forEach(item => {
|
|
|
- item.invoiceNum = +item.refundableQty
|
|
|
+ updateNum() {
|
|
|
+ this.detailData.saleOrderData.forEach((item) => {
|
|
|
+ item.invoiceNum = +item.refundableQty;
|
|
|
});
|
|
|
updateNum({
|
|
|
- ...this.detailData
|
|
|
- }).then(res=>{
|
|
|
+ ...this.detailData,
|
|
|
+ }).then((res) => {
|
|
|
this.$successMsg("修改成功");
|
|
|
- this.$parent.edit = false
|
|
|
- this.goBack();
|
|
|
+ this.$parent.edit = false;
|
|
|
+ this.goBack();
|
|
|
this.$parent.getList();
|
|
|
- })
|
|
|
-
|
|
|
-
|
|
|
+ });
|
|
|
},
|
|
|
// 获取详情
|
|
|
getDetail() {
|
|
|
- getDetail({id: this.listItem.id}).then(res => {
|
|
|
- if(res.data.saleOrderData) {
|
|
|
- res.data.saleOrderData.forEach(item => {
|
|
|
- item.sums1 = ['refundableQty'];
|
|
|
- item.sums2 = ['payAmount', 'price'];
|
|
|
- })
|
|
|
+ getDetail({ id: this.listItem.id }).then((res) => {
|
|
|
+ if (res.data.saleOrderData) {
|
|
|
+ res.data.saleOrderData.forEach((item) => {
|
|
|
+ item.sums1 = ["refundableQty"];
|
|
|
+ item.sums2 = ["payAmount", "price"];
|
|
|
+ });
|
|
|
}
|
|
|
this.detailData = res.data;
|
|
|
- })
|
|
|
+ });
|
|
|
},
|
|
|
- }
|
|
|
-}
|
|
|
+ },
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style scoped lang="scss">
|
|
|
- .detail-container {
|
|
|
- width: 100%;
|
|
|
- height: 100%;
|
|
|
- .input{
|
|
|
- ::v-deep .el-input__inner{
|
|
|
- text-align: right !important;
|
|
|
+.detail-container {
|
|
|
+ width: 100%;
|
|
|
+ height: 100%;
|
|
|
+ .input {
|
|
|
+ ::v-deep .el-input__inner {
|
|
|
+ text-align: right !important;
|
|
|
}
|
|
|
-
|
|
|
}
|
|
|
- }
|
|
|
-
|
|
|
-
|
|
|
+}
|
|
|
</style>
|