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 ff23d729
authored
May 09, 2023
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
字段取值修复
1 parent
9ff51c21
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
22 deletions
src/views/goods/grounding/editGrounding.vue
src/views/goods/grounding/editGrounding.vue
View file @
ff23d72
...
@@ -2,18 +2,10 @@
...
@@ -2,18 +2,10 @@
<
template
>
<
template
>
<d2-container
class=
"edit-commodity"
v-loading=
"!show"
>
<d2-container
class=
"edit-commodity"
v-loading=
"!show"
>
<div
class=
""
v-if=
"show"
>
<div
class=
""
v-if=
"show"
>
<grounding-form
<grounding-form
ref=
"d2GroundingForm"
:add-or-edit=
"addOrEdit"
:form-ref=
"proFormRef"
:origin-data=
"editData"
ref=
"d2GroundingForm"
:form-list=
"editForm"
:secondGoodsList=
"secondGoodsList"
@
handleAddConfirm=
"handleAddConfirm"
:add-or-edit=
"addOrEdit"
@
visibleChange=
"visibleChange"
@
interestsLoadmore=
"interestsLoadmore"
@
remoteMethod=
"remoteMethod"
:form-ref=
"proFormRef"
@
handleClose=
"handleAddClose"
></grounding-form>
:origin-data=
"editData"
:form-list=
"editForm"
:secondGoodsList=
"secondGoodsList"
@
handleAddConfirm=
"handleAddConfirm"
@
visibleChange=
"visibleChange"
@
interestsLoadmore=
"interestsLoadmore"
@
remoteMethod=
"remoteMethod"
@
handleClose=
"handleAddClose"
></grounding-form>
</div>
</div>
</d2-container>
</d2-container>
</
template
>
</
template
>
...
@@ -259,7 +251,7 @@ export default {
...
@@ -259,7 +251,7 @@ export default {
resArr
.
push
({
resArr
.
push
({
confId
:
v
.
id
,
confId
:
v
.
id
,
confNameValue
:
v
?.
upgradeGoodsName
,
confNameValue
:
v
?.
upgradeGoodsName
,
confTypeNameValue
:
`(
${
val
?.
goodsInfo
?.
goodsTypeName
}
/ ${val
?
.goodsInfo
?
.goodsName} /
$
{
v
?.
commodityCode
})
`,
confTypeNameValue
:
`(
${
val
?.
goodsInfo
?.
goodsTypeName
}
/ ${val
?
.goodsInfo
?
.goodsName} /
$
{
v
al
?.
commodityCode
})
`,
valueObj: {
valueObj: {
upgradeGoodsName: v?.upgradeGoodsName,
upgradeGoodsName: v?.upgradeGoodsName,
goodsName: val?.goodsInfo?.goodsName,
goodsName: val?.goodsInfo?.goodsName,
...
@@ -268,7 +260,7 @@ export default {
...
@@ -268,7 +260,7 @@ export default {
type: v?.type,
type: v?.type,
goodsType: val?.goodsInfo?.goodsType,
goodsType: val?.goodsInfo?.goodsType,
position: v?.position,
position: v?.position,
serviceItemNames: v?.upgradeGoodsServiceItemsList?.map(item => {
return item.serviceName
})?.join(',')
serviceItemNames: v?.upgradeGoodsServiceItemsList?.map(item => {
return item.serviceName
})?.join(',')
}
}
})
})
})
})
...
@@ -279,15 +271,15 @@ export default {
...
@@ -279,15 +271,15 @@ export default {
this.$nextTick(() => {
this.$nextTick(() => {
this.show = true
this.show = true
})
})
}).catch(() => {
}).catch(() => {
this.$nextTick(() => {
this.$nextTick(() => {
this.show = true
this.show = true
})
})
})
})
},
},
unique(arr){
unique(arr)
{
const res= new Map()
const res
= new Map()
return arr.filter((a)
=> !res.has(a.confId) && res.set(a.confId,
1))
return arr.filter((a)
=> !res.has(a.confId) && res.set(a.confId,
1))
},
},
getBaseData() {
getBaseData() {
this.editForm.forEach(item => {
this.editForm.forEach(item => {
...
@@ -318,7 +310,7 @@ export default {
...
@@ -318,7 +310,7 @@ export default {
confNameValue: res?.upgradeGoodsName,
confNameValue: res?.upgradeGoodsName,
confTypeNameValue: `
(
$
{
res
?.
goodsTypeName
}
/ ${res
?
.goodsName} /
$
{
v
?.
commodityCode
})
`,
confTypeNameValue: `
(
$
{
res
?.
goodsTypeName
}
/ ${res
?
.goodsName} /
$
{
v
?.
commodityCode
})
`,
}]
}]
res.serviceItemNames = res.upgradeGoods?.upgradeGoodsServiceItemsList?.map(v => {
return v.serviceName
})?.join(',')
res.serviceItemNames = res.upgradeGoods?.upgradeGoodsServiceItemsList?.map(v => {
return v.serviceName
})?.join(',')
this.editData = res || {}
this.editData = res || {}
this.getSelectingList(defaultSelect)
this.getSelectingList(defaultSelect)
})
})
...
@@ -378,9 +370,9 @@ export default {
...
@@ -378,9 +370,9 @@ export default {
var param = {}
var param = {}
if (obj === null || obj === undefined || obj === "") return param
if (obj === null || obj === undefined || obj === "") return param
for (var key in obj) {
for (var key in obj) {
if (obj[key] !== null && obj[key] !== undefined && obj[key] !== "") {
if (obj[key] !== null && obj[key] !== undefined && obj[key] !== "") {
param[key] = obj[key];
param[key] = obj[key];
}
}
}
}
return param
return param
},
},
...
...
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