Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
marketing
Overview
Overview
Details
Activity
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
marketing-web
marketing
Commits
5ec80d50
Commit
5ec80d50
authored
Nov 19, 2021
by
黑潮
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: link回显
parent
06b3152d
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
41 additions
and
42 deletions
+41
-42
ecmApi.js
src/service/api/ecmApi.js
+2
-0
form.js
src/views/card/form.js
+1
-1
item-wxa.vue
src/views/ecm/marketing-event/components/item-wxa.vue
+30
-37
lib-wxa.vue
src/views/ecm/marketing-event/components/lib-wxa.vue
+3
-1
index.vue
src/views/ecm/marketing-event/index.vue
+5
-3
No files found.
src/service/api/ecmApi.js
View file @
5ec80d50
...
...
@@ -79,3 +79,5 @@ export const getXsxsFalg = params => requests(PREFIX + 'get-xsxs-open-flag', par
export
const
getEcmLog
=
params
=>
requests
(
PREFIX
+
'get-ecm-operator_log'
,
params
);
export
const
getLinkResourceStatus
=
params
=>
requests
(
'api-admin/get-link-resource-status'
,
params
);
export
const
getLinkResourceStatusECM
=
params
=>
requests
(
'api-admin/get-link-resource-status-ecm'
,
params
);
src/views/card/form.js
View file @
5ec80d50
...
...
@@ -796,7 +796,7 @@ export default {
this
.
$nextTick
(()
=>
{
this
.
$refs
.
form
.
clearValidate
();
});
card
.
jumpFlag
==
1
&&
this
.
getLinkResourceStatus
(
card
.
jumpLink
);
!
this
.
isCopy
&&
card
.
jumpFlag
==
1
&&
this
.
getLinkResourceStatus
(
card
.
jumpLink
);
}
}
else
{
this
.
$tips
({
type
:
'error'
,
message
:
'初始化数据失败'
});
...
...
src/views/ecm/marketing-event/components/item-wxa.vue
View file @
5ec80d50
...
...
@@ -16,7 +16,7 @@
</
template
>
<
script
>
import
{
getLinkResourceStatus
}
from
'@/service/api/ecmApi.js'
;
import
{
getLinkResourceStatus
ECM
,
getLinkResourceStatus
}
from
'@/service/api/ecmApi.js'
;
export
default
{
name
:
'item-wxa'
,
data
()
{
...
...
@@ -35,48 +35,41 @@ export default {
}
}
},
watch
:
{
item
:
{
handler
()
{
this
.
statusText
=
''
;
},
immediate
:
true
}
},
mounted
()
{
this
.
getLinkResourceStatus
(
this
.
item
.
pagePath
);
},
methods
:
{
getLinkResourceStatus
(
v
)
{
let
result
=
JSON
.
parse
(
v
);
const
params
=
{
id
:
result
.
type
,
params
:
''
};
switch
(
result
.
type
)
{
case
'product_category_link'
:
case
'mall_customize_page'
:
case
'28'
:
case
28
:
case
'17'
:
case
17
:
case
'coup'
:
case
'gift'
:
result
.
params
&&
(
params
.
params
=
JSON
.
stringify
(
result
.
params
));
break
;
case
'yueshi-intergral_mall'
:
params
.
params
=
''
;
break
;
case
'35'
:
case
35
:
params
.
params
=
result
.
appid
;
break
;
case
'GAME_LINK_DZP'
:
case
'GAME_LINK_GGK'
:
case
'GAME_LINK_PTYX'
:
case
'GAME_LINK_KLFL'
:
case
'GAME_LINK_ZNM'
:
params
.
params
=
result
.
tagid
;
break
;
default
:
return
;
}
let
params
=
{};
const
statusMap
=
{
1
:
'已删除'
,
2
:
'已失效'
};
getLinkResourceStatus
(
params
).
then
(
res
=>
{
this
.
statusText
=
statusMap
[
res
.
result
]
||
''
;
});
const
result
=
JSON
.
parse
(
v
);
console
.
log
(
v
);
if
(
result
.
pageType
==
4
&&
result
.
type
&&
result
.
type
.
startsWith
(
'GAME_LINK'
))
{
params
=
{
id
:
result
.
type
,
params
:
result
.
tagid
};
getLinkResourceStatus
(
params
).
then
(
res
=>
{
this
.
statusText
=
statusMap
[
res
.
result
]
||
''
;
this
.
$emit
(
'set-status'
,
res
.
result
);
});
}
else
{
params
=
{
pagePath
:
v
};
getLinkResourceStatusECM
(
params
).
then
(
res
=>
{
this
.
statusText
=
statusMap
[
res
.
result
]
||
''
;
this
.
$emit
(
'set-status'
,
res
.
result
);
});
}
}
}
};
...
...
src/views/ecm/marketing-event/components/lib-wxa.vue
View file @
5ec80d50
...
...
@@ -62,7 +62,8 @@ export default {
default
()
{
return
{};
}
}
},
resourceStatus
:
Number
},
data
()
{
return
{
...
...
@@ -158,6 +159,7 @@ export default {
if
(
val
&&
this
.
item
.
ecmMarketingTypeRelationId
)
{
this
.
form
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
item
));
// console.log('编辑', this.item);
if
(
this
.
resourceStatus
!==
0
)
return
;
const
pagePath
=
this
.
form
.
pagePath
?
JSON
.
parse
(
this
.
form
.
pagePath
)
:
{};
this
.
wechatContent
.
type
=
pagePath
.
type
;
this
.
wechatContent
.
objId
=
''
;
...
...
src/views/ecm/marketing-event/index.vue
View file @
5ec80d50
...
...
@@ -15,7 +15,7 @@
<!-- 组件 区域 -->
<div
class=
"dm-marketing__content__item"
v-for=
"(v, i) in list"
:key=
"i"
>
<i
class=
"dm-marketing__content--index"
>
{{
i
+
1
}}
</i>
<component
:is=
"v.comName"
:item=
"v.item"
:isSupportVar=
"isSupportVar"
></component>
<component
:is=
"v.comName"
:item=
"v.item"
:isSupportVar=
"isSupportVar"
@
set-status=
"data => (v.resourceStatus = data)"
></component>
<template
v-if=
"!readOnly"
>
<i
class=
"el-icon-edit dm-marketing__opt--icon"
v-if=
"showEdit(v) && (v.comName === 'item-teltask' || v.comName === 'item-text' || v.comName === 'item-wxa' || v.comName === 'item-integral' || v.comName === 'item-qywx' || v.comName === 'item-qfxx')"
@
click=
"editItem(v)"
></i>
<i
v-else-if=
"v.comName == 'item-qywx' || v.comName == 'item-qfxx'"
class=
"el-icon-view dm-marketing__opt--icon"
@
click=
"editItem(v, true)"
></i>
...
...
@@ -34,7 +34,7 @@
</transition>
</div>
<!-- 弹窗组件 -->
<component
:is=
"dialogCom"
@
sendItem=
"saveToList"
:showOutCouponIcon=
"showOutCouponIcon"
:item=
"currentItem"
:show
.
sync=
"dialogShow"
:isSupportVar=
"isSupportVar"
:cardLimitType=
"cardLimitType"
:integralMultiple=
"integralMultiple"
:singleFlag=
"singleFlag"
:read-only=
"readOnly || showView"
></component>
<component
:is=
"dialogCom"
@
sendItem=
"saveToList"
:showOutCouponIcon=
"showOutCouponIcon"
:item=
"currentItem"
:show
.
sync=
"dialogShow"
:isSupportVar=
"isSupportVar"
:cardLimitType=
"cardLimitType"
:integralMultiple=
"integralMultiple"
:singleFlag=
"singleFlag"
:read-only=
"readOnly || showView"
:resource-status=
"resourceStatus"
></component>
</section>
</template>
...
...
@@ -165,7 +165,8 @@ export default {
maxEventCount
:
0
,
//item最大数
currentItem
:
{},
optShow
:
false
,
optTopShow
:
true
optTopShow
:
true
,
resourceStatus
:
0
};
},
created
()
{
...
...
@@ -500,6 +501,7 @@ export default {
},
// 编辑前置
editItem
(
obj
,
showView
)
{
this
.
resourceStatus
=
obj
.
resourceStatus
||
0
;
this
.
currentItem
=
obj
.
item
;
this
.
dialogCom
=
'lib-'
+
obj
.
comName
.
slice
(
5
);
this
.
$nextTick
(
_
=>
{
...
...
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