Commit 60e7be5e authored by xiabin's avatar xiabin

添加微信支付的功能

parent 794c5e7f
......@@ -11,7 +11,7 @@
<div class="video-main">
<video id="my-video-play" class="video-js vjs-default-skin vjs-big-play-centered"
controls preload="auto" >
controls preload="auto">
<source :src="coursewareInfo.videoUrl" type="video/mp4"/>
</video>
</div>
......@@ -36,11 +36,22 @@
¥{{coursewareInfo.price}}
</button>
<template v-else>
<button v-if="coursewareInfo.isShop" class="btn btn-danger m-l-20 hidden-xs mb-left" data-toggle="modal">已购买
</button>
<button v-else class="btn btn-danger m-l-20 mb-left" data-toggle="modal"
data-target="#pay">购买 ¥{{coursewareInfo.price}}
<button v-if="coursewareInfo.isShop" class="btn btn-danger m-l-20 hidden-xs mb-left"
data-toggle="modal">已购买
</button>
<template v-else>
<button v-if="isMobile === false && isWeixin === false" class="btn btn-danger m-l-20 mb-left"
data-toggle="modal"
data-target="#pay">购买 ¥{{coursewareInfo.price}}
</button>
<button v-if="isMobile === true && isWeixin === false" class="btn btn-danger m-l-20 mb-left"
@click="alipay(coursewareInfo.course_id)">购买 ¥{{coursewareInfo.price}}
</button>
<button v-if="isWeixin === true" class="btn btn-danger m-l-20 mb-left"
@click="weixinJsPay(coursewareInfo.course_id)">购买 ¥{{coursewareInfo.price}}
</button>
</template>
</template>
......@@ -157,8 +168,6 @@
}
},
methods: {
getWeixinPayQrcode(courseId){
},
alipay(courseId){
var url = __BASE_URL__ + 'home/pay?courseId=' + courseId;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment