|
|
var $ = require('jquery'),
|
|
|
IScroll = require('iscroll/iscroll-probe'),
|
|
|
Swiper = require('yoho.iswiper'),
|
|
|
tip = require('../plugin/tip');
|
|
|
|
|
|
var isCouponClick = true,
|
...
|
...
|
@@ -7,7 +8,7 @@ var isCouponClick = true, |
|
|
|
|
|
$(".coupon-content .receive-btn").on('touchstart', function(e) {
|
|
|
var that = this,
|
|
|
code = $(this).closest('.coupon-small').data('id') || '';
|
|
|
code = $(this).closest('.swiper-slide').data('id') || '';
|
|
|
|
|
|
if (isCouponClick === false) {
|
|
|
return false;
|
...
|
...
|
@@ -48,12 +49,10 @@ $(".coupon-content .receive-btn").on('touchstart', function(e) { |
|
|
});
|
|
|
});
|
|
|
|
|
|
$(window).ready(function() {
|
|
|
new IScroll('.coupon-content', {
|
|
|
probeType: 1,
|
|
|
vScroll: false,
|
|
|
hScroll: true,
|
|
|
mouseWheel: false,
|
|
|
click: true
|
|
|
});
|
|
|
}); |
|
|
\ No newline at end of file |
|
|
$(function() {
|
|
|
new Swiper('.coupon-content', {
|
|
|
slideElement: '.coupon-small',
|
|
|
slidesPerView: 'auto',
|
|
|
watchSlidesVisibility: true
|
|
|
})
|
|
|
}) |
...
|
...
|
|