|
@@ -328,9 +328,9 @@ class Guild extends Api
|
|
|
* 公会签约申请
|
|
|
*/
|
|
|
public function guildJoinin() {
|
|
|
- $join_time = $this->request->request("join_time"); //签约时长:1=3个月,2=6个月,3=12个月
|
|
|
+ $join_time = $this->request->request("join_time",1); //签约时长:1=3个月,2=6个月,3=12个月
|
|
|
$guild_id = $this->request->request("guild_id"); //公会ID
|
|
|
- if(!in_array($join_time,[1,2,3]) || !$guild_id) $this->error("参数错误!");
|
|
|
+ //if(!in_array($join_time,[1,2,3]) || !$guild_id) $this->error("参数错误!");
|
|
|
|
|
|
// 一个身份证号只能申请一次
|
|
|
$user_id = $this->auth->id;
|
|
@@ -349,15 +349,15 @@ class Guild extends Api
|
|
|
// 获取用户实名认证信息
|
|
|
$authUserIdcard = \app\common\model\UserAuth::where(["user_id"=>$user_id])->value("idcard");
|
|
|
// 搜索签约申请中是否有此身份证号
|
|
|
- $idcardfind = \app\common\model\GuildJoinin::where(["user_id"=>$user_id,"status"=>0])->find();
|
|
|
+ $idcardfind = \app\common\model\GuildJoinin::where(["user_id"=>$user_id,'guild_id'=>$guild_id,"status"=>0])->find();
|
|
|
if($idcardfind) $this->error("当前账号正在审核,请耐心等待!");
|
|
|
|
|
|
- $memberfind = \app\common\model\GuildMember::where(["user_id"=>$user_id,"status"=>1,"sign_time"=>["gt",time()]])->find();
|
|
|
+ $memberfind = \app\common\model\GuildMember::where(["user_id"=>$user_id,"status"=>1])->find();
|
|
|
if($memberfind) $this->error("一个账号只能加入一个公会哟!");
|
|
|
|
|
|
// 查看是否申请过
|
|
|
- $applyInfo = \app\common\model\GuildApply::where(["user_id"=>$user_id,"status"=>0])->find();
|
|
|
- if($applyInfo && $applyInfo->status>=0) $this->error("您已经发送过开厅申请了,请勿重复发送!");
|
|
|
+ /*$applyInfo = \app\common\model\GuildApply::where(["user_id"=>$user_id,"status"=>0])->find();
|
|
|
+ if($applyInfo && $applyInfo->status>=0) $this->error("您已经发送过开厅申请了,请勿重复发送!");*/
|
|
|
|
|
|
// // 获取公会信息
|
|
|
// $guildInfo = \app\common\model\Guild::where(["user_id"=>$user_id,"status"=>1])->find();
|
|
@@ -578,7 +578,7 @@ class Guild extends Api
|
|
|
$role = ["","管理","会长"];
|
|
|
if($guildMemberList) {
|
|
|
foreach($guildMemberList as $k => &$v) {
|
|
|
- $v["role"] = $role[$v["role"]];
|
|
|
+ $v["role_text"] = $role[$v["role"]];
|
|
|
if ($v['is_online'] == 1) {
|
|
|
$onlineText = '在线';
|
|
|
} else {
|