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
d234bf7b
Commit
d234bf7b
authored
Sep 22, 2020
by
lichengming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改了试验任务分配
parent
9241ce6a
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
150 additions
and
116 deletions
+150
-116
soil-test.js
api/soil/soil-test.js
+12
-1
PTVXETable.vue
components/table/PTVXETable.vue
+0
-1
assignPerson.vue
components/user-info-single/assignPerson.vue
+13
-0
SoilSampleItemManage.vue
pages/meter-entrust/SoilSampleItemManage.vue
+10
-15
EntrustRegisterEdit.vue
pages/meter-entrust/entrust-register/EntrustRegisterEdit.vue
+2
-1
TestInputIndex.vue
pages/soil-test-manage/test-input/TestInputIndex.vue
+0
-0
AllotByEntrust.vue
pages/soil-test-manage/test-task-manage/AllotByEntrust.vue
+0
-10
SampleManage.vue
...e/test-task-manage/entrust-sample-manage/SampleManage.vue
+6
-3
ItemLeftList.vue
...k-manage/entrust-sample-manage/item-tabs/ItemLeftList.vue
+3
-3
ItemRightList.vue
...-manage/entrust-sample-manage/item-tabs/ItemRightList.vue
+10
-3
SampleLeftList.vue
...nage/entrust-sample-manage/sample-tabs/SampleLeftList.vue
+21
-12
SampleRightList.vue
...age/entrust-sample-manage/sample-tabs/SampleRightList.vue
+69
-63
SampleTabs.vue
...k-manage/entrust-sample-manage/sample-tabs/SampleTabs.vue
+2
-3
soil-routes.js
router/soil-routes.js
+2
-1
No files found.
api/soil/soil-test.js
View file @
d234bf7b
...
@@ -8,5 +8,16 @@ import http from '../http'
...
@@ -8,5 +8,16 @@ import http from '../http'
export
default
{
export
default
{
// page
// page
pageExpAllot
:
data
=>
pageExpAllot
:
data
=>
http
.
post
(
'soil/v1/entrust/page_exp_allot'
,
data
).
then
(
res
=>
res
)
http
.
post
(
'soil/v1/entrust/page_exp_allot'
,
data
).
then
(
res
=>
res
),
// 试验任务分配按样品分配分页列表
pageExpAllotSample
:
data
=>
http
.
post
(
'soil/v1/sample/page_exp_allot_sample'
,
data
).
then
(
res
=>
res
),
// 试验任务按样品分配-试验项目分配操作
allotExp
:
data
=>
http
.
post
(
'soil/v1/experiment/allot_exp'
,
data
).
then
(
res
=>
res
),
// 试验任务分配样品对应检测项目分页列表
pageAllot
:
data
=>
http
.
post
(
'soil/v1/experiment/page_allot'
,
data
).
then
(
res
=>
res
),
pageExpTest
:
data
=>
http
.
post
(
'soil/v1/entrust/page_exp_test'
,
data
).
then
(
res
=>
res
)
}
}
components/table/PTVXETable.vue
View file @
d234bf7b
...
@@ -261,7 +261,6 @@ export default {
...
@@ -261,7 +261,6 @@ export default {
if
(
this
.
hideCheckbox
===
undefined
||
this
.
hideCheckbox
===
false
)
{
if
(
this
.
hideCheckbox
===
undefined
||
this
.
hideCheckbox
===
false
)
{
const
selData
=
data
.
selection
const
selData
=
data
.
selection
this
.
checkData
=
selData
this
.
checkData
=
selData
console
.
log
(
'checkData'
,
this
.
checkData
)
// 默认返回的是id数组
// 默认返回的是id数组
if
(
this
.
selectData
===
undefined
)
{
if
(
this
.
selectData
===
undefined
)
{
const
idList
=
[]
const
idList
=
[]
...
...
components/user-info-single/assignPerson.vue
View file @
d234bf7b
...
@@ -124,6 +124,19 @@ export default {
...
@@ -124,6 +124,19 @@ export default {
this
.
$refs
.
userCheck
.
_refresh
()
this
.
$refs
.
userCheck
.
_refresh
()
this
.
$refs
.
marshalling
.
_uidOpen
(
uid
)
this
.
$refs
.
marshalling
.
_uidOpen
(
uid
)
},
},
_openGoup
(
modalTitle
,
treeName
)
{
this
.
modalTitle
=
modalTitle
this
.
changeBool
=
false
this
.
showUserModal
=
true
this
.
titleChange
=
'用户编组'
if
(
treeName
===
undefined
)
{
this
.
treeName
=
'userMan'
}
else
{
this
.
treeName
=
treeName
}
this
.
$refs
.
userCheck
.
_refresh
()
this
.
$refs
.
marshalling
.
_open
()
},
// 当前登录用户所处的组织
// 当前登录用户所处的组织
_getCurrentOrg
:
async
function
()
{
_getCurrentOrg
:
async
function
()
{
const
result
=
await
sysOrg
.
getOrg
()
const
result
=
await
sysOrg
.
getOrg
()
...
...
pages/meter-entrust/SoilSampleItemManage.vue
View file @
d234bf7b
...
@@ -31,7 +31,7 @@
...
@@ -31,7 +31,7 @@
<!-- 表格 -->
<!-- 表格 -->
<Col
span=
"24"
>
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:table-height=
"tableHeight"
:form-id=
"formId"
:loading=
"true"
<PTVXETable
ref=
"pageTable"
:table-height=
"tableHeight"
:form-id=
"formId"
:loading=
"true"
:get-page=
"getPage"
:icon-msg=
"iconMsg"
@
on-result-change=
"_tableResultChange"
>
:get-page=
"getPage"
@
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"
...
@@ -54,7 +54,7 @@
...
@@ -54,7 +54,7 @@
</el-select>
</el-select>
<span
v-if=
"!showOption"
>
{{
scope
.
row
[
item
.
key
]
===
0
?
'否'
:
'是'
}}
</span>
<span
v-if=
"!showOption"
>
{{
scope
.
row
[
item
.
key
]
===
0
?
'否'
:
'是'
}}
</span>
</div>
</div>
<div
v-else-if=
"item.key==='
progres
s'"
>
<div
v-else-if=
"item.key==='
statu
s'"
>
{{
scope
.
row
[
item
.
key
].
display
}}
{{
scope
.
row
[
item
.
key
].
display
}}
</div>
</div>
<div
v-else-if=
"item.judged"
>
<div
v-else-if=
"item.judged"
>
...
@@ -119,6 +119,7 @@ export default {
...
@@ -119,6 +119,7 @@ export default {
components
:
{},
components
:
{},
data
()
{
data
()
{
return
{
return
{
formId
:
'SampleItemManage'
,
currentComponent
:
''
,
currentComponent
:
''
,
btn
:
[
btn
:
[
{
type
:
'success'
,
id
:
''
,
name
:
'提交分包'
},
{
type
:
'success'
,
id
:
''
,
name
:
'提交分包'
},
...
@@ -142,19 +143,13 @@ export default {
...
@@ -142,19 +143,13 @@ export default {
{
id
:
''
,
name
:
'关闭'
,
type
:
'primary'
}
{
id
:
''
,
name
:
'关闭'
,
type
:
'primary'
}
],
],
pageColumns
:
[
pageColumns
:
[
{
title
:
'项目类别'
,
key
:
'type'
,
width
:
160
},
{
title
:
'试验名称'
,
key
:
'name'
,
width
:
160
},
{
title
:
'检测项目'
,
key
:
'name'
,
width
:
140
},
{
title
:
'试验项目英文简写'
,
key
:
'shortName'
,
width
:
140
},
{
title
:
'子项目'
,
key
:
'sonItem'
,
width
:
140
},
{
title
:
'大类'
,
key
:
'mainType'
,
width
:
140
},
{
title
:
'是否分包'
,
key
:
'epibolyItem'
},
{
title
:
'小类'
,
key
:
'smallType'
},
{
title
:
'方法'
,
key
:
'method'
,
width
:
180
},
{
title
:
'检测依据'
,
key
:
'testBasis'
,
width
:
180
},
{
title
:
'设备'
,
key
:
'device'
,
width
:
180
},
{
title
:
'试验方法'
,
key
:
'testMethod'
,
width
:
180
},
{
title
:
'检测依据'
,
key
:
'code'
,
width
:
180
},
{
title
:
'状态'
,
key
:
'status'
,
width
:
180
}
{
title
:
'检测科室'
,
key
:
'groupName'
,
width
:
110
},
{
title
:
'比较符'
,
key
:
'compareSymbol'
,
width
:
100
},
{
title
:
'限值'
,
key
:
'limitValue'
},
{
title
:
'单位'
,
key
:
'unit'
},
{
title
:
'是否系统判定'
,
key
:
'judged'
,
width
:
120
,
judged
:
true
},
{
title
:
'备注'
,
key
:
'remark'
}
],
],
subOptions
:
[
subOptions
:
[
{
{
...
...
pages/meter-entrust/entrust-register/EntrustRegisterEdit.vue
View file @
d234bf7b
...
@@ -685,6 +685,7 @@ export default {
...
@@ -685,6 +685,7 @@ export default {
this
.
showModal
=
false
this
.
showModal
=
false
},
},
_open
(
formObj
)
{
_open
(
formObj
)
{
this
.
_getList
()
this
.
showBtn
=
true
this
.
showBtn
=
true
this
.
showModal
=
true
this
.
showModal
=
true
this
.
$refs
.
formObj
.
resetFields
()
this
.
$refs
.
formObj
.
resetFields
()
...
@@ -702,6 +703,7 @@ export default {
...
@@ -702,6 +703,7 @@ export default {
}
}
},
},
_openEdit
(
formObj
)
{
_openEdit
(
formObj
)
{
this
.
_getList
()
this
.
showBtn
=
false
this
.
showBtn
=
false
this
.
showModal
=
true
this
.
showModal
=
true
this
.
$refs
.
formObj
.
resetFields
()
this
.
$refs
.
formObj
.
resetFields
()
...
@@ -723,7 +725,6 @@ export default {
...
@@ -723,7 +725,6 @@ export default {
// }
// }
// }
// }
},
},
_showTime
(
formObj
)
{
_showTime
(
formObj
)
{
if
(
this
.
formObj
.
entrustDate
===
undefined
)
{
if
(
this
.
formObj
.
entrustDate
===
undefined
)
{
this
.
formObj
.
entrustDate
=
''
this
.
formObj
.
entrustDate
=
''
...
...
pages/soil-test-manage/test-input/TestInputIndex.vue
0 → 100644
View file @
d234bf7b
This diff is collapsed.
Click to expand it.
pages/soil-test-manage/test-task-manage/AllotByEntrust.vue
View file @
d234bf7b
...
@@ -93,16 +93,6 @@ export default {
...
@@ -93,16 +93,6 @@ export default {
id
:
''
,
id
:
''
,
name
:
'管理样品'
name
:
'管理样品'
},
},
{
type
:
'ios-list'
,
id
:
''
,
name
:
'项目管理'
},
{
type
:
'md-create'
,
id
:
''
,
name
:
'编辑协议'
},
{
type
:
'md-cloud'
,
id
:
''
,
name
:
'附件'
},
{
type
:
'md-cloud'
,
id
:
''
,
name
:
'附件'
},
{
type
:
'md-trash'
,
id
:
''
,
name
:
'删除'
},
{
type
:
'md-trash'
,
id
:
''
,
name
:
'删除'
},
{
{
...
...
pages/soil-test-manage/test-task-manage/entrust-sample-manage/SampleManage.vue
View file @
d234bf7b
...
@@ -29,6 +29,7 @@ export default {
...
@@ -29,6 +29,7 @@ export default {
return
{
return
{
type
:
''
,
type
:
''
,
contractId
:
''
,
// 合同id
contractId
:
''
,
// 合同id
entrustId
:
''
,
showSampleModal
:
false
,
showSampleModal
:
false
,
modalTitle
:
''
,
modalTitle
:
''
,
selectIds
:
[],
selectIds
:
[],
...
@@ -58,7 +59,7 @@ export default {
...
@@ -58,7 +59,7 @@ export default {
},
},
// 待发放
// 待发放
_waitSend
()
{
_waitSend
()
{
this
.
$refs
.
waitScanModal
.
_open
()
this
.
$refs
.
waitScanModal
.
_open
(
this
.
entrustId
)
},
},
// 已接收
// 已接收
_issuedPage
()
{
_issuedPage
()
{
...
@@ -66,11 +67,13 @@ export default {
...
@@ -66,11 +67,13 @@ export default {
},
},
_changeTabs
(
tab
,
event
)
{
_changeTabs
(
tab
,
event
)
{
if
(
tab
.
name
===
'alreadyIssued'
)
{
if
(
tab
.
name
===
'alreadyIssued'
)
{
this
.
_issuedPage
()
//
this._issuedPage()
}
else
if
(
tab
.
name
===
'waitReceive'
)
{
}
else
if
(
tab
.
name
===
'waitReceive'
)
{
// this._waitPage()
// this._waitPage()
this
.
$refs
.
waitReceiveModal
.
_open
()
}
else
if
(
tab
.
name
===
'waitScan'
)
{
}
else
if
(
tab
.
name
===
'waitScan'
)
{
this
.
_waitSend
()
this
.
$refs
.
waitScanModal
.
_open
(
this
.
entrustId
)
// this._waitSend()
}
}
},
},
_search
()
{
_search
()
{
...
...
pages/soil-test-manage/test-task-manage/entrust-sample-manage/item-tabs/ItemLeftList.vue
View file @
d234bf7b
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
</Form>
</Form>
</Col>
</Col>
<Col
span=
"24"
>
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
@
on-result-change=
"_btnClick"
class=
"contHide"
></btn-list>
<btn-list
:msg=
"btn"
@
on-result-change=
"_btnClick"
class=
"contHide"
style=
"margin-bottom: 6px;"
></btn-list>
</Col>
</Col>
<!-- 表格 -->
<!-- 表格 -->
<Col
span=
"24"
>
<Col
span=
"24"
>
...
@@ -59,7 +59,6 @@ export default {
...
@@ -59,7 +59,6 @@ export default {
{
key
:
'name'
,
name
:
'检测项目'
,
placeholder
:
'请输入检测项目'
},
{
key
:
'name'
,
name
:
'检测项目'
,
placeholder
:
'请输入检测项目'
},
{
key
:
'testBasis'
,
name
:
'检测依据'
,
placeholder
:
'请输入检测依据'
}
{
key
:
'testBasis'
,
name
:
'检测依据'
,
placeholder
:
'请输入检测依据'
}
],
],
btn
:
[{
id
:
''
,
name
:
'自动分配'
}],
getPage
:
{},
getPage
:
{},
pageColumns
:
[
pageColumns
:
[
{
title
:
'检测项目'
,
key
:
'name'
,
width
:
120
},
{
title
:
'检测项目'
,
key
:
'name'
,
width
:
120
},
...
@@ -139,7 +138,8 @@ export default {
...
@@ -139,7 +138,8 @@ export default {
}
}
},
},
_autoAssign
()
{
_autoAssign
()
{
this
.
$refs
.
autoAssignModal
.
_open
()
console
.
log
(
'自动分配'
)
// this.$refs.autoAssignModal._open()
// this.$store.dispatch('FoodItem/autoAllotNum').then(() => {
// this.$store.dispatch('FoodItem/autoAllotNum').then(() => {
// const num = this.$store.state.FoodItem.count
// const num = this.$store.state.FoodItem.count
// if (num !== undefined) {
// if (num !== undefined) {
...
...
pages/soil-test-manage/test-task-manage/entrust-sample-manage/item-tabs/ItemRightList.vue
View file @
d234bf7b
...
@@ -46,13 +46,15 @@
...
@@ -46,13 +46,15 @@
</PTVXETable>
</PTVXETable>
</Col>
</Col>
</Row>
</Row>
<AssignPerson
ref=
"personModal"
@
on-result-change=
"_page"
></AssignPerson>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
Global
from
'../../../../../api/config'
import
Global
from
'../../../../../api/config'
import
{
soilTest
}
from
'../../../../../api'
import
{
soilTest
}
from
'../../../../../api'
import
AssignPerson
from
'../../../../../components/user-info-single/AssignPerson'
export
default
{
export
default
{
components
:
{},
components
:
{
AssignPerson
},
data
()
{
data
()
{
return
{
return
{
// 定义表格名称----英文
// 定义表格名称----英文
...
@@ -267,8 +269,9 @@ export default {
...
@@ -267,8 +269,9 @@ export default {
async
_btnClick
(
msg
)
{
async
_btnClick
(
msg
)
{
switch
(
msg
)
{
switch
(
msg
)
{
case
'按人分配'
:
case
'按人分配'
:
await
this
.
_reportDueDate
()
this
.
_allotByPerson
()
await
this
.
_userAssign
()
// await this._reportDueDate()
// await this._userAssign()
break
break
case
'按组分配'
:
case
'按组分配'
:
await
this
.
_reportDueDate
()
await
this
.
_reportDueDate
()
...
@@ -295,6 +298,10 @@ export default {
...
@@ -295,6 +298,10 @@ export default {
break
break
}
}
},
},
_allotByPerson
()
{
const
user
=
Global
.
getUserInfo
(
'userInfo'
)
this
.
$refs
.
personModal
.
_openGoupByUserId
(
'分配人员'
,
user
.
id
,
'itemTree'
)
},
// 信息维护
// 信息维护
_maintainInfo
()
{
_maintainInfo
()
{
if
(
this
.
selectSampleIds
.
length
===
0
)
{
if
(
this
.
selectSampleIds
.
length
===
0
)
{
...
...
pages/soil-test-manage/test-task-manage/entrust-sample-manage/sample-tabs/SampleLeftList.vue
View file @
d234bf7b
...
@@ -14,13 +14,13 @@
...
@@ -14,13 +14,13 @@
</Form>
</Form>
</Col>
</Col>
<Col
span=
"24"
>
<Col
span=
"24"
>
<btn-list
:msg=
"btn"
@
on-result-change=
"_btnClick"
class=
"contHide
"
></btn-list>
<btn-list
@
on-result-change=
"_btnClick"
class=
"contHide"
style=
"margin-bottom: 6px;
"
></btn-list>
</Col>
</Col>
<!-- 表格 -->
<!-- 表格 -->
<Col
span=
"24"
>
<Col
span=
"24"
>
<PTVXETable
ref=
"pageTable"
:pageColumns=
"pageColumns"
:table-name=
"tableName"
<PTVXETable
ref=
"pageTable"
:pageColumns=
"pageColumns"
:table-name=
"tableName"
:tableHeight=
"tableHeight"
:tableHeight=
"tableHeight"
@
on-result-change=
"_tableResultChange"
:getPage=
"getPage"
:rows=
"100"
select-data
>
@
on-result-change=
"_tableResultChange"
:getPage=
"getPage"
:rows=
"100"
>
<vxe-table-column
<vxe-table-column
v-for=
"item in userColumns.length > 0 ?userColumns:pageColumns"
v-for=
"item in userColumns.length > 0 ?userColumns:pageColumns"
:key=
"item.key"
:key=
"item.key"
...
@@ -50,20 +50,23 @@ export default {
...
@@ -50,20 +50,23 @@ export default {
data
()
{
data
()
{
return
{
return
{
currentComponent
:
''
,
currentComponent
:
''
,
formObj
:
{},
formObj
:
{
entrustId
:
undefined
},
entrustId
:
''
,
tableName
:
'food-task-assign-item-left'
,
tableName
:
'food-task-assign-item-left'
,
// 用户自己选中的列
// 用户自己选中的列
userColumns
:
[],
userColumns
:
[],
selectIds
:
[],
optionList
:
[
optionList
:
[
{
key
:
'name'
,
name
:
'检测项目'
,
placeholder
:
'请输入检测项目'
},
{
key
:
'name'
,
name
:
'检测项目'
,
placeholder
:
'请输入检测项目'
},
{
key
:
'testBasis'
,
name
:
'检测依据'
,
placeholder
:
'请输入检测依据'
}
{
key
:
'testBasis'
,
name
:
'检测依据'
,
placeholder
:
'请输入检测依据'
}
],
],
btn
:
[{
id
:
''
,
name
:
'自动分配'
}],
getPage
:
{},
getPage
:
{},
pageColumns
:
[
pageColumns
:
[
{
title
:
'
检测项目'
,
key
:
'nam
e'
,
width
:
120
},
{
title
:
'
试样编号'
,
key
:
'sampleCod
e'
,
width
:
120
},
{
title
:
'
检测依据'
,
key
:
'testBasis
'
,
width
:
140
},
{
title
:
'
委托编号'
,
key
:
'entrustCode
'
,
width
:
140
},
{
title
:
'
检测依据名称'
,
key
:
'testBasisName
'
,
width
:
200
}
{
title
:
'
委托商'
,
key
:
'client
'
,
width
:
200
}
]
]
}
}
},
},
...
@@ -90,7 +93,8 @@ export default {
...
@@ -90,7 +93,8 @@ export default {
break
break
}
}
},
},
_open
()
{
_open
(
id
)
{
this
.
entrustId
=
id
this
.
_page
()
this
.
_page
()
},
},
_searchParams
()
{
_searchParams
()
{
...
@@ -101,7 +105,8 @@ export default {
...
@@ -101,7 +105,8 @@ 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
soilTest
.
pageExpAllot
(
this
.
formObj
.
entrustId
=
this
.
entrustId
const
result
=
await
soilTest
.
pageExpAllotSample
(
this
.
$serializeForm
(
this
.
formObj
)
this
.
$serializeForm
(
this
.
formObj
)
)
)
if
(
result
)
{
if
(
result
)
{
...
@@ -112,10 +117,14 @@ export default {
...
@@ -112,10 +117,14 @@ export default {
_tableResultChange
(
msg
,
data
)
{
_tableResultChange
(
msg
,
data
)
{
switch
(
msg
)
{
switch
(
msg
)
{
case
'page'
:
case
'page'
:
this
.
getPage
=
this
.
$store
.
state
.
FoodItem
.
page
this
.
_page
()
break
break
case
'selectData'
:
// case 'selectData':
this
.
$emit
(
'on-result-change'
,
data
)
// this.$emit('on-result-change', data)
// break
case
'selectIds'
:
this
.
selectIds
=
data
this
.
$emit
(
'on-result-change'
,
this
.
selectIds
.
join
(
','
))
break
break
case
'changeSize'
:
case
'changeSize'
:
this
.
_page
()
this
.
_page
()
...
...
pages/soil-test-manage/test-task-manage/entrust-sample-manage/sample-tabs/SampleRightList.vue
View file @
d234bf7b
...
@@ -35,6 +35,7 @@
...
@@ -35,6 +35,7 @@
</div>
</div>
<a
v-else-if=
"item.key==='code'"
@
click
.
stop=
"_detailModal(scope.row)"
>
{{
scope
.
row
[
item
.
key
]
}}
</a>
<a
v-else-if=
"item.key==='code'"
@
click
.
stop=
"_detailModal(scope.row)"
>
{{
scope
.
row
[
item
.
key
]
}}
</a>
<a
v-else-if=
"item.key==='num'"
@
click
.
stop=
"_sampleDetail(scope.row)"
>
{{
scope
.
row
[
item
.
key
]
}}
</a>
<a
v-else-if=
"item.key==='num'"
@
click
.
stop=
"_sampleDetail(scope.row)"
>
{{
scope
.
row
[
item
.
key
]
}}
</a>
<span
v-else-if=
"item.key==='status'"
>
{{
scope
.
row
[
item
.
key
].
display
}}
</span>
<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>
...
@@ -46,13 +47,15 @@
...
@@ -46,13 +47,15 @@
</PTVXETable>
</PTVXETable>
</Col>
</Col>
</Row>
</Row>
<AssignPerson
ref=
"personModal"
@
on-result-change=
"_assignBackData"
></AssignPerson>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
Global
from
'../../../../../api/config'
import
Global
from
'../../../../../api/config'
import
{
soilTest
}
from
'../../../../../api'
import
{
soilTest
}
from
'../../../../../api'
import
AssignPerson
from
'../../../../../components/user-info-single/AssignPerson'
export
default
{
export
default
{
components
:
{},
components
:
{
AssignPerson
},
data
()
{
data
()
{
return
{
return
{
// 定义表格名称----英文
// 定义表格名称----英文
...
@@ -83,8 +86,7 @@ export default {
...
@@ -83,8 +86,7 @@ export default {
{
key
:
'detectType'
,
name
:
'样品类别'
,
placeholder
:
'请输入样品类别'
}
{
key
:
'detectType'
,
name
:
'样品类别'
,
placeholder
:
'请输入样品类别'
}
],
],
btn
:
[
btn
:
[
{
type
:
'success'
,
id
:
''
,
name
:
'按人分配'
},
{
type
:
'success'
,
id
:
''
,
name
:
'试验项目分配'
},
{
type
:
'warning'
,
id
:
''
,
name
:
'按组分配'
},
{
type
:
''
,
id
:
'food-task-assign-adjust-group'
,
name
:
'调整分组'
},
{
type
:
''
,
id
:
'food-task-assign-adjust-group'
,
name
:
'调整分组'
},
{
{
type
:
''
,
type
:
''
,
...
@@ -95,27 +97,16 @@ export default {
...
@@ -95,27 +97,16 @@ export default {
],
],
getPage
:
{},
getPage
:
{},
pageColumns
:
[
pageColumns
:
[
{
title
:
'检测项目'
,
key
:
'name'
,
width
:
120
,
fixed
:
'left'
},
{
title
:
'试验名称'
,
key
:
'name'
,
width
:
160
},
{
title
:
'样品编号'
,
key
:
'num'
,
width
:
180
},
{
title
:
'试验项目英文简写'
,
key
:
'shortName'
,
width
:
140
},
{
title
:
'样品名称'
,
key
:
'sampleName'
,
width
:
140
},
{
title
:
'大类'
,
key
:
'mainType'
,
width
:
140
},
{
title
:
'服务类型'
,
key
:
'serviceType'
,
width
:
160
},
{
title
:
'小类'
,
key
:
'smallType'
,
width
:
140
},
{
title
:
'产品'
,
key
:
'subClass'
,
width
:
160
},
{
title
:
'检测依据'
,
key
:
'testBasis'
,
width
:
180
},
{
title
:
'计划完成时间'
,
key
:
'planEndDate'
,
width
:
120
,
date
:
true
},
{
title
:
'试验方法'
,
key
:
'testMethod'
,
width
:
180
},
{
title
:
'应出报告日期'
,
key
:
'reportDueDate'
,
width
:
120
,
date
:
true
},
{
title
:
'状态'
,
key
:
'status'
,
width
:
180
}
{
title
:
'数据出具日期'
,
key
:
'resultDate'
,
width
:
120
,
date
:
true
},
{
title
:
'检测依据'
,
key
:
'testBasis'
,
width
:
140
},
{
title
:
'检测依据名称'
,
key
:
'testBasisName'
,
width
:
200
},
{
title
:
'检测方法'
,
key
:
'testMethod'
,
width
:
260
},
{
title
:
'主检人'
,
key
:
'tester'
,
width
:
100
},
{
title
:
'检测科室'
,
key
:
'groupName'
,
width
:
150
},
{
title
:
'判定依据'
,
key
:
'judgeBasis'
,
width
:
140
},
{
title
:
'判定依据名称'
,
key
:
'judgeBasisName'
,
width
:
200
},
{
title
:
'接样日期'
,
key
:
'receiveDate'
,
width
:
100
,
date
:
true
},
{
title
:
'项目备注'
,
key
:
'remark'
,
width
:
200
},
{
title
:
'样品备注'
,
key
:
'sampleRemark'
,
width
:
200
},
{
title
:
'委托备注'
,
key
:
'contractRemark'
,
width
:
200
}
],
],
leftSelectData
:
[],
leftSelectData
:
[],
sampleIds
:
[],
selectIds
:
[],
// 检测项目id
selectIds
:
[],
// 检测项目id
selectData
:
[],
// 检测项目data
selectData
:
[],
// 检测项目data
selectSampleIds
:
[],
// 样品ids
selectSampleIds
:
[],
// 样品ids
...
@@ -259,16 +250,15 @@ export default {
...
@@ -259,16 +250,15 @@ export default {
})
})
},
},
_resultChange
(
msg
)
{
_resultChange
(
msg
)
{
if
(
this
.
$store
.
state
.
FoodItem
.
success
)
{
this
.
$Message
.
success
(
msg
)
this
.
$Message
.
success
(
msg
)
this
.
_page
()
this
.
_page
()
}
this
.
$emit
(
'on-result-change'
)
this
.
selectIds
=
[]
},
},
async
_btnClick
(
msg
)
{
async
_btnClick
(
msg
)
{
switch
(
msg
)
{
switch
(
msg
)
{
case
'按人分配'
:
case
'试验项目分配'
:
await
this
.
_reportDueDate
()
this
.
_userAssign
()
await
this
.
_userAssign
()
break
break
case
'按组分配'
:
case
'按组分配'
:
await
this
.
_reportDueDate
()
await
this
.
_reportDueDate
()
...
@@ -317,7 +307,8 @@ export default {
...
@@ -317,7 +307,8 @@ export default {
}
}
},
},
_open
(
data
)
{
_open
(
data
)
{
this
.
leftSelectData
=
data
this
.
getPage
.
records
=
[]
this
.
sampleIds
=
data
if
(
data
.
length
===
0
)
{
if
(
data
.
length
===
0
)
{
this
.
$set
(
this
.
getPage
,
'records'
,
[])
this
.
$set
(
this
.
getPage
,
'records'
,
[])
this
.
$set
(
this
.
getPage
,
'total'
,
0
)
this
.
$set
(
this
.
getPage
,
'total'
,
0
)
...
@@ -327,7 +318,7 @@ export default {
...
@@ -327,7 +318,7 @@ export default {
this
.
selectData
=
[]
this
.
selectData
=
[]
this
.
result
=
[]
this
.
result
=
[]
}
else
{
}
else
{
this
.
_
formSearch
()
this
.
_
page
()
}
}
},
},
_refresh
()
{
_refresh
()
{
...
@@ -346,10 +337,8 @@ export default {
...
@@ -346,10 +337,8 @@ 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
)
this
.
formObj
.
sampleIds
=
this
.
sampleIds
const
result
=
await
soilTest
.
pageExpAllot
(
const
result
=
await
soilTest
.
pageAllot
(
this
.
$serializeForm
(
this
.
formObj
))
this
.
$serializeForm
(
this
.
formObj
)
)
if
(
result
)
{
if
(
result
)
{
this
.
$refs
.
pageTable
.
_hideLoading
()
this
.
$refs
.
pageTable
.
_hideLoading
()
this
.
$refs
.
pageTable
.
_checkAll
()
this
.
$refs
.
pageTable
.
_checkAll
()
...
@@ -388,37 +377,40 @@ export default {
...
@@ -388,37 +377,40 @@ export default {
},
},
// 按人分配 选人选时间
// 按人分配 选人选时间
_userAssign
()
{
_userAssign
()
{
if
(
this
.
defaultPlanDate
)
{
// 有字典
if
(
this
.
sampleNames
===
''
)
{
// 有计划完成时间
const
user
=
Global
.
getUserInfo
(
'userInfo'
)
const
user
=
Global
.
getUserInfo
(
'userInfo'
)
this
.
currentComponent
=
'AssignPerson'
console
.
log
(
user
)
this
.
$nextTick
(
function
()
{
this
.
$refs
.
personModal
.
_openGoup
(
'分配人员'
,
'itemTree'
)
this
.
$refs
.
refModal
.
_openGoupByUserId
(
// if (this.defaultPlanDate) {
'分配人员'
,
// // 有字典
user
.
id
,
// if (this.sampleNames === '') {
'itemTree'
// // 有计划完成时间
)
// const user = Global.getUserInfo('userInfo')
})
// this.currentComponent = 'AssignPerson'
}
else
{
// this.$nextTick(function() {
// 有字典,无计划完成时间的
// this.$refs.refModal._openGoupByUserId(
this
.
$Modal
.
confirm
({
// '分配人员',
title
:
'提示'
,
// user.id,
content
:
// 'itemTree'
'所选项目中含有未设置计划完成时间的'
+
// )
`
${
this
.
_reportDueDate
()}
`
+
// })
'请确认!'
,
// } else {
onOk
:
()
=>
{}
// // 有字典,无计划完成时间的
})
// this.$Modal.confirm({
}
// title: '提示',
}
else
{
// content:
// 无字典
// '所选项目中含有未设置计划完成时间的' +
this
.
currentComponent
=
'EndDateModal'
// `${this._reportDueDate()}` +
this
.
$nextTick
(()
=>
{
// '请确认!',
this
.
_endDate
()
// onOk: () => {}
})
// })
}
// }
// } else {
// // 无字典
// this.currentComponent = 'EndDateModal'
// this.$nextTick(() => {
// this._endDate()
// })
// }
},
},
// 遍历出计划时间为空的样品名
// 遍历出计划时间为空的样品名
_reportDueDate
()
{
_reportDueDate
()
{
...
@@ -500,6 +492,20 @@ export default {
...
@@ -500,6 +492,20 @@ export default {
})
})
})
})
},
},
_assignBackData
(
data
)
{
console
.
log
(
data
)
const
tempData
=
{}
tempData
.
ids
=
this
.
selectIds
.
join
(
','
)
tempData
.
user
=
data
.
realname
tempData
.
userId
=
data
.
userId
this
.
_allotItems
(
tempData
)
},
_allotItems
:
async
function
(
data
)
{
const
result
=
await
soilTest
.
allotExp
(
data
)
if
(
result
)
{
this
.
_resultChange
(
'分配成功'
)
}
},
// 样品详情
// 样品详情
_sampleDetail
(
data
)
{
_sampleDetail
(
data
)
{
this
.
$nextTick
(
function
()
{
this
.
$nextTick
(
function
()
{
...
...
pages/soil-test-manage/test-task-manage/entrust-sample-manage/sample-tabs/SampleTabs.vue
View file @
d234bf7b
...
@@ -32,9 +32,8 @@ export default {
...
@@ -32,9 +32,8 @@ export default {
_rightResult
()
{
_rightResult
()
{
this
.
$refs
.
SampleleftModal
.
_page
()
this
.
$refs
.
SampleleftModal
.
_page
()
},
},
_open
()
{
_open
(
id
)
{
console
.
log
(
'按样品分配'
)
this
.
$refs
.
SampleleftModal
.
_open
(
id
)
this
.
$refs
.
SampleleftModal
.
_open
()
// this.$refs.rightModal._getColumn()
// this.$refs.rightModal._getColumn()
}
}
}
}
...
...
router/soil-routes.js
View file @
d234bf7b
...
@@ -14,6 +14,7 @@ import BackupsManage from '../pages/soil-sample-manage/backups-manage/SampleBack
...
@@ -14,6 +14,7 @@ import BackupsManage from '../pages/soil-sample-manage/backups-manage/SampleBack
import
SampleTakeIndex
from
'../pages/soil-sample-manage/sample-take/SampleTakeIndex'
import
SampleTakeIndex
from
'../pages/soil-sample-manage/sample-take/SampleTakeIndex'
import
SurplusManage
from
'../pages/soil-sample-manage/surplus-manage/SampleSurplusIndex'
import
SurplusManage
from
'../pages/soil-sample-manage/surplus-manage/SampleSurplusIndex'
import
TestTaskIndex
from
'../pages/soil-test-manage/test-task-manage/TestTaskIndex'
import
TestTaskIndex
from
'../pages/soil-test-manage/test-task-manage/TestTaskIndex'
import
TestInputIndex
from
'../pages/soil-test-manage/test-input/TestInputIndex'
import
Blank
from
'~/pages/blank'
import
Blank
from
'~/pages/blank'
export
default
[
export
default
[
{
{
...
@@ -84,7 +85,7 @@ export default [
...
@@ -84,7 +85,7 @@ export default [
},
},
{
{
path
:
'do_test'
,
path
:
'do_test'
,
component
:
ExperimentItemManage
,
component
:
TestInputIndex
,
meta
:
{
title
:
'试样检测'
}
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