Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
P
pda-ui
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
pda
pda-ui
Commits
c0268649
Commit
c0268649
authored
Jan 24, 2024
by
赵汉亭
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
任务单--未完成版
parent
ed46a900
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
692 additions
and
270 deletions
+692
-270
protask.js
src/api/mes/pro/protask.js
+8
-0
single.vue
src/components/workunitSelect/single.vue
+198
-0
index.vue
src/views/mes/pro/schedule/index.vue
+469
-254
ProogingBom.vue
src/views/mes/proofing/components/ProogingBom.vue
+2
-1
proofingInfo.vue
src/views/mes/proofing/proofingInfo.vue
+15
-15
No files found.
src/api/mes/pro/protask.js
View file @
c0268649
...
...
@@ -52,3 +52,11 @@ export function delProtask(taskId) {
method
:
'delete'
})
}
// 生成任务单、合并任务单
export
function
addProtaskList
(
taskId
)
{
return
request
({
url
:
'/mes/pro/protask'
+
taskId
,
method
:
'post'
,
})
}
src/components/workunitSelect/single.vue
0 → 100644
View file @
c0268649
<
template
>
<el-dialog
title=
"工作单元选择"
v-if=
"showFlag"
:visible
.
sync=
"showFlag"
:modal=
false
width=
"80%"
center
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<el-form-item
label=
"工作单元编码"
prop=
"workunitCode"
>
<el-input
v-model=
"queryParams.workunitCode"
placeholder=
"请输入工单编码"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"工作单元名称"
prop=
"workunitName"
>
<el-input
v-model=
"queryParams.workunitName"
placeholder=
"请输入工作单元名称"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"工作站"
prop=
"workstationName"
>
<el-input
v-model=
"queryParams.workstationName"
placeholder=
"请输入工作站名称"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
icon=
"el-icon-search"
size=
"mini"
@
click=
"handleQuery"
>
搜索
</el-button>
<el-button
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"resetQuery"
>
重置
</el-button>
</el-form-item>
</el-form>
<el-table
v-loading=
"loading"
:data=
"workorderList"
@
current-change=
"handleCurrent"
@
row-dblclick=
"handleRowDbClick"
>
<el-table-column
width=
"55"
align=
"center"
>
<template
v-slot=
"scope"
>
<el-radio
v-model=
"selectedWorkorderId"
:label=
"scope.row.workorderId"
@
change=
"handleRowChange(scope.row)"
>
{{
""
}}
</el-radio>
</
template
>
</el-table-column>
<el-table-column
label=
"工单编码"
width=
"180"
prop=
"workorderCode"
>
</el-table-column>
<el-table-column
label=
"工单名称"
width=
"200"
align=
"center"
prop=
"workorderName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"工单来源"
align=
"center"
prop=
"orderSource"
>
<
template
slot-scope=
"scope"
>
<dict-tag
:options=
"dict.type.mes_workorder_sourcetype"
:value=
"scope.row.orderSource"
/>
</
template
>
</el-table-column>
<el-table-column
label=
"订单编号"
width=
"140"
align=
"center"
prop=
"sourceCode"
/>
<el-table-column
label=
"产品编号"
width=
"120"
align=
"center"
prop=
"productCode"
/>
<el-table-column
label=
"产品名称"
width=
"200"
align=
"center"
prop=
"productName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"规格型号"
align=
"center"
prop=
"productSpc"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"单位"
align=
"center"
prop=
"unitOfMeasure"
/>
<el-table-column
label=
"工单数量"
align=
"center"
prop=
"quantity"
/>
<el-table-column
label=
"客户编码"
align=
"center"
prop=
"clientCode"
/>
<el-table-column
label=
"客户名称"
align=
"center"
prop=
"clientName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"需求日期"
align=
"center"
prop=
"requestDate"
width=
"180"
>
<
template
slot-scope=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
requestDate
,
'{y
}
-{m
}
-{d
}
'
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<
/el-table
>
<
pagination
v
-
show
=
"total>0"
:
total
=
"total"
:
page
.
sync
=
"queryParams.pageNum"
:
limit
.
sync
=
"queryParams.pageSize"
@
pagination
=
"getList"
/>
<
div
slot
=
"footer"
class
=
"dialog-footer"
>
<
el
-
button
type
=
"primary"
@
click
=
"confirmSelect"
>
确
定
<
/el-button
>
<
el
-
button
@
click
=
"showFlag=false"
>
取
消
<
/el-button
>
<
/div
>
<
/el-dialog
>
<
/template
>
<
script
>
import
{
listWorkorder
}
from
"@/api/mes/pro/workunit"
;
export
default
{
name
:
'WorkOrderSelectSingle'
,
components
:
{
}
,
dicts
:
[
'mes_order_status'
,
'mes_workorder_sourcetype'
],
props
:{
workunit
:
{
type
:
Object
,
default
:
function
(){
return
{
'workorderType'
:
'SELF'
}
}}
//外部传入的工单过滤信息
}
,
data
()
{
return
{
showFlag
:
false
,
// 遮罩层
loading
:
true
,
// 选中数组
selectedWorkorderId
:
undefined
,
selectedRows
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 生产工单表格数据
workorderList
:
[],
// 弹出层标题
title
:
""
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
workorderCode
:
null
,
workorderName
:
null
,
workorderType
:
this
.
workunit
.
workunitType
,
orderSource
:
null
,
sourceCode
:
null
,
productId
:
null
,
productCode
:
null
,
productName
:
null
,
productSpc
:
null
,
unitOfMeasure
:
null
,
quantity
:
null
,
quantityProduced
:
null
,
quantityChanged
:
null
,
quantityScheduled
:
null
,
clientId
:
null
,
clientCode
:
null
,
clientName
:
null
,
requestDate
:
null
,
parentId
:
null
,
ancestors
:
null
,
status
:
'CONFIRMED'
,
}
,
}
}
,
created
()
{
this
.
getList
();
}
,
methods
:{
/** 查询生产工单列表 */
getList
()
{
this
.
loading
=
true
;
listWorkorder
(
this
.
queryParams
).
then
(
response
=>
{
this
.
workorderList
=
response
.
rows
;
this
.
loading
=
false
;
}
);
}
,
/** 搜索按钮操作 */
handleQuery
()
{
this
.
getList
();
}
,
/** 重置按钮操作 */
resetQuery
()
{
this
.
resetForm
(
"queryForm"
);
this
.
handleQuery
();
}
,
handleCurrent
(
row
){
if
(
row
){
this
.
selectedRows
=
row
;
}
}
,
// 单选选中数据
handleRowChange
(
row
)
{
if
(
row
){
this
.
selectedRows
=
row
;
}
}
,
//双击选中
handleRowDbClick
(
row
){
if
(
row
){
this
.
selectedRows
=
row
;
this
.
$emit
(
'onSelected'
,
this
.
selectedRows
);
this
.
showFlag
=
false
;
}
}
,
//确定选中
confirmSelect
(){
if
(
this
.
selectedWorkorderId
==
null
||
this
.
selectedWorkorderId
==
0
){
this
.
$notify
({
title
:
'提示'
,
type
:
'warning'
,
message
:
'请至少选择一条数据!'
}
);
return
;
}
this
.
$emit
(
'onSelected'
,
this
.
selectedRows
);
this
.
showFlag
=
false
;
}
}
}
<
/script>
\ No newline at end of file
src/views/mes/pro/schedule/index.vue
View file @
c0268649
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<el-form-item
label=
"工单编码"
prop=
"workorderCode"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
label-width=
"68px"
>
<el-form-item
prop=
"taskCode"
>
<el-input
v-model=
"queryParams.
workorder
Code"
placeholder=
"请输入
工
单编码"
v-model=
"queryParams.
task
Code"
placeholder=
"请输入
任务
单编码"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
<template
slot=
"label"
>
<TipLabel
title=
"编码"
tip=
"任务单编码"
/>
</
template
>
</el-form-item>
<el-form-item
label=
"工单名称"
prop=
"workorder
Name"
>
<el-form-item
prop=
"task
Name"
>
<el-input
v-model=
"queryParams.
workorder
Name"
placeholder=
"请输入
工
单名称"
v-model=
"queryParams.
task
Name"
placeholder=
"请输入
任务
单名称"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
<
template
slot=
"label"
>
<TipLabel
title=
"名称"
tip=
"任务单名称"
/>
</
template
>
</el-form-item>
<el-form-item
label=
"来源单据"
prop=
"sourceCod
e"
>
<el-form-item
prop=
"workstationNam
e"
>
<el-input
v-model=
"queryParams.
sourceCod
e"
placeholder=
"请输入
来源单据
"
v-model=
"queryParams.
workstationNam
e"
placeholder=
"请输入
工作站名称
"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
<
template
slot=
"label"
>
<TipLabel
title=
"工作站"
tip=
"工作站名称"
/>
</
template
>
</el-form-item>
<el-form-item
label=
"产品编号"
prop=
"
product
Code"
>
<el-form-item
label=
"产品编号"
prop=
"
item
Code"
>
<el-input
v-model=
"queryParams.
product
Code"
v-model=
"queryParams.
item
Code"
placeholder=
"请输入产品编号"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"产品名称"
prop=
"
product
Name"
>
<el-form-item
label=
"产品名称"
prop=
"
item
Name"
>
<el-input
v-model=
"queryParams.
product
Name"
v-model=
"queryParams.
item
Name"
placeholder=
"请输入产品名称"
clearable
@
keyup
.
enter
.
native=
"handleQuery"
/>
</el-form-item>
<el-form-item
label=
"客户编码"
prop=
"clientCode"
>
<
!-- <
el-form-item label="客户编码" prop="clientCode">
<el-input
v-model="queryParams.clientCode"
placeholder="请输入客户编码"
...
...
@@ -60,86 +76,202 @@
/>
</el-form-item>
<el-form-item label="需求日期" prop="requestDate">
<el-date-picker
clearable
<el-date-picker
clearable
v-model="queryParams.requestDate"
type="date"
value-format="yyyy-MM-dd"
placeholder=
"请选择需求日期"
>
placeholder="请选择需求日期"
>
</el-date-picker>
</el-form-item>
</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"
>
搜索
</el-button
>
<el-button
icon=
"el-icon-refresh"
size=
"mini"
@
click=
"resetQuery"
>
重置
</el-button
>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
icon=
"el-icon-refresh"
v-hasPermi=
"['mes:pro:protask:list']"
circle=
""
@
click=
"getList"
></el-button>
<el-button
type=
"primary"
icon=
"el-icon-edit"
v-hasPermi=
"['mes:pro:protask:edit']"
circle=
""
@
click=
"handleOpenGantt"
></el-button>
<el-button
type=
"primary"
icon=
"el-icon-refresh"
v-hasPermi=
"['mes:pro:protask:list']"
circle=
""
@
click=
"getList"
></el-button>
<el-button
type=
"primary"
icon=
"el-icon-edit"
v-hasPermi=
"['mes:pro:protask:edit']"
circle=
""
@
click=
"handleOpenGantt"
></el-button>
</el-form-item>
</el-form>
<div
class=
"wrapper"
>
<div
class=
"container"
>
<GanttChar
class=
"left-container"
ref=
"ganttChar"
:tasks=
"tasks"
></GanttChar>
<GanttChar
class=
"left-container"
ref=
"ganttChar"
:tasks=
"tasks"
></GanttChar>
</div>
</div>
<el-table
v-loading=
"loading"
:data=
"
workorder
List"
row-key=
"
workorder
Id"
:data=
"
task
List"
row-key=
"
task
Id"
default-expand-all
:tree-props=
"
{
children: 'children', hasChildren: 'hasChildren'
}"
:tree-props=
"{
children: 'children', hasChildren: 'hasChildren'
}"
>
<el-table-column
label=
"
工单编码"
width=
"180"
prop=
"workorderCode"
>
<el-table-column
label=
"
任务单编码"
width=
"120"
prop=
"taskCode"
>
<
template
slot-scope=
"scope"
>
<el-button
size=
"mini"
type=
"text"
@
click=
"handleView(scope.row)"
v-hasPermi=
"['mes:pro:protask:query']"
>
{{
scope
.
row
.
workorderCode
}}
</el-button>
>
{{
scope
.
row
.
taskCode
}}
</el-button
>
</
template
>
</el-table-column>
<el-table-column
label=
"工单名称"
width=
"200"
align=
"center"
prop=
"workorderName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"工单来源"
align=
"center"
prop=
"orderSource"
>
<el-table-column
label=
"任务单名称"
width=
"200"
align=
"center"
prop=
"taskName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"工作站名称"
align=
"center"
prop=
"workstationName"
width=
"180"
/>
<el-table-column
label=
"工艺名称"
width=
"140"
align=
"center"
prop=
"routeName"
/>
<el-table-column
label=
"工序名称"
align=
"center"
prop=
"processName"
:show-overflow-tooltip=
"true"
/>
<!-- <el-table-column
label="产品编号"
width="120"
align="center"
prop="itemCode"
/> -->
<el-table-column
label=
"产品名称"
width=
"180"
align=
"center"
prop=
"itemName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"规格型号"
align=
"center"
prop=
"specification"
/>
<el-table-column
label=
"单位"
align=
"center"
prop=
"unitOfMeasure"
/>
<el-table-column
label=
"排产数量"
align=
"center"
prop=
"quantity"
/>
<!-- <el-table-column
label="已生产数量"
align="center"
width="100px"
prop="quantityProduced"
/>
<el-table-column
label="合格品数量"
align="center"
prop="quantityQuanlify"
width="100"
/>
<el-table-column
label="不良品数量"
align="center"
width="100px"
prop="quantityUnquanlify"
/>
<el-table-column label="调整数量" align="center" prop="quantityChanged" /> -->
<el-table-column
label=
"开始生产时间"
align=
"center"
prop=
"startTime"
width=
"180"
:show-overflow-tooltip=
"true"
>
<
template
slot-scope=
"scope"
>
<dict-tag
:options=
"dict.type.mes_workorder_sourcetype"
:value=
"scope.row.orderSource"
/>
<span>
{{
parseTime
(
scope
.
row
.
startTime
,
"{y
}
-{m
}
-{d
}
:{h
}
-{m
}
-{s
}
"
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<el-table-column
label=
"订单编号"
width=
"140"
align=
"center"
prop=
"sourceCode"
/>
<el-table-column
label=
"产品编号"
width=
"120"
align=
"center"
prop=
"productCode"
/>
<el-table-column
label=
"产品名称"
width=
"200"
align=
"center"
prop=
"productName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"规格型号"
align=
"center"
prop=
"productSpc"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"单位"
align=
"center"
prop=
"unitOfMeasure"
/>
<el-table-column
label=
"工单数量"
align=
"center"
prop=
"quantity"
/>
<el-table-column
label=
"调整数量"
align=
"center"
prop=
"quantityChanged"
/>
<el-table-column
label=
"已生产数量"
align=
"center"
width=
"100px"
prop=
"quantityProduced"
/>
<el-table-column
label=
"客户编码"
align=
"center"
prop=
"clientCode"
/>
<el-table-column
label=
"客户名称"
align=
"center"
prop=
"clientName"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"需求日期"
align=
"center"
prop=
"requestDate"
width=
"180"
>
<
el
-
table
-
column
label
=
"生产时长"
align
=
"center"
prop
=
"duration"
width
=
"120"
>
<
/el-table-column
>
<
el
-
table
-
column
label
=
"完成生产时间"
align
=
"center"
prop
=
"endTime"
width
=
"180"
>
<
template
slot
-
scope
=
"scope"
>
<span>
{{
parseTime
(
scope
.
row
.
requestDate
,
'{y
}
-{m
}
-{d
}
'
)
}}
<
/span
>
<
span
>
{{
parseTime
(
scope
.
row
.
endTime
,
"{y
}
-{m
}
-{d
}
:{h
}
-{m
}
-{s
}
"
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<
el
-
table
-
column
label
=
"排产状态"
align
=
"center"
prop
=
"status"
>
<
el
-
table
-
column
label
=
"需求日期"
align
=
"center"
prop
=
"requestDate"
width
=
"180"
>
<
template
slot
-
scope
=
"scope"
>
<
dict
-
tag
:
options
=
"dict.type.mes_order_status"
:
value
=
"scope.row.status"
/
>
<
span
>
{{
parseTime
(
scope
.
row
.
requestDate
,
"{y
}
-{m
}
-{d
}
"
)
}}
<
/span
>
<
/template
>
<
/el-table-column
>
<
el
-
table
-
column
label
=
"操作"
width
=
"150px"
align
=
"center"
class
-
name
=
"small-padding fixed-width"
>
<
el
-
table
-
column
label
=
"生产状态"
align
=
"center"
prop
=
"status"
width
=
"120"
/>
<
el
-
table
-
column
label
=
"备注"
align
=
"center"
prop
=
"remark"
width
=
"120"
/>
<
el
-
table
-
column
label
=
"操作"
width
=
"150px"
align
=
"center"
class
-
name
=
"small-padding fixed-width"
>
<
template
slot
-
scope
=
"scope"
>
<
el
-
button
size
=
"mini"
type
=
"text"
icon
=
"el-icon-edit"
v
-
if
=
"scope.row.status ==
'CONFIRMED
'"
v
-
if
=
"scope.row.status ==
'NORMARL
'"
@
click
=
"handleUpdate(scope.row)"
v
-
hasPermi
=
"['mes:pro:protask:edit']"
>
排产
<
/el-button
>
>
排产
<
/el-butto
n
>
<
/template
>
<
/el-table-column
>
<
/el-table
>
<
pagination
v
-
show
=
"total
>
0"
v
-
show
=
"total
>
0"
:
total
=
"total"
:
page
.
sync
=
"queryParams.pageNum"
:
limit
.
sync
=
"queryParams.pageSize"
...
...
@@ -147,126 +279,135 @@
/>
<!--
添加或修改生产工单对话框
-->
<
el
-
dialog
:
title
=
"title"
:
visible
.
sync
=
"open"
width
=
"960px"
append
-
to
-
body
>
<
el
-
dialog
:
title
=
"title"
:
visible
.
sync
=
"open"
width
=
"1000px"
append
-
to
-
body
>
<
el
-
form
ref
=
"form"
:
model
=
"form"
label
-
width
=
"80px"
>
<
el
-
row
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"工单编号"
prop
=
"workorderCode"
>
<
el
-
input
v
-
model
=
"form.workorderCode"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"工单名称"
prop
=
"workorderName"
>
<
el
-
input
v
-
model
=
"form.workorderName"
readonly
=
"readonly"
/>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"编号"
prop
=
"taskCode"
>
<
el
-
input
v
-
model
=
"form.taskCode"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"来源类型"
prop
=
"orderSource"
>
<
el
-
radio
-
group
v
-
model
=
"form.orderSource"
disabled
>
<
el
-
radio
v
-
for
=
"dict in dict.type.mes_workorder_sourcetype"
:
key
=
"dict.value"
:
label
=
"dict.value"
>
{{
dict
.
label
}}
<
/el-radio
>
<
/el-radio-group>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"名称"
prop
=
"taskName"
>
<
el
-
input
v
-
model
=
"form.taskName"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
v
-
if
=
"form.orderSource == 'ORDER'
"
>
<
el
-
form
-
item
label
=
"
订单编号"
prop
=
"sourceCod
e"
>
<
el
-
input
v
-
model
=
"form.
sourceCod
e"
readonly
=
"readonly"
/>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12
"
>
<
el
-
form
-
item
label
=
"
产品名称"
prop
=
"itemNam
e"
>
<
el
-
input
v
-
model
=
"form.
itemNam
e"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"8"
>
<
el
-
form
-
item
label
=
"排产状态"
prop
=
"status"
>
<
el
-
select
v
-
model
=
"form.status"
disabled
>
<
el
-
option
v
-
for
=
"dict in dict.type.mes_order_status"
:
key
=
"dict.value"
:
label
=
"dict.label"
:
value
=
"dict.value"
><
/el-option
>
<
/el-select
>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"工序名称"
prop
=
"processName"
>
<
el
-
input
v
-
model
=
"form.processName"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"产品编号"
prop
=
"productCode"
>
<
el
-
input
v
-
model
=
"form.productCode"
readonly
=
"readonly"
>
<
/el-input
>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"工作站"
prop
=
"workstationName"
>
<
el
-
input
v
-
model
=
"form.workstationName"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"
产品名称"
prop
=
"productName
"
>
<
el
-
input
v
-
model
=
"form.
productName"
readonly
=
"readonly
"
/>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"
工作单元"
prop
=
"workunitId
"
>
<
el
-
input
v
-
model
=
"form.
workunitName
"
/>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"规格型号"
prop
=
"productSpc"
>
<
el
-
input
v
-
model
=
"form.productSpc"
readonly
=
"readonly"
/>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"排产数量"
prop
=
"quantity"
>
<
el
-
input
v
-
model
=
"form.quantity"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"单位"
prop
=
"unitOfMeasure"
>
<
el
-
input
v
-
model
=
"form.unitOfMeasure"
readonly
=
"readonly"
/>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"开始生产时间"
prop
=
"startTime"
>
<
el
-
date
-
picker
v
-
model
=
"form.startTime"
type
=
"date"
value
-
format
=
"yyyy-MM-dd:hh-mm-ss"
placeholder
=
"请选择开始时间"
>
<
/el-date-picker
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"工单数量"
prop
=
"quantity"
>
<
el
-
input
v
-
model
=
"form.quantity"
readonly
=
"readonly"
/>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"生产时长"
prop
=
"duration"
>
<
el
-
input
v
-
model
=
"form.duration"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"12"
>
<
el
-
col
:
lg
=
"6"
:
md
=
"8"
:
sm
=
"12"
:
xs
=
"12"
>
<
el
-
form
-
item
label
=
"需求日期"
prop
=
"requestDate"
>
<
el
-
date
-
picker
disabled
<
el
-
date
-
picker
v
-
model
=
"form.requestDate"
type
=
"date"
value
-
format
=
"yyyy-MM-dd"
placeholder
=
"请选择需求日期"
>
placeholder
=
"请选择需求日期"
>
<
/el-date-picker
>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
el
-
row
v
-
if
=
"form.orderSource == 'ORDER'"
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"客户编号"
prop
=
"clientCode"
>
<
el
-
input
v
-
model
=
"form.clientCode"
readonly
=
"readonly"
>
<
/el-input
>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
:
span
=
"12"
>
<
el
-
form
-
item
label
=
"客户名称"
prop
=
"clientName"
>
<
el
-
input
v
-
model
=
"form.clientName"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
el
-
col
><
/el-col
>
<
/el-row
>
<
el
-
row
>
<
el
-
col
:
span
=
"24"
>
<
el
-
form
-
item
label
=
"备注"
prop
=
"remark"
>
<
el
-
input
v
-
model
=
"form.remark"
type
=
"textarea"
readonly
=
"readonly"
/>
<
el
-
input
v
-
model
=
"form.remark"
type
=
"textarea"
readonly
=
"readonly"
/>
<
/el-form-item
>
<
/el-col
>
<
/el-row
>
<
/el-form
>
<
el
-
steps
:
active
=
"activeProcess"
v
-
if
=
"form.workorderId !=null"
align
-
center
simple
>
<
el
-
step
v
-
for
=
"(item,index) in processOptions"
:
title
=
"item.processName"
@
click
.
native
=
"handleStepClick(index)"
>
<
el
-
steps
:
active
=
"activeProcess"
v
-
if
=
"form.taskId != null"
align
-
center
simple
>
<
el
-
step
v
-
for
=
"(item, index) in processOptions"
:
title
=
"item.itemName"
:
key
=
"item.itemId"
@
click
.
native
=
"handleStepClick(index)"
>
<
/el-step
>
<
/el-steps
>
<
el
-
card
v
-
for
=
" (item,index) in processOptions "
:
key
=
"index"
v
-
if
=
"activeProcess == index && form.workorderId !=null"
>
<
ProTask
:
workorderId
=
"form.workorderId"
:
routeId
=
"item.routeId"
:
processId
=
"item.processId"
:
colorCode
=
"item.colorCode"
:
optType
=
"optType"
><
/ProTask
>
<
template
v
-
if
=
"activeProcess == index && form.taskId != null"
>
<
el
-
card
v
-
for
=
"(item, index) in processOptions"
:
key
=
"index"
>
<
ProTask
:
workorderId
=
"form.taskId"
:
routeId
=
"item.routeId"
:
processId
=
"item.itemId"
:
colorCode
=
"item.colorCode"
:
optType
=
"optType"
><
/ProTask
>
<
/el-card
>
<
/template
>
<
div
slot
=
"footer"
class
=
"dialog-footer"
>
<
el
-
button
type
=
"primary"
@
click
=
"cancel"
v
-
if
=
"optType =='view' || form.status !='PREPARE' "
>
返回
<
/el-button
>
<
el
-
button
type
=
"primary"
@
click
=
"submitForm"
v
-
if
=
"form.status =='PREPARE' && optType !='view' "
>
确
定
<
/el-button
>
<
el
-
button
type
=
"success"
@
click
=
"handleFinish"
v
-
if
=
"form.status =='PREPARE' && optType !='view' && form.workorderId !=null"
>
完成
<
/el-button
>
<
el
-
button
type
=
"primary"
@
click
=
"cancel"
v
-
if
=
"optType == 'view' || form.status != 'NORMARL'"
>
返回
<
/el-butto
n
>
<
el
-
button
type
=
"primary"
@
click
=
"submitForm"
v
-
if
=
"form.status == 'NORMARL' && optType != 'view'"
>
确
定
<
/el-butto
n
>
<
el
-
button
type
=
"success"
@
click
=
"handleFinish"
v
-
if
=
"
form.status == 'NORMARL' &&
optType != 'view' &&
form.workorderId != null
"
>
完成
<
/el-butto
n
>
<
el
-
button
@
click
=
"cancel"
>
取
消
<
/el-button
>
<
/div
>
<
/el-dialog
>
...
...
@@ -274,8 +415,22 @@
<
/template
>
<
script
>
import
{
listWorkorder
,
getWorkorder
,
delWorkorder
,
addWorkorder
,
updateWorkorder
}
from
"@/api/mes/pro/workorder"
;
import
{
listGanttTaskList
}
from
"@/api/mes/pro/protask"
;
import
{
listWorkorder
,
getWorkorder
,
delWorkorder
,
addWorkorder
,
updateWorkorder
,
}
from
"@/api/mes/pro/workorder"
;
import
{
listProtask
,
listGanttTaskList
,
getProtask
,
addProtask
,
updateProtask
,
delProtask
,
addProtaskList
,
}
from
"@/api/mes/pro/protask"
;
import
{
listProductprocess
}
from
"@/api/mes/pro/routeprocess"
;
import
ProTask
from
"./proTask.vue"
;
import
GanttChar
from
"./ganttx.vue"
;
...
...
@@ -284,16 +439,16 @@ import "@riophae/vue-treeselect/dist/vue-treeselect.css";
export
default
{
name
:
"Workorder"
,
dicts
:
[
'mes_order_status'
,
'mes_workorder_sourcetype'
],
dicts
:
[
"mes_order_status"
,
"mes_workorder_sourcetype"
],
components
:
{
Treeselect
,
ProTask
,
GanttChar
GanttChar
,
}
,
data
()
{
return
{
//自动生成编码
autoGenFlag
:
false
,
autoGenFlag
:
false
,
optType
:
undefined
,
activeProcess
:
0
,
// 遮罩层
...
...
@@ -306,10 +461,10 @@ export default {
single
:
true
,
// 非多个禁用
multiple
:
true
,
//
生产工
单表格数据
workorder
List
:
[],
//
生产
工单树选项
workorder
Options
:
[],
//
任务
单表格数据
task
List
:
[],
//
任务单
工单树选项
task
Options
:
[],
//当前生产工单中产品对应的工序列表
processOptions
:
[],
// 弹出层标题
...
...
@@ -322,29 +477,50 @@ export default {
pageSize
:
10
,
workorderCode
:
null
,
workorderName
:
null
,
workorderType
:
'SELF'
,
//这里的排产要排除自产之外的外协和外购
workorderType
:
"SELF"
,
//这里的排产要排除自产之外的外协和外购
taskCode
:
null
,
taskId
:
null
,
taskName
:
null
,
workstationCode
:
null
,
workstationName
:
null
,
workstationid
:
null
,
orderSource
:
null
,
sourceCode
:
null
,
productId
:
null
,
productCode
:
null
,
productName
:
null
,
productSpc
:
null
,
itemId
:
null
,
itemCode
:
null
,
itemName
:
null
,
routeId
:
null
,
routeName
:
null
,
routeCode
:
null
,
processId
:
null
,
processName
:
null
,
processCode
:
null
,
specification
:
null
,
unitOfMeasure
:
null
,
quantity
:
null
,
quantityProduced
:
null
,
quantityQuanlify
:
null
,
quantityUnquanlify
:
null
,
quantityChanged
:
null
,
quantityScheduled
:
null
,
clientId
:
null
,
clientCode
:
null
,
clientName
:
null
,
requestDate
:
null
,
parentId
:
null
,
ancestors
:
null
,
status
:
'CONFIRMED'
,
startTime
:
null
,
duration
:
null
,
endTime
:
null
,
colorCode
:
null
,
requestDate
:
null
,
remark
:
null
,
status
:
"NORMARL"
,
workunitName
:
null
,
workunitId
:
null
,
}
,
tasks
:{
tasks
:
{
data
:
[],
links
:
[]
links
:
[]
,
}
,
// 表单参数
form
:
{
}
,
...
...
@@ -355,20 +531,24 @@ export default {
this
.
getGanttTasks
();
}
,
methods
:
{
/** 查询
生产工
单列表 */
/** 查询
任务
单列表 */
getList
()
{
this
.
loading
=
true
;
listWorkorder
(
this
.
queryParams
).
then
(
response
=>
{
this
.
workorderList
=
this
.
handleTree
(
response
.
rows
,
"workorderId"
,
"parentId"
);
listProtask
(
this
.
queryParams
).
then
((
response
)
=>
{
this
.
taskList
=
this
.
handleTree
(
response
.
rows
,
"taskId"
// "parentId"
);
this
.
total
=
response
.
total
;
this
.
loading
=
false
;
}
);
}
,
handleOpenGantt
(){
this
.
$router
.
push
({
path
:
'/mes/pro/schedule/ganttedit'
}
)
handleOpenGantt
()
{
this
.
$router
.
push
({
path
:
"/mes/pro/schedule/ganttedit"
}
);
}
,
getGanttTasks
(){
listGanttTaskList
(
this
.
queryParams
).
then
(
response
=>
{
getGanttTasks
()
{
listGanttTaskList
(
this
.
queryParams
).
then
(
(
response
)
=>
{
this
.
tasks
.
data
=
response
.
data
.
data
;
this
.
tasks
.
links
=
response
.
data
.
links
;
this
.
$refs
.
ganttChar
.
reload
();
...
...
@@ -376,30 +556,34 @@ export default {
}
,
//获取当前产品对应的生产工序
getProcess
(){
listProductprocess
(
this
.
form
.
productId
).
then
(
response
=>
{
getProcess
()
{
listProductprocess
(
this
.
form
.
productId
).
then
((
response
)
=>
{
this
.
processOptions
=
response
.
data
;
}
);
}
,
/** 转换
生产工
单数据结构 */
/** 转换
任务
单数据结构 */
normalizer
(
node
)
{
if
(
node
.
children
&&
!
node
.
children
.
length
)
{
delete
node
.
children
;
}
return
{
id
:
node
.
workorder
Id
,
label
:
node
.
workorder
Name
,
children
:
node
.
children
id
:
node
.
task
Id
,
label
:
node
.
task
Name
,
children
:
node
.
children
,
}
;
}
,
/** 查询生产工单下拉树结构 */
getTreeselect
()
{
listWorkorder
().
then
(
response
=>
{
this
.
workorderOptions
=
[];
const
data
=
{
workorderId
:
0
,
workorderName
:
'顶级节点'
,
children
:
[]
}
;
data
.
children
=
this
.
handleTree
(
response
.
data
,
"workorderId"
,
"parentId"
);
this
.
workorderOptions
.
push
(
data
);
listProtask
().
then
((
response
)
=>
{
this
.
taskOptions
=
[];
const
data
=
{
taskId
:
0
,
taskName
:
"顶级节点"
,
children
:
[],
}
;
data
.
children
=
this
.
handleTree
(
response
.
data
,
"taskId"
,
"parentId"
);
this
.
taskOptions
.
push
(
data
);
}
);
}
,
// 取消按钮
...
...
@@ -414,39 +598,58 @@ export default {
workorderCode
:
null
,
workorderName
:
null
,
orderSource
:
null
,
taskCode
:
null
,
taskId
:
null
,
taskName
:
null
,
workstationCode
:
null
,
workstationName
:
null
,
workstationid
:
null
,
sourceCode
:
null
,
productId
:
null
,
productCode
:
null
,
productName
:
null
,
productSpc
:
null
,
itemId
:
null
,
itemCode
:
null
,
itemName
:
null
,
routeId
:
null
,
routeName
:
null
,
routeCode
:
null
,
processId
:
null
,
processName
:
null
,
processCode
:
null
,
specification
:
null
,
unitOfMeasure
:
null
,
quantity
:
null
,
quantityProduced
:
null
,
quantityQuanlify
:
null
,
quantityUnquanlify
:
null
,
quantityChanged
:
null
,
quantityScheduled
:
null
,
clientId
:
null
,
clientCode
:
null
,
clientName
:
null
,
requestDate
:
null
,
parentId
:
null
,
status
:
"PREPARE"
,
status
:
"NORMARL"
,
startTime
:
null
,
duration
:
null
,
endTime
:
null
,
colorCode
:
null
,
remark
:
null
,
createBy
:
null
,
createTime
:
null
,
updateBy
:
null
,
updateTime
:
null
updateTime
:
null
,
workunitName
:
null
,
workunitId
:
null
,
}
;
this
.
activeProcess
=
0
;
this
.
activeProcess
=
0
;
this
.
autoGenFlag
=
false
;
this
.
resetForm
(
"form"
);
}
,
//甘特图按钮点击
openGanttChart
(){
this
.
$refs
.
ganttChar
.
showFlag
=
true
;
openGanttChart
()
{
this
.
$refs
.
ganttChar
.
showFlag
=
true
;
}
,
//Step点击
handleStepClick
(
index
){
this
.
activeProcess
=
index
;
handleStepClick
(
index
)
{
this
.
activeProcess
=
index
;
}
,
/** 搜索按钮操作 */
handleQuery
()
{
...
...
@@ -458,50 +661,52 @@ export default {
this
.
handleQuery
();
}
,
//从BOM行中直接新增
handleSubAdd
(
row
){
handleSubAdd
(
row
)
{
this
.
open
=
false
;
this
.
reset
();
this
.
getTreeselect
();
if
(
row
!=
null
&&
row
.
workorder
Id
)
{
if
(
row
!=
null
&&
row
.
task
Id
)
{
this
.
form
=
row
;
this
.
form
.
parentId
=
row
.
workorder
Id
;
this
.
form
.
workorder
Id
=
null
;
this
.
form
.
workorder
Code
=
null
;
this
.
form
.
parentId
=
row
.
task
Id
;
this
.
form
.
task
Id
=
null
;
this
.
form
.
task
Code
=
null
;
}
else
{
this
.
form
.
parentId
=
0
;
}
this
.
open
=
true
;
this
.
title
=
"添加
生产工
单"
;
this
.
optType
=
"add"
;
this
.
title
=
"添加
任务
单"
;
this
.
optType
=
"add"
;
}
,
/** 新增按钮操作 */
handleAdd
(
row
)
{
this
.
reset
();
this
.
getTreeselect
();
if
(
row
!=
null
&&
row
.
workorder
Id
)
{
if
(
row
!=
null
&&
row
.
task
Id
)
{
this
.
form
.
parentId
=
row
.
workorderId
;
this
.
form
.
orderSource
=
row
.
orderSource
;
this
.
form
.
sourceCode
=
row
.
sourceCode
;
this
.
form
.
clientId
=
row
.
clientId
;
this
.
form
.
clientCode
=
row
.
clientCode
;
this
.
form
.
clientName
=
row
.
clientName
;
this
.
form
.
workunitName
=
row
.
workunitName
;
this
.
form
.
workunitId
=
row
.
workunitId
;
}
else
{
this
.
form
.
parentId
=
0
;
}
this
.
open
=
true
;
this
.
title
=
"添加
生产工
单"
;
this
.
optType
=
"add"
;
this
.
title
=
"添加
任务
单"
;
this
.
optType
=
"add"
;
}
,
// 查询明细按钮操作
handleView
(
row
){
handleView
(
row
)
{
this
.
reset
();
this
.
getTreeselect
();
const
workorderId
=
row
.
workorder
Id
||
this
.
ids
;
get
Workorder
(
workorderId
).
then
(
response
=>
{
const
taskId
=
row
.
task
Id
||
this
.
ids
;
get
Protask
(
taskId
).
then
((
response
)
=>
{
this
.
form
=
response
.
data
;
this
.
getProcess
();
this
.
open
=
true
;
this
.
title
=
"查看
工
单信息"
;
this
.
title
=
"查看
任务
单信息"
;
this
.
optType
=
"view"
;
}
);
}
,
...
...
@@ -510,32 +715,32 @@ export default {
this
.
reset
();
this
.
getTreeselect
();
if
(
row
!=
null
)
{
this
.
form
.
parentId
=
row
.
workorder
Id
;
this
.
form
.
parentId
=
row
.
task
Id
;
}
get
Workorder
(
row
.
workorderId
).
then
(
response
=>
{
get
Protask
(
row
.
taskId
).
then
((
response
)
=>
{
this
.
form
=
response
.
data
;
this
.
getProcess
();
this
.
open
=
true
;
this
.
title
=
"生产排产"
;
this
.
optType
=
"edit"
;
this
.
optType
=
"edit"
;
}
);
}
,
/** 提交按钮 */
submitForm
()
{
this
.
$refs
[
"form"
].
validate
(
valid
=>
{
this
.
$refs
[
"form"
].
validate
(
(
valid
)
=>
{
if
(
valid
)
{
if
(
this
.
form
.
workorder
Id
!=
null
)
{
update
Workorder
(
this
.
form
).
then
(
response
=>
{
if
(
this
.
form
.
task
Id
!=
null
)
{
update
Protask
(
this
.
form
).
then
((
response
)
=>
{
this
.
$modal
.
msgSuccess
(
"修改成功"
);
//this.open = false;
this
.
$refs
[
"bomlist"
].
getList
();
this
.
getList
();
}
);
}
else
{
add
Workorder
(
this
.
form
).
then
(
response
=>
{
add
Protask
(
this
.
form
).
then
((
response
)
=>
{
this
.
$modal
.
msgSuccess
(
"新增成功"
);
//this.open = false;
this
.
form
.
workorder
Id
=
response
.
data
;
this
.
form
.
task
Id
=
response
.
data
;
this
.
getList
();
}
);
}
...
...
@@ -544,65 +749,75 @@ export default {
}
,
/** 删除按钮操作 */
handleDelete
(
row
)
{
this
.
$modal
.
confirm
(
'是否确认删除生产工单编号为"'
+
row
.
workorderId
+
'"的数据项?'
).
then
(
function
()
{
return
delWorkorder
(
row
.
workorderId
);
}
).
then
(()
=>
{
this
.
$modal
.
confirm
(
'是否确认删除生产工单编号为"'
+
row
.
taskId
+
'"的数据项?'
)
.
then
(
function
()
{
return
delProtask
(
row
.
taskId
);
}
)
.
then
(()
=>
{
this
.
getList
();
this
.
$modal
.
msgSuccess
(
"删除成功"
);
}
).
catch
(()
=>
{
}
);
}
)
.
catch
(()
=>
{
}
);
}
,
handleSelectProduct
(){
handleSelectProduct
()
{
this
.
$refs
.
itemSelect
.
showFlag
=
true
;
}
,
handleSelectClient
(){
handleSelectClient
()
{
this
.
$refs
.
clientSelect
.
showFlag
=
true
;
}
,
/** 导出按钮操作 */
handleExport
()
{
this
.
download
(
'mes/pro/workorder/export'
,
{
...
this
.
queryParams
}
,
`workorder_${new Date().getTime()
}
.xlsx`
)
this
.
download
(
"mes/pro/protask/export"
,
{
...
this
.
queryParams
,
}
,
`workorder_${new Date().getTime()
}
.xlsx`
);
}
,
handleFinish
(){
handleFinish
()
{
let
that
=
this
;
this
.
$modal
.
confirm
(
'是否完成工单编制?【完成后将不能更改】'
).
then
(
function
(){
that
.
form
.
status
=
'CONFIRMED'
;
this
.
$modal
.
confirm
(
"是否完成任务单编制?【完成后将不能更改】"
)
.
then
(
function
()
{
that
.
form
.
status
=
"CONFIRMED"
;
that
.
submitForm
();
}
);
}
,
//物料选择弹出框
onItemSelected
(
obj
){
if
(
obj
!=
undefined
&&
obj
!=
null
)
{
this
.
form
.
product
Id
=
obj
.
itemId
;
this
.
form
.
product
Code
=
obj
.
itemCode
;
this
.
form
.
product
Name
=
obj
.
itemName
;
this
.
form
.
productSpc
=
obj
.
specification
;
onItemSelected
(
obj
)
{
if
(
obj
!=
undefined
&&
obj
!=
null
)
{
this
.
form
.
item
Id
=
obj
.
itemId
;
this
.
form
.
item
Code
=
obj
.
itemCode
;
this
.
form
.
item
Name
=
obj
.
itemName
;
this
.
form
.
specification
=
obj
.
specification
;
this
.
form
.
unitOfMeasure
=
obj
.
unitOfMeasure
;
}
}
,
//客户选择弹出框
onClientSelected
(
obj
){
if
(
obj
!=
undefined
&&
obj
!=
null
)
{
onClientSelected
(
obj
)
{
if
(
obj
!=
undefined
&&
obj
!=
null
)
{
this
.
form
.
clientId
=
obj
.
clientId
;
this
.
form
.
clientCode
=
obj
.
clientCode
;
this
.
form
.
clientName
=
obj
.
clientName
;
}
}
,
//自动生成编码
handleAutoGenChange
(
autoGenFlag
){
if
(
autoGenFlag
)
{
genCode
(
'WORKORDER_CODE'
).
then
(
response
=>
{
this
.
form
.
workorder
Code
=
response
;
handleAutoGenChange
(
autoGenFlag
)
{
if
(
autoGenFlag
)
{
genCode
(
"TASK_CODE"
).
then
((
response
)
=>
{
this
.
form
.
task
Code
=
response
;
}
);
}
else
{
this
.
form
.
workorderCode
=
null
;
}
}
}
else
{
this
.
form
.
taskCode
=
null
;
}
}
,
}
,
}
;
<
/script
>
<
style
scoped
>
.
wrapper
{
.
wrapper
{
height
:
400
px
;
}
.
container
{
...
...
src/views/mes/proofing/components/ProogingBom.vue
View file @
c0268649
...
...
@@ -113,6 +113,7 @@
<el-dialog
:visible
.
sync=
"showFlag"
width=
"700px"
title=
"添加BOM"
>
<el-form
ref=
"form"
class=
"page-form"
:model=
"form"
:rules=
"rules"
inline
...
...
@@ -120,7 +121,7 @@
size=
"small"
>
<el-row>
<el-col
:span=
"
24
"
>
<el-col
:span=
"
12
"
>
<el-form-item
label=
"物料"
prop=
"itemId"
>
<el-input
v-model=
"form.itemName"
...
...
src/views/mes/proofing/proofingInfo.vue
View file @
c0268649
...
...
@@ -24,7 +24,7 @@
label-width=
"100px"
>
<el-row>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
prop=
"prototypeRequestCode"
>
<
template
slot=
"label"
>
申请单编码
</
template
>
<el-input
...
...
@@ -35,7 +35,7 @@
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"产品"
prop=
"itemId"
>
<el-input
v-model=
"form.itemName"
...
...
@@ -51,7 +51,7 @@
<ItemSelect
ref=
"ItemSelectRef"
@
onSelected=
"onItemSelect"
/>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"工艺路线"
prop=
"routeId"
>
<el-input
v-model=
"form.routeName"
...
...
@@ -70,7 +70,7 @@
/>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"简称"
prop=
"abbreviation"
>
<el-input
v-model=
"form.abbreviation"
...
...
@@ -80,7 +80,7 @@
</el-col>
</el-row>
<el-row>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"样品英文名"
prop=
"enName"
>
<el-input
v-model=
"form.enName"
...
...
@@ -88,14 +88,14 @@
></el-input>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"样品数量"
prop=
"num"
>
<el-input
v-model=
"form.num"
placeholder=
"请输入样品数量"
>
<
template
slot=
"suffix"
>
{{
form
.
unit
}}
</
template
>
</el-input>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"打样形式"
prop=
"type"
>
<el-input
v-model=
"form.type"
...
...
@@ -103,7 +103,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"分配方式"
prop=
"modality"
>
<el-input
v-model=
"form.modality"
...
...
@@ -111,7 +111,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"表面处理"
prop=
"surfaceTreatment"
>
<el-input
v-model=
"form.surfaceTreatment"
...
...
@@ -119,7 +119,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"NG原因"
prop=
"ngReason"
>
<el-input
v-model=
"form.ngReason"
...
...
@@ -127,7 +127,7 @@
></el-input>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
prop=
"plannedFinishDate"
>
<
template
slot=
"label"
>
<TipLabel
title=
"完成日期"
tip=
"计划完成日期"
/>
...
...
@@ -139,7 +139,7 @@
></el-date-picker>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
prop=
"plannedLayoutDate"
>
<
template
slot=
"label"
>
<TipLabel
title=
"版面时间"
tip=
"版面需求时间"
/>
...
...
@@ -151,7 +151,7 @@
></el-date-picker>
</el-form-item>
</el-col>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"测试标准"
prop=
"testStandard"
>
<el-input
v-model=
"form.testStandard"
...
...
@@ -161,7 +161,7 @@
</el-col>
</el-row>
<el-row>
<el-col
:
md=
"6
"
:sm=
"12"
:xs=
"12"
>
<el-col
:
lg=
"6"
:md=
"8
"
:sm=
"12"
:xs=
"12"
>
<el-form-item
label=
"备注"
prop=
"remark"
>
<el-input
type=
"textarea"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment