فهرست منبع

Merge branch 'master' of http://59.57.98.130:3000/jjhc/jucai

linwu 1 سال پیش
والد
کامیت
5830e44315

+ 10 - 1
app/Admin/Controllers/Recruit/RecruitTicketController.php

@@ -137,7 +137,16 @@ class RecruitTicketController extends Controller
                 $item = [
                     $v->realname,
                     $v->card,
-                    $post_data[$v->post_id]
+                    $post_data[$v->post_id],
+                    '',
+                    '',
+                    '',
+                    '',
+                    '',
+                    '',
+                    '',
+                    '',
+                    $v->mobile
                 ];
                 array_push($data,$item);
             }else{

+ 149 - 187
app/Http/Controllers/Web/Recruit/IndexController.php

@@ -1762,7 +1762,7 @@ class IndexController extends WebBaseController
         }
 
 
-        $limit_time = 1694079000;
+        $limit_time = 1694683800;
         $time = time();
         if( $time > $limit_time){
             return $this->showMessage('抱歉,考察审核端口已关闭!', route('recruit.show',array('id',$recruit['id'])), true, '上一页', '3');
@@ -1978,7 +1978,7 @@ class IndexController extends WebBaseController
         } else {
             return redirect(route('login'));
         }
-        $limit_time = 1694079000;
+        $limit_time = 1694683800;
         $time = time();
         if( $time > $limit_time){
             return $this->showMessage('抱歉,考察审核端口已关闭!', route('recruit.show',array('id',38)), true, '上一页', '3');
@@ -2318,7 +2318,7 @@ class IndexController extends WebBaseController
         }
         //手动设置择岗时间段
         $time = time();
-        if($time > 1694491200 || $time < 1694394000){
+        if($time > 1695096000 || $time < 1694998800){
         //if($time > 1694491200){
             return $this->showMessage('抱歉,未到择岗时间!', route('recruit.show',array('id',$recruit_id)), true, '上一页', '2');
         }
@@ -2326,114 +2326,34 @@ class IndexController extends WebBaseController
             $option_list = [
                 [
                     'id' => 1,
-                    'name' => '梅岭街道'
-                ],
-                [
-                    'id' => 2,
-                    'name' => '西园街道'
-                ],
-                [
-                    'id' => 3,
-                    'name' => '罗山街道'
-                ],
-                [
-                    'id' => 4,
-                    'name' => '新塘街道'
-                ],
-                [
-                    'id' => 5,
                     'name' => '陈埭镇'
                 ],
                 [
-                    'id' => 6,
+                    'id' => 2,
                     'name' => '池店镇'
                 ],
                 [
-                    'id' => 7,
-                    'name' => '安海镇'
-                ],
-                [
-                    'id' => 8,
-                    'name' => '内坑镇'
-                ],
-                [
-                    'id' => 9,
+                    'id' => 3,
                     'name' => '金井镇'
                 ],
                 [
-                    'id' => 10,
+                    'id' => 4,
                     'name' => '龙湖镇'
-                ],
-                [
-                    'id' => 11,
-                    'name' => '经济开发区'
                 ]
             ];
         }else{
             $option_list = [
                 [
-                    'id' => 12,
-                    'name' => '青阳街道'
-                ],
-                [
-                    'id' => 13,
-                    'name' => '梅岭街道'
-                ],
-                [
-                    'id' => 14,
-                    'name' => '西园街道'
-                ],
-                [
-                    'id' => 15,
-                    'name' => '罗山街道'
-                ],
-                [
-                    'id' => 16,
-                    'name' => '灵源街道'
-                ],
-                [
-                    'id' => 17,
-                    'name' => '新塘街道'
-                ],
-                [
-                    'id' => 18,
+                    'id' => 5,
                     'name' => '陈埭镇'
                 ],
                 [
-                    'id' => 19,
-                    'name' => '池店镇'
-                ],
-                [
-                    'id' => 20,
-                    'name' => '安海镇'
-                ],
-                [
-                    'id' => 21,
-                    'name' => '磁灶镇'
-                ],
-                [
-                    'id' => 22,
-                    'name' => '内坑镇'
-                ],
-                [
-                    'id' => 23,
-                    'name' => '紫帽镇'
-                ],
-                [
-                    'id' => 24,
-                    'name' => '永和镇'
-                ],
-                [
-                    'id' => 25,
+                    'id' => 6,
                     'name' => '金井镇'
                 ],
                 [
-                    'id' => 26,
+                    'id' => 7,
                     'name' => '龙湖镇'
-                ],
-                [
-                    'id' => 27,
-                    'name' => '经济开发区'
                 ]
             ];
         }
