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 20453ec8
authored
May 20, 2026
by
zhangxw
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
产品供应商由SPU改为SKU维度需求开发
1 parent
29d51a8a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
50 additions
and
71 deletions
src/views/goods/productManage/components/productManage/SupplierSelect.vue
src/views/goods/productManage/components/productManage/drawerDetail.vue
src/views/goods/productManage/components/productManage/drawerSkuDetail.vue
src/views/goods/productManage/components/productManage/drawerUpdate.vue
src/views/goods/productManage/components/productManage/multipleSpecificationForm.vue
src/views/goods/productManage/components/productManage/productForm.vue
src/views/goods/productManage/components/productManage/singleSpecificationForm.vue
src/views/goods/productManage/components/productManage/sourceMaterial.vue
src/views/goods/productManage/components/productManage/SupplierSelect.vue
0 → 100644
View file @
20453ec
This diff is collapsed.
Click to expand it.
src/views/goods/productManage/components/productManage/drawerDetail.vue
View file @
20453ec
...
...
@@ -41,10 +41,6 @@
<span
class=
"label"
>
配件性质:
</span>
<span
class=
"value"
>
{{ formatAccessoryType($$(commodityInfo.goodsInfo, 'accessoryType')) }}
</span>
</p>
<p
class=
"item_class"
>
<span
class=
"label"
>
供应商:
</span>
<EllipsisPopover
class=
"value"
:content=
"$$(commodityInfo.goodsInfo, 'providerName') || '-'"
></EllipsisPopover>
</p>
<p
class=
"item_class"
>
<span
class=
"label"
>
供应方:
</span>
<span
class=
"value"
>
{{ $$(commodityInfo.goodsInfo, 'supplierName') || '-' }}
</span>
...
...
@@ -78,6 +74,9 @@
<el-form-item
class=
"d2-drawer-item"
label=
"运营成本/元:"
>
<EllipsisPopover
:content=
"!filterEmpty(item.operationCost) ? priceFilter(item.operationCost) : '-'"
></EllipsisPopover>
</el-form-item>
<el-form-item
class=
"d2-drawer-item"
label=
"供应商:"
>
<EllipsisPopover
:content=
"item.providerName || '-'"
></EllipsisPopover>
</el-form-item>
</div>
</el-form>
<!-- 分页 -->
...
...
src/views/goods/productManage/components/productManage/drawerSkuDetail.vue
View file @
20453ec
...
...
@@ -37,10 +37,6 @@
<span
class=
"label"
>
配件性质:
</span>
<span
class=
"value"
>
{{
formatAccessoryType
(
$$
(
commodityInfo
.
goodsInfo
,
"accessoryType"
))
}}
</span>
</p>
<p
class=
"item_class"
>
<span
class=
"label"
>
供应商:
</span>
<EllipsisPopover
class=
"value"
:content=
"$$(commodityInfo.goodsInfo, 'providerName') || '-'"
></EllipsisPopover>
</p>
<p
class=
"item_class"
>
<span
class=
"label"
>
供应方:
</span>
<span
class=
"value"
>
{{
$$
(
commodityInfo
.
goodsInfo
,
"supplierName"
)
||
"-"
}}
</span>
...
...
@@ -88,6 +84,9 @@
<el-form-item
class=
"d2-drawer-item"
label=
"运营成本/元:"
>
<EllipsisPopover
:content=
"!filterEmpty(item.operationCost) ? priceFilter(item.operationCost) : '-'"
></EllipsisPopover>
</el-form-item>
<el-form-item
class=
"d2-drawer-item"
label=
"供应商:"
>
<EllipsisPopover
:content=
"item.providerName || '-'"
></EllipsisPopover>
</el-form-item>
</div>
</el-form>
</div>
...
...
src/views/goods/productManage/components/productManage/drawerUpdate.vue
View file @
20453ec
...
...
@@ -168,7 +168,8 @@ export default {
specsValueList
:
val
.
specificationData
?.
split
(
';~;'
),
type
:
val
.
type
,
thirdPartyName
:
val
.
thirdPartyName
,
thirdPartyCode
:
val
.
thirdPartyCode
,
thirdPartyCode
:
val
.
thirdPartyCode
,
providerIds
:
val
.
providerIds
||
[],
priceUnitType
,
priceUnitName
,
purchaseCost
:
val
.
purchaseCost
,
...
...
@@ -254,8 +255,7 @@ export default {
supplierCode
:
res
.
goodsInfo
.
supplierCode
,
merchantGoodsInfos
:
res
?.
merchantGoodsInfos
,
scrmFlag
:
res
?.
goodsInfo
?.
scrmFlag
,
accessoryType
:
res
.
goodsInfo
?.
accessoryType
,
providerId
:
res
.
goodsInfo
?.
providerId
accessoryType
:
res
.
goodsInfo
?.
accessoryType
}
this
.
productFormData
=
deepClone
({
...
res
.
goodsInfo
,
status
:
res
?.
status
,
oldconvertedValue
:
res
.
goodsInfo
?.
convertedValue
,
tempGoodsType
,
secondaryGoodsType
:
res
.
goodsInfo
.
secondaryGoodsType
,
thirdLevelGoodsType
:
res
.
goodsInfo
.
thirdLevelGoodsType
})
||
{}
this
.
setUpdateGoodsInfo
(
objData
)
...
...
@@ -345,7 +345,8 @@ export default {
warrantyPeriod
:
this
.
membraneTypeList
.
includes
(
productFormData
?.
goodsType
)
||
!
isEquityOrExtend
?
warrantyVal
:
''
,
// 质保时间 膜类或非权益/延保类
type
:
item
.
type
,
thirdPartyName
:
item
.
thirdPartyName
,
thirdPartyCode
:
item
.
thirdPartyCode
,
thirdPartyCode
:
item
.
thirdPartyCode
,
providerIds
:
item
.
providerIds
||
[],
priceUnitType
:
item
.
priceUnitType
,
priceUnitName
:
item
.
priceUnitName
,
productTemplateId
:
item
?.
productTemplateId
,
...
...
@@ -419,7 +420,8 @@ export default {
warrantyPeriod
:
this
.
membraneTypeList
.
includes
(
productFormData
?.
goodsType
)
||
!
isEquityOrExtend
?
warrantyVal
:
''
,
// 质保时间 膜类或非权益/延保类
type
:
item
.
type
,
thirdPartyName
:
item
.
thirdPartyName
,
thirdPartyCode
:
item
.
thirdPartyCode
,
thirdPartyCode
:
item
.
thirdPartyCode
,
providerIds
:
item
.
providerIds
||
[],
priceUnitType
:
item
.
priceUnitType
,
priceUnitName
:
item
.
priceUnitName
,
purchaseCost
:
item
.
purchaseCost
,
...
...
@@ -528,7 +530,8 @@ export default {
specsValueList
:
specName
?
`
${
specName
}
`
.
split
(
';~;'
)
:
[],
type
,
thirdPartyName
:
''
,
thirdPartyCode
:
''
,
thirdPartyCode
:
''
,
providerIds
:
[],
priceUnitType
:
''
,
priceUnitName
:
''
,
purchaseCost
:
''
,
...
...
@@ -624,6 +627,7 @@ export default {
item
.
operationCostEmpty
=
true
// 运营成本必填
item
.
applicableAreaEmpty
=
true
// 适用区域必填
item
.
purchaseCostEmpty
=
true
// 采购成本必填
item
.
providerIdsEmpty
=
true
// 供应商必填
if
(
this
.
equitySceneType
.
includes
(
this
.
goodsInfoData
.
goodsType
)
&&
!
this
.
baseConfig
.
supplierCode
.
includes
(
`
${
this
.
goodsInfoData
.
supplierCode
}
`
))
{
// 会员权益升级类目(仅供应方是非第三方) 服务项目、嘀加成本必填
item
.
serviceItemArrEmpty
=
true
...
...
@@ -644,7 +648,7 @@ export default {
}
let
specialList
=
[]
// 1. 基础必填字段 产品编码、采购成本、运营系数、运营成本、适用区域
const
baseFields
=
[
'specificationData'
,
'type'
,
'purchaseCost'
,
'operationCoefficient'
,
'operationCost'
,
'upgradeGoodsAreaList'
]
const
baseFields
=
[
'specificationData'
,
'type'
,
'p
roviderIds'
,
'p
urchaseCost'
,
'operationCoefficient'
,
'operationCost'
,
'upgradeGoodsAreaList'
]
const
{
goodsType
,
supplierCode
}
=
this
.
goodsInfoData
// 2. 权益/延保类
if
(
isEquityOrExtend
)
{
...
...
src/views/goods/productManage/components/productManage/multipleSpecificationForm.vue
View file @
20453ec
...
...
@@ -109,6 +109,11 @@
<span>
供应来源
</span>
<div
class=
"resize-handle"
@
mousedown=
"onResizeStart"
></div>
</td>
<td
style=
"position: relative"
>
<span
class=
"color-red"
>
*
</span>
<span>
供应商
</span>
<div
class=
"resize-handle"
@
mousedown=
"onResizeStart"
></div>
</td>
<!-- 仅延保类/权益服务 广联直营展示 -->
<td
v-if=
"(extendedPosiType.includes(goodsInfoData.goodsType) || equitySceneType.includes(goodsInfoData.goodsType)) && !baseConfig.supplierCode.includes(`${goodsInfoData.supplierCode}`)"
style=
"position: relative"
>
<span
class=
"color-red"
>
*
</span>
...
...
@@ -215,6 +220,12 @@
<el-option
v-for=
"opt in supplySourceOptions"
:key=
"opt.value"
:label=
"opt.label"
:value=
"opt.value"
/>
</el-select>
</td>
<td>
<SupplierSelect
v-model=
"row.item.providerIds"
:custom-class=
"!row.item.providerIds.length && row.item.providerIdsEmpty ? 'border-red' : ''"
width=
"calc(100% - 40px)"
/>
</td>
<td
v-if=
"(extendedPosiType.includes(goodsInfoData.goodsType) || equitySceneType.includes(goodsInfoData.goodsType)) && !baseConfig.supplierCode.includes(`${goodsInfoData.supplierCode}`)"
>
<div
style=
"transform: translateX(6px)"
>
<el-input
v-model=
"row.item.djCost"
class=
"w-150-per"
:class=
"{ 'border-red': filterEmpty(row.item.djCost) && row.item.djCostEmpty }"
:disabled=
"true"
placeholder=
"请输入"
size=
"small"
@
input=
"handlePrice($event, row.originalIndex, 'djCost')"
></el-input>
...
...
@@ -368,7 +379,7 @@ import carSeriesDialog from './carSeriesDialog.vue'
import
extendServiceItemsDialog
from
'./extendServiceItemsDialog.vue'
import
serviceItemsDialog
from
'./serviceItemsDialog.vue'
import
specsManage
from
'./specsManage.vue'
import
SupplierSelect
from
'./SupplierSelect.vue'
export
default
{
name
:
'MultipleSpecificationForm'
,
components
:
{
...
...
@@ -377,7 +388,8 @@ export default {
CarSeriesDialog
:
carSeriesDialog
,
SpecsManage
:
specsManage
,
// ApplicableAreaSelect,
ApplicableAreaQuerySelect
ApplicableAreaQuerySelect
,
SupplierSelect
},
mixins
:
[
useTableVirtualScroll
,
useResizableColumns
],
inject
:
[
'pageData'
],
...
...
@@ -1272,7 +1284,8 @@ export default {
specsValueList: [this.goodsInfoData.specificationDetailList[i]?.specificationValueList[j]?.specificationValue],
type: '',
thirdPartyName: '',
thirdPartyCode: '',
thirdPartyCode: '',
providerIds: [],
priceUnitType: null,
priceUnitName: '',
purchaseCost: '',
...
...
@@ -1330,7 +1343,8 @@ export default {
item.oldwarningValueMax = temp.warningValueMax
item.type = temp.type
item.thirdPartyName = temp.thirdPartyName
item.thirdPartyCode = temp.thirdPartyCode
item.thirdPartyCode = temp.thirdPartyCode
item.providerIds = temp.providerIds || []
item.priceUnitType = temp.priceUnitType
item.priceUnitName = temp.priceUnitName
item.purchaseCost = temp.purchaseCost
...
...
src/views/goods/productManage/components/productManage/productForm.vue
View file @
20453ec
This diff is collapsed.
Click to expand it.
src/views/goods/productManage/components/productManage/singleSpecificationForm.vue
View file @
20453ec
...
...
@@ -35,7 +35,6 @@
<span>
供应商编码
</span>
<div
class=
"resize-handle"
@
mousedown=
"onResizeStart"
></div>
</td>
<!-- 轻改/延保展示,延保不必填 -->
<td
style=
"position: relative"
>
<span
v-if=
"!isEquityOrExtendType"
class=
"color-red"
>
*
</span>
<span>
计价单位
</span>
...
...
@@ -89,6 +88,11 @@
<span>
供应来源
</span>
<div
class=
"resize-handle"
@
mousedown=
"onResizeStart"
></div>
</td>
<td
style=
"position: relative"
>
<span
class=
"color-red"
>
*
</span>
<span>
供应商
</span>
<div
class=
"resize-handle"
@
mousedown=
"onResizeStart"
></div>
</td>
<!-- 延保/权益 非第三方展示 -->
<td
v-if=
"(extendedPosiType.includes(goodsInfoData.goodsType) || equitySceneType.includes(goodsInfoData.goodsType)) && !baseConfig.supplierCode.includes(`$
{goodsInfoData.supplierCode}`)" style="position: relative">
<span
class=
"color-red"
>
*
</span>
...
...
@@ -317,7 +321,12 @@
:value=
"opt.value"
/>
</el-select>
</td>
<td>
<SupplierSelect
v-model=
"row.item.providerIds"
:custom-class=
"!row.item.providerIds.length && row.item.providerIdsEmpty ? 'border-red' : ''"
width=
"calc(100% - 40px)"
/>
</td>
<td
v-if=
"(extendedPosiType.includes(goodsInfoData.goodsType) || equitySceneType.includes(goodsInfoData.goodsType)) && !baseConfig.supplierCode.includes(`$
{goodsInfoData.supplierCode}`)">
<el-input
v-model=
"row.item.djCost"
class=
"w-150-per"
...
...
@@ -542,7 +551,7 @@ import useTableVirtualScroll from "@/views/goods/productManage/mixins/useTableVi
import
carSeriesDialog
from
"./carSeriesDialog.vue"
;
import
extendServiceItemsDialog
from
"./extendServiceItemsDialog.vue"
;
import
serviceItemsDialog
from
"./serviceItemsDialog.vue"
;
import
SupplierSelect
from
'./SupplierSelect.vue'
export
default
{
name
:
"SingleSpecificationForm"
,
components
:
{
...
...
@@ -551,6 +560,7 @@ export default {
CarSeriesDialog
:
carSeriesDialog
,
// ApplicableAreaSelect,
ApplicableAreaQuerySelect
,
SupplierSelect
},
mixins
:
[
useTableVirtualScroll
,
useResizableColumns
],
props
:
{
...
...
@@ -1083,6 +1093,7 @@ export default {
type: "",
thirdPartyName: "",
thirdPartyCode: "",
providerIds: [],
priceUnitType: null,
priceUnitName: "",
purchaseCost: "",
...
...
src/views/goods/productManage/components/productManage/sourceMaterial.vue
View file @
20453ec
...
...
@@ -13,15 +13,12 @@
:origin-data=
"editData"
@
accessoryTypeChange=
"handleAccessoryTypeChange"
@
handleAddBrandSupplyConfirm=
"handleAddBrandSupplyConfirm"
@
handleEditBrandSupplyConfirm=
"handleEditBrandSupplyConfirm"
@
handleAddSupplierConfirm=
"handleAddSupplierConfirm"
@
handleEditSupplierConfirm=
"handleEditSupplierConfirm"
>
@
handleEditBrandSupplyConfirm=
"handleEditBrandSupplyConfirm"
>
</ProductForm>
</div>
</
template
>
<
script
>
import
{
addGoodsProvider
,
editGoodsProvider
,
getGoodsProviderList
}
from
"@api/productManage"
;
import
{
mapActions
}
from
"vuex"
;
import
{
addBrandSupplyMerchant
,
editBrandSupplyMerchant
,
getAllCategory
,
getBrandSupplyMerchant
}
from
"@/api/product"
;
import
{
deepClone
}
from
"@/common/util"
;
...
...
@@ -53,8 +50,6 @@ export default {
brandMerchantName
:
""
,
supplierCode
:
""
,
supplierName
:
""
,
providerId
:
""
,
providerName
:
""
,
address
:
""
,
contactName
:
""
,
contactPhone
:
""
,
...
...
@@ -123,19 +118,6 @@ export default {
isDisabled
:
false
,
},
{
name
:
"providerId"
,
label
:
"供应商"
,
isRequired
:
true
,
type
:
"dialog-add-select"
,
multiple
:
false
,
isClear
:
true
,
optionList
:
[],
optionId
:
"id"
,
optionLabel
:
"providerName"
,
width
:
"432px"
,
isDisabled
:
false
,
},
{
name
:
"thumbUrl"
,
label
:
"缩略图"
,
type
:
"photo"
,
...
...
@@ -210,8 +192,6 @@ export default {
this
.
getBrandSupplyList
(
2
);
// 获取类目
this
.
getGoodTypeList
();
// 获取供应商
this
.
getGoodsProvider
();
},
methods
:
{
...
mapActions
({
...
...
@@ -309,34 +289,6 @@ export default {
this.getBrandSupplyList(data.partitionFlag);
});
},
// 获取供应商
getGoodsProvider() {
return getGoodsProviderList({ currentPage: 1, pageSize: 9999 }).then((res) => {
this.editForm[0].formBlock[this.editForm[0].formBlock.findIndex(val => val.name == "providerId")].optionList = res?.list || [];
return res?.list || [];
});
},
// 新增供应商
handleAddSupplierConfirm(data, done) {
const supplierIndex = this.editForm[0]?.formBlock.findIndex(val => val.name === "providerId");
if (supplierIndex === -1)
return;
addGoodsProvider(data).then((res) => {
this.getGoodsProvider().then(() => {
done && done(res);
});
});
},
// 编辑供应商
handleEditSupplierConfirm(data, done) {
const supplierIndex = this.editForm[0]?.formBlock.findIndex(val => val.name === "providerId");
if (supplierIndex === -1)
return;
editGoodsProvider(data).then((res) => {
this.getGoodsProvider();
done && done(res);
});
},
handleAccessoryTypeChange(val) {
this.$emit("accessoryTypeChange", val);
},
...
...
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