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
6e881d59
Commit
6e881d59
authored
Mar 31, 2021
by
caoyanzhi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update: 弹窗调整
parent
e7a177ba
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
19 deletions
+22
-19
form.vue
src/views/pop/form.vue
+9
-10
list.vue
src/views/pop/list.vue
+13
-9
No files found.
src/views/pop/form.vue
View file @
6e881d59
...
...
@@ -155,7 +155,7 @@
<i
class=
"iconfont icon-jia"
></i>
<p>
还可添加{{ surplus }}个弹窗
</p>
</div>
<el-button
@
click=
"submit"
>
确认新建
</el-button>
<el-button
@
click=
"submit"
>
{{ group.id ? '保持' : '确认新建' }}
</el-button>
</el-form>
</div>
</section>
...
...
@@ -197,12 +197,12 @@ const defaultPop = {
],
// 投放的会员分组
popupMemberGroupList
:
[
{
// 会员分组id
memberTagGroupId
:
''
,
// 会员分组名称
groupName
:
''
}
//
{
//
// 会员分组id
//
memberTagGroupId: '',
//
// 会员分组名称
//
groupName: ''
//
}
],
linkToolsVisible
:
false
,
// 投放详情 - 图片
...
...
@@ -285,7 +285,6 @@ export default {
dateTime
:
[],
// 计划时间
popupList
:
[]
// 弹窗列表
},
defaultPop
:
Object
.
assign
({},
defaultPop
),
rules
:
{
name
:
[{
required
:
true
,
message
:
'请输入计划名称'
,
trigger
:
'change'
}],
dateTime
:
[{
required
:
true
,
validator
:
validateDateLessYear
,
trigger
:
'change'
}]
...
...
@@ -496,9 +495,9 @@ export default {
// let sortNum = 0;
for
(
const
key
in
this
.
popSort
)
{
if
(
!
this
.
popSort
[
key
])
{
// this.defaultPop.sortNum = key
;
const
pop
=
JSON
.
parse
(
JSON
.
stringify
(
defaultPop
))
;
this
.
popSort
[
`
${
key
}
`
]
=
true
;
this
.
group
.
popupList
.
push
(
Object
.
assign
({},
defaultP
op
,
{
sortNum
:
key
,
fileList
:
[]
}));
this
.
group
.
popupList
.
push
(
Object
.
assign
({},
p
op
,
{
sortNum
:
key
,
fileList
:
[]
}));
return
;
}
}
...
...
src/views/pop/list.vue
View file @
6e881d59
...
...
@@ -61,12 +61,12 @@
<el-table-column
label=
"操作"
align=
"left"
width=
"170"
>
<
template
slot-scope=
"scope"
>
<el-button
v-if=
"scope.row.activeStatus === 2 || scope.row.activeStatus === 3"
type=
"text"
@
click=
"goForm(group, 'edit')"
>
查看
</el-button>
<dm-delete
v-if=
"scope.row.activeStatus === 2"
@
confirm=
"
delData
(scope.row)"
tips=
"是否停止该条数据?"
>
<dm-delete
v-if=
"scope.row.activeStatus === 2"
@
confirm=
"
stopPop
(scope.row)"
tips=
"是否停止该条数据?"
>
<el-button
type=
"text"
>
停止
</el-button>
</dm-delete>
<el-button
v-if=
"scope.row.activeStatus === 1"
type=
"text"
@
click=
"goForm(group, 'edit')"
>
编辑
</el-button>
<dm-delete
v-if=
"scope.row.activeStatus === 1 || scope.row.activeStatus === 3"
@
confirm=
"
delData
(scope.row)"
tips=
"是否删除该条数据?"
>
<el-button
type=
"text"
@
click=
"removePop(scope.row.popupId)"
>
删除
</el-button>
<dm-delete
v-if=
"scope.row.activeStatus === 1 || scope.row.activeStatus === 3"
@
confirm=
"
removePop
(scope.row)"
tips=
"是否删除该条数据?"
>
<el-button
type=
"text"
>
删除
</el-button>
</dm-delete>
</
template
>
</el-table-column>
...
...
@@ -173,13 +173,17 @@ export default {
this
.
$router
.
push
(
`/pop/edit?id=
${
group
.
id
}
`
);
}
},
async
removePop
(
popupId
)
{
const
res
=
await
removePopup
({
popupId
});
console
.
log
(
res
);
removePop
(
pop
)
{
removePopup
({
popupId
:
pop
.
id
}).
then
(
res
=>
{
this
.
$message
.
success
(
'删除成功'
);
this
.
getTableList
();
});
},
async
stopPop
(
popupId
)
{
const
res
=
await
stopPopup
({
popupId
});
console
.
log
(
res
);
stopPop
(
pop
)
{
stopPopup
({
popupId
:
pop
.
id
}).
then
(
res
=>
{
this
.
$message
.
success
(
'弹窗计划已停止'
);
this
.
getTableList
();
});
}
}
};
...
...
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