www_fpvone_cn/application/index/view/players/myclub.html

376 lines
13 KiB
HTML
Raw Permalink Normal View History

2024-12-20 12:29:51 +08:00
<link rel="stylesheet" type="text/css" href="__CDN__/assets/css/door/css/flyer.css">
<link rel="stylesheet" type="text/css" href="__CDN__/assets/css/door/css/public.css">
<link rel="stylesheet" type="text/css" href="__CDN__/assets/css/door/css/layui.css">
<link rel="stylesheet" type="text/css" href="https://at.alicdn.com/t/font_1291339_s2iegrqsymf.css">
<link rel="stylesheet" type="text/css" href="__CDN__/assets/css/door/css/newClub.css?v={$site.version}">
<style>
.sociatybox button{
margin: 0 5px;
padding: 10px 30px;
}
.sociatybox table td:last-child{
width: 39%;
}
.sociatybox .resbtn{
background: #aaa;
}
.layui-layer-btn .layui-layer-btn0{
background: #000;
}
@media screen and (max-width: 768px){
.sociatybox button{
margin: 0 2px;
padding: 8px 10px;
}
}
</style>
<div class="fly-right">
<div class="searchbox">
<p class="my-event">我的队伍 | My Club</p>
</div>
{if $player_status==0}
<div class="nosociaty">
<img src="/assets/addons/cms/img/noclub.png">
<!--<p><a style="text-decoration: underline;" href="/index/players/sociaty.html">请先加入公会,等待队伍的邀请</a></p>-->
<p><a href="javascript:;">请先加入公会,等待队伍的邀请</a></p>
</div>
</div>
{elseif $player_status==2}
<div class="clubmain">
<div class="clubinfo">
<div class="info">
<div class="item">
<div>
<div class="name">
<p>队伍名称</p>
<p>Club Name</p>
</div>
<div class="text">{$club_info.name}</div>
</div>
</div>
<div class="item">
<div>
<div class="name">
<p>所属地区</p>
<p>Address</p>
</div>
<div class="text">{$club_info.province}{$club_info.city=='选择'?'':$club_info.city}{$club_info.district=='选择'?'':$club_info.district}</div>
</div>
</div>
<div class="item">
<div>
<div class="name">
<p>参赛主体</p>
<p>Competitors</p>
</div>
<div class="text">{$club_info.competitors}</div>
</div>
</div>
<div class="item twocows">
<div>
<div class="name">
<p>队徽</p>
<p>Club Logo</p>
</div>
<div class="text"><img src="{$club_info.logo}" width="120"></div>
</div>
<div>
<div class="name">
<p>队旗</p>
<p>Club Flag</p>
</div>
<div class="text"><img src="{$club_info.flag}" width="120"></div>
</div>
</div>
<div class="item">
<div>
<div class="name">
<p>ASFC会员</p>
<p>ASFC User</p>
</div>
<div class="text">{$club_info.is_asfc?'是':'否'}</div>
</div>
</div>
<div class="item twocows">
<div>
<div class="name">
<p>领队</p>
<p>Club Leader</p>
</div>
<div class="text">{$club_info.leader}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.leader_tel}</div>
</div>
</div>
<div class="item twocows">
<div>
<div class="name">
<p>副领队1</p>
<p>Deputy Leader</p>
</div>
<div class="text">{$club_info.deputy_leader1}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.deputy_leader1_tel}</div>
</div>
</div>
<div class="item twocows">
<div>
<div class="name">
<p>副领队2</p>
<p>Deputy Leader</p>
</div>
<div class="text">{$club_info.deputy_leader2}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.deputy_leader2_tel}</div>
</div>
</div>
<div class="item twocows">
<div>
<div class="name">
<p>主教练</p>
<p>Deputy Leader</p>
</div>
<div class="text">{$club_info.head_coach}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.head_coach_tel}</div>
</div>
</div>
<div class="item twocows">
<div>
<div class="name">
<p>教练员1</p>
<p>Deputy Leader</p>
</div>
<div class="text">{$club_info.coach1}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.coach1_tel}</div>
</div>
</div>
{if $club_info.coach2}
<div class="item twocows">
<div>
<div class="name">
<p>教练员2</p>
<p>Deputy Leader</p>
</div>
<div class="text">{$club_info.coach2}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.coach2_tel}</div>
</div>
</div>
{/if}
{if $club_info.coach3}
<div class="item twocows">
<div>
<div class="name">
<p>教练员2</p>
<p>Deputy Leader</p>
</div>
<div class="text">{$club_info.coach3}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.coach3_tel}</div>
</div>
</div>
{/if}
{if $club_info.coach4}
<div class="item twocows">
<div>
<div class="name">
<p>教练员2</p>
<p>Deputy Leader</p>
</div>
<div class="text">{$club_info.coach4}</div>
</div>
<div>
<div class="name">
<p>联系电话</p>
<p>Contact</p>
</div>
<div class="text">{$club_info.coach4_tel}</div>
</div>
</div>
{/if}
</div>
<div class="btn">
<a onclick="exitClub()">
<p>申诉</p>
</a>
</div>
</div>
</div>
{elseif $player_status==3}
<div class="nosociaty">
<img src="/assets/addons/cms/img/hasclub.png">
<p>请等待联赛组委会审核,<a href="tel:13136225305">加急审核请致电13136225305</a></p>
</div>
{else}
<div class="nosociaty">
<img src="/assets/addons/cms/img/noclub.png">
<p>暂未收到队伍的邀请通知,敬请期待</p>
</div>
<div class="sociatybox" style="display:none;">
<table border="0">
<thead>
<td>
<p>队伍名称</p>
<p>Club Name</p>
</td>
<td>
<p>邀请时间</p>
<p>Invite Time</p>
</td>
<td>
<p>操作</p>
<p>Operation</p>
</td>
</thead>
<tbody>
</tbody>
</table>
<div id="page"></div>
</div>
{/if}
</div>
<script src="__CDN__/assets/css/door/layui/layui.js"></script>
<script type="text/javascript" charset="utf-8">
// 更新列表
function getlist(res){
$('.sociatybox table tbody').empty()
let itemhtml='';
res.forEach((item)=>{
itemhtml+=`
<tr>
<td>${item.club_name}</td>
<td>${item.updatetime}</td>
<td><button class="agbtn" id="${item.id}">同意</button><button class="resbtn" id="${item.id}">拒绝</button></td>
</tr>
`
})
$('.sociatybox table tbody').append(itemhtml);
$('.resbtn').click(function(){
const thats=$(this);
layer.confirm('您确定要拒绝队伍的邀请吗?',{
title:''
},function(){
$.get('/index/players/reject_invate',{
invate_id:thats.attr('id')
},function(res){
if(res.code){
layer.msg('操作成功',{icon:1});
setTimeout(function () {
location.reload();
}, 2000);
}
})
})
})
$('.agbtn').click(function(){
const thats=$(this);
layer.confirm('您确定要同意加入此队伍吗?',{
title:''
},function(){
$.get('/index/players/agree_invate',{
invate_id:thats.attr('id')
},function(res){
if(res.code){
layer.msg('操作成功',{icon:1});
setTimeout(function () {
location.reload();
}, 2000);
}
})
})
})
}
layui.use(['layer','laypage'],function(){
const laypage=layui.laypage;
// 获取申请列表
let page=1;
if({$player_status}==1){
$.get('/index/players/myinvate',function(res){
if(res.total>0){
$('.nosociaty').hide();
$('.sociatybox').show();
getlist(res.data);
// 分页
layui.laypage.render({
elem: 'page',
limit: 10,
count: res.total,
layout: ['count', 'prev', 'page', 'next'],
prev: '<em><</em>',
next: '<em>></em>',
theme: '#C2C2C2',
curr: page,
jump: function(obj){
$.post('{:url("/index/players/myinvate")}',{
page:obj.curr
},function(data){
getlist(data.data)
})
}
})
}
})
}
})
// 退出俱乐部
function exitClub(){
const rethat=$(this)
layer.prompt({
title: '申诉理由',
formType: 2
}, function(text, index){
layer.close(index);
$.post('/index/complain/player_complain',{
complain_text:text
},function(res){
if(res.code){
layer.msg('提交成功,请等待管理员联系您',{icon:1});
setTimeout(function () {
location.reload();
}, 2000);
}else{
layer.msg('请不要频繁提交',{icon:2});
}
})
})
}
</script>