This commit is contained in:
jiask 2025-09-15 09:56:09 +08:00
parent eb2a2eb7c9
commit cfdb17bec7
1 changed files with 55 additions and 53 deletions

View File

@ -1,31 +1,31 @@
<template> <template>
<div style="padding: 10px;background: #E5EBF6;min-height: 830px;"> <div style="padding: 10px;background: #E5EBF6;min-height: 830px;">
<div style="background: #FFF;padding: 10px;border-radius: 10px;margin-bottom: 20px;"> <div style="background: #FFF;padding: 10px;border-radius: 10px;margin-bottom: 20px;">
<el-descriptions style="margin-bottom: 20px;" title="基本信息" :column="4" size="medium" border> <el-descriptions style="margin-bottom: 20px;" title="基本信息" :column="4" size="medium" border>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">询价单号</template> <template slot="label">询价单号</template>
{{baseInfo.inquiryCode}} {{baseInfo.inquiryCode}}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">询价标题</template> <template slot="label">询价标题</template>
{{baseInfo.title}} {{baseInfo.title}}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">联系人</template> <template slot="label">联系人</template>
{{ baseInfo.linkMan }} {{ baseInfo.linkMan }}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">联系电话</template> <template slot="label">联系电话</template>
{{ baseInfo.phone }} {{ baseInfo.phone }}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">送货地址</template> <template slot="label">送货地址</template>
{{ baseInfo.address }} {{ baseInfo.address }}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">交货时间</template> <template slot="label">交货时间</template>
{{ baseInfo.arrivalTime }} {{ baseInfo.arrivalTime }}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">报价时间</template> <template slot="label">报价时间</template>
{{ baseInfo.startTime }} - {{ baseInfo.startTime }} {{ baseInfo.startTime }} - {{ baseInfo.startTime }}
@ -33,62 +33,62 @@
<el-descriptions-item> <el-descriptions-item>
<template slot="label">要求到货时间</template> <template slot="label">要求到货时间</template>
{{baseInfo.requestArrivalTime}} {{baseInfo.requestArrivalTime}}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">总金额</template> <template slot="label">总金额</template>
{{ (baseInfo.quoteAmount/100).toFixed(2) }} {{ (baseInfo.quoteAmount/100).toFixed(2) }}
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label">备注</template> <template slot="label">备注</template>
{{ baseInfo.remark }} {{ baseInfo.remark }}
</el-descriptions-item> </el-descriptions-item>
</el-descriptions> </el-descriptions>
</div> </div>
<div style="width: 100%;height: 450px;padding: 10px;border-radius: 10px;margin-bottom: 10px;background: #FFF;"> <div style="width: 100%;height: 450px;padding: 10px;border-radius: 10px;margin-bottom: 10px;background: #FFF;">
<div style="width: 100%;display: flex;justify-content: space-between;align-items: center;margin-bottom: 10px;"> <div style="width: 100%;display: flex;justify-content: space-between;align-items: center;margin-bottom: 10px;">
<div> <div>
货品信息 货品信息
</div> </div>
</div> </div>
<div style="width: 100%;height: 400px;overflow-y: auto;"> <div style="width: 100%;height: 400px;overflow-y: auto;">
<el-table v-loading="loading" :data="materialList" ref="multipleTable" height="380" :row-key="(row)=>{return row.materialId}" @selection-change="handleSelectionChange"> <el-table v-loading="loading" :data="materialList" ref="multipleTable" height="380" :row-key="(row)=>{return row.materialId}" @selection-change="handleSelectionChange">
<!-- <el-table-column type="selection" width="50" align="center" :reserve-selection="true" /> --> <!-- <el-table-column type="selection" width="50" align="center" :reserve-selection="true" /> -->
<el-table-column label="序号" align="center" width="80" type="index" /> <el-table-column label="序号" align="center" width="80" type="index" />
<!-- <el-table-column label="图片" align="center" prop="" :show-overflow-tooltip="true" /> --> <!-- <el-table-column label="图片" align="center" prop="" :show-overflow-tooltip="true" /> -->
<el-table-column label="货品编码" align="center" prop="materialCode" :show-overflow-tooltip="true" /> <el-table-column label="货品编码" align="center" prop="materialCode" :show-overflow-tooltip="true" />
<el-table-column label="货品名称" align="center" prop="materialName" :show-overflow-tooltip="true" /> <el-table-column label="货品名称" align="center" prop="materialName" :show-overflow-tooltip="true" />
<el-table-column label="货品类别" align="center" prop="materialTypeName" :show-overflow-tooltip="true" /> <el-table-column label="货品类别" align="center" prop="materialTypeName" :show-overflow-tooltip="true" />
<el-table-column label="计量单位" align="center" prop="unitName" :show-overflow-tooltip="true" /> <el-table-column label="计量单位" align="center" prop="unitName" :show-overflow-tooltip="true" />
<el-table-column label="货品规格" align="center" prop="size" :show-overflow-tooltip="true"> <el-table-column label="货品规格" align="center" prop="size" :show-overflow-tooltip="true">
<!-- <template slot-scope="scope"> <!-- <template slot-scope="scope">
<span v-if="scope.row.salesMode==1">按份</span> <span v-if="scope.row.salesMode==1">按份</span>
<span v-if="scope.row.salesMode==2">称重</span> <span v-if="scope.row.salesMode==2">称重</span>
</template> --> </template> -->
</el-table-column> </el-table-column>
<el-table-column label="采购数量" align="center" prop="purNum" :show-overflow-tooltip="true" /> <el-table-column label="采购数量" align="center" prop="purNum" :show-overflow-tooltip="true" />
<el-table-column label="报价数量" align="center" prop="quoteNum" :show-overflow-tooltip="true" /> <el-table-column label="报价数量" align="center" prop="quoteNum" :show-overflow-tooltip="true" />
<el-table-column label="中选单价" align="center" prop="singlePrice" :show-overflow-tooltip="true"> <el-table-column label="中选单价" align="center" prop="singlePrice" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ (scope.row.singlePrice/100).toFixed(2) }}</span> <span>{{ (scope.row.singlePrice/100).toFixed(2) }}</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="中选总价(元)" align="center" prop="totalPrice" :show-overflow-tooltip="true"> <el-table-column label="中选总价(元)" align="center" prop="totalPrice" :show-overflow-tooltip="true">
<template slot-scope="scope"> <template slot-scope="scope">
<span>{{ (scope.row.totalPrice/100).toFixed(2) }}</span> <span>{{ (scope.row.totalPrice/100).toFixed(2) }}</span>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
</div> </div>
</div> </div>
<div style="width: 100%;height: 80px;padding: 10px;background: #FFF;border-radius: 10px;display: flex;align-items: center;justify-content: center;"> <div style="width: 100%;height: 80px;padding: 10px;background: #FFF;border-radius: 10px;display: flex;align-items: center;justify-content: center;">
<!-- <el-button type="primary" @click="confirmSave" :loading="loadingBtn">保存草稿</el-button> --> <!-- <el-button type="primary" @click="confirmSave" :loading="loadingBtn">保存草稿</el-button> -->
<el-button @click="jumpList">返回</el-button> <el-button @click="jumpList">返回</el-button>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import { getGoodsInquiryDetailInfoApi } from "@/api/foodManage/purchaseManage"; import { getGoodsInquiryDetailInfoApi } from "@/api/foodManage/purchaseManage";
export default { export default {
name: "SupplierQuotationDetail", name: "SupplierQuotationDetail",
@ -98,12 +98,12 @@ export default {
supplierQuotationData:{},// supplierQuotationData:{},//
loading:false, loading:false,
loadingBtn:false, loadingBtn:false,
baseInfo: { baseInfo: {
orderTitle:undefined, orderTitle:undefined,
contractType:undefined, contractType:undefined,
areaId:undefined, areaId:undefined,
canteenId:undefined, canteenId:undefined,
dateRange:[], dateRange:[],
}, },
// //
baseRules: { baseRules: {
@ -130,19 +130,19 @@ export default {
canteenOptions:[], canteenOptions:[],
supplierOptions:[], supplierOptions:[],
stallOptions:[], stallOptions:[],
pickerOptions: { pickerOptions: {
disabledDate(v) { disabledDate(v) {
return v.getTime() < (new Date().getTime() - 86400000);// - 86400000 return v.getTime() < (new Date().getTime() - 86400000);// - 86400000
} }
}, },
materialList:[], materialList:[],
openDialog:false, openDialog:false,
materialTreeOptions:[], materialTreeOptions:[],
// //
queryParams: { queryParams: {
pageNum: 1, pageNum: 1,
pageSize: 10, pageSize: 10,
}, },
// //
total: 0, total: 0,
@ -152,15 +152,15 @@ export default {
noMaterial:false, noMaterial:false,
}; };
}, },
created() { created() {
if(this.$route.query.supplierQuotationData){ if(this.$route.query.supplierQuotationData){
this.supplierQuotationData = JSON.parse(this.$route.query.supplierQuotationData) this.supplierQuotationData = JSON.parse(this.$route.query.supplierQuotationData)
console.log(this.supplierQuotationData) console.log(this.supplierQuotationData)
this.getContractInfo() this.getContractInfo()
} }
}, },
watch:{ watch:{
'$route.query.supplierQuotationData':function(newId, oldId) { '$route.query.supplierQuotationData':function(newId, oldId) {
if(newId){ if(newId){
this.supplierQuotationData = JSON.parse(newId) this.supplierQuotationData = JSON.parse(newId)
this.getContractInfo() this.getContractInfo()
@ -170,36 +170,38 @@ export default {
} }
}, },
}, },
methods: { methods: {
// //
jumpList() { jumpList() {
const obj = { path: "/foodManage/supplierFunction/supplierQuotationDetail" }; const obj = { path: "/foodManage/supplierFunction/supplierQuotationDetail" };
this.$tab.closeOpenPage(obj); this.$tab.closeOpenPage(obj);
this.$router.replace({ path: "/foodManage/supplierFunction/supplierQuotation" }); // this.$router.replace({ path: "/foodManage/supplierFunction/supplierQuotation" }); //
}, },
getContractInfo(){ getContractInfo(){
console.log(this.supplierQuotationData) console.log(this.supplierQuotationData)
let param = { let param = {
inquiryId:this.supplierQuotationData.inquiryId, inquiryId:this.supplierQuotationData.inquiryId,
supplierId:this.supplierQuotationData.supplierId supplierId:this.supplierQuotationData.supplierId
} }
// //
getGoodsInquiryDetailInfoApi(param).then((response) => { getGoodsInquiryDetailInfoApi(param).then((response) => {
this.baseInfo = this.supplierQuotationData; this.baseInfo = this.supplierQuotationData;
// this.$set(this.baseInfo,'dateRange',[this.baseInfo.startTime,this.baseInfo.endTime]) this.baseInfo.arrivalTime=response.data[0].arrivalTime;
this.materialList = response.data; console.log("this.baseInfo",this.baseInfo)
// this.$set(this.baseInfo,'dateRange',[this.baseInfo.startTime,this.baseInfo.endTime])
this.materialList = response.data;
// supplierPageApi({ isPaging:1,areaIdList:[] }).then((response) => { // supplierPageApi({ isPaging:1,areaIdList:[] }).then((response) => {
// this.supplierOptions = response.rows||[]; // this.supplierOptions = response.rows||[];
// }); // });
}); });
}, },
// //
handleSelectionChange(selection) { handleSelectionChange(selection) {
// this.batchIds1 = selection.map(item => item.tradeId) // this.batchIds1 = selection.map(item => item.tradeId)
// this.single = selection.length !== 1 // this.single = selection.length !== 1
// this.multiple = !selection.length // this.multiple = !selection.length
}, },
// //
formatDate(date) { formatDate(date) {
// YYYY-MM-DD // YYYY-MM-DD
@ -220,7 +222,7 @@ export default {
const minutes = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes() const minutes = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()
const seconds = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds() const seconds = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds()
return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`; return `${year}-${month}-${day} ${hours}:${minutes}:${seconds}`;
} }
} }
}; };
</script> </script>
@ -262,10 +264,10 @@ export default {
align-items: center; align-items: center;
cursor: pointer; cursor: pointer;
} }
.dish-name:hover{ .dish-name:hover{
background-color:rgba(0, 0, 0, 0.1); background-color:rgba(0, 0, 0, 0.1);
color: #4b80fd; color: #4b80fd;
} }
.dialog-center{ .dialog-center{
width: 10%; width: 10%;
@ -317,4 +319,4 @@ export default {
border: 1px solid #fff; border: 1px solid #fff;
cursor: pointer; cursor: pointer;
} }
</style> </style>