Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eduline
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
冷斌
eduline
Commits
ee85e8cc
Commit
ee85e8cc
authored
May 18, 2020
by
陈超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
T
parent
6f90d52c
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
180 additions
and
139 deletions
+180
-139
addons/theme/stv1/_static_w3g/css/common.css
+17
-0
apps/course/Tpl/default/PayVideo/index_w3g.html
+162
-138
apps/course/Tpl/default/Video/view_w3g.html
+1
-1
No files found.
addons/theme/stv1/_static_w3g/css/common.css
View file @
ee85e8cc
...
@@ -863,6 +863,13 @@ div::-webkit-scrollbar {
...
@@ -863,6 +863,13 @@ div::-webkit-scrollbar {
border-radius
:
1.5625rem
;
border-radius
:
1.5625rem
;
}
}
.vip_buy_pay_button_disable
{
width
:
7.25rem
;
height
:
2.5rem
;
background
:
#F5F5F5
;
border-radius
:
1.5625rem
;
}
/* Course */
/* Course */
.course_detail_video_container
{
.course_detail_video_container
{
height
:
10rem
;
height
:
10rem
;
...
@@ -879,3 +886,12 @@ div::-webkit-scrollbar {
...
@@ -879,3 +886,12 @@ div::-webkit-scrollbar {
padding
:
0.75rem
0.75rem
;
padding
:
0.75rem
0.75rem
;
padding-bottom
:
0
;
padding-bottom
:
0
;
}
}
/* Pay Course */
.pay_course_info
{
padding
:
1.25rem
0.75rem
;
}
.pay_course_bottom
{
padding
:
0.75rem
;
}
\ No newline at end of file
apps/course/Tpl/default/PayVideo/index_w3g.html
View file @
ee85e8cc
...
@@ -3,16 +3,74 @@
...
@@ -3,16 +3,74 @@
<link
href=
"__APP__/css/pay_video_3g.css"
rel=
"stylesheet"
>
<link
href=
"__APP__/css/pay_video_3g.css"
rel=
"stylesheet"
>
<style>
<style>
body
{
padding
:
0
!important
;
}
</style>
</style>
<div
class=
"body"
>
<div
id=
"app"
>
<div
class=
"layout_v"
>
<div
class=
"pay_course_info layout_h"
>
<van-image
src=
"{:getCover($cover,220,130)}"
fit=
"cover"
width=
"120"
height=
"68"
></van-image>
<div
class=
"layout_v"
style=
"margin-left: 0.75rem;"
>
<span
class=
"text_14_600 color_333333"
>
{$video_title}
</span>
<span
class=
"text_14_600 color_FF3B3B"
style=
"margin-top: 0.5rem;"
>
{$moner_data['oriPrice']}
</span>
</div>
</div>
<div
class=
"normal_gap"
></div>
<div
class=
"layout_v pay_course_bottom"
>
<div
class=
"layout_h_v_c"
>
<van-image
height=
"28"
width=
"28"
fit=
"cover"
src=
"__APP__/images/weixin.png"
></van-image>
<span
class=
"text_14_400 color_333333"
style=
"margin-left: 0.75rem;"
>
微信
</span>
</div>
<van-icon
name=
"__THEME__/img/picker_y@3x.png"
size=
"20"
></van-icon>
</div>
<div
class=
"divider"
></div>
<div
style=
"margin-top: 1.5rem;"
class=
"layout_h"
>
<van-icon
@
click=
"agree = !agree"
:name=
"agree ? '__THEME__/img/picker_y@3x.png' : '__THEME__/img/unpicker.png'"
></van-icon>
我已阅读并同意
<a
href=
"{:U('basic/Single/info',array('id'=>'buy'))}"
>
《{$site['site_keyword']}购买协议》
</a>
</div>
</div>
<div
class=
"layout_h_v_c fixed_bottom_bar"
>
<span
class=
"text_14_600 color_333333"
style=
"margin-right: 0.5rem;"
>
合计
</span>
<span
class=
"text_14_600 color_FF3B3B"
>
¥{{totalPrice}}
</span>
<span
class=
"text_12_400 color_999999"
>
{{discount}}
</span>
<div
class=
"weight_full layout_h_r"
>
<div
@
click=
"onBuy"
class=
"vip_buy_pay_button layout_center"
><span
class=
"text_14_400 color_white"
>
确认支付
</span></div>
</div>
</div>
</div>
<script>
new
Vue
({
el
:
"#app"
,
data
:
function
()
{
return
{
agree
:
false
,
info
:
{}
}
},
computed
:
{
totalPrice
:
function
()
{
return
"$0"
},
discount
:
function
()
{
return
"(已优惠:¥0)"
}
},
methods
:
{
onBuy
:
function
()
{
}
}
})
</script>
<!-- <div class="body">
<div class="wrap">
<div class="wrap">
<div class="min-height-wrap">
<div class="min-height-wrap">
<div
class=
"class_order_tit"
>
核对订单信息
</div>
<!--商品信息-->
<dl class="df_course-info">
<dl class="df_course-info">
<dt><h3>
商品信息
</h3></dt>
<dd>
<dd>
<if condition="$pay_video_type eq 'zy_video'">
<if condition="$pay_video_type eq 'zy_video'">
<a href="{:U('course/Video/view',['id'=>$id])}">
<a href="{:U('course/Video/view',['id'=>$id])}">
...
@@ -38,7 +96,6 @@
...
@@ -38,7 +96,6 @@
</dd>
</dd>
</dl>
</dl>
<!--支付方式-->
<dl class="df_pay-style">
<dl class="df_pay-style">
<dt><h3>支付方式</h3></dt>
<dt><h3>支付方式</h3></dt>
<php>if($is_wx){unset($payWay['支付宝支付']);}$firstPayWay = current($payWay);</php>
<php>if($is_wx){unset($payWay['支付宝支付']);}$firstPayWay = current($payWay);</php>
...
@@ -51,16 +108,14 @@
...
@@ -51,16 +108,14 @@
</if>
</if>
<if condition="in_array('unionpay',$payConfig['pay'])">
<if condition="in_array('unionpay',$payConfig['pay'])">
<!--<span val="unionpay">银联支付</span>-->
</if>
</if>
<if condition="in_array('lcnpay',$payConfig['pay'])">
<if condition="in_array('lcnpay',$payConfig['pay'])">
<dd
value=
"lcnpay"
class=
"paytype"
><a
class=
"icon icon-qianbao"
></a><span
class=
"name"
>
<!-- <img style="width: 24px;position: relative;top: -4px;left: -1%" src="__APP__/icon/yue.png" alt="图标"/> -->
余额支付(¥{$account_balance})
</span><i
class=
"<if condition='($firstPayWay eq lcnpay)'>icon icon-xuanze</if>"
></i></dd>
<dd value="lcnpay" class="paytype"><a class="icon icon-qianbao"></a><span class="name">余额支付(¥{$account_balance})</span><i class="<if condition='($firstPayWay eq lcnpay)'>icon icon-xuanze</if>"></i></dd>
</if>
</if>
</dl>
</dl>
<!--优惠券-->
<if condition="$is_asb OR ($pay_order AND $used_coupon)">
<if
condition=
"$is_asb OR ($pay_order AND $used_coupon)"
>
<!-- 拼团无优惠券 --><!-- 砍价成功无优惠券 -->
<elseif condition="$show_coupon eq 1 and $course_hour_info eq null" />
<elseif condition="$show_coupon eq 1 and $course_hour_info eq null" />
<dl class="df_pay-coupon">
<dl class="df_pay-coupon">
<a href="{:U('course/PayVideo/coupon',['id'=>$id, 'vst'=>$coupon_vst, 'asb'=>$_GET['asb']])}">
<a href="{:U('course/PayVideo/coupon',['id'=>$id, 'vst'=>$coupon_vst, 'asb'=>$_GET['asb']])}">
...
@@ -70,7 +125,6 @@
...
@@ -70,7 +125,6 @@
</dl>
</dl>
</if>
</if>
<!--实付金额-->
<dl class="df_pay-price">
<dl class="df_pay-price">
<dd><h3>实付金额</h3><p id="pay_money">¥<if condition="$course_hour_info">{$course_hour_info['course_hour_price']}<else/>{$moner_data['price']}</if></p></dt>
<dd><h3>实付金额</h3><p id="pay_money">¥<if condition="$course_hour_info">{$course_hour_info['course_hour_price']}<else/>{$moner_data['price']}</if></p></dt>
<if condition="in_array($pay_video_type, ['zy_video','zy_live','zy_classes']) and $chd eq 0">
<if condition="in_array($pay_video_type, ['zy_video','zy_live','zy_classes']) and $chd eq 0">
...
@@ -78,12 +132,10 @@
...
@@ -78,12 +132,10 @@
</if>
</if>
</dl>
</dl>
<!--购买协议-->
<div class="df_pay-protocol">
<div class="df_pay-protocol">
<p><i class="icon icon-xuanze" attr="1"></i>我已阅读并同意<a href="{:U('basic/Single/info',array('id'=>'buy'))}">《{$site['site_keyword']}购买协议》</a></p>
<p><i class="icon icon-xuanze" attr="1"></i>我已阅读并同意<a href="{:U('basic/Single/info',array('id'=>'buy'))}">《{$site['site_keyword']}购买协议》</a></p>
</div>
</div>
<!--提交订单-->
<div class="df_pay-buy">
<div class="df_pay-buy">
<h3>合计:<strong id="pay_money2">¥<if condition="$course_hour_info">{$course_hour_info['course_hour_price']}<else/>{$moner_data['price']}</if></strong></h3>
<h3>合计:<strong id="pay_money2">¥<if condition="$course_hour_info">{$course_hour_info['course_hour_price']}<else/>{$moner_data['price']}</if></strong></h3>
<a href="javascript:;" onclick="buyOperat(this,{$id},'video');" type="submit">提交</a>
<a href="javascript:;" onclick="buyOperat(this,{$id},'video');" type="submit">提交</a>
...
@@ -116,9 +168,9 @@
...
@@ -116,9 +168,9 @@
</form>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
-->
<if
condition=
"$is_wx eq false"
>
<
!-- <
if condition="$is_wx eq false">
<style>
<style>
#_ts_box_h5{width:290px;height:180px;text-align: center;color: #535353;border-radius: 5px;position: fixed;background: #fff;-webkit-box-shadow: 0 2px 5px #dddddd;-moz-box-shadow: 0 2px 5px #dddddd;-khtml-box-shadow: 0 2px 5px #dddddd;-ms-box-shadow: 0 0 15px #888888;box-shadow: 0 0 15px #888888;z-index: 997;left: 5%;top: 35%;margin: 0 auto;background: #fff;}
#_ts_box_h5{width:290px;height:180px;text-align: center;color: #535353;border-radius: 5px;position: fixed;background: #fff;-webkit-box-shadow: 0 2px 5px #dddddd;-moz-box-shadow: 0 2px 5px #dddddd;-khtml-box-shadow: 0 2px 5px #dddddd;-ms-box-shadow: 0 0 15px #888888;box-shadow: 0 0 15px #888888;z-index: 997;left: 5%;top: 35%;margin: 0 auto;background: #fff;}
._hide_box_h5{z-index:996;filter:alpha(opacity=50);background:#666;opacity: 0.5;-moz-opacity: 0.5;left:0;top:0;height:99%;width:100%;position:fixed;}
._hide_box_h5{z-index:996;filter:alpha(opacity=50);background:#666;opacity: 0.5;-moz-opacity: 0.5;left:0;top:0;height:99%;width:100%;position:fixed;}
...
@@ -132,150 +184,122 @@
...
@@ -132,150 +184,122 @@
<div id="_layer-content">已完成支付</div>
<div id="_layer-content">已完成支付</div>
<div class="_layer-wt"><a href="{:U('course/PayVideo/index',['vst'=>$_GET['vst']])}">支付遇到问题,联系客服</a></div>
<div class="_layer-wt"><a href="{:U('course/PayVideo/index',['vst'=>$_GET['vst']])}">支付遇到问题,联系客服</a></div>
</div>
</div>
</if>
</if>
-->
<script>
<script>
$
(
function
(){
//
$(function(){
$
(
".df_pay-style dd:last-child"
).
children
(
"i"
).
css
(
"border"
,
"1px solid #ededed"
);
//
$(".df_pay-style dd:last-child").children("i").css("border","1px solid #ededed");
$
(
".df_pay-style dd"
).
on
(
"click"
,
function
(){
//
$(".df_pay-style dd").on("click",function(){
$
(
this
).
children
(
"i"
).
attr
(
"class"
,
"icon icon-xuanze"
).
css
(
"border"
,
"1px solid transparent"
).
parent
().
siblings
().
children
(
"i"
).
removeAttr
(
"class"
,
"icon icon-xuanze"
).
css
(
"border"
,
"1px solid #ededed"
);
//
$(this).children("i").attr("class","icon icon-xuanze").css("border","1px solid transparent").parent().siblings().children("i").removeAttr("class","icon icon-xuanze").css("border","1px solid #ededed");
});
//
});
$
(
".df_pay-protocol i"
).
on
(
"click"
,
function
(){
// $(".df_pay-protocol i").on("click",function(){
var
proVal
=
$
(
this
).
attr
(
"attr"
);
// var proVal = $(this).attr("attr");
if
(
proVal
==
1
){
// if(proVal==1){
$
(
this
).
attr
(
"attr"
,
"0"
).
css
(
"color"
,
"#656565"
);
// $(this).attr("attr","0").css("color","#656565");
}
else
{
// }else{
$
(
this
).
attr
(
"attr"
,
"1"
).
css
(
"color"
,
"#57BC4C"
)
// $(this).attr("attr","1").css("color","#57BC4C")
}
// }
});
// });
})
// })
// '
<
if
condition
=
"$is_wx eq false"
>
'
// $(function(){
// var wpay = "{$_GET['
wpay
']}";
// var ppn = "{$_GET['
ppn
']}";
// if(wpay != ''){
// $('
.
_hide_box_h5
,
#
_ts_box_h5
').show();
// $('
#
_layer
-
content
').click(function(){
// $('
.
_hide_box_h5
,
#
_ts_box_h5
').hide();
// s = setInterval(function(){
// $.ajax({
// url: "{:U('
course
/
PayVideo
/
getPayStatus
')}",
// data:{pay_pass_num:ppn},
// type:'
post
',
// success: function(res){
// try{
// res = JSON.parse(res);
// if(res.status == 1){
// clearInterval(s);
// ui.success('
购买成功
');
// setTimeout(function(){
// window.location.href = res.data;
// },2000);
// }
// }catch(e){
// return;
// }
// }
// });
// },1800);
// });
// }
// });
// '
<
/if>
'
'<if condition="$is_wx eq false">'
// $(function(){
$
(
function
(){
// $('.paytype').click(function(){
var
wpay
=
"{$_GET['wpay']}"
;
// var pay = $(this).attr('value');
var
ppn
=
"{$_GET['ppn']}"
;
// $('input:hidden[name="pay"]').val(pay);
if
(
wpay
!=
''
){
// });
$
(
'._hide_box_h5,#_ts_box_h5'
).
show
();
// });
$
(
'#_layer-content'
).
click
(
function
(){
$
(
'._hide_box_h5,#_ts_box_h5'
).
hide
();
// function buyvCoupon(cid,coupon_id,discount_type) {
s
=
setInterval
(
function
(){
// if(MID
<=
0
){
$
.
ajax
({
// ui.confirm('请先登录', {
url
:
"{:U('course/PayVideo/getPayStatus')}"
,
// yes: function () {
data
:{
pay_pass_num
:
ppn
},
// window.location.href = "{:U('basic/Passport/login')}";
type
:
'post'
,
// }
success
:
function
(
res
){
// });
try
{
// return false;
res
=
JSON
.
parse
(
res
);
// }
if
(
res
.
status
==
1
){
// if(!cid || !coupon_id || !discount_type){
clearInterval
(
s
);
// ui.error('参数错误');
ui
.
success
(
'购买成功'
);
// return false;
setTimeout
(
function
(){
// }
window
.
location
.
href
=
res
.
data
;
// var price = $('#pay_money_val').val();
},
2000
);
// if(price
<=
0
){
}
// ui.error('该课程不需要您购买');
}
catch
(
e
){
// return false;
return
;
// }
}
// $('#coupon_id').val(coupon_id);
}
// $.post(U("course/PayVideo/checkCoupon"),{cid:cid,coupon_id:coupon_id,discount_type:discount_type,price:price},function(e){
});
// if(e.status == 1){
},
1800
);
// $('.removeUse').show();
});
// }else{
}
// ui.error(e.info);
});
// }
'</if>'
// },'json');
// }
$
(
function
(){
//取消使用
// var id = '{$coupon.id}';
// function removeUse(sid){
// var price = '{$moner_data.price}';
// var code = $("input[name='card']").val();
// // console.log(price);
// $.ajax({
// $.ajax({
// type:"POST",
// type:"POST",
// url:"{:U('course/PayVideo/
getCouponInfo
')}",
// url:"{:U('course/PayVideo/
cancelExchangeCard
')}",
// data:{
id:
id},
// data:{
code:code,mhm_id:s
id},
// dataType:"json",
// dataType:"json",
// success:function(data){
// success:function(data){
// if(data){
// if(data.status == 1){
// buyvCoupon(data.coupon_id,data.cuid,data.type,price);
// ui.success(data.info);
// setTimeout('window.location.reload()', 500);
// }else{
// }else{
// ui.error(data.info);
// return false;
// return false;
// }
// }
// }
// }
// });
// });
// }
//支付方式选择
$
(
'.paytype'
).
click
(
function
(){
var
pay
=
$
(
this
).
attr
(
'value'
);
$
(
'input:hidden[name="pay"]'
).
val
(
pay
);
});
// $(".hide_box").fadeToggle();
// $(".shang_box").fadeToggle();
});
function
buyvCoupon
(
cid
,
coupon_id
,
discount_type
)
{
if
(
MID
<=
0
){
ui
.
confirm
(
'请先登录'
,
{
yes
:
function
()
{
window
.
location
.
href
=
"{:U('basic/Passport/login')}"
;
}
});
return
false
;
}
if
(
!
cid
||
!
coupon_id
||
!
discount_type
){
ui
.
error
(
'参数错误'
);
return
false
;
}
var
price
=
$
(
'#pay_money_val'
).
val
();
if
(
price
<=
0
){
ui
.
error
(
'该课程不需要您购买'
);
return
false
;
}
$
(
'#coupon_id'
).
val
(
coupon_id
);
$
.
post
(
U
(
"course/PayVideo/checkCoupon"
),{
cid
:
cid
,
coupon_id
:
coupon_id
,
discount_type
:
discount_type
,
price
:
price
},
function
(
e
){
if
(
e
.
status
==
1
){
// $('#cod_money1').text("-¥"+e.data.minus_price);
// $('#cod_money2').text("¥"+e.data.minus_price);
// $('#pay_money').text("¥"+e.data.after_price);
// $('#pay_money2').text("¥"+e.data.after_price);
// $('#pay_money_val').val(e.data.after_price);
// ui.success(e.info);
$
(
'.removeUse'
).
show
();
}
else
{
ui
.
error
(
e
.
info
);
}
},
'json'
);
}
//取消使用
function
removeUse
(
sid
){
var
code
=
$
(
"input[name='card']"
).
val
();
$
.
ajax
({
type
:
"POST"
,
url
:
"{:U('course/PayVideo/cancelExchangeCard')}"
,
data
:{
code
:
code
,
mhm_id
:
sid
},
dataType
:
"json"
,
success
:
function
(
data
){
if
(
data
.
status
==
1
){
ui
.
success
(
data
.
info
);
setTimeout
(
'window.location.reload()'
,
500
);
}
else
{
ui
.
error
(
data
.
info
);
return
false
;
}
}
});
}
/**
/**
* 删除字符串str的首尾空格
* 删除字符串str的首尾空格
* @name trim
* @name trim
* @grammar UM.utils.trim(str) => String
* @grammar UM.utils.trim(str) => String
*/
*/
var
trim
=
function
(
str
)
{
//
var trim =function (str) {
return
str
.
replace
(
/
(
^
[
\t\n\r]
+
)
|
([
\t\n\r]
+$
)
/g
,
''
);
//
return str.replace(/(^[ \t\n\r]+)|([ \t\n\r]+$)/g, '');
}
//
}
//购买操作
//购买操作
...
...
apps/course/Tpl/default/Video/view_w3g.html
View file @
ee85e8cc
...
@@ -64,7 +64,7 @@
...
@@ -64,7 +64,7 @@
<div
class=
"fixed_bottom_bar layout_h_v_c"
>
<div
class=
"fixed_bottom_bar layout_h_v_c"
>
<template
v-if=
"bought"
>
<template
v-if=
"bought"
>
<div
class=
"vip_buy_pay_button_disable layout_center weight_full"
><span
class=
"text_14_400 color_white"
>
已购买
</span></div>
</template>
</template>
<template
v-else
>
<template
v-else
>
...
...
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