feat(钢卷管理): 新增生产时间记录及耗时计算功能
添加TimeInput组件用于时间输入,并在钢卷合并、分条、打字、分步操作中增加生产开始/结束时间字段 实现生产耗时自动计算功能,支持显示xx天xx小时xx分钟格式 在基础面板中增加生产时间修正对话框,支持批量修改时间
This commit is contained in:
86
klp-ui/src/components/TimeInput.vue
Normal file
86
klp-ui/src/components/TimeInput.vue
Normal file
@@ -0,0 +1,86 @@
|
|||||||
|
<template>
|
||||||
|
<div class="time-input-group">
|
||||||
|
<el-date-picker v-model="dateValue" type="date" value-format="yyyy-MM-dd" placeholder="选择日期" style="width: 140px;" @change="updateDateTime" />
|
||||||
|
<span class="time-separator">@</span>
|
||||||
|
<el-input-number :controls="false" v-model="hourValue" placeholder="时" min="0" max="23" style="width: 60px;" @change="updateDateTime" />
|
||||||
|
<span class="time-separator">:</span>
|
||||||
|
<el-input-number :controls="false" v-model="minuteValue" placeholder="分" min="0" max="59" style="width: 60px;" @change="updateDateTime" />
|
||||||
|
<span class="time-separator">:00</span>
|
||||||
|
<el-button v-if="showNowButton" type="text" size="small" @click="setToNow" style="margin-left: 8px;">此刻</el-button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'TimeInput',
|
||||||
|
props: {
|
||||||
|
value: {
|
||||||
|
type: String,
|
||||||
|
default: ''
|
||||||
|
},
|
||||||
|
showNowButton: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
dateValue: '',
|
||||||
|
hourValue: '',
|
||||||
|
minuteValue: ''
|
||||||
|
};
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
value: {
|
||||||
|
handler(newValue) {
|
||||||
|
this.parseDateTime(newValue);
|
||||||
|
},
|
||||||
|
immediate: true
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
parseDateTime(dateTimeStr) {
|
||||||
|
if (!dateTimeStr) {
|
||||||
|
this.dateValue = '';
|
||||||
|
this.hourValue = '';
|
||||||
|
this.minuteValue = '';
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
const date = new Date(dateTimeStr);
|
||||||
|
if (!isNaN(date.getTime())) {
|
||||||
|
this.dateValue = date.toISOString().split('T')[0];
|
||||||
|
this.hourValue = date.getHours();
|
||||||
|
this.minuteValue = date.getMinutes();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
updateDateTime() {
|
||||||
|
if (this.dateValue && this.hourValue !== '' && this.minuteValue !== '') {
|
||||||
|
const dateTimeStr = `${this.dateValue} ${this.hourValue}:${this.minuteValue}:00`;
|
||||||
|
this.$emit('input', dateTimeStr);
|
||||||
|
} else {
|
||||||
|
this.$emit('input', '');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
setToNow() {
|
||||||
|
const now = new Date();
|
||||||
|
this.dateValue = now.toISOString().split('T')[0];
|
||||||
|
this.hourValue = now.getHours();
|
||||||
|
this.minuteValue = now.getMinutes();
|
||||||
|
this.updateDateTime();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.time-input-group {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.time-separator {
|
||||||
|
color: #909399;
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -215,6 +215,21 @@
|
|||||||
<WarehouseSelect v-model="targetCoil.warehouseId" placeholder="请选择逻辑库区" :disabled="readonly" />
|
<WarehouseSelect v-model="targetCoil.warehouseId" placeholder="请选择逻辑库区" :disabled="readonly" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="form-row">
|
||||||
|
<el-form-item label="生产开始时间" prop="productionStartTime" class="form-item-half">
|
||||||
|
<TimeInput v-model="targetCoil.productionStartTime" @input="calculateProductionDuration" :disabled="readonly" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生产结束时间" prop="productionEndTime" class="form-item-half">
|
||||||
|
<TimeInput v-model="targetCoil.productionEndTime" @input="calculateProductionDuration" :disabled="readonly" :show-now-button="true" />
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="form-row">
|
||||||
|
<el-form-item label="生产耗时" prop="productionDuration" class="form-item-half">
|
||||||
|
<el-input v-model="targetCoil.formattedDuration" placeholder="自动计算" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</div>
|
||||||
</el-form>
|
</el-form>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -231,6 +246,7 @@ import ActualWarehouseSelect from "@/components/KLPService/ActualWarehouseSelect
|
|||||||
import RawMaterialSelector from "@/components/KLPService/RawMaterialSelect";
|
import RawMaterialSelector from "@/components/KLPService/RawMaterialSelect";
|
||||||
import ProductSelector from "@/components/KLPService/ProductSelect";
|
import ProductSelector from "@/components/KLPService/ProductSelect";
|
||||||
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
||||||
|
import TimeInput from "@/components/TimeInput";
|
||||||
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@@ -240,7 +256,8 @@ export default {
|
|||||||
ActualWarehouseSelect,
|
ActualWarehouseSelect,
|
||||||
RawMaterialSelector,
|
RawMaterialSelector,
|
||||||
ProductSelector,
|
ProductSelector,
|
||||||
WarehouseSelect
|
WarehouseSelect,
|
||||||
|
TimeInput
|
||||||
},
|
},
|
||||||
dicts: ['coil_quality_status'],
|
dicts: ['coil_quality_status'],
|
||||||
data() {
|
data() {
|
||||||
@@ -270,6 +287,10 @@ export default {
|
|||||||
coatingType: '',
|
coatingType: '',
|
||||||
actualLength: undefined,
|
actualLength: undefined,
|
||||||
actualWidth: undefined,
|
actualWidth: undefined,
|
||||||
|
productionStartTime: '',
|
||||||
|
productionEndTime: '',
|
||||||
|
productionDuration: '',
|
||||||
|
formattedDuration: '',
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
currentCoilNo: [
|
currentCoilNo: [
|
||||||
@@ -759,6 +780,49 @@ export default {
|
|||||||
this.$router.back();
|
this.$router.back();
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// 格式化毫秒值为xx天xx小时xx分钟
|
||||||
|
formatDuration(milliseconds) {
|
||||||
|
if (!milliseconds || milliseconds < 0) return '';
|
||||||
|
|
||||||
|
const seconds = Math.floor(milliseconds / 1000);
|
||||||
|
const minutes = Math.floor(seconds / 60);
|
||||||
|
const hours = Math.floor(minutes / 60);
|
||||||
|
const days = Math.floor(hours / 24);
|
||||||
|
|
||||||
|
const remainingHours = hours % 24;
|
||||||
|
const remainingMinutes = minutes % 60;
|
||||||
|
|
||||||
|
let result = '';
|
||||||
|
if (days > 0) result += `${days}天`;
|
||||||
|
if (remainingHours > 0) result += `${remainingHours}小时`;
|
||||||
|
if (remainingMinutes > 0) result += `${remainingMinutes}分钟`;
|
||||||
|
|
||||||
|
return result || '0分钟';
|
||||||
|
},
|
||||||
|
// 计算生产耗时
|
||||||
|
calculateProductionDuration() {
|
||||||
|
const { productionStartTime, productionEndTime } = this.targetCoil;
|
||||||
|
if (productionStartTime && productionEndTime) {
|
||||||
|
const start = new Date(productionStartTime).getTime();
|
||||||
|
const end = new Date(productionEndTime).getTime();
|
||||||
|
if (end < start) {
|
||||||
|
this.$message({
|
||||||
|
message: '结束时间不能早于开始时间',
|
||||||
|
type: 'error',
|
||||||
|
});
|
||||||
|
this.$set(this.targetCoil, 'productionDuration', '');
|
||||||
|
this.$set(this.targetCoil, 'formattedDuration', '');
|
||||||
|
} else {
|
||||||
|
const durationMs = end - start;
|
||||||
|
const durationMinutes = Math.round(durationMs / (1000 * 60));
|
||||||
|
this.$set(this.targetCoil, 'productionDuration', durationMinutes);
|
||||||
|
this.$set(this.targetCoil, 'formattedDuration', this.formatDuration(durationMinutes * 60 * 1000));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$set(this.targetCoil, 'productionDuration', '');
|
||||||
|
this.$set(this.targetCoil, 'formattedDuration', '');
|
||||||
|
}
|
||||||
|
},
|
||||||
// closePage 关闭当前页面
|
// closePage 关闭当前页面
|
||||||
closePage() {
|
closePage() {
|
||||||
this.$router.back();
|
this.$router.back();
|
||||||
|
|||||||
@@ -173,7 +173,7 @@
|
|||||||
<el-table-column label="业务目的" align="center" prop="businessPurpose" v-if="showBusinessPurpose" width="150">
|
<el-table-column label="业务目的" align="center" prop="businessPurpose" v-if="showBusinessPurpose" width="150">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-select v-model="scope.row.businessPurpose" placeholder="业务目的" filterable
|
<el-select v-model="scope.row.businessPurpose" placeholder="业务目的" filterable
|
||||||
@change="handleBusinessPurposeChange(scope.row)">
|
@change="handleRowChange(scope.row)">
|
||||||
<el-option v-for="item in dict.type.coil_business_purpose" :key="item.value" :value="item.value"
|
<el-option v-for="item in dict.type.coil_business_purpose" :key="item.value" :value="item.value"
|
||||||
:label="item.label" />
|
:label="item.label" />
|
||||||
</el-select>
|
</el-select>
|
||||||
@@ -182,8 +182,8 @@
|
|||||||
|
|
||||||
<el-table-column label="关联订单" align="center" prop="relatedToOrder" v-if="showRelatedToOrder" width="150">
|
<el-table-column label="关联订单" align="center" prop="relatedToOrder" v-if="showRelatedToOrder" width="150">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-switch @change="handleRelatedToOrderChange(scope.row)" v-model="scope.row.isRelatedToOrder"
|
<el-switch @change="handleRowChange(scope.row)" v-model="scope.row.isRelatedToOrder" :active-value="1"
|
||||||
:active-value="1" :inactive-value="0" />
|
:inactive-value="0" />
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|
||||||
@@ -230,7 +230,21 @@
|
|||||||
<el-tag v-else type="info" size="mini">未发货</el-tag>
|
<el-tag v-else type="info" size="mini">未发货</el-tag>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- <el-table-column label="备注" align="center" prop="remark" show-overflow-tooltip/> -->
|
|
||||||
|
<el-table-column label="实测宽度" align="center" prop="width" v-if="showWidthEdit" width="150">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-input v-model="scope.row.actualWidth" placeholder="请输入实测宽度"
|
||||||
|
@change="handleRowChange(scope.row)"></el-input>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
|
<el-table-column label="预留宽度" align="center" prop="width" v-if="showWidthEdit" width="150">
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-input v-model="scope.row.reservedWidth" placeholder="请输入预留宽度"
|
||||||
|
@change="handleRowChange(scope.row)"></el-input>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
|
||||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button size="mini" type="text" icon="el-icon-view" @click="handlePreviewLabel(scope.row)">
|
<el-button size="mini" type="text" icon="el-icon-view" @click="handlePreviewLabel(scope.row)">
|
||||||
@@ -247,18 +261,16 @@
|
|||||||
@click="handleCancelExport(scope.row)">
|
@click="handleCancelExport(scope.row)">
|
||||||
撤回发货
|
撤回发货
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button size="mini" v-if="showProductionTimeEdit" type="text" icon="el-icon-close"
|
||||||
|
@click="handleProductionTimeEdit(scope.row)">
|
||||||
|
加工修正
|
||||||
|
</el-button>
|
||||||
<el-button size="mini" v-if="showExportTime" type="text" icon="el-icon-sold-out"
|
<el-button size="mini" v-if="showExportTime" type="text" icon="el-icon-sold-out"
|
||||||
@click="handleReturnCoil(scope.row)">
|
@click="handleReturnCoil(scope.row)">
|
||||||
退货钢卷
|
退货钢卷
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- <el-button size="mini" v-if="showAbnormal" type="text" icon="el-icon-upload"
|
|
||||||
@click="handleAbnormal(scope.row)">查看异常</el-button> -->
|
|
||||||
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleCheck(scope.row)"
|
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleCheck(scope.row)"
|
||||||
v-if="showControl">修正</el-button>
|
v-if="showControl">修正</el-button>
|
||||||
<!-- <el-button size="mini" type="text" icon="el-icon-time" @click="handleLog(scope.row)"
|
|
||||||
v-if="showWareLog">吞吐记录</el-button> -->
|
|
||||||
<!-- <el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
|
|
||||||
v-if="showControl">删除</el-button> -->
|
|
||||||
<el-button size="mini" type="text" icon="el-icon-search" @click="handleTrace(scope.row)">追溯</el-button>
|
<el-button size="mini" type="text" icon="el-icon-search" @click="handleTrace(scope.row)">追溯</el-button>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -396,6 +408,28 @@
|
|||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
||||||
|
<el-dialog title="生产时间修正" :visible.sync="productionTimeFormVisible" width="500px" append-to-body>
|
||||||
|
<el-form ref="productionTimeForm" :model="productionTimeForm" :rules="productionTimeFormRules"
|
||||||
|
label-width="100px">
|
||||||
|
<el-form-item label="生产开始时间" prop="productionStartTime">
|
||||||
|
<el-date-picker v-model="productionTimeForm.productionStartTime" type="datetime"
|
||||||
|
value-format="yyyy-MM-dd HH:mm:ss" placeholder="请选择生产时间" @change="(value) => { productionTimeForm.productionStartTime = value; calculateProductionDuration(); }" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生产结束时间" prop="productionEndTime">
|
||||||
|
<el-date-picker v-model="productionTimeForm.productionEndTime" type="datetime"
|
||||||
|
value-format="yyyy-MM-dd HH:mm:ss" placeholder="请选择生产时间" @change="(value) => { productionTimeForm.productionEndTime = value; calculateProductionDuration(); }" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生产耗时" prop="productionDuration">
|
||||||
|
<!-- <div>{{ productionTimeForm.formattedDuration }}</div> -->
|
||||||
|
<el-input v-model="productionTimeForm.formattedDuration" placeholder="自动计算" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<div slot="footer" class="dialog-footer">
|
||||||
|
<el-button :loading="buttonLoading" type="primary" @click="submitProductionTimeForm">确 定</el-button>
|
||||||
|
<el-button @click="productionTimeFormVisible = false">取 消</el-button>
|
||||||
|
</div>
|
||||||
|
</el-dialog>
|
||||||
|
|
||||||
<!-- <el-dialog title="异常信息" :visible.sync="abnormalOpen" width="90%" append-to-body> -->
|
<!-- <el-dialog title="异常信息" :visible.sync="abnormalOpen" width="90%" append-to-body> -->
|
||||||
<abnormal-list v-if="showAbnormal && currentCoilId" :coil-id="currentCoilId"></abnormal-list>
|
<abnormal-list v-if="showAbnormal && currentCoilId" :coil-id="currentCoilId"></abnormal-list>
|
||||||
<!-- </el-dialog> -->
|
<!-- </el-dialog> -->
|
||||||
@@ -553,7 +587,17 @@ export default {
|
|||||||
showNewExport: {
|
showNewExport: {
|
||||||
type: Boolean,
|
type: Boolean,
|
||||||
default: false,
|
default: false,
|
||||||
}
|
},
|
||||||
|
// 展示宽度快捷编辑
|
||||||
|
showWidthEdit: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
|
// 展示生产时间快捷编辑
|
||||||
|
showProductionTimeEdit: {
|
||||||
|
type: Boolean,
|
||||||
|
default: false,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -724,6 +768,18 @@ export default {
|
|||||||
currentCoilId: '',
|
currentCoilId: '',
|
||||||
userList: [],
|
userList: [],
|
||||||
logOpen: false,
|
logOpen: false,
|
||||||
|
productionTimeForm: {
|
||||||
|
productionStartTime: '',
|
||||||
|
productionEndTime: '',
|
||||||
|
formattedDuration: '',
|
||||||
|
productionDuration: 0,
|
||||||
|
},
|
||||||
|
productionTimeFormRules: {
|
||||||
|
productionTime: [
|
||||||
|
{ required: true, message: "生产时间不能为空", trigger: "blur" }
|
||||||
|
],
|
||||||
|
},
|
||||||
|
productionTimeFormVisible: false,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -759,6 +815,88 @@ export default {
|
|||||||
this.userList = res.rows || [];
|
this.userList = res.rows || [];
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
handleProductionTimeEdit(row) {
|
||||||
|
// 创建一个新对象,避免直接引用row
|
||||||
|
this.productionTimeForm = { ...row };
|
||||||
|
this.productionTimeFormVisible = true;
|
||||||
|
// 初始化时计算一次
|
||||||
|
this.calculateProductionDuration();
|
||||||
|
},
|
||||||
|
// 格式化毫秒值为xx天xx小时xx分钟
|
||||||
|
formatDuration(milliseconds) {
|
||||||
|
if (!milliseconds || milliseconds < 0) return '';
|
||||||
|
|
||||||
|
const seconds = Math.floor(milliseconds / 1000);
|
||||||
|
const minutes = Math.floor(seconds / 60);
|
||||||
|
const hours = Math.floor(minutes / 60);
|
||||||
|
const days = Math.floor(hours / 24);
|
||||||
|
|
||||||
|
const remainingHours = hours % 24;
|
||||||
|
const remainingMinutes = minutes % 60;
|
||||||
|
|
||||||
|
let result = '';
|
||||||
|
if (days > 0) result += `${days}天`;
|
||||||
|
if (remainingHours > 0) result += `${remainingHours}小时`;
|
||||||
|
if (remainingMinutes > 0) result += `${remainingMinutes}分钟`;
|
||||||
|
|
||||||
|
return result || '0分钟';
|
||||||
|
},
|
||||||
|
// 计算生产耗时
|
||||||
|
calculateProductionDuration() {
|
||||||
|
const { productionStartTime, productionEndTime } = this.productionTimeForm;
|
||||||
|
if (productionStartTime && productionEndTime) {
|
||||||
|
const start = new Date(productionStartTime).getTime();
|
||||||
|
const end = new Date(productionEndTime).getTime();
|
||||||
|
if (end < start) {
|
||||||
|
this.$message({
|
||||||
|
message: '结束时间不能早于开始时间',
|
||||||
|
type: 'error',
|
||||||
|
});
|
||||||
|
this.$set(this.productionTimeForm, 'productionDuration', '');
|
||||||
|
this.$set(this.productionTimeForm, 'formattedDuration', '');
|
||||||
|
} else {
|
||||||
|
const durationMs = end - start;
|
||||||
|
const durationMinutes = Math.round(durationMs / (1000 * 60));
|
||||||
|
this.$set(this.productionTimeForm, 'productionDuration', durationMinutes);
|
||||||
|
// 同时保存格式化后的显示值
|
||||||
|
this.$set(this.productionTimeForm, 'formattedDuration', this.formatDuration(durationMinutes * 60 * 1000));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$set(this.productionTimeForm, 'productionDuration', '');
|
||||||
|
this.$set(this.productionTimeForm, 'formattedDuration', '');
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 处理生产时间提交
|
||||||
|
submitProductionTimeForm() {
|
||||||
|
this.$refs.productionTimeForm.validate((valid) => {
|
||||||
|
if (valid) {
|
||||||
|
// 再次验证时间逻辑
|
||||||
|
const { productionStartTime, productionEndTime } = this.productionTimeForm;
|
||||||
|
if (productionStartTime && productionEndTime) {
|
||||||
|
const start = new Date(productionStartTime).getTime();
|
||||||
|
const end = new Date(productionEndTime).getTime();
|
||||||
|
if (end < start) {
|
||||||
|
this.$message({
|
||||||
|
message: '结束时间不能早于开始时间',
|
||||||
|
type: 'error',
|
||||||
|
});
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
this.buttonLoading = true;
|
||||||
|
updateMaterialCoilSimple(this.productionTimeForm).then(res => {
|
||||||
|
this.buttonLoading = false;
|
||||||
|
this.$message({
|
||||||
|
message: '更新成功',
|
||||||
|
type: 'success',
|
||||||
|
});
|
||||||
|
this.productionTimeFormVisible = false;
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
handleNextWarehouseChange(row) {
|
handleNextWarehouseChange(row) {
|
||||||
if (!this.editNext) {
|
if (!this.editNext) {
|
||||||
return;
|
return;
|
||||||
@@ -777,37 +915,13 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleBusinessPurposeChange(row) {
|
// 处理行数据变化
|
||||||
if (!this.showBusinessPurpose) {
|
handleRowChange(row) {
|
||||||
return;
|
|
||||||
}
|
|
||||||
updateMaterialCoilSimple(row).then(res => {
|
updateMaterialCoilSimple(row).then(res => {
|
||||||
if (res.code === 200) {
|
this.$message({
|
||||||
this.$message({
|
message: '更新成功',
|
||||||
message: '更新成功',
|
type: 'success',
|
||||||
type: 'success',
|
});
|
||||||
});
|
|
||||||
} else {
|
|
||||||
this.$message({
|
|
||||||
message: res.msg || '更新失败',
|
|
||||||
type: 'error',
|
|
||||||
});
|
|
||||||
}
|
|
||||||
})
|
|
||||||
},
|
|
||||||
handleRelatedToOrderChange(row) {
|
|
||||||
updateMaterialCoilSimple(row).then(res => {
|
|
||||||
if (res.code === 200) {
|
|
||||||
this.$message({
|
|
||||||
message: '更新成功',
|
|
||||||
type: 'success',
|
|
||||||
});
|
|
||||||
} else {
|
|
||||||
this.$message({
|
|
||||||
message: res.msg || '更新失败',
|
|
||||||
type: 'error',
|
|
||||||
});
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
// 打印标签
|
// 打印标签
|
||||||
|
|||||||
@@ -149,6 +149,15 @@
|
|||||||
<el-form-item label="镀层种类" prop="coatingType">
|
<el-form-item label="镀层种类" prop="coatingType">
|
||||||
<MemoInput storageKey="coatingType" v-model="splitForm.coatingType" placeholder="请输入镀层种类" />
|
<MemoInput storageKey="coatingType" v-model="splitForm.coatingType" placeholder="请输入镀层种类" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="生产开始时间" prop="productionStartTime">
|
||||||
|
<TimeInput v-model="splitForm.productionStartTime" @input="calculateProductionDuration" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生产结束时间" prop="productionEndTime">
|
||||||
|
<TimeInput v-model="splitForm.productionEndTime" @input="calculateProductionDuration" :show-now-button="true" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生产耗时" prop="productionDuration">
|
||||||
|
<el-input v-model="splitForm.formattedDuration" placeholder="自动计算" disabled />
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="备注" prop="remark">
|
<el-form-item label="备注" prop="remark">
|
||||||
<el-input v-model="splitForm.remark" placeholder="请输入备注" type="textarea" />
|
<el-input v-model="splitForm.remark" placeholder="请输入备注" type="textarea" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -187,6 +196,9 @@
|
|||||||
m</el-descriptions-item>
|
m</el-descriptions-item>
|
||||||
<el-descriptions-item label="调制度">{{ selectedSplitItem.temperGrade || '-' }}</el-descriptions-item>
|
<el-descriptions-item label="调制度">{{ selectedSplitItem.temperGrade || '-' }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="镀层种类">{{ selectedSplitItem.coatingType || '-' }}</el-descriptions-item>
|
<el-descriptions-item label="镀层种类">{{ selectedSplitItem.coatingType || '-' }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="生产开始时间">{{ selectedSplitItem.productionStartTime || '-' }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="生产结束时间">{{ selectedSplitItem.productionEndTime || '-' }}</el-descriptions-item>
|
||||||
|
<el-descriptions-item label="生产耗时">{{ selectedSplitItem.formattedDuration || (selectedSplitItem.productionDuration ? selectedSplitItem.productionDuration + ' 分钟' : '-') }}</el-descriptions-item>
|
||||||
<el-descriptions-item label="备注" :span="2">{{ selectedSplitItem.remark || '-' }}</el-descriptions-item>
|
<el-descriptions-item label="备注" :span="2">{{ selectedSplitItem.remark || '-' }}</el-descriptions-item>
|
||||||
</el-descriptions>
|
</el-descriptions>
|
||||||
</el-card>
|
</el-card>
|
||||||
@@ -208,6 +220,7 @@ import ProductSelect from "@/components/KLPService/ProductSelect";
|
|||||||
import RawMaterialSelect from "@/components/KLPService/RawMaterialSelect";
|
import RawMaterialSelect from "@/components/KLPService/RawMaterialSelect";
|
||||||
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
||||||
import ActualWarehouseSelect from "@/components/KLPService/ActualWarehouseSelect";
|
import ActualWarehouseSelect from "@/components/KLPService/ActualWarehouseSelect";
|
||||||
|
import TimeInput from "@/components/TimeInput";
|
||||||
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@@ -231,6 +244,7 @@ export default {
|
|||||||
RawMaterialSelect,
|
RawMaterialSelect,
|
||||||
WarehouseSelect,
|
WarehouseSelect,
|
||||||
ActualWarehouseSelect,
|
ActualWarehouseSelect,
|
||||||
|
TimeInput,
|
||||||
},
|
},
|
||||||
dicts: ['coil_quality_status'],
|
dicts: ['coil_quality_status'],
|
||||||
data() {
|
data() {
|
||||||
@@ -264,6 +278,10 @@ export default {
|
|||||||
temperGrade: '',
|
temperGrade: '',
|
||||||
coatingType: '',
|
coatingType: '',
|
||||||
remark: '',
|
remark: '',
|
||||||
|
productionStartTime: '',
|
||||||
|
productionEndTime: '',
|
||||||
|
productionDuration: '',
|
||||||
|
formattedDuration: '',
|
||||||
},
|
},
|
||||||
// 已分条钢卷列表
|
// 已分条钢卷列表
|
||||||
splitList: [],
|
splitList: [],
|
||||||
@@ -443,6 +461,10 @@ export default {
|
|||||||
temperGrade: '',
|
temperGrade: '',
|
||||||
coatingType: '',
|
coatingType: '',
|
||||||
remark: '',
|
remark: '',
|
||||||
|
productionStartTime: '',
|
||||||
|
productionEndTime: '',
|
||||||
|
productionDuration: '',
|
||||||
|
formattedDuration: '',
|
||||||
parentCoilId: this.coilId,
|
parentCoilId: this.coilId,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -547,6 +569,49 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
// 格式化毫秒值为xx天xx小时xx分钟
|
||||||
|
formatDuration(milliseconds) {
|
||||||
|
if (!milliseconds || milliseconds < 0) return '';
|
||||||
|
|
||||||
|
const seconds = Math.floor(milliseconds / 1000);
|
||||||
|
const minutes = Math.floor(seconds / 60);
|
||||||
|
const hours = Math.floor(minutes / 60);
|
||||||
|
const days = Math.floor(hours / 24);
|
||||||
|
|
||||||
|
const remainingHours = hours % 24;
|
||||||
|
const remainingMinutes = minutes % 60;
|
||||||
|
|
||||||
|
let result = '';
|
||||||
|
if (days > 0) result += `${days}天`;
|
||||||
|
if (remainingHours > 0) result += `${remainingHours}小时`;
|
||||||
|
if (remainingMinutes > 0) result += `${remainingMinutes}分钟`;
|
||||||
|
|
||||||
|
return result || '0分钟';
|
||||||
|
},
|
||||||
|
// 计算生产耗时
|
||||||
|
calculateProductionDuration() {
|
||||||
|
const { productionStartTime, productionEndTime } = this.splitForm;
|
||||||
|
if (productionStartTime && productionEndTime) {
|
||||||
|
const start = new Date(productionStartTime).getTime();
|
||||||
|
const end = new Date(productionEndTime).getTime();
|
||||||
|
if (end < start) {
|
||||||
|
this.$message({
|
||||||
|
message: '结束时间不能早于开始时间',
|
||||||
|
type: 'error',
|
||||||
|
});
|
||||||
|
this.$set(this.splitForm, 'productionDuration', '');
|
||||||
|
this.$set(this.splitForm, 'formattedDuration', '');
|
||||||
|
} else {
|
||||||
|
const durationMs = end - start;
|
||||||
|
const durationMinutes = Math.round(durationMs / (1000 * 60));
|
||||||
|
this.$set(this.splitForm, 'productionDuration', durationMinutes);
|
||||||
|
this.$set(this.splitForm, 'formattedDuration', this.formatDuration(durationMinutes * 60 * 1000));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$set(this.splitForm, 'productionDuration', '');
|
||||||
|
this.$set(this.splitForm, 'formattedDuration', '');
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -218,6 +218,15 @@
|
|||||||
<ActualWarehouseSelect v-model="item.actualWarehouseId" placeholder="请选择真实库区" block
|
<ActualWarehouseSelect v-model="item.actualWarehouseId" placeholder="请选择真实库区" block
|
||||||
:disabled="readonly" />
|
:disabled="readonly" />
|
||||||
</el-form-item> -->
|
</el-form-item> -->
|
||||||
|
<el-form-item label="生产开始时间">
|
||||||
|
<TimeInput v-model="item.productionStartTime" @input="() => calculateProductionDuration(item)" :disabled="readonly" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生产结束时间">
|
||||||
|
<TimeInput v-model="item.productionEndTime" @input="() => calculateProductionDuration(item)" :disabled="readonly" :show-now-button="true" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="生产耗时">
|
||||||
|
<el-input v-model="item.formattedDuration" placeholder="自动计算" disabled />
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="备注">
|
<el-form-item label="备注">
|
||||||
<el-input v-model="item.remark" placeholder="请输入备注" :disabled="readonly" />
|
<el-input v-model="item.remark" placeholder="请输入备注" :disabled="readonly" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -238,6 +247,7 @@ import ActualWarehouseSelect from "@/components/KLPService/ActualWarehouseSelect
|
|||||||
import RawMaterialSelect from "@/components/KLPService/RawMaterialSelect";
|
import RawMaterialSelect from "@/components/KLPService/RawMaterialSelect";
|
||||||
import ProductSelect from "@/components/KLPService/ProductSelect";
|
import ProductSelect from "@/components/KLPService/ProductSelect";
|
||||||
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
||||||
|
import TimeInput from "@/components/TimeInput";
|
||||||
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@@ -247,6 +257,7 @@ export default {
|
|||||||
RawMaterialSelect,
|
RawMaterialSelect,
|
||||||
ProductSelect,
|
ProductSelect,
|
||||||
WarehouseSelect,
|
WarehouseSelect,
|
||||||
|
TimeInput,
|
||||||
},
|
},
|
||||||
dicts: ['coil_quality_status'],
|
dicts: ['coil_quality_status'],
|
||||||
data() {
|
data() {
|
||||||
@@ -289,6 +300,10 @@ export default {
|
|||||||
coatingType: '',
|
coatingType: '',
|
||||||
actualLength: undefined,
|
actualLength: undefined,
|
||||||
actualWidth: undefined,
|
actualWidth: undefined,
|
||||||
|
productionStartTime: '',
|
||||||
|
productionEndTime: '',
|
||||||
|
productionDuration: '',
|
||||||
|
formattedDuration: '',
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
loading: false,
|
loading: false,
|
||||||
@@ -475,6 +490,10 @@ export default {
|
|||||||
coatingType: '',
|
coatingType: '',
|
||||||
actualLength: undefined,
|
actualLength: undefined,
|
||||||
actualWidth: undefined,
|
actualWidth: undefined,
|
||||||
|
productionStartTime: '',
|
||||||
|
productionEndTime: '',
|
||||||
|
productionDuration: '',
|
||||||
|
formattedDuration: '',
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -612,6 +631,51 @@ export default {
|
|||||||
// 不再预加载物品列表,改为实时搜索
|
// 不再预加载物品列表,改为实时搜索
|
||||||
|
|
||||||
this.$message.success('已复制到所有子卷');
|
this.$message.success('已复制到所有子卷');
|
||||||
|
},
|
||||||
|
// 格式化毫秒值为xx天xx小时xx分钟
|
||||||
|
formatDuration(milliseconds) {
|
||||||
|
if (!milliseconds || milliseconds < 0) return '';
|
||||||
|
|
||||||
|
const seconds = Math.floor(milliseconds / 1000);
|
||||||
|
const minutes = Math.floor(seconds / 60);
|
||||||
|
const hours = Math.floor(minutes / 60);
|
||||||
|
const days = Math.floor(hours / 24);
|
||||||
|
|
||||||
|
const remainingHours = hours % 24;
|
||||||
|
const remainingMinutes = minutes % 60;
|
||||||
|
|
||||||
|
let result = '';
|
||||||
|
if (days > 0) result += `${days}天`;
|
||||||
|
if (remainingHours > 0) result += `${remainingHours}小时`;
|
||||||
|
if (remainingMinutes > 0) result += `${remainingMinutes}分钟`;
|
||||||
|
|
||||||
|
return result || '0分钟';
|
||||||
|
},
|
||||||
|
// 计算生产耗时
|
||||||
|
calculateProductionDuration(item) {
|
||||||
|
if (!item) return;
|
||||||
|
|
||||||
|
const { productionStartTime, productionEndTime } = item;
|
||||||
|
if (productionStartTime && productionEndTime) {
|
||||||
|
const start = new Date(productionStartTime).getTime();
|
||||||
|
const end = new Date(productionEndTime).getTime();
|
||||||
|
if (end < start) {
|
||||||
|
this.$message({
|
||||||
|
message: '结束时间不能早于开始时间',
|
||||||
|
type: 'error',
|
||||||
|
});
|
||||||
|
this.$set(item, 'productionDuration', '');
|
||||||
|
this.$set(item, 'formattedDuration', '');
|
||||||
|
} else {
|
||||||
|
const durationMs = end - start;
|
||||||
|
const durationMinutes = Math.round(durationMs / (1000 * 60));
|
||||||
|
this.$set(item, 'productionDuration', durationMinutes);
|
||||||
|
this.$set(item, 'formattedDuration', this.formatDuration(durationMinutes * 60 * 1000));
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.$set(item, 'productionDuration', '');
|
||||||
|
this.$set(item, 'formattedDuration', '');
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -192,6 +192,18 @@
|
|||||||
<ActualWarehouseSelect :clearInput="false" clearable v-model="updateForm.actualWarehouseId" placeholder="请选择真实库区" block />
|
<ActualWarehouseSelect :clearInput="false" clearable v-model="updateForm.actualWarehouseId" placeholder="请选择真实库区" block />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="生产开始时间" prop="productionStartTime">
|
||||||
|
<TimeInput v-model="updateForm.productionStartTime" @input="calculateProductionDuration" />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="生产结束时间" prop="productionEndTime">
|
||||||
|
<TimeInput v-model="updateForm.productionEndTime" @input="calculateProductionDuration" :show-now-button="true" />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
|
<el-form-item label="生产耗时" prop="productionDuration">
|
||||||
|
<el-input v-model="updateForm.formattedDuration" placeholder="自动计算" disabled />
|
||||||
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="备注" prop="remark">
|
<el-form-item label="备注" prop="remark">
|
||||||
<el-input v-model="updateForm.remark" type="textarea" :rows="4" placeholder="请输入备注信息(非必填)" maxlength="500"
|
<el-input v-model="updateForm.remark" type="textarea" :rows="4" placeholder="请输入备注信息(非必填)" maxlength="500"
|
||||||
show-word-limit />
|
show-word-limit />
|
||||||
@@ -237,6 +249,7 @@ import ActualWarehouseSelect from "@/components/KLPService/ActualWarehouseSelect
|
|||||||
import RawMaterialSelect from "@/components/KLPService/RawMaterialSelect";
|
import RawMaterialSelect from "@/components/KLPService/RawMaterialSelect";
|
||||||
import ProductSelect from "@/components/KLPService/ProductSelect";
|
import ProductSelect from "@/components/KLPService/ProductSelect";
|
||||||
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
import WarehouseSelect from "@/components/KLPService/WarehouseSelect";
|
||||||
|
import TimeInput from "@/components/TimeInput";
|
||||||
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
import { generateCoilNoPrefix } from "@/utils/coil/coilNo";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@@ -246,6 +259,7 @@ export default {
|
|||||||
RawMaterialSelect,
|
RawMaterialSelect,
|
||||||
ProductSelect,
|
ProductSelect,
|
||||||
WarehouseSelect,
|
WarehouseSelect,
|
||||||
|
TimeInput,
|
||||||
},
|
},
|
||||||
dicts: ['coil_quality_status'],
|
dicts: ['coil_quality_status'],
|
||||||
data() {
|
data() {
|
||||||
@@ -292,6 +306,10 @@ export default {
|
|||||||
coatingType: '',
|
coatingType: '',
|
||||||
actualLength: undefined,
|
actualLength: undefined,
|
||||||
actualWidth: undefined,
|
actualWidth: undefined,
|
||||||
|
productionStartTime: '',
|
||||||
|
productionEndTime: '',
|
||||||
|
productionDuration: '',
|
||||||
|
formattedDuration: '',
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
currentCoilNo: [
|
currentCoilNo: [
|
||||||
@@ -556,6 +574,18 @@ export default {
|
|||||||
nextWarehouseName: this.getWarehouseName(data.warehouseId),
|
nextWarehouseName: this.getWarehouseName(data.warehouseId),
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 填充时间相关字段
|
||||||
|
if (data.productionStartTime) {
|
||||||
|
this.updateForm.productionStartTime = data.productionStartTime;
|
||||||
|
}
|
||||||
|
if (data.productionEndTime) {
|
||||||
|
this.updateForm.productionEndTime = data.productionEndTime;
|
||||||
|
}
|
||||||
|
if (data.productionDuration) {
|
||||||
|
this.updateForm.productionDuration = data.productionDuration;
|
||||||
|
this.updateForm.formattedDuration = this.formatDuration(data.productionDuration);
|
||||||
|
}
|
||||||
|
|
||||||
// 不再预加载物品列表,改为实时搜索
|
// 不再预加载物品列表,改为实时搜索
|
||||||
|
|
||||||
// 加载变更历史
|
// 加载变更历史
|
||||||
@@ -751,6 +781,20 @@ export default {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 验证时间逻辑
|
||||||
|
const { productionStartTime, productionEndTime } = this.updateForm;
|
||||||
|
if (productionStartTime && productionEndTime) {
|
||||||
|
const start = new Date(productionStartTime).getTime();
|
||||||
|
const end = new Date(productionEndTime).getTime();
|
||||||
|
if (end < start) {
|
||||||
|
this.$message({
|
||||||
|
message: '结束时间不能早于开始时间',
|
||||||
|
type: 'error',
|
||||||
|
});
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
const loadingInstance = this.$loading({
|
const loadingInstance = this.$loading({
|
||||||
lock: true,
|
lock: true,
|
||||||
text: '正在更新钢卷信息,请稍后...',
|
text: '正在更新钢卷信息,请稍后...',
|
||||||
@@ -796,6 +840,50 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
|
// 格式化毫秒值为xx天xx小时xx分钟
|
||||||
|
formatDuration(milliseconds) {
|
||||||
|
if (!milliseconds || milliseconds < 0) return '';
|
||||||
|
|
||||||
|
const seconds = Math.floor(milliseconds / 1000);
|
||||||
|
const minutes = Math.floor(seconds / 60);
|
||||||
|
const hours = Math.floor(minutes / 60);
|
||||||
|
const days = Math.floor(hours / 24);
|
||||||
|
|
||||||
|
const remainingHours = hours % 24;
|
||||||
|
const remainingMinutes = minutes % 60;
|
||||||
|
|
||||||
|
let result = '';
|
||||||
|
if (days > 0) result += `${days}天`;
|
||||||
|
if (remainingHours > 0) result += `${remainingHours}小时`;
|
||||||
|
if (remainingMinutes > 0) result += `${remainingMinutes}分钟`;
|
||||||
|
|
||||||
|
return result || '0分钟';
|
||||||
|
},
|
||||||
|
// 计算生产耗时
|
||||||
|
calculateProductionDuration() {
|
||||||
|
const { productionStartTime, productionEndTime } = this.updateForm;
|
||||||
|
if (productionStartTime && productionEndTime) {
|
||||||
|
const start = new Date(productionStartTime).getTime();
|
||||||
|
const end = new Date(productionEndTime).getTime();
|
||||||
|
if (end < start) {
|
||||||
|
this.$message({
|
||||||
|
message: '结束时间不能早于开始时间',
|
||||||
|
type: 'error',
|
||||||
|
});
|
||||||
|
this.updateForm.productionDuration = '';
|
||||||
|
this.updateForm.formattedDuration = '';
|
||||||
|
} else {
|
||||||
|
const durationMs = end - start;
|
||||||
|
const durationMinutes = Math.round(durationMs / (1000 * 60));
|
||||||
|
this.updateForm.productionDuration = durationMinutes;
|
||||||
|
this.updateForm.formattedDuration = this.formatDuration(durationMinutes * 60 * 1000);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.updateForm.productionDuration = '';
|
||||||
|
this.updateForm.formattedDuration = '';
|
||||||
|
}
|
||||||
|
},
|
||||||
// 取消操作
|
// 取消操作
|
||||||
handleCancel() {
|
handleCancel() {
|
||||||
this.$router.back();
|
this.$router.back();
|
||||||
@@ -980,6 +1068,8 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* 表单样式优化 */
|
/* 表单样式优化 */
|
||||||
.form-card {
|
.form-card {
|
||||||
::v-deep .el-input-number {
|
::v-deep .el-input-number {
|
||||||
|
|||||||
27
klp-ui/src/views/wms/coil/views/base/timeEdit.vue
Normal file
27
klp-ui/src/views/wms/coil/views/base/timeEdit.vue
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
<template>
|
||||||
|
<BasePage :qrcode="qrcode" :querys="querys" :labelType="labelType" :hideWarehouseQuery="hideWarehouseQuery"
|
||||||
|
:hideType="hideType" :showControl="showControl" :showProductionTimeEdit="showProductionTimeEdit" />
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import BasePage from '../../panels/base.vue';
|
||||||
|
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
BasePage
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
qrcode: false,
|
||||||
|
querys: {
|
||||||
|
// dataType: 1,
|
||||||
|
},
|
||||||
|
hideWarehouseQuery: true,
|
||||||
|
showProductionTimeEdit: true,
|
||||||
|
showControl: false,
|
||||||
|
labelType: '2',
|
||||||
|
hideType: false,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
Reference in New Issue
Block a user