change - add成品出库审核
parent
67f59a344c
commit
ed0dc9fcdf
@ -0,0 +1,27 @@
|
|||||||
|
package com.hw.wms.domain.vo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotBlank;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 原材料出库审核VO
|
||||||
|
* @ClassName: WmsRawOutstockAuditVo
|
||||||
|
* @Author : xins
|
||||||
|
* @Date :2023-12-21 16:33
|
||||||
|
* @Version :1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class WmsProductOutstockAuditVo {
|
||||||
|
|
||||||
|
//审核状态
|
||||||
|
@NotBlank(message = "任务编号必须输入")
|
||||||
|
private String taskCode;
|
||||||
|
|
||||||
|
//审核状态
|
||||||
|
@NotBlank(message = "审核状态必须输入")
|
||||||
|
private String auditStatus;
|
||||||
|
|
||||||
|
//审核意见
|
||||||
|
private String auditReason;
|
||||||
|
}
|
@ -0,0 +1,27 @@
|
|||||||
|
import request from '@/utils/request'
|
||||||
|
|
||||||
|
// 查询成品出库记录列表,提供审核使用
|
||||||
|
export function auditListProductoutstock(query) {
|
||||||
|
return request({
|
||||||
|
url: '/wms/productoutstock/auditList',
|
||||||
|
method: 'get',
|
||||||
|
params: query
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取成品出库记录详细信息,供审核使用
|
||||||
|
export function getProductOutstockAudit(productOutstockId) {
|
||||||
|
return request({
|
||||||
|
url: '/wms/productoutstock/getProductOutstockAudit/' + productOutstockId,
|
||||||
|
method: 'get'
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
// 审核成品出库记录
|
||||||
|
export function auditProductOutstock(data) {
|
||||||
|
return request({
|
||||||
|
url: '/wms/productoutstock/auditProductOutstock',
|
||||||
|
method: 'post',
|
||||||
|
data: data
|
||||||
|
})
|
||||||
|
}
|
@ -0,0 +1,288 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
|
||||||
|
<el-form-item label="任务编号" prop="taskCode">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.taskCode"
|
||||||
|
placeholder="请输入任务编号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="仓库" prop="warehouseId">
|
||||||
|
<el-select v-model="queryParams.warehouseId" clearable>
|
||||||
|
<el-option
|
||||||
|
v-for="item in warehouseOptions"
|
||||||
|
:key="item.warehouseId"
|
||||||
|
:label="item.warehouseName"
|
||||||
|
:value="item.warehouseId"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="计划编号" prop="planCode">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.planCode"
|
||||||
|
placeholder="请输入计划编号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="明细编号" prop="planDetailCode">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.planDetailCode"
|
||||||
|
placeholder="请输入计划明细编号"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="出库类型" prop="outstockType">
|
||||||
|
<el-select
|
||||||
|
v-model="queryParams.outstockType"
|
||||||
|
placeholder="请选择出库类型"
|
||||||
|
clearable
|
||||||
|
style="width: 240px"
|
||||||
|
>
|
||||||
|
<el-option
|
||||||
|
v-for="dict in dict.type.wms_product_outstock_task_type"
|
||||||
|
:key="dict.value"
|
||||||
|
:label="dict.label"
|
||||||
|
:value="dict.value"
|
||||||
|
/>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="申请人" prop="applyBy">
|
||||||
|
<el-input
|
||||||
|
v-model="queryParams.applyBy"
|
||||||
|
placeholder="请输入申请人"
|
||||||
|
clearable
|
||||||
|
@keyup.enter.native="handleQuery"
|
||||||
|
/>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item>
|
||||||
|
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||||
|
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
|
||||||
|
<el-table v-loading="loading" :data="productoutstockList" @selection-change="handleSelectionChange">
|
||||||
|
<el-table-column type="selection" width="55" align="center" />
|
||||||
|
<el-table-column label="任务编号" align="center" prop="taskCode" />
|
||||||
|
<el-table-column label="仓库名称" align="center" prop="warehouseName" />
|
||||||
|
<el-table-column label="计划编号" align="center" prop="planCode" />
|
||||||
|
<el-table-column label="计划明细编号" align="center" prop="planDetailCode" />
|
||||||
|
<el-table-column label="出库类型" align="center" prop="outstockType" >
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.wms_product_outstock_task_type" :value="scope.row.outstockType"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="申请人" align="center" prop="applyBy" />
|
||||||
|
<el-table-column label="申请原因" align="center" prop="applyReason" />
|
||||||
|
<el-table-column label="申请时间" align="center" prop="applyDate" width="180">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<span>{{ parseTime(scope.row.applyDate, '{y}-{m}-{d}') }}</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="审核状态" align="center" prop="auditStatus" >
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.wms_audit_status" :value="scope.row.auditStatus"/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-button
|
||||||
|
size="mini"
|
||||||
|
type="text"
|
||||||
|
icon="el-icon-lock"
|
||||||
|
@click="handleAudit(scope.row)"
|
||||||
|
v-hasPermi="['wms:rawoutstock:audit:query']"
|
||||||
|
v-if="scope.row.auditStatus=='0'"
|
||||||
|
>审核</el-button>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</el-table>
|
||||||
|
|
||||||
|
<pagination
|
||||||
|
v-show="total>0"
|
||||||
|
:total="total"
|
||||||
|
:page.sync="queryParams.pageNum"
|
||||||
|
:limit.sync="queryParams.pageSize"
|
||||||
|
@pagination="getList"
|
||||||
|
/>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import { auditListRawoutstock,getWarehouses4Audit } from "@/api/wms/rawoutstock";
|
||||||
|
import {auditListProductoutstock} from "@/api/wms/productoutstock";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "Productoutstock",
|
||||||
|
dicts: ['wms_audit_status', 'wms_execute_status', 'wms_product_outstock_task_type'],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 选中数组
|
||||||
|
ids: [],
|
||||||
|
// 子表选中数据
|
||||||
|
checkedWmsRawOutstockDetail: [],
|
||||||
|
// 非单个禁用
|
||||||
|
single: true,
|
||||||
|
// 非多个禁用
|
||||||
|
multiple: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 成品出库记录表格数据
|
||||||
|
productoutstockList: [],
|
||||||
|
// 成品出库记录明细表格数据
|
||||||
|
wmsRawOutstockDetailList: [],
|
||||||
|
// 弹出层标题
|
||||||
|
title: "",
|
||||||
|
// 是否显示弹出层
|
||||||
|
open: false,
|
||||||
|
// 查询参数
|
||||||
|
queryParams: {
|
||||||
|
pageNum: 1,
|
||||||
|
pageSize: 10,
|
||||||
|
taskCode: null,
|
||||||
|
warehouseId: null,
|
||||||
|
locationCode: null,
|
||||||
|
orderId: null,
|
||||||
|
planCode: null,
|
||||||
|
planDetailCode: null,
|
||||||
|
stationId: null,
|
||||||
|
productId: null,
|
||||||
|
materialBatch: null,
|
||||||
|
palletInfoCode: null,
|
||||||
|
outstockAmount: null,
|
||||||
|
realOutstockAmount: null,
|
||||||
|
endStationCode: null,
|
||||||
|
operationType: null,
|
||||||
|
taskType: null,
|
||||||
|
outstockType: null,
|
||||||
|
applyReason: null,
|
||||||
|
auditReason: null,
|
||||||
|
auditStatus: '0',
|
||||||
|
executeStatus: null,
|
||||||
|
applyBy: null,
|
||||||
|
applyDate: null,
|
||||||
|
auditBy: null,
|
||||||
|
auditDate: null,
|
||||||
|
updateDate: null,
|
||||||
|
beginTime: null,
|
||||||
|
endTime: null
|
||||||
|
},
|
||||||
|
// 表单参数
|
||||||
|
form: {},
|
||||||
|
// 仓库列表
|
||||||
|
warehouseOptions: [],
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.getList();
|
||||||
|
this.getWarehouseList();
|
||||||
|
},
|
||||||
|
activated() {
|
||||||
|
const time = this.$route.query.t;
|
||||||
|
if (time != null && time != this.uniqueId) {
|
||||||
|
this.uniqueId = time;
|
||||||
|
this.queryParams.pageNum = Number(this.$route.query.pageNum);
|
||||||
|
this.getList();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/** 查询成品出库记录列表 */
|
||||||
|
getList() {
|
||||||
|
this.loading = true;
|
||||||
|
auditListProductoutstock(this.queryParams).then(response => {
|
||||||
|
this.productoutstockList = response.rows;
|
||||||
|
this.total = response.total;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
/** 查询仓库列表 */
|
||||||
|
getWarehouseList() {
|
||||||
|
getWarehouses4Audit().then(response => {
|
||||||
|
this.warehouseOptions = response.data;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
// 取消按钮
|
||||||
|
cancel() {
|
||||||
|
this.open = false;
|
||||||
|
this.reset();
|
||||||
|
},
|
||||||
|
// 表单重置
|
||||||
|
reset() {
|
||||||
|
this.form = {
|
||||||
|
rawOutstockId: null,
|
||||||
|
taskCode: null,
|
||||||
|
warehouseId: null,
|
||||||
|
locationCode: null,
|
||||||
|
orderId: null,
|
||||||
|
planCode: null,
|
||||||
|
planDetailCode: null,
|
||||||
|
stationId: null,
|
||||||
|
productId: null,
|
||||||
|
materialBatch: null,
|
||||||
|
palletInfoCode: null,
|
||||||
|
outstockAmount: null,
|
||||||
|
realOutstockAmount: null,
|
||||||
|
endStationCode: null,
|
||||||
|
operationType: null,
|
||||||
|
taskType: null,
|
||||||
|
applyReason: null,
|
||||||
|
auditReason: null,
|
||||||
|
auditStatus: null,
|
||||||
|
executeStatus: null,
|
||||||
|
applyBy: null,
|
||||||
|
applyDate: null,
|
||||||
|
auditBy: null,
|
||||||
|
auditDate: null,
|
||||||
|
updateBy: null,
|
||||||
|
updateDate: null,
|
||||||
|
beginTime: null,
|
||||||
|
endTime: null
|
||||||
|
};
|
||||||
|
this.wmsRawOutstockDetailList = [];
|
||||||
|
this.resetForm("form");
|
||||||
|
},
|
||||||
|
/** 搜索按钮操作 */
|
||||||
|
handleQuery() {
|
||||||
|
this.queryParams.pageNum = 1;
|
||||||
|
this.getList();
|
||||||
|
},
|
||||||
|
/** 重置按钮操作 */
|
||||||
|
resetQuery() {
|
||||||
|
this.resetForm("queryForm");
|
||||||
|
this.handleQuery();
|
||||||
|
},
|
||||||
|
// 多选框选中数据
|
||||||
|
handleSelectionChange(selection) {
|
||||||
|
this.ids = selection.map(item => item.rawOutstockId)
|
||||||
|
this.single = selection.length!==1
|
||||||
|
this.multiple = !selection.length
|
||||||
|
},
|
||||||
|
/** 新增按钮操作 */
|
||||||
|
handleAdd() {
|
||||||
|
this.reset();
|
||||||
|
this.open = true;
|
||||||
|
this.title = "添加成品出库记录";
|
||||||
|
},
|
||||||
|
/** 审核按钮操作 */
|
||||||
|
handleAudit(row) {
|
||||||
|
this.reset();
|
||||||
|
const productOutstockId = row.productOutstockId
|
||||||
|
const taskCode = row.taskCode
|
||||||
|
const warehouseName = row.warehouseName;
|
||||||
|
const params = {pageNum: this.queryParams.pageNum, warehouseName: warehouseName, detailFlag: '0',productOutstockId: productOutstockId};
|
||||||
|
this.$tab.openPage("成品出库审核[" + taskCode + "]", '/wms/product-outstock/audit/' + taskCode, params);
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
@ -0,0 +1,276 @@
|
|||||||
|
<template>
|
||||||
|
<div class="app-container">
|
||||||
|
<el-form ref="form" :model="form" label-width="100px">
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="任务编号" prop="taskCode">
|
||||||
|
<el-input v-model="form.taskCode" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="仓库" prop="warehouseName">
|
||||||
|
<el-input v-model="form.warehouseName" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="计划编号" prop="planCode">
|
||||||
|
<el-input v-model="form.planCode" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="明细编号" prop="planDetailCode">
|
||||||
|
<el-input v-model="form.planDetailCode" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="成品编码" prop="materialCode">
|
||||||
|
<el-input v-model="form.materialCode" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="成品名称" prop="materialName">
|
||||||
|
<el-input v-model="form.materialName" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="成品条码" prop="productBatch">
|
||||||
|
<el-input v-model="form.productBatch" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="销售订单编号" prop="saleorderCode">
|
||||||
|
<el-input v-model="form.saleorderCode" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="申请出库数量" prop="applyQty">
|
||||||
|
<el-input v-model="form.applyQty" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2" v-if="detailFlag">
|
||||||
|
<el-form-item label="已出库数量" prop="outstockQty">
|
||||||
|
<el-input v-model="form.outstockQty" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="申请人" prop="applyBy">
|
||||||
|
<el-input v-model="form.applyBy" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="申请时间" prop="applyDate">
|
||||||
|
<el-input v-model="form.applyDate" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="16" :offset="2">
|
||||||
|
<el-form-item label="申请原因" prop="applyReason">
|
||||||
|
<el-input v-model="form.applyReason" type="textarea" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="16" :offset="2">
|
||||||
|
<el-form-item label="出库类型" prop="outstockType">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.wms_product_outstock_task_type" :value="form.outstockType"/>
|
||||||
|
</template>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row v-if="detailFlag">
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="审核人" prop="auditBy">
|
||||||
|
<el-input v-model="form.auditBy" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="审核时间" prop="auditDate">
|
||||||
|
<el-input v-model="form.auditDate" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="16" :offset="2">
|
||||||
|
<el-form-item label="审核原因" prop="auditReason">
|
||||||
|
<el-input v-model="form.auditReason" type="textarea" :disabled="detailFlag"/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
<el-row v-if="detailFlag">
|
||||||
|
<el-col :span="16" :offset="2">
|
||||||
|
<el-form-item label="同步ERP数量" prop="erpAmount">
|
||||||
|
<el-input v-model="form.erpAmount" disabled/>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
|
||||||
|
<el-row v-if="detailFlag">
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="审核状态" prop="auditStatus">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.wms_audit_status" :value="form.auditStatus"/>
|
||||||
|
</template>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="8" :offset="2">
|
||||||
|
<el-form-item label="执行状态" prop="executeStatus">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<dict-tag :options="dict.type.wms_execute_status" :value="form.executeStatus"/>
|
||||||
|
</template>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
|
||||||
|
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button type="primary" @click="auditPass" v-if="!detailFlag">审核通过</el-button>
|
||||||
|
<el-button type="primary" @click="auditFail" v-if="!detailFlag">审核不通过</el-button>
|
||||||
|
<el-button @click="cancel">关 闭</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import {auditProductOutstock, getProductOutstockAudit} from "@/api/wms/productoutstock";
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: "ProductoutstockDetail",
|
||||||
|
dicts: ["wms_audit_status","wms_erp_status","wms_execute_status","wms_product_outstock_task_type"],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
// 遮罩层
|
||||||
|
loading: true,
|
||||||
|
// 选中数组
|
||||||
|
ids: [],
|
||||||
|
// 非单个禁用
|
||||||
|
single: true,
|
||||||
|
// 非多个禁用
|
||||||
|
multiple: true,
|
||||||
|
// 显示搜索条件
|
||||||
|
showSearch: true,
|
||||||
|
// 总条数
|
||||||
|
total: 0,
|
||||||
|
// 成品出库记录明细表格数据
|
||||||
|
wmsProductOutstockDetailList: [],
|
||||||
|
// 弹出层标题
|
||||||
|
title: "",
|
||||||
|
// 是否显示弹出层
|
||||||
|
open: false,
|
||||||
|
// 表单参数
|
||||||
|
form: {},
|
||||||
|
// 表单校验
|
||||||
|
detailFlag: true
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
const taskCode = this.$route.params && this.$route.params.taskCode;
|
||||||
|
const productOutstockId = this.$route.query && this.$route.query.productOutstockId;
|
||||||
|
const detailFlag = this.$route.query && this.$route.query.detailFlag;
|
||||||
|
const warehouseName = this.$route.query && this.$route.query.warehouseName;
|
||||||
|
this.form.productOutstockId = productOutstockId;
|
||||||
|
this.form.taskCode = taskCode;
|
||||||
|
this.form.warehouseName = warehouseName;
|
||||||
|
this.detailFlag = detailFlag == "1";
|
||||||
|
this.getProductOutstock();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
/** 查询成品出库记录列表 */
|
||||||
|
getProductOutstock() {
|
||||||
|
this.loading = true;
|
||||||
|
getProductOutstockAudit(this.form.productOutstockId).then(response => {
|
||||||
|
this.form = response.data;
|
||||||
|
this.loading = false;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
// 取消按钮
|
||||||
|
cancel() {
|
||||||
|
const obj = {path: "/wms/productmanagement/productoutstock", query: {t: Date.now(), pageNum: this.$route.query.pageNum}};
|
||||||
|
this.$tab.closeOpenPage(obj);
|
||||||
|
},
|
||||||
|
// 表单重置
|
||||||
|
reset() {
|
||||||
|
this.form = {
|
||||||
|
rawReturnId: null,
|
||||||
|
taskCode: null,
|
||||||
|
warehouseId: null,
|
||||||
|
locationCode: null,
|
||||||
|
planCode: null,
|
||||||
|
planDetailCode: null,
|
||||||
|
productId: null,
|
||||||
|
materialId: null,
|
||||||
|
materialBarcode: null,
|
||||||
|
batchCode: null,
|
||||||
|
planAmount: null,
|
||||||
|
returnAmount: null,
|
||||||
|
operationType: null,
|
||||||
|
taskType: null,
|
||||||
|
endStationCode: null,
|
||||||
|
applyReason: null,
|
||||||
|
auditReason: null,
|
||||||
|
auditStatus: null,
|
||||||
|
executeStatus: null,
|
||||||
|
applyBy: null,
|
||||||
|
applyDate: null,
|
||||||
|
auditBy: null,
|
||||||
|
auditDate: null,
|
||||||
|
updateBy: null,
|
||||||
|
updateDate: null,
|
||||||
|
beginTime: null,
|
||||||
|
endTime: null,
|
||||||
|
erpStatus: null,
|
||||||
|
erpAmount: null
|
||||||
|
};
|
||||||
|
this.wmsProductOutstockDetailList = [];
|
||||||
|
this.resetForm("form");
|
||||||
|
},
|
||||||
|
//审核通过
|
||||||
|
auditPass() {
|
||||||
|
this.form.auditStatus = "1";
|
||||||
|
this.submitForm();
|
||||||
|
},
|
||||||
|
//审核不通过
|
||||||
|
auditFail() {
|
||||||
|
this.form.auditStatus = "2";
|
||||||
|
if (!this.form.auditReason || this.form.auditReason == "" || this.form.auditReason == undefined) {
|
||||||
|
this.$modal.msgWarning("请输入审核原因!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.submitForm();
|
||||||
|
},
|
||||||
|
/** 提交按钮 */
|
||||||
|
submitForm() {
|
||||||
|
this.$refs["form"].validate(valid => {
|
||||||
|
if (valid) {
|
||||||
|
auditProductOutstock(this.form).then(response => {
|
||||||
|
this.$modal.msgSuccess("保存成功");
|
||||||
|
this.cancel();
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
Loading…
Reference in New Issue