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
68a58609
Commit
68a58609
authored
Jul 17, 2025
by
沈翠玲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
缺陷分类和 缺陷代码,生产追溯
parent
87991eb0
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
1584 additions
and
4 deletions
+1584
-4
defectClass.js
src/api/mes/md/defectClass.js
+37
-0
defectNormal.js
src/api/mes/md/defectNormal.js
+37
-0
productSee.js
src/api/mes/proTable/productSee.js
+10
-0
main.js
src/main.js
+2
-1
request.js
src/utils/request.js
+24
-1
index.vue
src/views/mes/md/defectClass/index.vue
+379
-0
index.vue
src/views/mes/md/defectNormal/index.vue
+433
-0
index.vue
src/views/mes/pro/feedback/index.vue
+4
-2
index.vue
src/views/mes/proTable/productSee/index.vue
+422
-0
line.vue
src/views/mes/proTable/productSee/line.vue
+236
-0
No files found.
src/api/mes/md/defectClass.js
0 → 100644
View file @
68a58609
import
request
from
'@/utils/request'
// 查询【请填写功能名称】列表
export
function
listdefectClass
(
query
)
{
return
request
({
url
:
'/qms/defectClass/list'
,
method
:
'get'
,
params
:
query
})
}
// 新增【请填写功能名称】
export
function
adddefectClass
(
data
)
{
return
request
({
url
:
'/qms/defectClass/add'
,
method
:
'post'
,
data
:
data
})
}
// 修改【请填写功能名称】
export
function
updatedefectClass
(
data
)
{
return
request
({
url
:
'/qms/defectClass/update'
,
method
:
'post'
,
data
:
data
})
}
// 删除【请填写功能名称】
export
function
deldefectClass
(
defectClassId
)
{
return
request
({
url
:
'/qms/defectClass/delete/'
+
defectClassId
,
method
:
'post'
})
}
src/api/mes/md/defectNormal.js
0 → 100644
View file @
68a58609
import
request
from
'@/utils/request'
// 查询【请填写功能名称】列表
export
function
listdefect
(
query
)
{
return
request
({
url
:
'/qms/defect/list'
,
method
:
'get'
,
params
:
query
})
}
// 新增【请填写功能名称】
export
function
adddefect
(
data
)
{
return
request
({
url
:
'/qms/defect/add'
,
method
:
'post'
,
data
:
data
})
}
// 修改【请填写功能名称】
export
function
updatedefect
(
data
)
{
return
request
({
url
:
'/qms/defect/update'
,
method
:
'post'
,
data
:
data
})
}
// 删除【请填写功能名称】
export
function
deldefect
(
defectId
)
{
return
request
({
url
:
'/qms/defect/delete/'
+
defectId
,
method
:
'post'
})
}
src/api/mes/proTable/productSee.js
0 → 100644
View file @
68a58609
import
request
from
'@/utils/request'
//
export
function
getplbl
(
query
)
{
return
request
({
url
:
"/report/pro/tracedback/plbl"
,
method
:
"get"
,
params
:
query
,
});
}
\ No newline at end of file
src/main.js
View file @
68a58609
...
...
@@ -16,7 +16,7 @@ import store from './store'
import
router
from
'./router'
import
directive
from
'./directive'
// directive
import
plugins
from
'./plugins'
// plugins
import
{
download
,
download1
}
from
'@/utils/request'
import
{
download
,
download1
,
download2
}
from
'@/utils/request'
import
'./assets/icons'
// icon
import
'./permission'
// permission control
...
...
@@ -65,6 +65,7 @@ Vue.prototype.selectDictLabel = selectDictLabel
Vue
.
prototype
.
selectDictLabels
=
selectDictLabels
Vue
.
prototype
.
download
=
download
Vue
.
prototype
.
download1
=
download1
Vue
.
prototype
.
download2
=
download2
Vue
.
prototype
.
handleTree
=
handleTree
Vue
.
prototype
.
formatMoney
=
formatMoney
...
...
src/utils/request.js
View file @
68a58609
...
...
@@ -226,5 +226,28 @@ export function download1(url, params, filename) {
downloadLoadingInstance
.
close
();
})
}
export
function
download2
(
url
,
params
,
filename
)
{
downloadLoadingInstance
=
Loading
.
service
({
text
:
"正在下载数据,请稍候"
,
spinner
:
"el-icon-loading"
,
background
:
"rgba(0, 0, 0, 0.7)"
,
})
return
service
.
get
(
url
,
params
,
{
// transformRequest: [(params) => { return tansParams(params) }],
headers
:
{
'Content-Type'
:
'application/json;charset=utf-8'
},
responseType
:
'blob'
}).
then
(
async
(
data
)
=>
{
const
isLogin
=
await
blobValidate
(
data
);
if
(
isLogin
)
{
const
blob
=
new
Blob
([
data
])
saveAs
(
blob
,
filename
)
}
else
{
const
resText
=
await
data
.
text
();
const
rspObj
=
JSON
.
parse
(
resText
);
const
errMsg
=
errorCode
[
rspObj
.
code
]
||
rspObj
.
msg
||
errorCode
[
'default'
]
Message
.
error
(
errMsg
);
}
downloadLoadingInstance
.
close
();
}).
catch
((
r
)
=>
{
console
.
error
(
r
)
Message
.
error
(
'下载文件出现错误,请联系管理员!'
)
downloadLoadingInstance
.
close
();
})
}
export
default
service
src/views/mes/md/defectClass/index.vue
0 → 100644
View file @
68a58609
This diff is collapsed.
Click to expand it.
src/views/mes/md/defectNormal/index.vue
0 → 100644
View file @
68a58609
This diff is collapsed.
Click to expand it.
src/views/mes/pro/feedback/index.vue
View file @
68a58609
...
...
@@ -620,12 +620,14 @@ export default {
workunitName
=
workunit
.
data
.
workunitName
;
detail
.
push
({
"barcode"
:
row
.
workorderCode
,
showText
:
'编排单号:'
+
row
.
arrangeCode
+
'
\
n报工次数:'
+
operNo
+
'
\
n数量:'
+
row
.
quantityQualify
+
'
\
n工单号:'
+
row
.
workorderCode
+
'
\
n下道工序机台:'
+
workunitName
,
showText
:
'编排单号:'
+
row
.
arrangeCode
+
'
\
n报工次数:'
+
operNo
+
'
\
n数量:'
+
row
.
quantityQualify
+
'
\
n工单号:'
+
row
.
workorderCode
+
'
\
n下道工序机台:'
+
workunitName
+
'
\
n缺陷问题:'
+
(
row
.
defectCodes
||
''
),
"gp"
:
1
}
)
detail
.
push
({
"barcode"
:
row
.
workorderCode
,
showText
:
'编排单号:'
+
row
.
arrangeCode
+
'
\
n报工次数:'
+
operNo
+
'
\
n数量:'
+
row
.
quantityQualify
+
'
\
n工单号:'
+
row
.
workorderCode
+
'
\
n下道工序机台:'
+
workunitName
,
showText
:
'编排单号:'
+
row
.
arrangeCode
+
'
\
n报工次数:'
+
operNo
+
'
\
n数量:'
+
row
.
quantityQualify
+
'
\
n工单号:'
+
row
.
workorderCode
+
'
\
n下道工序机台:'
+
workunitName
+
'
\
n缺陷问题:'
+
row
.
defectCodes
||
''
,
"gp"
:
1
}
)
postPrintPdf
(
...
...
src/views/mes/proTable/productSee/index.vue
0 → 100644
View file @
68a58609
This diff is collapsed.
Click to expand it.
src/views/mes/proTable/productSee/line.vue
0 → 100644
View file @
68a58609
<
template
>
<div
class=
"app-container"
>
<el-table
:data=
"sizeItems"
>
<el-table-column
label=
"SIZE码"
width=
"120px"
align=
"center"
prop=
"workorderSoSizeItemId"
:show-overflow-tooltip=
"true"
/>
<el-table-column
label=
"指令数"
align=
"center"
prop=
"quantity"
/>
<el-table-column
label=
"LOSS数"
align=
"center"
prop=
"lossNum"
/>
<el-table-column
label=
"样品数"
align=
"center"
prop=
"samples"
/>
</el-table>
</div>
</
template
>
<
script
>
import
{
getIssueline
,
delIssueline
,
addIssueline
,
updateIssueline
}
from
"@/api/mes/wm/issueline"
;
export
default
{
name
:
"Issueline"
,
props
:{
sizeItems
:
null
},
data
()
{
return
{
// 遮罩层
loading
:
true
,
// 选中数组
ids
:
[],
// 非单个禁用
single
:
true
,
// 非多个禁用
multiple
:
true
,
// 显示搜索条件
showSearch
:
true
,
// 总条数
total
:
0
,
// 生产领料单行表格数据
issuelineList
:
[],
// 弹出层标题
title
:
""
,
// 是否显示弹出层
open
:
false
,
// 查询参数
queryParams
:
{
pageNum
:
1
,
pageSize
:
10
,
issueId
:
this
.
issueId
,
itemId
:
null
,
itemCode
:
null
,
itemName
:
null
,
specification
:
null
,
unitOfMeasure
:
null
,
quantityIssued
:
null
,
batchCode
:
null
,
warehouseId
:
null
,
warehouseCode
:
null
,
warehouseName
:
null
,
locationId
:
null
,
locationCode
:
null
,
locationName
:
null
,
areaId
:
null
,
areaCode
:
null
,
areaName
:
null
,
},
// 表单参数
form
:
{},
// 表单校验
rules
:
{
itemId
:
[
{
required
:
true
,
message
:
"产品物料不能为空"
,
trigger
:
"blur"
}
],
quantityIssued
:
[
{
required
:
true
,
message
:
"领料数量不能为空"
,
trigger
:
"blur"
}
],
}
};
},
watch
:{
sizeItems
()
{
console
.
log
(
'this.sizeItems'
,
this
.
sizeItems
)
}
},
created
()
{
},
methods
:
{
// 取消按钮
cancel
()
{
this
.
open
=
false
;
this
.
reset
();
},
// 表单重置
reset
()
{
this
.
form
=
{
lineId
:
null
,
issueId
:
this
.
issueId
,
itemId
:
null
,
itemCode
:
null
,
itemName
:
null
,
specification
:
null
,
unitOfMeasure
:
null
,
quantityIssued
:
null
,
batchCode
:
null
,
warehouseId
:
null
,
warehouseCode
:
null
,
warehouseName
:
null
,
locationId
:
null
,
locationCode
:
null
,
locationName
:
null
,
areaId
:
null
,
areaCode
:
null
,
areaName
:
null
,
remark
:
null
,
attr1
:
null
,
attr2
:
null
,
attr3
:
null
,
attr4
:
null
,
createBy
:
null
,
createTime
:
null
,
updateBy
:
null
,
updateTime
:
null
};
this
.
resetForm
(
"form"
);
},
/** 搜索按钮操作 */
handleQuery
()
{
this
.
queryParams
.
pageNum
=
1
;
this
.
getList
();
},
/** 重置按钮操作 */
resetQuery
()
{
this
.
resetForm
(
"queryForm"
);
this
.
handleQuery
();
},
// 多选框选中数据
handleSelectionChange
(
selection
)
{
this
.
ids
=
selection
.
map
(
item
=>
item
.
lineId
)
this
.
single
=
selection
.
length
!==
1
this
.
multiple
=
!
selection
.
length
},
getSummaries
(
param
){
const
{
columns
,
data
}
=
param
const
sums
=
[]
columns
.
forEach
((
column
,
index
)
=>
{
if
(
index
===
1
)
{
sums
[
index
]
=
'总数量'
}
else
if
(
column
.
label
===
'领料数量'
)
{
const
temp
=
data
.
reduce
((
prev
,
curr
)
=>
{
return
prev
+
Number
(
curr
.
quantityIssued
);
},
0
)
sums
[
index
]
=
Number
.
isInteger
(
temp
)
?
temp
:
temp
.
toFixed
(
3
);
}
else
{
sums
[
index
]
=
''
}
})
return
sums
},
/** 新增按钮操作 */
handleAdd
()
{
this
.
reset
();
this
.
open
=
true
;
this
.
title
=
"添加生产领料单行"
;
},
/** 修改按钮操作 */
handleUpdate
(
row
)
{
this
.
reset
();
const
lineId
=
row
.
lineId
||
this
.
ids
getIssueline
(
lineId
).
then
(
response
=>
{
debugger
;
this
.
form
=
response
.
data
;
this
.
open
=
true
;
this
.
title
=
"修改生产领料单行"
;
});
},
/** 提交按钮 */
submitForm
()
{
this
.
$refs
[
"form"
].
validate
(
valid
=>
{
if
(
valid
)
{
if
(
this
.
form
.
lineId
!=
null
)
{
updateIssueline
(
this
.
form
).
then
(
response
=>
{
this
.
$modal
.
msgSuccess
(
"修改成功"
);
this
.
open
=
false
;
this
.
getList
();
});
}
else
{
addIssueline
(
this
.
form
).
then
(
response
=>
{
this
.
$modal
.
msgSuccess
(
"新增成功"
);
this
.
open
=
false
;
this
.
getList
();
});
}
}
});
},
/** 删除按钮操作 */
handleDelete
(
row
)
{
const
lineIds
=
row
.
lineId
||
this
.
ids
;
this
.
$modal
.
confirm
(
'是否确认删除生产领料单行编号为"'
+
lineIds
+
'"的数据项?'
).
then
(
function
()
{
return
delIssueline
(
lineIds
);
}).
then
(()
=>
{
this
.
getList
();
this
.
$modal
.
msgSuccess
(
"删除成功"
);
}).
catch
(()
=>
{});
},
handleSelectStock
(){
this
.
$refs
.
stockSelect
.
showFlag
=
true
;
this
.
$refs
.
stockSelect
.
getList
();
},
//物料选择弹出框
onStockSelected
(
obj
){
if
(
obj
!=
undefined
&&
obj
!=
null
){
this
.
form
.
materialStockId
=
obj
.
materialStockId
;
this
.
form
.
itemId
=
obj
.
itemId
;
this
.
form
.
itemCode
=
obj
.
itemCode
;
this
.
form
.
itemName
=
obj
.
itemName
;
this
.
form
.
specification
=
obj
.
specification
;
this
.
form
.
unitOfMeasure
=
obj
.
unitOfMeasure
;
this
.
form
.
batchCode
=
obj
.
batchCode
;
this
.
form
.
warehouseId
=
obj
.
warehouseId
;
this
.
form
.
warehouseCode
=
obj
.
warehouseCode
;
this
.
form
.
warehouseName
=
obj
.
warehouseName
;
this
.
form
.
locationId
=
obj
.
locationId
;
this
.
form
.
locationCode
=
obj
.
locationCode
;
this
.
form
.
locationName
=
obj
.
locationName
;
this
.
form
.
areaId
=
obj
.
areaId
;
this
.
form
.
areaCode
=
obj
.
areaCode
;
this
.
form
.
areaName
=
obj
.
areaName
;
this
.
form
.
quantityIssued
=
obj
.
quantityOnhand
;
this
.
form
.
quantityMax
=
obj
.
quantityOnhand
;
}
},
/** 导出按钮操作 */
handleExport
()
{
this
.
download
(
'wm/issueline/export'
,
{
...
this
.
queryParams
},
`issueline_
${
new
Date
().
getTime
()}
.xlsx`
)
}
}
};
</
script
>
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