예제 #1
0
 public function resumeTypeHtml()
 {
     $default_type = array(1 => array('pkid' => 1, 'name' => '中文简历', 'url' => '/Student/like'), 3 => array('pkid' => 3, 'name' => '中/英文简历', 'url' => '/EnStudent/enlike'), 4 => array('pkid' => 4, 'name' => '附件简历', 'url' => '/PageOffice/like'));
     $data = $this->resumeType();
     //是否已经上传了简历附件
     if (isset($data[4])) {
         $upload_file = 1;
     } else {
         $upload_file = 0;
     }
     $default = $this->ResumeModel->resumeDefault();
     //默认投递
     $this->assign('default', $default_type[$default['resume_type']]);
     //做选择数组
     foreach ($default_type as $key => $value) {
         if (empty($data[$key])) {
             unset($default_type[$key]);
         } else {
             if ($key == $default['resume_type']) {
                 unset($default_type[$key]);
             }
         }
     }
     //插件下载链接
     $download_url = 'http://' . C('APP_IP') . ':8080/JavaBridge/posetup.exe';
     $this->assign('default_type', $default_type);
     $this->assign('upload_file', $upload_file);
     $this->assign('pop_show', isset($data[1]) ? 'show' : 'hide');
     //判断是否能够上传简历,先有中文简历后方可上传简历
     $this->assign('data', $data);
     $this->assign('download_url', $download_url);
     $this->assign('browser', checkBrowser());
     $this->assign('cookie_set', cookieUploadCheck());
     return $this->fetch('resume_upload');
 }
예제 #2
0
 public function checkBrowser()
 {
     $check = cookieUploadCheck();
     $url_view = I('post.url');
     if (!$check) {
         if (!empty($url_view)) {
             $this->assign('url_view', $url_view);
         }
         $download_url = 'http://' . C('APP_IP') . ':8080/JavaBridge/posetup.exe';
         $this->assign('download_url', $download_url);
         $html = $this->fetch('/Student/resume_other_box');
         exit(json_encode(array('status' => 'success', 'html' => $html)));
     } else {
         exit(json_encode(array('status' => 'fail')));
     }
 }