Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
O
op-web-service
Project
Project
Details
Activity
Releases
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
bp
op-web-service
Commits
2a0a5ae1
Commit
2a0a5ae1
authored
Aug 12, 2021
by
v-yuchenglong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update:商品添加图片bug
parent
5ab3a7a3
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
11 deletions
+17
-11
addProduc.vue
src/pages/Activity/releaseProduc/components/addProduc.vue
+17
-11
No files found.
src/pages/Activity/releaseProduc/components/addProduc.vue
View file @
2a0a5ae1
...
...
@@ -367,14 +367,11 @@ export default {
},
// 图片删除后
removeDetailFiles
(
file
,
fileList
)
{
for
(
let
i
=
0
;
i
<
fileList
.
length
;
i
++
)
{
if
(
fileList
[
i
].
uid
==
file
.
uid
)
{
this
.
picUploadList
.
splice
(
i
,
1
);
}
}
removeDetailFiles
()
{
this
.
picStr
=
""
;
this
.
hideUpload
=
this
.
picUploadList
.
length
>=
this
.
limitCount
;
this
.
picUrlList
=
[];
this
.
picUploadList
=
[];
// this.hideUpload = this.picUploadList.length >= this.limitCount;
},
// 获取商家
...
...
@@ -394,13 +391,13 @@ export default {
// 查看商品详情
async
markGoodsInfoMet
(
goodSkuID
)
{
this
.
picUrlList
=
[];
let
params
=
{
goods_sku_id
:
goodSkuID
,
marketing_type
:
"4"
};
const
res
=
await
markGoodsInfo
(
params
);
this
.
inventoryRest
=
res
.
result
.
goods_info
.
inventory_rest
;
this
.
inventoryTotal
=
res
.
result
.
goods_info
.
inventory_total
;
this
.
commodityForm
=
res
.
result
.
goods_info
;
this
.
commodityForm
.
business1
=
res
.
result
.
goods_info
.
ota_id
;
this
.
picUrlList
=
[];
for
(
var
i
in
res
.
result
.
goods_info
.
desc_pic_url_list
)
{
this
.
picUrlList
.
push
({
url
:
res
.
result
.
goods_info
.
desc_pic_url_list
[
i
],
...
...
@@ -466,11 +463,13 @@ export default {
// 添加修改商品
async
commodity
(
type
,
val
)
{
this
.
$refs
.
picUpload
&&
this
.
$refs
.
picUpload
.
clearFiles
&&
this
.
$refs
.
picUpload
.
clearFiles
();
this
.
picUrlList
=
[];
this
.
addCommodityPopup
=
true
;
this
.
commodityForm
=
{};
if
(
type
==
"add"
)
{
this
.
hideUpload
=
false
;
// this.picUrlList = [];
this
.
inventoryRest
=
0
;
this
.
commodityForm
.
total_amount_order
=
0
;
this
.
addCommodityTitle
=
"商品添加"
;
...
...
@@ -487,7 +486,7 @@ export default {
const
res
=
await
addGoods
({
marketing_name
:
this
.
stepTwoTitle
,
goods_name
:
this
.
commodityForm
.
goods_name
,
desc_pic_url
:
this
.
pic
UploadList
.
join
(
","
)
,
desc_pic_url
:
this
.
pic
Str
,
desc
:
""
,
inventory
:
this
.
commodityForm
.
inventory_total
,
original_price
:
this
.
commodityForm
.
original_price
,
...
...
@@ -502,7 +501,7 @@ export default {
type
:
"success"
,
});
this
.
comTableData
.
push
(
res
.
result
.
goods_info
);
this
.
$refs
.
picUpload
.
clearFiles
();
//
this.$refs.picUpload.clearFiles();
this
.
addCommodityPopup
=
false
;
}
else
{
ElMessage
.
error
(
res
.
reason
);
...
...
@@ -592,6 +591,13 @@ export default {
}
this
.
comTableData
=
newVal
;
},
picUrlList
:
function
()
{
if
(
this
.
picUrlList
.
length
>=
this
.
limitCount
)
{
this
.
hideUpload
=
true
}
else
{
this
.
hideUpload
=
false
}
}
},
created
()
{
this
.
getBusinessListMet
();
...
...
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