review(mes):work-order 的代码实现,功能测试
parent
3463213cd4
commit
38405b1d20
|
|
@ -9,8 +9,8 @@
|
|||
</el-row>
|
||||
<!-- BOM 列表 -->
|
||||
<el-table v-loading="loading" :data="bomList" :stripe="true" :show-overflow-tooltip="true">
|
||||
<el-table-column label="物料编码" align="center" prop="itemCode" width="120" />
|
||||
<el-table-column label="物料名称" align="center" prop="itemName" min-width="150" />
|
||||
<el-table-column label="BOM 物料编码" align="center" prop="itemCode" width="120" />
|
||||
<el-table-column label="BOM 物料名称" align="center" prop="itemName" min-width="150" />
|
||||
<el-table-column label="规格型号" align="center" prop="itemSpec" width="120" />
|
||||
<el-table-column label="单位" align="center" prop="unitMeasureName" width="80" />
|
||||
<!-- TODO @AI:物料/名称,增加该类; -->
|
||||
|
|
@ -20,6 +20,7 @@
|
|||
<template #default="scope">
|
||||
<el-button link type="primary" @click="openBomForm('update', scope.row)">编辑</el-button>
|
||||
<el-button link type="danger" @click="handleDeleteBom(scope.row.id)">删除</el-button>
|
||||
<!-- TODO @AI:生成订单 -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@
|
|||
>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<!-- TODO @AI:生成 -->
|
||||
<el-form-item label="工单编码" prop="code">
|
||||
<el-input v-model="formData.code" placeholder="请输入工单编码" :disabled="isDetail" />
|
||||
</el-form-item>
|
||||
|
|
@ -38,6 +39,7 @@
|
|||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<!-- TODO @AI:应该只有【客户订单】时,才展示这个表单项。 -->
|
||||
<el-col :span="8">
|
||||
<el-form-item label="来源单据编号" prop="orderSourceCode">
|
||||
<el-input
|
||||
|
|
@ -47,9 +49,27 @@
|
|||
/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="工单类型" prop="type">
|
||||
<el-select
|
||||
v-model="formData.type"
|
||||
placeholder="请选择工单类型"
|
||||
class="!w-1/1"
|
||||
:disabled="isDetail"
|
||||
>
|
||||
<el-option
|
||||
v-for="dict in getIntDictOptions(DICT_TYPE.MES_PRO_WORK_ORDER_TYPE)"
|
||||
:key="dict.value"
|
||||
:label="dict.label"
|
||||
:value="dict.value"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<!-- TODO @AI:应该是 ItemSelect -->
|
||||
<el-form-item label="产品" prop="productId">
|
||||
<el-select
|
||||
v-model="formData.productId"
|
||||
|
|
@ -68,6 +88,8 @@
|
|||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<!-- TODO @AI:这里 disabled 展示:产品名称、规格类型、单位; -->
|
||||
<!-- TODO @AI:这个字段“单位”,应该不用存储,通过 item 查询就好了; -->
|
||||
<el-col :span="8">
|
||||
<el-form-item label="单位" prop="unitMeasureId">
|
||||
<el-select
|
||||
|
|
@ -87,6 +109,7 @@
|
|||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<!-- TODO @ai:工单数量; -->
|
||||
<el-form-item label="生产数量" prop="quantity">
|
||||
<el-input-number
|
||||
v-model="formData.quantity"
|
||||
|
|
@ -100,6 +123,7 @@
|
|||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<!-- TODO @AI:这个需要搞个客户的 select 弹出;类似 itemselect 这种; -->
|
||||
<el-form-item label="客户" prop="clientId">
|
||||
<el-select
|
||||
v-model="formData.clientId"
|
||||
|
|
@ -117,8 +141,10 @@
|
|||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- TODO @AI:展示客户编码、客户名称; -->
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<!-- TODO @AI:只有外协、外购,才有供应商 -->
|
||||
<el-form-item label="供应商" prop="vendorId">
|
||||
<el-select
|
||||
v-model="formData.vendorId"
|
||||
|
|
@ -136,8 +162,10 @@
|
|||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- TODO @AI:展示供应商编码、供应商名称; -->
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<!-- TODO @AI:这个字段,是必须的么?在调研确认下; -->
|
||||
<el-form-item label="批次号" prop="batchCode">
|
||||
<el-input
|
||||
v-model="formData.batchCode"
|
||||
|
|
@ -184,6 +212,7 @@
|
|||
<el-tab-pane label="工单 BOM" name="bom">
|
||||
<WorkOrderBom v-if="formData.id" :work-order-id="formData.id" :disabled="isDetail" />
|
||||
</el-tab-pane>
|
||||
<!-- TODO @AI:物料需求,是不是缺的? -->
|
||||
</el-tabs>
|
||||
<template #footer v-if="!isDetail">
|
||||
<el-button @click="submitForm" type="primary" :disabled="formLoading">确 定</el-button>
|
||||
|
|
|
|||
|
|
@ -2,6 +2,8 @@
|
|||
<template>
|
||||
<ContentWrap>
|
||||
<!-- 搜索工作栏 -->
|
||||
<!-- TODO @AI:产品编号、产品名称 -->
|
||||
<!-- TODO @AI:客户编号、客户名称 -->
|
||||
<el-form
|
||||
class="-mb-15px"
|
||||
:model="queryParams"
|
||||
|
|
@ -28,7 +30,12 @@
|
|||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="工单类型" prop="type">
|
||||
<el-select v-model="queryParams.type" placeholder="请选择工单类型" clearable class="!w-240px">
|
||||
<el-select
|
||||
v-model="queryParams.type"
|
||||
placeholder="请选择工单类型"
|
||||
clearable
|
||||
class="!w-240px"
|
||||
>
|
||||
<el-option
|
||||
v-for="dict in getIntDictOptions(DICT_TYPE.MES_PRO_WORK_ORDER_TYPE)"
|
||||
:key="dict.value"
|
||||
|
|
@ -37,6 +44,7 @@
|
|||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<!-- TODO @AI:来源类型 改成 工单来源 -->
|
||||
<el-form-item label="来源类型" prop="orderSourceType">
|
||||
<el-select
|
||||
v-model="queryParams.orderSourceType"
|
||||
|
|
@ -104,6 +112,7 @@
|
|||
|
||||
<!-- 列表 -->
|
||||
<ContentWrap>
|
||||
<!-- TODO @AI:生产工单,是父子结构; -->
|
||||
<el-table v-loading="loading" :data="list" :stripe="true" :show-overflow-tooltip="true">
|
||||
<el-table-column label="工单编码" align="center" prop="code" width="140" />
|
||||
<el-table-column label="工单名称" align="center" prop="name" min-width="150" />
|
||||
|
|
@ -120,14 +129,24 @@
|
|||
/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="产品名称" align="center" prop="productName" min-width="120" />
|
||||
<!-- TODO @AI:订单编号 -->
|
||||
<el-table-column label="产品编码" align="center" prop="productCode" width="120" />
|
||||
<el-table-column label="产品名称" align="center" prop="productName" min-width="120" />
|
||||
<el-table-column label="规格型号" align="center" prop="productSpec" width="120" />
|
||||
<el-table-column label="单位" align="center" prop="unitMeasureName" width="80" />
|
||||
<el-table-column label="生产数量" align="center" prop="quantity" width="100" />
|
||||
<el-table-column label="已生产" align="center" prop="quantityProduced" width="80" />
|
||||
<el-table-column label="工单数量" align="center" prop="quantity" width="100" />
|
||||
<el-table-column label="已生产数量" align="center" prop="quantityProduced" width="80" />
|
||||
<!-- TODO @AI:客户编码 -->
|
||||
<!-- TODO @AI:客户名称 -->
|
||||
<el-table-column label="客户" align="center" prop="clientName" width="120" />
|
||||
<el-table-column label="需求日期" align="center" prop="requestDate" :formatter="dateFormatter" width="180" />
|
||||
<el-table-column
|
||||
label="需求日期"
|
||||
align="center"
|
||||
prop="requestDate"
|
||||
:formatter="dateFormatter"
|
||||
width="180"
|
||||
/>
|
||||
<!-- TODO @AI:单据状态 -->
|
||||
<el-table-column label="工单状态" align="center" prop="status" width="100">
|
||||
<template #default="scope">
|
||||
<dict-tag :type="DICT_TYPE.MES_PRO_WORK_ORDER_STATUS" :value="scope.row.status" />
|
||||
|
|
@ -142,6 +161,7 @@
|
|||
/>
|
||||
<el-table-column label="操作" align="center" width="200" fixed="right">
|
||||
<template #default="scope">
|
||||
<!-- TODO @AI:新增、完成、取消、预览 -->
|
||||
<!-- 草稿状态:编辑、删除 -->
|
||||
<template v-if="scope.row.status === MesProWorkOrderStatusEnum.PREPARE">
|
||||
<el-button
|
||||
|
|
|
|||
Loading…
Reference in New Issue