Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
Y
yongxinda-admin
Project
Project
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
Graph
比较
统计图
议题
0
议题
0
列表
看板
标记
Milestones
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
刘旭
yongxinda-admin
Commits
3dc3f17b
提交
3dc3f17b
authored
11月 16, 2022
作者:
刘旭
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
优化
上级
0d18fd71
隐藏空白字符变更
内嵌
并排
正在显示
3 个修改的文件
包含
17 行增加
和
5 行删除
+17
-5
edit.vue
src/views/commodityManage/edit.vue
+9
-1
selectSpec.vue
src/views/commodityManage/selectSpec.vue
+1
-3
shelves.vue
src/views/commodityManage/shelves.vue
+7
-1
没有找到文件。
src/views/commodityManage/edit.vue
浏览文件 @
3dc3f17b
<
template
>
<div
class=
"app-container"
>
<el-drawer
v-model=
"editDrawer"
size=
"100%"
@
before-close=
"handleCancel"
>
<el-drawer
v-model=
"editDrawer"
size=
"100%"
:
before-close=
"handleCancel"
>
<el-card
class=
"box-card"
>
<h3>
商品介绍
</h3>
<el-form
ref=
"goodsRef"
:rules=
"rules"
:model=
"goods"
label-width=
"150px"
>
...
...
@@ -319,12 +319,15 @@ initList()
let
init
=
(
id
:
number
)
=>
{
detailGoods
(
id
).
then
((
res
:
any
)
=>
{
if
(
res
.
code
===
200
)
{
if
(
!
res
.
data
.
goods
.
gallery
)
res
.
data
.
goods
.
gallery
=
[]
res
.
data
.
goods
.
gallery
.
map
((
item
:
any
)
=>
{
fileList
.
value
.
push
({
url
:
item
,
name
:
item
.
split
(
'/'
)[
item
.
split
(
'/'
).
length
-
1
]
})
})
goods
.
value
=
res
.
data
.
goods
;
for
(
let
s
in
res
.
data
.
parts
)
{
goodsParts
.
value
.
push
(
res
.
data
.
parts
[
s
].
partGoodsId
)
...
...
@@ -548,6 +551,11 @@ let handleSpecificationAdd = () => {
}
else
{
specForm
.
value
.
value
=
specForm
.
value
.
value
[
0
]
specifications
.
value
[
dictTableIndex
.
value
]
=
specForm
.
value
specifications
.
value
?.
forEach
((
item
:
any
)
=>
{
if
(
specifications
.
value
[
dictTableIndex
.
value
].
specification
===
item
.
specification
)
{
item
.
customSpec
=
specifications
.
value
[
dictTableIndex
.
value
].
customSpec
}
})
specVisiable
.
value
=
false
;
}
}
...
...
src/views/commodityManage/selectSpec.vue
浏览文件 @
3dc3f17b
...
...
@@ -96,8 +96,6 @@ let radioChange = (e: any, item: any) => {
}
})
if
(
specList
.
value
.
indexOf
(
e
)
==
-
1
)
specList
.
value
.
push
(
e
)
console
.
log
(
specList
.
value
,
'specList'
);
}
let
clickAdd
=
()
=>
{
...
...
@@ -112,7 +110,7 @@ let clickAdd = () => {
specList
.
value
=
[]
specData
.
value
=
poty
.
value
emits
(
'productsData'
,
attributes
.
value
)
console
.
log
(
attributes
.
value
,
'规格属性数据'
);
//
console.log(attributes.value, '规格属性数据');
}
let
handleAttributeDelete
=
(
row
:
any
)
=>
{
let
index
=
attributes
.
value
.
indexOf
(
row
);
...
...
src/views/commodityManage/shelves.vue
浏览文件 @
3dc3f17b
<
template
>
<div
class=
"app-container"
>
<el-drawer
v-model=
"shelvesDrawer"
size=
"100%"
@
before-close=
"handleCancel"
>
<el-drawer
v-model=
"shelvesDrawer"
size=
"100%"
:
before-close=
"handleCancel"
>
<el-card
class=
"box-card"
>
<h3>
商品介绍
</h3>
<el-form
ref=
"goodsRef"
:rules=
"rules"
:model=
"goods"
label-width=
"150px"
>
...
...
@@ -468,6 +468,7 @@ let handleSpecificationAdd = () => {
customSpec
:
dictSwitch
.
value
})
}
specForm
.
value
.
customSpec
=
false
specVisiable
.
value
=
false
;
specToProduct
();
}
else
{
...
...
@@ -479,6 +480,11 @@ let handleSpecificationAdd = () => {
}
else
{
specForm
.
value
.
value
=
specForm
.
value
.
value
[
0
]
specifications
.
value
[
dictTableIndex
.
value
]
=
specForm
.
value
specifications
.
value
?.
forEach
((
item
:
any
)
=>
{
if
(
specifications
.
value
[
dictTableIndex
.
value
].
specification
===
item
.
specification
)
{
item
.
customSpec
=
specifications
.
value
[
dictTableIndex
.
value
].
customSpec
}
})
specVisiable
.
value
=
false
;
}
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论