Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
梁建民
/
wmsApp
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
2ffa0ef6
authored
Jul 13, 2023
by
LJM
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
复核-箱信息须支持上下滑动
parent
cb29bab9
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
195 additions
and
72 deletions
assets/css/stockRecheck/sort.scss
pages/picking/sort.vue
pages/stockRecheck/sort.vue
pages/tallyReceive/index.vue
pages/tallyReceive/operate.vue
assets/css/stockRecheck/sort.scss
View file @
2ffa0ef6
...
...
@@ -263,7 +263,7 @@
.uni-drawer-picking
{
width
:
100%
;
background-color
:
#ffffff
;
padding
:
22rpx
22rpx
0
22rpx
;
padding
:
22rpx
22rpx
100rpx
22rpx
;
.title
{
position
:
relative
;
.iconfont
{
...
...
@@ -429,9 +429,9 @@
}
}
.btn
{
position
:
absolute
;
bottom
:
0
;
position
:
fixed
;
left
:
0
;
bottom
:
0
;
width
:
100%
;
z-index
:
99
;
.btn0
{
...
...
pages/picking/sort.vue
View file @
2ffa0ef6
...
...
@@ -59,6 +59,10 @@
<text
class=
"tt"
>
{{
item
.
position_name
}}
</text>
</view>
<view
class=
"input-box row verCenter"
>
<text
class=
"label"
>
容器:
</text>
<text
class=
"text"
>
{{
item
.
container_sn
}}
</text>
</view>
<view
class=
"input-box row verCenter"
>
<text
class=
"label"
>
入库批次号:
</text>
<text
class=
"text"
>
{{
item
.
stock_in_batch_sn
}}
</text>
</view>
...
...
@@ -733,54 +737,80 @@ export default {
*/
chooseImageChange
()
{
this
.
noexebshowFalg
=
false
;
var
self
=
this
;
// 使用 chooseImage选择图片
uni
.
chooseImage
({
count
:
self
.
maxNums
,
sizeType
:
[
'compressed'
],
count
:
this
.
maxNum
,
sizeType
:
[
'
original'
,
'
compressed'
],
sourceType
:
[
'album'
,
'camera'
],
success
:
chooseImageRes
=>
{
console
.
log
(
'选择图片成功:'
,
chooseImageRes
);
// 显示loading
uni
.
showLoading
({
title
:
'上传中...'
});
const
tempFilePaths
=
chooseImageRes
.
tempFilePaths
;
let
maxNum
=
tempFilePaths
.
length
*
1
+
self
.
image_list
.
length
*
1
;
if
(
maxNum
>
self
.
maxNum
)
{
// 获取选择的图片路径数组
const
imagePaths
=
chooseImageRes
.
tempFilePaths
;
// 判断选择的图片数量是否超过最大限制数量
let
maxNum
=
Number
(
imagePaths
.
length
)
+
Number
(
this
.
image_list
.
length
);
//当前上传的+已经上传的
if
(
maxNum
>
this
.
maxNum
)
{
uni
.
hideLoading
();
uni
.
showToast
({
title
:
'图片不超过'
+
self
.
maxNum
+
'张'
,
icon
:
'
error
'
title
:
'图片不超过'
+
this
.
maxNum
+
'张'
,
icon
:
'
none
'
});
return
false
;
}
for
(
let
i
=
0
;
i
<
tempFilePaths
.
length
;
i
++
)
{
// 遍历图片路径数组,对每张图片进行压缩
imagePaths
.
forEach
(
imagePath
=>
{
// 使用compressImage 压缩图片
uni
.
compressImage
({
src
:
imagePath
,
quality
:
50
,
//压缩质量,范围0~100,数值越小,质量越低,压缩率越高
success
:
compressedRes
=>
{
console
.
log
(
'压缩图片成功:'
,
compressedRes
);
// 获取压缩后的图片路径
const
compressedImagePath
=
compressedRes
.
tempFilePath
;
// 在这里处理压缩后的图片,上传到服务器
uni
.
uploadFile
({
url
:
API
.
upload
+
'?sys_type=4'
,
filePath
:
tempFilePaths
[
i
]
,
filePath
:
compressedImagePath
,
name
:
'file'
,
header
:
{
'Content-Type'
:
'multipart/form-data'
},
success
:
uploadFileRes
=>
{
console
.
log
(
'服务器上传图片成功:'
,
uploadFileRes
);
uni
.
hideLoading
();
var
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
let
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
if
(
data
.
code
===
0
)
{
self
.
image_list
.
push
({
this
.
image_list
.
push
({
pic_id
:
data
.
data
.
oss_image_id
,
small_image_url
:
data
.
data
.
small_image_url
,
big_image_url
:
data
.
data
.
big_image_url
});
}
else
{
uni
.
showToast
({
title
:
'网络出现问题'
,
icon
:
'error
'
title
:
data
.
msg
,
icon
:
'none
'
});
}
},
fail
:
error
=>
{
console
.
log
(
'上传图片失败:'
,
error
);
uni
.
hideLoading
();
}
});
},
fail
:
err
=>
{
console
.
log
(
'压缩图片失败:'
,
err
);
}
});
});
}
});
},
...
...
@@ -831,7 +861,14 @@ export default {
});
this
.
request
(
URL
,
'POST'
,
{
page
:
this
.
page
,
limit
:
this
.
limit
,
...
this
.
searchParams
},
false
).
then
(
res
=>
{
if
(
res
.
code
===
0
)
{
this
.
list
=
res
.
data
.
list
;
//过滤出应拣数量不为0的数据
if
(
this
.
curr
==
0
)
{
var
filteredList
=
res
.
data
.
list
.
filter
(
item
=>
item
.
lock_qty
-
item
.
pick_qty
>
0
);
this
.
list
=
filteredList
;
}
else
if
(
this
.
curr
==
1
)
{
var
filteredList
=
res
.
data
.
list
.
filter
(
item
=>
item
.
total_lock_num
-
item
.
total_pick_num
>
0
);
this
.
list
=
filteredList
;
}
this
.
filter_list
=
createArray
(
this
.
list
.
length
,
false
);
typeof
callback
==
'function'
&&
callback
(
res
.
data
.
list
);
}
else
{
...
...
pages/stockRecheck/sort.vue
View file @
2ffa0ef6
...
...
@@ -101,9 +101,13 @@
<text
class=
"label"
>
其他批次属性:
</text>
<text
class=
"text"
>
{{
item
.
other_batch_attr
}}
</text>
</view>
<view
class=
"input-box row verCenter"
v-if=
"item.customer_material_number"
>
<text
class=
"label"
>
客户物料编码:
</text>
<text
class=
"text"
>
{{
item
.
customer_material_number
}}
</text>
<view
class=
"input-box row verCenter"
>
<text
class=
"label"
>
销 售 员:
</text>
<text
class=
"text"
>
{{
item
.
sale_name
}}
</text>
</view>
<view
class=
"input-box row"
>
<text
class=
"label"
>
客户:
</text>
<text
class=
"desc"
>
{{
item
.
customer_name
}}
</text>
</view>
<view
class=
"input-box row verCenter"
>
<text
class=
"label"
>
待复核数:
</text>
...
...
@@ -113,13 +117,9 @@
<text
class=
"label"
>
已复核数:
</text>
<text
class=
"text"
style=
"color: #F98119;"
>
{{
item
.
recheck_qty
}}
</text>
</view>
<view
class=
"input-box row verCenter"
>
<text
class=
"label"
>
销 售 员:
</text>
<text
class=
"text"
>
{{
item
.
sale_name
}}
</text>
</view>
<view
class=
"input-box row"
>
<text
class=
"label"
>
客户:
</text>
<text
class=
"desc"
>
{{
item
.
customer_name
}}
</text>
<view
class=
"input-box row verCenter"
style=
"flex: 0 0 100%;"
v-if=
"item.customer_material_number"
>
<text
class=
"label"
>
客户物料编码:
</text>
<text
class=
"text"
>
{{
item
.
customer_material_number
}}
</text>
</view>
<view
class=
"input-box row"
>
<text
class=
"label"
>
主单仓库备注:
</text>
...
...
@@ -153,7 +153,7 @@
<text
class=
"text"
>
{{
item
.
task_num
}}
</text>
</view>
<view
class=
"input-box row verCenter"
>
<text
class=
"label"
>
合计
应拣
数量:
</text>
<text
class=
"label"
>
合计
复核
数量:
</text>
<text
class=
"text"
>
{{
item
.
total_check_num
}}
</text>
</view>
<view
class=
"btn row rowCenter verCenter"
@
click=
"showDrawer(2, item)"
>
选择
</view>
...
...
@@ -503,7 +503,8 @@
</uni-drawer>
<!-- 箱信息 -->
<uni-drawer
ref=
"showBoxInfo"
mode=
"right"
>
<view
class=
"uni-drawer-picking box-drawer"
>
<view
class=
"uni-drawer-picking box-drawer"
style=
"height: 100%;"
>
<scroll-view
scroll-y=
"true"
style=
"height: 100%;overflow-y: scroll;"
>
<view
class=
"title row rowCenter verCenter"
>
<text
class=
"iconfont icon-juxing2"
@
click=
"closeBox()"
></text>
<text
class=
"text"
>
箱信息
</text>
...
...
@@ -545,6 +546,7 @@
<view
class=
"btn0 row rowCenter verCenter"
@
click=
"closeBox()"
>
取 消
</view>
<view
class=
"btn1 row rowCenter verCenter"
style=
"width: 50%;"
@
click=
"updatePackInfo()"
>
确认
</view>
</view>
</scroll-view>
</view>
</uni-drawer>
</view>
...
...
@@ -713,54 +715,80 @@ export default {
*/
chooseImageChange
()
{
this
.
noexebshowFalg
=
false
;
var
self
=
this
;
// 使用 chooseImage选择图片
uni
.
chooseImage
({
count
:
self
.
maxNums
,
sizeType
:
[
'compressed'
],
count
:
this
.
maxNum
,
sizeType
:
[
'
original'
,
'
compressed'
],
sourceType
:
[
'album'
,
'camera'
],
success
:
chooseImageRes
=>
{
console
.
log
(
'选择图片成功:'
,
chooseImageRes
);
// 显示loading
uni
.
showLoading
({
title
:
'上传中...'
});
const
tempFilePaths
=
chooseImageRes
.
tempFilePaths
;
let
maxNum
=
tempFilePaths
.
length
*
1
+
self
.
image_list
.
length
*
1
;
if
(
maxNum
>
self
.
maxNum
)
{
// 获取选择的图片路径数组
const
imagePaths
=
chooseImageRes
.
tempFilePaths
;
// 判断选择的图片数量是否超过最大限制数量
let
maxNum
=
Number
(
imagePaths
.
length
)
+
Number
(
this
.
image_list
.
length
);
//当前上传的+已经上传的
if
(
maxNum
>
this
.
maxNum
)
{
uni
.
hideLoading
();
uni
.
showToast
({
title
:
'图片不超过'
+
self
.
maxNum
+
'张'
,
icon
:
'
error
'
title
:
'图片不超过'
+
this
.
maxNum
+
'张'
,
icon
:
'
none
'
});
return
false
;
}
for
(
let
i
=
0
;
i
<
tempFilePaths
.
length
;
i
++
)
{
// 遍历图片路径数组,对每张图片进行压缩
imagePaths
.
forEach
(
imagePath
=>
{
// 使用compressImage 压缩图片
uni
.
compressImage
({
src
:
imagePath
,
quality
:
50
,
//压缩质量,范围0~100,数值越小,质量越低,压缩率越高
success
:
compressedRes
=>
{
console
.
log
(
'压缩图片成功:'
,
compressedRes
);
// 获取压缩后的图片路径
const
compressedImagePath
=
compressedRes
.
tempFilePath
;
// 在这里处理压缩后的图片,上传到服务器
uni
.
uploadFile
({
url
:
API
.
upload
+
'?sys_type=4'
,
filePath
:
tempFilePaths
[
i
]
,
filePath
:
compressedImagePath
,
name
:
'file'
,
header
:
{
'Content-Type'
:
'multipart/form-data'
},
success
:
uploadFileRes
=>
{
console
.
log
(
'服务器上传图片成功:'
,
uploadFileRes
);
uni
.
hideLoading
();
var
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
let
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
if
(
data
.
code
===
0
)
{
self
.
image_list
.
push
({
this
.
image_list
.
push
({
pic_id
:
data
.
data
.
oss_image_id
,
small_image_url
:
data
.
data
.
small_image_url
,
big_image_url
:
data
.
data
.
big_image_url
});
}
else
{
uni
.
showToast
({
title
:
'网络出现问题'
,
icon
:
'error
'
title
:
data
.
msg
,
icon
:
'none
'
});
}
},
fail
:
error
=>
{
console
.
log
(
'上传图片失败:'
,
error
);
uni
.
hideLoading
();
}
});
},
fail
:
err
=>
{
console
.
log
(
'压缩图片失败:'
,
err
);
}
});
});
}
});
},
...
...
@@ -959,8 +987,14 @@ export default {
if
(
res
.
code
===
0
)
{
if
(
res
.
data
.
list
.
length
>
0
)
{
//过滤出待复核不为0的数据
if
(
this
.
curr
==
0
)
{
var
filteredList
=
res
.
data
.
list
.
filter
(
item
=>
item
.
no_recheck_qty
>
0
);
this
.
list
=
filteredList
;
}
else
if
(
this
.
curr
==
1
)
{
var
filteredList
=
res
.
data
.
list
.
filter
(
item
=>
item
.
total_check_num
>
0
);
this
.
list
=
filteredList
;
}
this
.
filter_list
=
createArray
(
filteredList
.
length
,
false
);
typeof
callback
==
'function'
&&
callback
(
filteredList
);
}
else
{
...
...
pages/tallyReceive/index.vue
View file @
2ffa0ef6
...
...
@@ -624,50 +624,76 @@ export default {
*/
chooseImageChange
()
{
this
.
noexebshowFalg
=
false
;
var
self
=
this
;
// 使用 chooseImage选择图片
uni
.
chooseImage
({
count
:
self
.
maxNums
,
sizeType
:
[
'compressed'
],
count
:
this
.
maxNum
,
sizeType
:
[
'
original'
,
'
compressed'
],
sourceType
:
[
'album'
,
'camera'
],
success
:
chooseImageRes
=>
{
console
.
log
(
'选择图片成功:'
,
chooseImageRes
);
// 显示loading
uni
.
showLoading
({
title
:
'上传中...'
});
const
tempFilePaths
=
chooseImageRes
.
tempFilePaths
;
let
maxNum
=
tempFilePaths
.
length
*
1
+
self
.
image_list
.
length
*
1
;
if
(
maxNum
>
self
.
maxNum
)
{
// 获取选择的图片路径数组
const
imagePaths
=
chooseImageRes
.
tempFilePaths
;
// 判断选择的图片数量是否超过最大限制数量
let
maxNum
=
Number
(
imagePaths
.
length
)
+
Number
(
this
.
image_list
.
length
);
//当前上传的+已经上传的
if
(
maxNum
>
this
.
maxNum
)
{
uni
.
hideLoading
();
uni
.
showToast
({
title
:
'图片不超过'
+
self
.
maxNum
+
'张'
,
icon
:
'
error
'
title
:
'图片不超过'
+
this
.
maxNum
+
'张'
,
icon
:
'
none
'
});
return
false
;
}
for
(
let
i
=
0
;
i
<
tempFilePaths
.
length
;
i
++
)
{
// 遍历图片路径数组,对每张图片进行压缩
imagePaths
.
forEach
(
imagePath
=>
{
// 使用compressImage 压缩图片
uni
.
compressImage
({
src
:
imagePath
,
quality
:
50
,
//压缩质量,范围0~100,数值越小,质量越低,压缩率越高
success
:
compressedRes
=>
{
console
.
log
(
'压缩图片成功:'
,
compressedRes
);
// 获取压缩后的图片路径
const
compressedImagePath
=
compressedRes
.
tempFilePath
;
// 在这里处理压缩后的图片,上传到服务器
uni
.
uploadFile
({
url
:
API
.
upload
+
'?sys_type=4'
,
filePath
:
tempFilePaths
[
i
]
,
filePath
:
compressedImagePath
,
name
:
'file'
,
header
:
{
'Content-Type'
:
'multipart/form-data'
},
success
:
uploadFileRes
=>
{
console
.
log
(
'服务器上传图片成功:'
,
uploadFileRes
);
uni
.
hideLoading
();
var
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
let
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
if
(
data
.
code
===
0
)
{
self
.
image_list
.
push
(
data
.
data
.
oss_image_url
);
this
.
image_list
.
push
(
data
.
data
.
oss_image_url
);
}
else
{
uni
.
showToast
({
title
:
'网络出现问题'
,
icon
:
'error
'
title
:
data
.
msg
,
icon
:
'none
'
});
}
},
fail
:
error
=>
{
console
.
log
(
'上传图片失败:'
,
error
);
uni
.
hideLoading
();
}
});
},
fail
:
err
=>
{
console
.
log
(
'压缩图片失败:'
,
err
);
}
});
});
}
});
},
...
...
pages/tallyReceive/operate.vue
View file @
2ffa0ef6
...
...
@@ -494,50 +494,76 @@ export default {
*/
chooseImageChange
()
{
this
.
noexebshowFalg
=
false
;
var
self
=
this
;
// 使用 chooseImage选择图片
uni
.
chooseImage
({
count
:
self
.
maxNums
,
sizeType
:
[
'compressed'
],
count
:
this
.
maxNum
,
sizeType
:
[
'
original'
,
'
compressed'
],
sourceType
:
[
'album'
,
'camera'
],
success
:
chooseImageRes
=>
{
console
.
log
(
'选择图片成功:'
,
chooseImageRes
);
// 显示loading
uni
.
showLoading
({
title
:
'上传中...'
});
const
tempFilePaths
=
chooseImageRes
.
tempFilePaths
;
let
maxNum
=
tempFilePaths
.
length
*
1
+
self
.
image_list
.
length
*
1
;
if
(
maxNum
>
self
.
maxNum
)
{
// 获取选择的图片路径数组
const
imagePaths
=
chooseImageRes
.
tempFilePaths
;
// 判断选择的图片数量是否超过最大限制数量
let
maxNum
=
Number
(
imagePaths
.
length
)
+
Number
(
this
.
image_list
.
length
);
//当前上传的+已经上传的
if
(
maxNum
>
this
.
maxNum
)
{
uni
.
hideLoading
();
uni
.
showToast
({
title
:
'图片不超过'
+
self
.
maxNum
+
'张'
,
icon
:
'
error
'
title
:
'图片不超过'
+
this
.
maxNum
+
'张'
,
icon
:
'
none
'
});
return
false
;
}
for
(
let
i
=
0
;
i
<
tempFilePaths
.
length
;
i
++
)
{
// 遍历图片路径数组,对每张图片进行压缩
imagePaths
.
forEach
(
imagePath
=>
{
// 使用compressImage 压缩图片
uni
.
compressImage
({
src
:
imagePath
,
quality
:
50
,
//压缩质量,范围0~100,数值越小,质量越低,压缩率越高
success
:
compressedRes
=>
{
console
.
log
(
'压缩图片成功:'
,
compressedRes
);
// 获取压缩后的图片路径
const
compressedImagePath
=
compressedRes
.
tempFilePath
;
// 在这里处理压缩后的图片,上传到服务器
uni
.
uploadFile
({
url
:
API
.
upload
+
'?sys_type=4'
,
filePath
:
tempFilePaths
[
i
]
,
filePath
:
compressedImagePath
,
name
:
'file'
,
header
:
{
'Content-Type'
:
'multipart/form-data'
},
success
:
uploadFileRes
=>
{
console
.
log
(
'服务器上传图片成功:'
,
uploadFileRes
);
uni
.
hideLoading
();
var
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
let
data
=
JSON
.
parse
(
uploadFileRes
.
data
);
if
(
data
.
code
===
0
)
{
self
.
image_list
.
push
(
data
.
data
.
oss_image_url
);
this
.
image_list
.
push
(
data
.
data
.
oss_image_url
);
}
else
{
uni
.
showToast
({
title
:
'网络出现问题'
,
icon
:
'error
'
title
:
data
.
msg
,
icon
:
'none
'
});
}
},
fail
:
error
=>
{
console
.
log
(
'上传图片失败:'
,
error
);
uni
.
hideLoading
();
}
});
},
fail
:
err
=>
{
console
.
log
(
'压缩图片失败:'
,
err
);
}
});
});
}
});
},
...
...
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