供应链接口对接

This commit is contained in:
zzyuan 2025-07-10 11:18:19 +08:00
parent dbbbe5829b
commit 9adfb412be
5 changed files with 33 additions and 42 deletions

View File

@ -88,7 +88,7 @@ export function getReturnMaterialInfoApi(data) {
// 新增退货单-保存 // 新增退货单-保存
export function addReturnMaterialApi(data) { export function addReturnMaterialApi(data) {
return request({ return request({
url: '/smart-canteen/ims_refund_goods/add', url: '/smart-canteen/ims_refund_goods/save',
method: 'post', method: 'post',
headers: { headers: {
//"merchant-id":"378915229716713472", //"merchant-id":"378915229716713472",

View File

@ -307,13 +307,13 @@ export default {
"commitStatus": this.queryParams.commitStatus, "commitStatus": this.queryParams.commitStatus,
// "approveStatus": this.queryParams.approveStatus // "approveStatus": this.queryParams.approveStatus
} }
if(this.dateRange&&this.dateRange.length>0){ // if(this.dateRange&&this.dateRange.length>0){
param.startTime=this.formatDateTime(this.dateRange[0]) // param.startTime=this.formatDate(this.dateRange[0])
param.endTime=this.formatDateTime(this.dateRange[1]) // param.endTime=this.formatDate(this.dateRange[1])
}else{ // }else{
param.startTime=undefined; // param.startTime=undefined;
param.endTime=undefined; // param.endTime=undefined;
} // }
fetchMaterialPageApi(param).then(response => { fetchMaterialPageApi(param).then(response => {
this.tableListData = response.rows; this.tableListData = response.rows;
this.total = Number(response.total); this.total = Number(response.total);

View File

@ -24,8 +24,8 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="退货仓库" prop="warehouseId"> <el-form-item label="退货仓库" prop="refundWarehouseId">
<el-select v-model="baseInfo.warehouseId" clearable placeholder="请选择退货仓库" style="width: 100%;"> <el-select v-model="baseInfo.refundWarehouseId" clearable placeholder="请选择退货仓库" style="width: 100%;">
<el-option v-for="item in wareHouseOptions" <el-option v-for="item in wareHouseOptions"
:key="item.warehouseId" :key="item.warehouseId"
:label="item.warehouseName" :label="item.warehouseName"
@ -33,8 +33,8 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="退货人" prop="refundName"> <el-form-item label="退货人" prop="refundContact">
<el-input v-model="baseInfo.refundName" placeholder="请输入退货人" maxlength="20" clearable style="width: 240px"/> <el-input v-model="baseInfo.refundContact" placeholder="请输入退货人" maxlength="20" clearable style="width: 240px"/>
</el-form-item> </el-form-item>
<el-form-item label="退货时间" prop="refundTime"> <el-form-item label="退货时间" prop="refundTime">
<el-date-picker <el-date-picker
@ -198,7 +198,7 @@ export default {
refundTime: [ refundTime: [
{ required: true, message: "交货时间不能为空", trigger: "change" } { required: true, message: "交货时间不能为空", trigger: "change" }
], ],
warehouseId: [ refundWarehouseId: [
{ required: true, message: "送货仓库不能为空", trigger: "change" } { required: true, message: "送货仓库不能为空", trigger: "change" }
], ],
supplyAddress: [ supplyAddress: [
@ -263,7 +263,7 @@ export default {
}); });
drpWareHousePageApi({ areaId:this.baseInfo.areaId }).then((response) => { drpWareHousePageApi({ areaId:this.baseInfo.areaId }).then((response) => {
this.wareHouseOptions = response.rows||[]; this.wareHouseOptions = response.rows||[];
this.$set(this.baseInfo,'warehouseId',this.baseInfo.warehouseId) this.$set(this.baseInfo,'refundWarehouseId',this.baseInfo.refundWarehouseId)
}); });
}); });
}, },
@ -296,7 +296,7 @@ export default {
getWareHouseData() { getWareHouseData() {
drpWareHousePageApi({ areaId:this.baseInfo.areaId }).then((response) => { drpWareHousePageApi({ areaId:this.baseInfo.areaId }).then((response) => {
this.wareHouseOptions = response.rows||[]; this.wareHouseOptions = response.rows||[];
this.$set(this.baseInfo,'warehouseId',null) this.$set(this.baseInfo,'refundWarehouseId',null)
}); });
}, },
/** 查询货品类别下拉树结构 */ /** 查询货品类别下拉树结构 */
@ -327,7 +327,7 @@ export default {
}, },
// //
addMaterial(){ addMaterial(){
if(this.baseInfo.areaId!=undefined||this.baseInfo.warehouseId!=undefined){ if(this.baseInfo.areaId!=undefined||this.baseInfo.refundWarehouseId!=undefined){
this.openDialog=true this.openDialog=true
this.resetQuery() this.resetQuery()
setTimeout(()=>{ setTimeout(()=>{
@ -354,7 +354,7 @@ export default {
"pageSize": this.queryParams.pageSize, "pageSize": this.queryParams.pageSize,
"pageNum": this.queryParams.pageNum, "pageNum": this.queryParams.pageNum,
"areaId": this.baseInfo.areaId, "areaId": this.baseInfo.areaId,
"warehouseId": this.baseInfo.warehouseId, "warehouseId": this.baseInfo.refundWarehouseId,
"materialName": this.queryParams.materialName, "materialName": this.queryParams.materialName,
"materialCode": this.queryParams.materialCode, "materialCode": this.queryParams.materialCode,
"materialTypeIds": this.queryParams.materialTypeIds, "materialTypeIds": this.queryParams.materialTypeIds,
@ -387,8 +387,8 @@ export default {
this.$refs["baseInfo"].validate(valid => { this.$refs["baseInfo"].validate(valid => {
if (valid) { if (valid) {
let param = Object.assign({},this.baseInfo); let param = Object.assign({},this.baseInfo);
param.refundTime = this.formatDate(this.baseInfo.refundTime) param.refundTime = this.formatDateTime(this.baseInfo.refundTime)
param.refundTotalAmount=0 // param.refundTotalAmount=0
param.refundTotalNum=0 param.refundTotalNum=0
param.detailList = [] param.detailList = []
this.noMaterial = false; this.noMaterial = false;
@ -436,8 +436,8 @@ export default {
this.$refs["baseInfo"].validate(valid => { this.$refs["baseInfo"].validate(valid => {
if (valid) { if (valid) {
let param = Object.assign({},this.baseInfo); let param = Object.assign({},this.baseInfo);
param.refundTime = this.formatDate(this.baseInfo.refundTime) param.refundTime = this.formatDateTime(this.baseInfo.refundTime)
param.refundTotalAmount=0 // param.refundTotalAmount=0
param.refundTotalNum=0 param.refundTotalNum=0
param.detailList = [] param.detailList = []
this.noMaterial = false; this.noMaterial = false;

View File

@ -37,8 +37,8 @@
}" clearable @change="handleAreaChange"> }" clearable @change="handleAreaChange">
</el-cascader> </el-cascader>
</el-form-item> </el-form-item>
<el-form-item label="退货人" prop="returnMan"> <el-form-item label="退货人" prop="refundContact">
<el-input v-model="queryParams.returnMan" placeholder="请输入退货人" maxlength="20" clearable style="width: 240px"/> <el-input v-model="queryParams.refundContact" placeholder="请输入退货人" maxlength="20" clearable style="width: 240px"/>
</el-form-item> </el-form-item>
<el-form-item label="提交状态" prop="commitStatus"> <el-form-item label="提交状态" prop="commitStatus">
<el-select v-model="queryParams.commitStatus" placeholder="请选择提交状态" style="width: 240px;"> <el-select v-model="queryParams.commitStatus" placeholder="请选择提交状态" style="width: 240px;">
@ -80,26 +80,17 @@
<el-table-column label="退货单号" align="center" prop="refundGoodsCode" :show-overflow-tooltip="true" /> <el-table-column label="退货单号" align="center" prop="refundGoodsCode" :show-overflow-tooltip="true" />
<el-table-column label="所属区域" align="center" prop="areaName" :show-overflow-tooltip="true" width="120"/> <el-table-column label="所属区域" align="center" prop="areaName" :show-overflow-tooltip="true" width="120"/>
<el-table-column label="供应商" align="center" prop="supplierName" :show-overflow-tooltip="true" width="120"/> <el-table-column label="供应商" align="center" prop="supplierName" :show-overflow-tooltip="true" width="120"/>
<!-- <el-table-column label="确认状态" align="center" prop="supplierConfirmStatus" :show-overflow-tooltip="true" width="100"> <el-table-column label="退货仓库" align="center" prop="warehouseName" :show-overflow-tooltip="true" width="120"/>
<el-table-column label="退货时间" align="center" prop="refundTime" :show-overflow-tooltip="true" width="150"/>
<el-table-column label="退货人" align="center" prop="refundContact" :show-overflow-tooltip="true" width="150"/>
<el-table-column label="退款金额(元)" align="center" prop="refundTotalAmount" :show-overflow-tooltip="true" width="120">
<template slot-scope="scope"> <template slot-scope="scope">
<span v-if="scope.row.supplierConfirmStatus==1">待确认</span> <span>{{ (scope.row.refundTotalAmount/100).toFixed(2) }}</span>
<span v-if="scope.row.supplierConfirmStatus==2">确认通过</span>
<span v-if="scope.row.supplierConfirmStatus==3">已拒绝</span>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="货品数量" align="center" prop="refundTotalNum" :show-overflow-tooltip="true" width="100"/>
<el-table-column label="订单总金额(元)" align="center" prop="orderAmount" :show-overflow-tooltip="true" width="120"> <!-- <el-table-column label="所属食堂" align="center" prop="canteenName" :show-overflow-tooltip="true" width="120"/>
<template slot-scope="scope"> <el-table-column label="所属档口" align="center" prop="stallName" :show-overflow-tooltip="true" width="120"/> -->
<span>{{ (scope.row.orderAmount/100).toFixed(2) }}</span>
</template>
</el-table-column> -->
<el-table-column label="货品数量" align="center" prop="totalNum" :show-overflow-tooltip="true" width="100"/>
<el-table-column label="供应商" align="center" prop="supplierName" :show-overflow-tooltip="true" width="120"/>
<el-table-column label="交货日期" align="center" prop="requestArrivalTime" :show-overflow-tooltip="true" width="150"/>
<el-table-column label="w" align="center" prop="canteenName" :show-overflow-tooltip="true" width="120"/>
<el-table-column label="所属档口" align="center" prop="stallName" :show-overflow-tooltip="true" width="120"/>
<!-- <el-table-column label="审批人" align="center" prop="" :show-overflow-tooltip="true" width="120"/> <!-- <el-table-column label="审批人" align="center" prop="" :show-overflow-tooltip="true" width="120"/>
<el-table-column label="审批完成时间" align="center" prop="" :show-overflow-tooltip="true" width="120"/> --> <el-table-column label="审批完成时间" align="center" prop="" :show-overflow-tooltip="true" width="120"/> -->
<!-- <el-table-column label="负责人" align="center" prop="contractPerson" :show-overflow-tooltip="true" width="120"/> --> <!-- <el-table-column label="负责人" align="center" prop="contractPerson" :show-overflow-tooltip="true" width="120"/> -->

View File

@ -353,7 +353,7 @@ export default {
/** 删除按钮操作 */ /** 删除按钮操作 */
handleDelete(row) { handleDelete(row) {
this.$modal.confirm('是否确认删除数据项?').then(function() { this.$modal.confirm('是否确认删除数据项?').then(function() {
return delWarehouseOutApi({orderGoodsIds:[row.orderGoodsId]}); return delWarehouseOutApi({outIds:[row.outId]});
}).then(() => { }).then(() => {
this.getList(); this.getList();
this.$modal.msgSuccess("删除成功"); this.$modal.msgSuccess("删除成功");