|
|
@@ -135,6 +135,27 @@ class IndexController extends WebBaseController
|
|
|
} else {
|
|
|
$appoint_info->check_ticket = 0;
|
|
|
}
|
|
|
+
|
|
|
+ //20251017增加确认面试功能
|
|
|
+ if ($recruit->face_comfirm) {
|
|
|
+ if ($appoint_info->audit != 3) {//审核未通过,无需确认
|
|
|
+ $appoint_info->face_comfirm = 0;
|
|
|
+ } else {
|
|
|
+ $time = time();
|
|
|
+ if (strtotime($recruit->face_comfirm_start) > $time || strtotime($recruit->face_comfirm_end) < $time) {
|
|
|
+ $appoint_info->face_comfirm = -1; //确认未开始
|
|
|
+ } else {
|
|
|
+ if ($appoint_info->face_audit != -2) {
|
|
|
+ $appoint_info->face_comfirm = -2;//已确认无需再次确认
|
|
|
+ } else {
|
|
|
+ $appoint_info->face_comfirm = 1;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ $appoint_info->face_comfirm = 0;//无需确认
|
|
|
+ }
|
|
|
+
|
|
|
//面试
|
|
|
$face_ticket = RecruitTicket::where('appoint_id', $appoint_info->id)->where('ex_type', 3)->first();
|
|
|
|
|
|
@@ -3030,6 +3051,60 @@ class IndexController extends WebBaseController
|
|
|
|
|
|
}
|
|
|
|
|
|
+ public function comfirm_face(Request $request)
|
|
|
+ {
|
|
|
+ $user = $this->getUser();
|
|
|
+ if (!empty($user)) {
|
|
|
+ $uid = $user->id;
|
|
|
+ } else {
|
|
|
+ return redirect(route('login'));
|
|
|
+ }
|
|
|
+
|
|
|
+ //招考id
|
|
|
+ $id = $request->input('recruit_id', 0);
|
|
|
+ if (!$id) {
|
|
|
+ return ['status' => 0, 'msg' => '请选择报名项目!', 'data' => ''];
|
|
|
+ }
|
|
|
+
|
|
|
+ $recruit = Recruit::find($id);
|
|
|
+ if (!$recruit['status']) {
|
|
|
+ return ['status' => 0, 'msg' => '抱歉,该项目状态不正确,请联系客服!', 'data' => ''];
|
|
|
+ }
|
|
|
+
|
|
|
+ if (!$recruit->face_comfirm) {
|
|
|
+ return ['status' => 0, 'msg' => '该项目无须确认面试考试!', 'data' => ''];
|
|
|
+ }
|
|
|
+
|
|
|
+ $appoint_info = RecruitAppointInfo::where('recruit_id', $id)->where('uid', $uid)->first();
|
|
|
+ if (!$appoint_info) {
|
|
|
+ return ['status' => 0, 'msg' => '找不到您的报名记录,请检查!', 'data' => ''];
|
|
|
+ }
|
|
|
+
|
|
|
+ if ($appoint_info->audit != 3) {
|
|
|
+ return ['status' => 0, 'msg' => '您的报名未审核通过,无需确认!', 'data' => ''];
|
|
|
+ }
|
|
|
+
|
|
|
+ $time = time();
|
|
|
+ if (strtotime($recruit->face_comfirm_start) > $time || strtotime($recruit->face_comfirm_end) < $time) {
|
|
|
+ return ['status' => 0, 'msg' => '未在笔试确认时间段!', 'data' => ''];
|
|
|
+ }
|
|
|
+
|
|
|
+ if ($appoint_info->face_audit != -2) {
|
|
|
+ return ['status' => 0, 'msg' => '您已确认参加面试,无需再次确认!', 'data' => ''];
|
|
|
+ }
|
|
|
+
|
|
|
+ $appoint_info->update(['face_audit' => -1]);
|
|
|
+ $log = [
|
|
|
+ 'type' => 3,
|
|
|
+ 'appoint_id' => $appoint_info->id,
|
|
|
+ 'uid' => $uid,
|
|
|
+ 'log' => '用户确认参加面试',
|
|
|
+ ];
|
|
|
+ RecruitAppointLog::create($log);
|
|
|
+ return ['status' => 1, 'msg' => '确认成功', 'data' => $appoint_info->id];
|
|
|
+
|
|
|
+ }
|
|
|
+
|
|
|
public function supplementary_entry(Request $request)
|
|
|
{
|
|
|
$user = $this->getUser();
|