Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
patzn-cloud-web-back-soil
Overview
Overview
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
wangweidong
patzn-cloud-web-back-soil
Commits
9f279cbe
Commit
9f279cbe
authored
Jun 14, 2020
by
wangweidong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
个人检测任务证书编制
parent
ada0b339
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
693 additions
and
79 deletions
+693
-79
index.js
api/index.js
+1
-0
meter-item.js
api/meter/meter-item.js
+34
-0
meter-sample.js
api/meter/meter-sample.js
+2
-3
MeterCertificateMake.vue
pages/meter-certificate/make/MeterCertificateMake.vue
+274
-0
MeterCertificateMakeHis.vue
pages/meter-certificate/make/MeterCertificateMakeHis.vue
+263
-0
MeterCertificateMakeIndex.vue
pages/meter-certificate/make/MeterCertificateMakeIndex.vue
+36
-0
MeterOutPersonalTask.vue
pages/meter-out/personal-task/MeterOutPersonalTask.vue
+10
-4
MeterPersonItemTaskManage.vue
pages/meter-out/personal-task/MeterPersonItemTaskManage.vue
+61
-72
meter-routes.js
router/meter-routes.js
+12
-0
No files found.
api/index.js
View file @
9f279cbe
...
@@ -29,4 +29,5 @@ export { default as meterManage } from './meter/meter-manage'
...
@@ -29,4 +29,5 @@ export { default as meterManage } from './meter/meter-manage'
export
{
default
as
meterEntrust
}
from
'./meter/meter-entrust'
export
{
default
as
meterEntrust
}
from
'./meter/meter-entrust'
export
{
default
as
meterSample
}
from
'./meter/meter-sample'
export
{
default
as
meterSample
}
from
'./meter/meter-sample'
export
{
default
as
meterManageItem
}
from
'./meter/meter-manage-item'
export
{
default
as
meterManageItem
}
from
'./meter/meter-manage-item'
export
{
default
as
meterItem
}
from
'./meter/meter-item'
export
{
default
as
lmsBaseDict
}
from
'./lims/lms-base-dict'
export
{
default
as
lmsBaseDict
}
from
'./lims/lms-base-dict'
api/meter/meter-item.js
0 → 100644
View file @
9f279cbe
/**
* 工作台
*/
import
http
from
'../http'
import
{
https
}
from
'../https'
export
default
{
// page
page
:
data
=>
http
.
post
(
'meter/v1/item/page'
,
data
).
then
(
res
=>
res
),
pageTest
:
data
=>
http
.
post
(
'meter/v1/item/page_test'
,
data
).
then
(
res
=>
res
),
// 个人任务
getById
:
data
=>
http
.
get
(
'meter/v1/item/'
+
data
).
then
(
res
=>
res
),
deleteById
:
data
=>
http
.
delete
(
'meter/v1/item/?ids='
+
data
).
then
(
res
=>
res
),
// 保存
save
:
data
=>
https
.
post
(
'meter/v1/item/add_send_entrust'
,
JSON
.
stringify
(
data
))
.
then
(
res
=>
res
),
testValue
:
data
=>
http
.
post
(
'meter/v1/item/bath_write_value/'
+
data
.
itemIds
,
data
)
.
then
(
res
=>
res
),
testEnd
:
data
=>
http
.
post
(
'meter/v1/item/bath_test_end?itemIds='
+
data
.
ids
+
'&sampleId='
+
data
.
sampleId
)
.
then
(
res
=>
res
)
}
api/meter/meter-sample.js
View file @
9f279cbe
...
@@ -8,15 +8,14 @@ import { https } from '../https'
...
@@ -8,15 +8,14 @@ import { https } from '../https'
export
default
{
export
default
{
// page
// page
page
:
data
=>
http
.
post
(
'meter/v1/sample/page'
,
data
).
then
(
res
=>
res
),
page
:
data
=>
http
.
post
(
'meter/v1/sample/page'
,
data
).
then
(
res
=>
res
),
// 个人任务
pagePersonTask
:
data
=>
http
.
post
(
'meter/v1/item/page'
,
data
).
then
(
res
=>
res
),
pageSubpackageSample
:
data
=>
pageSubpackageSample
:
data
=>
http
.
post
(
'meter/v1/sample/page_subpackage_sample'
,
data
).
then
(
res
=>
res
),
http
.
post
(
'meter/v1/sample/page_subpackage_sample'
,
data
).
then
(
res
=>
res
),
pageOutDistribute
:
data
=>
pageOutDistribute
:
data
=>
http
.
post
(
'meter/v1/sample/page_distribute'
,
data
).
then
(
res
=>
res
),
http
.
post
(
'meter/v1/sample/page_distribute'
,
data
).
then
(
res
=>
res
),
pageOutPersonalTask
:
data
=>
pageOutPersonalTask
:
data
=>
http
.
post
(
'meter/v1/sample/page_out_personal_task'
,
data
).
then
(
res
=>
res
),
http
.
post
(
'meter/v1/sample/page_out_personal_task'
,
data
).
then
(
res
=>
res
),
pageCertificateMake
:
data
=>
http
.
post
(
'meter/v1/sample/page_certificate_make'
,
data
).
then
(
res
=>
res
),
getById
:
data
=>
http
.
get
(
'meter/v1/sample/'
+
data
).
then
(
res
=>
res
),
getById
:
data
=>
http
.
get
(
'meter/v1/sample/'
+
data
).
then
(
res
=>
res
),
deleteById
:
data
=>
deleteById
:
data
=>
http
.
delete
(
'meter/v1/sample/?ids='
+
data
).
then
(
res
=>
res
),
http
.
delete
(
'meter/v1/sample/?ids='
+
data
).
then
(
res
=>
res
),
...
...
pages/meter-certificate/make/MeterCertificateMake.vue
0 → 100644
View file @
9f279cbe
<
template
>
<div>
<!--内容-->
<div
class=
"layout-content-padding"
>
<div
class=
"layout-content-main"
>
<Row>
<!--查询-->
<Col
span=
"24"
style=
"margin-top: 10px"
>
<Form
id=
"formId"
v-show=
"searchOpen"
:label-width=
"90"
inline
onsubmit=
"return false"
>
<label
class=
"label-sign"
></label>
<Form-item
class=
"search-item"
label=
"实验室名称:"
>
<Input
v-model=
"formObj.name"
@
on-enter=
"_formSearch"
name=
"name"
placeholder=
"请输入实验室名称"
clearable
/>
</Form-item>
<Form-item
class=
"search-item"
label=
"资质:"
>
<Input
v-model=
"formObj.aptitude"
@
on-enter=
"_formSearch"
name=
"aptitude"
placeholder=
"请输入资质"
clearable
/>
</Form-item>
<Form-item
class=
"search-btn"
>
<Button
@
click=
"_formSearch"
type=
"primary"
>
搜索
</Button>
</Form-item>
</Form>
</Col>
<!--操作-->
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
:open=
"searchOpen"
:show-search-btn=
"true"
@
on-result-change=
"_btnClick"
class=
"contHide"
></btn-list>
</Col>
<!--表格-->
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:table-height=
"tableHeight"
:form-id=
"formId"
:loading=
"true"
:get-page=
"getPage"
:icon-msg=
"iconMsg"
@
on-result-change=
"_tableResultChange"
>
<vxe-table-column
v-for=
"item in pageColumns"
:key=
"item.key"
:field=
"item.key"
:title=
"item.title"
:min-width=
"item.width?item.width:200"
:fixed=
"item.fixed?item.fixed:undefined"
sortable
>
<template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
[
item
.
key
]
}}
</span>
</
template
>
</vxe-table-column>
</PTVXETable>
</Col>
</Row>
</div>
</div>
</div>
</template>
<
script
>
import
{
meterSample
}
from
'../../../api'
export
default
{
components
:
{},
data
()
{
return
{
currentComponent
:
''
,
formId
:
'meterSubcontractorFormId'
,
searchOpen
:
false
,
btn
:
[
{
type
:
'success'
,
id
:
''
,
name
:
'仪器领用'
},
{
type
:
'success'
,
id
:
''
,
name
:
'车辆管理'
},
{
type
:
'success'
,
id
:
''
,
name
:
'提交'
}
],
iconMsg
:
[
{
type
:
'md-create'
,
id
:
''
,
name
:
'编辑'
},
{
type
:
'md-car'
,
id
:
''
,
name
:
'车辆管理'
},
{
type
:
'ios-list-box'
,
id
:
''
,
name
:
'仪器领用'
},
{
type
:
'md-cloud'
,
id
:
''
,
name
:
'附件'
},
{
type
:
'md-remove-circle'
,
id
:
''
,
name
:
'删除'
},
{
type
:
'ios-clock'
,
id
:
''
,
name
:
'操作日志'
}
],
formObj
:
{
name
:
undefined
,
aptitude
:
undefined
},
selectIds
:
[],
getPage
:
{},
pageColumns
:
[
{
title
:
'样品名称'
,
key
:
'name'
,
width
:
120
},
{
title
:
'样品编号'
,
key
:
'code'
,
width
:
120
},
{
title
:
'型号规格'
,
key
:
'spec'
},
{
title
:
'出厂编号'
,
key
:
'factoryNumber'
},
{
title
:
'检测类型'
,
key
:
'type'
},
{
title
:
'委托单位'
,
key
:
'client'
,
width
:
200
},
{
title
:
'联系人'
,
key
:
'person'
,
width
:
120
},
{
title
:
'联系电话'
,
key
:
'tel'
,
width
:
120
},
{
title
:
'详细地址'
,
key
:
'address'
,
width
:
250
},
{
title
:
'数量'
,
key
:
'quantity'
},
{
title
:
'备注'
,
key
:
'remark'
}
]
}
},
computed
:
{
tableHeight
:
function
()
{
if
(
this
.
searchOpen
)
{
return
this
.
$tableHeight
(
'search'
)
}
else
{
return
this
.
$tableHeight
(
'noSearch'
)
}
}
},
mounted
()
{
this
.
_page
()
},
methods
:
{
_modalResult
()
{
if
(
this
.
currentComponent
===
'FoodSubcontracterEdit'
)
{
this
.
_page
()
}
},
_btnClick
(
msg
,
componentName
)
{
this
.
currentComponent
=
componentName
this
.
$nextTick
(
function
()
{
switch
(
msg
)
{
case
'添加'
:
this
.
_editModal
(
false
)
break
case
'提交'
:
this
.
_submitToReview
()
break
case
'search'
:
this
.
searchOpen
=
!
this
.
searchOpen
break
}
})
},
_submitToReview
()
{
this
.
_submitByContractIds
(
'委托评审'
)
},
_submitByContractIds
(
cont
)
{
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
'确定要把这 '
+
ids
.
length
+
' 条记录提交到'
+
cont
+
'?'
,
onOk
:
()
=>
{
const
result
=
meterSample
.
submit
(
ids
)
if
(
result
)
{
console
.
log
(
result
)
}
}
})
}
},
_iconClick
(
res
,
data
,
componentName
)
{
this
.
currentComponent
=
componentName
this
.
$nextTick
(
function
()
{
switch
(
res
)
{
case
'编辑'
:
// this._editModal(true, data.id)
this
.
_personModal
(
data
)
break
case
'资质项目'
:
this
.
_itemModal
(
data
.
id
)
break
case
'附件'
:
this
.
_upload
(
data
.
id
)
break
case
'删除'
:
this
.
_deleteByIds
([
data
.
id
])
break
case
'操作日志'
:
this
.
_record
(
data
.
id
)
break
}
})
},
_personModal
(
data
)
{
console
.
log
(
data
)
this
.
$refs
.
personModal
.
_open
(
data
.
id
)
},
_record
(
id
)
{
this
.
$refs
.
refModal
.
_open
(
id
)
},
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'iconClick'
:
this
.
_iconClick
(
data
.
name
,
data
.
rowData
,
data
.
componentName
)
break
case
'selectIds'
:
this
.
selectIds
=
data
break
case
'changeSize'
:
this
.
_page
()
break
}
},
_page
:
async
function
()
{
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
console
.
log
(
'this.formObj'
,
this
.
formObj
)
const
result
=
await
meterSample
.
pageCertificateMake
(
this
.
formObj
)
if
(
result
)
{
this
.
$refs
.
pageTable
.
_hideLoading
()
this
.
getPage
=
result
}
},
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
},
// 删除
_deleteByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
'确定删除该记录?'
,
onOk
:
()
=>
{
this
.
_delete
(
ids
)
}
})
},
// 编辑&添加
_editModal
(
edit
,
id
)
{
if
(
edit
)
{
// 编辑
this
.
_getById
(
id
)
}
else
{
// 添加
this
.
$refs
.
editSubcontractorModal
.
_open
()
}
},
// 追加项目
_itemModal
(
data
)
{
this
.
$refs
.
refModal
.
_open
(
data
)
},
_upload
(
id
)
{
// 上传文件
this
.
$refs
.
refModal
.
_open
(
id
,
'subcontractorId'
)
},
_getById
:
async
function
(
id
)
{
const
result
=
await
meterSample
.
getById
(
id
)
if
(
result
)
{
this
.
$refs
.
editSubcontractorModal
.
_openEdit
(
result
)
}
},
_delete
:
async
function
(
ids
)
{
const
result
=
await
meterSample
.
deleteById
(
ids
)
if
(
result
)
{
this
.
_formSearch
()
this
.
$Message
.
success
(
'删除成功!'
)
}
}
}
}
</
script
>
pages/meter-certificate/make/MeterCertificateMakeHis.vue
0 → 100644
View file @
9f279cbe
<
template
>
<div>
<!--内容-->
<div
class=
"layout-content-padding"
>
<div
class=
"layout-content-main"
>
<Row>
<!--查询-->
<Col
span=
"24"
style=
"margin-top: 10px"
>
<Form
id=
"formId"
v-show=
"searchOpen"
:label-width=
"90"
inline
onsubmit=
"return false"
>
<label
class=
"label-sign"
></label>
<Form-item
class=
"search-item"
label=
"实验室名称:"
>
<Input
v-model=
"formObj.name"
@
on-enter=
"_formSearch"
name=
"name"
placeholder=
"请输入实验室名称"
clearable
/>
</Form-item>
<Form-item
class=
"search-item"
label=
"资质:"
>
<Input
v-model=
"formObj.aptitude"
@
on-enter=
"_formSearch"
name=
"aptitude"
placeholder=
"请输入资质"
clearable
/>
</Form-item>
<Form-item
class=
"search-btn"
>
<Button
@
click=
"_formSearch"
type=
"primary"
>
搜索
</Button>
</Form-item>
</Form>
</Col>
<!--操作-->
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
:open=
"searchOpen"
:show-search-btn=
"true"
@
on-result-change=
"_btnClick"
class=
"contHide"
></btn-list>
</Col>
<!--表格-->
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:table-height=
"tableHeight"
:form-id=
"formId"
:loading=
"true"
:get-page=
"getPage"
:icon-msg=
"iconMsg"
@
on-result-change=
"_tableResultChange"
>
<vxe-table-column
v-for=
"item in pageColumns"
:key=
"item.key"
:field=
"item.key"
:title=
"item.title"
:min-width=
"item.width?item.width:200"
:fixed=
"item.fixed?item.fixed:undefined"
sortable
>
<template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
[
item
.
key
]
}}
</span>
</
template
>
</vxe-table-column>
</PTVXETable>
</Col>
</Row>
</div>
</div>
</div>
</template>
<
script
>
import
{
meterEntrust
}
from
'../../../api'
export
default
{
components
:
{},
data
()
{
return
{
currentComponent
:
''
,
formId
:
'meterSubcontractorFormId'
,
searchOpen
:
false
,
btn
:
[
{
type
:
'success'
,
id
:
'meter-go-out-entrust-add-btn'
,
name
:
'添加'
},
{
type
:
'success'
,
id
:
'meter-go-out-entrust-submit-btn'
,
name
:
'提交'
}
],
iconMsg
:
[
{
type
:
'md-create'
,
id
:
''
,
name
:
'编辑'
},
{
type
:
'ios-beaker'
,
id
:
''
,
name
:
'管理样品'
},
{
type
:
'md-cloud'
,
id
:
''
,
name
:
'附件'
},
{
type
:
'md-remove-circle'
,
id
:
''
,
name
:
'删除'
},
{
type
:
'ios-clock'
,
id
:
''
,
name
:
'操作日志'
}
],
formObj
:
{
name
:
undefined
,
aptitude
:
undefined
},
selectIds
:
[],
getPage
:
{},
pageColumns
:
[
{
title
:
'委托单位'
,
key
:
'client'
,
width
:
200
},
{
title
:
'联系人'
,
key
:
'person'
,
width
:
120
},
{
title
:
'联系电话'
,
key
:
'tel'
,
width
:
120
},
{
title
:
'传真'
,
key
:
'fax'
,
width
:
120
},
{
title
:
'详细地址'
,
key
:
'address'
,
width
:
250
},
{
title
:
'邮编'
,
key
:
'postcode'
},
{
title
:
'E-mail'
,
key
:
'email'
,
width
:
120
},
{
title
:
'委托日期'
,
key
:
'edate'
,
width
:
120
},
{
title
:
'费用合计'
,
key
:
'fee'
,
width
:
120
},
{
title
:
'合同号'
,
key
:
'contractCode'
,
width
:
120
},
{
title
:
'备注'
,
key
:
'remark'
}
]
}
},
computed
:
{
tableHeight
:
function
()
{
if
(
this
.
searchOpen
)
{
return
this
.
$tableHeight
(
'search'
)
}
else
{
return
this
.
$tableHeight
(
'noSearch'
)
}
}
},
mounted
()
{
this
.
_page
()
},
methods
:
{
_modalResult
()
{
if
(
this
.
currentComponent
===
'FoodSubcontracterEdit'
)
{
this
.
_page
()
}
},
_btnClick
(
msg
,
componentName
)
{
this
.
currentComponent
=
componentName
this
.
$nextTick
(
function
()
{
switch
(
msg
)
{
case
'添加'
:
this
.
_editModal
(
false
)
break
case
'提交'
:
this
.
_submitToReview
()
break
case
'search'
:
this
.
searchOpen
=
!
this
.
searchOpen
break
}
})
},
_submitToReview
()
{
this
.
_submitByContractIds
(
'委托评审'
)
},
_submitByContractIds
(
cont
)
{
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
'确定要把这 '
+
ids
.
length
+
' 条记录提交到'
+
cont
+
'?'
,
onOk
:
()
=>
{
const
result
=
meterEntrust
.
submit
(
ids
)
if
(
result
)
{
console
.
log
(
result
)
}
}
})
}
},
_iconClick
(
res
,
data
,
componentName
)
{
this
.
currentComponent
=
componentName
this
.
$nextTick
(
function
()
{
switch
(
res
)
{
case
'编辑'
:
this
.
_editModal
(
true
,
data
.
id
)
break
case
'资质项目'
:
this
.
_itemModal
(
data
.
id
)
break
case
'附件'
:
this
.
_upload
(
data
.
id
)
break
case
'删除'
:
this
.
_deleteByIds
([
data
.
id
])
break
case
'操作日志'
:
this
.
_record
(
data
.
id
)
break
}
})
},
_record
(
id
)
{
this
.
$refs
.
refModal
.
_open
(
id
)
},
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'page'
:
this
.
getPage
=
this
.
$store
.
state
.
FoodSubcontracter
.
page
break
case
'iconClick'
:
this
.
_iconClick
(
data
.
name
,
data
.
rowData
,
data
.
componentName
)
break
case
'selectIds'
:
this
.
selectIds
=
data
break
case
'changeSize'
:
this
.
_page
()
break
}
},
_page
:
async
function
()
{
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
console
.
log
(
'this.formObj'
,
this
.
formObj
)
const
result
=
await
meterEntrust
.
pageGoOutEntrust
(
this
.
formObj
)
if
(
result
)
{
this
.
$refs
.
pageTable
.
_hideLoading
()
this
.
getPage
=
result
}
},
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
},
// 删除
_deleteByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
'确定删除该记录?'
,
onOk
:
()
=>
{
this
.
_delete
(
ids
)
}
})
},
// 编辑&添加
_editModal
(
edit
,
id
)
{
if
(
edit
)
{
// 编辑
this
.
_getById
(
id
)
}
else
{
// 添加
this
.
$refs
.
editSubcontractorModal
.
_open
()
}
},
// 追加项目
_itemModal
(
data
)
{
this
.
$refs
.
refModal
.
_open
(
data
)
},
_upload
(
id
)
{
// 上传文件
this
.
$refs
.
refModal
.
_open
(
id
,
'subcontractorId'
)
},
_getById
:
async
function
(
id
)
{
const
result
=
await
meterEntrust
.
getVOById
(
id
)
if
(
result
)
{
this
.
$refs
.
editSubcontractorModal
.
_openEdit
(
result
)
}
},
_delete
:
async
function
(
ids
)
{
const
result
=
await
meterEntrust
.
deleteById
(
ids
)
if
(
result
)
{
this
.
_formSearch
()
this
.
$Message
.
success
(
'删除成功!'
)
}
}
}
}
</
script
>
pages/meter-certificate/make/MeterCertificateMakeIndex.vue
0 → 100644
View file @
9f279cbe
<
template
>
<div>
<div
class=
"layout-content-padding"
>
<div
class=
"layout-content-main"
>
<el-tabs
v-model=
"activeName"
>
<el-tab-pane
label=
"待完成"
name=
"wait"
>
<MeterGoOutEntrust
ref=
"waitTabs"
></MeterGoOutEntrust>
</el-tab-pane>
<el-tab-pane
label=
"历史记录"
name=
"his"
>
<MeterGoOutEntrustHis
ref=
"hisTabs"
></MeterGoOutEntrustHis>
</el-tab-pane>
</el-tabs>
</div>
</div>
</div>
</
template
>
<
script
>
import
MeterGoOutEntrust
from
'./MeterCertificateMake'
import
MeterGoOutEntrustHis
from
'./MeterCertificateMakeHis'
export
default
{
name
:
'MeterGoOutEntrustIndex'
,
components
:
{
MeterGoOutEntrust
,
MeterGoOutEntrustHis
},
data
()
{
return
{
activeName
:
'wait'
}
}
}
</
script
>
<
style
scoped
>
</
style
>
pages/meter-out/personal-task/MeterOutPersonalTask.vue
View file @
9f279cbe
...
@@ -45,16 +45,16 @@
...
@@ -45,16 +45,16 @@
</Row>
</Row>
</div>
</div>
</div>
</div>
<MeterPerson
SampleManage
ref=
"personModal"
></MeterPersonSample
Manage>
<MeterPerson
ItemTaskManage
ref=
"personModal"
></MeterPersonItemTask
Manage>
<MeterSubcontractorEdit
ref=
"editSubcontractorModal"
@
on-result-change=
"_formSearch"
></MeterSubcontractorEdit>
<MeterSubcontractorEdit
ref=
"editSubcontractorModal"
@
on-result-change=
"_formSearch"
></MeterSubcontractorEdit>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
{
meterSample
}
from
'../../../api'
import
{
meterSample
}
from
'../../../api'
import
MeterSubcontractorEdit
from
'./MeterGoOutTestEdit'
import
MeterSubcontractorEdit
from
'./MeterGoOutTestEdit'
import
MeterPerson
SampleManage
from
'./MeterPersonSample
Manage'
import
MeterPerson
ItemTaskManage
from
'./MeterPersonItemTask
Manage'
export
default
{
export
default
{
components
:
{
MeterSubcontractorEdit
,
MeterPerson
Sample
Manage
},
components
:
{
MeterSubcontractorEdit
,
MeterPerson
ItemTask
Manage
},
data
()
{
data
()
{
return
{
return
{
currentComponent
:
''
,
currentComponent
:
''
,
...
@@ -70,6 +70,11 @@ export default {
...
@@ -70,6 +70,11 @@ export default {
type
:
'success'
,
type
:
'success'
,
id
:
''
,
id
:
''
,
name
:
'车辆管理'
name
:
'车辆管理'
},
{
type
:
'success'
,
id
:
''
,
name
:
'提交'
}
}
],
],
iconMsg
:
[
iconMsg
:
[
...
@@ -103,7 +108,8 @@ export default {
...
@@ -103,7 +108,8 @@ export default {
selectIds
:
[],
selectIds
:
[],
getPage
:
{},
getPage
:
{},
pageColumns
:
[
pageColumns
:
[
{
title
:
'样品名称'
,
key
:
'name'
,
width
:
160
},
{
title
:
'样品名称'
,
key
:
'name'
,
width
:
120
},
{
title
:
'样品编号'
,
key
:
'code'
,
width
:
120
},
{
title
:
'型号规格'
,
key
:
'spec'
},
{
title
:
'型号规格'
,
key
:
'spec'
},
{
title
:
'出厂编号'
,
key
:
'factoryNumber'
},
{
title
:
'出厂编号'
,
key
:
'factoryNumber'
},
{
title
:
'检测类型'
,
key
:
'type'
},
{
title
:
'检测类型'
,
key
:
'type'
},
...
...
pages/meter-out/personal-task/MeterPerson
Sample
Manage.vue
→
pages/meter-out/personal-task/MeterPerson
ItemTask
Manage.vue
View file @
9f279cbe
...
@@ -10,24 +10,24 @@
...
@@ -10,24 +10,24 @@
<Form
id=
"formId"
:label-width=
"80"
inline
onsubmit=
"return false"
>
<Form
id=
"formId"
:label-width=
"80"
inline
onsubmit=
"return false"
>
<label
class=
"label-sign"
></label>
<label
class=
"label-sign"
></label>
<Form-item
label=
"样品名称:"
class=
"search-item"
>
<Form-item
label=
"样品名称:"
class=
"search-item"
>
<Input
v-model=
"formObj.name"
@
on-enter=
"_formSearch"
placeholder=
"请输入样品名称"
clearable
/>
<Input
v-model=
"formObj.name"
placeholder=
"请输入样品名称"
clearable
@
on-enter=
"_formSearch"
/>
</Form-item>
</Form-item>
<Form-item
label=
"样品编号:"
class=
"search-item"
>
<Form-item
label=
"样品编号:"
class=
"search-item"
>
<Input
v-model=
"formObj.code"
@
on-enter=
"_formSearch"
placeholder=
"请输入样品编号"
clearable
/>
<Input
v-model=
"formObj.code"
placeholder=
"请输入样品编号"
clearable
@
on-enter=
"_formSearch"
/>
</Form-item>
</Form-item>
<Form-item
class=
"search-btn"
style=
"margin-left: -10px"
>
<Form-item
class=
"search-btn"
style=
"margin-left: -10px"
>
<Button
@
click=
"_formSearch"
type=
"primary
"
>
搜索
</Button>
<Button
type=
"primary"
@
click=
"_formSearch
"
>
搜索
</Button>
</Form-item>
</Form-item>
</Form>
</Form>
</Col>
</Col>
<Col
span=
"24"
>
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
:open=
"searchOpen"
:show-search-btn=
"true"
@
on-result-change=
"_btnClick
"
<btn-list
:msg=
"btn"
:open=
"searchOpen"
:show-search-btn=
"true"
class=
"contHide
"
class=
"contHide
"
></btn-list>
@
on-result-change=
"_btnClick
"
></btn-list>
</Col>
</Col>
<Col
span=
"24"
>
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:table-height=
"tableHeight"
:form-id=
"formId"
:get-page=
"getPage"
<PTVXETable
ref=
"pageTable"
:table-height=
"tableHeight"
:form-id=
"formId"
:get-page=
"getPage"
:icon-msg=
"iconMsg"
@
on-result-change=
"_tableResultChange"
select-data
>
:icon-msg=
"iconMsg"
select-data
@
on-result-change=
"_tableResultChange"
>
<vxe-table-column
<vxe-table-column
v-for=
"item in pageColumns"
v-for=
"item in pageColumns"
:key=
"item.key"
:key=
"item.key"
...
@@ -42,6 +42,17 @@
...
@@ -42,6 +42,17 @@
<div
v-else-if=
"item.key==='jobOut'"
>
<div
v-else-if=
"item.key==='jobOut'"
>
{{
scope
.
row
[
item
.
key
]
===
1
?
'是'
:
'否'
}}
{{
scope
.
row
[
item
.
key
]
===
1
?
'是'
:
'否'
}}
</div>
</div>
<span
v-else-if=
"item.key==='singleJudge'"
>
{{
scope
.
row
[
item
.
key
]
===
undefined
?
''
:
scope
.
row
[
item
.
key
].
display
}}
</span>
<div
v-else-if=
"item.key==='testValue'"
>
<el-input
v-model=
"scope.row.testValue"
size=
"medium"
placeholder=
"请输入检测结果"
@
blur=
"_handleTestValueEdit(scope.row.id,scope.row.testValue)"
/>
</div>
<div
v-else-if=
"item.key==='progress'"
>
<div
v-else-if=
"item.key==='progress'"
>
{{
scope
.
row
.
progress
.
display
}}
{{
scope
.
row
.
progress
.
display
}}
</div>
</div>
...
@@ -56,7 +67,7 @@
...
@@ -56,7 +67,7 @@
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
{
meter
Sample
}
from
'../../../api'
import
{
meter
Item
}
from
'../../../api'
export
default
{
export
default
{
components
:
{
components
:
{
// FoodSampleGovernDetail,
// FoodSampleGovernDetail,
...
@@ -85,13 +96,18 @@ export default {
...
@@ -85,13 +96,18 @@ export default {
// meter-review-entrust-pass-btn
// meter-review-entrust-pass-btn
type
:
'success'
,
type
:
'success'
,
id
:
''
,
id
:
''
,
name
:
'
分包
'
name
:
'
完成
'
},
},
// meter-review-entrust-back-btn
// meter-review-entrust-back-btn
{
{
type
:
'success'
,
type
:
'success'
,
id
:
''
,
id
:
''
,
name
:
'取消分包'
name
:
'填写检测值'
},
{
type
:
'success'
,
id
:
''
,
name
:
'判定'
}
}
],
],
options
:
[
options
:
[
...
@@ -129,6 +145,7 @@ export default {
...
@@ -129,6 +145,7 @@ export default {
{
title
:
'比较符'
,
key
:
'compare'
,
width
:
100
},
{
title
:
'比较符'
,
key
:
'compare'
,
width
:
100
},
{
title
:
'限量值'
,
key
:
'limitValue'
,
width
:
140
},
{
title
:
'限量值'
,
key
:
'limitValue'
,
width
:
140
},
{
title
:
'检测值'
,
key
:
'testValue'
,
width
:
140
},
{
title
:
'检测值'
,
key
:
'testValue'
,
width
:
140
},
{
title
:
'单项判定'
,
key
:
'singleJudge'
,
width
:
140
},
{
title
:
'进度'
,
key
:
'progress'
,
width
:
110
}
{
title
:
'进度'
,
key
:
'progress'
,
width
:
110
}
],
],
dateList
:
[],
dateList
:
[],
...
@@ -167,8 +184,8 @@ export default {
...
@@ -167,8 +184,8 @@ export default {
this
.
currentComponent
=
componentName
this
.
currentComponent
=
componentName
this
.
$nextTick
(
function
()
{
this
.
$nextTick
(
function
()
{
switch
(
msg
)
{
switch
(
msg
)
{
case
'
分包
'
:
case
'
完成
'
:
this
.
_
subpackageSample
()
this
.
_
testEnd
()
break
break
case
'导入检测项目'
:
case
'导入检测项目'
:
this
.
_importItem
()
this
.
_importItem
()
...
@@ -232,13 +249,30 @@ export default {
...
@@ -232,13 +249,30 @@ export default {
this
.
showModal
=
true
this
.
showModal
=
true
this
.
_page
()
this
.
_page
()
},
},
_testEnd
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
success
(
'请选择完成检测的项目'
)
return
false
}
this
.
_testItemEnd
(
this
.
selectIds
)
},
_testItemEnd
:
async
function
()
{
const
result
=
await
meterItem
.
testEnd
({
ids
:
this
.
selectIds
,
sampleId
:
this
.
formObj
.
sampleId
})
if
(
result
)
{
await
this
.
_page
()
}
},
_formSearch
()
{
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
},
},
_page
:
async
function
()
{
_page
:
async
function
()
{
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
console
.
log
(
'this.formObj'
,
this
.
formObj
)
console
.
log
(
'this.formObj'
,
this
.
formObj
)
const
result
=
await
meter
Sample
.
pagePersonTask
(
this
.
formObj
)
const
result
=
await
meter
Item
.
pageTest
(
this
.
formObj
)
console
.
log
(
'result'
,
result
)
console
.
log
(
'result'
,
result
)
if
(
result
)
{
if
(
result
)
{
this
.
getPage
=
result
this
.
getPage
=
result
...
@@ -320,59 +354,6 @@ export default {
...
@@ -320,59 +354,6 @@ export default {
_copy
(
sampleId
,
type
)
{
_copy
(
sampleId
,
type
)
{
this
.
$refs
.
refModal
.
_open
(
sampleId
,
type
)
this
.
$refs
.
refModal
.
_open
(
sampleId
,
type
)
},
},
// 复制样品
_copySample
(
data
)
{
if
(
data
.
type
===
2
)
{
// 粮油的编辑页
this
.
currentComponent
=
'FoodSampleGovernLYEdit'
this
.
$store
.
dispatch
(
'FoodSample/getByGovernId'
,
data
.
sampleId
)
.
then
(()
=>
{
this
.
$nextTick
(
function
()
{
this
.
$refs
.
refModal
.
_openCopySample
(
this
.
$store
.
state
.
FoodSample
.
governModel
)
})
})
}
else
{
this
.
currentComponent
=
'FoodSampleGovernEdit'
this
.
$store
.
dispatch
(
'FoodSample/getByGovernId'
,
data
.
sampleId
)
.
then
(()
=>
{
this
.
$nextTick
(
function
()
{
this
.
$refs
.
refModal
.
_openCopySample
(
this
.
$store
.
state
.
FoodSample
.
governModel
)
})
})
}
},
_copyAll
(
data
)
{
if
(
data
.
type
===
2
)
{
// 粮油的编辑页
this
.
currentComponent
=
'FoodSampleGovernLYEdit'
this
.
$store
.
dispatch
(
'FoodSample/getByGovernId'
,
data
.
sampleId
)
.
then
(()
=>
{
this
.
$nextTick
(
function
()
{
this
.
$refs
.
refModal
.
_openCopyAll
(
this
.
$store
.
state
.
FoodSample
.
governModel
)
})
})
}
else
{
this
.
currentComponent
=
'FoodSampleGovernEdit'
this
.
$store
.
dispatch
(
'FoodSample/getByGovernId'
,
data
.
sampleId
)
.
then
(()
=>
{
this
.
$nextTick
(
function
()
{
this
.
$refs
.
refModal
.
_openCopyAll
(
this
.
$store
.
state
.
FoodSample
.
governModel
)
})
})
}
},
// 导入样品
// 导入样品
_importSample
()
{
_importSample
()
{
const
data
=
{
const
data
=
{
...
@@ -408,13 +389,6 @@ export default {
...
@@ -408,13 +389,6 @@ export default {
this
.
_subpackage
(
this
.
selectIds
)
this
.
_subpackage
(
this
.
selectIds
)
}
}
},
},
_subpackage
:
async
function
(
ids
)
{
const
result
=
await
meterSample
.
subpackageSample
(
ids
)
if
(
result
)
{
this
.
$Message
.
success
(
'分包成功!'
)
await
this
.
_page
()
}
},
_importItemPackage
()
{
_importItemPackage
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
if
(
this
.
selectIds
.
length
===
0
)
{
...
@@ -436,6 +410,21 @@ export default {
...
@@ -436,6 +410,21 @@ export default {
_operationRecord
(
id
)
{
_operationRecord
(
id
)
{
// 操作日志
// 操作日志
this
.
$refs
.
recordModal
.
_open
(
id
)
this
.
$refs
.
recordModal
.
_open
(
id
)
},
// 单个填写检测值
_handleTestValueEdit
:
async
function
(
id
,
testValue
)
{
if
(
testValue
!==
''
&&
undefined
!==
testValue
)
{
const
data
=
{}
data
.
itemIds
=
id
data
.
testValue
=
testValue
const
result
=
await
meterItem
.
testValue
(
data
)
if
(
result
)
{
this
.
$Message
.
success
(
'保存成功'
)
await
this
.
_page
()
}
else
{
this
.
$Message
.
error
(
'保存失败'
)
}
}
}
}
}
}
}
}
...
...
router/meter-routes.js
View file @
9f279cbe
...
@@ -16,6 +16,7 @@ import MeterReviewEntrust from '../pages/meter-review/MeterReviewEntrust'
...
@@ -16,6 +16,7 @@ import MeterReviewEntrust from '../pages/meter-review/MeterReviewEntrust'
import
MeterSubpackageTaskIndex
from
'../pages/meter-subcontract/subpackage-task/MeterSubpackageTaskIndex'
import
MeterSubpackageTaskIndex
from
'../pages/meter-subcontract/subpackage-task/MeterSubpackageTaskIndex'
import
MeterOutTaskDistributeIndex
from
'../pages/meter-out/task-distribute/MeterOutTaskDistributeIndex'
import
MeterOutTaskDistributeIndex
from
'../pages/meter-out/task-distribute/MeterOutTaskDistributeIndex'
import
MeterOutPersonalTaskIndex
from
'../pages/meter-out/personal-task/MeterOutPersonalTaskIndex'
import
MeterOutPersonalTaskIndex
from
'../pages/meter-out/personal-task/MeterOutPersonalTaskIndex'
import
MeterCertificateMakeIndex
from
'../pages/meter-certificate/make/MeterCertificateMakeIndex'
import
Blank
from
'~/pages/blank'
import
Blank
from
'~/pages/blank'
export
default
[
export
default
[
{
{
...
@@ -91,5 +92,16 @@ export default [
...
@@ -91,5 +92,16 @@ export default [
meta
:
{
title
:
'个人检测任务'
}
meta
:
{
title
:
'个人检测任务'
}
}
}
]
]
},
{
path
:
'certificate'
,
component
:
Blank
,
children
:
[
{
path
:
'certificate_make'
,
component
:
MeterCertificateMakeIndex
,
meta
:
{
title
:
'证书编制'
}
}
]
}
}
]
]
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