@@ -2532,7 +2452,7 @@ class IndexController extends WebBaseController
         $recruit_id = $request->input('recruit_id');
         $appoint_id = $request->input('appoint_id');
         $time = time();
-        if($time > 1694491200 || $time < 1694394000){
+        if($time > 1695096000 || $time < 1694998800){
             return ['status' => 0, 'msg' => "抱歉,未到择岗时间!"];
         }
         $info = RecruitAppointSelect::where('uid',$uid)->where('recruit_id',$recruit_id)->where('appoint_id',$appoint_id)->first();
@@ -2569,169 +2489,211 @@ class IndexController extends WebBaseController
     public function get_select_result(Request $request)
     {
         $redis = Cache::getRedis();
-        $quota = $redis->get('recruit_quota');
+        $quota = $redis->get('recruit_quotaA');
         if(!$quota){
             $quota = [
-                [
-                    'name' => '新塘街道',
-                    'value' => 13
-                ],
                 [
                     'name' => '陈埭镇',
-                    'value' => 88
+                    'value' => 2
                 ],
                 [
                     'name' => '池店镇',
-                    'value' => 10
-                ],
-                [
-                    'name' => '安海镇',
-                    'value' => 10
-                ],
-                [
-                    'name' => '磁灶镇',
-                    'value' => 21
-                ],
-                [
-                    'name' => '内坑镇',
-                    'value' => 22
-                ],
-                [
-                    'name' => '东石镇',
-                    'value' => 4
-                ],
-                [
-                    'name' => '永和镇',
-                    'value' => 27
-                ],
-                [
-                    'name' => '英林镇',
-                    'value' => 5
+                    'value' => 1
                 ],
                 [
                     'name' => '金井镇',
-                    'value' => 13
+                    'value' => 2
                 ],
                 [
                     'name' => '龙湖镇',
-                    'value' => 53
-                ],
-                [
-                    'name' => '深沪镇',
-                    'value' => 23
-                ],
-                [
-                    'name' => '西滨镇',
-                    'value' => 3
+                    'value' => 2
                 ]
             ];
-            $redis->set('recruit_quota',json_encode($quota));
+            $redis->set('recruit_quotaA',json_encode($quota));
         }else{
             $quota = json_decode($quota,true);
         }
-        $limit = $request->input('limit',1);
-        $list = DB::table('recruit_appoint_select as a')->leftJoin('recruit_appoint_info as b','a.appoint_id','=','b.id')->leftJoin('recruit_ticket as c','a.appoint_id','=','c.appoint_id')->whereRaw('a.select_result is null and a.batch=2 and a.status=1')->select(['b.realname','c.ex_number','a.result','a.select_result','a.id'])->orderBy('record','desc')->limit($limit)->get();
+        $list = DB::table('recruit_appoint_select as a')->leftJoin('recruit_appoint_info as b','a.appoint_id','=','b.id')->leftJoin('recruit_ticket as c','a.appoint_id','=','c.appoint_id')->whereRaw('a.select_result is null and a.batch=3 and a.type=2 and a.status=1 and a.id > 1262')->select(['b.realname','c.ex_number','a.result','a.select_result','a.id','a.record','a.record2','a.record3'])->orderBy('record','desc')->orderBy('record2','desc')->orderBy('record3','desc')->limit(2)->get()->toArray();
         $return_data = [
             'list' => []
         ];
         $array_column = array_column($quota,'name');
-        foreach ($list as $k => $v){
-            $person_select_result = json_decode($v->result,true);
-            $flag = 0;//是否择岗成功
-            foreach ($person_select_result as $val){
-                //寻找下标
-                $index = array_search($val,$array_column);
-                if($quota[$index]['value'] > 0){
-                    $quota_data = [
-                        'index' => $index,
-                        'old_value' => $quota[$index]['value']
-                    ];
-                    //有名额允许择岗
-                    DB::table('recruit_appoint_select')->where('id',$v->id)->update(['select_result'=>$val,'status' => 1]);
-                    $v->select_result = $val;
-                    $quota[$index]['value']--;
-                    $quota_data['new_value'] = $quota[$index]['value'];
-                    $redis->set('recruit_quota',json_encode($quota));
-                    $flag = 1;
-                    break;
-                }
-            }
-            if(!$flag){
-                $v->select_result = '未匹配到志愿,本轮择岗不成功!';
-                DB::table('recruit_appoint_select')->where('id',$v->id)->update(['select_result'=>'未匹配到志愿,本轮择岗不成功!','status' => -2]);
+        if(count($list) > 1){
+            $current = $list[0];
+            $next = $list[1];
+        }else{
+            $current = $list[0];
+            $next = false;
+        }
+
+        $person_select_result = json_decode($current->result,true);
+        $flag = 0;//是否择岗成功
+        foreach ($person_select_result as $val){
+            //寻找下标
+            $index = array_search($val,$array_column);
+            if($quota[$index]['value']){
+                if($next && $current->record == $next->record && $current->record2 == $next->record2 && $current->record3 == $next->record3 && $quota[$index]['value'] == 1){
+                    //如果当前处理人员不是最后一个,且分数与下一名人员三个维度完全一样的话并且该人员欲择的岗位仅剩一位,则特殊处理
+                    //查找同样分数人同样志愿
+                    $next_select_result = json_decode($next->result,true);
+                    //寻找下标
+                    $current_index = array_search($val,$person_select_result);
+                    $next_index = array_search($val,$next_select_result);
+                    if($current_index > $next_index){
+                        //如果当前人员对当前镇街的意向排序大于下一人,调换两个指针,先排序下一个人
+                        $current = $next;
+                    }
+                }
+                $quota_data = [
+                    'index' => $index,
+                    'old_value' => $quota[$index]['value']
+                ];
+                //有名额允许择岗
+                DB::table('recruit_appoint_select')->where('id',$current->id)->update(['select_result'=>$val,'status' => 1]);
+                $current->select_result = $val;
+                $quota[$index]['value']--;
+                $quota_data['new_value'] = $quota[$index]['value'];
+                $redis->set('recruit_quotaA',json_encode($quota));
+                $flag = 1;
+                break;
             }
-
-            array_push($return_data['list'],$v);
         }
+        if(!$flag){
+            $current->select_result = '未匹配到志愿,本轮择岗不成功!';
+            DB::table('recruit_appoint_select')->where('id',$current->id)->update(['select_result'=>'未匹配到志愿,本轮择岗不成功!','status' => -2]);
+        }
+
         $return_data['quota'] = $quota_data;
         return ['status' => 1, 'msg' => '择岗排序成功', 'data' => $return_data];
     }
 
     public function select_init(Request $request)
     {
-        $count = DB::table('recruit_appoint_select')->whereRaw('select_result is null and batch = 2')->count();
+        $count = DB::table('recruit_appoint_select')->whereRaw('select_result is null and batch = 3 and type = 2')->count();
 
         $redis = Cache::getRedis();
-        $quota = $redis->get('recruit_quota');
-        if(!$quota){
-            $quota = [
+        $quotaA = $redis->get('recruit_quotaA');
+        $quotaB = $redis->get('recruit_quotaB');
+        if(!$quotaA){
+            $quotaA = [
+                [
+                    'name' => '梅岭街道',
+                    'value' => 3
+                ],
+                [
+                    'name' => '西园街道',
+                    'value' => 3
+                ],
+                [
+                    'name' => '罗山街道',
+                    'value' => 3
+                ],
+                [
+                    'name' => '新塘街道',
+                    'value' => 3
+                ],
+                [
+                    'name' => '陈埭镇',
+                    'value' => 10
+                ],
+                [
+                    'name' => '池店镇',
+                    'value' => 7
+                ],
+                [
+                    'name' => '安海镇',
+                    'value' => 5
+                ],
+                [
+                    'name' => '内坑镇',
+                    'value' => 3
+                ],
+                [
+                    'name' => '金井镇',
+                    'value' => 3
+                ],
+                [
+                    'name' => '龙湖镇',
+                    'value' => 5
+                ],
+                [
+                    'name' => '经济开发区',
+                    'value' => 5
+                ]
+            ];
+            $redis->set('recruit_quota',json_encode($quotaA));
+        }
+        if(!$quotaB){
+            $quotaB = [
+                [
+                    'name' => '青阳街道',
+                    'value' => 7
+                ],
+                [
+                    'name' => '梅岭街道',
+                    'value' => 14
+                ],
+                [
+                    'name' => '西园街道',
+                    'value' => 11
+                ],
+                [
+                    'name' => '罗山街道',
+                    'value' => 7
+                ],
+                [
+                    'name' => '灵源街道',
+                    'value' => 3
+                ],
                 [
                     'name' => '新塘街道',
                     'value' => 13
                 ],
                 [
                     'name' => '陈埭镇',
-                    'value' => 88
+                    'value' => 49
                 ],
                 [
                     'name' => '池店镇',
-                    'value' => 10
+                    'value' => 23
                 ],
                 [
                     'name' => '安海镇',
-                    'value' => 10
+                    'value' => 16
                 ],
                 [
                     'name' => '磁灶镇',
-                    'value' => 21
+                    'value' => 2
                 ],
                 [
                     'name' => '内坑镇',
-                    'value' => 22
-                ],
-                [
-                    'name' => '东石镇',
                     'value' => 4
                 ],
                 [
-                    'name' => '永和镇',
-                    'value' => 27
+                    'name' => '紫帽镇',
+                    'value' => 8
                 ],
                 [
-                    'name' => '英林镇',
+                    'name' => '永和镇',
                     'value' => 5
                 ],
                 [
                     'name' => '金井镇',
-                    'value' => 13
+                    'value' => 11
                 ],
                 [
                     'name' => '龙湖镇',
-                    'value' => 53
+                    'value' => 41
                 ],
                 [
-                    'name' => '深沪镇',
-                    'value' => 23
-                ],
-                [
-                    'name' => '西滨镇',
-                    'value' => 3
+                    'name' => '经济开发区',
+                    'value' => 18
                 ]
             ];
-            $redis->set('recruit_quota',json_encode($quota));
+            $redis->set('recruit_quota',json_encode($quotaB));
         }
-        $list = DB::table('recruit_appoint_select as a')->leftJoin('recruit_appoint_info as b','a.appoint_id','=','b.id')->leftJoin('recruit_ticket as c','a.appoint_id','=','c.appoint_id')->whereRaw('a.select_result is not null and a.batch=2')->select(['b.realname','c.ex_number','a.result','a.select_result','a.id'])->orderBy('record','desc')->get();
-        return ['status' => 1, 'msg' => '获取初始化信息成功', 'data' => ['count' => $count, 'quota' => $quota, 'list' => $list]];
+        $list = DB::table('recruit_appoint_select as a')->leftJoin('recruit_appoint_info as b','a.appoint_id','=','b.id')->leftJoin('recruit_ticket as c','a.appoint_id','=','c.appoint_id')->whereRaw('a.select_result is not null and a.batch=3 and type = 2')->select(['b.realname','c.ex_number','a.result','a.select_result','a.id'])->orderBy('record','desc')->get();
+        return ['status' => 1, 'msg' => '获取初始化信息成功', 'data' => ['count' => $count, 'quota' => $quotaB, 'list' => $list]];
     }
 
     public function interviewer_random(Request $request)
@@ -2816,7 +2778,7 @@ class IndexController extends WebBaseController
             return $this->showMessage('您已登记信息,无需再次登记!', route('recruit.show',array('id',$recruit['id'])), true, '上一页', '3');
         }
 
-        $uids = [179049,179051,175896,177011,179015,179134,166830,179056,179110,179140,179040,179154,168701,149108,176405,176637,179182,179115,52845,179240,179036,170227,179286,179145,177121,169161,179282,179318,179173,179385,179287,175723,165156,179217,179085,179174,179441,179459,179448,179461,179476,170189,158658,162111,179504,177503,169950,173378,179571,179576,179548,175865,132228,168809,158464,150061,179594,169655,179311,168348,179131,179654,179664,179683,175855,179100,56968,179610,179146,179731,176717,179435,179669,175794,179487,176307,179806,179758,179555,179822,176249,179769,179815,179685,179856,179840,179828,179844,179376,169398,169530,170181,179799,179123,179652,179936,176102,179261,179957,179888,180033,180039,180050,180028,180064,180078,159819,180085,179987,177195,176790,175722,179933,176170,180122,176929,179872,180151,180123,176834,179547,179879,180196,170277,159623,179892,179904,180227,179952,180232,165930,179195,173624,180244,180277,180325,180321,180265,179871,179908,149297,179898,180407,180239,169158,175716,169910,180288,180452,162757,180309,180474,179266,164225,180465,169899,180098,175481,179306,180458,176454,180451,180507,180531,169591,180456,175467,180589,180587,180590,180601,179679,180597,180602,180604,175637,179830,165858,179835,180677,169304,180711,180234,180426,169691,176956,178303,170289,177028,179894,180311,176683,169720,150103,180705,176548,176655,180849,176101,180855,180808,180869,180348,180733,180889,180866,180399,180657,180920,180876,179701,152053,180208,175641,180831,169075,180980,180988,180991,180686,181016,181023,180974,152179,179284,181058,168483,177233,176619,181110,180809,180979,181122,180916,181142,180992,177427,181143,169886,147697,181173,181218,181041,181171,163107,180363,151296,169429,150164,181258,176891,56330,169740,181272,170078,177000,181317,180845,181303,180839,180983];//写死用户
+        $uids = [165882];//写死用户
 
         if(!in_array($uid,$uids)){
             return $this->showMessage('您无需登记信息!', route('recruit.show',array('id',$recruit['id'])), true, '上一页', '3');

+ 4 - 1
app/Http/Middleware/VerifyCsrfToken.php

@@ -18,6 +18,9 @@ class VerifyCsrfToken extends Middleware
         'common/sms/send',
         'api/checkuser',
         'auth/login/sms',
-        'jjhc/yqfk/chaxun'
+        'jjhc/yqfk/chaxun',
+        'recruit/select_init',
+        'recruit/get_select_result',
+        'share/*'
     ];
 }

+ 1 - 1
app/Validators/AuthValidatorRequest.php

@@ -12,7 +12,7 @@ class AuthValidatorRequest extends BaseValidatorRequest
         return [
            'rules'=>[
                'account'=>['required'],
-               'password'=>['required','min:8','regex:/^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z]{8,}$/']
+               'password'=>['required','min:8','regex:/^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z0-9A-Za-z_.\-#$%!]{8,}$/']
            ],
            'messages'=>[
                'account.required'=>'请输入用户名',

+ 4 - 4
public/themes/default/views/app/recruit/post_select.blade.php

@@ -186,13 +186,13 @@
             },
             methods: {
                 post: function() {
-                    if (type == 1 && this.select_list.length != 11) {
-                        this.$message.error('请对11个镇(街道)进行排序!');
+                    if (type == 1 && this.select_list.length != 4) {
+                        this.$message.error('请对4个镇(街道)进行排序!');
                         return false;
                     }
 
-                    if (type == 2 && this.select_list.length != 16) {
-                        this.$message.error('请对16个镇(街道)进行排序!');
+                    if (type == 2 && this.select_list.length != 3) {
+                        this.$message.error('请对3个镇(街道)进行排序!');
                         return false;
                     }
 

+ 1 - 1
public/themes/default/views/app/recruit/select_result.blade.php

@@ -68,7 +68,7 @@
     <div id="app">
         <div class="recruit_container clearfix">
             <div class="recruit_show_content" style="margin-top: 10px;width: 100%">
-                <div class="title" style="text-align: center"><h2>晋江市公开招聘第十三批村务(社区)专职工作者择岗系统</h2></div>
+                <div class="title" style="text-align: center"><h2>晋江市公开招聘第十五批村务(社区)专职工作者B类择岗系统</h2></div>
                 <div class="clearfix">
                     <div class="operation">
                         <el-button type="primary" @click="getResult()" :disabled="disabled" v-text="start_button"></el-button>

+ 2 - 2
public/themes/default/views/app/recruit/show.blade.php

@@ -110,7 +110,7 @@
                         <li style="background:#764DB3;float: left;margin-bottom:10px;">择岗</li>
                     </a>
                 @endif
-                @if($recruit->id == 18)
+                @if($recruit->id == 18 || $recruit->id == 38)
 
                     <a href="{{ route('recruit.supplement_info',array('id'=>$recruit->id)) }}" >
                         <li style="background:#764DB3;float: left;margin-bottom:10px;">信息采集</li>
@@ -279,7 +279,7 @@
                     <span style="font-family: 微软雅黑;letter-spacing: 0;font-size: 18px">&nbsp; &nbsp;</span><span style="font-family: 微软雅黑;letter-spacing: 0;font-size: 16px">1.本人为现役军人。</span>
                 </p>
                 <p style="margin-bottom: 0;margin-left: 0;text-indent: 32px;line-height: 37px">
-                    <span style="font-family: 微软雅黑;letter-spacing: 0;font-size: 16px">2.本人为普通高等院校全日制在读的非2022年应届毕业生。</span>
+                    <span style="font-family: 微软雅黑;letter-spacing: 0;font-size: 16px">2.本人为普通高等院校全日制在读的非毕业生。</span>
                 </p>
                 <p style="margin-bottom: 0;margin-left: 0;text-indent: 32px;line-height: 37px">
                     <span style="font-family: 微软雅黑;letter-spacing: 0;font-size: 16px">3.本人曾因犯罪受过刑事处罚。</span>

+ 1 - 0
routes/web.php

@@ -120,6 +120,7 @@ Route::group([
     $router->post('comfirm_post','Web\Recruit\IndexController@comfirm_post')->name('recruit.comfirm_post');
     $router->get('select_result','Web\Recruit\IndexController@select_result')->name('recruit.select_result');
     $router->post('get_select_result','Web\Recruit\IndexController@get_select_result')->name('recruit.get_select_result');
+    $router->get('get_select_result','Web\Recruit\IndexController@get_select_result')->name('recruit.get_select_result');
     $router->post('select_init','Web\Recruit\IndexController@select_init')->name('recruit.select_init');
     $router->get('supplement_info','Web\Recruit\IndexController@supplement_info')->name('recruit.supplement_info');
     $router->post('save_supplement_info','Web\Recruit\IndexController@save_supplement_info')->name('recruit.save_supplement_info');