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
1f4d8d1e
Commit
1f4d8d1e
authored
Nov 09, 2020
by
lichengming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改了余样管理的批量填写信息
parent
fdc9bd87
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
191 additions
and
5 deletions
+191
-5
SampleSurplusBatchEdit.vue
...l-sample-manage/surplus-manage/SampleSurplusBatchEdit.vue
+159
-0
SampleSurplusManage.vue
...-sample-manage/surplus-manage/tab/SampleSurplusManage.vue
+19
-1
SelectOriTempRecord.vue
pages/soil-test-manage/test-input/SelectOriTempRecord.vue
+6
-3
ItemRightList.vue
...s/soil-test-manage/test-input/item-tabs/ItemRightList.vue
+7
-1
No files found.
pages/soil-sample-manage/surplus-manage/SampleSurplusBatchEdit.vue
0 → 100644
View file @
1f4d8d1e
<
template
>
<div>
<Modal
v-model=
"showModal"
:mask-closable=
"false"
>
<p
slot=
"header"
>
填写存放信息
</p>
<div>
<Form
id=
"storage-location-form"
ref=
"formObj"
:model=
"formObj"
:rules=
"ruleValidate"
:label-width=
"100"
>
<Form-item
label=
"保存容器:"
prop=
"keepContainer"
>
<Input
v-model=
"formObj.keepContainer"
clearable
placeholder=
"请输入保存容器"
></Input>
</Form-item>
<Form-item
label=
"制备数量"
>
<Input
v-model=
"formObj.quantity"
clearable
placeholder=
"请输入备样数量"
></Input>
</Form-item>
<Form-item
label=
"留存位置"
>
<Input
v-model=
"formObj.keepLocation"
clearable
placeholder=
"请输入留存位置"
></Input>
</Form-item>
</Form>
</div>
<div
slot=
"footer"
>
<modal-footer
ref=
"footerModal"
@
on-result-change=
"_footerResult"
:footer=
"footerList"
></modal-footer>
</div>
</Modal>
</div>
</
template
>
<
script
>
import
{
soilSample
}
from
'../../../api'
export
default
{
components
:
{},
data
()
{
return
{
ids
:
[],
// 委托ids
showModal
:
false
,
formObj
:
{},
ruleValidate
:
{
backupLocation
:
[
{
required
:
true
,
message
:
'备样位置不能为空'
,
trigger
:
'blur'
}
]
},
footerList
:
[
{
id
:
''
,
name
:
'取消'
,
type
:
''
},
{
id
:
''
,
name
:
'保存'
,
type
:
'primary'
}
],
conditionList
:
[],
locList
:
[],
backupUserList
:
[],
sampleUnit
:
''
}
},
mounted
()
{
this
.
_getConditionList
()
this
.
_getUserList
()
},
methods
:
{
_locChange
(
msg
,
data
)
{
switch
(
msg
)
{
case
'select'
:
this
.
formObj
.
backupPlace
=
data
.
backupPlace
this
.
_getCondition
(
data
.
backupPlace
)
break
case
'query'
:
this
.
formObj
.
backupPlace
=
data
.
backupPlace
this
.
_getLocList
(
data
.
backupPlace
)
break
}
},
selCondi
(
data
)
{
this
.
$forceUpdate
()
this
.
formObj
.
conditions
=
data
},
selUser
(
data
)
{
this
.
$forceUpdate
()
if
(
data
)
{
for
(
let
i
=
0
;
i
<
this
.
backupUserList
.
length
;
i
++
)
{
if
(
this
.
backupUserList
[
i
].
id
===
data
)
{
this
.
formObj
.
backupUser
=
this
.
backupUserList
[
i
].
realname
}
}
}
else
{
this
.
getPage
.
records
[
this
.
currentIndex
].
backupUser
=
''
}
this
.
formObj
.
backupUserId
=
data
},
// 存储条件 回调
_locChangeCondition
(
msg
,
data
)
{
switch
(
msg
)
{
case
'select'
:
this
.
formObj
.
storageCondition
=
data
.
name
this
.
_getLocCondition
(
data
.
name
)
break
case
'query'
:
this
.
formObj
.
storageCondition
=
data
.
name
this
.
_getLocConditionList
(
data
.
name
)
break
}
},
_footerResult
(
name
)
{
switch
(
name
)
{
case
'取消'
:
this
.
_cancel
()
break
case
'保存'
:
this
.
_ok
()
break
}
},
_open
(
data
)
{
this
.
showModal
=
true
this
.
formObj
=
this
.
$resetFields
(
this
.
formObj
)
this
.
sampleUnit
=
''
this
.
$refs
.
footerModal
.
_hideLoading
()
this
.
ids
=
data
// 循环遍历数据
},
_getConditionList
:
async
function
()
{
const
result
=
await
soilSample
.
getDictList
(
'存储条件'
)
if
(
result
)
{
this
.
conditionList
=
result
}
},
_getUserList
:
async
function
()
{
const
result
=
await
soilSample
.
getUserList
()
if
(
result
)
{
console
.
log
(
result
)
this
.
backupUserList
=
result
.
records
}
},
//
_dateChange
(
data
)
{
this
.
formObj
.
endDate
=
data
},
_cancel
()
{
this
.
showModal
=
false
this
.
$refs
.
footerModal
.
_hideLoading
()
},
_hideLoading
()
{
this
.
$refs
.
footerModal
.
_hideLoading
()
},
_ok
()
{
this
.
$refs
.
formObj
.
validate
(
valid
=>
{
if
(
valid
)
{
const
data
=
this
.
formObj
this
.
_saveInfo
({
id
:
this
.
ids
.
join
(
','
),
obj
:
data
})
}
else
{
this
.
$Message
.
error
(
'表单验证失败!'
)
this
.
$refs
.
footerModal
.
_hideLoading
()
}
})
},
_saveInfo
:
async
function
(
data
)
{
const
result
=
await
soilSample
.
editPrepare
(
data
)
if
(
result
)
{
this
.
$Message
.
success
(
'保存成功'
)
this
.
$emit
(
'on-result-change'
)
this
.
showModal
=
false
}
}
}
}
</
script
>
pages/soil-sample-manage/surplus-manage/tab/SampleSurplusManage.vue
View file @
1f4d8d1e
...
@@ -86,10 +86,12 @@
...
@@ -86,10 +86,12 @@
</div>
</div>
<SampleParpareApply
ref=
"applyModal"
@
on-result-change=
"_page"
></SampleParpareApply>
<SampleParpareApply
ref=
"applyModal"
@
on-result-change=
"_page"
></SampleParpareApply>
<Operation
ref=
"recordModal"
></Operation>
<Operation
ref=
"recordModal"
></Operation>
<SampleSurplusBatchEdit
ref=
"batchEdit"
@
on-result-change=
"_page"
></SampleSurplusBatchEdit>
</div>
</div>
</template>
</template>
<
script
>
<
script
>
import
SampleParpareApply
from
'../SurplusParpareApply'
import
SampleParpareApply
from
'../SurplusParpareApply'
import
SampleSurplusBatchEdit
from
'../SampleSurplusBatchEdit'
// eslint-disable-next-line no-unused-vars
// eslint-disable-next-line no-unused-vars
import
http
from
'../../../../api/http'
import
http
from
'../../../../api/http'
import
{
soilSample
}
from
'../../../../api'
import
{
soilSample
}
from
'../../../../api'
...
@@ -97,7 +99,8 @@ import Operation from '../../../../components/operation/Operation'
...
@@ -97,7 +99,8 @@ import Operation from '../../../../components/operation/Operation'
export
default
{
export
default
{
components
:
{
components
:
{
SampleParpareApply
,
SampleParpareApply
,
Operation
Operation
,
SampleSurplusBatchEdit
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -119,6 +122,11 @@ export default {
...
@@ -119,6 +122,11 @@ export default {
type
:
'primary'
,
type
:
'primary'
,
id
:
''
,
id
:
''
,
name
:
'完成处理'
name
:
'完成处理'
},
{
type
:
'primary'
,
id
:
''
,
name
:
'批量填写存放信息'
}
}
// { type: '', id: '', name: '填写存放信息' },
// { type: '', id: '', name: '填写存放信息' },
// { type: '', id: '', name: '申请处理' },
// { type: '', id: '', name: '申请处理' },
...
@@ -349,6 +357,9 @@ export default {
...
@@ -349,6 +357,9 @@ export default {
case
'填写存放信息'
:
case
'填写存放信息'
:
this
.
_batchEdit
()
this
.
_batchEdit
()
break
break
case
'批量填写存放信息'
:
this
.
_writeInfo
()
break
case
'导出'
:
case
'导出'
:
if
(
this
.
getPage
.
records
.
length
===
0
)
{
if
(
this
.
getPage
.
records
.
length
===
0
)
{
this
.
$Message
.
warning
(
'暂无数据,不可导出'
)
this
.
$Message
.
warning
(
'暂无数据,不可导出'
)
...
@@ -364,6 +375,13 @@ export default {
...
@@ -364,6 +375,13 @@ export default {
break
break
}
}
},
},
_writeInfo
()
{
if
(
this
.
selectIds
.
length
===
0
)
{
this
.
$Message
.
warning
(
'请选择一条或多条数据!'
)
}
else
{
this
.
$refs
.
batchEdit
.
_open
(
this
.
selectIds
)
}
},
_resultChange
(
msg
)
{
_resultChange
(
msg
)
{
this
.
$Message
.
success
(
msg
)
this
.
$Message
.
success
(
msg
)
this
.
_page
()
this
.
_page
()
...
...
pages/soil-test-manage/test-input/SelectOriTempRecord.vue
View file @
1f4d8d1e
...
@@ -81,6 +81,7 @@ export default {
...
@@ -81,6 +81,7 @@ export default {
businessTypeList
:
0
businessTypeList
:
0
},
},
entrustId
:
''
,
entrustId
:
''
,
clientList
:
[],
selectData
:
[],
selectData
:
[],
itemIds
:
[],
itemIds
:
[],
footerList
:
[
footerList
:
[
...
@@ -140,10 +141,11 @@ export default {
...
@@ -140,10 +141,11 @@ export default {
_hideLoading
()
{
_hideLoading
()
{
this
.
$refs
.
footerModal
.
_hideLoading
()
this
.
$refs
.
footerModal
.
_hideLoading
()
},
},
_open
(
ids
,
entrustId
)
{
_open
(
ids
,
entrustId
,
clientInfo
)
{
console
.
log
(
Global
.
recordURL
)
console
.
log
(
Global
.
recordURL
)
this
.
formObj
=
this
.
$resetFields
(
this
.
formObj
)
this
.
formObj
=
this
.
$resetFields
(
this
.
formObj
)
this
.
entrustId
=
entrustId
this
.
entrustId
=
entrustId
this
.
clientList
=
clientInfo
this
.
_classTree
()
this
.
_classTree
()
this
.
showModal
=
true
this
.
showModal
=
true
this
.
itemIds
=
ids
this
.
itemIds
=
ids
...
@@ -205,9 +207,10 @@ export default {
...
@@ -205,9 +207,10 @@ export default {
recordUrl
=
Global
.
recordURL
recordUrl
=
Global
.
recordURL
}
}
const
url
=
const
url
=
recordUrl
+
'/print/v1/eln/template_
YT
_'
+
this
.
selectData
[
0
].
id
recordUrl
+
'/print/v1/eln/template_
meter
_'
+
this
.
selectData
[
0
].
id
const
params
=
{
const
params
=
{
ids
:
this
.
itemIds
.
join
(
','
)
ids
:
this
.
itemIds
.
join
(
','
),
client
:
this
.
clientList
[
0
]
}
}
this
.
$refs
.
iframeModal
.
_createIframe
(
url
,
params
)
this
.
$refs
.
iframeModal
.
_createIframe
(
url
,
params
)
console
.
log
(
'原始记录'
,
url
,
params
)
console
.
log
(
'原始记录'
,
url
,
params
)
...
...
pages/soil-test-manage/test-input/item-tabs/ItemRightList.vue
View file @
1f4d8d1e
...
@@ -457,7 +457,9 @@ export default {
...
@@ -457,7 +457,9 @@ export default {
this
.
$message
.
warning
(
'请至少选择一条数据'
)
this
.
$message
.
warning
(
'请至少选择一条数据'
)
}
else
{
}
else
{
const
errorInfo
=
[]
const
errorInfo
=
[]
const
clientInfo
=
[]
for
(
let
i
=
0
;
i
<
this
.
selectData
.
length
;
i
++
)
{
for
(
let
i
=
0
;
i
<
this
.
selectData
.
length
;
i
++
)
{
clientInfo
.
push
(
this
.
selectData
[
i
].
client
)
console
.
log
(
this
.
selectData
[
i
].
recorded
)
console
.
log
(
this
.
selectData
[
i
].
recorded
)
if
(
this
.
selectData
[
i
].
recorded
!==
'否'
)
{
if
(
this
.
selectData
[
i
].
recorded
!==
'否'
)
{
errorInfo
.
push
(
this
.
selectData
[
i
].
index
+
1
)
errorInfo
.
push
(
this
.
selectData
[
i
].
index
+
1
)
...
@@ -467,7 +469,11 @@ export default {
...
@@ -467,7 +469,11 @@ export default {
this
.
$Message
.
warning
(
'所选数据中有已填写原始记录的'
)
this
.
$Message
.
warning
(
'所选数据中有已填写原始记录的'
)
}
else
{
}
else
{
console
.
log
(
'打开填写原始记录界面'
)
console
.
log
(
'打开填写原始记录界面'
)
this
.
$refs
.
recordModal
.
_open
(
this
.
selectIds
,
this
.
entrustId
)
this
.
$refs
.
recordModal
.
_open
(
this
.
selectIds
,
this
.
entrustId
,
clientInfo
)
}
}
}
}
},
},
...
...
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