Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
mes-pda-scan
Project
Project
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
ximai
mes-pda-scan
Commits
e8309f3d
Commit
e8309f3d
authored
Jul 05, 2024
by
何远江
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加解除装箱功能
parent
05e17ab6
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
170 additions
and
11 deletions
+170
-11
packing.vue
pages/packing/packing.vue
+12
-11
unpacking.vue
pages/packing/unpacking.vue
+158
-0
No files found.
pages/packing/packing.vue
View file @
e8309f3d
<
template
>
<
template
>
<view
class=
"lists"
>
<view
class=
"lists"
>
<StickyNavBar
:class=
"
{'meteringTab':current
=== 1
}">
<StickyNavBar
:class=
"
{'meteringTab':current
!== 0
}">
<NavBar
title=
"装箱"
></NavBar>
<NavBar
title=
"装箱"
></NavBar>
<view
class=
"selectSheet"
>
<view
class=
"selectSheet"
>
<u-tabs
:list=
"list"
:is-scroll=
"false"
:current=
"current"
@
change=
"changeTab"
></u-tabs>
<u-tabs
:list=
"list"
:is-scroll=
"false"
:current=
"current"
@
change=
"changeTab"
></u-tabs>
</view>
</view>
<!--
<view
class=
"headerTitle"
>
<view
class=
"items"
>
箱号:
{{
orderBoxNum
}}
</view>
</view>
-->
<view
class=
""
v-if=
"current === 0"
>
<view
class=
""
v-if=
"current === 0"
>
<view
class=
"btn"
>
<view
class=
"btn"
>
<view
class=
"boxSelect"
>
<view
class=
"boxSelect"
>
...
@@ -32,6 +29,7 @@
...
@@ -32,6 +29,7 @@
</StickyNavBar>
</StickyNavBar>
<relationships
v-show=
"current === 0"
:list=
"goodsList"
@
deleGonds=
"deleGonds"
/>
<relationships
v-show=
"current === 0"
:list=
"goodsList"
@
deleGonds=
"deleGonds"
/>
<metering
v-show=
"current === 1"
:form=
"form"
/>
<metering
v-show=
"current === 1"
:form=
"form"
/>
<unpacking
v-show=
"current === 2"
/>
<BottomBtn
:btnArr=
"btnArr"
@
getBtnHandle=
"getBtnHandle"
v-if=
"current === 0"
></BottomBtn>
<BottomBtn
:btnArr=
"btnArr"
@
getBtnHandle=
"getBtnHandle"
v-if=
"current === 0"
></BottomBtn>
</view>
</view>
</
template
>
</
template
>
...
@@ -42,6 +40,7 @@
...
@@ -42,6 +40,7 @@
import
BottomBtn
from
'@/components/BottomBtn/index.vue'
;
import
BottomBtn
from
'@/components/BottomBtn/index.vue'
;
import
relationships
from
'./relationships.vue'
;
import
relationships
from
'./relationships.vue'
;
import
metering
from
'./metering.vue'
;
import
metering
from
'./metering.vue'
;
import
unpacking
from
'./unpacking.vue'
;
import
{
import
{
parseTime
parseTime
}
from
"@/utils/ruoyi"
;
}
from
"@/utils/ruoyi"
;
...
@@ -52,7 +51,8 @@
...
@@ -52,7 +51,8 @@
ContentLoadingMore
,
ContentLoadingMore
,
BottomBtn
,
BottomBtn
,
relationships
,
relationships
,
metering
metering
,
unpacking
},
},
data
()
{
data
()
{
return
{
return
{
...
@@ -62,9 +62,10 @@
...
@@ -62,9 +62,10 @@
border
:
true
,
border
:
true
,
list
:
[{
list
:
[{
name
:
'装箱关联'
name
:
'装箱关联'
},
},{
{
name
:
'计量称重'
name
:
'计量称重'
},{
name
:
'解除装箱'
}
}
],
],
current
:
0
,
current
:
0
,
...
...
pages/packing/unpacking.vue
0 → 100644
View file @
e8309f3d
<
template
>
<view>
<view
class=
"btn"
>
<uni-easyinput
prefixIcon=
"search"
:disabled=
"isDisabled"
v-model=
"wxparams"
:focus=
"isFocus"
placeholder=
"请扫描产品包装条码/外箱码"
@
input=
"handleInputPlnr"
></uni-easyinput>
<view
class=
"title"
>
<text>
明细
</text>
</view>
</view>
<view
class=
"cardbox"
>
<view
class=
"cardContent"
v-for=
"(item, index) in goodsList"
:key=
"item.PLNR"
>
<view
class=
"listItemTitle"
>
<view>
<view
class=
"item"
>
PL号:
{{
item
}}
</view>
</view>
<u-button
size=
"mini"
type=
"primary"
plain
@
click=
"deleGonds(index)"
>
<u-icon
name=
"trash"
size=
"28"
></u-icon>
删除
</u-button>
</view>
</view>
</view>
<BottomBtn
:btnArr=
"btnArr"
@
getBtnHandle=
"getBtnHandle"
></BottomBtn>
</view>
</
template
>
<
script
>
import
BottomBtn
from
'@/components/BottomBtn/index.vue'
;
import
{
parseTime
}
from
"@/utils/ruoyi"
;
export
default
{
components
:
{
BottomBtn
},
data
()
{
return
{
isFocus
:
false
,
isDisabled
:
false
,
wxparams
:
""
,
goodsList
:
[],
btnArr
:
[{
style
:
''
,
type
:
'warning'
,
text
:
'返回'
,
way
:
'goBack'
},
{
style
:
''
,
type
:
'primary'
,
text
:
'提交'
,
way
:
'goSubmit'
}
],
};
},
methods
:
{
handleInputPlnr
(
e
)
{
this
.
isFocus
=
false
;
this
.
isDisabled
=
true
;
if
(
this
.
goodsList
.
some
((
item
)
=>
item
===
e
))
{
this
.
$u
.
toast
(
'已经存在当前条码'
);
this
.
reset
()
return
}
e
&&
this
.
goodsList
.
push
(
e
)
this
.
reset
()
},
deleGonds
(
index
)
{
this
.
goodsList
.
splice
(
index
,
1
)
},
reset
()
{
setTimeout
(()
=>
{
this
.
isFocus
=
true
;
this
.
isDisabled
=
false
;
this
.
wxparams
=
''
},
1000
);
},
getBtnHandle
(
row
)
{
console
.
log
(
'getBtnHandle'
,
row
);
this
[
row
.
way
]();
},
// 提交
goSubmit
()
{
if
(
!
this
.
goodsList
.
length
)
{
return
this
.
$u
.
toast
(
'请添加需要解除装箱的箱条码/外箱码'
)
}
const
DATUM
=
parseTime
(
new
Date
(),
'{y}{m}{d}'
),
UNAME
=
this
.
vuex_user
.
nickName
,
UZEIT
=
parseTime
(
new
Date
(),
'{h}{i}{s}'
);
const
arr
=
this
.
goodsList
.
map
((
item
)
=>
{
return
{
plnr
:
item
,
UPDKZ
:
'D'
,
DATUM
,
UNAME
,
UZEIT
,
}
})
this
.
$u
.
api
.
sapApi
.
sapCasePlnr
(
arr
)
.
then
((
res
)
=>
{
const
flag
=
res
.
some
((
item
)
=>
{
const
b
=
item
.
TYPE
==
'E'
if
(
b
)
{
this
.
$u
.
toast
(
item
.
MESSAGE
)
}
return
b
})
if
(
!
flag
)
{
this
.
$u
.
toast
(
res
[
0
].
MESSAGE
);
this
.
goodsList
=
[]
}
})
},
goBack
()
{}
},
};
</
script
>
<
style
scoped
lang=
'scss'
>
.btn
{
padding
:
10rpx
20rpx
;
background
:
#fff
;
.title
{
margin-top
:
10rpx
;
color
:
#000
;
font-size
:
34rpx
;
}
}
.cardContent
{
border-radius
:
8px
;
background
:
#fff
;
margin-bottom
:
20rpx
;
}
.listItemTitle
{
display
:
flex
;
justify-content
:
space-between
;
padding
:
20rpx
;
border-bottom
:
2px
solid
#f8f8f8
;
.u-btn
{
width
:
150rpx
;
margin
:
0px
;
margin-top
:
10rpx
;
}
.item
{
line-height
:
50rpx
;
color
:
#333
;
font-size
:
28rpx
;
font-weight
:
500
;
word-break
:
break-all
;
font-weight
:
600
;
}
}
</
style
>
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