Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
dj-car-life-system
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit e4258f70
authored
Aug 09, 2024
by
zhangxw
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
套餐支持全场景上架需求开发
1 parent
18a791fa
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
339 additions
and
75 deletions
src/views/goods/grounding/components/detail.vue
src/views/goods/grounding/constants/data.js
src/views/goods/packageManage/components/detail.vue
src/views/goods/packageManage/components/packageForm.vue
src/views/goods/packageManage/editPackage.vue
src/views/goods/packageManage/index.vue
src/views/goods/packageManage/packageView.vue
src/views/goods/productManage/components/multipleSpecificationForm.vue
src/views/goods/productManage/components/singleSpecificationForm.vue
src/views/goods/productManage/update.vue
src/views/goods/grounding/components/detail.vue
View file @
e4258f7
...
...
@@ -251,9 +251,9 @@ export default {
:
shopType
==
'2'
?
[
'positionStr'
,
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'giftCost'
,
'recoveryCost'
,
'virtualAccountCost'
,
'djCost'
,
'thirdPartyCost'
]
:
this
.
equitySceneType
.
includes
(
formData
?.
goodsType
)
||
this
.
extendedPosiType
.
includes
(
formData
?.
goodsType
)
?
(
this
.
extendedPosiType
.
includes
(
formData
?.
goodsType
)
&&
this
.
baseConfig
.
supplierCode
.
includes
(
`${formData.supplierCode
}
`
)
?
[
'p
ositionStr'
,
'p
roductTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'giftCost'
,
'recoveryCost'
,
'virtualAccountCost'
,
'upgradeProductCost'
]
:
[
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'giftCost'
,
'recoveryCost'
,
'virtualAccountCost'
,
'upgradeProductCost'
])
?
(
this
.
extendedPosiType
.
includes
(
formData
?.
goodsType
)
&&
!
this
.
baseConfig
.
supplierCode
.
includes
(
`${formData.supplierCode
}
`
)
?
[
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'giftCost'
,
'recoveryCost'
,
'virtualAccountCost'
,
'upgradeProductCost'
]
:
[
'p
ositionStr'
,
'p
roductTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'giftCost'
,
'recoveryCost'
,
'virtualAccountCost'
,
'upgradeProductCost'
])
:
[
'positionStr'
,
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'giftCost'
,
'recoveryCost'
,
'virtualAccountCost'
,
'djCost'
,
'thirdPartyCost'
]
// 未勾选基础商品类型
if
(
!
this
.
formData
.
productType
?.
includes
(
1
))
spliceForm
.
push
(
'baseSupplyModeStr'
)
...
...
src/views/goods/grounding/constants/data.js
View file @
e4258f7
...
...
@@ -36,3 +36,205 @@ export const crowdUpgradeSupplyModeList = [{
confId
:
2
,
confName
:
'门店'
}]
// 套餐上架商品信息form表单
export
const
packageGoodsForm
=
[{
name
:
'upgradeGoodsId'
,
label
:
'上架商品'
,
isRequired
:
true
,
type
:
'searchSelect'
,
optionList
:
[],
isClear
:
false
,
optionId
:
'confId'
,
optionNameLabel
:
'confNameValue'
,
optionTypeNameLabel
:
'confTypeNameValue'
,
width
:
'432px'
},
{
type
:
'incidBox'
,
key
:
'goodsType'
,
detailInfo
:
[{
label
:
'商品名称'
,
value
:
'upgradeGoodsName'
},
{
label
:
'商品编码'
,
value
:
'type'
},
{
label
:
'第三方编码'
,
value
:
'thirdPartyCode'
},
{
label
:
'采购价'
,
value
:
'purchasePrice'
,
unit
:
true
},
{
label
:
'参考售价'
,
value
:
'upgradePrice'
,
unit
:
true
},
{
label
:
'所属系列'
,
value
:
'goodsName'
},
{
label
:
'所属分类'
,
value
:
'goodsTypeName'
},
{
label
:
'商品ID'
,
value
:
'upgradeCommodityCode'
}]
},
{
name
:
'position'
,
label
:
'上架部位'
,
type
:
'radio'
,
radioGroupList
:
[]
},
{
name
:
'goodsAlias'
,
label
:
'商品别名'
,
type
:
'input'
,
maxlength
:
50
,
width
:
'432px'
},
{
name
:
'warrantyType'
,
label
:
'质保卡类型'
,
type
:
'select'
,
isClear
:
false
,
optionList
:
[{
confId
:
0
,
confName
:
'质保卡'
},
{
confId
:
1
,
confName
:
'质保权益卡'
}],
optionId
:
'confId'
,
optionLabel
:
'confName'
,
width
:
'432px'
},
{
name
:
'upgradeSupplyMode'
,
label
:
'升级/产品供货模式'
,
type
:
'radio'
,
index
:
2
,
radioGroupList
:
[]
},
{
name
:
'sellPrice'
,
label
:
'售价'
,
type
:
'input'
,
width
:
'432px'
,
unit
:
true
,
handleInput
:
true
},
{
name
:
'minSellPrice'
,
label
:
'最低售价'
,
type
:
'input'
,
width
:
'432px'
,
unit
:
true
,
handleInput
:
true
},
{
name
:
'upgradeProductCost'
,
label
:
'产品、升级成本'
,
type
:
'input'
,
width
:
'432px'
,
unit
:
true
,
handleInput
:
true
},
{
name
:
'recoveryCost'
,
label
:
'回收成本'
,
type
:
'input'
,
width
:
'432px'
,
unit
:
true
,
handleInput
:
true
},
{
name
:
'virtualAccountCost'
,
label
:
'虚拟对账成本'
,
type
:
'input'
,
width
:
'432px'
,
unit
:
true
,
handleInput
:
true
},
{
name
:
'djCost'
,
label
:
'嘀加成本'
,
type
:
'input'
,
width
:
'432px'
,
unit
:
true
,
handleInput
:
true
},
{
name
:
'thirdPartyCost'
,
label
:
'第三方成本'
,
type
:
'input'
,
width
:
'432px'
,
unit
:
true
,
handleInput
:
true
}]
// 套餐查看详情form
export
const
packageGoodsDetail
=
[
{
name
:
'upgradeGoodsName'
,
label
:
'上架商品'
,
type
:
'incidBox'
,
key
:
'goodsType'
,
detailInfo
:
[{
label
:
'商品名称'
,
value
:
'upgradeGoodsName'
},
{
label
:
'商品编码'
,
value
:
'type'
},
{
label
:
'第三方编码'
,
value
:
'thirdPartyCode'
},
{
label
:
'采购价'
,
value
:
'purchasePrice'
,
unit
:
true
},
{
label
:
'参考售价'
,
value
:
'upgradePrice'
,
unit
:
true
},
{
label
:
'所属系列'
,
value
:
'goodsName'
},
{
label
:
'所属分类'
,
value
:
'goodsTypeName'
},
{
label
:
'商品ID'
,
value
:
'upgradeCommodityCode'
}]
},
{
name
:
'positionStr'
,
label
:
'上架部位'
},
{
name
:
'goodsAlias'
,
label
:
'商品别名'
},
{
name
:
'warrantyTypeStr'
,
label
:
'质保卡类型'
},
{
name
:
'upgradeSupplyModeStr'
,
label
:
'升级产品供货模式'
},
{
name
:
'sellPrice'
,
label
:
'售价'
,
unit
:
true
},
{
name
:
'minSellPrice'
,
label
:
'最低售价'
,
unit
:
true
},
{
name
:
'upgradeProductCost'
,
label
:
'产品、升级成本'
,
unit
:
true
},
{
name
:
'recoveryCost'
,
label
:
'回收成本'
,
unit
:
true
},
{
name
:
'virtualAccountCost'
,
label
:
'虚拟对账成本'
,
unit
:
true
},
{
name
:
'djCost'
,
label
:
'嘀加成本'
,
unit
:
true
},
{
name
:
'thirdPartyCost'
,
label
:
'第三方成本'
,
unit
:
true
}
]
src/views/goods/packageManage/components/detail.vue
View file @
e4258f7
...
...
@@ -15,7 +15,7 @@
<!-- 商品信息块 -->
<div
v-if=
"idx == 1"
class=
"flex_item"
>
<div
v-for=
"(ele, eleIndex) in formData['groundingGoodsList']"
:key=
"eleIndex"
class=
"groundingGoods-item"
>
<div
v-for=
"(item, index) in i.formBlock
"
:key=
"index"
:class=
"(item.type === 'incidBox' || item.type === 'table' || item.type === 'upload
') ? 'item message-box' : 'item'"
>
<div
v-for=
"(item, index) in i.formBlock
[eleIndex]"
:key=
"index"
:class=
"(item.type === 'incidBox
') ? 'item message-box' : 'item'"
>
<!-- 商品附带信息 -->
<div
v-if=
"item.type === 'incidBox'"
>
<el-form-item
:prop=
"`groundingGoodsList[$
{eleIndex}][${item.name}]`"
...
...
@@ -25,14 +25,20 @@
style="margin-bottom: 0">
<div
class=
"incid_box"
>
<div
class=
"item"
v-for=
"(subItem, subIndex) in item.detailInfo"
:key=
"subIndex"
>
<div
class=
"label"
>
{{
subItem
.
unit
?
(
subItem
.
label
+
'(元)/件'
)
:
subItem
.
label
}}
:
</div>
<div
class=
"label"
>
{{
subItem
.
unit
?
(
membraneTypeList
.
includes
(
ele
[
item
.
key
])
?
subItem
.
label
+
`(元)/${subItem.value == 'purchasePrice' ? '卷' : '车'
}
`
:
(
subItem
.
label
+
'(元)/件'
))
:
subItem
.
label
}}
:
<
/div
>
<
div
class
=
"value"
>
{{
subItem
.
unit
?
priceFilter
(
ele
[
subItem
.
value
])
:
ele
[
subItem
.
value
]
}}
<
/div
>
<
/div
>
<!--
商品分类
延保类
-->
<div
class=
"item"
v-if=
"e
xtendedPosiType.includes(ele[item.key]) && !baseConfig.supplierCode.includes(`$
{ele['supplierCode']}`
)">
<
div
class
=
"item"
v
-
if
=
"
e
le
[
item
.
key
]
==
1
||
(
extendedPosiType
.
includes
(
ele
[
item
.
key
])
&&
!
baseConfig
.
supplierCode
.
includes
(
`${ele['supplierCode']
}
`
)
)
">
<div class="
label
">部位:</div>
<div class="
value
"
>
{{
ele
[
'positionNames'
]
}}
<
/div
>
<
/div
>
<!--
质保年限
膜类展示
-->
<
div
class
=
"item"
v
-
if
=
"membraneTypeList.includes(ele[item.key])"
>
<
div
class
=
"label"
>
质保年限
/
年:
<
/div
>
<
div
class
=
"value"
>
{{
ele
[
'warrantyPeriod'
]
}}
<
/div
>
<
/div
>
<!--
商品分类
权益升级
(线上
126
)
-->
<
div
class
=
"item"
v
-
if
=
"
equitySceneType
.
includes
(
ele
[
item
.
key
])
&&
!
baseConfig
.
supplierCode
.
includes
(
`${ele['supplierCode']
}
`
)
">
<div class="
label
">服务时间/年:</div>
...
...
@@ -59,13 +65,13 @@
<
div
v
-
else
>
<
el
-
form
-
item
:
prop
=
"
`groundingGoodsList[${eleIndex
}
][${item.name
}
]`"
:rules="
rules
[
item
.
name
]
"
:label="item.label ? (item.unit ? (
item.label + '(元)/件'
) : item.label) + ':' : ''"
v-if="item.name !== 'positionStr' || (item.name == 'positionStr'
&&
extendedPosiType.includes(ele.goodsType)
&&
!baseConfig.supplierCode.includes(`${ele['supplierCode']}`))"
:label="
item
.
label
?
(
item
.
unit
?
(
membraneTypeList
.
includes
(
ele
[
'goodsType'
])
?
item
.
label
+
`(元)/车`
:
(
item
.
label
+
'(元)/件'
)
)
:
item
.
label
)
+
':'
:
''
"
v-if="
item
.
name
!==
'positionStr'
||
(
item
.
name
==
'positionStr'
&&
e
le
.
goodsType
==
1
)
||
(
item
.
name
==
'positionStr'
&&
e
xtendedPosiType
.
includes
(
ele
.
goodsType
)
&&
!
baseConfig
.
supplierCode
.
includes
(
`${ele['supplierCode']
}
`
))
"
:label-width="
item
.
label
?
'180px'
:
'0px'
"
class="
dis
-
in
-
block
"
style="
margin
-
bottom
:
0
"
>
<
div
>
<span>
{{
item
.
unit
?
priceFilter
(
ele
[
item
.
name
])
:
(
ele
[
item
.
name
])
}}
</span>
<
span
>
{{
item
.
unit
?
priceFilter
(
ele
[
item
.
name
])
:
(
ele
[
item
.
name
])
}}
<
/span
>
<
span
v
-
if
=
"item.name == 'minSellPrice'"
>
{{
ele
[
'validMinSellPrice'
]
==
'Y'
?
'(校验最低价)'
:
'(不校验最低价)'
}}
<
/span
>
<
/div
>
<
/el-form-item
>
...
...
@@ -125,7 +131,7 @@
class
=
"dis-in-block"
style
=
"margin-bottom: 0"
>
<
div
>
<span>
{{
item
.
unit
?
priceFilter
(
formData
[
item
.
name
])
:
formData
[
item
.
name
]
}}
</span>
<
span
>
{{
item
.
unit
||
item
.
isPrice
?
priceFilter
(
formData
[
item
.
name
])
||
'-'
:
formData
[
item
.
name
]
||
'-'
}}
<
/span
>
<
/div
>
<
/el-form-item
>
<
/div
>
...
...
@@ -171,6 +177,7 @@ export default {
return
{
equitySceneType
:
baseConfig
.
equitySceneType
||
[],
// 权益类目
extendedPosiType
:
baseConfig
.
extendedPosiType
||
[],
// 延保类
membraneTypeList
:
baseConfig
.
membraneTypeList
,
userInfo
:
this
.
$store
.
state
.
d2admin
.
user
.
info
,
formData
:
{
}
,
examineFlag
:
false
,
...
...
@@ -223,6 +230,9 @@ export default {
}
,
mounted
()
{
deepClone
(
this
.
originData
?.
groundingGoodsList
)?.
forEach
((
v
,
index
)
=>
{
this
.
filterForm
(
index
,
deepClone
(
this
.
originData
))
}
)
this
.
formData
=
deepClone
(
this
.
originData
)
this
.
$nextTick
(()
=>
{
const
$store
=
this
.
$store
.
getters
[
'd2admin/auth/curBtns'
]
...
...
@@ -238,6 +248,36 @@ export default {
...
mapActions
({
get
:
'd2admin/base/get'
}
),
filterForm
(
index
,
formData
)
{
const
{
formList
}
=
this
const
itemData
=
formData
?.
groundingGoodsList
[
index
]
// 1 太阳膜 2 (1.3场景商品)
const
shopType
=
itemData
?.
goodsType
==
1
?
'1'
:
itemData
?.
sceneType
==
3
?
'2'
:
''
const
shopForm
=
deepClone
(
formList
[
1
].
formBlock
[
index
])
// 太阳膜/延保类(第三方供应方)保留上架部位字段 positionStr
const
spliceForm
=
shopType
==
'1'
?
[
'giftCost'
,
'recoveryCost'
,
'virtualAccountCost'
,
'djCost'
,
'thirdPartyCost'
]
:
shopType
==
'2'
?
[
'positionStr'
,
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'recoveryCost'
,
'virtualAccountCost'
,
'djCost'
,
'thirdPartyCost'
]
:
this
.
equitySceneType
.
includes
(
itemData
?.
goodsType
)
||
this
.
extendedPosiType
.
includes
(
itemData
?.
goodsType
)
?
(
this
.
extendedPosiType
.
includes
(
itemData
?.
goodsType
)
&&
!
this
.
baseConfig
.
supplierCode
.
includes
(
`${itemData.supplierCode
}
`
)
?
[
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'recoveryCost'
,
'virtualAccountCost'
,
'upgradeProductCost'
]
:
[
'positionStr'
,
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'recoveryCost'
,
'virtualAccountCost'
,
'upgradeProductCost'
])
:
[
'positionStr'
,
'productTypeStr'
,
'warrantyTypeStr'
,
'baseSupplyModeStr'
,
'upgradeSupplyModeStr'
,
'recoveryCost'
,
'virtualAccountCost'
,
'djCost'
,
'thirdPartyCost'
]
// 回收成本:产品供货模式选择“门店回收原厂+嘀加”时展示
if
(
itemData
.
upgradeSupplyMode
==
4
)
{
spliceForm
.
indexOf
(
'recoveryCost'
)
>
-
1
&&
spliceForm
.
splice
(
spliceForm
.
indexOf
(
'recoveryCost'
),
1
)
}
// 虚拟对账成本:产品供货模式选择“门店套码+嘀加”“ 服务商自采+嘀加”时展示
if
(
itemData
.
upgradeSupplyMode
==
3
||
itemData
.
upgradeSupplyMode
==
5
)
{
spliceForm
.
indexOf
(
'virtualAccountCost'
)
>
-
1
&&
spliceForm
.
splice
(
spliceForm
.
indexOf
(
'virtualAccountCost'
),
1
)
}
const
newForm
=
shopForm
.
filter
(
v
=>
!
spliceForm
?.
includes
(
v
.
name
))
this
.
$set
(
this
.
formList
[
1
].
formBlock
,
index
,
newForm
)
this
.
$nextTick
(()
=>
{
this
.
show
=
true
}
)
}
,
// 文件预览
handleFileView
(
item
)
{
if
(
item
?.
voucherFileUrl
?.
includes
(
'.pdf'
))
{
...
...
@@ -317,6 +357,13 @@ export default {
.
groundingGoods
-
item
{
padding
-
top
:
15
px
;
border
-
bottom
:
1
px
solid
#
E5E5E5
;
.
item
{
display
:
inline
-
block
;
width
:
33
%
;
}
.
message
-
box
{
width
:
100
%
}
}
.
groundingGoods
-
item
:
last
-
child
{
border
:
none
;
...
...
src/views/goods/packageManage/components/packageForm.vue
View file @
e4258f7
This diff is collapsed.
Click to expand it.
src/views/goods/packageManage/editPackage.vue
View file @
e4258f7
This diff is collapsed.
Click to expand it.
src/views/goods/packageManage/index.vue
View file @
e4258f7
...
...
@@ -226,6 +226,27 @@ export default {
},
width
:
'100'
},
{
label
:
'产品、升级成本/元'
,
prop
:
'upgradeProductCost'
,
formatter
:
(
cellValue
)
=>
{
return
this
.
priceFilter
(
cellValue
.
upgradeProductCost
)
},
width
:
'150'
},
{
label
:
'虚拟对账成本/元'
,
prop
:
'virtualAccountCost'
,
formatter
:
(
cellValue
)
=>
{
return
this
.
priceFilter
(
cellValue
.
virtualAccountCost
)
},
width
:
'150'
},
{
label
:
'回收成本/元'
,
prop
:
'recoveryCost'
,
formatter
:
(
cellValue
)
=>
{
return
this
.
priceFilter
(
cellValue
.
recoveryCost
)
},
width
:
'100'
},
{
label
:
'嘀加成本/元'
,
prop
:
'djCost'
,
formatter
:
(
cellValue
)
=>
{
...
...
src/views/goods/packageManage/packageView.vue
View file @
e4258f7
...
...
@@ -15,6 +15,7 @@ import { sceneList, BaseData } from '@/common/constants.js'
import
{
mapActions
}
from
'vuex'
import
{
deepClone
,
Util
}
from
'@/common/util'
import
{
baseConfig
}
from
"@/main"
import
{
packageGoodsDetail
,
upgradeSupplyModeList
,
crowdUpgradeSupplyModeList
}
from
'../grounding/constants/data'
export
default
{
name
:
'PackageDetail'
,
components
:
{
...
...
@@ -32,7 +33,10 @@ export default {
sellPrice
:
[{
required
:
true
}],
minSellPrice
:
[{
required
:
true
}],
djCost
:
[{
required
:
true
}],
thirdPartyCost
:
[{
required
:
true
}]
thirdPartyCost
:
[{
required
:
true
}],
upgradeProductCost
:
[{
required
:
true
}],
recoveryCost
:
[{
required
:
true
}],
virtualAccountCost
:
[{
required
:
true
}]
},
editForm
:
[{
title
:
'套餐信息'
,
...
...
@@ -42,78 +46,43 @@ export default {
},
{
name
:
'sellPrice'
,
label
:
'售价'
,
unit
:
true
// unit: true
isPrice
:
true
},
{
name
:
'minSellPrice'
,
label
:
'最低售价'
,
unit
:
true
// unit: true
isPrice
:
true
},
{
name
:
'djCost'
,
label
:
'嘀加成本'
,
unit
:
true
},
{
name
:
'thirdPartyCost'
,
label
:
'第三方成本'
,
unit
:
true
}]
},
{
title
:
'商品信息'
,
formBlock
:
[{
name
:
'upgradeGoodsName'
,
label
:
'上架商品'
,
type
:
'incidBox'
,
key
:
'goodsType'
,
detailInfo
:
[{
label
:
'商品名称'
,
value
:
'upgradeGoodsName'
},
{
label
:
'商品编码'
,
value
:
'type'
},
{
label
:
'第三方编码'
,
value
:
'thirdPartyCode'
},
{
label
:
'采购价'
,
value
:
'purchasePrice'
,
unit
:
true
},
{
label
:
'参考售价'
,
value
:
'upgradePrice'
,
unit
:
true
},
{
label
:
'所属系列'
,
value
:
'goodsName'
},
{
label
:
'所属分类'
,
value
:
'goodsTypeName'
},
{
label
:
'商品ID'
,
value
:
'upgradeCommodityCode'
}]
name
:
'upgradeProductCost'
,
label
:
'产品、升级成本'
,
// unit: true
isPrice
:
true
},
{
name
:
'positionStr'
,
label
:
'上架部位'
name
:
'recoveryCost'
,
label
:
'回收成本'
,
// unit: true
isPrice
:
true
},
{
name
:
'goodsAlias'
,
label
:
'商品别名'
},
{
name
:
'sellPrice'
,
label
:
'售价'
,
unit
:
true
},
{
name
:
'minSellPrice'
,
label
:
'最低售价'
,
unit
:
true
name
:
'virtualAccountCost'
,
label
:
'虚拟对账成本'
,
// unit: true
isPrice
:
true
},
{
name
:
'djCost'
,
label
:
'嘀加成本'
,
unit
:
true
// unit: true
isPrice
:
true
},
{
name
:
'thirdPartyCost'
,
label
:
'第三方成本'
,
unit
:
true
// unit: true
isPrice
:
true
}]
},
{
title
:
'商品信息'
,
formBlock
:
[]
},
{
title
:
'门店信息'
,
formBlock
:
[{
name
:
'sceneName'
,
...
...
@@ -137,7 +106,11 @@ export default {
show
:
false
,
editData
:
{},
examineFlag
:
false
,
detailId
:
''
detailId
:
''
,
warrantyTypeShow
:
{
0
:
'质保卡'
,
1
:
'质保权益卡'
},
}
},
mounted
()
{
...
...
@@ -155,24 +128,33 @@ export default {
}),
async
getBaseData
()
{
this
.
extendedPosiTypeList
=
await
this
.
get
(
BaseData
.
extendedPosiTypeList
)
this
.
positionTypeList
=
await
this
.
get
(
BaseData
.
positionTypeList
)
},
getDetailInfo
(
id
)
{
getPackageDetailInfo
({
id
}).
then
(
res
=>
{
res
.
reviewLogList
?.
forEach
(
val
=>
{
val
.
updatedDateStr
=
val
.
updatedDate
?
Util
.
dateFormate
(
val
.
updatedDate
,
'YYYY-MM-DD HH:mm:ss'
)
:
''
})
let
arr
=
[]
if
(
res
.
sceneType
==
3
)
{
// 1.3场景 升级产品供货模式
arr
=
crowdUpgradeSupplyModeList
}
res
.
groundingGoodsList
=
[]
res
?.
merchantGoodsInfoList
?.
forEach
(
val
=>
{
if
(
val
.
goodsType
==
1
)
{
// 太阳膜类 升级产品供货模式(优先级高)
arr
=
upgradeSupplyModeList
}
this
.
editForm
[
1
].
formBlock
.
push
(
packageGoodsDetail
)
// 延保类回显部位
const
positionNamesArr
=
deepClone
(
this
.
extendedPosiTypeList
).
filter
(
subVal
=>
(
val
?.
upgradeGoods
?.
position
?.
split
(
','
))?.
includes
(
subVal
.
position
+
''
))
||
[]
const
positionNamesArr
=
deepClone
(
this
.
positionTypeList
.
concat
(
this
.
extendedPosiTypeList
)
).
filter
(
subVal
=>
(
val
?.
upgradeGoods
?.
position
?.
split
(
','
))?.
includes
(
subVal
.
position
+
''
))
||
[]
res
.
groundingGoodsList
.
push
({
goodsType
:
val
?.
goodsType
,
// 类目值
upgradeGoodsId
:
val
?.
upgradeGoodsId
,
// 升级商品Id
upgradeGoodsName
:
val
?.
upgradeGoodsName
,
// 升级商品名称
goodsAlias
:
val
?.
goodsAlias
,
// 商品别名
goodsAlias
:
val
?.
goodsAlias
||
'-'
,
// 商品别名
goodsTypeName
:
val
?.
goodsTypeName
,
// 升级商品所属类目
upgradePrice
:
val
?.
upgradePrice
,
// 参考售价
positionStr
:
deepClone
(
this
.
extendedPosiTypeList
)?.
filter
(
subVal
=>
val
?.
position
==
subVal
.
position
)[
0
]?.
confName
||
''
,
// 上架部位
positionStr
:
deepClone
(
this
.
positionTypeList
.
concat
(
this
.
extendedPosiTypeList
)
)?.
filter
(
subVal
=>
val
?.
position
==
subVal
.
position
)[
0
]?.
confName
||
''
,
// 上架部位
positionNames
:
positionNamesArr
.
length
?
positionNamesArr
.
map
(
subItem
=>
{
return
subItem
?.
confName
}).
join
(
'/'
)
:
''
,
// 部位名称
positionNamesArr
:
positionNamesArr
,
// 多部位数组
purchasePrice
:
val
?.
upgradeGoods
?.
purchasePrice
,
// 采购价
...
...
@@ -190,7 +172,13 @@ export default {
validMinSellPrice
:
val
?.
validMinSellPrice
,
// 是否校验最低价
djCost
:
val
?.
djCost
,
// 嘀加成本
thirdPartyCost
:
val
?.
thirdPartyCost
,
// 第三方成本
supplierCode
:
val
?.
goodsInfo
?.
supplierCode
// 供应方
supplierCode
:
val
?.
goodsInfo
?.
supplierCode
,
// 供应方
warrantyTypeStr
:
this
.
warrantyTypeShow
[
val
?.
warrantyType
]
||
'-'
,
// 质保卡类型
upgradeSupplyMode
:
val
?.
upgradeSupplyMode
,
upgradeSupplyModeStr
:
arr
?.
filter
(
v
=>
v
.
confId
==
val
.
upgradeSupplyMode
)[
0
]?.
confName
||
''
,
// 升级产品供货模式
upgradeProductCost
:
val
?.
upgradeProductCost
,
// 升级产品成本
virtualAccountCost
:
val
?.
virtualAccountCost
,
// 虚拟对账成本
recoveryCost
:
val
?.
recoveryCost
// 回收成本
})
})
res
.
sceneName
=
sceneList
[
res
.
sceneType
]
||
'-'
...
...
src/views/goods/productManage/components/multipleSpecificationForm.vue
View file @
e4258f7
...
...
@@ -418,6 +418,7 @@
</td>
<td
style=
"width: 60px;"
>
<el-button
type=
"text"
:disabled=
"subItem.merchantGoodsInfos && subItem.merchantGoodsInfos.length > 0"
@
click=
"delspecificationValueList(subIndex)"
>
删除
</el-button>
</td>
...
...
src/views/goods/productManage/components/singleSpecificationForm.vue
View file @
e4258f7
...
...
@@ -314,7 +314,9 @@
</div>
</td>
<td
style=
"width: 60px;"
>
<!-- SPU状态是草稿/SKU上架为待审核状态/SKU是待上架状态 -->
<el-button
type=
"text"
:disabled=
"subItem.merchantGoodsInfos && subItem.merchantGoodsInfos.length > 0"
@
click=
"delgoodsSpecificationSingleList(subIndex)"
>
删除
</el-button>
</td>
...
...
@@ -475,6 +477,7 @@ export default {
this
.
maxPrice
=
priceArr
.
length
?
Math
.
max
(...
priceArr
)
:
0
this
.
getBaseData
()
this
.
computedTableWidth
(
this
.
goodsInfoData
?.
goodsType
)
console
.
log
(
this
.
goodsInfoData
.
goodsSpecificationSingleList
)
},
methods
:
{
...
mapMutations
(
'goodsInfoData'
,
[
'setUpdateGoodsInfo'
]),
...
...
src/views/goods/productManage/update.vue
View file @
e4258f7
...
...
@@ -144,6 +144,7 @@ export default {
entityCardFlag
:
val
.
entityCardFlag
==
'Y'
,
minSuitCarPrice
:
val
.
minSuitCarPrice
,
maxSuitCarPrice
:
val
.
maxSuitCarPrice
,
merchantGoodsInfos
:
val
?.
merchantGoodsInfos
,
// 编辑产品价格输入框限制
oldpurchasePrice
:
val
.
purchasePrice
,
oldupgradePrice
:
val
.
upgradePrice
,
...
...
@@ -180,7 +181,8 @@ export default {
goodsName
:
res
.
goodsInfo
.
goodsName
,
applicableModelNames
:
res
.
goodsInfo
?.
goodsType
==
1
?
deepClone
(
applicableModelTypeList
).
filter
(
val
=>
res
.
goodsInfo
?.
carTypeList
?.
indexOf
(
val
.
confId
)
>
-
1
).
map
(
item
=>
item
.
confName
).
join
(
'/'
)
:
''
,
positionNames
:
res
.
goodsInfo
?.
goodsType
==
1
?
deepClone
(
this
.
positionTypeList
).
filter
(
val
=>
selectedPositions
.
indexOf
(
val
.
position
)
>
-
1
).
map
(
item
=>
item
.
confName
).
join
(
'/'
)
:
''
,
supplierCode
:
res
.
goodsInfo
.
supplierCode
supplierCode
:
res
.
goodsInfo
.
supplierCode
,
merchantGoodsInfos
:
res
?.
merchantGoodsInfos
}
this
.
productFormData
=
deepClone
({
...
res
.
goodsInfo
,
status
:
res
?.
status
,
oldconvertedValue
:
res
.
goodsInfo
?.
convertedValue
})
||
{}
this
.
setUpdateGoodsInfo
(
objData
)
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment