盘点管理下5个页面国际化

This commit is contained in:
猫猫guowen
2025-06-05 16:02:04 +08:00
parent f3c2f3a1ac
commit 02d3734e9f
7 changed files with 1021 additions and 530 deletions

View File

@@ -2,8 +2,8 @@
<div class="app-container">
<!-- 主表信息录入 -->
<el-form :model="formData" ref="formRef" size="small" :inline="true" label-width="68px" :rules="rules">
<el-form-item label="仓库" prop="warehouseId" required>
<el-select v-model="formData.warehouseId" placeholder="请选择仓库" clearable>
<el-form-item :label="$t('checkCreate.warehouse')" prop="warehouseId" required> <!-- 仓库 -->
<el-select v-model="formData.warehouseId" :placeholder="$t('checkCreate.selectWarehouse')" clearable>
<el-option
v-for="dict in warehouseOptions"
:key="dict.warehouseId"
@@ -12,15 +12,15 @@
/>
</el-select>
</el-form-item>
<el-form-item label="客户" prop="customerNo" required>
<el-form-item :label="$t('checkCreate.customer')" prop="customerNo" required> <!-- 客户 -->
<el-input
v-model="formData.customerNo"
placeholder="请输入客户编号"
:placeholder="$t('checkCreate.inputCustomerNo')"
clearable
/>
</el-form-item>
<el-form-item label="单据类型" prop="checkType" required>
<el-select v-model="formData.checkType" placeholder="请选择单据类型" clearable>
<el-form-item :label="$t('checkCreate.documentType')" prop="checkType" required> <!-- 单据类型 -->
<el-select v-model="formData.checkType" :placeholder="$t('checkCreate.selectDocumentType')" clearable>
<el-option
v-for="dict in dict.type.check_stock_type"
:key="dict.value"
@@ -30,60 +30,60 @@
</el-select>
</el-form-item>
<el-form-item>
<el-button type="warning" icon="el-icon-refresh" size="mini" @click="reset">重置</el-button>
<el-button type="success" icon="el-icon-check" size="mini" @click="handleSave">保存单据</el-button>
<el-button type="warning" icon="el-icon-refresh" size="mini" @click="reset">{{ $t('checkCreate.reset') }}</el-button> <!-- 重置 -->
<el-button type="success" icon="el-icon-check" size="mini" @click="handleSave">{{ $t('checkCreate.saveDocument') }}</el-button> <!-- 保存单据 -->
</el-form-item>
</el-form>
<div class="mb8">
<el-button type="primary" icon="el-icon-plus" size="mini" @click="handleSelectMaterials">选择物资</el-button>
<el-button type="info" icon="el-icon-refresh-right" size="mini" @click="handleReload">重新建单</el-button>
<el-button type="primary" icon="el-icon-plus" size="mini" @click="handleSelectMaterials">{{ $t('checkCreate.selectMaterial') }}</el-button> <!-- 选择物资 -->
<el-button type="info" icon="el-icon-refresh-right" size="mini" @click="handleReload">{{ $t('checkCreate.recreateDocument') }}</el-button> <!-- 重新建单 -->
</div>
<!-- 物资明细表格 -->
<el-table v-loading="loading" :data="materialList">
<el-table-column label="物资编号" align="center" prop="productId" />
<el-table-column label="物资名称" align="center" prop="productName" />
<el-table-column label="批号" align="center" prop="lotNo">
<el-table-column :label="$t('checkCreate.materialCode')" align="center" prop="productId" /> <!-- 物资编号 -->
<el-table-column :label="$t('checkCreate.materialName')" align="center" prop="productName" /> <!-- 物资名称 -->
<el-table-column :label="$t('checkCreate.batchNo')" align="center" prop="lotNo"> <!-- 批号 -->
<template slot-scope="scope">
<el-input v-model="scope.row.lotNo" size="mini" placeholder="请输入批号" />
<el-input v-model="scope.row.lotNo" size="mini" :placeholder="$t('checkCreate.inputBatchNo')" />
</template>
</el-table-column>
<el-table-column label="数量" align="center" prop="quantity">
<el-table-column :label="$t('checkCreate.quantity')" align="center" prop="quantity"> <!-- 数量 -->
<template slot-scope="scope">
<el-input-number v-model="scope.row.quantity" :min="1" size="mini" @change="handleQuantityChange(scope.row)" />
</template>
</el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column :label="$t('checkCreate.operation')" align="center" class-name="small-padding fixed-width"> <!-- 操作 -->
<template slot-scope="scope">
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.$index)">删除</el-button>
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.$index)">{{ $t('checkCreate.delete') }}</el-button> <!-- 删除 -->
</template>
</el-table-column>
</el-table>
<!-- 选择物资弹窗 -->
<el-dialog title="选择物资" :visible.sync="materialDialog" width="800px" append-to-body>
<el-dialog :title="$t('checkCreate.selectMaterial')" :visible.sync="materialDialog" width="800px" append-to-body> <!-- 选择物资 -->
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" label-width="68px">
<el-form-item label="物资编码" prop="productId">
<el-form-item :label="$t('checkCreate.materialCode')" prop="productId"> <!-- 物资编码 -->
<el-input
v-model="queryParams.productId"
placeholder="请输入物资编码"
:placeholder="$t('checkCreate.inputMaterialCode')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物资名称" prop="productName">
<el-form-item :label="$t('checkCreate.materialName')" prop="productName"> <!-- 物资名称 -->
<el-input
v-model="queryParams.productName"
placeholder="请输入物资名称"
:placeholder="$t('checkCreate.inputMaterialName')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="批号" prop="lotNo">
<el-form-item :label="$t('checkCreate.batchNo')" prop="lotNo"> <!-- 批号 -->
<el-input
v-model="queryParams.lotNo"
placeholder="请输入批号"
:placeholder="$t('checkCreate.inputBatchNo')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -97,27 +97,21 @@
/>
</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-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">{{ $t('checkCreate.search') }}</el-button> <!-- 搜索 -->
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">{{ $t('checkCreate.reset') }}</el-button> <!-- 重置 -->
</el-form-item>
</el-form>
<el-table v-loading="materialLoading" :data="materialOptions" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" />
<el-table-column label="物资编码" align="center" prop="productId" />
<el-table-column label="物资名称" align="center" prop="productName" />
<!-- <el-table-column label="批号" align="center" prop="lotNo">
<template slot-scope="scope">
<el-input v-model="scope.row.lotNo" size="mini" placeholder="请输入批号" />
</template>
</el-table-column> -->
<el-table-column label="数量" align="center" prop="quantity" />
<!-- <el-table-column label="仓库" align="center" prop="warehouseId" /> -->
<el-table-column :label="$t('checkCreate.materialCode')" align="center" prop="productId" /> <!-- 物资编码 -->
<el-table-column :label="$t('checkCreate.materialName')" align="center" prop="productName" /> <!-- 物资名称 -->
<el-table-column :label="$t('checkCreate.quantity')" align="center" prop="quantity" /> <!-- 数量 -->
</el-table>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="confirmSelectMaterials">确 定</el-button>
<el-button @click="cancelSelectMaterials">取 消</el-button>
<el-button type="primary" @click="confirmSelectMaterials">{{ $t('checkCreate.confirm') }}</el-button> <!-- 确定 -->
<el-button @click="cancelSelectMaterials">{{ $t('checkCreate.cancel') }}</el-button> <!-- 取消 -->
</div>
</el-dialog>
</div>
@@ -139,13 +133,13 @@
// 表单验证规则
rules: {
warehouseId: [
{ required: true, message: "请选择仓库", trigger: "change" }
{ required: true, message: this.$t('checkCreate.warehouseRequired'), trigger: "change" }
],
customerNo: [
{ required: true, message: "请输入客户编号", trigger: "blur" }
{ required: true, message: this.$t('checkCreate.customerRequired'), trigger: "blur" }
],
billType: [
{ required: true, message: "请选择单据类型", trigger: "change" }
{ required: true, message: this.$t('checkCreate.documentTypeRequired'), trigger: "change" }
]
},
// 主表数据
@@ -208,7 +202,7 @@
/** 确认选择物资 */
confirmSelectMaterials() {
if (this.selectedMaterials.length === 0) {
this.$modal.msgError("请选择物资");
this.$modal.msgError(this.$t('checkCreate.selectMaterialRequired'));
return;
}
// 过滤掉已经存在的物资
@@ -217,7 +211,7 @@
});
if (newMaterials.length === 0) {
this.$modal.msgWarning("所选物资已存在,请重新选择");
this.$modal.msgWarning(this.$t('checkCreate.materialExistWarning'));
return;
}
@@ -260,7 +254,7 @@
// 如果修改后的数量大于初始数量,给出提示并重置为当前值
if (row.quantity > row.quantityOrignal) {
this.$modal.msgError("数量不能大于库存数量");
this.$modal.msgError(this.$t('checkCreate.quantityExceedError'));
row.quantity = row.quantityOrignal;
}
},
@@ -269,7 +263,7 @@
this.$refs.formRef.validate(valid => {
if (valid) {
if (this.materialList.length === 0) {
this.$modal.msgError("请选择物资");
this.$modal.msgError(this.$t('checkCreate.selectMaterialRequired'));
return;
}
const data = {
@@ -279,7 +273,7 @@
// 这里需要调用保存接口
saveCheckStock(data).then(response => {
console.log(response)
this.$modal.msgSuccess("单据"+response.msg+"保存成功");
this.$modal.msgSuccess(this.$t('checkCreate.saveSuccess', { msg: response.msg }));
this.$tab.refreshPage(this.$route);
// this.reset();
});

View File

@@ -1,50 +1,50 @@
<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="盘点单据id" prop="checkStockDetailId">
<el-form-item :label="$t('checkDifference.checkStockDetailId')" prop="checkStockDetailId"> <!-- 盘点单据id -->
<el-input
v-model="queryParams.checkStockDetailId"
placeholder="请输入盘点单据id"
:placeholder="$t('checkDifference.inputCheckStockDetailId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="库存id" prop="stockId">
<el-form-item :label="$t('checkDifference.stockId')" prop="stockId"> <!-- 库存id -->
<el-input
v-model="queryParams.stockId"
placeholder="请输入库存id"
:placeholder="$t('checkDifference.inputStockId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="托盘" prop="trayCode">
<el-form-item :label="$t('checkDifference.trayCode')" prop="trayCode"> <!-- 托盘 -->
<el-input
v-model="queryParams.trayCode"
placeholder="请输入托盘"
:placeholder="$t('checkDifference.inputTrayCode')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="货位id" prop="cargoSpaceId">
<el-form-item :label="$t('checkDifference.cargoSpaceId')" prop="cargoSpaceId"> <!-- 货位id -->
<el-input
v-model="queryParams.cargoSpaceId"
placeholder="请输入货位id"
:placeholder="$t('checkDifference.inputCargoSpaceId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="物料id" prop="productId">
<el-form-item :label="$t('checkDifference.productId')" prop="productId"> <!-- 物料id -->
<el-input
v-model="queryParams.productId"
placeholder="请输入物料id"
:placeholder="$t('checkDifference.inputProductId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="批次号" prop="lotNo">
<el-form-item :label="$t('checkDifference.lotNo')" prop="lotNo"> <!-- 批次号 -->
<el-input
v-model="queryParams.lotNo"
placeholder="请输入批次号"
:placeholder="$t('checkDifference.inputLotNo')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -90,8 +90,8 @@
/>
</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-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">{{$t('checkDifference.search')}}</el-button> <!-- 搜索 -->
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">{{$t('checkDifference.reset')}}</el-button> <!-- 重置 -->
</el-form-item>
</el-form>
@@ -143,20 +143,20 @@
<el-table v-loading="loading" :data="differenceList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="盘点id" align="center" prop="checkGuid" />
<el-table-column label="盘点单据id" align="center" prop="checkStockDetailId" />
<el-table-column label="库存id" align="center" prop="stockId" />
<el-table-column label="托盘" align="center" prop="trayCode" />
<el-table-column label="货位id" align="center" prop="cargoSpaceId" />
<el-table-column label="物料id" align="center" prop="productId" />
<el-table-column label="批次号" align="center" prop="lotNo" />
<el-table-column label="供应商" align="center" prop="supplier" />
<el-table-column label="客户" align="center" prop="customer" />
<el-table-column label="原值" align="center" prop="oldQuantity" />
<el-table-column label="新值" align="center" prop="newQuantity" />
<el-table-column label="操作方式" align="center" prop="recordType" />
<el-table-column label="物料guid" align="center" prop="productGuid" />
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<el-table-column :label="$t('checkDifference.checkGuid')" align="center" prop="checkGuid" /> <!-- 盘点id -->
<el-table-column :label="$t('checkDifference.checkStockDetailId')" align="center" prop="checkStockDetailId" /> <!-- 盘点单据id -->
<el-table-column :label="$t('checkDifference.stockId')" align="center" prop="stockId" /> <!-- 库存id -->
<el-table-column :label="$t('checkDifference.trayCode')" align="center" prop="trayCode" /> <!-- 托盘 -->
<el-table-column :label="$t('checkDifference.cargoSpaceId')" align="center" prop="cargoSpaceId" /> <!-- 货位id -->
<el-table-column :label="$t('checkDifference.productId')" align="center" prop="productId" /> <!-- 物料id -->
<el-table-column :label="$t('checkDifference.lotNo')" align="center" prop="lotNo" /> <!-- 批次号 -->
<el-table-column :label="$t('checkDifference.supplier')" align="center" prop="supplier" /> <!-- 供应商 -->
<el-table-column :label="$t('checkDifference.customer')" align="center" prop="customer" /> <!-- 客户 -->
<el-table-column :label="$t('checkDifference.oldQuantity')" align="center" prop="oldQuantity" /> <!-- 原值 -->
<el-table-column :label="$t('checkDifference.newQuantity')" align="center" prop="newQuantity" /> <!-- 新值 -->
<el-table-column :label="$t('checkDifference.recordType')" align="center" prop="recordType" /> <!-- 操作方式 -->
<el-table-column :label="$t('checkDifference.productGuid')" align="center" prop="productGuid" /> <!-- 物料guid -->
<el-table-column :label="$t('checkDifference.operation')" align="center" class-name="small-padding fixed-width"> <!-- 操作 -->
<template slot-scope="scope">
<el-button
size="mini"
@@ -164,14 +164,14 @@
icon="el-icon-edit"
@click="handleUpdate(scope.row)"
v-hasPermi="['check:difference:edit']"
>修改</el-button>
>{{$t('checkDifference.edit')}}</el-button> <!-- 修改 -->
<el-button
size="mini"
type="text"
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['check:difference:remove']"
>删除</el-button>
>{{$t('checkDifference.delete')}}</el-button> <!-- 删除 -->
</template>
</el-table-column>
</el-table>
@@ -187,43 +187,43 @@
<!-- 添加或修改盘点差异对话框 -->
<el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
<el-form ref="form" :model="form" :rules="rules" label-width="80px">
<el-form-item label="盘点单据id" prop="checkStockDetailId">
<el-input v-model="form.checkStockDetailId" placeholder="请输入盘点单据id" />
<el-form-item :label="$t('checkDifference.checkStockDetailId')" prop="checkStockDetailId"> <!-- 盘点单据id -->
<el-input v-model="form.checkStockDetailId" :placeholder="$t('checkDifference.inputCheckStockDetailId')" />
</el-form-item>
<el-form-item label="库存id" prop="stockId">
<el-input v-model="form.stockId" placeholder="请输入库存id" />
<el-form-item :label="$t('checkDifference.stockId')" prop="stockId"> <!-- 库存id -->
<el-input v-model="form.stockId" :placeholder="$t('checkDifference.inputStockId')" />
</el-form-item>
<el-form-item label="托盘" prop="trayCode">
<el-input v-model="form.trayCode" placeholder="请输入托盘" />
<el-form-item :label="$t('checkDifference.trayCode')" prop="trayCode"> <!-- 托盘 -->
<el-input v-model="form.trayCode" :placeholder="$t('checkDifference.inputTrayCode')" />
</el-form-item>
<el-form-item label="货位id" prop="cargoSpaceId">
<el-input v-model="form.cargoSpaceId" placeholder="请输入货位id" />
<el-form-item :label="$t('checkDifference.cargoSpaceId')" prop="cargoSpaceId"> <!-- 货位id -->
<el-input v-model="form.cargoSpaceId" :placeholder="$t('checkDifference.inputCargoSpaceId')" />
</el-form-item>
<el-form-item label="物料id" prop="productId">
<el-input v-model="form.productId" placeholder="请输入物料id" />
<el-form-item :label="$t('checkDifference.productId')" prop="productId"> <!-- 物料id -->
<el-input v-model="form.productId" :placeholder="$t('checkDifference.inputProductId')" />
</el-form-item>
<el-form-item label="批次号" prop="lotNo">
<el-input v-model="form.lotNo" placeholder="请输入批次号" />
<el-form-item :label="$t('checkDifference.lotNo')" prop="lotNo"> <!-- 批次号 -->
<el-input v-model="form.lotNo" :placeholder="$t('checkDifference.inputLotNo')" />
</el-form-item>
<el-form-item label="供应商" prop="supplier">
<el-input v-model="form.supplier" placeholder="请输入供应商" />
<el-form-item :label="$t('checkDifference.supplier')" prop="supplier"> <!-- 供应商 -->
<el-input v-model="form.supplier" :placeholder="$t('checkDifference.inputSupplier')" />
</el-form-item>
<el-form-item label="客户" prop="customer">
<el-input v-model="form.customer" placeholder="请输入客户" />
<el-form-item :label="$t('checkDifference.customer')" prop="customer"> <!-- 客户 -->
<el-input v-model="form.customer" :placeholder="$t('checkDifference.inputCustomer')" />
</el-form-item>
<el-form-item label="原值" prop="oldQuantity">
<el-input v-model="form.oldQuantity" placeholder="请输入原值" />
<el-form-item :label="$t('checkDifference.oldQuantity')" prop="oldQuantity"> <!-- 原值 -->
<el-input v-model="form.oldQuantity" :placeholder="$t('checkDifference.inputOldQuantity')" />
</el-form-item>
<el-form-item label="新值" prop="newQuantity">
<el-input v-model="form.newQuantity" placeholder="请输入新值" />
<el-form-item :label="$t('checkDifference.newQuantity')" prop="newQuantity"> <!-- 新值 -->
<el-input v-model="form.newQuantity" :placeholder="$t('checkDifference.inputNewQuantity')" />
</el-form-item>
<el-form-item label="物料guid" prop="productGuid">
<el-input v-model="form.productGuid" placeholder="请输入物料guid" />
<el-form-item :label="$t('checkDifference.productGuid')" prop="productGuid"> <!-- 物料guid -->
<el-input v-model="form.productGuid" :placeholder="$t('checkDifference.inputProductGuid')" />
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button type="primary" @click="submitForm">确 定</el-button>
<el-button @click="cancel">取 消</el-button>
<el-button type="primary" @click="submitForm">{{$t('checkDifference.confirm')}}</el-button> <!-- 确定 -->
<el-button @click="cancel">{{$t('checkDifference.cancel')}}</el-button> <!-- 取消 -->
</div>
</el-dialog>
</div>

View File

@@ -1,16 +1,16 @@
<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="任务ID" prop="jobId">
<el-form-item :label="$t('checkJobIn.jobId')" prop="jobId"> <!--任务ID-->
<el-input
v-model="queryParams.jobId"
placeholder="请输入任务ID"
:placeholder="$t('checkJobIn.inputJobId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="任务状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择任务状态" clearable>
<el-form-item :label="$t('checkJobIn.status')" prop="status"> <!--任务状态-->
<el-select v-model="queryParams.status" :placeholder="$t('checkJobIn.selectStatus')" clearable>
<el-option
v-for="dict in dict.type.mydo_job_status"
:key="dict.value"
@@ -29,10 +29,10 @@
/>
</el-select>
</el-form-item>-->
<el-form-item label="任务号" prop="taskNo">
<el-form-item :label="$t('checkJobIn.taskNo')" prop="taskNo"> <!--任务号-->
<el-input
v-model="queryParams.taskNo"
placeholder="请输入任务号"
:placeholder="$t('checkJobIn.inputTaskNo')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -61,10 +61,10 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="托盘码" prop="trayCode">
<el-form-item :label="$t('checkJobIn.trayCode')" prop="trayCode"> <!--托盘码-->
<el-input
v-model="queryParams.trayCode"
placeholder="请输入托盘码"
:placeholder="$t('checkJobIn.inputTrayCode')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -93,10 +93,10 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="目标货位" prop="targetCargoSpaceId">
<el-form-item :label="$t('checkJobIn.targetCargoSpace')" prop="targetCargoSpaceId"> <!--目标货位-->
<el-input
v-model="queryParams.targetCargoSpaceId"
placeholder="请输入目标货位ID"
:placeholder="$t('checkJobIn.inputTargetCargoSpace')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -125,8 +125,8 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="执行阶段" prop="executionPhase">
<el-select v-model="queryParams.executionPhase" placeholder="请选择执行阶段" clearable>
<el-form-item :label="$t('checkJobIn.executionPhase')" prop="executionPhase"> <!--执行阶段-->
<el-select v-model="queryParams.executionPhase" :placeholder="$t('checkJobIn.selectExecutionPhase')" clearable>
<el-option
v-for="dict in dict.type.execution_phase_type"
:key="dict.value"
@@ -135,8 +135,8 @@
/>
</el-select>
</el-form-item>
<el-form-item label="任务类型" prop="inOrOut">
<el-select v-model="queryParams.inOrOut" placeholder="请选择任务类型" clearable>
<el-form-item :label="$t('checkJobIn.jobType')" prop="inOrOut"> <!--任务类型-->
<el-select v-model="queryParams.inOrOut" :placeholder="$t('checkJobIn.selectJobType')" clearable>
<el-option
v-for="dict in dict.type.check_in_job_type"
:key="dict.value"
@@ -145,34 +145,34 @@
/>
</el-select>
</el-form-item>
<el-form-item label="开始时间" prop="startTime">
<el-form-item :label="$t('checkJobIn.startTime')" prop="startTime"> <!--开始时间-->
<el-date-picker clearable
v-model="queryParams.startTime"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择开始时间">
:placeholder="$t('checkJobIn.selectStartTime')">
</el-date-picker>
</el-form-item>
<el-form-item label="结束时间" prop="finishTime">
<el-form-item :label="$t('checkJobIn.finishTime')" prop="finishTime"> <!--结束时间-->
<el-date-picker clearable
v-model="queryParams.finishTime"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择结束时间">
:placeholder="$t('checkJobIn.selectFinishTime')">
</el-date-picker>
</el-form-item>
<el-form-item label="入口" prop="entranceId">
<el-form-item :label="$t('checkJobIn.entrance')" prop="entranceId"> <!--入口-->
<el-input
v-model="queryParams.entranceId"
placeholder="请输入入口ID"
:placeholder="$t('checkJobIn.inputEntranceId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="出口" prop="exitId">
<el-form-item :label="$t('checkJobIn.exit')" prop="exitId"> <!--出口-->
<el-input
v-model="queryParams.exitId"
placeholder="请输入出口ID"
:placeholder="$t('checkJobIn.inputExitId')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -185,10 +185,10 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="仓库" prop="warehouseId">
<el-form-item :label="$t('checkJobIn.warehouse')" prop="warehouseId"> <!--仓库-->
<el-input
v-model="queryParams.warehouseId"
placeholder="请输入仓库ID"
:placeholder="$t('checkJobIn.inputWarehouseId')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -202,97 +202,87 @@
/>
</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-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">{{$t('checkJobIn.search')}}</el-button> <!--搜索-->
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">{{$t('checkJobIn.reset')}}</el-button> <!--重置-->
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-edit"
size="mini"
@click="handleCompletedManually({type: 'invalid'})"
v-hasPermi="['job:mydoJob:CompletedManually']"
>手动作废</el-button>
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
@click="handleCompletedManually({type: 'completed'})"
v-hasPermi="['job:mydoJob:CompletedManually']"
>手动完成</el-button>
</el-col>
<!-- <el-col :span="1.5">
<el-button
type="warning"
plain
icon="el-icon-download"
size="mini"
@click="handleExport"
v-hasPermi="['job:mydoJob:export']"
>导出</el-button>
</el-col>-->
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="danger"
plain
icon="el-icon-delete"
size="mini"
:disabled="multiple"
@click="handleManualVoid"
v-hasPermi="['check:job:in:void']"
>{{$t('checkJobIn.manualVoid')}}</el-button> <!--手动作废-->
</el-col>
<el-col :span="1.5">
<el-button
type="success"
plain
icon="el-icon-edit"
size="mini"
:disabled="multiple"
@click="handleManualFinish"
v-hasPermi="['check:job:in:finish']"
>{{$t('checkJobIn.manualFinish')}}</el-button> <!--手动完成-->
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="mydoJobList" @selection-change="handleSelectionChange" @row-click="handleRowClick" highlight-current-row :current-row="currentRow"
max-height="300">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="任务ID" align="center" prop="jobId" fixed />
<el-table-column label="任务状态" align="center" prop="status">
<el-table-column :label="$t('checkJobIn.jobId')" align="center" prop="jobId" /> <!--任务ID-->
<el-table-column :label="$t('checkJobIn.status')" align="center" prop="status"> <!--任务状态-->
<template slot-scope="scope">
<dict-tag :options="dict.type.mydo_job_status" :value="scope.row.status"/>
</template>
</el-table-column>
<el-table-column label="上线类型" align="center" prop="onLineType">
<el-table-column :label="$t('checkJobIn.onLineType')" align="center" prop="onLineType"> <!--上线类型-->
<template slot-scope="scope">
<dict-tag :options="dict.type.on_line_type" :value="scope.row.onLineType"/>
</template>
</el-table-column>
<el-table-column label="任务类型" align="center" prop="inOrOut">
<el-table-column :label="$t('checkJobIn.jobType')" align="center" prop="inOrOut"> <!--任务类型-->
<template slot-scope="scope">
<dict-tag :options="dict.type.check_in_job_type" :value="scope.row.inOrOut"/>
</template>
</el-table-column>
<el-table-column label="任务号" align="center" prop="taskNo" />
<el-table-column label="供应商" align="center" prop="supplierName" key="supplierId" value="supplierName" />
<!-- <el-table-column label="客户ID" align="center" prop="customerId" />-->
<el-table-column label="部门" align="center" prop="departmentName" />
<el-table-column label="托盘码" align="center" prop="trayCode" />
<el-table-column label="巷道ID" align="center" prop="roadwayId" />
<el-table-column label="货位" align="center" prop="cargoSpaceName" />
<el-table-column label="目标巷道" align="center" prop="targetRoadwayId" />
<el-table-column label="目标货位" align="center" prop="targetCargoSpaceName" />
<el-table-column label="产线ID" align="center" prop="lineId" />
<el-table-column label="车间ID" align="center" prop="workshopId" />
<el-table-column label="优先级" align="center" prop="priority" />
<el-table-column label="执行阶段" align="center" prop="executionPhase">
<el-table-column :label="$t('checkJobIn.taskNo')" align="center" prop="taskNo" /> <!--任务号-->
<el-table-column :label="$t('checkJobIn.supplier')" align="center" prop="supplierName" key="supplierId" value="supplierName" /> <!--供应商-->
<el-table-column :label="$t('checkJobIn.department')" align="center" prop="departmentName" /> <!--部门-->
<el-table-column :label="$t('checkJobIn.trayCode')" align="center" prop="trayCode" /> <!--托盘码-->
<el-table-column :label="$t('checkJobIn.roadwayId')" align="center" prop="roadwayId" /> <!--巷道ID-->
<el-table-column :label="$t('checkJobIn.cargoSpace')" align="center" prop="cargoSpaceName" /> <!--货位-->
<el-table-column :label="$t('checkJobIn.targetRoadway')" align="center" prop="targetRoadwayId" /> <!--目标巷道-->
<el-table-column :label="$t('checkJobIn.targetCargoSpace')" align="center" prop="targetCargoSpaceName" /> <!--目标货位-->
<el-table-column :label="$t('checkJobIn.lineId')" align="center" prop="lineId" /> <!--产线ID-->
<el-table-column :label="$t('checkJobIn.workshopId')" align="center" prop="workshopId" /> <!--车间ID-->
<el-table-column :label="$t('checkJobIn.priority')" align="center" prop="priority" /> <!--优先级-->
<el-table-column :label="$t('checkJobIn.executionPhase')" align="center" prop="executionPhase"> <!--执行阶段-->
<template slot-scope="scope">
<dict-tag :options="dict.type.execution_phase_type" :value="scope.row.executionPhase"/>
</template>
</el-table-column>
<el-table-column label="开始时间" align="center" prop="startTime" width="180">
<el-table-column :label="$t('checkJobIn.startTime')" align="center" prop="startTime" width="180"> <!--开始时间-->
<template slot-scope="scope">
<span>{{ parseTime(scope.row.startTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="结束时间" align="center" prop="finishTime" width="180">
<el-table-column :label="$t('checkJobIn.finishTime')" align="center" prop="finishTime" width="180"> <!--结束时间-->
<template slot-scope="scope">
<span>{{ parseTime(scope.row.finishTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="入口ID" align="center" prop="entranceId" />
<!-- <el-table-column label="出口ID" align="center" prop="exitId" />-->
<el-table-column label="班组ID" align="center" prop="classId" />
<el-table-column label="仓库ID" align="center" prop="warehouseId" />
<el-table-column label="重分标记" align="center" prop="faultFlag" />
<el-table-column :label="$t('checkJobIn.entranceId')" align="center" prop="entranceId" /> <!--入口ID-->
<el-table-column :label="$t('checkJobIn.classId')" align="center" prop="classId" /> <!--班组ID-->
<el-table-column :label="$t('checkJobIn.warehouseId')" align="center" prop="warehouseId" /> <!--仓库ID-->
<el-table-column :label="$t('checkJobIn.faultFlag')" align="center" prop="faultFlag" /> <!--重分标记-->
</el-table>
<pagination
@@ -307,36 +297,23 @@
max-height="300"
>
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="子任务ID" align="center" prop="jobDetailId" />
<el-table-column label="任务ID" align="center" prop="jobId" />
<el-table-column label="库存ID" align="center" prop="stockId" />
<el-table-column label="批次号" align="center" prop="lotNo" />
<el-table-column label="入库时间" align="center" prop="inDate" width="180">
<el-table-column :label="$t('checkJobIn.jobDetailId')" align="center" prop="jobDetailId" /> <!--子任务ID-->
<el-table-column :label="$t('checkJobIn.jobId')" align="center" prop="jobId" /> <!--任务ID-->
<el-table-column :label="$t('checkJobIn.stockId')" align="center" prop="stockId" /> <!--库存ID-->
<el-table-column :label="$t('checkJobIn.lotNo')" align="center" prop="lotNo" /> <!--批次号-->
<el-table-column :label="$t('checkJobIn.inDate')" align="center" prop="inDate" width="180"> <!--入库时间-->
<template slot-scope="scope">
<span>{{ parseTime(scope.row.inDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="单据ID" align="center" prop="inOrOutId" />
<el-table-column label="子单据ID" align="center" prop="inOrOutDId" />
<el-table-column label="物料GUID" align="center" prop="productGuid" />
<el-table-column label="物料编码" align="center" prop="productId" />
<el-table-column label="库存状态" align="center" prop="stockStatus" />
<el-table-column label="入库数量" align="center" prop="inQuantity" />
<!-- <el-table-column label="库存数量" align="center" prop="stockQuantity" />-->
<!-- <el-table-column label="出库数量" align="center" prop="outQuantity" />-->
<!-- <el-table-column label="整层数量" align="center" prop="layerQuantity" />-->
<!-- <el-table-column label="出库层数量" align="center" prop="outLayerQuantity" />-->
<!-- <el-table-column label="回流数量" align="center" prop="giveNum" />-->
<!-- <el-table-column label="追溯入库单ID" align="center" prop="stockinId" />-->
<!-- <el-table-column label="垛型ID" align="center" prop="stackingId" />-->
<!-- <el-table-column label="出库口ID" align="center" prop="exitId" />-->
<el-table-column label="生产日期" align="center" prop="printDate" />
<!-- <el-table-column label="客户ID" align="center" prop="customerId" />-->
<el-table-column label="供应商ID" align="center" prop="supplierId" />
<!-- <el-table-column label="备用字段1" align="center" prop="spare1" />
<el-table-column label="备用字段2" align="center" prop="spare2" />
<el-table-column label="备用字段3" align="center" prop="spare3" />
<el-table-column label="备用字段4" align="center" prop="spare4" />-->
<el-table-column :label="$t('checkJobIn.inOrOutId')" align="center" prop="inOrOutId" /> <!--单据ID-->
<el-table-column :label="$t('checkJobIn.inOrOutDId')" align="center" prop="inOrOutDId" /> <!--子单据ID-->
<el-table-column :label="$t('checkJobIn.productGuid')" align="center" prop="productGuid" /> <!--物料GUID-->
<el-table-column :label="$t('checkJobIn.productId')" align="center" prop="productId" /> <!--物料编码-->
<el-table-column :label="$t('checkJobIn.stockStatus')" align="center" prop="stockStatus" /> <!--库存状态-->
<el-table-column :label="$t('checkJobIn.inQuantity')" align="center" prop="inQuantity" /> <!--入库数量-->
<el-table-column :label="$t('checkJobIn.printDate')" align="center" prop="printDate" /> <!--生产日期-->
<el-table-column :label="$t('checkJobIn.supplierId')" align="center" prop="supplierId" /> <!--供应商ID-->
</el-table>
<pagination
@@ -423,15 +400,16 @@ export default {
// 表单参数
form: {},
// 表单校验
// 表单校验
rules: {
jobId: [
{ required: true, message: "任务ID不能为空", trigger: "blur" }
{ required: true, message: this.$t('checkJobIn.jobIdRequired'), trigger: "blur" }
],
status: [
{ required: true, message: "任务状态不能为空", trigger: "change" }
{ required: true, message: this.$t('checkJobIn.statusRequired'), trigger: "change" }
],
taskNo: [
{ required: true, message: "任务号不能为空", trigger: "blur" }
{ required: true, message: this.$t('checkJobIn.taskNoRequired'), trigger: "blur" }
],
}
}
@@ -522,7 +500,7 @@ export default {
handleCompletedManually(row) {
const jobIds = this.ids;
if (jobIds.length === 0) {
this.$modal.msgError("请选择要操作的数据");
this.$modal.msgError(this.$t('checkJobIn.selectData'));
return;
}
if (row.type === 'invalid'){

View File

@@ -1,16 +1,16 @@
<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="任务ID" prop="jobId">
<el-form-item :label="$t('checkJobOut.jobId')" prop="jobId"> <!-- 任务ID -->
<el-input
v-model="queryParams.jobId"
placeholder="请输入任务ID"
:placeholder="$t('checkJobOut.inputJobId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="任务状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择任务状态" clearable>
<el-form-item :label="$t('checkJobOut.status')" prop="status"> <!-- 任务状态 -->
<el-select v-model="queryParams.status" :placeholder="$t('checkJobOut.selectStatus')" clearable>
<el-option
v-for="dict in dict.type.mydo_job_status"
:key="dict.value"
@@ -29,10 +29,10 @@
/>
</el-select>
</el-form-item>-->
<el-form-item label="任务号" prop="taskNo">
<el-form-item :label="$t('checkJobOut.taskNo')" prop="taskNo"> <!-- 任务号 -->
<el-input
v-model="queryParams.taskNo"
placeholder="请输入任务号"
:placeholder="$t('checkJobOut.inputTaskNo')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -61,10 +61,10 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="托盘码" prop="trayCode">
<el-form-item :label="$t('checkJobOut.trayCode')" prop="trayCode"> <!-- 托盘码 -->
<el-input
v-model="queryParams.trayCode"
placeholder="请输入托盘码"
:placeholder="$t('checkJobOut.inputTrayCode')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -93,10 +93,10 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="目标货位" prop="targetCargoSpaceId">
<el-form-item :label="$t('checkJobOut.targetCargoSpace')" prop="targetCargoSpaceId"> <!-- 目标货位 -->
<el-input
v-model="queryParams.targetCargoSpaceId"
placeholder="请输入目标货位ID"
:placeholder="$t('checkJobOut.inputTargetCargoSpace')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -125,8 +125,8 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="执行阶段" prop="executionPhase">
<el-select v-model="queryParams.executionPhase" placeholder="请选择执行阶段" clearable>
<el-form-item :label="$t('checkJobOut.executionPhase')" prop="executionPhase"> <!-- 执行阶段 -->
<el-select v-model="queryParams.executionPhase" :placeholder="$t('checkJobOut.selectExecutionPhase')" clearable>
<el-option
v-for="dict in dict.type.execution_phase_type"
:key="dict.value"
@@ -135,8 +135,8 @@
/>
</el-select>
</el-form-item>
<el-form-item label="任务类型" prop="inOrOut">
<el-select v-model="queryParams.inOrOut" placeholder="请选择任务类型" clearable>
<el-form-item :label="$t('checkJobOut.jobType')" prop="inOrOut"> <!-- 任务类型 -->
<el-select v-model="queryParams.inOrOut" :placeholder="$t('checkJobOut.selectJobType')" clearable>
<el-option
v-for="dict in dict.type.check_out_job_type"
:key="dict.value"
@@ -145,34 +145,34 @@
/>
</el-select>
</el-form-item>
<el-form-item label="开始时间" prop="startTime">
<el-form-item :label="$t('checkJobOut.startTime')" prop="startTime"> <!-- 开始时间 -->
<el-date-picker clearable
v-model="queryParams.startTime"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择开始时间">
:placeholder="$t('checkJobOut.selectStartTime')">
</el-date-picker>
</el-form-item>
<el-form-item label="结束时间" prop="finishTime">
<el-form-item :label="$t('checkJobOut.finishTime')" prop="finishTime"> <!-- 结束时间 -->
<el-date-picker clearable
v-model="queryParams.finishTime"
type="date"
value-format="yyyy-MM-dd"
placeholder="请选择结束时间">
:placeholder="$t('checkJobOut.selectFinishTime')">
</el-date-picker>
</el-form-item>
<el-form-item label="入口" prop="entranceId">
<el-form-item :label="$t('checkJobOut.entranceId')" prop="entranceId"> <!-- 入口ID -->
<el-input
v-model="queryParams.entranceId"
placeholder="请输入入口ID"
:placeholder="$t('checkJobOut.inputEntranceId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="出口" prop="exitId">
<el-form-item :label="$t('checkJobOut.exitId')" prop="exitId"> <!-- 出口ID -->
<el-input
v-model="queryParams.exitId"
placeholder="请输入出口ID"
:placeholder="$t('checkJobOut.inputExitId')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -185,10 +185,10 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="仓库" prop="warehouseId">
<el-form-item :label="$t('checkJobOut.warehouse')" prop="warehouseId"> <!-- 仓库 -->
<el-input
v-model="queryParams.warehouseId"
placeholder="请输入仓库ID"
:placeholder="$t('checkJobOut.inputWarehouseId')"
clearable
@keyup.enter.native="handleQuery"
/>
@@ -202,12 +202,13 @@
/>
</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-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">{{$t('checkJobOut.search')}}</el-button> <!-- 搜索 -->
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">{{$t('checkJobOut.reset')}}</el-button> <!-- 重置 -->
</el-form-item>
</el-form>
<!-- <el-row :gutter="10" class="mb8">
<el-row :gutter="10" class="mb8">
<el-col :span="1.5">
<el-button
type="danger"
@@ -216,7 +217,7 @@
size="mini"
@click="handleCompletedManually({type: 'invalid'})"
v-hasPermi="['job:mydoJob:CompletedManually']"
>手动作废</el-button>
>{{$t('checkJobOut.manualInvalid')}}</el-button> <!-- 手动作废 -->
</el-col>
<el-col :span="1.5">
<el-button
@@ -226,9 +227,9 @@
size="mini"
@click="handleCompletedManually({type: 'completed'})"
v-hasPermi="['job:mydoJob:CompletedManually']"
>手动完成</el-button>
>{{$t('checkJobOut.manualFinish')}}</el-button> <!-- 手动完成 -->
</el-col>
&lt;!&ndash; <el-col :span="1.5">
<!-- <el-col :span="1.5">
<el-button
type="warning"
plain
@@ -237,62 +238,73 @@
@click="handleExport"
v-hasPermi="['job:mydoJob:export']"
>导出</el-button>
</el-col>&ndash;&gt;
</el-col> -->
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>-->
</el-row>
<el-table v-loading="loading" :data="mydoJobList" @selection-change="handleSelectionChange" @row-click="handleRowClick" highlight-current-row :current-row="currentRow"
max-height="300">
<el-table v-loading="loading" :data="jobList" @selection-change="handleSelectionChange" @row-click="handleRowClick">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="任务ID" align="center" prop="jobId" fixed />
<el-table-column label="任务状态" align="center" prop="status">
<el-table-column :label="$t('checkJobOut.jobId')" align="center" prop="jobId" /> <!-- 任务ID -->
<el-table-column :label="$t('checkJobOut.status')" align="center" prop="status"> <!-- 任务状态 -->
<template slot-scope="scope">
<dict-tag :options="dict.type.mydo_job_status" :value="scope.row.status"/>
</template>
</el-table-column>
<el-table-column label="上线类型" align="center" prop="onLineType">
<el-table-column :label="$t('checkJobOut.onLineType')" align="center" prop="onLineType"> <!-- 上线类型 -->
<template slot-scope="scope">
<dict-tag :options="dict.type.on_line_type" :value="scope.row.onLineType"/>
</template>
</el-table-column>
<el-table-column label="任务类型" align="center" prop="inOrOut">
<el-table-column :label="$t('checkJobOut.jobType')" align="center" prop="inOrOut"> <!-- 任务类型 -->
<template slot-scope="scope">
<dict-tag :options="dict.type.check_out_job_type" :value="scope.row.inOrOut"/>
</template>
</el-table-column>
<el-table-column label="任务号" align="center" prop="taskNo" />
<el-table-column label="供应商" align="center" prop="supplierName" key="supplierId" value="supplierName" />
<!-- <el-table-column label="客户ID" align="center" prop="customerId" />-->
<el-table-column label="部门" align="center" prop="departmentName" />
<el-table-column label="托盘码" align="center" prop="trayCode" />
<el-table-column label="巷道ID" align="center" prop="roadwayId" />
<el-table-column label="货位" align="center" prop="cargoSpaceName" />
<el-table-column label="目标巷道" align="center" prop="targetRoadwayId" />
<el-table-column label="目标货位" align="center" prop="targetCargoSpaceName" />
<el-table-column label="产线ID" align="center" prop="lineId" />
<el-table-column label="车间ID" align="center" prop="workshopId" />
<el-table-column label="优先级" align="center" prop="priority" />
<el-table-column label="执行阶段" align="center" prop="executionPhase">
<el-table-column :label="$t('checkJobOut.taskNo')" align="center" prop="taskNo" /> <!-- 任务号 -->
<el-table-column :label="$t('checkJobOut.supplierId')" align="center" prop="supplierId" /> <!-- 供应商ID -->
<el-table-column :label="$t('checkJobOut.departmentId')" align="center" prop="departmentId" /> <!-- 部门ID -->
<el-table-column :label="$t('checkJobOut.trayCode')" align="center" prop="trayCode" /> <!-- 托盘码 -->
<el-table-column :label="$t('checkJobOut.roadwayId')" align="center" prop="roadwayId" /> <!-- 巷道ID -->
<el-table-column :label="$t('checkJobOut.cargoSpaceId')" align="center" prop="cargoSpaceId" /> <!-- 货位ID -->
<el-table-column :label="$t('checkJobOut.targetRoadwayId')" align="center" prop="targetRoadwayId" /> <!-- 目标巷道ID -->
<el-table-column :label="$t('checkJobOut.targetCargoSpace')" align="center" prop="targetCargoSpaceId" /> <!-- 目标货位 -->
<el-table-column :label="$t('checkJobOut.lineId')" align="center" prop="lineId" /> <!-- 产线ID -->
<el-table-column :label="$t('checkJobOut.workshopId')" align="center" prop="workshopId" /> <!-- 车间ID -->
<el-table-column :label="$t('checkJobOut.priority')" align="center" prop="priority" /> <!-- 优先级 -->
<el-table-column :label="$t('checkJobOut.executionPhase')" align="center" prop="executionPhase"> <!-- 执行阶段 -->
<template slot-scope="scope">
<dict-tag :options="dict.type.execution_phase_type" :value="scope.row.executionPhase"/>
</template>
</el-table-column>
<el-table-column label="开始时间" align="center" prop="startTime" width="180">
<el-table-column :label="$t('checkJobOut.startTime')" align="center" prop="startTime" width="180"> <!-- 开始时间 -->
<template slot-scope="scope">
<span>{{ parseTime(scope.row.startTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="结束时间" align="center" prop="finishTime" width="180">
<el-table-column :label="$t('checkJobOut.finishTime')" align="center" prop="finishTime" width="180"> <!-- 结束时间 -->
<template slot-scope="scope">
<span>{{ parseTime(scope.row.finishTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="入口ID" align="center" prop="entranceId" />
<!-- <el-table-column label="出口ID" align="center" prop="exitId" />-->
<el-table-column label="班组ID" align="center" prop="classId" />
<el-table-column label="仓库ID" align="center" prop="warehouseId" />
<el-table-column label="重分标记" align="center" prop="faultFlag" />
<el-table-column :label="$t('checkJobOut.entranceId')" align="center" prop="entranceId" /> <!-- 入口ID -->
<el-table-column :label="$t('checkJobOut.exitId')" align="center" prop="exitId" /> <!-- 出口ID -->
<el-table-column :label="$t('checkJobOut.classId')" align="center" prop="classId" /> <!-- 班组ID -->
<el-table-column :label="$t('checkJobOut.warehouse')" align="center" prop="warehouseId" /> <!-- 仓库 -->
<el-table-column :label="$t('checkJobOut.faultFlag')" align="center" prop="faultFlag" /> <!-- 重分标记 -->
<el-table-column :label="$t('checkJobOut.operation')" align="center" class-name="small-padding fixed-width"> <!-- 操作 -->
<template slot-scope="scope">
<el-button
size="mini"
type="text"
@click="handleManualFinish(scope.row)"
>{{$t('checkJobOut.manualFinish')}}</el-button> <!-- 手动完成 -->
<el-button
size="mini"
type="text"
@click="handleManualInvalid(scope.row)"
>{{$t('checkJobOut.manualInvalid')}}</el-button> <!-- 手动作废 -->
</template>
</el-table-column>
</el-table>
<pagination
@@ -303,32 +315,36 @@
@pagination="getList"
/>
<el-table v-loading="detailLoading" :data="mydoJobDetailList" @selection-change="handleSelectionChange"
max-height="300"
>
<el-table v-loading="loading" :data="subJobList" @selection-change="handleSelectionChange">
<el-table-column type="selection" width="55" align="center" />
<el-table-column label="子任务ID" align="center" prop="jobDetailId" />
<el-table-column label="任务ID" align="center" prop="jobId" />
<el-table-column label="库存ID" align="center" prop="stockId" />
<el-table-column label="批次号" align="center" prop="lotNo" />
<el-table-column label="入库时间" align="center" prop="inDate" width="180">
<el-table-column :label="$t('checkJobOut.subJobId')" align="center" prop="subJobId" /> <!-- 子任务ID -->
<el-table-column :label="$t('checkJobOut.jobId')" align="center" prop="jobId" /> <!-- 任务ID -->
<el-table-column :label="$t('checkJobOut.stockId')" align="center" prop="stockId" /> <!-- 库存ID -->
<el-table-column :label="$t('checkJobOut.batchNo')" align="center" prop="batchNo" /> <!-- 批次号 -->
<el-table-column :label="$t('checkJobOut.inTime')" align="center" prop="inTime" width="180"> <!-- 入库时间 -->
<template slot-scope="scope">
<span>{{ parseTime(scope.row.inDate, '{y}-{m}-{d}') }}</span>
<span>{{ parseTime(scope.row.inTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column label="单据ID" align="center" prop="inOrOutId" />
<el-table-column label="子单据ID" align="center" prop="inOrOutDId" />
<el-table-column label="物料GUID" align="center" prop="productGuid" />
<el-table-column label="物料编码" align="center" prop="productId" />
<el-table-column label="库存状态" align="center" prop="stockStatus" />
<el-table-column label="入库数量" align="center" prop="inQuantity" />
<!-- <el-table-column label="库存数量" align="center" prop="stockQuantity" />-->
<!-- <el-table-column label="出库数量" align="center" prop="outQuantity" />-->
<!-- <el-table-column label="整层数量" align="center" prop="layerQuantity" />-->
<!-- <el-table-column label="出库层数量" align="center" prop="outLayerQuantity" />-->
<!-- <el-table-column label="回流数量" align="center" prop="giveNum" />-->
<!-- <el-table-column label="追溯入库单ID" align="center" prop="stockinId" />-->
<!-- <el-table-column label="垛型ID" align="center" prop="stackingId" />-->
<el-table-column :label="$t('checkJobOut.billId')" align="center" prop="billId" /> <!-- 单据ID -->
<el-table-column :label="$t('checkJobOut.subBillId')" align="center" prop="subBillId" /> <!-- 子单据ID -->
<el-table-column :label="$t('checkJobOut.materialGuid')" align="center" prop="materialGuid" /> <!-- 物料GUID -->
<el-table-column :label="$t('checkJobOut.materialCode')" align="center" prop="materialCode" /> <!-- 物料编码 -->
<el-table-column :label="$t('checkJobOut.stockStatus')" align="center" prop="stockStatus" /> <!-- 库存状态 -->
<el-table-column :label="$t('checkJobOut.inQty')" align="center" prop="inQty" /> <!-- 入库数量 -->
<el-table-column :label="$t('checkJobOut.productDate')" align="center" prop="productDate" width="180"> <!-- 生产日期 -->
<template slot-scope="scope">
<span>{{ parseTime(scope.row.productDate, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column :label="$t('checkJobOut.supplierId')" align="center" prop="supplierId" /> <!-- 供应商ID -->
<!-- <el-table-column label="库存数量" align="center" prop="stockQuantity" />
<!-- <el-table-column label="出库数量" align="center" prop="outQuantity" />
<!-- <el-table-column label="整层数量" align="center" prop="layerQuantity" />
<!-- <el-table-column label="出库层数量" align="center" prop="outLayerQuantity" />
<!-- <el-table-column label="回流数量" align="center" prop="giveNum" />
<!-- <el-table-column label="追溯入库单ID" align="center" prop="stockinId" />
<!-- <el-table-column label="垛型ID" align="center" prop="stackingId" />
<!-- <el-table-column label="出库口ID" align="center" prop="exitId" />-->
<el-table-column label="生产日期" align="center" prop="printDate" />
<!-- <el-table-column label="客户ID" align="center" prop="customerId" />-->
@@ -425,13 +441,13 @@ export default {
// 表单校验
rules: {
jobId: [
{ required: true, message: "任务ID不能为空", trigger: "blur" }
{ required: true, message: this.$t('checkJobOut.inputJobId'), trigger: 'blur' }
],
status: [
{ required: true, message: "任务状态不能为空", trigger: "change" }
{ required: true, message: this.$t('checkJobOut.selectStatus'), trigger: 'change' }
],
taskNo: [
{ required: true, message: "任务号不能为空", trigger: "blur" }
{ required: true, message: this.$t('checkJobOut.inputTaskNo'), trigger: 'blur' }
],
}
}
@@ -522,7 +538,7 @@ export default {
handleCompletedManually(row) {
const jobIds = this.ids;
if (jobIds.length === 0) {
this.$modal.msgError("请选择要操作的数据");
this.$modal.msgError(this.$t('checkJobOut.selectData')); // 请选择要操作的数据
return;
}
if (row.type === 'invalid'){
@@ -563,6 +579,34 @@ export default {
this.detailLoading = false;
});
},
/** 手动完成按钮操作 */
handleManualFinish(row) {
const jobIds = row.jobId || this.ids;
if (jobIds.length === 0) {
this.$modal.msgError(this.$t('checkJobOut.selectData'));
return;
}
this.$modal.confirm(this.$t('checkJobOut.confirmFinish', { jobIds: jobIds })).then(function() {
return manualFinish(jobIds);
}).then(() => {
this.getList();
this.$modal.msgSuccess(this.$t('checkJobOut.finishSuccess'));
}).catch(() => {});
},
/** 手动作废按钮操作 */
handleManualInvalid(row) {
const jobIds = row.jobId || this.ids;
if (jobIds.length === 0) {
this.$modal.msgError(this.$t('checkJobOut.selectData'));
return;
}
this.$modal.confirm(this.$t('checkJobOut.confirmInvalid', { jobIds: jobIds })).then(function() {
return manualInvalid(jobIds);
}).then(() => {
this.getList();
this.$modal.msgSuccess(this.$t('checkJobOut.invalidSuccess'));
}).catch(() => {});
},
}
}
</script>

View File

@@ -1,16 +1,16 @@
<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="盘点单据ID" prop="stockCheckId">
<el-form-item :label="$t('checkStockCheck.stockCheckId')" prop="stockCheckId"> <!-- 盘点单据ID -->
<el-input
v-model="queryParams.stockCheckId"
placeholder="请输入盘点单据ID"
:placeholder="$t('checkStockCheck.inputStockCheckId')"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="盘库类型" prop="checkType">
<el-select v-model="queryParams.checkType" placeholder="请选择盘库类型" clearable>
<el-form-item :label="$t('checkStockCheck.checkType')" prop="checkType"> <!-- 盘库类型 -->
<el-select v-model="queryParams.checkType" :placeholder="$t('checkStockCheck.selectCheckType')" clearable>
<el-option
v-for="dict in dict.type.check_stock_type"
:key="dict.value"
@@ -19,8 +19,8 @@
/>
</el-select>
</el-form-item>
<el-form-item label="状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择盘库类型" clearable>
<el-form-item :label="$t('checkStockCheck.status')" prop="status"> <!-- 状态 -->
<el-select v-model="queryParams.status" :placeholder="$t('checkStockCheck.selectStatus')" clearable>
<el-option
v-for="dict in dict.type.check_bill_status"
:key="dict.value"
@@ -45,8 +45,8 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>-->
<el-form-item label="仓库" prop="warehouseId">
<el-select v-model="queryParams.warehouseId" placeholder="请选择仓库" clearable>
<el-form-item :label="$t('checkStockCheck.warehouse')" prop="warehouseId"> <!-- 仓库 -->
<el-select v-model="queryParams.warehouseId" :placeholder="$t('checkStockCheck.selectWarehouse')" clearable>
<el-option
v-for="item in warehouseOptions"
:key="item.warehouseId"
@@ -144,8 +144,8 @@
/>
</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-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">{{$t('checkStockCheck.search')}}</el-button> <!-- 搜索 -->
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">{{$t('checkStockCheck.reset')}}</el-button> <!-- 重置 -->
</el-form-item>
</el-form>
@@ -159,7 +159,7 @@
:disabled="multiple"
@click="handleInvalidated"
v-hasPermi="['check:stockCheck:edit']"
>单据作废</el-button>
>{{$t('checkStockCheck.invalidate')}}</el-button> <!-- 单据作废 -->
</el-col>
<el-col :span="1.5">
<el-button
@@ -169,7 +169,7 @@
size="mini"
@click="handleReview"
v-hasPermi="['check:stockCheck:edit']"
>单据审核</el-button>
>{{$t('checkStockCheck.review')}}</el-button> <!-- 单据审核 -->
</el-col>
<el-col :span="1.5">
<el-button
@@ -180,7 +180,7 @@
:disabled="single"
@click="handleConfirmation"
v-hasPermi="['check:stockCheck:edit']"
>单据确认</el-button>
>{{$t('checkStockCheck.confirm')}}</el-button> <!-- 单据确认 -->
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
@@ -189,25 +189,24 @@
<el-table v-loading="loading" :data="stockCheckList" @selection-change="handleSelectionChange" @row-click="handleRowClick">
<el-table-column type="selection" width="55" align="center" />
<!-- <el-table-column label="GUID" align="center" prop="stockGuid" /> -->
<el-table-column label="盘点单据ID" align="center" prop="stockCheckId" />
<el-table-column label="盘库类型" align="center" prop="checkType">
<el-table-column :label="$t('checkStockCheck.stockCheckId')" align="center" prop="stockCheckId" /> <!-- 盘点单据ID -->
<el-table-column :label="$t('checkStockCheck.checkType')" align="center" prop="checkType"> <!-- 盘库类型 -->
<template slot-scope="scope">
<dict-tag :options="dict.type.check_stock_type" :value="scope.row.checkType"/>
</template>
</el-table-column>
<el-table-column label="单据状态" align="center" prop="status" >
<el-table-column :label="$t('checkStockCheck.status')" align="center" prop="status" > <!-- 单据状态 -->
<template slot-scope="scope">
<dict-tag :options="dict.type.check_bill_status" :value="scope.row.status"/>
</template>
</el-table-column>
<el-table-column label="仓库ID" align="center" prop="warehouseId" />
<el-table-column label="单据来源" align="center" prop="stockSource" />
<el-table-column label="部门编码" align="center" prop="departmentNo" />
<el-table-column label="创建人" align="center" prop="createManId" />
<el-table-column label="建立时间" align="center" prop="createDate" />
<el-table-column label=" 完成日期" align="center" prop="finishDate" />
<el-table-column :label="$t('checkStockCheck.warehouseId')" align="center" prop="warehouseId" /> <!-- 仓库ID -->
<el-table-column :label="$t('checkStockCheck.stockSource')" align="center" prop="stockSource" /> <!-- 单据来源 -->
<el-table-column :label="$t('checkStockCheck.departmentNo')" align="center" prop="departmentNo" /> <!-- 部门编码 -->
<el-table-column :label="$t('checkStockCheck.createManId')" align="center" prop="createManId" /> <!-- 创建人 -->
<el-table-column :label="$t('checkStockCheck.createDate')" align="center" prop="createDate" /> <!-- 建立时间 -->
<el-table-column :label="$t('checkStockCheck.finishDate')" align="center" prop="finishDate" /> <!-- 完成日期 -->
</el-table>
<pagination
@@ -220,19 +219,19 @@
<el-table v-loading="detailLoading" :data="stockCheckDetailList" @selection-change="handleDetailSelectionChange">
<!-- <el-table-column type="selection" width="55" align="center" /> -->
<el-table-column label="子单ID" align="center" prop="stockCheckDetailId" />
<el-table-column :label="$t('checkStockCheck.detailId')" align="center" prop="stockCheckDetailId" /> <!-- 子单ID -->
<!-- <el-table-column label="主单GUID" align="center" prop="stockCheckGuid" /> -->
<el-table-column label="主单ID" align="center" prop="stockCheckId" />
<el-table-column label="批次号" align="center" prop="lotNo"/>
<el-table-column :label="$t('checkStockCheck.mainId')" align="center" prop="stockCheckId" /> <!-- 主单ID -->
<el-table-column :label="$t('checkStockCheck.lotNo')" align="center" prop="lotNo"/> <!-- 批次号 -->
<!-- <el-table-column label="物料ID" align="center" prop="productGuid"/>-->
<el-table-column label="物料编码" align="center" prop="productId"/>
<el-table-column label="物料描述" align="center" prop="extraField.materialDesc"/>
<el-table-column label="英文描述" align="center" prop="extraField.englishDesc"/>
<el-table-column label="箱号" align="center" prop="extraField.cartonNo"/>
<el-table-column label="包装方式" align="center" prop="extraField.packingMethod"/>
<el-table-column label="计划数量" align="center" prop="quantity"/>
<el-table-column label="扫码数量" align="center" prop="scanNum"/>
<el-table-column label="实际数量" align="center" prop="assignNum"/>
<el-table-column :label="$t('checkStockCheck.productId')" align="center" prop="productId"/> <!-- 物料编码 -->
<el-table-column :label="$t('checkStockCheck.materialDesc')" align="center" prop="extraField.materialDesc"/> <!-- 物料描述 -->
<el-table-column :label="$t('checkStockCheck.englishDesc')" align="center" prop="extraField.englishDesc"/> <!-- 英文描述 -->
<el-table-column :label="$t('checkStockCheck.cartonNo')" align="center" prop="extraField.cartonNo"/> <!-- 箱号 -->
<el-table-column :label="$t('checkStockCheck.packingMethod')" align="center" prop="extraField.packingMethod"/> <!-- 包装方式 -->
<el-table-column :label="$t('checkStockCheck.quantity')" align="center" prop="quantity"/> <!-- 计划数量 -->
<el-table-column :label="$t('checkStockCheck.scanNum')" align="center" prop="scanNum"/> <!-- 扫码数量 -->
<el-table-column :label="$t('checkStockCheck.assignNum')" align="center" prop="assignNum"/> <!-- 实际数量 -->
</el-table>
<pagination
@@ -318,16 +317,16 @@ export default {
// 表单校验
rules: {
stockCheckId: [
{ required: true, message: "盘点单据ID不能为空", trigger: "blur" }
{ required: true, message: this.$t('checkStockCheck.stockCheckIdRequired'), trigger: "blur" }
],
checkType: [
{ required: true, message: "盘库类型不能为空", trigger: "change" }
{ required: true, message: this.$t('checkStockCheck.checkTypeRequired'), trigger: "change" }
],
createDate: [
{ required: true, message: "建立时间不能为空", trigger: "blur" }
{ required: true, message: this.$t('checkStockCheck.createDateRequired'), trigger: "blur" }
],
status: [
{ required: true, message: "单据状态不能为空", trigger: "change" }
{ required: true, message: this.$t('checkStockCheck.statusRequired'), trigger: "change" }
],
}
}
@@ -438,13 +437,13 @@ export default {
if (valid) {
if (this.form.stockGuid != null) {
updateStockCheck(this.form).then(response => {
this.$modal.msgSuccess("修改成功")
this.$modal.msgSuccess(this.$t('checkStockCheck.editSuccess'))
this.open = false
this.getList()
})
} else {
addStockCheck(this.form).then(response => {
this.$modal.msgSuccess("新增成功")
this.$modal.msgSuccess(this.$t('checkStockCheck.addSuccess'))
this.open = false
this.getList()
})
@@ -461,18 +460,18 @@ export default {
"status": "5"
}
updateStockCheck(data).then(response => {
this.$modal.msgSuccess("作废成功")
this.$modal.msgSuccess(this.$t('checkStockCheck.invalidateSuccess'))
this.getList()
})
} else {
this.$modal.msgError("只有未审核的单据可以作废")
this.$modal.msgError(this.$t('checkStockCheck.onlyUnreviewedCanInvalidate'))
}
},
/** 审核按钮操作 */
handleReview(row) {
let stockCheck = this.stockCheckList.find(item => item.stockGuid === (row?.stockGuid || this.ids[0]));
if (stockCheck.status === "2") {
this.$modal.msgError("单据已审核,请勿重复审核")
this.$modal.msgError(this.$t('checkStockCheck.alreadyReviewed'))
return
}
if (stockCheck.status === "1") {
@@ -481,11 +480,11 @@ export default {
"status": "2"
}
updateStockCheck(data).then(response => {
this.$modal.msgSuccess("审核成功")
this.$modal.msgSuccess(this.$t('checkStockCheck.reviewSuccess'))
this.getList()
})
} else {
this.$modal.msgError("只有未审核的单据可以审核")
this.$modal.msgError(this.$t('checkStockCheck.onlyUnreviewedCanReview'))
}
},
/** 确认按钮操作 */
@@ -497,11 +496,11 @@ export default {
"status": "4"
}
updateStockCheck(data).then(response => {
this.$modal.msgSuccess("确认成功")
this.$modal.msgSuccess(this.$t('checkStockCheck.confirmSuccess'))
this.getList()
})
} else {
this.$modal.msgError("只有已审核的单据可以确认")
this.$modal.msgError(this.$t('checkStockCheck.onlyReviewedCanConfirm'))
}
},
}