98 lines
3.1 KiB
PHP
98 lines
3.1 KiB
PHP
@extends('layouts.app')
|
||
@section('content')
|
||
<link rel="stylesheet" href="css/user.css" type="text/css" />
|
||
<section class="padding_btm">
|
||
<!--我的粉丝-->
|
||
<div class="j_account_money">
|
||
我的关注<span>{{ $children_count }}人</span>
|
||
<button class="btn yellow circle" type="button" data-href="{{ route('team.index') }}">我的粉丝</button>
|
||
</div>
|
||
<ul class="j_people_list" id="content-page">
|
||
@include('team.item')
|
||
</ul>
|
||
<!--end 我的粉丝-->
|
||
<div class="btn fluid nextpage refjs more_27 bg_see" data-posturl="{{ route('team.novip') }}" data-page="1" data-qkey="" data-content="content-page">查看更多内容</div>
|
||
|
||
</section>
|
||
@endsection
|
||
@section('script')
|
||
<script type="text/javascript">
|
||
|
||
function copy(str)
|
||
{
|
||
var save = function (e){
|
||
e.clipboardData.setData('text/plain',str);
|
||
e.preventDefault();
|
||
}
|
||
document.addEventListener('copy',save);
|
||
document.execCommand("copy");
|
||
}
|
||
|
||
function refjs()
|
||
{
|
||
$(".wechat").on("click",function(){
|
||
var wechat=$(this).data('wechat');
|
||
if(wechat==''){
|
||
updateAlert('没有推荐人或推荐人没有绑定微信');
|
||
}else{
|
||
copy(wechat);
|
||
updateAlert('微信号已复制,长按粘贴去微信联系ta吧');
|
||
}
|
||
});
|
||
|
||
$("#node").change(function(data){
|
||
var node = $(this).val();
|
||
location.href = "{{ route('team.index') }}/" + node;
|
||
});
|
||
|
||
$('[data-href]').on('click', function(event) {
|
||
event.preventDefault();
|
||
if ($(this).hasClass('ajax-get') || $(this).hasClass('ajax-post')) {
|
||
return;
|
||
}
|
||
location.href = $(this).data('href');
|
||
});
|
||
|
||
}
|
||
|
||
$(function(){
|
||
refjs();
|
||
})
|
||
|
||
$(".nextpage").on('click',function(){
|
||
var $this = $(this);
|
||
if($this.data('end')==1){
|
||
updateAlert('已经到最后一页',false);
|
||
return false;
|
||
}
|
||
$this.removeClass('bg_see');
|
||
$this.addClass('loading');
|
||
$this.addClass('loading-light');
|
||
$this.addClass('gray');
|
||
var page=$this.data('page');
|
||
var content=$this.data('content');
|
||
var href=$this.data('posturl');
|
||
var query=$this.data('qkey')+"&page="+(page+1);
|
||
$.get(href,query,function(data){
|
||
if(data.statusCode==200){
|
||
$("#"+content).append(data.message);
|
||
$this.data('page',(page+1));
|
||
$this.removeClass('loading');
|
||
$this.removeClass('loading-light');
|
||
$this.removeClass('gray');
|
||
$this.addClass('bg_see');
|
||
if($this.hasClass('refjs')){
|
||
refjs();
|
||
}
|
||
} else {
|
||
updateAlert(data.msg,false);
|
||
$this.data('end',1);
|
||
$this.removeClass('loading');
|
||
$this.removeClass('loading-light');
|
||
$this.text('已经到最后一页');
|
||
}
|
||
});
|
||
});
|
||
</script>
|
||
@endsection
|