h5 data-xx
<a href="javascript:;" data-type='0' class="weui-dialog__btn weui-dialog__btn_default pay">AA</a>
<a href="javascript:;" data-type='1' class="weui-dialog__btn weui-dialog__btn_primary pay">土豪买单</a>
<p class="detail" data-activity="{$activity_id}"></p>
<p class="room-infs" data-id ="{$vo['id']}"></p>
$('.pay').on('click',function () {
$.ajax({
url:"{:U('Invite/followInvite')}",
type:'get',
data:{invite_uid:$('.room-infs').data('id'),activity_id:$('.detail').data('activity'),type:$(this).data('type')},//取值
dataType:'json',
success:function(data){
if(data['status'] == '1'){
alert('邀请发送成功');
}else{
alert(data['err']);
}
}
})
})