|
@@ -2641,19 +2641,25 @@ class IndexController extends WebBaseController
|
|
|
}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=3 and a.type=2 and a.status=1')->select(['b.realname','c.ex_number','a.result','a.select_result','a.id'])->orderBy('record','desc')->limit($limit)->get();
|
|
|
+ $limit = $request->input('limit',2);
|
|
|
+ $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')->select(['b.realname','c.ex_number','a.result','a.select_result','a.id'])->orderBy('record','desc')->orderBy('record2','desc')->orderBy('record3','desc')->limit($limit)->get()->toArray();
|
|
|
+ dd($list);
|
|
|
$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){
|
|
|
+ if($v->record == $list[$k+1]->record && $v->record2 == $list[$k+1]->record2 && $v->record3 == $list[$k+1]->record3 && $quota[$index]['value'] == 1){//如果当前人员的分数与下一名人员三个维度完全一样的话,特殊处理
|
|
|
+ //查找同样分数人同样志愿
|
|
|
+
|
|
|
+ }
|
|
|
$quota_data = [
|
|
|
'index' => $index,
|
|
|
'old_value' => $quota[$index]['value']
|