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
539658d4
authored
Jul 29, 2025
by
liangjianmin
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
feat(shipOut): 添加出库单图片管理功能,支持回单图和客户收货图的上传与删除
parent
99a826e8
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
47 additions
and
24 deletions
pages/stockRecheck/shipOut.vue
util/api.js
pages/stockRecheck/shipOut.vue
View file @
539658d4
...
...
@@ -119,15 +119,39 @@
<text
class=
"text"
>
{{
item
.
finish_time
}}
</text>
</view>
<view
class=
"input-box row"
style=
"flex: 0 0 100%;"
>
<text
class=
"label"
>
回单图片:
</text>
<view
class=
"pick_img_list row"
>
<template
v-if=
"item.receipt_img_list.length > 0"
>
<view
class=
"img_list"
v-for=
"(v, i) in item.receipt_img_list"
:key=
"i"
>
<image
:src=
"v.small_image_url"
mode=
"aspectFill"
@
click=
"previewChange(item.receipt_img_list, i)"
></image>
<text
class=
"iconfont icon-a-juxing11"
@
click=
"deletePic(index, i)"
v-if=
"v.id_del"
></text>
</view>
</
template
>
<view
class=
"default row rowCenter verCenter"
@
click=
"chooseImageChange(index, 2)"
v-if=
"item.receipt_img_list.length < maxNum"
><text
class=
"iconfont icon-a-juxing3"
></text></view>
</view>
</view>
<view
class=
"input-box row"
style=
"flex: 0 0 100%;"
>
<text
class=
"label"
>
客户收货图片:
</text>
<view
class=
"pick_img_list row"
>
<
template
v-if=
"item.customer_take_img_list.length > 0"
>
<view
class=
"img_list"
v-for=
"(v, i) in item.customer_take_img_list"
:key=
"i"
>
<image
:src=
"v.small_image_url"
mode=
"aspectFill"
@
click=
"previewChange(item.customer_take_img_list, i)"
></image>
<text
class=
"iconfont icon-a-juxing11"
@
click=
"deletePic(index, i)"
v-if=
"v.id_del"
></text>
</view>
</
template
>
<view
class=
"default row rowCenter verCenter"
@
click=
"chooseImageChange(index, 3)"
v-if=
"item.customer_take_img_list.length < maxNum"
><text
class=
"iconfont icon-a-juxing3"
></text></view>
</view>
</view>
<view
class=
"input-box row"
style=
"flex: 0 0 100%;"
>
<text
class=
"label"
>
签收图片:
</text>
<view
class=
"pick_img_list row"
>
<template
v-if=
"item.sign_
pic_ids
.length > 0"
>
<view
class=
"img_list"
v-for=
"(v, i) in item.sign_
pic_ids
"
:key=
"i"
>
<image
:src=
"v.small_image_url"
mode=
"aspectFill"
@
click=
"previewChange(item.sign_
pic_ids
, i)"
></image>
<
template
v-if=
"item.sign_
img_list
.length > 0"
>
<view
class=
"img_list"
v-for=
"(v, i) in item.sign_
img_list
"
:key=
"i"
>
<image
:src=
"v.small_image_url"
mode=
"aspectFill"
@
click=
"previewChange(item.sign_
img_list
, i)"
></image>
<text
class=
"iconfont icon-a-juxing11"
@
click=
"deletePic(index, i)"
v-if=
"v.id_del"
></text>
</view>
</
template
>
<view
class=
"default row rowCenter verCenter"
@
click=
"chooseImageChange(index
)"
v-if=
"item.sign_pic_ids
.length < maxNum"
><text
class=
"iconfont icon-a-juxing3"
></text></view>
<view
class=
"default row rowCenter verCenter"
@
click=
"chooseImageChange(index
, 1)"
v-if=
"item.sign_img_list
.length < maxNum"
><text
class=
"iconfont icon-a-juxing3"
></text></view>
</view>
</view>
<view
class=
"row"
style=
"justify-content: flex-end;width: 100%;"
>
...
...
@@ -414,9 +438,9 @@
box_num
:
''
,
//包裹数
select_box_type
:
''
//箱信息类型
},
s
ignUserPic
Params
:
{
type
:
1
,
//1上传 2删除
img_id
:
''
,
s
etStockoutPics
Params
:
{
pic_type
:
''
,
// 1签收图 2回单图 3客户收货图
pic_ids
:
''
,
stock_out_id
:
''
}
};
...
...
@@ -935,7 +959,7 @@
/**
* 选择图片
*/
chooseImageChange
(
index
)
{
chooseImageChange
(
index
,
pic_type
)
{
this
.
noexebshowFalg
=
false
;
// 使用 chooseImage选择图片
uni
.
chooseImage
({
...
...
@@ -1007,7 +1031,7 @@
let
img_id
=
data
.
data
.
oss_image_id
;
//签约图片更新
this
.
s
ignUserPic
(
this
.
list
[
index
].
stock_out_id
,
img_id
,
1
);
this
.
s
etStockoutPics
(
this
.
list
[
index
].
stock_out_id
,
img_id
,
pic_type
);
}
else
{
uni
.
showToast
({
...
...
@@ -1033,22 +1057,21 @@
}
});
},
/**
* 删除和新增签约图片
/** 保存出库单图片
* @param {number} stock_out_id - 出库单ID
* @param {string} img_id - 图片ID,多个以逗号分隔
* @param {number}
type - 操作类型:1-新增 2-删除
* @param {number}
pic_type - 1 签收图 2回单图 3客户收货图
*/
s
ignUserPic
(
stock_out_id
,
img_id
,
type
,
callback
)
{
s
etStockoutPics
(
stock_out_id
,
pic_ids
,
pic_
type
,
callback
)
{
// 使用对象展开运算符一次性更新参数
this
.
s
ignUserPic
Params
=
{
...
this
.
s
ignUserPic
Params
,
this
.
s
etStockoutPics
Params
=
{
...
this
.
s
etStockoutPics
Params
,
stock_out_id
,
img_id
,
type
pic_ids
,
pic_
type
};
this
.
request
(
API
.
s
ignUserPic
,
'POST'
,
this
.
signUserPic
Params
,
true
).
then
(
res
=>
{
this
.
request
(
API
.
s
etStockoutPics
,
'POST'
,
this
.
setStockoutPics
Params
,
true
).
then
(
res
=>
{
if
(
res
.
code
===
0
)
{
uni
.
showToast
({
title
:
'操作成功'
,
...
...
@@ -1075,12 +1098,8 @@
success
:
(
res
)
=>
{
if
(
res
.
confirm
)
{
//签约图片删除
this
.
signUserPic
(
this
.
list
[
index
].
stock_out_id
,
this
.
list
[
index
].
sign_pic_ids
[
i
].
img_id
,
2
,
()
=>
{
this
.
list
[
index
].
sign_pic_ids
.
splice
(
i
,
1
);
this
.
list
=
[...
this
.
list
];
this
.
$forceUpdate
();
});
}
else
if
(
res
.
cancel
)
{
// 用户点击取消
console
.
log
(
'用户点击取消'
);
...
...
util/api.js
View file @
539658d4
...
...
@@ -420,6 +420,10 @@ const API = {
* */
signUserPic
:
API_BASE
+
'/api/stockout/signUserPic'
,
/**
* 保存出库单图片
*/
setStockoutPics
:
API_BASE
+
'/api/stockOut/setStockoutPics'
,
/**
* 查询相似三方送检任务数
* */
isHasShippingCodeInspectionOrder
:
API_BASE
+
'/api/inspectionOrder/isHasShippingCodeInspectionOrder'
,
...
...
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