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
398fc1be
Commit
398fc1be
authored
Jun 16, 2022
by
crushh
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/游戏营销' into master
parents
71b2cd8f
b3a4b2f7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
17 deletions
+19
-17
base-config.vue
src/views/game/cmh/base-config.vue
+4
-2
rule-config.vue
src/views/game/cmh/rule-config.vue
+15
-15
No files found.
src/views/game/cmh/base-config.vue
View file @
398fc1be
...
...
@@ -3,7 +3,7 @@
<dm-sub-title
type=
"line"
>
基本信息
</dm-sub-title>
<div
class=
"mt20"
>
<el-form-item
label=
"游戏名称"
prop=
"gameName"
>
<el-input
maxlength=
"10"
class=
"w382"
@
change=
"handleNameChange"
v-model
.
trim=
"baseForm.gameName"
show-word-limit
:disabled=
"isDisabled"
placeholder=
"请输入游戏名称"
/>
</el-form-item>
<el-form-item
label=
"游戏时间"
prop=
"gameTime"
><el-date-picker
class=
"w382"
v-model=
"baseForm.gameTime"
:disabled=
"isDisabled"
:picker-options=
"pickerOptions"
value-format=
"timestamp"
@
change=
"handleDateChange"
type=
"daterange"
range-separator=
"~"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
>
</el-date-picker></el-form-item>
<el-form-item
label=
"游戏时间"
prop=
"gameTime"
><el-date-picker
class=
"w382"
v-model=
"baseForm.gameTime"
:disabled=
"isDisabled"
:picker-options=
"pickerOptions"
value-format=
"timestamp"
@
change=
"handleDateChange
(val, 'gameTime')
"
type=
"daterange"
range-separator=
"~"
start-placeholder=
"开始日期"
end-placeholder=
"结束日期"
>
</el-date-picker></el-form-item>
<el-form-item
label=
"游戏说明"
prop=
"gameRule"
>
<el-input
maxlength=
"500"
class=
"w382"
v-model=
"baseForm.gameRule"
show-word-limit
:autosize=
"
{ minRows: 4 }" type="textarea" />
</el-form-item>
</div>
<dm-sub-title
type=
"line"
>
展示信息配置
</dm-sub-title>
...
...
@@ -253,7 +253,7 @@ export default {
handleDateChange
(
val
,
type
)
{
console
.
log
(
val
,
type
);
this
.
$emit
(
'change'
,
this
.
baseForm
);
if
(
type
)
{
if
(
type
==
'adsFlag'
)
{
this
.
$nextTick
(
_
=>
{
const
adsImg
=
document
.
getElementsByClassName
(
'adsImg'
);
adsImg
[
0
].
scrollIntoView
({
...
...
@@ -264,6 +264,8 @@ export default {
behavior
:
'smooth'
});
});
}
else
if
(
type
==
'gameTime'
&&
this
.
baseForm
.
gameTime
&&
this
.
baseForm
.
gameTime
.
length
)
{
this
.
baseForm
.
gameTime
[
1
]
=
this
.
baseForm
.
gameTime
[
1
]
+
86399000
;
}
},
handleTemplateChange
(
val
)
{
...
...
src/views/game/cmh/rule-config.vue
View file @
398fc1be
...
...
@@ -182,7 +182,7 @@ export default {
memberDesc
:
''
,
playConditionFlag
:
1
,
shareFlag
:
0
,
playTimes
:
1000
,
playTimes
:
''
,
filterJsonView
:
''
,
shareImageUrl
:
''
,
memberWeightView
:
{
searchId
:
''
},
...
...
@@ -299,10 +299,9 @@ export default {
console
.
log
(
this
.
ruleForm
);
},
gameTime
(
val
)
{
if
(
val
.
length
)
{
console
.
log
(
val
[
1
]
-
val
[
0
]);
console
.
log
((
val
[
1
]
-
val
[
0
])
/
(
24
*
60
*
60
*
1000
)
+
1
);
this
.
gameDays
=
(
val
[
1
]
-
val
[
0
])
/
(
24
*
60
*
60
*
1000
)
+
1
;
if
(
val
&&
val
.
length
)
{
this
.
gameDays
=
(
val
[
1
]
-
val
[
0
])
/
(
24
*
60
*
60
*
1000
);
console
.
log
(
this
.
gameDays
);
this
.
gameDays
=
this
.
gameDays
.
toFixed
();
}
}
...
...
@@ -406,6 +405,16 @@ export default {
this
.
$refs
.
ruleForm
.
clearValidate
(
name
);
},
validateData
()
{
this
.
$refs
.
ruleForm
.
validate
(
val
=>
{
this
.
boolVal
=
val
;
if
(
!
val
)
{
this
.
scrollToError
(
this
);
}
});
if
(
!
this
.
boolVal
)
{
this
.
$message
.
error
(
'请确认规则设置的必填字段都已填写且通过校验'
);
return
false
;
}
if
(
this
.
ruleForm
.
memberType
==
0
&&
this
.
toggleTag
&&
!
this
.
ruleForm
.
filterJsonView
)
{
this
.
$message
.
error
(
'人群筛选未保存条件'
);
return
false
;
...
...
@@ -422,16 +431,7 @@ export default {
return
false
;
}
}
this
.
$refs
.
ruleForm
.
validate
(
val
=>
{
this
.
boolVal
=
val
;
if
(
!
val
)
{
this
.
scrollToError
(
this
);
}
});
if
(
!
this
.
boolVal
)
{
this
.
$message
.
error
(
'请确认规则设置的必填字段都已填写且通过校验'
);
return
false
;
}
return
true
;
},
nextStep
(
noNext
)
{
...
...
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