Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mes-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
mes
mes-ui
Commits
691bd0fc
Commit
691bd0fc
authored
Oct 22, 2024
by
沈翠玲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改代码
parent
b7d5e0d3
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
645 additions
and
11 deletions
+645
-11
lpnLabel.js
src/api/mes/lpn/lpnLabel.js
+11
-0
index.vue
src/views/mes/lpn/lpnLabel/index.vue
+310
-0
index.vue
src/views/mes/lpn/lpnNoDuplicate/index.vue
+306
-0
index.vue
src/views/mes/pro/dta/index.vue
+15
-8
commandList.vue
src/views/mes/pro/workorder/commandList.vue
+3
-3
No files found.
src/api/mes/lpn/lpnLabel.js
0 → 100644
View file @
691bd0fc
import
request
from
'@/utils/request'
// 查询列表
export
function
listlpnrecord
(
query
)
{
return
request
({
url
:
'/pro/serial/lpn/record/list'
,
method
:
'get'
,
params
:
query
})
}
src/views/mes/lpn/lpnLabel/index.vue
0 → 100644
View file @
691bd0fc
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
@
submit
.
native
.
prevent
label-width=
"100px"
>
<el-form-item
label=
"LPN扫码/输入"
prop=
"lpnNo"
>
<el-input
v-model=
"queryParams.lpnNo"
placeholder=
"LPN扫码/输入回车立马打印"
clearable
@
keyup
.
enter
.
native=
"handleprint"
/>
</el-form-item>
<el-form-item>
<el-button
type=
"primary"
size=
"mini"
@
click=
"handleprint"
>
打印
</el-button
>
</el-form-item>
</el-form>
<el-row
:gutter=
"10"
class=
"mb8"
>
<!--
<el-col
:span=
"1.5"
>
<el-button
type=
"warning"
plain
icon=
"el-icon-download"
size=
"mini"
@
click=
"handleExport"
v-hasPermi=
"['pro:scheduleSetupRule:export']"
>
导出
</el-button>
</el-col>
-->
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
</el-row>
<el-table
v-loading=
"loading"
:data=
"scheduleSetupRuleList"
@
selection-change=
"handleSelectionChange"
>
<!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
-->
<el-table-column
label=
"工单号"
align=
"center"
width=
"120"
prop=
"workorderCode"
/>
<el-table-column
label=
"销售编号"
align=
"center"
width=
"160"
prop=
"salesVoucher"
/>
<el-table-column
label=
"销售编号项次"
align=
"center"
width=
"160"
prop=
"salesVoucherItem"
/>
<el-table-column
label=
"LPN码"
align=
"center"
prop=
"lpnNo"
/>
<el-table-column
label=
"on"
align=
"center"
prop=
"是否打印"
>
<template
slot-scope=
"scope"
>
{{
scope
.
row
.
on
?
'是'
:
'否'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"创建人"
align=
"center"
prop=
"createBy"
/>
<el-table-column
label=
"创建时间"
align=
"center"
prop=
"createTime"
/>
</el-table>
<pagination
v-show=
"total > 0"
:total=
"total"
:page
.
sync=
"queryParams.pageNum"
:limit
.
sync=
"queryParams.pageSize"
@
pagination=
"getList"
/>
</div>
</template>
<
script
>
import
{
listlpnrecord
}
from
'@/api/mes/lpn/lpnLabel'
import
{
listReport
}
from
'@/api/mes/report/ureport'
export
default
{
name
:
'lpnLabel'
,
data
()
{
return
{
// 遮罩层
loading
:
true
,
// 选中数组
ids
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 客户产品标签模板对照表表格数据
scheduleSetupRuleList
:
[],
// 弹出层标题
title
:
''
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
pageNum
:
1
,
pageSize
:
10
,
lpnNo
:
null
,
},
customerOptions
:
[],
brandOptions
:
[],
templateOptions
:
[],
selectedRows
:
[],
timer
:
null
,
// 表单参数
form
:
{},
// 表单校验
rules
:
{
templateId
:
[
{
required
:
true
,
message
:
'请选择模板'
,
trigger
:
[
'blur'
,
'change'
],
},
],
},
}
},
created
()
{
this
.
getList
()
},
methods
:
{
handleprint
(){
if
(
this
.
timer
!==
null
)
return
this
.
timer
=
setTimeout
(()
=>
{
console
.
log
(
'打印'
,
this
.
queryParams
)
this
.
timer
=
null
},
100
)
},
onItemSelected
(
obj
)
{
if
(
obj
!=
undefined
&&
obj
!=
null
)
{
this
.
form
.
itemId
=
obj
.
itemId
this
.
form
.
itemCode
=
obj
.
itemCode
this
.
form
.
itemName
=
obj
.
itemName
}
},
/** 查询客户产品标签模板对照表列表 */
getList
()
{
this
.
loading
=
true
listlpnrecord
(
this
.
queryParams
).
then
((
response
)
=>
{
this
.
scheduleSetupRuleList
=
response
.
rows
this
.
total
=
response
.
total
this
.
loading
=
false
})
},
// 取消按钮
cancel
()
{
this
.
open
=
false
this
.
reset
()
},
// 表单重置
reset
()
{
this
.
form
=
{
itemCode
:
null
,
customerName
:
null
,
brandName
:
null
,
brandCode
:
null
,
brandId
:
null
,
itemId
:
null
,
itemName
:
null
,
itemTypeCode
:
null
,
itemTypeId
:
null
,
itemTypeName
:
null
,
sapItemCode
:
null
,
templateName
:
null
,
templateType
:
null
,
templateCode
:
null
,
templateId
:
null
,
createBy
:
null
,
}
this
.
resetForm
(
'form'
)
},
/** 搜索按钮操作 */
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
this
.
getList
()
},
handleSelectProduct
()
{
this
.
$refs
.
itemSelect
.
showFlag
=
true
},
handleitemType
()
{
this
.
$refs
.
brSelect
.
showFlag
=
true
},
onitemTypeed
(
row
)
{
if
(
Object
.
values
(
row
).
length
>
0
)
{
this
.
form
.
itemTypeId
=
row
.
itemTypeId
this
.
form
.
sapTypeCode
=
row
.
sapTypeCode
this
.
form
.
itemTypeCode
=
row
.
itemTypeCode
this
.
form
.
itemTypeName
=
row
.
itemTypeName
}
},
/** 重置按钮操作 */
resetQuery
()
{
this
.
resetForm
(
'queryForm'
)
this
.
handleQuery
()
},
// 多选框选中数据
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
((
item
)
=>
item
.
id
)
this
.
selectedRows
=
selection
this
.
single
=
selection
.
length
!==
1
this
.
multiple
=
!
selection
.
length
},
/** 新增按钮操作 */
handleAdd
()
{
this
.
reset
()
this
.
open
=
true
this
.
title
=
'添加客户产品标签模板对照表'
},
/** 修改按钮操作 */
handleUpdate
(
row
)
{
if
(
!
row
||
!
row
.
id
)
row
=
this
.
selectedRows
[
0
]
this
.
reset
()
this
.
form
=
row
this
.
open
=
true
this
.
title
=
'修改客户产品标签模板对照表'
},
/** 提交按钮 */
submitForm
()
{
this
.
$refs
[
'form'
].
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
this
.
form
.
customerCode
)
{
this
.
form
.
customerName
=
this
.
customerOptions
.
find
(
(
v
)
=>
this
.
form
.
customerCode
===
v
.
KUNNR
).
NAME
}
if
(
this
.
form
.
brandCode
)
{
this
.
form
.
brandName
=
this
.
brandOptions
.
find
(
(
v
)
=>
this
.
form
.
brandCode
===
v
.
brandCode
).
brandName
}
if
(
this
.
form
.
templateId
)
{
const
template
=
this
.
templateOptions
.
find
(
(
v
)
=>
this
.
form
.
templateId
===
v
.
id
)
this
.
form
.
templateName
=
template
.
name
this
.
form
.
templateType
=
template
.
reportType
this
.
form
.
templateCode
=
template
.
id
+
''
}
if
(
this
.
form
.
id
!=
null
)
{
updateCustomerLabel
(
this
.
form
).
then
((
response
)
=>
{
this
.
$modal
.
msgSuccess
(
'修改成功'
)
this
.
open
=
false
this
.
getList
()
})
}
else
{
addCustomerLabel
(
this
.
form
).
then
((
response
)
=>
{
this
.
$modal
.
msgSuccess
(
'新增成功'
)
this
.
open
=
false
this
.
getList
()
})
}
}
})
},
/** 删除按钮操作 */
handleDelete
(
row
)
{
const
Ids
=
row
.
id
||
this
.
ids
this
.
$modal
.
confirm
(
'是否确认删除客户产品标签模板对照表编号为"'
+
Ids
+
'"的数据项?'
)
.
then
(
function
()
{
return
delcustomerLabel
(
Ids
)
})
.
then
(()
=>
{
this
.
getList
()
this
.
$modal
.
msgSuccess
(
'删除成功'
)
})
.
catch
(()
=>
{})
},
/** 导出按钮操作 */
handleExport
()
{
this
.
download
(
'pro/scheduleSetupRule/export'
,
{
...
this
.
queryParams
,
},
`scheduleSetupRule_
${
new
Date
().
getTime
()}
.xlsx`
)
},
},
}
</
script
>
\ No newline at end of file
src/views/mes/lpn/lpnNoDuplicate/index.vue
0 → 100644
View file @
691bd0fc
<
template
>
<div
class=
"app-container"
>
<el-form
:model=
"queryParams"
ref=
"queryForm"
size=
"small"
:inline=
"true"
v-show=
"showSearch"
@
submit
.
native
.
prevent
label-width=
"100px"
>
<el-form-item
label=
"生产工单号"
prop=
"workorderCode"
>
<el-input
v-model=
"queryParams.workorderCode"
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-row
:gutter=
"10"
class=
"mb8"
>
<el-col
:span=
"1.5"
>
<el-button
type=
"primary"
size=
"mini"
:disabled=
"multiple"
@
click=
"handleprint"
>
打印
</el-button
>
</el-col>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
</el-row>
<el-table
v-loading=
"loading"
:data=
"scheduleSetupRuleList"
@
selection-change=
"handleSelectionChange"
>
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
<el-table-column
label=
"工单号"
align=
"center"
width=
"120"
prop=
"workorderCode"
/>
<el-table-column
label=
"销售编号"
align=
"center"
width=
"160"
prop=
"salesVoucher"
/>
<el-table-column
label=
"销售编号项次"
align=
"center"
width=
"160"
prop=
"salesVoucherItem"
/>
<el-table-column
label=
"LPN码"
align=
"center"
prop=
"lpnNo"
/>
<el-table-column
label=
"on"
align=
"center"
prop=
"是否打印"
>
<template
slot-scope=
"scope"
>
{{
scope
.
row
.
on
?
'是'
:
'否'
}}
</
template
>
</el-table-column>
<el-table-column
label=
"创建人"
align=
"center"
prop=
"createBy"
/>
<el-table-column
label=
"创建时间"
align=
"center"
prop=
"createTime"
/>
</el-table>
<pagination
v-show=
"total > 0"
:total=
"total"
:page-sizes=
"[100, 500, 1000, 5000]"
:page
.
sync=
"queryParams.pageNum"
:limit
.
sync=
"queryParams.pageSize"
@
pagination=
"getList"
/>
</div>
</template>
<
script
>
import
{
listlpnrecord
}
from
'@/api/mes/lpn/lpnLabel'
import
{
listReport
}
from
'@/api/mes/report/ureport'
export
default
{
name
:
'lpnLabel'
,
data
()
{
return
{
// 遮罩层
loading
:
true
,
// 选中数组
ids
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 客户产品标签模板对照表表格数据
scheduleSetupRuleList
:
[],
// 弹出层标题
title
:
''
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
pageNum
:
1
,
pageSize
:
100
,
workorderCode
:
null
,
},
customerOptions
:
[],
brandOptions
:
[],
templateOptions
:
[],
selectedRows
:
[],
timer
:
null
,
// 表单参数
form
:
{},
// 表单校验
rules
:
{
templateId
:
[
{
required
:
true
,
message
:
'请选择模板'
,
trigger
:
[
'blur'
,
'change'
],
},
],
},
}
},
created
()
{
this
.
getList
()
},
methods
:
{
handleprint
(){
if
(
this
.
timer
!==
null
)
return
this
.
timer
=
setTimeout
(()
=>
{
console
.
log
(
'打印'
,
this
.
queryParams
)
this
.
timer
=
null
},
100
)
},
onItemSelected
(
obj
)
{
if
(
obj
!=
undefined
&&
obj
!=
null
)
{
this
.
form
.
itemId
=
obj
.
itemId
this
.
form
.
itemCode
=
obj
.
itemCode
this
.
form
.
itemName
=
obj
.
itemName
}
},
/** 查询客户产品标签模板对照表列表 */
getList
()
{
this
.
loading
=
true
listlpnrecord
(
this
.
queryParams
).
then
((
response
)
=>
{
this
.
scheduleSetupRuleList
=
response
.
rows
this
.
total
=
response
.
total
this
.
loading
=
false
})
},
// 取消按钮
cancel
()
{
this
.
open
=
false
this
.
reset
()
},
// 表单重置
reset
()
{
this
.
form
=
{
itemCode
:
null
,
customerName
:
null
,
brandName
:
null
,
brandCode
:
null
,
brandId
:
null
,
itemId
:
null
,
itemName
:
null
,
itemTypeCode
:
null
,
itemTypeId
:
null
,
itemTypeName
:
null
,
sapItemCode
:
null
,
templateName
:
null
,
templateType
:
null
,
templateCode
:
null
,
templateId
:
null
,
createBy
:
null
,
}
this
.
resetForm
(
'form'
)
},
/** 搜索按钮操作 */
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
this
.
getList
()
},
handleSelectProduct
()
{
this
.
$refs
.
itemSelect
.
showFlag
=
true
},
handleitemType
()
{
this
.
$refs
.
brSelect
.
showFlag
=
true
},
onitemTypeed
(
row
)
{
if
(
Object
.
values
(
row
).
length
>
0
)
{
this
.
form
.
itemTypeId
=
row
.
itemTypeId
this
.
form
.
sapTypeCode
=
row
.
sapTypeCode
this
.
form
.
itemTypeCode
=
row
.
itemTypeCode
this
.
form
.
itemTypeName
=
row
.
itemTypeName
}
},
/** 重置按钮操作 */
resetQuery
()
{
this
.
resetForm
(
'queryForm'
)
this
.
handleQuery
()
},
// 多选框选中数据
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
((
item
)
=>
item
.
id
)
this
.
selectedRows
=
selection
this
.
single
=
selection
.
length
!==
1
this
.
multiple
=
!
selection
.
length
},
/** 新增按钮操作 */
handleAdd
()
{
this
.
reset
()
this
.
open
=
true
this
.
title
=
'添加客户产品标签模板对照表'
},
/** 修改按钮操作 */
handleUpdate
(
row
)
{
if
(
!
row
||
!
row
.
id
)
row
=
this
.
selectedRows
[
0
]
this
.
reset
()
this
.
form
=
row
this
.
open
=
true
this
.
title
=
'修改客户产品标签模板对照表'
},
/** 提交按钮 */
submitForm
()
{
this
.
$refs
[
'form'
].
validate
((
valid
)
=>
{
if
(
valid
)
{
if
(
this
.
form
.
customerCode
)
{
this
.
form
.
customerName
=
this
.
customerOptions
.
find
(
(
v
)
=>
this
.
form
.
customerCode
===
v
.
KUNNR
).
NAME
}
if
(
this
.
form
.
brandCode
)
{
this
.
form
.
brandName
=
this
.
brandOptions
.
find
(
(
v
)
=>
this
.
form
.
brandCode
===
v
.
brandCode
).
brandName
}
if
(
this
.
form
.
templateId
)
{
const
template
=
this
.
templateOptions
.
find
(
(
v
)
=>
this
.
form
.
templateId
===
v
.
id
)
this
.
form
.
templateName
=
template
.
name
this
.
form
.
templateType
=
template
.
reportType
this
.
form
.
templateCode
=
template
.
id
+
''
}
if
(
this
.
form
.
id
!=
null
)
{
updateCustomerLabel
(
this
.
form
).
then
((
response
)
=>
{
this
.
$modal
.
msgSuccess
(
'修改成功'
)
this
.
open
=
false
this
.
getList
()
})
}
else
{
addCustomerLabel
(
this
.
form
).
then
((
response
)
=>
{
this
.
$modal
.
msgSuccess
(
'新增成功'
)
this
.
open
=
false
this
.
getList
()
})
}
}
})
},
/** 删除按钮操作 */
handleDelete
(
row
)
{
const
Ids
=
row
.
id
||
this
.
ids
this
.
$modal
.
confirm
(
'是否确认删除客户产品标签模板对照表编号为"'
+
Ids
+
'"的数据项?'
)
.
then
(
function
()
{
return
delcustomerLabel
(
Ids
)
})
.
then
(()
=>
{
this
.
getList
()
this
.
$modal
.
msgSuccess
(
'删除成功'
)
})
.
catch
(()
=>
{})
},
/** 导出按钮操作 */
handleExport
()
{
this
.
download
(
'pro/scheduleSetupRule/export'
,
{
...
this
.
queryParams
,
},
`scheduleSetupRule_
${
new
Date
().
getTime
()}
.xlsx`
)
},
},
}
</
script
>
\ No newline at end of file
src/views/mes/pro/dta/index.vue
View file @
691bd0fc
...
...
@@ -48,6 +48,7 @@
v-hasPermi=
"['pro:scheduleSetupRule:remove']"
>
删除
</el-button>
</el-col>
-->
<el-col
:span=
"1.5"
>
<el-button
type=
"warning"
...
...
@@ -55,16 +56,18 @@
icon=
"el-icon-download"
size=
"mini"
@
click=
"handleExport"
v-hasPermi=
"['pro:scheduleSetupRule:export']"
>
导出
</el-button>
</el-col>
-->
:disabled=
"single"
v-hasPermi=
"['pro:dta:export']"
>
LPN导出
</el-button>
</el-col>
<right-toolbar
:showSearch
.
sync=
"showSearch"
@
queryTable=
"getList"
></right-toolbar>
</el-row>
<el-table
v-loading=
"loading"
:data=
"scheduleSetupRuleList"
@
selection-change=
"handleSelectionChange"
>
<
!--
<el-table-column
type=
"selection"
width=
"55"
align=
"center"
/>
--
>
<
el-table-column
type=
"selection"
width=
"55"
align=
"center"
/
>
<el-table-column
label=
"工单编号"
align=
"center"
prop=
"workorderCode"
/>
<el-table-column
label=
"销售单号"
align=
"center"
prop=
"saleCode"
/>
<el-table-column
label=
"销售单号"
align=
"center"
prop=
"salesVoucher"
/>
<el-table-column
label=
"销售单号项次"
align=
"center"
prop=
"salesVoucherItem"
/>
<el-table-column
label=
"物料名称"
align=
"center"
prop=
"itemName"
/>
<el-table-column
label=
"开始时间"
align=
"center"
prop=
"startTime"
/>
<el-table-column
label=
"排版方式"
align=
"center"
prop=
"dtaType"
...
...
@@ -229,6 +232,7 @@ export default {
return
{
// 遮罩层
loading
:
true
,
selectedRows
:
[],
// 选中数组
ids
:
[],
//dta列表
...
...
@@ -336,6 +340,7 @@ export default {
},
// 多选框选中数据
handleSelectionChange
(
selection
)
{
this
.
selectedRows
=
selection
this
.
ids
=
selection
.
map
(
item
=>
item
.
ruleId
)
this
.
single
=
selection
.
length
!==
1
this
.
multiple
=
!
selection
.
length
...
...
@@ -397,9 +402,11 @@ export default {
},
/** 导出按钮操作 */
handleExport
()
{
this
.
download
(
'pro/scheduleSetupRule/export'
,
{
...
this
.
queryParams
},
`scheduleSetupRule_
${
new
Date
().
getTime
()}
.xlsx`
)
const
row
=
this
.
selectedRows
[
0
]
this
.
download
(
'pro/serial/lpn/record/export'
,
{
salesVoucher
:
row
.
salesVoucher
,
salesVoucherItem
:
row
.
salesVoucherItem
,
},
`dta_
${
new
Date
().
getTime
()}
.xlsx`
)
}
}
};
...
...
src/views/mes/pro/workorder/commandList.vue
View file @
691bd0fc
...
...
@@ -147,9 +147,9 @@ export default {
this
.
handleQuery
();
},
async
handleFous
(
row
)
{
if
(
row
.
taskList
&&
row
.
taskList
.
length
)
{
return
}
//
if (row.taskList&&row.taskList.length) {
//
return
//
}
const
response
=
await
gettaskWorkunitList
({
workstationId
:
row
.
workstationId
})
this
.
$set
(
row
,
'taskList'
,
response
.
rows
)
console
.
log
(
row
)
...
...
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