Toggle navigation
Toggle navigation
This project
Loading...
Sign in
fe
/
yohobuy-portal-fe2
·
Commits
Go to a project
GitLab
Go to group
Project
Activity
Files
Commits
Pipelines
0
Builds
0
Graphs
Milestones
Issues
0
Merge Requests
0
Members
Labels
Wiki
Forks
Network
Create a new issue
Download as
Email Patches
Plain Diff
Browse Files
Authored by
xuhongyun
8 years ago
Commit
b72f5490ce5ad43bcc4aaccc23179e6fdacde9c6
1 parent
eaaa32f5
build
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
81 additions
and
1 deletions
dist/yohobuy-portal-fe/5.0.2/jquery/marketing.CouponList.Index.js
server/controllers/marketing.CouponList.js
server/interfaces/marketing.CouponList.js
server/views/marketing/CouponList/Index.html
dist/yohobuy-portal-fe/5.0.2/jquery/marketing.CouponList.Index.js
View file @
b72f549
...
...
@@ -443,6 +443,45 @@ webpackJsonp([75],[
}
});
// 更新微信卡券h5链接
$
(
document
).
on
(
'click'
,
'#updateh5-btn'
,
function
()
{
var
obj
=
{};
var
e
=
new
common
.
edit
(
"#h5LinkForm"
);
var
url
=
"/coupon/updateH5Link"
;
var
dialog
=
common
.
dialog
.
confirm
(
"更新微信卡券h5链接"
,
artTemplate
(
"h5Link-template"
,
obj
),
function
()
{
e
.
submit
(
url
,
function
(
option
)
{
console
.
log
(
option
.
data
);
option
.
success
=
function
(
res
)
{
if
(
res
.
code
==
200
)
{
common
.
util
.
__tip
(
'更新微信卡券h5链接成功!'
,
'success'
);
dialog
.
close
();
}
else
{
common
.
util
.
__tip
(
res
.
message
);
dialog
.
close
();
}
return
false
;
};
option
.
error
=
function
(){
common
.
util
.
__tip
(
'提交失败!'
,
'fail'
);
};
});
return
false
;
});
});
// 查看操作记录
$
(
document
).
on
(
'click'
,
'.operation-records'
,
function
()
{
var
couponId
=
$
(
this
).
data
(
'coupon-id'
);
...
...
server/controllers/marketing.CouponList.js
View file @
b72f549
...
...
@@ -60,6 +60,10 @@ module.exports = function (app) {
// 更新第三方信息
app
.
post
(
"/coupon/updateCouponsUseRule"
,
"CouponList_updateCouponsUseRule"
);
// 更新微信卡券H5链接
app
.
post
(
"/coupon/updateH5Link"
,
"CouponList_updateH5Link"
);
//清除指定商品
app
.
post
(
"/coupon/cleanPrdLimit"
,
"CouponList_cleanPrdLimit"
);
};
\ No newline at end of file
...
...
server/interfaces/marketing.CouponList.js
View file @
b72f549
...
...
@@ -99,6 +99,15 @@ module.exports = {
publicNumberType
:
{
type
:
Number
}
}
},
updateH5Link
:
{
title
:
"更新微信卡券H5链接"
,
url
:
"/coupon/updateH5Link"
,
params
:
{
h5Link
:
{
type
:
String
},
cardId
:
{
type
:
String
},
publicNumberCode
:
{
type
:
Number
}
}
},
cleanPrdLimit
:
{
title
:
"清除指定商品"
,
url
:
"/coupon/cleanPrdLimit"
,
...
...
server/views/marketing/CouponList/Index.html
View file @
b72f549
...
...
@@ -5,6 +5,7 @@
<div
class=
"panel panel-default"
style=
"margin-bottom:10px;"
>
<div
class=
"panel-body"
style=
"padding-bottom: 0"
>
<a
id=
"add-btn"
href=
"/market/couponList/add"
class=
"btn btn-success "
><i
class=
"fa fa-plus"
></i>
添加优惠券
</a>
<a
id=
"updateh5-btn"
href=
"javascript:;"
class=
"btn btn-success "
><i
class=
"fa fa-plus"
></i>
定制卡券h5链接
</a>
</div>
<div
class=
"panel-body"
>
<div
class=
"row"
>
...
...
@@ -321,13 +322,40 @@
<
label
class
=
"col-sm-2 control-label"
>
微信公众号
<
/label
>
<
div
class
=
"col-sm-8"
>
<
select
name
=
"publicNumberType"
id
=
"publicNumberType"
tabindex
=
"-1"
class
=
"form-control"
style
=
"width: 200px;"
>
<
option
value
=
"
0"
{{
if
publicNumberType
==
0
}}
selected
{{
/if}}>有货YOHOBUY 订阅号</
option
>
<
option
value
=
"
1"
{{
if
publicNumberType
==
1
}}
selected
{{
/if}}>有货YOHOBUY 订阅号</
option
>
<
option
value
=
"3"
{{
if
publicNumberType
==
3
}}
selected
{{
/if}}>有货潮流志微信 订阅号</
option
>
<
/select
>
<
/div
>
<
/div
>
<
/div
>
</script>
<script
id=
"h5Link-template"
type=
"text/template"
charset=
"utf-8"
>
<
div
class
=
"row"
id
=
"h5LinkForm"
>
<
div
class
=
"form-group"
>
<
label
class
=
"col-sm-2 control-label"
>
微信公众号
<
/label
>
<
div
class
=
"col-sm-8"
>
<
select
name
=
"publicNumberCode"
id
=
"publicNumberCode"
tabindex
=
"-1"
class
=
"form-control"
style
=
"width: 200px;"
>
<
option
value
=
"1"
{{
if
publicNumberCode
==
1
}}
selected
{{
/if}}>有货YOHOBUY 订阅号</
option
>
<
option
value
=
"3"
{{
if
publicNumberCode
==
3
}}
selected
{{
/if}}>有货潮流志微信 订阅号</
option
>
<
/select
>
<
/div
>
<
/div
>
<
div
class
=
"form-group"
>
<
label
class
=
"col-sm-2 control-label"
>
卡券
ID
<
/label
>
<
div
class
=
"col-sm-8"
>
<
input
id
=
"cardId"
class
=
"form-control panel-input"
value
=
"{{thirdId}}"
type
=
"text"
placeholder
=
"卡券ID"
>
<
/div
>
<
/div
>
<
div
class
=
"form-group"
>
<
label
class
=
"col-sm-2 control-label"
>
H5
链接
<
/label
>
<
div
class
=
"col-sm-8"
>
<
input
id
=
"h5Link"
class
=
"form-control panel-input"
value
=
"{{h5Link}}"
type
=
"text"
placeholder
=
"h5链接"
>
<
/div
>
<
/div
>
<
/div
>
</script>
<
%include '../../common/__ui/footer'%>
...
...
Please
register
or
login
to post a comment