|
|
@@ -7,39 +7,45 @@
|
|
|
:maxable="true"
|
|
|
:title="'详情'"
|
|
|
append-to-body
|
|
|
- :before-close="cancel"
|
|
|
+ :before-close="cancelDetails"
|
|
|
>
|
|
|
<div class="form-wrapper">
|
|
|
<el-form
|
|
|
ref="form"
|
|
|
:model="form"
|
|
|
- :inline="true"
|
|
|
label-position="right"
|
|
|
- label-width="100px"
|
|
|
+ label-width="107px"
|
|
|
>
|
|
|
- <el-row :gutter="10" class="basic" type="flex" style="flex-wrap: wrap">
|
|
|
+ <el-row
|
|
|
+ :gutter="10"
|
|
|
+ class="basic"
|
|
|
+ type="flex"
|
|
|
+ style="flex-wrap: wrap"
|
|
|
+ v-for="(el, index) in fieldList"
|
|
|
+ :key="index"
|
|
|
+ >
|
|
|
<el-col
|
|
|
- :xs="12"
|
|
|
- :sm="12"
|
|
|
- :md="12"
|
|
|
- :lg="8"
|
|
|
+ :xs="6"
|
|
|
+ :sm="6"
|
|
|
+ :md="6"
|
|
|
+ :lg="6"
|
|
|
:xl="6"
|
|
|
- v-for="item in fieldList"
|
|
|
+ v-for="item in el"
|
|
|
:key="item.prop"
|
|
|
>
|
|
|
<el-form-item :label="item.label">
|
|
|
<!-- <div class="item_label">{{ current[item.prop] }}</div> -->
|
|
|
- <el-input :value="fieldValue(item.prop)" disabled />
|
|
|
+ <el-input :value="fieldValue(item.prop)" readonly />
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</el-row>
|
|
|
<el-row :gutter="10">
|
|
|
- <el-col :xs="12" :sm="12" :md="12" :lg="8" :xl="6">
|
|
|
+ <el-col :xs="6" :sm="6" :md="6" :lg="6" :xl="6">
|
|
|
<el-form-item label="所属工厂:">
|
|
|
- <el-input v-model="form.factoryName" :disabled="true"> </el-input>
|
|
|
+ <el-input v-model="form.factoryName" :readonly="true"> </el-input>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :xs="12" :sm="12" :md="12" :lg="8" :xl="6">
|
|
|
+ <el-col :xs="6" :sm="6" :md="6" :lg="6" :xl="6">
|
|
|
<el-form-item label="所属工作中心:">
|
|
|
<el-select
|
|
|
style="width: 100%"
|
|
|
@@ -57,7 +63,7 @@
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
- <el-col :xs="12" :sm="12" :md="12" :lg="8" :xl="6">
|
|
|
+ <el-col :xs="6" :sm="6" :md="6" :lg="6" :xl="6">
|
|
|
<el-form-item label="所属班组:" required>
|
|
|
<el-select
|
|
|
style="width: 100%"
|
|
|
@@ -78,21 +84,19 @@
|
|
|
</el-row>
|
|
|
<el-row>
|
|
|
<el-form-item label="报工类型:" required>
|
|
|
- <el-radio-group v-model="form.singleReport">
|
|
|
+ <el-radio-group v-model="form.singleReport" disabled>
|
|
|
<!-- v-if="clientEnvironmentId != 2" -->
|
|
|
- <el-radio :label="1" :disabled="singleDis">单件报工</el-radio>
|
|
|
- <el-radio :label="0" :disabled="batchDis">批量报工</el-radio>
|
|
|
+ <el-radio :label="1">单件报工</el-radio>
|
|
|
+ <el-radio :label="0">批量报工</el-radio>
|
|
|
</el-radio-group>
|
|
|
</el-form-item>
|
|
|
</el-row>
|
|
|
<el-row>
|
|
|
<el-form-item label="派单方式:" prop="taskAss">
|
|
|
<!-- @change="changeDispatch" -->
|
|
|
- <el-radio-group v-model="form.taskAss">
|
|
|
- <el-radio :label="1" :disabled="orderDis">生产订单派单</el-radio>
|
|
|
- <el-radio :label="0" :disabled="procTaskDis"
|
|
|
- >工序任务派单</el-radio
|
|
|
- >
|
|
|
+ <el-radio-group v-model="form.taskAss" disabled>
|
|
|
+ <el-radio :label="1">生产订单派单</el-radio>
|
|
|
+ <el-radio :label="0">工序任务派单</el-radio>
|
|
|
</el-radio-group>
|
|
|
</el-form-item>
|
|
|
</el-row>
|
|
|
@@ -117,6 +121,7 @@
|
|
|
placeholder="请选择工位"
|
|
|
size="mini"
|
|
|
multiple
|
|
|
+ disabled
|
|
|
filterable
|
|
|
>
|
|
|
<el-option
|
|
|
@@ -137,6 +142,7 @@
|
|
|
size="mini"
|
|
|
filterable
|
|
|
multiple
|
|
|
+ disabled
|
|
|
>
|
|
|
<el-option
|
|
|
v-for="item in crewList"
|
|
|
@@ -156,6 +162,7 @@
|
|
|
size="mini"
|
|
|
filterable
|
|
|
multiple
|
|
|
+ disabled
|
|
|
>
|
|
|
<el-option
|
|
|
v-for="item in productionList"
|
|
|
@@ -194,7 +201,7 @@
|
|
|
row-key="id"
|
|
|
>
|
|
|
<template v-slot:toolbar>
|
|
|
- <el-button
|
|
|
+ <!-- <el-button
|
|
|
type="primary"
|
|
|
@click="dispatch(item, 1)"
|
|
|
:loading="toolbarLoading"
|
|
|
@@ -214,9 +221,9 @@
|
|
|
:loading="toolbarLoading"
|
|
|
>
|
|
|
保存
|
|
|
- </el-button>
|
|
|
+ </el-button> -->
|
|
|
|
|
|
- <div style="margin-left: 50px; display: inline-block">
|
|
|
+ <div style="display: inline-block">
|
|
|
<span
|
|
|
class="text"
|
|
|
style="
|
|
|
@@ -258,7 +265,7 @@
|
|
|
</template>
|
|
|
<template v-slot:quantity="{ row }">
|
|
|
<el-input
|
|
|
- :disabled="permissions(row)"
|
|
|
+ :readonly="permissions(row)"
|
|
|
type="number"
|
|
|
v-model="row.quantity"
|
|
|
placeholder="请输入数量"
|
|
|
@@ -267,7 +274,7 @@
|
|
|
</template>
|
|
|
<template v-slot:weight="{ row }">
|
|
|
<el-input
|
|
|
- :disabled="permissions(row)"
|
|
|
+ :readonly="permissions(row)"
|
|
|
type="number"
|
|
|
v-model="row.weight"
|
|
|
placeholder="请输入重量"
|
|
|
@@ -293,7 +300,7 @@
|
|
|
</template>
|
|
|
<template v-slot:startTime="{ row }">
|
|
|
<el-date-picker
|
|
|
- :disabled="permissions(row)"
|
|
|
+ :readonly="permissions(row)"
|
|
|
class="w100"
|
|
|
v-model="row.startTime"
|
|
|
type="datetime"
|
|
|
@@ -304,7 +311,7 @@
|
|
|
</template>
|
|
|
<template v-slot:endTime="{ row }">
|
|
|
<el-date-picker
|
|
|
- :disabled="permissions(row)"
|
|
|
+ :readonly="permissions(row)"
|
|
|
class="w100"
|
|
|
v-model="row.endTime"
|
|
|
type="datetime"
|
|
|
@@ -315,7 +322,7 @@
|
|
|
</template>
|
|
|
|
|
|
<template v-slot:action="{ row }">
|
|
|
- <!-- :disabled="resetBtnDis(row)" -->
|
|
|
+ <!-- :readonly="resetBtnDis(row)" -->
|
|
|
<el-popconfirm
|
|
|
title="确定要重置该条数据吗?"
|
|
|
@confirm="resetData(row, item)"
|
|
|
@@ -333,10 +340,7 @@
|
|
|
</div>
|
|
|
|
|
|
<div slot="footer">
|
|
|
- <el-button plain @click="cancel">取消</el-button>
|
|
|
- <el-button type="primary" @click="confirm" :loading="toolbarLoading"
|
|
|
- >确定</el-button
|
|
|
- >
|
|
|
+ <el-button plain @click="cancelDetails">取消</el-button>
|
|
|
</div>
|
|
|
</ele-modal>
|
|
|
</template>
|
|
|
@@ -384,19 +388,36 @@
|
|
|
procTaskDis: false, // 工序任务派单选择
|
|
|
firstTaskindex: '', // 首工序id 对应的工序列表数据下标
|
|
|
fieldList: [
|
|
|
- { label: '生产订单号:', prop: 'code' },
|
|
|
- { label: '计划编号:', prop: 'productionPlanCode' },
|
|
|
- { label: '工艺路线:', prop: 'produceRoutingName' },
|
|
|
- // { label: '编码', prop: 'productCode' },
|
|
|
- { label: '名称:', prop: 'productName' },
|
|
|
- { label: '生产编号:', prop: 'productionCodes' },
|
|
|
- { label: '牌号:', prop: 'brandNo' },
|
|
|
- { label: '批次号:', prop: 'batchNo' },
|
|
|
- { label: '型号:', prop: 'model' },
|
|
|
- { label: '要求生产数量:', prop: 'formingNum' },
|
|
|
- { label: '要求生产重量:', prop: 'initialWeight' },
|
|
|
- { label: '计划开始时间:', prop: 'planStartTime' },
|
|
|
- { label: '计划结束时间:', prop: 'planCompleteTime' }
|
|
|
+ [
|
|
|
+ { label: '生产订单号:', prop: 'code' },
|
|
|
+ { label: '计划编号:', prop: 'productionPlanCode' },
|
|
|
+ { label: '工艺路线:', prop: 'produceRoutingName' },
|
|
|
+ { label: '名称:', prop: 'productName' }
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ { label: '生产编号:', prop: 'productionCodes' },
|
|
|
+ { label: '牌号:', prop: 'brandNo' },
|
|
|
+ { label: '批次号:', prop: 'batchNo' },
|
|
|
+ { label: '型号:', prop: 'model' }
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ { label: '要求生产数量:', prop: 'formingNum' },
|
|
|
+ { label: '要求生产重量:', prop: 'initialWeight' },
|
|
|
+ { label: '计划开始时间:', prop: 'planStartTime' },
|
|
|
+ { label: '计划结束时间:', prop: 'planCompleteTime' }
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ { label: 'BOM版本:', prop: 'bomCategoryName' },
|
|
|
+ { label: 'BOM类型:', prop: 'produceType' },
|
|
|
+ { label: '首工序:', prop: 'firstTaskName' },
|
|
|
+ { label: '创建时间:', prop: 'createTime' }
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ { label: '机型:', prop: 'modelKey' },
|
|
|
+ { label: '颜色:', prop: 'colorKey' },
|
|
|
+ { label: '派单人:', prop: 'dispatcher' },
|
|
|
+ { label: '派单时间:', prop: 'dispatchTime' }
|
|
|
+ ]
|
|
|
],
|
|
|
shiftList: [],
|
|
|
dateValue: '',
|
|
|
@@ -410,7 +431,22 @@
|
|
|
computed: {
|
|
|
fieldValue() {
|
|
|
return (field) => {
|
|
|
- return this.current[field];
|
|
|
+ let value = this.current[field];
|
|
|
+ if (field == 'modelKey' || field == 'colorKey') {
|
|
|
+ return value.toString();
|
|
|
+ }
|
|
|
+ if (field == 'produceType') {
|
|
|
+ if (value == 1) {
|
|
|
+ return 'PBOM';
|
|
|
+ }
|
|
|
+ if (value == 2) {
|
|
|
+ return 'MBOM';
|
|
|
+ }
|
|
|
+ if (value == 3) {
|
|
|
+ return 'ABOM';
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return value || '';
|
|
|
};
|
|
|
},
|
|
|
clientEnvironmentId() {
|
|
|
@@ -423,7 +459,7 @@
|
|
|
// if(this.form.taskAss == 1){
|
|
|
// return '1000px'
|
|
|
// }
|
|
|
- return '75vw';
|
|
|
+ return '85vw';
|
|
|
},
|
|
|
// 重置按钮 的置灰权限 没有进行操作跟派单的数据 置灰
|
|
|
resetBtnDis() {
|
|
|
@@ -444,8 +480,9 @@
|
|
|
// 列表输入框操作 已派单的不能操作
|
|
|
permissions() {
|
|
|
return (row) => {
|
|
|
- if (!row.status) return false;
|
|
|
- if (row.status.code == 1) return true;
|
|
|
+ // if (!row.status) return false;
|
|
|
+ // if (row.status.code == 1) return true;
|
|
|
+ return true;
|
|
|
};
|
|
|
},
|
|
|
// 时间段显示
|
|
|
@@ -467,14 +504,14 @@
|
|
|
align: 'center',
|
|
|
fixed: 'left'
|
|
|
},
|
|
|
- {
|
|
|
- width: 45,
|
|
|
- type: 'selection',
|
|
|
- columnKey: 'selection',
|
|
|
- align: 'center',
|
|
|
- fixed: 'left',
|
|
|
- reserveSelection: true
|
|
|
- },
|
|
|
+ // {
|
|
|
+ // width: 45,
|
|
|
+ // type: 'selection',
|
|
|
+ // columnKey: 'selection',
|
|
|
+ // align: 'center',
|
|
|
+ // fixed: 'left',
|
|
|
+ // reserveSelection: true
|
|
|
+ // },
|
|
|
{
|
|
|
prop: 'name',
|
|
|
label: this.dynamicName,
|
|
|
@@ -580,6 +617,10 @@
|
|
|
res.value == '0' ? 0 : res.value == '1' ? 1 : 2;
|
|
|
}
|
|
|
});
|
|
|
+ },
|
|
|
+
|
|
|
+ cancelDetails() {
|
|
|
+ this.$emit('update:detailsVisible', false);
|
|
|
}
|
|
|
}
|
|
|
};
|
|
|
@@ -602,11 +643,11 @@
|
|
|
margin-top: 20px;
|
|
|
}
|
|
|
|
|
|
- ::v-deep .el-radio-button__orig-radio:checked + .el-radio-button__inner {
|
|
|
- background-color: #10d070;
|
|
|
- border-color: #10d070;
|
|
|
- }
|
|
|
::v-deep .el-radio-button__orig-radio:checked + .el-radio-button__inner {
|
|
|
box-shadow: none;
|
|
|
}
|
|
|
+
|
|
|
+ ::v-deep .el-input.is-disabled .el-input__inner {
|
|
|
+ color: #ab7777;
|
|
|
+ }
|
|
|
</style>
|