|
@@ -251,7 +251,7 @@ class RecruitController extends Controller
|
|
|
$form->number('ordid', '排序')->default(0);
|
|
|
$form->multipleFile('addFile', '附件')->move('storage/app/public/recruit/' . time());
|
|
|
})->tab('报名表单与条件', function ($form) {
|
|
|
- $form->checkbox('forms', '报名表单模块')->options(['basic' => '基础信息模块','expand_special' => '扩展模块-加分','detail' => '详情介绍模块','identification' => '身份证明上传模块','education_certification' => '学历证明上传模块','other_certification' => '其他证明上传模块', 'remark' => '备注模块','chengnuoshu'=>'诚信承诺书','shixin'=>'失信被执行人查询信息页扫描件','baokaoshengming' => '报考声明书','internship' => '实习专场'])->default(['basic'])->setMustMark();
|
|
|
+ $form->checkbox('forms', '报名表单模块')->options(['basic' => '基础信息模块','expand_special' => '扩展模块-加分','detail' => '详情介绍模块','identification' => '身份证明上传模块','education_certification' => '学历证明上传模块','other_certification' => '其他证明上传模块','hj_certification' => '户籍证明上传模块', 'remark' => '备注模块','chengnuoshu'=>'诚信承诺书','shixin'=>'失信被执行人查询信息页扫描件','baokaoshengming' => '报考声明书','internship' => '实习专场'])->default(['basic'])->setMustMark();
|
|
|
$str = "let num = $(\"#forms\").find(\".checked\").length;
|
|
|
if(num == 0){
|
|
|
alert(\"未选中报名表单模块\");
|
|
@@ -932,6 +932,7 @@ class RecruitController extends Controller
|
|
|
'identification'=>[],
|
|
|
'education_certification'=>[],
|
|
|
'other_certification'=>[],
|
|
|
+ 'hj_certification'=>[],
|
|
|
];
|
|
|
|
|
|
if(in_array('expand_special',$recruit->forms)){
|
|
@@ -958,7 +959,7 @@ class RecruitController extends Controller
|
|
|
$data->material = [];
|
|
|
}
|
|
|
}
|
|
|
- if(in_array('identification',$recruit->forms) || in_array('internship',$recruit->forms)){
|
|
|
+ if(in_array('identification',$recruit->forms)){
|
|
|
if(json_decode($data->identification)){
|
|
|
$data->identification = json_decode($data->identification);
|
|
|
$photo_data = [];
|
|
@@ -981,7 +982,7 @@ class RecruitController extends Controller
|
|
|
$data->identification = [];
|
|
|
}
|
|
|
}
|
|
|
- if(in_array('education_certification',$recruit->forms) || in_array('internship',$recruit->forms)){
|
|
|
+ if(in_array('education_certification',$recruit->forms)){
|
|
|
if(json_decode($data->education_certification)){
|
|
|
$data->education_certification = json_decode($data->education_certification);
|
|
|
$photo_data = [];
|
|
@@ -1004,7 +1005,7 @@ class RecruitController extends Controller
|
|
|
$data->education_certification = [];
|
|
|
}
|
|
|
}
|
|
|
- if(in_array('other_certification',$recruit->forms) || in_array('internship',$recruit->forms)){
|
|
|
+ if(in_array('other_certification',$recruit->forms)){
|
|
|
if(json_decode($data->other_certification)){
|
|
|
$data->other_certification = json_decode($data->other_certification);
|
|
|
$photo_data = [];
|
|
@@ -1027,6 +1028,29 @@ class RecruitController extends Controller
|
|
|
$data->other_certification = [];
|
|
|
}
|
|
|
}
|
|
|
+ if(in_array('hj_certification',$recruit->forms)){
|
|
|
+ if(json_decode($data->hj_certification)){
|
|
|
+ $data->hj_certification = json_decode($data->hj_certification);
|
|
|
+ $photo_data = [];
|
|
|
+ foreach ($data->hj_certification as $k => $v) {
|
|
|
+ if($v->status){
|
|
|
+ $photo_data[] = [
|
|
|
+ 'alt' => $v->name,
|
|
|
+ 'pid' => $v->uid,
|
|
|
+ 'src' => $v->response->path,
|
|
|
+ ];
|
|
|
+ }
|
|
|
+ }
|
|
|
+ $photos['hj_certification'] = [
|
|
|
+ 'title' => '户籍证明',
|
|
|
+ 'id' => 1,
|
|
|
+ 'start' => 0,
|
|
|
+ 'data' =>$photo_data
|
|
|
+ ];
|
|
|
+ }else{
|
|
|
+ $data->hj_certification = [];
|
|
|
+ }
|
|
|
+ }
|
|
|
if(in_array('chengnuoshu',$recruit->forms)){
|
|
|
if(json_decode($data->chengnuoshu)){
|
|
|
$data->chengnuoshu = json_decode($data->chengnuoshu);
|
|
@@ -2229,6 +2253,23 @@ class RecruitController extends Controller
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+ if(in_array('hj_certification',explode(',', $recruit->forms))){
|
|
|
+ $hj_certification = json_decode($value->hj_certification,true);
|
|
|
+ if($hj_certification){
|
|
|
+ foreach ($hj_certification as $k => $v){
|
|
|
+ if(array_key_exists('response',$v) && array_key_exists('path',$v['response'])){
|
|
|
+ $old_path = base_path() . "/public/" . $v['response']['path'];
|
|
|
+ }else{
|
|
|
+ $old_path = base_path() . "/public/" . $v['url'];
|
|
|
+ }
|
|
|
+ if (file_exists($old_path)) {
|
|
|
+ $basename = basename($old_path);
|
|
|
+ $new_path = $path . $basename; //iconv("UTF-8", "GBK", $p->picture_name);
|
|
|
+ copy($old_path, $new_path); //拷贝到新目录
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
if(empty($value->word_url)){
|
|
|
$value->word_url = $this->fetch_word(['recruit_id'=>$recruit_id,'appoint_id'=>$value->id]);
|
|
|
}
|
|
@@ -2363,6 +2404,9 @@ class RecruitController extends Controller
|
|
|
if(in_array('other_certification',explode(',', $recruit->forms)) || in_array('internship',explode(',', $recruit->forms))){
|
|
|
$header[] = '其他证明';
|
|
|
}
|
|
|
+ if(in_array('hj_certification',explode(',', $recruit->forms)) || in_array('internship',explode(',', $recruit->forms))){
|
|
|
+ $header[] = '户籍证明';
|
|
|
+ }
|
|
|
if(in_array('chengnuoshu',explode(',', $recruit->forms))){
|
|
|
$header[] = '诚信承诺书';
|
|
|
}
|
|
@@ -2615,6 +2659,20 @@ class RecruitController extends Controller
|
|
|
}
|
|
|
array_push($item, implode("\r\n", $other_certifications));
|
|
|
}
|
|
|
+ if (in_array('hj_certification', explode(',', $recruit->forms))) {
|
|
|
+ $hj_certification = json_decode($v->hj_certification, true);
|
|
|
+ $hj_certifications = [];
|
|
|
+ if(is_array($hj_certification)){
|
|
|
+ if($hj_certification){
|
|
|
+ foreach ($hj_certification as $val){
|
|
|
+ if(array_key_exists('path', $val['response'])){
|
|
|
+ array_push($hj_certifications,"https://www.jucai.gov.cn" . $val['response']['path']);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ array_push($item, implode("\r\n", $hj_certifications));
|
|
|
+ }
|
|
|
if (in_array('chengnuoshu', explode(',', $recruit->forms))) {
|
|
|
$chengnuoshu = json_decode($v->chengnuoshu, true);
|
|
|
$chengnuoshu = [];
|