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
14ba9e6a
Commit
14ba9e6a
authored
Nov 02, 2020
by
lichengming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改了扫码领样
parent
50fc05b6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
32 deletions
+20
-32
soil-sample.js
api/soil/soil-sample.js
+5
-1
TakeByEwm.vue
pages/soil-sample-manage/sample-take/TakeByEwm.vue
+15
-31
No files found.
api/soil/soil-sample.js
View file @
14ba9e6a
...
@@ -137,5 +137,9 @@ export default {
...
@@ -137,5 +137,9 @@ export default {
// 余样编辑
// 余样编辑
editPrepare
:
data
=>
editPrepare
:
data
=>
http
.
put
(
'soil/v1/prepare/'
+
data
.
id
,
data
.
obj
).
then
(
res
=>
res
),
http
.
put
(
'soil/v1/prepare/'
+
data
.
id
,
data
.
obj
).
then
(
res
=>
res
),
getUserList
:
data
=>
http
.
post
(
'/base/v1/user/page'
).
then
(
res
=>
res
)
getUserList
:
data
=>
http
.
post
(
'/base/v1/user/page'
).
then
(
res
=>
res
),
scanTakeSample
:
data
=>
http
.
post
(
'soil/v1/sample/scan_take_sample?sampleCode='
+
data
)
.
then
(
res
=>
res
)
}
}
pages/soil-sample-manage/sample-take/TakeByEwm.vue
View file @
14ba9e6a
...
@@ -22,6 +22,8 @@
...
@@ -22,6 +22,8 @@
</
template
>
</
template
>
<
script
>
<
script
>
/* 扫码接收、扫码发放 */
/* 扫码接收、扫码发放 */
import
{
soilSample
}
from
'../../../api'
export
default
{
export
default
{
components
:
{},
components
:
{},
data
()
{
data
()
{
...
@@ -62,38 +64,20 @@ export default {
...
@@ -62,38 +64,20 @@ export default {
_cancel
()
{
_cancel
()
{
this
.
showSubmitModal
=
false
this
.
showSubmitModal
=
false
},
},
_numBlur
()
{
_numBlur
:
async
function
()
{
if
(
this
.
modalTitle
===
'扫码接收'
)
{
// 扫码发放
// 扫码接收
const
param
=
{}
this
.
$store
Object
.
assign
(
param
,
this
.
formObj
,
{
num
:
this
.
num
})
.
dispatch
(
'FoodSample/scanReceive'
,
{
const
result
=
await
soilSample
.
scanTakeSample
(
this
.
num
)
num
:
this
.
num
if
(
result
)
{
})
console
.
log
(
result
)
.
then
(()
=>
{
// this._resultChange(' 发放')
this
.
_resultChange
(
' 接收'
)
})
}
else
{
// 扫码发放
const
param
=
{}
Object
.
assign
(
param
,
this
.
formObj
,
{
num
:
this
.
num
})
if
(
this
.
modalTitle
===
'扫码发放'
)
{
this
.
$store
.
dispatch
(
'FoodSample/scanSend'
,
this
.
$serializeFormSearch
(
param
))
.
then
(()
=>
{
this
.
_resultChange
(
' 发放'
)
})
}
else
if
(
this
.
modalTitle
===
'扫码接收发放'
)
{
this
.
$store
.
dispatch
(
'FoodSample/scanReceiveSend'
,
this
.
$serializeFormSearch
(
param
)
)
.
then
(()
=>
{
this
.
_resultChange
(
' 接收发放'
)
})
}
// 扫码接收发放
}
}
// this.$store
// .dispatch('FoodSample/scanSend', this.$serializeFormSearch(param))
// .then(() => {
// this._resultChange(' 发放')
// })
this
.
_autoFocus
()
this
.
_autoFocus
()
},
},
_resultChange
(
msg
)
{
_resultChange
(
msg
)
{
...
...
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