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
24f72b77
Commit
24f72b77
authored
Oct 09, 2020
by
wangweidong
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/dev' into dev
parents
e707313b
c2c17d7e
Hide whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
1884 additions
and
76 deletions
+1884
-76
soil-statistics.js
api/soil/soil-statistics.js
+6
-28
soil-test.js
api/soil/soil-test.js
+37
-1
ReportAuditIndex.vue
pages/soil-report-manage/report-audit/ReportAuditIndex.vue
+47
-0
historyTask.vue
pages/soil-report-manage/report-audit/tabs/historyTask.vue
+374
-0
reportAudit.vue
pages/soil-report-manage/report-audit/tabs/reportAudit.vue
+398
-0
ReportIssueIndex.vue
pages/soil-report-manage/report-issue/ReportIssueIndex.vue
+47
-0
historyTask.vue
pages/soil-report-manage/report-issue/tabs/historyTask.vue
+399
-0
reportIssue.vue
pages/soil-report-manage/report-issue/tabs/reportIssue.vue
+409
-0
ReportInfoMake.vue
pages/soil-report-manage/report-make/tabs/ReportInfoMake.vue
+2
-11
ReportMakeByEntrust.vue
...il-report-manage/report-make/tabs/ReportMakeByEntrust.vue
+20
-28
DataAudit.vue
pages/soil-test-manage/test-data-audit/DataAudit.vue
+1
-1
ItemLeftList.vue
...il-test-manage/test-data-audit/item-tabs/ItemLeftList.vue
+1
-1
ItemRightList.vue
...l-test-manage/test-data-audit/item-tabs/ItemRightList.vue
+52
-2
DataCheck.vue
pages/soil-test-manage/test-data-check/DataCheck.vue
+1
-1
ItemLeftList.vue
...il-test-manage/test-data-check/item-tabs/ItemLeftList.vue
+1
-1
ItemRightList.vue
...l-test-manage/test-data-check/item-tabs/ItemRightList.vue
+51
-1
ItemRightList.vue
...s/soil-test-manage/test-input/item-tabs/ItemRightList.vue
+26
-1
soil-routes.js
router/soil-routes.js
+12
-0
No files found.
api/soil/soil-statistics.js
View file @
24f72b77
...
@@ -7,32 +7,10 @@ import http from '../http'
...
@@ -7,32 +7,10 @@ import http from '../http'
export
default
{
export
default
{
// 检测依据管理
// 检测依据管理
standardPage
:
data
=>
pageReportMake
:
data
=>
http
.
post
(
'soil/v1/standard/page'
,
data
).
then
(
res
=>
res
),
http
.
post
(
'soil/v1/entrust/page_report_make'
,
data
).
then
(
res
=>
res
),
standardGetById
:
data
=>
pageReportCheck
:
data
=>
http
.
get
(
'soil/v1/standard/'
+
data
).
then
(
res
=>
res
),
http
.
post
(
'soil/v1/entrust/page_report_check'
,
data
).
then
(
res
=>
res
),
standardSave
:
data
=>
http
.
post
(
'soil/v1/standard/'
,
data
).
then
(
res
=>
res
),
pageReportIssue
:
data
=>
standardEdit
:
data
=>
http
.
post
(
'soil/v1/entrust/page_report_issue'
,
data
).
then
(
res
=>
res
)
http
.
put
(
'soil/v1/standard/'
+
data
.
id
,
data
.
obj
).
then
(
res
=>
res
),
standardDeleteById
:
data
=>
http
.
delete
(
'soil/v1/standard/?ids='
+
data
).
then
(
res
=>
res
),
// 试验项目
// page
page
:
data
=>
http
.
post
(
'soil/v1/aptitude_exp/page'
,
data
).
then
(
res
=>
res
),
getById
:
data
=>
http
.
get
(
'soil/v1/aptitude_exp/'
+
data
).
then
(
res
=>
res
),
deleteById
:
data
=>
http
.
delete
(
'soil/v1/aptitude_exp/?ids='
+
data
).
then
(
res
=>
res
),
// 保存
save
:
data
=>
http
.
post
(
'soil/v1/aptitude_exp/'
,
data
).
then
(
res
=>
res
),
edit
:
data
=>
http
.
put
(
'soil/v1/aptitude_exp/'
+
data
.
id
,
data
.
obj
).
then
(
res
=>
res
),
// 指标页面
expItemPage
:
data
=>
http
.
post
(
'soil/v1/exp_item/page'
,
data
).
then
(
res
=>
res
),
expItemDeleteByIds
:
data
=>
http
.
delete
(
'soil/v1/exp_item/?ids='
+
data
).
then
(
res
=>
res
),
expItemSave
:
data
=>
http
.
post
(
'soil/v1/exp_item/'
,
data
).
then
(
res
=>
res
),
expItemEdit
:
data
=>
http
.
put
(
'soil/v1/exp_item/'
+
data
.
id
,
data
.
obj
).
then
(
res
=>
res
),
expItemGetById
:
data
=>
http
.
get
(
'soil/v1/exp_item/'
+
data
).
then
(
res
=>
res
)
}
}
api/soil/soil-test.js
View file @
24f72b77
...
@@ -61,5 +61,41 @@ export default {
...
@@ -61,5 +61,41 @@ export default {
itemSave
:
data
=>
http
.
post
(
'soil/v1/item/'
,
data
).
then
(
res
=>
res
),
itemSave
:
data
=>
http
.
post
(
'soil/v1/item/'
,
data
).
then
(
res
=>
res
),
itemEdit
:
data
=>
itemEdit
:
data
=>
http
.
put
(
'soil/v1/item/'
+
data
.
id
,
data
.
obj
).
then
(
res
=>
res
),
http
.
put
(
'soil/v1/item/'
+
data
.
id
,
data
.
obj
).
then
(
res
=>
res
),
itemGetById
:
data
=>
http
.
get
(
'soil/v1/item/'
+
data
).
then
(
res
=>
res
)
itemGetById
:
data
=>
http
.
get
(
'soil/v1/item/'
+
data
).
then
(
res
=>
res
),
endExp
:
data
=>
http
.
post
(
'soil/v1/experiment/end_exp?ids='
+
data
).
then
(
res
=>
res
),
pageExpCheck
:
data
=>
http
.
post
(
'soil/v1/entrust/page_exp_check'
,
data
).
then
(
res
=>
res
),
endExpCheck
:
data
=>
http
.
post
(
'soil/v1/experiment/end_exp_check?ids='
+
data
).
then
(
res
=>
res
),
endExpAudit
:
data
=>
http
.
post
(
'soil/v1/experiment/end_exp_audit?ids='
+
data
).
then
(
res
=>
res
),
pageCheckByExp
:
data
=>
http
.
post
(
'soil/v1/experiment/page_check_by_exp'
,
data
).
then
(
res
=>
res
),
pageExpByCheck
:
data
=>
http
.
post
(
'soil/v1/experiment/page_exp_check'
,
data
).
then
(
res
=>
res
),
pageExpAudit
:
data
=>
http
.
post
(
'soil/v1/entrust/page_exp_audit'
,
data
).
then
(
res
=>
res
),
pageAuditByExp
:
data
=>
http
.
post
(
'soil/v1/experiment/page_audit_by_exp'
,
data
).
then
(
res
=>
res
),
pageExpByAudit
:
data
=>
http
.
post
(
'soil/v1/experiment/page_exp_audit'
,
data
).
then
(
res
=>
res
),
auditBack
:
data
=>
http
.
post
(
'soil/v1/experiment/exp_audit_back?ids='
+
data
.
ids
+
'&remark='
+
data
.
remark
)
.
then
(
res
=>
res
),
checkBack
:
data
=>
http
.
post
(
'soil/v1/experiment/exp_check_back?ids='
+
data
.
ids
+
'&remark='
+
data
.
remark
)
.
then
(
res
=>
res
)
}
}
pages/soil-report-manage/report-audit/ReportAuditIndex.vue
0 → 100644
View file @
24f72b77
<
template
>
<div>
<div
class=
"layout-content-padding"
>
<div
class=
"layout-content-main"
>
<el-tabs
v-model=
"activeName"
@
tab-click=
"_changeTabs"
>
<el-tab-pane
label=
"报告审核"
name=
"lab"
>
<reportMake
ref=
"labTabs"
/>
</el-tab-pane>
<el-tab-pane
label=
"历史任务"
name=
"his"
>
<historyTask
ref=
"hisTabs"
/>
</el-tab-pane>
</el-tabs>
</div>
</div>
</div>
</
template
>
<
script
>
import
reportMake
from
'./tabs/reportAudit'
import
historyTask
from
'./tabs/historyTask'
export
default
{
components
:
{
reportMake
,
historyTask
},
data
()
{
return
{
activeName
:
'lab'
}
},
mounted
()
{
this
.
activeName
=
'lab'
this
.
_page
()
},
methods
:
{
_changeTabs
(
tab
,
event
)
{
if
(
tab
.
name
===
'lab'
)
{
this
.
_page
()
}
else
{
this
.
$refs
.
hisTabs
.
_clearPage
()
this
.
$refs
.
hisTabs
.
_page
()
}
},
_page
()
{
this
.
$refs
.
labTabs
.
_clearPage
()
this
.
$refs
.
labTabs
.
_page
()
}
}
}
</
script
>
pages/soil-report-manage/report-audit/tabs/historyTask.vue
0 → 100644
View file @
24f72b77
<
template
>
<div>
<Row>
<Form
id=
"lab-sample-form-his"
v-show=
"searchOpen"
:label-width=
"70"
inline
onsubmit=
"return false"
class=
"search-form"
>
<label
class=
"label-sign"
/>
<Form-item
class=
"search-item"
label=
"委托方:"
>
<Input
@
on-enter=
"_formSearch"
name=
"client"
placeholder=
"请输入委托方"
clearable
/>
</Form-item>
<Form-item
class=
"search-item"
label=
"委托编号:"
>
<Input
@
on-enter=
"_formSearch"
name=
"entrustCode"
placeholder=
"请输入委托编号"
clearable
/>
</Form-item>
<!--
<Form-item
class=
"search-item"
label=
"报检时间:"
>
-->
<!--
<Date-picker-->
<!-- ref="sampleTime"-->
<!-- type="datetimerange"-->
<!-- placeholder="报检时间"-->
<!-- style="width: 100%;"-->
<!-- :editable="false"-->
<!-- transfer-->
<!-- @on-change="_labSampleTime"-->
<!-- />-->
<!--
<input
type=
"hidden"
name=
"inspectionDateBegin"
>
-->
<!--
<input
type=
"hidden"
name=
"inspectionDateEnd"
>
-->
<!--
</Form-item>
-->
<Form-item
class=
"search-btn"
>
<Button
@
click=
"_formSearch"
type=
"primary"
>
搜索
</Button>
</Form-item>
</Form>
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
:open=
"searchOpen"
@
on-result-change=
"_btnClick"
show-search-btn=
"true"
/>
</Col>
<Col
/>
<Button
@
click=
"_downloadByIds"
>
下载
</Button>
</Col>
<Col
/>
<element-table
ref=
"pageTable"
:page-columns=
"pageColumns"
:table-height=
"tableHeight"
:get-page=
"getPage"
@
on-result-change=
"_tableResultChange"
show-check-box
select-data
>
<el-table-column
v-for=
"item in pageColumns"
:key=
"item.key"
:prop=
"item.key"
:label=
"item.title"
:align=
"item.align"
:width=
"item.width"
:min-width=
"200"
:fixed=
"item.fixed?item.fixed:undefined"
show-overflow-tooltip
sortable
>
<template
slot-scope=
"scope"
@
click
.
stop=
"_handleIndex(scope)"
>
<span
v-if=
"item.datetime"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd HH:MM:ss'
):
''
}}
</span>
<div
v-else-if=
"item.status"
>
{{
scope
.
row
[
item
.
key
]
===
undefined
?
''
:
scope
.
row
[
item
.
key
].
display
}}
</div>
<span
v-else
>
{{
scope
.
row
[
item
.
key
]
}}
</span>
</
template
>
</el-table-column>
<el-table-column
slot=
"col"
:width=
"120"
label=
"操作"
align=
"center"
fixed=
"right"
>
<
template
slot-scope=
"scope"
>
<icon-list
:msg=
"iconMsg"
:row-data=
"scope.row"
:row-index=
"scope.$index"
@
on-result-change=
"_iconClick"
/>
</
template
>
</el-table-column>
</element-table>
</Col>
</Row>
<fileManage
ref=
"FileManage"
@
on-result-change=
"_fileResult"
/>
<OperationModal
ref=
"operationModal"
/>
</div>
</template>
<
script
>
// eslint-disable-next-line import/named
import
{
soilStatistics
}
from
'../../../../api'
import
global
from
'../../../../api/config'
import
OperationModal
from
'../../../../components/operation/Operation'
export
default
{
name
:
'PreparationManage'
,
components
:
{
OperationModal
},
data
()
{
return
{
name
:
''
,
pageColumns
:
[
{
title
:
'委托方'
,
key
:
'client'
,
width
:
200
},
{
title
:
'联系人'
,
key
:
'person'
,
width
:
120
},
{
title
:
'委托编号'
,
key
:
'entrustCode'
,
width
:
120
},
{
title
:
'报告是否生成'
,
key
:
'reported'
,
width
:
120
},
{
title
:
'状态'
,
key
:
'progress'
,
width
:
120
,
status
:
true
},
{
title
:
'电话/手机'
,
key
:
'tel'
,
width
:
120
},
{
title
:
'传真'
,
key
:
'fax'
,
width
:
120
},
{
title
:
'详细地址'
,
key
:
'address'
,
width
:
250
},
{
title
:
'邮箱'
,
key
:
'email'
},
{
title
:
'费用合计'
,
key
:
'fee'
,
width
:
120
},
{
title
:
'备注'
,
key
:
'remark'
}
],
btn
:
[
// { id: 'env-report-make-submit', type: 'primary', name: '提交' },
// { id: '', type: 'primary', name: '生成' },
// { id: '', type: 'primary', name: '下载' }
],
getPage
:
{},
searchOpen
:
false
,
currentIndex
:
''
,
selectIds
:
[],
selectData
:
[],
iconMsg
:
[
{
id
:
''
,
type
:
'pt-a-view'
,
name
:
'预览报告'
},
{
id
:
''
,
type
:
'pt-a-cloud'
,
name
:
'附件'
},
{
id
:
''
,
type
:
'pt-a-clock'
,
name
:
'操作日志'
}
]
}
},
computed
:
{
tableHeight
()
{
if
(
this
.
searchOpen
)
{
return
this
.
$tableHeight
(
'tabSearch'
)
}
else
{
return
this
.
$tableHeight
(
'tabNoSearch'
)
}
}
},
methods
:
{
async
_page
()
{
const
data
=
this
.
$serialize
(
'lab-sample-form-his'
)
Object
.
assign
(
data
,
this
.
$refs
.
pageTable
.
_searchParams
())
const
result
=
await
soilStatistics
.
pageReportMake
(
data
)
if
(
result
)
{
this
.
getPage
=
result
this
.
$refs
.
pageTable
.
_initTable
()
}
},
_clearPage
()
{
$
(
'#lab-sample-form-his'
)
.
find
(
'input'
)
.
each
(
function
()
{
$
(
this
).
val
(
''
)
})
// this.$refs.sampleTime.handleClear()
},
_btnClick
(
msg
,
data
)
{
switch
(
msg
)
{
case
'扫码接收'
:
this
.
_scanReceive
()
break
case
'手动接收'
:
this
.
_sampleReceive
()
break
case
'search'
:
this
.
searchOpen
=
!
this
.
searchOpen
break
}
},
_scanReceive
()
{
this
.
$refs
.
receiveModal
.
_open
()
},
_sampleReceive
()
{
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_receiveByIds
(
ids
,
`确认要接收
${
ids
.
length
}
条数据吗?`
)
}
},
_receiveByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要处理该条数据吗?`
,
onOk
:
()
=>
{
this
.
_receiveIds
(
ids
)
}
})
},
async
_receiveIds
(
ids
)
{
const
result
=
await
soilStatistics
.
submitReportCheck
(
ids
)
if
(
result
)
{
this
.
_resultChange
(
'提交成功!'
)
}
},
_submitReportCheck
()
{
const
data
=
this
.
selectData
if
(
data
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
return
false
}
this
.
_submitByIds
(
this
.
selectIds
,
`确定要提交
${
this
.
selectIds
.
length
}
条数据吗?`
)
},
_submitByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要提交该条数据吗?`
,
onOk
:
()
=>
{
this
.
_submit
(
ids
)
}
})
},
// 接口异步
_submit
:
async
function
(
ids
)
{
if
(
ids
.
length
===
0
)
return
false
const
result
=
await
soilStatistics
.
submitEntrustReportCheck
(
ids
)
if
(
result
)
{
this
.
$Message
.
success
(
'提交成功!'
)
this
.
_formSearch
()
}
},
_resultChange
(
msg
)
{
this
.
$Message
.
success
(
msg
)
this
.
_formSearch
()
},
_createReport
()
{
console
.
log
(
this
.
currentComponent
)
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
$refs
.
createReportModal
.
_open
(
this
.
selectData
)
}
},
_downloadByIds
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_download
(
this
.
selectIds
,
`确定要下载
${
this
.
selectIds
.
length
}
条数据吗?`
)
}
},
_download
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
'确定要下载报告?'
,
onOk
:
()
=>
{
window
.
open
(
global
.
baseURL
+
'/v1/sample_report/download_report/'
+
ids
,
'_blank'
)
}
})
},
_iconClick
(
name
,
data
)
{
switch
(
name
)
{
case
'提交'
:
this
.
_receiveByIds
(
data
.
id
)
break
case
'附件'
:
this
.
_uploadByIds
(
data
.
id
)
break
case
'预览报告'
:
this
.
_viewReport
(
data
)
break
case
'操作日志'
:
this
.
_record
(
data
.
id
)
break
}
},
_record
(
id
)
{
this
.
$refs
.
operationModal
.
_open
(
id
)
},
_viewReport
(
data
)
{
this
.
_getObjectKey
(
data
)
},
_getObjectKey
:
async
function
(
data
)
{
const
result
=
await
soilStatistics
.
getObjectKey
(
data
.
id
)
if
(
result
)
{
this
.
$openWindowModeless
({
objectKey
:
result
,
id
:
data
.
id
,
isReport
:
0
})
}
},
_uploadByIds
(
id
)
{
const
tempData
=
{
id
:
id
,
uploadFileUrl
:
'/v1/entrust_attachment/upload/'
,
downloadFileUrl
:
'/v1/entrust_attachment/download/'
}
this
.
$refs
.
FileManage
.
_open
(
tempData
,
'entrustId'
)
},
// 文件返回的数据
_fileResult
(
msg
,
data
)
{
switch
(
msg
)
{
case
'file-page'
:
this
.
$refs
.
FileManage
.
_openFile
(
data
)
break
case
'delete-page'
:
this
.
$refs
.
FileManage
.
_delEntrustPage
(
''
,
data
)
break
case
'success'
:
this
.
$Message
.
success
(
'删除成功!'
)
this
.
$refs
.
FileManage
.
_pageEntrust
()
break
default
:
this
.
$refs
.
FileManage
.
_pageEntrust
()
}
},
_handleIndex
(
data
)
{
this
.
currentIndex
=
data
.
$index
},
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'page'
:
this
.
_page
()
break
case
'selectIds'
:
this
.
selectIds
=
data
break
case
'selectData'
:
this
.
selectData
=
data
this
.
selectIds
=
[]
for
(
let
i
=
0
;
i
<
this
.
selectData
.
length
;
i
++
)
{
this
.
selectIds
.
push
(
this
.
selectData
[
i
].
id
)
}
break
default
:
this
.
_page
()
}
},
_labSampleTime
(
data
)
{
$
(
'input[name="inspectionDateBegin"]'
).
val
(
data
[
0
])
$
(
'input[name="inspectionDateEnd"]'
).
val
(
data
[
1
])
console
.
log
(
data
)
},
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
}
}
}
</
script
>
<
style
scoped
>
</
style
>
pages/soil-report-manage/report-audit/tabs/reportAudit.vue
0 → 100644
View file @
24f72b77
<
template
>
<div>
<Row>
<Form
id=
"lab-sample-form"
v-show=
"searchOpen"
:label-width=
"70"
inline
onsubmit=
"return false"
class=
"search-form"
>
<label
class=
"label-sign"
/>
<Form-item
class=
"search-item"
label=
"委托方:"
>
<Input
@
on-enter=
"_formSearch"
name=
"client"
placeholder=
"请输入委托方"
clearable
/>
</Form-item>
<Form-item
class=
"search-item"
label=
"委托编号:"
>
<Input
@
on-enter=
"_formSearch"
name=
"entrustCode"
placeholder=
"请输入委托编号"
clearable
/>
</Form-item>
<!--
<Form-item
class=
"search-item"
label=
"报检时间:"
>
-->
<!--
<Date-picker-->
<!-- ref="sampleTime"-->
<!-- type="datetimerange"-->
<!-- placeholder="报检时间"-->
<!-- style="width: 100%;"-->
<!-- :editable="false"-->
<!-- transfer-->
<!-- @on-change="_labSampleTime"-->
<!-- />-->
<!--
<input
type=
"hidden"
name=
"inspectionDateBegin"
>
-->
<!--
<input
type=
"hidden"
name=
"inspectionDateEnd"
>
-->
<!--
</Form-item>
-->
<Form-item
class=
"search-btn"
>
<Button
@
click=
"_formSearch"
type=
"primary"
>
搜索
</Button>
</Form-item>
</Form>
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
:open=
"searchOpen"
@
on-result-change=
"_btnClick"
show-search-btn=
"true"
/>
</Col>
<!--
<Col
span=
"24"
>
-->
<!--
<Button
type=
"primary"
@
click=
"_submitReportCheck"
>
-->
<!-- 提交-->
<!--
</Button>
-->
<!--
<Button
@
click=
"_downloadByIds"
>
-->
<!-- 下载-->
<!--
</Button>
-->
<!--
<Button
type=
"warning"
@
click=
"_goBack"
>
-->
<!-- 退回-->
<!--
</Button>
-->
<!--
</Col>
-->
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:page-columns=
"pageColumns"
:table-height=
"tableHeight"
:get-page=
"getPage"
:icon-msg=
"iconMsg"
@
on-result-change=
"_tableResultChange"
show-check-box
select-data
>
<vxe-table-column
v-for=
"item in pageColumns"
:key=
"item.key"
:field=
"item.key"
:title=
"item.title"
:width=
"item.width"
:min-width=
"200"
:fixed=
"item.fixed?item.fixed:undefined"
sortable
>
<template
slot-scope=
"scope"
@
click
.
stop=
"_handleIndex(scope)"
>
<span
v-if=
"item.datetime"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd HH:MM:ss'
):
''
}}
</span>
<div
v-else-if=
"item.status"
>
{{
scope
.
row
[
item
.
key
]
===
undefined
?
''
:
scope
.
row
[
item
.
key
].
display
}}
</div>
<span
v-else
>
{{
scope
.
row
[
item
.
key
]
}}
</span>
</
template
>
</vxe-table-column>
</PTVXETable>
</Col>
</Row>
<FileManage
ref=
"FileManage"
@
on-result-change=
"_fileResult"
/>
<Reason
ref=
"reasonModal"
@
on-result-change=
"_reasonResult"
/>
<OperationModal
ref=
"operationModal"
/>
</div>
</template>
<
script
>
// eslint-disable-next-line import/named
import
{
soilStatistics
}
from
'../../../../api'
import
global
from
'../../../../api/config'
import
Reason
from
'../../../../components/base/Reason'
import
OperationModal
from
'../../../../components/operation/Operation'
export
default
{
name
:
'PreparationManage'
,
components
:
{
Reason
,
OperationModal
},
data
()
{
return
{
name
:
''
,
pageColumns
:
[
{
title
:
'委托方'
,
key
:
'client'
,
width
:
200
},
{
title
:
'联系人'
,
key
:
'person'
,
width
:
120
},
{
title
:
'委托编号'
,
key
:
'entrustCode'
,
width
:
120
},
{
title
:
'报告是否生成'
,
key
:
'reported'
,
width
:
120
},
{
title
:
'状态'
,
key
:
'progress'
,
width
:
120
,
status
:
true
},
{
title
:
'电话/手机'
,
key
:
'tel'
,
width
:
120
},
{
title
:
'传真'
,
key
:
'fax'
,
width
:
120
},
{
title
:
'详细地址'
,
key
:
'address'
,
width
:
250
},
{
title
:
'邮箱'
,
key
:
'email'
},
{
title
:
'费用合计'
,
key
:
'fee'
,
width
:
120
},
{
title
:
'备注'
,
key
:
'remark'
}
],
btn
:
[
{
id
:
''
,
type
:
'primary'
,
name
:
'提交'
},
{
id
:
''
,
type
:
'primary'
,
name
:
'下载'
},
{
id
:
''
,
type
:
'primary'
,
name
:
'退回'
}
],
getPage
:
{},
searchOpen
:
false
,
currentIndex
:
''
,
selectIds
:
[],
selectData
:
[],
iconMsg
:
[
{
id
:
''
,
type
:
'pt-a-view'
,
name
:
'预览报告'
},
{
id
:
''
,
type
:
'pt-a-cloud'
,
name
:
'附件'
},
{
id
:
''
,
type
:
'pt-a-clock'
,
name
:
'操作日志'
}
]
}
},
computed
:
{
tableHeight
()
{
if
(
this
.
searchOpen
)
{
return
this
.
$tableHeight
(
'tabSearch'
)
}
else
{
return
this
.
$tableHeight
(
'tabNoSearch'
)
}
}
},
methods
:
{
async
_page
()
{
const
data
=
this
.
$serialize
(
'lab-sample-form'
)
Object
.
assign
(
data
,
this
.
$refs
.
pageTable
.
_searchParams
())
const
result
=
await
soilStatistics
.
pageReportCheck
(
data
)
if
(
result
)
{
this
.
getPage
=
result
this
.
$refs
.
pageTable
.
_hideLoading
()
}
},
_clearPage
()
{
$
(
'#lab-sample-form'
)
.
find
(
'input'
)
.
each
(
function
()
{
$
(
this
).
val
(
''
)
})
// this.$refs.sampleTime.handleClear()
},
_btnClick
(
msg
,
data
)
{
switch
(
msg
)
{
case
'提交'
:
this
.
_submitReportCheck
()
break
case
'下载'
:
this
.
_downloadByIds
()
break
case
'退回'
:
this
.
_goBack
()
break
case
'扫码接收'
:
this
.
_scanReceive
()
break
case
'手动接收'
:
this
.
_sampleReceive
()
break
case
'search'
:
this
.
searchOpen
=
!
this
.
searchOpen
break
}
},
_goBack
()
{
// 退回
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条委托!'
)
}
else
{
this
.
$refs
.
reasonModal
.
_open
(
'退回原因'
)
}
},
_reasonResult
(
data
)
{
if
(
undefined
!==
data
&&
data
!==
''
)
{
this
.
_reportCheckBack
(
data
)
}
},
_reportCheckBack
:
async
function
(
data
)
{
const
result
=
await
soilStatistics
.
entrustReportCheckBack
({
ids
:
this
.
selectIds
,
remark
:
data
})
if
(
result
)
{
this
.
$Message
.
success
(
'退回成功!'
)
await
this
.
_page
()
}
},
_scanReceive
()
{
this
.
$refs
.
receiveModal
.
_open
()
},
_sampleReceive
()
{
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_receiveByIds
(
ids
,
`确认要接收
${
ids
.
length
}
条数据吗?`
)
}
},
_receiveByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要处理该条数据吗?`
,
onOk
:
()
=>
{
this
.
_receiveIds
(
ids
)
}
})
},
async
_receiveIds
(
ids
)
{
const
result
=
await
soilStatistics
.
submitReportCheck
(
ids
)
if
(
result
)
{
this
.
_resultChange
(
'提交成功!'
)
}
},
_submitReportCheck
()
{
const
data
=
this
.
selectData
if
(
data
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
return
false
}
this
.
_submitByIds
(
this
.
selectIds
,
`确定要提交
${
this
.
selectIds
.
length
}
条数据吗?`
)
},
_submitByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要提交该条数据吗?`
,
onOk
:
()
=>
{
this
.
_submit
(
ids
)
}
})
},
// 接口异步
_submit
:
async
function
(
ids
)
{
if
(
ids
.
length
===
0
)
return
false
const
result
=
await
soilStatistics
.
submitEntrustReportCheck
(
ids
)
if
(
result
)
{
this
.
$Message
.
success
(
'提交成功!'
)
this
.
_formSearch
()
}
},
_resultChange
(
msg
)
{
this
.
$Message
.
success
(
msg
)
this
.
_formSearch
()
},
_createReport
()
{
console
.
log
(
this
.
currentComponent
)
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
$refs
.
createReportModal
.
_open
(
this
.
selectData
)
}
},
_downloadByIds
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_download
(
this
.
selectIds
,
`确定要下载
${
this
.
selectIds
.
length
}
条数据吗?`
)
}
},
_download
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
'确定要下载报告?'
,
onOk
:
()
=>
{
window
.
open
(
global
.
baseURL
+
'/v1/sample_report/download_report/'
+
ids
,
'_blank'
)
}
})
},
_iconClick
(
name
,
data
)
{
switch
(
name
)
{
case
'提交'
:
this
.
_receiveByIds
(
data
.
id
)
break
case
'附件'
:
this
.
_uploadByIds
(
data
.
id
)
break
case
'预览报告'
:
this
.
_viewReport
(
data
)
break
case
'操作日志'
:
this
.
_record
(
data
.
id
)
break
}
},
_record
(
id
)
{
this
.
$refs
.
operationModal
.
_open
(
id
)
},
_viewReport
(
data
)
{
this
.
_getObjectKey
(
data
)
},
_getObjectKey
:
async
function
(
data
)
{
const
result
=
await
soilStatistics
.
getObjectKey
(
data
.
id
)
if
(
result
)
{
this
.
$openWindowModeless
({
objectKey
:
result
,
id
:
data
.
id
,
isReport
:
0
})
}
},
_uploadByIds
(
id
)
{
const
tempData
=
{
id
:
id
,
uploadFileUrl
:
'/v1/entrust_attachment/upload/'
,
downloadFileUrl
:
'/v1/entrust_attachment/download/'
}
this
.
$refs
.
FileManage
.
_open
(
tempData
,
'entrustId'
)
},
// 文件返回的数据
_fileResult
(
msg
,
data
)
{
switch
(
msg
)
{
case
'file-page'
:
this
.
$refs
.
FileManage
.
_openFile
(
data
)
break
case
'delete-page'
:
this
.
$refs
.
FileManage
.
_delEntrustPage
(
''
,
data
)
break
case
'success'
:
this
.
$Message
.
success
(
'删除成功!'
)
this
.
$refs
.
FileManage
.
_pageEntrust
()
break
default
:
this
.
$refs
.
FileManage
.
_pageEntrust
()
}
},
_handleIndex
(
data
)
{
this
.
currentIndex
=
data
.
$index
},
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'page'
:
this
.
_page
()
break
case
'selectIds'
:
this
.
selectIds
=
data
break
case
'selectData'
:
this
.
selectData
=
data
this
.
selectIds
=
[]
for
(
let
i
=
0
;
i
<
this
.
selectData
.
length
;
i
++
)
{
this
.
selectIds
.
push
(
this
.
selectData
[
i
].
id
)
}
break
default
:
this
.
_page
()
}
},
_labSampleTime
(
data
)
{
$
(
'input[name="inspectionDateBegin"]'
).
val
(
data
[
0
])
$
(
'input[name="inspectionDateEnd"]'
).
val
(
data
[
1
])
console
.
log
(
data
)
},
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
}
}
}
</
script
>
<
style
scoped
>
</
style
>
pages/soil-report-manage/report-issue/ReportIssueIndex.vue
0 → 100644
View file @
24f72b77
<
template
>
<div>
<div
class=
"layout-content-padding"
>
<div
class=
"layout-content-main"
>
<el-tabs
v-model=
"activeName"
@
tab-click=
"_changeTabs"
>
<el-tab-pane
label=
"报告签发"
name=
"lab"
>
<reportMake
ref=
"labTabs"
/>
</el-tab-pane>
<el-tab-pane
label=
"历史任务"
name=
"his"
>
<historyTask
ref=
"hisTabs"
/>
</el-tab-pane>
</el-tabs>
</div>
</div>
</div>
</
template
>
<
script
>
import
reportMake
from
'./tabs/reportIssue'
import
historyTask
from
'./tabs/historyTask'
export
default
{
components
:
{
reportMake
,
historyTask
},
data
()
{
return
{
activeName
:
'lab'
}
},
mounted
()
{
this
.
activeName
=
'lab'
this
.
_page
()
},
methods
:
{
_changeTabs
(
tab
,
event
)
{
if
(
tab
.
name
===
'lab'
)
{
this
.
_page
()
}
else
{
this
.
$refs
.
hisTabs
.
_clearPage
()
this
.
$refs
.
hisTabs
.
_page
()
}
},
_page
()
{
this
.
$refs
.
labTabs
.
_clearPage
()
this
.
$refs
.
labTabs
.
_page
()
}
}
}
</
script
>
pages/soil-report-manage/report-issue/tabs/historyTask.vue
0 → 100644
View file @
24f72b77
<
template
>
<div>
<Row>
<Form
id=
"lab-sample-form-his"
v-show=
"searchOpen"
:label-width=
"70"
inline
onsubmit=
"return false"
class=
"search-form"
>
<label
class=
"label-sign"
/>
<Form-item
class=
"search-item"
label=
"委托方:"
>
<Input
@
on-enter=
"_formSearch"
name=
"client"
placeholder=
"请输入委托方"
clearable
/>
</Form-item>
<Form-item
class=
"search-item"
label=
"委托编号:"
>
<Input
@
on-enter=
"_formSearch"
name=
"entrustCode"
placeholder=
"请输入委托编号"
clearable
/>
</Form-item>
<!--
<Form-item
class=
"search-item"
label=
"报检时间:"
>
-->
<!--
<Date-picker-->
<!-- ref="sampleTime"-->
<!-- type="datetimerange"-->
<!-- placeholder="报检时间"-->
<!-- style="width: 100%;"-->
<!-- :editable="false"-->
<!-- transfer-->
<!-- @on-change="_labSampleTime"-->
<!-- />-->
<!--
<input
type=
"hidden"
name=
"inspectionDateBegin"
>
-->
<!--
<input
type=
"hidden"
name=
"inspectionDateEnd"
>
-->
<!--
</Form-item>
-->
<Form-item
class=
"search-btn"
>
<Button
@
click=
"_formSearch"
type=
"primary"
>
搜索
</Button>
</Form-item>
</Form>
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
:open=
"searchOpen"
@
on-result-change=
"_btnClick"
show-search-btn=
"true"
/>
</Col>
<Col
/>
<!--
<Button
type=
"primary"
@
click=
"_submitReportCheck"
>
-->
<!-- 提交-->
<!--
</Button>
-->
<Button
@
click=
"_downloadByIds"
>
下载
</Button>
</Col>
<Col
/>
<element-table
ref=
"pageTable"
:page-columns=
"pageColumns"
:table-height=
"tableHeight"
:get-page=
"getPage"
@
on-result-change=
"_tableResultChange"
show-check-box
select-data
>
<el-table-column
v-for=
"item in pageColumns"
:key=
"item.key"
:prop=
"item.key"
:label=
"item.title"
:align=
"item.align"
:width=
"item.width"
:min-width=
"200"
:fixed=
"item.fixed?item.fixed:undefined"
show-overflow-tooltip
sortable
>
<template
slot-scope=
"scope"
@
click
.
stop=
"_handleIndex(scope)"
>
<span
v-if=
"item.datetime"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd HH:MM:ss'
):
''
}}
</span>
<div
v-else-if=
"item.status"
>
{{
scope
.
row
[
item
.
key
]
===
undefined
?
''
:
scope
.
row
[
item
.
key
].
display
}}
</div>
<span
v-else
>
{{
scope
.
row
[
item
.
key
]
}}
</span>
</
template
>
</el-table-column>
<el-table-column
slot=
"col"
:width=
"120"
label=
"操作"
align=
"center"
fixed=
"right"
>
<
template
slot-scope=
"scope"
>
<icon-list
:msg=
"iconMsg"
:row-data=
"scope.row"
:row-index=
"scope.$index"
@
on-result-change=
"_iconClick"
/>
</
template
>
</el-table-column>
</element-table>
</Col>
</Row>
<fileManage
ref=
"FileManage"
@
on-result-change=
"_fileResult"
/>
<OperationModal
ref=
"operationModal"
/>
</div>
</template>
<
script
>
// eslint-disable-next-line import/named
import
{
soilStatistics
}
from
'../../../../api'
import
global
from
'../../../../api/config'
import
OperationModal
from
'../../../../components/operation/Operation'
export
default
{
name
:
'PreparationManage'
,
components
:
{
OperationModal
},
data
()
{
return
{
name
:
''
,
pageColumns
:
[
{
title
:
'委托方'
,
key
:
'client'
,
width
:
200
},
{
title
:
'联系人'
,
key
:
'person'
,
width
:
120
},
{
title
:
'委托编号'
,
key
:
'entrustCode'
,
width
:
120
},
{
title
:
'报告是否生成'
,
key
:
'reported'
,
width
:
120
},
{
title
:
'状态'
,
key
:
'progress'
,
width
:
120
,
status
:
true
},
{
title
:
'电话/手机'
,
key
:
'tel'
,
width
:
120
},
{
title
:
'传真'
,
key
:
'fax'
,
width
:
120
},
{
title
:
'详细地址'
,
key
:
'address'
,
width
:
250
},
{
title
:
'邮箱'
,
key
:
'email'
},
{
title
:
'费用合计'
,
key
:
'fee'
,
width
:
120
},
{
title
:
'备注'
,
key
:
'remark'
}
],
btn
:
[
// { id: 'env-report-make-submit', type: 'primary', name: '提交' },
// { id: '', type: 'primary', name: '生成' },
// { id: '', type: 'primary', name: '下载' }
],
getPage
:
{},
searchOpen
:
false
,
currentIndex
:
''
,
selectIds
:
[],
selectData
:
[],
iconMsg
:
[
{
id
:
''
,
type
:
'pt-a-view'
,
name
:
'预览报告'
},
// { id: '', type: 'pt-a-view', name: '预览PDF' },
{
id
:
''
,
type
:
'pt-a-cloud'
,
name
:
'附件'
},
{
id
:
''
,
type
:
'pt-a-clock'
,
name
:
'操作日志'
}
]
}
},
computed
:
{
tableHeight
()
{
if
(
this
.
searchOpen
)
{
return
this
.
$tableHeight
(
'tabSearch'
)
}
else
{
return
this
.
$tableHeight
(
'tabNoSearch'
)
}
}
},
methods
:
{
async
_page
()
{
const
data
=
this
.
$serialize
(
'lab-sample-form-his'
)
Object
.
assign
(
data
,
this
.
$refs
.
pageTable
.
_searchParams
())
const
result
=
await
soilStatistics
.
pageReportMake
(
data
)
if
(
result
)
{
this
.
getPage
=
result
this
.
$refs
.
pageTable
.
_initTable
()
}
},
_clearPage
()
{
$
(
'#lab-sample-form-his'
)
.
find
(
'input'
)
.
each
(
function
()
{
$
(
this
).
val
(
''
)
})
// this.$refs.sampleTime.handleClear()
},
_btnClick
(
msg
,
data
)
{
switch
(
msg
)
{
case
'扫码接收'
:
this
.
_scanReceive
()
break
case
'手动接收'
:
this
.
_sampleReceive
()
break
case
'search'
:
this
.
searchOpen
=
!
this
.
searchOpen
break
}
},
_scanReceive
()
{
this
.
$refs
.
receiveModal
.
_open
()
},
_sampleReceive
()
{
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_receiveByIds
(
ids
,
`确认要接收
${
ids
.
length
}
条数据吗?`
)
}
},
_receiveByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要处理该条数据吗?`
,
onOk
:
()
=>
{
this
.
_receiveIds
(
ids
)
}
})
},
async
_receiveIds
(
ids
)
{
const
result
=
await
soilStatistics
.
submitReportCheck
(
ids
)
if
(
result
)
{
this
.
_resultChange
(
'提交成功!'
)
}
},
_submitReportCheck
()
{
const
data
=
this
.
selectData
if
(
data
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
return
false
}
this
.
_submitByIds
(
this
.
selectIds
,
`确定要提交
${
this
.
selectIds
.
length
}
条数据吗?`
)
},
_submitByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要提交该条数据吗?`
,
onOk
:
()
=>
{
this
.
_submit
(
ids
)
}
})
},
// 接口异步
_submit
:
async
function
(
ids
)
{
if
(
ids
.
length
===
0
)
return
false
const
result
=
await
soilStatistics
.
submitEntrustReportCheck
(
ids
)
if
(
result
)
{
this
.
$Message
.
success
(
'提交成功!'
)
this
.
_formSearch
()
}
},
_resultChange
(
msg
)
{
this
.
$Message
.
success
(
msg
)
this
.
_formSearch
()
},
_createReport
()
{
console
.
log
(
this
.
currentComponent
)
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
$refs
.
createReportModal
.
_open
(
this
.
selectData
)
}
},
_downloadByIds
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_download
(
this
.
selectIds
,
`确定要下载
${
this
.
selectIds
.
length
}
条数据吗?`
)
}
},
_download
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
'确定要下载报告?'
,
onOk
:
()
=>
{
window
.
open
(
global
.
baseURL
+
'/v1/sample_report/download_report/'
+
ids
,
'_blank'
)
}
})
},
_iconClick
(
name
,
data
)
{
switch
(
name
)
{
case
'提交'
:
this
.
_receiveByIds
(
data
.
id
)
break
case
'附件'
:
this
.
_uploadByIds
(
data
.
id
)
break
case
'预览报告'
:
this
.
_viewReport
(
data
)
break
case
'预览PDF'
:
this
.
_viewPDF
(
data
)
break
case
'操作日志'
:
this
.
_record
(
data
.
id
)
break
}
},
// 没有生成pdf先生成在预览
_viewPDF
(
data
)
{
console
.
log
(
data
)
if
(
data
.
pdfObjectKey
)
{
this
.
$pdfView
(
data
.
pdfObjectKey
)
}
else
{
console
.
log
(
123456
)
// window.open(
// 'http://api.pertest.patzn.com/food/v1/sample_report/generate_pdf_auto?id=' +
// data.id
// )
// this.autoPdf(data)
// window.open(
// global.baseURL +
// '/food/v1/sample_report/generate_pdf_auto?id=' +
// data.id
// )
}
},
_viewReport
(
data
)
{
this
.
_getObjectKey
(
data
)
},
_record
(
id
)
{
this
.
$refs
.
operationModal
.
_open
(
id
)
},
_getObjectKey
:
async
function
(
data
)
{
const
result
=
await
soilStatistics
.
getObjectKey
(
data
.
id
)
if
(
result
)
{
this
.
$openWindowModeless
({
objectKey
:
result
,
id
:
data
.
id
,
isReport
:
0
})
}
},
_uploadByIds
(
id
)
{
const
tempData
=
{
id
:
id
,
uploadFileUrl
:
'/v1/entrust_attachment/upload/'
,
downloadFileUrl
:
'/v1/entrust_attachment/download/'
}
this
.
$refs
.
FileManage
.
_open
(
tempData
,
'entrustId'
)
},
// 文件返回的数据
_fileResult
(
msg
,
data
)
{
switch
(
msg
)
{
case
'file-page'
:
this
.
$refs
.
FileManage
.
_openFile
(
data
)
break
case
'delete-page'
:
this
.
$refs
.
FileManage
.
_delEntrustPage
(
''
,
data
)
break
case
'success'
:
this
.
$Message
.
success
(
'删除成功!'
)
this
.
$refs
.
FileManage
.
_pageEntrust
()
break
default
:
this
.
$refs
.
FileManage
.
_pageEntrust
()
}
},
_handleIndex
(
data
)
{
this
.
currentIndex
=
data
.
$index
},
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'page'
:
this
.
_page
()
break
case
'selectIds'
:
this
.
selectIds
=
data
break
case
'selectData'
:
this
.
selectData
=
data
this
.
selectIds
=
[]
for
(
let
i
=
0
;
i
<
this
.
selectData
.
length
;
i
++
)
{
this
.
selectIds
.
push
(
this
.
selectData
[
i
].
id
)
}
break
default
:
this
.
_page
()
}
},
_labSampleTime
(
data
)
{
$
(
'input[name="inspectionDateBegin"]'
).
val
(
data
[
0
])
$
(
'input[name="inspectionDateEnd"]'
).
val
(
data
[
1
])
console
.
log
(
data
)
},
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
}
}
}
</
script
>
<
style
scoped
>
</
style
>
pages/soil-report-manage/report-issue/tabs/reportIssue.vue
0 → 100644
View file @
24f72b77
<
template
>
<div>
<Row>
<Form
id=
"lab-sample-form"
v-show=
"searchOpen"
:label-width=
"70"
inline
onsubmit=
"return false"
class=
"search-form"
>
<label
class=
"label-sign"
/>
<Form-item
class=
"search-item"
label=
"委托方:"
>
<Input
@
on-enter=
"_formSearch"
name=
"client"
placeholder=
"请输入委托方"
clearable
/>
</Form-item>
<Form-item
class=
"search-item"
label=
"委托编号:"
>
<Input
@
on-enter=
"_formSearch"
name=
"entrustCode"
placeholder=
"请输入委托编号"
clearable
/>
</Form-item>
<!--
<Form-item
class=
"search-item"
label=
"报检时间:"
>
-->
<!--
<Date-picker-->
<!-- ref="sampleTime"-->
<!-- type="datetimerange"-->
<!-- placeholder="报检时间"-->
<!-- style="width: 100%;"-->
<!-- :editable="false"-->
<!-- transfer-->
<!-- @on-change="_labSampleTime"-->
<!-- />-->
<!--
<input
type=
"hidden"
name=
"inspectionDateBegin"
>
-->
<!--
<input
type=
"hidden"
name=
"inspectionDateEnd"
>
-->
<!--
</Form-item>
-->
<Form-item
class=
"search-btn"
>
<Button
@
click=
"_formSearch"
type=
"primary"
>
搜索
</Button>
</Form-item>
</Form>
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
:open=
"searchOpen"
@
on-result-change=
"_btnClick"
show-search-btn=
"true"
/>
</Col>
<!--
<Col
span=
"24"
>
-->
<!-- <!–
<Button
type=
"primary"
@
click=
"_submitReportCheck"
>
–>
-->
<!--
<Button
type=
"primary"
@
click=
"_submitReportIssue"
>
-->
<!-- 提交-->
<!--
</Button>
-->
<!--
<Button
@
click=
"_downloadByIds"
>
-->
<!-- 下载-->
<!--
</Button>
-->
<!--
<Button
type=
"warning"
@
click=
"_goBack"
>
-->
<!-- 退回-->
<!--
</Button>
-->
<!--
</Col>
-->
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:page-columns=
"pageColumns"
:table-height=
"tableHeight"
:get-page=
"getPage"
:icon-msg=
"iconMsg"
@
on-result-change=
"_tableResultChange"
show-check-box
select-data
>
<vxe-table-column
v-for=
"item in pageColumns"
:key=
"item.key"
:field=
"item.key"
:title=
"item.title"
:width=
"item.width"
:min-width=
"200"
:fixed=
"item.fixed?item.fixed:undefined"
sortable
>
<template
slot-scope=
"scope"
@
click
.
stop=
"_handleIndex(scope)"
>
<span
v-if=
"item.datetime"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd HH:MM:ss'
):
''
}}
</span>
<div
v-else-if=
"item.status"
>
{{
scope
.
row
[
item
.
key
]
===
undefined
?
''
:
scope
.
row
[
item
.
key
].
display
}}
</div>
<span
v-else
>
{{
scope
.
row
[
item
.
key
]
}}
</span>
</
template
>
</vxe-table-column>
</PTVXETable>
</Col>
</Row>
<fileManage
ref=
"FileManage"
@
on-result-change=
"_fileResult"
/>
<Reason
ref=
"reasonModal"
@
on-result-change=
"_reasonResult"
/>
<OperationModal
ref=
"operationModal"
/>
</div>
</template>
<
script
>
// eslint-disable-next-line import/named
import
{
soilStatistics
}
from
'../../../../api'
import
global
from
'../../../../api/config'
import
Reason
from
'../../../../components/base/Reason'
import
OperationModal
from
'../../../../components/operation/Operation'
export
default
{
name
:
'PreparationManage'
,
components
:
{
Reason
,
OperationModal
},
data
()
{
return
{
name
:
''
,
pageColumns
:
[
{
title
:
'委托方'
,
key
:
'client'
,
width
:
200
},
{
title
:
'联系人'
,
key
:
'person'
,
width
:
120
},
{
title
:
'委托编号'
,
key
:
'entrustCode'
,
width
:
120
},
{
title
:
'报告是否生成'
,
key
:
'reported'
,
width
:
120
},
{
title
:
'状态'
,
key
:
'progress'
,
width
:
120
,
status
:
true
},
{
title
:
'电话/手机'
,
key
:
'tel'
,
width
:
120
},
{
title
:
'传真'
,
key
:
'fax'
,
width
:
120
},
{
title
:
'详细地址'
,
key
:
'address'
,
width
:
250
},
{
title
:
'邮箱'
,
key
:
'email'
},
{
title
:
'费用合计'
,
key
:
'fee'
,
width
:
120
},
{
title
:
'备注'
,
key
:
'remark'
}
],
btn
:
[
{
id
:
''
,
type
:
'primary'
,
name
:
'提交'
},
{
id
:
''
,
type
:
'primary'
,
name
:
'下载'
},
{
id
:
''
,
type
:
'primary'
,
name
:
'退回'
}
],
getPage
:
{},
searchOpen
:
false
,
currentIndex
:
''
,
selectIds
:
[],
selectData
:
[],
iconMsg
:
[
{
id
:
''
,
type
:
'pt-a-view'
,
name
:
'预览报告'
},
{
id
:
''
,
type
:
'pt-a-cloud'
,
name
:
'附件'
},
{
id
:
''
,
type
:
'pt-a-clock'
,
name
:
'操作日志'
}
]
}
},
computed
:
{
tableHeight
()
{
if
(
this
.
searchOpen
)
{
return
this
.
$tableHeight
(
'tabSearch'
)
}
else
{
return
this
.
$tableHeight
(
'tabNoSearch'
)
}
}
},
methods
:
{
async
_page
()
{
const
data
=
this
.
$serialize
(
'lab-sample-form'
)
Object
.
assign
(
data
,
this
.
$refs
.
pageTable
.
_searchParams
())
const
result
=
await
soilStatistics
.
pageReportIssue
(
data
)
if
(
result
)
{
this
.
getPage
=
result
this
.
$refs
.
pageTable
.
_hideLoading
()
}
},
_clearPage
()
{
$
(
'#lab-sample-form'
)
.
find
(
'input'
)
.
each
(
function
()
{
$
(
this
).
val
(
''
)
})
// this.$refs.sampleTime.handleClear()
},
_btnClick
(
msg
,
data
)
{
switch
(
msg
)
{
case
'提交'
:
this
.
_submitReportIssue
()
break
case
'下载'
:
this
.
_downloadByIds
()
break
case
'退回'
:
this
.
_goBack
()
break
case
'扫码接收'
:
this
.
_scanReceive
()
break
case
'手动接收'
:
this
.
_sampleReceive
()
break
case
'search'
:
this
.
searchOpen
=
!
this
.
searchOpen
break
}
},
_scanReceive
()
{
this
.
$refs
.
receiveModal
.
_open
()
},
_sampleReceive
()
{
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_receiveByIds
(
ids
,
`确认要接收
${
ids
.
length
}
条数据吗?`
)
}
},
_receiveByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要处理该条数据吗?`
,
onOk
:
()
=>
{
this
.
_receiveIds
(
ids
)
}
})
},
async
_receiveIds
(
ids
)
{
const
result
=
await
soilStatistics
.
submitReportCheck
(
ids
)
if
(
result
)
{
this
.
_resultChange
(
'提交成功!'
)
}
},
_goBack
()
{
// 退回
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条委托!'
)
}
else
{
this
.
$refs
.
reasonModal
.
_open
(
'退回原因'
)
}
},
_reasonResult
(
data
)
{
if
(
undefined
!==
data
&&
data
!==
''
)
{
this
.
_reportCheckBack
(
data
)
}
},
_reportCheckBack
:
async
function
(
data
)
{
const
result
=
await
soilStatistics
.
entrustReportIssueBack
({
ids
:
this
.
selectIds
,
remark
:
data
})
if
(
result
)
{
this
.
$Message
.
success
(
'退回成功!'
)
await
this
.
_page
()
}
},
_submitReportCheck
()
{
const
data
=
this
.
selectData
if
(
data
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
return
false
}
this
.
_submitByIds
(
this
.
selectIds
,
`确定要提交
${
this
.
selectIds
.
length
}
条数据吗?`
)
},
_submitReportIssue
()
{
const
data
=
this
.
selectData
if
(
data
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
return
false
}
this
.
_submitByIds
(
this
.
selectIds
,
`确定要提交
${
this
.
selectIds
.
length
}
条数据吗?`
)
},
_submitByIds
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
`确定要提交该条数据吗?`
,
onOk
:
()
=>
{
this
.
_submit
(
ids
)
}
})
},
// 接口异步
_submit
:
async
function
(
ids
)
{
if
(
ids
.
length
===
0
)
return
false
const
result
=
await
soilStatistics
.
submitEntrustReportIssue
(
ids
)
if
(
result
)
{
this
.
$Message
.
success
(
'提交成功!'
)
this
.
_formSearch
()
}
},
_resultChange
(
msg
)
{
this
.
$Message
.
success
(
msg
)
this
.
_formSearch
()
},
_createReport
()
{
console
.
log
(
this
.
currentComponent
)
const
ids
=
this
.
selectIds
if
(
ids
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
$refs
.
createReportModal
.
_open
(
this
.
selectData
)
}
},
_downloadByIds
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据!'
)
}
else
{
this
.
_download
(
this
.
selectIds
,
`确定要下载
${
this
.
selectIds
.
length
}
条数据吗?`
)
}
},
_download
(
ids
,
content
)
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
content
||
'确定要下载报告?'
,
onOk
:
()
=>
{
window
.
open
(
global
.
baseURL
+
'/v1/sample_report/download_report/'
+
ids
,
'_blank'
)
}
})
},
_iconClick
(
name
,
data
)
{
switch
(
name
)
{
case
'提交'
:
this
.
_receiveByIds
(
data
.
id
)
break
case
'附件'
:
this
.
_uploadByIds
(
data
.
id
)
break
case
'预览报告'
:
this
.
_viewReport
(
data
)
break
case
'操作日志'
:
this
.
_record
(
data
.
id
)
break
}
},
_viewReport
(
data
)
{
this
.
_getObjectKey
(
data
)
},
_record
(
id
)
{
this
.
$refs
.
operationModal
.
_open
(
id
)
},
_getObjectKey
:
async
function
(
data
)
{
const
result
=
await
soilStatistics
.
getObjectKey
(
data
.
id
)
if
(
result
)
{
this
.
$openWindowModeless
({
objectKey
:
result
,
id
:
data
.
id
,
isReport
:
0
})
}
},
_uploadByIds
(
id
)
{
const
tempData
=
{
id
:
id
,
uploadFileUrl
:
'/v1/entrust_attachment/upload/'
,
downloadFileUrl
:
'/v1/entrust_attachment/download/'
}
this
.
$refs
.
FileManage
.
_open
(
tempData
,
'entrustId'
)
},
// 文件返回的数据
_fileResult
(
msg
,
data
)
{
switch
(
msg
)
{
case
'file-page'
:
this
.
$refs
.
FileManage
.
_openFile
(
data
)
break
case
'delete-page'
:
this
.
$refs
.
FileManage
.
_delEntrustPage
(
''
,
data
)
break
case
'success'
:
this
.
$Message
.
success
(
'删除成功!'
)
this
.
$refs
.
FileManage
.
_pageEntrust
()
break
default
:
this
.
$refs
.
FileManage
.
_pageEntrust
()
}
},
_handleIndex
(
data
)
{
this
.
currentIndex
=
data
.
$index
},
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'page'
:
this
.
_page
()
break
case
'selectIds'
:
this
.
selectIds
=
data
break
case
'selectData'
:
this
.
selectData
=
data
this
.
selectIds
=
[]
for
(
let
i
=
0
;
i
<
this
.
selectData
.
length
;
i
++
)
{
this
.
selectIds
.
push
(
this
.
selectData
[
i
].
id
)
}
break
default
:
this
.
_page
()
}
},
_labSampleTime
(
data
)
{
$
(
'input[name="inspectionDateBegin"]'
).
val
(
data
[
0
])
$
(
'input[name="inspectionDateEnd"]'
).
val
(
data
[
1
])
console
.
log
(
data
)
},
_formSearch
()
{
this
.
$refs
.
pageTable
.
_pageChange
(
1
)
}
}
}
</
script
>
<
style
scoped
>
</
style
>
pages/soil-report-manage/report-make/tabs/ReportInfoMake.vue
View file @
24f72b77
...
@@ -47,18 +47,9 @@
...
@@ -47,18 +47,9 @@
</Form>
</Form>
</Col>
</Col>
<Col
span=
"24"
>
<Col
span=
"24"
>
<
BtnL
ist
:msg=
"btn"
:open=
"searchOpen"
:showSearchBtn=
"true"
@
on-result-change=
"_btnClick"
<
btn-l
ist
:msg=
"btn"
:open=
"searchOpen"
:showSearchBtn=
"true"
@
on-result-change=
"_btnClick"
class=
"contHide"
>
class=
"contHide"
>
<!--切换待认领任务-->
</btn-list>
<template
slot=
"processTask"
>
<div
class=
"fr process-task"
>
<el-checkbox
v-model=
"formObj.personal"
@
change=
"_page"
:true-label=
"1"
:false-label=
"0"
size=
"medium"
>
个人任务
</el-checkbox>
</div>
</
template
>
</BtnList>
</Col>
</Col>
<!-- 表格 -->
<!-- 表格 -->
<Col
span=
"24"
>
<Col
span=
"24"
>
...
...
pages/soil-report-manage/report-make/tabs/ReportMakeByEntrust.vue
View file @
24f72b77
...
@@ -79,13 +79,15 @@
...
@@ -79,13 +79,15 @@
</div>
</div>
</div>
</div>
<SampleByMakeModal
ref=
"sampleByMakeModal"
></SampleByMakeModal>
<SampleByMakeModal
ref=
"sampleByMakeModal"
></SampleByMakeModal>
<Operation
ref=
"operation"
></Operation>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
{
soil
Test
}
from
'../../../../api'
import
{
soil
Statistics
}
from
'../../../../api'
import
SampleByMakeModal
from
'../SampleByMakeModal'
import
SampleByMakeModal
from
'../SampleByMakeModal'
import
Operation
from
'../../../../components/operation/Operation'
export
default
{
export
default
{
components
:
{
SampleByMakeModal
},
components
:
{
SampleByMakeModal
,
Operation
},
data
()
{
data
()
{
return
{
return
{
typeList
:
[{
name
:
'企业'
,
value
:
0
},
{
name
:
'政府'
,
value
:
1
}],
typeList
:
[{
name
:
'企业'
,
value
:
0
},
{
name
:
'政府'
,
value
:
1
}],
...
@@ -94,33 +96,19 @@ export default {
...
@@ -94,33 +96,19 @@ export default {
formObj
:
{},
formObj
:
{},
pageColumns
:
[
pageColumns
:
[
{
{
title
:
'委托
单位
'
,
title
:
'委托
商
'
,
key
:
'c
name
'
,
key
:
'c
lient
'
,
width
:
180
,
width
:
180
,
detail
:
true
,
fixed
:
'left'
fixed
:
'left'
},
},
{
title
:
'委托名称'
,
key
:
'name'
,
width
:
160
},
{
title
:
'委托编号'
,
key
:
'entrustCode'
,
width
:
180
},
{
title
:
'委托编号'
,
key
:
'code'
,
width
:
180
},
{
title
:
'报告编号'
,
key
:
'reportCode'
,
width
:
180
},
{
title
:
'类型'
,
key
:
'type'
,
width
:
80
,
type
:
true
},
{
title
:
'水深'
,
key
:
'waterDepth'
,
width
:
180
},
{
title
:
'状态'
,
key
:
'progress'
,
width
:
110
,
status
:
true
},
{
title
:
'状态'
,
key
:
'status'
,
width
:
110
,
status
:
true
},
{
title
:
'应出报告日期'
,
key
:
'reportDueDate'
,
width
:
130
,
date
:
true
},
{
title
:
'委托日期'
,
key
:
'entrustDate'
,
width
:
180
,
date
:
true
},
{
title
:
'是否判定'
,
key
:
'judge'
,
width
:
100
,
judge
:
true
},
{
title
:
'进度'
,
key
:
'progress'
,
width
:
110
,
status
:
true
},
{
{
title
:
'制表人'
,
key
:
'tabulater'
,
width
:
110
},
title
:
'报告剩余天数'
,
{
title
:
'制表日期'
,
key
:
'tabulateDate'
,
width
:
110
,
date
:
true
}
key
:
'reportRemainDay'
,
width
:
130
,
day
:
true
},
{
title
:
'报告进度统计'
,
key
:
'reportProgress'
,
width
:
450
},
{
title
:
'主联系人'
,
key
:
'linkman'
,
width
:
100
},
{
title
:
'联系手机'
,
key
:
'tel'
,
width
:
120
},
{
title
:
'检测类型'
,
key
:
'detectType'
,
width
:
130
},
{
title
:
'服务类型'
,
key
:
'serviceType'
,
width
:
120
},
{
title
:
'是否带照片'
,
key
:
'havePhoto'
,
width
:
120
},
{
title
:
'报告语言'
,
key
:
'reportType'
,
width
:
100
},
{
title
:
'报告类别'
,
key
:
'reportClass'
,
width
:
120
},
{
title
:
'备注'
,
key
:
'remark'
}
],
],
iconMsg
:
[
iconMsg
:
[
{
{
...
@@ -227,7 +215,7 @@ export default {
...
@@ -227,7 +215,7 @@ export default {
this
.
$refs
.
refModal
.
_open
(
data
)
this
.
$refs
.
refModal
.
_open
(
data
)
break
break
case
'操作记录'
:
case
'操作记录'
:
this
.
$refs
.
refModal
.
_open
(
data
.
id
)
this
.
_operationRecord
(
data
.
id
)
break
break
case
'附件'
:
case
'附件'
:
this
.
_upload
(
data
.
id
)
this
.
_upload
(
data
.
id
)
...
@@ -235,6 +223,10 @@ export default {
...
@@ -235,6 +223,10 @@ export default {
}
}
})
})
},
},
_operationRecord
(
id
)
{
// 操作日志
this
.
$refs
.
operation
.
_open
(
id
)
},
_tableResultChange
(
msg
,
data
)
{
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
switch
(
msg
)
{
case
'page'
:
case
'page'
:
...
@@ -254,7 +246,7 @@ export default {
...
@@ -254,7 +246,7 @@ export default {
},
},
_page
:
async
function
()
{
_page
:
async
function
()
{
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
const
result
=
await
soil
Test
.
pageExpTest
(
const
result
=
await
soil
Statistics
.
pageReportMake
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
...
pages/soil-test-manage/test-data-audit/DataAudit.vue
View file @
24f72b77
...
@@ -402,7 +402,7 @@ export default {
...
@@ -402,7 +402,7 @@ export default {
_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
soilTest
.
pageExp
Tes
t
(
const
result
=
await
soilTest
.
pageExp
Audi
t
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
...
pages/soil-test-manage/test-data-audit/item-tabs/ItemLeftList.vue
View file @
24f72b77
...
@@ -104,7 +104,7 @@ export default {
...
@@ -104,7 +104,7 @@ export default {
_page
:
async
function
()
{
_page
:
async
function
()
{
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
this
.
formObj
.
entrustId
=
this
.
id
this
.
formObj
.
entrustId
=
this
.
id
const
result
=
await
soilTest
.
page
Tes
tByExp
(
const
result
=
await
soilTest
.
page
Audi
tByExp
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
...
pages/soil-test-manage/test-data-audit/item-tabs/ItemRightList.vue
View file @
24f72b77
...
@@ -50,6 +50,7 @@
...
@@ -50,6 +50,7 @@
<!-- <SelectOriTempRecord ref="recordModal" @on-result-change="_page"></SelectOriTempRecord>-->
<!-- <SelectOriTempRecord ref="recordModal" @on-result-change="_page"></SelectOriTempRecord>-->
<!-- <OriginalRecordEdit ref="editModal"></OriginalRecordEdit>-->
<!-- <OriginalRecordEdit ref="editModal"></OriginalRecordEdit>-->
<IndexManage
ref=
"indexModal"
@
on-result-change=
"_page"
></IndexManage>
<IndexManage
ref=
"indexModal"
@
on-result-change=
"_page"
></IndexManage>
<Reason
ref=
"reasonModal"
@
on-result-change=
"_reasonResult"
></Reason>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
...
@@ -59,9 +60,11 @@ import AssignPerson from '../../../../components/user-info-single/AssignPerson'
...
@@ -59,9 +60,11 @@ import AssignPerson from '../../../../components/user-info-single/AssignPerson'
// import SelectOriTempRecord from '../SelectOriTempRecord'
// import SelectOriTempRecord from '../SelectOriTempRecord'
// import OriginalRecordEdit from '../OriginalRecordEdit'
// import OriginalRecordEdit from '../OriginalRecordEdit'
import
IndexManage
from
'../IndexManage'
import
IndexManage
from
'../IndexManage'
import
Reason
from
'../../../../components/base/Reason'
export
default
{
export
default
{
components
:
{
components
:
{
AssignPerson
,
AssignPerson
,
Reason
,
// SelectOriTempRecord,
// SelectOriTempRecord,
// OriginalRecordEdit,
// OriginalRecordEdit,
IndexManage
IndexManage
...
@@ -103,7 +106,7 @@ export default {
...
@@ -103,7 +106,7 @@ export default {
],
],
btn
:
[
btn
:
[
{
type
:
'success'
,
id
:
''
,
name
:
'提交'
},
{
type
:
'success'
,
id
:
''
,
name
:
'提交'
},
{
type
:
'
waring
'
,
id
:
''
,
name
:
'退回'
},
{
type
:
''
,
id
:
''
,
name
:
'退回'
},
{
type
:
''
,
id
:
'food-task-assign-adjust-group'
,
name
:
'调整分组'
},
{
type
:
''
,
id
:
'food-task-assign-adjust-group'
,
name
:
'调整分组'
},
{
{
type
:
''
,
type
:
''
,
...
@@ -157,6 +160,21 @@ export default {
...
@@ -157,6 +160,21 @@ export default {
// this._dicSearch()
// this._dicSearch()
},
},
methods
:
{
methods
:
{
_reasonResult
(
data
)
{
if
(
undefined
!==
data
&&
data
!==
''
)
{
this
.
_reportCheckBack
(
data
)
}
},
_reportCheckBack
:
async
function
(
data
)
{
const
result
=
await
soilTest
.
auditBack
({
ids
:
this
.
selectIds
,
remark
:
data
})
if
(
result
)
{
this
.
_resultChange
(
'退回成功'
)
}
},
_iconClick
(
res
,
data
,
currentComponent
)
{
_iconClick
(
res
,
data
,
currentComponent
)
{
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
switch
(
res
)
{
switch
(
res
)
{
...
@@ -170,6 +188,13 @@ export default {
...
@@ -170,6 +188,13 @@ export default {
}
}
})
})
},
},
_auditBack
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据'
)
}
else
{
this
.
$refs
.
reasonModal
.
_open
(
'退回原因'
)
}
},
_indexManage
(
data
)
{
_indexManage
(
data
)
{
this
.
$refs
.
indexModal
.
_open
(
data
)
this
.
$refs
.
indexModal
.
_open
(
data
)
},
},
...
@@ -322,6 +347,12 @@ export default {
...
@@ -322,6 +347,12 @@ export default {
// await this._reportDueDate()
// await this._reportDueDate()
// await this._userAssign()
// await this._userAssign()
break
break
case
'提交'
:
this
.
_submitToMake
()
break
case
'退回'
:
this
.
_auditBack
()
break
case
'试验项目分配'
:
case
'试验项目分配'
:
this
.
_userAssign
()
this
.
_userAssign
()
break
break
...
@@ -353,6 +384,25 @@ export default {
...
@@ -353,6 +384,25 @@ export default {
break
break
}
}
},
},
_submitToMake
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据'
)
}
else
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
'确定提交该数据?'
,
onOk
:
()
=>
{
this
.
_submitToMakeOk
()
}
})
}
},
_submitToMakeOk
:
async
function
()
{
const
result
=
await
soilTest
.
endExpAudit
(
this
.
selectIds
.
join
(
','
))
if
(
result
)
{
this
.
_resultChange
(
'提交成功'
)
}
},
_addRecord
()
{
_addRecord
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$message
.
warning
(
'请至少选择一条数据'
)
this
.
$message
.
warning
(
'请至少选择一条数据'
)
...
@@ -428,7 +478,7 @@ export default {
...
@@ -428,7 +478,7 @@ export default {
this
.
formObj
.
entrustId
=
this
.
entrustId
this
.
formObj
.
entrustId
=
this
.
entrustId
this
.
formObj
.
name
=
this
.
leftSelectData
.
name
this
.
formObj
.
name
=
this
.
leftSelectData
.
name
this
.
formObj
.
testMethod
=
this
.
leftSelectData
.
testMethod
this
.
formObj
.
testMethod
=
this
.
leftSelectData
.
testMethod
const
result
=
await
soilTest
.
pageExp
erimentTes
t
(
const
result
=
await
soilTest
.
pageExp
ByAudi
t
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
...
pages/soil-test-manage/test-data-check/DataCheck.vue
View file @
24f72b77
...
@@ -402,7 +402,7 @@ export default {
...
@@ -402,7 +402,7 @@ export default {
_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
soilTest
.
pageExp
Test
(
const
result
=
await
soilTest
.
pageExp
Check
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
...
pages/soil-test-manage/test-data-check/item-tabs/ItemLeftList.vue
View file @
24f72b77
...
@@ -104,7 +104,7 @@ export default {
...
@@ -104,7 +104,7 @@ export default {
_page
:
async
function
()
{
_page
:
async
function
()
{
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
Object
.
assign
(
this
.
formObj
,
this
.
$refs
.
pageTable
.
_searchParams
())
this
.
formObj
.
entrustId
=
this
.
id
this
.
formObj
.
entrustId
=
this
.
id
const
result
=
await
soilTest
.
page
Test
ByExp
(
const
result
=
await
soilTest
.
page
Check
ByExp
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
...
pages/soil-test-manage/test-data-check/item-tabs/ItemRightList.vue
View file @
24f72b77
...
@@ -50,6 +50,7 @@
...
@@ -50,6 +50,7 @@
<!-- <SelectOriTempRecord ref="recordModal" @on-result-change="_page"></SelectOriTempRecord>-->
<!-- <SelectOriTempRecord ref="recordModal" @on-result-change="_page"></SelectOriTempRecord>-->
<!-- <OriginalRecordEdit ref="editModal"></OriginalRecordEdit>-->
<!-- <OriginalRecordEdit ref="editModal"></OriginalRecordEdit>-->
<IndexManage
ref=
"indexModal"
@
on-result-change=
"_page"
></IndexManage>
<IndexManage
ref=
"indexModal"
@
on-result-change=
"_page"
></IndexManage>
<Reason
ref=
"reasonModal"
@
on-result-change=
"_reasonResult"
></Reason>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
...
@@ -59,9 +60,11 @@ import AssignPerson from '../../../../components/user-info-single/AssignPerson'
...
@@ -59,9 +60,11 @@ import AssignPerson from '../../../../components/user-info-single/AssignPerson'
// import SelectOriTempRecord from '../SelectOriTempRecord'
// import SelectOriTempRecord from '../SelectOriTempRecord'
// import OriginalRecordEdit from '../OriginalRecordEdit'
// import OriginalRecordEdit from '../OriginalRecordEdit'
import
IndexManage
from
'../IndexManage'
import
IndexManage
from
'../IndexManage'
import
Reason
from
'../../../../components/base/Reason'
export
default
{
export
default
{
components
:
{
components
:
{
AssignPerson
,
AssignPerson
,
Reason
,
// SelectOriTempRecord,
// SelectOriTempRecord,
// OriginalRecordEdit,
// OriginalRecordEdit,
IndexManage
IndexManage
...
@@ -157,6 +160,21 @@ export default {
...
@@ -157,6 +160,21 @@ export default {
// this._dicSearch()
// this._dicSearch()
},
},
methods
:
{
methods
:
{
_reasonResult
(
data
)
{
if
(
undefined
!==
data
&&
data
!==
''
)
{
this
.
_reportCheckBack
(
data
)
}
},
_reportCheckBack
:
async
function
(
data
)
{
const
result
=
await
soilTest
.
checkBack
({
ids
:
this
.
selectIds
,
remark
:
data
})
if
(
result
)
{
this
.
_resultChange
(
'退回成功'
)
}
},
_iconClick
(
res
,
data
,
currentComponent
)
{
_iconClick
(
res
,
data
,
currentComponent
)
{
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
switch
(
res
)
{
switch
(
res
)
{
...
@@ -328,6 +346,12 @@ export default {
...
@@ -328,6 +346,12 @@ export default {
case
'填写原始记录'
:
case
'填写原始记录'
:
this
.
_addRecord
()
this
.
_addRecord
()
break
break
case
'提交'
:
this
.
_submitToAudit
()
break
case
'退回'
:
this
.
_checkBack
()
break
case
'按组分配'
:
case
'按组分配'
:
await
this
.
_reportDueDate
()
await
this
.
_reportDueDate
()
await
this
.
_groupAssign
()
await
this
.
_groupAssign
()
...
@@ -353,6 +377,32 @@ export default {
...
@@ -353,6 +377,32 @@ export default {
break
break
}
}
},
},
_checkBack
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据'
)
}
else
{
this
.
$refs
.
reasonModal
.
_open
(
'退回原因'
)
}
},
_submitToAudit
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请至少选择一条数据'
)
}
else
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
'确定提交该数据?'
,
onOk
:
()
=>
{
this
.
_submitToAuditOk
()
}
})
}
},
_submitToAuditOk
:
async
function
()
{
const
result
=
await
soilTest
.
endExpCheck
(
this
.
selectIds
.
join
(
','
))
if
(
result
)
{
this
.
_resultChange
(
'提交成功'
)
}
},
_addRecord
()
{
_addRecord
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$message
.
warning
(
'请至少选择一条数据'
)
this
.
$message
.
warning
(
'请至少选择一条数据'
)
...
@@ -428,7 +478,7 @@ export default {
...
@@ -428,7 +478,7 @@ export default {
this
.
formObj
.
entrustId
=
this
.
entrustId
this
.
formObj
.
entrustId
=
this
.
entrustId
this
.
formObj
.
name
=
this
.
leftSelectData
.
name
this
.
formObj
.
name
=
this
.
leftSelectData
.
name
this
.
formObj
.
testMethod
=
this
.
leftSelectData
.
testMethod
this
.
formObj
.
testMethod
=
this
.
leftSelectData
.
testMethod
const
result
=
await
soilTest
.
pageExp
erimentTest
(
const
result
=
await
soilTest
.
pageExp
ByCheck
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
...
pages/soil-test-manage/test-input/item-tabs/ItemRightList.vue
View file @
24f72b77
...
@@ -38,6 +38,7 @@
...
@@ -38,6 +38,7 @@
<span
<span
v-else-if=
"item.date"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd'
):
''
}}
</span>
v-else-if=
"item.date"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd'
):
''
}}
</span>
<span
v-else-if=
"item.datetime"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd HH:MM'
):
''
}}
</span>
<span
v-else-if=
"item.datetime"
>
{{
scope
.
row
[
item
.
key
]?
$dateformat
(
scope
.
row
[
item
.
key
],
'yyyy-mm-dd HH:MM'
):
''
}}
</span>
<span
v-else-if=
"item.key==='progress'"
>
{{
scope
.
row
[
item
.
key
].
display
}}
</span>
<span
v-else
>
{{
scope
.
row
[
item
.
key
]
}}
</span>
<span
v-else
>
{{
scope
.
row
[
item
.
key
]
}}
</span>
</
template
>
</
template
>
</vxe-table-column>
</vxe-table-column>
...
@@ -103,6 +104,7 @@ export default {
...
@@ -103,6 +104,7 @@ export default {
],
],
btn
:
[
btn
:
[
{
type
:
'success'
,
id
:
''
,
name
:
'填写原始记录'
},
{
type
:
'success'
,
id
:
''
,
name
:
'填写原始记录'
},
{
type
:
'success'
,
id
:
''
,
name
:
'完成提交'
},
{
type
:
''
,
id
:
'food-task-assign-adjust-group'
,
name
:
'调整分组'
},
{
type
:
''
,
id
:
'food-task-assign-adjust-group'
,
name
:
'调整分组'
},
{
{
type
:
''
,
type
:
''
,
...
@@ -122,9 +124,9 @@ export default {
...
@@ -122,9 +124,9 @@ export default {
{
title
:
'试样深度'
,
key
:
'sampleDepth'
,
width
:
180
},
{
title
:
'试样深度'
,
key
:
'sampleDepth'
,
width
:
180
},
{
title
:
'试样包装类型'
,
key
:
'samplePack'
,
width
:
180
},
{
title
:
'试样包装类型'
,
key
:
'samplePack'
,
width
:
180
},
{
title
:
'是否填写原始记录'
,
key
:
'recorded'
,
width
:
180
},
{
title
:
'是否填写原始记录'
,
key
:
'recorded'
,
width
:
180
},
{
title
:
'状态'
,
key
:
'progress'
,
width
:
180
},
{
title
:
'大类'
,
key
:
'mainType'
,
width
:
140
},
{
title
:
'大类'
,
key
:
'mainType'
,
width
:
140
},
{
title
:
'小类'
,
key
:
'smallType'
,
width
:
140
},
{
title
:
'小类'
,
key
:
'smallType'
,
width
:
140
},
{
title
:
'原始记录是否填写'
,
key
:
'recorded'
,
width
:
140
},
{
title
:
'检测方法'
,
key
:
'testMethod'
,
width
:
260
},
{
title
:
'检测方法'
,
key
:
'testMethod'
,
width
:
260
},
{
title
:
'检测依据'
,
key
:
'testBasis'
,
width
:
140
},
{
title
:
'检测依据'
,
key
:
'testBasis'
,
width
:
140
},
{
title
:
'检测科室'
,
key
:
'groupName'
,
width
:
150
}
{
title
:
'检测科室'
,
key
:
'groupName'
,
width
:
150
}
...
@@ -328,6 +330,9 @@ export default {
...
@@ -328,6 +330,9 @@ export default {
case
'填写原始记录'
:
case
'填写原始记录'
:
this
.
_addRecord
()
this
.
_addRecord
()
break
break
case
'完成提交'
:
this
.
_submitItem
(
this
.
selectData
)
break
case
'按组分配'
:
case
'按组分配'
:
await
this
.
_reportDueDate
()
await
this
.
_reportDueDate
()
await
this
.
_groupAssign
()
await
this
.
_groupAssign
()
...
@@ -353,6 +358,26 @@ export default {
...
@@ -353,6 +358,26 @@ export default {
break
break
}
}
},
},
_submitItem
(
data
)
{
console
.
log
(
data
)
if
(
data
[
0
].
recorded
!==
'是'
)
{
this
.
$Message
.
warning
(
'未编制报告不能提交'
)
}
else
{
this
.
$Modal
.
confirm
({
title
:
'提示'
,
content
:
'确定提交该数据?'
,
onOk
:
()
=>
{
this
.
_submitOk
()
}
})
}
},
_submitOk
:
async
function
()
{
const
result
=
await
soilTest
.
endExp
(
this
.
selectIds
.
join
(
','
))
if
(
result
)
{
this
.
_resultChange
(
'提交成功'
)
}
},
_addRecord
()
{
_addRecord
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$message
.
warning
(
'请至少选择一条数据'
)
this
.
$message
.
warning
(
'请至少选择一条数据'
)
...
...
router/soil-routes.js
View file @
24f72b77
...
@@ -23,6 +23,8 @@ import yearDeclara from '../pages/soil-statistics/yearDeclara'
...
@@ -23,6 +23,8 @@ import yearDeclara from '../pages/soil-statistics/yearDeclara'
import
MeterCustomerEntrust
from
'../pages/soil-statistics/customer-entrust/MeterCustomerEntrust'
import
MeterCustomerEntrust
from
'../pages/soil-statistics/customer-entrust/MeterCustomerEntrust'
import
MeterPersonalTask
from
'../pages/soil-statistics/personal-task/MeterPersonalTask'
import
MeterPersonalTask
from
'../pages/soil-statistics/personal-task/MeterPersonalTask'
import
MeterAnnualEntrust
from
'../pages/soil-statistics/annual-entrust/MeterAnnualEntrust'
import
MeterAnnualEntrust
from
'../pages/soil-statistics/annual-entrust/MeterAnnualEntrust'
import
ReportAuditIndex
from
'../pages/soil-report-manage/report-audit/ReportAuditIndex'
import
ReportIssueIndex
from
'../pages/soil-report-manage/report-issue/ReportIssueIndex'
import
Blank
from
'~/pages/blank'
import
Blank
from
'~/pages/blank'
export
default
[
export
default
[
{
{
...
@@ -116,6 +118,16 @@ export default [
...
@@ -116,6 +118,16 @@ export default [
path
:
'make_report'
,
path
:
'make_report'
,
component
:
ReportMakeIndex
,
component
:
ReportMakeIndex
,
meta
:
{
title
:
'报告编制'
}
meta
:
{
title
:
'报告编制'
}
},
{
path
:
'report_audit'
,
component
:
ReportAuditIndex
,
meta
:
{
title
:
'报告审核'
}
},
{
path
:
'report_issue'
,
component
:
ReportIssueIndex
,
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