| | |
| | | '2'=>'账户被锁定', |
| | | '3'=>'未通过' |
| | | ); |
| | | |
| | | /* 查询数量 */ |
| | | function getResumeNum($Where=array()){ |
| | | return $this->select_num('resume',$Where); |
| | | } |
| | | |
| | | /* 查询简历数 */ |
| | | function getExpectNum($Where=array()){ |
| | | return $this->select_num('resume_expect',$Where); |
| | | } |
| | | |
| | | /** |
| | | * 通过uid查询单条简历。有默认简历返回默认简历;没有默认简历,返回最近更新的简历 |
| | | */ |
| | |
| | | |
| | | return $expect; |
| | | } |
| | | |
| | | private function addErrorLog($uid,$type='',$content) { |
| | | |
| | | require_once ('errlog.model.php'); |
| | |
| | | $LogM = new log_model($this->db, $this->def); |
| | | return $LogM -> addMemberLog($uid,$usertype,$content,$opera,$type); |
| | | } |
| | | |
| | | /** |
| | | * 批量查个人基本信息 |
| | | * @param array $whereData |
| | |
| | | * @param array $data 自定义处理数组 |
| | | * @return array|bool|false|string|void |
| | | */ |
| | | public function getSimpleList($whereData, $data = array()) |
| | | { |
| | | public function getSimpleList($whereData, $data = array()) { |
| | | |
| | | $data['field'] = empty($data['field']) ? '*' : $data['field']; |
| | | $List = $this->select_all('resume_expect', $whereData, $data['field']); |
| | |
| | | |
| | | return $List; |
| | | } |
| | | |
| | | //搜索筛选-简历列表 |
| | | public function searchList($data){ |
| | | |
| | |
| | | $data['zdids']=$zdids; |
| | | return $data; |
| | | } |
| | | |
| | | /** |
| | | * 简历列表 |
| | | * @param array $whereData |
| | | * @param array $data field:查询字段; |
| | | 'utype':列表显示位置,不同的位置可能有不同的需求 ; |
| | | 'cache':页面需要传回缓存 多条数据查询合并, |
| | | withResumeFiled:联合resume表 多条数据查询合并时查询resume表的字段 |
| | | downresume_where:在联合resume表查询时,查询down_resume表的条件 |
| | | search:列表搜索的post值,主要用于列表搜索筛选 |
| | | |
| | | * 'utype':列表显示位置,不同的位置可能有不同的需求 ; |
| | | * 'cache':页面需要传回缓存 多条数据查询合并, |
| | | * withResumeFiled:联合resume表 多条数据查询合并时查询resume表的字段 |
| | | * downresume_where:在联合resume表查询时,查询down_resume表的条件 |
| | | * search:列表搜索的post值,主要用于列表搜索筛选 |
| | | */ |
| | | public function getList($whereData,$data=array('utype'=>'')){ |
| | | |
| | |
| | | * @param null[] $data 自定义处理数组 |
| | | * @return array|bool|false|string|void |
| | | */ |
| | | public function getResumeInfo($whereData, $data = array('logo'=>null)) |
| | | { |
| | | public function getResumeInfo($whereData, $data = array('logo' => null)) { |
| | | |
| | | $data['field'] = empty($data['field']) ? '*' : $data['field']; |
| | | $resumeInfo = $this -> select_once('resume', $whereData, $data['field']); |
| | |
| | | * @param null[] $data | mData member表要修改数据; rData resume表要修改数据; utype 修改操作类型:admin-后台,user-会员中心; port 刷新简历操作端 |
| | | * @return array|string[] |
| | | */ |
| | | public function upResumeInfo($whereData = array(), $data = array('mData' => null, 'rData' => null, 'utype' => null, 'port' => 1)) |
| | | { |
| | | public function upResumeInfo($whereData = array(), $data = array('mData' => null, 'rData' => null, 'utype' => null, 'port' => 1)) { |
| | | |
| | | $return = array(); |
| | | |
| | |
| | | * @param $port |
| | | * @return bool |
| | | */ |
| | | private function setExpectInfo($uid, $rData, $port) |
| | | { |
| | | private function setExpectInfo($uid, $rData, $port) { |
| | | |
| | | $eField = '`sex`,`birthday`,`exp`,`edu`,`uname`,`r_status`,`photo`'; |
| | | $expect = $this->select_once('resume_expect', array('uid' => $uid), $eField); |
| | |
| | | * @param array $data uid=>用户id; eid=>简历id; rfield=>基本信息查询字段; needCache=>需要调用缓存; tb=>查询表范围 |
| | | * @return mixed |
| | | */ |
| | | public function getInfo($data = array('uid'=>null,'eid'=>null,'needCache'=>null,'tb'=>null)) |
| | | { |
| | | |
| | | public function getInfo($data = array('uid' => null, 'eid' => null, 'needCache' => null, 'tb' => null)) { |
| | | if ($data['needCache'] == 1){ |
| | | $cache = $this -> getClass(array('user','city','job','hy','introduce')); |
| | | $return['cache'] = $cache; |
| | |
| | | $eid = intval($data['eid']); |
| | | |
| | | $expect = $this -> getExpect(array('id'=>$eid,'uid'=>$resume['uid']),array('cache'=>$cache,'needCache'=>$data['needCache'])); |
| | | |
| | | //查询所有附表信息 |
| | | if ($expect['id'] && $data['tb'] == 'all'){ |
| | | $edu = $this -> getResumeEdus(array('eid'=>$eid,'uid'=>$resume['uid'],'orderby'=>'sdate,desc'),'*',$cache['userclass_name']); |
| | | |
| | | $other = $this -> getResumeOthers((array('eid'=>$eid,'uid'=>$resume['uid']))); |
| | | |
| | | $project = $this -> getResumeProjects(array('eid'=>$eid,'uid'=>$resume['uid'],'orderby'=>'sdate,desc')); |
| | | |
| | | $skill = $this -> getResumeSkills(array('eid'=>$eid,'uid'=>$resume['uid']),'*',$cache['userclass_name']); |
| | | |
| | | $training = $this -> getResumeTrains(array('eid'=>$eid,'uid'=>$resume['uid'],'orderby'=>'sdate,desc')); |
| | | |
| | | $work = $this -> getResumeWorks(array('eid'=>$eid,'uid'=>$resume['uid'],'orderby'=>'sdate,desc')); |
| | | |
| | | $show = $this -> getResumeShowList(array('eid'=>$eid,'uid'=>$resume['uid'],'orderby'=>'sort,desc')); |
| | | } |
| | | } |
| | |
| | | * @param array $data : uid => 查看用户id; eid=>简历id; field=>基本信息查询字段; cache=>返回包含的缓存数据 |
| | | * @return array|bool|false|string|void |
| | | */ |
| | | public function getInfoByEid($data = array()) |
| | | { |
| | | public function getInfoByEid($data = array()) { |
| | | $res = array(); |
| | | $eid = intval($data['eid']); |
| | | $uid = intval($data['uid']); //查看简历的用户uid |
| | |
| | | |
| | | return $resume; |
| | | } |
| | | |
| | | /** |
| | | * 企业、猎头通过uid查看用户姓名 |
| | | */ |
| | | function getUnameByUid($uid, $data = array()) |
| | | { |
| | | function getUnameByUid($uid, $data = array()) { |
| | | $name = ''; |
| | | if (empty($data['comid']) || empty($data['usertype'])){ |
| | | return $name; |
| | |
| | | } |
| | | return $name; |
| | | } |
| | | |
| | | //个人随机默认头像 |
| | | public function deflogo($data = array()){ |
| | | |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 创建简历字段检测 |
| | | */ |
| | |
| | | |
| | | if (!empty($rData)){ |
| | | |
| | | if($rData['name']=='') {$return['msg'] == '请填写真实姓名';} |
| | | if ($rData['name'] == '') { |
| | | $return['msg'] == '请填写真实姓名'; |
| | | } |
| | | |
| | | if($rData['sex']=='') {$return['msg'] == '请选择性别';} |
| | | if ($rData['sex'] == '') { |
| | | $return['msg'] == '请选择性别'; |
| | | } |
| | | |
| | | if($rData['birthday']=='') {$return['msg'] == '请选择出生年月';} |
| | | if ($rData['birthday'] == '') { |
| | | $return['msg'] == '请选择出生年月'; |
| | | } |
| | | |
| | | if($rData['living']=='') {$return['msg'] == '请填写现居住地';} |
| | | if ($rData['living'] == '') { |
| | | $return['msg'] == '请填写现居住地'; |
| | | } |
| | | |
| | | if($rData['edu']=='') {$return['msg'] == '请选择最高学历';} |
| | | if ($rData['edu'] == '') { |
| | | $return['msg'] == '请选择最高学历'; |
| | | } |
| | | |
| | | if($rData['exp']=='') {$return['msg'] == '请选择工作经验';} |
| | | if ($rData['exp'] == '') { |
| | | $return['msg'] == '请选择工作经验'; |
| | | } |
| | | |
| | | if($rData['telphone']=='') {$return['msg'] == '请填写手机号码';} |
| | | if ($rData['telphone'] == '') { |
| | | $return['msg'] == '请填写手机号码'; |
| | | } |
| | | } |
| | | |
| | | if (!empty($eData)){ |
| | | |
| | | if($eData['name']=='') {$return['msg'] == '请填写期望职位';} |
| | | if ($eData['name'] == '') { |
| | | $return['msg'] == '请填写期望职位'; |
| | | } |
| | | |
| | | if($eData['hy']=='') {$return['msg'] == '请选择从事行业';} |
| | | if ($eData['hy'] == '') { |
| | | $return['msg'] == '请选择从事行业'; |
| | | } |
| | | |
| | | if($eData['job_class']=='') {$return['msg'] == '请选择期望职位';} |
| | | if ($eData['job_class'] == '') { |
| | | $return['msg'] == '请选择期望职位'; |
| | | } |
| | | |
| | | if($eData['minsalary']=='') {$return['msg'] == '请填写期望薪资';} |
| | | if ($eData['minsalary'] == '') { |
| | | $return['msg'] == '请填写期望薪资'; |
| | | } elseif ($eData['maxsalary'] > 0 && (int)$eData['minsalary'] > (int)$eData['maxsalary']) { |
| | | $return['msg'] == '最高薪资必须大于最低薪资'; |
| | | } |
| | | |
| | | elseif($eData['maxsalary']>0 && (int)$eData['minsalary'] > (int)$eData['maxsalary']){$return['msg'] == '最高薪资必须大于最低薪资';} |
| | | if ($eData['city_class'] == '') { |
| | | $return['msg'] == '请选择工作地区'; |
| | | } |
| | | |
| | | if($eData['city_class']==''){$return['msg'] == '请选择工作地区';} |
| | | if ($eData['type'] == '') { |
| | | $return['msg'] == '请选择工作性质'; |
| | | } |
| | | |
| | | if($eData['type']=='') {$return['msg'] == '请选择工作性质';} |
| | | if ($eData['report'] == '') { |
| | | $return['msg'] == '请选择到岗时间'; |
| | | } |
| | | |
| | | if($eData['report']=='') {$return['msg'] == '请选择到岗时间';} |
| | | |
| | | if($eData['jobstatus']=='') {$return['msg'] == '请选择求职状态';} |
| | | if ($eData['jobstatus'] == '') { |
| | | $return['msg'] == '请选择求职状态'; |
| | | } |
| | | } |
| | | |
| | | if (!empty($workData)){ |
| | | |
| | | if($workData['workname']=='') {$return['msg'] == '请填写公司名称';} |
| | | if ($workData['workname'] == '') { |
| | | $return['msg'] == '请填写公司名称'; |
| | | } |
| | | |
| | | if($workData['worksdate']==''){$return['msg'] == '请填写工作时间';} |
| | | if ($workData['worksdate'] == '') { |
| | | $return['msg'] == '请填写工作时间'; |
| | | } |
| | | |
| | | if($workData['worktitle']==''){$return['msg'] == '请填写公司职务';} |
| | | if ($workData['worktitle'] == '') { |
| | | $return['msg'] == '请填写公司职务'; |
| | | } |
| | | |
| | | if($workData['workedate'] < $workData['worksdate']){$return['msg'] == '工作时间不合理';} |
| | | if ($workData['workedate'] < $workData['worksdate']) { |
| | | $return['msg'] == '工作时间不合理'; |
| | | } |
| | | } |
| | | |
| | | if (!empty($eduData)){ |
| | | |
| | | if($eduData['eduname']=='') {$return['msg'] == '请填写学校名称';} |
| | | if ($eduData['eduname'] == '') { |
| | | $return['msg'] == '请填写学校名称'; |
| | | } |
| | | |
| | | if($eduData['edusdate']=='') {$return['msg'] == '请填写在校时间';} |
| | | if ($eduData['edusdate'] == '') { |
| | | $return['msg'] == '请填写在校时间'; |
| | | } |
| | | |
| | | if($eduData['eduedate']=='') {$return['msg'] == '请填写离校或预计离校时间';} |
| | | if ($eduData['eduedate'] == '') { |
| | | $return['msg'] == '请填写离校或预计离校时间'; |
| | | } |
| | | |
| | | if($eduData['education']==''){$return['msg'] == '请选择相关学历';} |
| | | if ($eduData['education'] == '') { |
| | | $return['msg'] == '请选择相关学历'; |
| | | } |
| | | |
| | | if($eduData['eduspec']=='') {$return['msg'] == '请填写相关专业';} |
| | | if ($eduData['eduspec'] == '') { |
| | | $return['msg'] == '请填写相关专业'; |
| | | } |
| | | |
| | | if($eduData['eduedate'] < $eduData['edusdate']){$return['msg'] == '在校时间不合理';} |
| | | if ($eduData['eduedate'] < $eduData['edusdate']) { |
| | | $return['msg'] == '在校时间不合理'; |
| | | } |
| | | } |
| | | |
| | | if (!empty($proData)){ |
| | | |
| | | if($proData['proname']=='') {$return['msg'] == '请填写项目名称';} |
| | | if ($proData['proname'] == '') { |
| | | $return['msg'] == '请填写项目名称'; |
| | | } |
| | | |
| | | if($proData['prosdate']==''){$return['msg'] == '请填写项目开始时间';} |
| | | if ($proData['prosdate'] == '') { |
| | | $return['msg'] == '请填写项目开始时间'; |
| | | } |
| | | |
| | | if($proData['proedate']==''){$return['msg'] == '请填写项目结束时间';} |
| | | if ($proData['proedate'] == '') { |
| | | $return['msg'] == '请填写项目结束时间'; |
| | | } |
| | | |
| | | if($proData['protitle']==''){$return['msg'] == '请填写项目担任职务';} |
| | | if ($proData['protitle'] == '') { |
| | | $return['msg'] == '请填写项目担任职务'; |
| | | } |
| | | |
| | | if($eduData['proedate'] < $eduData['prosdate']){$return['msg'] == '项目时间不合理';} |
| | | if ($eduData['proedate'] < $eduData['prosdate']) { |
| | | $return['msg'] == '项目时间不合理'; |
| | | } |
| | | } |
| | | return $return; |
| | | } |
| | |
| | | * @param $post |
| | | * @return array |
| | | */ |
| | | public function addDocInfo($post) |
| | | { |
| | | public function addDocInfo($post) { |
| | | |
| | | $eid = intval($post['eid']); |
| | | $uid = intval($post['uid']); |
| | |
| | | * @param array $data | port 刷新端口 sxlog: 1-需要添加刷新日志; |
| | | * @return boolean | $return |
| | | */ |
| | | public function upInfo($whereData, $data = array('eData' => null, 'utype' => null, 'port' => 1, 'sxlog' => null)) |
| | | { |
| | | public function upInfo($whereData, $data = array('eData' => null, 'utype' => null, 'port' => 1, 'sxlog' => null)) { |
| | | |
| | | if (!empty($whereData)) { |
| | | |
| | |
| | | * @param array $data |
| | | * @return array |
| | | */ |
| | | public function getExpect($whereData,$data = array()) |
| | | { |
| | | public function getExpect($whereData, $data = array()) { |
| | | |
| | | $field = isset($data['field']) ? $data['field'] : '*'; |
| | | |
| | |
| | | |
| | | return $edu; |
| | | } |
| | | |
| | | /** |
| | | * 查询多个教育经历 $userclass_name 个人缓存,调用方法里已经有缓存的,可以先对学历进行处理 |
| | | */ |
| | |
| | | |
| | | return $edus; |
| | | } |
| | | |
| | | //添加/修改 教育经历 |
| | | public function addResumeEdu($addData,$data = array()){ |
| | | |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | //查询单条其他描述 |
| | | public function getResumeOther($where = array(), $field = '*'){ |
| | | |
| | |
| | | } |
| | | return $others; |
| | | } |
| | | |
| | | //添加/修改 其他描述 |
| | | public function addResumeOther($addData,$data = array()){ |
| | | |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | //查询单条项目经历 |
| | | public function getResumeProject($where = array(), $field = '*'){ |
| | | |
| | |
| | | |
| | | return $project; |
| | | } |
| | | |
| | | //查询多条项目经历 |
| | | public function getResumeProjects($where = array(), $field = '*'){ |
| | | |
| | |
| | | |
| | | return $projects; |
| | | } |
| | | |
| | | //添加/修改 项目经历 |
| | | public function addResumeProject($addData,$data = array()){ |
| | | |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | //查询单条职业技能 |
| | | public function getResumeSkill($where = array(), $field = '*', $userclass_name = null){ |
| | | |
| | |
| | | |
| | | return $skill; |
| | | } |
| | | |
| | | //查询多条职业技能 |
| | | public function getResumeSkills($where = array(), $field = '*', $userclass_name = null){ |
| | | $cache = $this -> getClass(array('user')); |
| | |
| | | } |
| | | return $skills; |
| | | } |
| | | |
| | | //添加/修改 职业技能 |
| | | public function addResumeSkill($addData,$data = array()){ |
| | | |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | //查询单条培训经历 |
| | | public function getResumeTrain($where = array(), $field = '*'){ |
| | | |
| | |
| | | |
| | | return $training; |
| | | } |
| | | |
| | | //查询多条培训经历 |
| | | public function getResumeTrains($where = array(), $field = '*'){ |
| | | |
| | |
| | | |
| | | return $trainings; |
| | | } |
| | | |
| | | //添加/修改 培训经历 |
| | | public function addResumeTrain($addData,$data = array()){ |
| | | |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | //查询单个工作经历 |
| | | public function getResumeWork($where = array(), $field = '*'){ |
| | | |
| | |
| | | * @param string $field |
| | | * @return array|bool|false|string|void |
| | | */ |
| | | public function getResumeWorks($where = array(), $field = '*') |
| | | { |
| | | |
| | | public function getResumeWorks($where = array(), $field = '*') { |
| | | $works = $this->select_all('resume_work', $where, $field); |
| | | |
| | | if ($works) { |
| | | foreach ($works as $k => $v) { |
| | | |
| | | $works[$k]['content'] = str_replace('\r\n', '<br/>', strip_tags($v['content'], '\r\n')); |
| | | $works[$k]['content'] = $v['content'] ? str_replace('\r\n', '<br/>', strip_tags($v['content'], '\r\n')) : ""; |
| | | $works[$k]['sdate_n'] = date('Y-m', $v['sdate']); |
| | | $works[$k]['edate_n'] = $v['edate'] == 0 ? '至今' : date('Y-m', $v['edate']); |
| | | $works[$k]['date_n'] = $works[$k]['sdate_n'] . '-' . $works[$k]['edate_n']; |
| | | if ($v['edate'] == 0) { |
| | | |
| | | $works[$k]['time_n']= $this->computeTime(time() - $v['sdate']); |
| | | } else { |
| | | |
| | | $works[$k]['time_n']= $this->computeTime($v['edate'] - $v['sdate']); |
| | | } |
| | | } |
| | | } |
| | | return $works; |
| | |
| | | * @param $timesDiff |
| | | * @return string |
| | | */ |
| | | private function computeTime($timesDiff) |
| | | { |
| | | private function computeTime($timesDiff) { |
| | | |
| | | $avgHour = ceil($timesDiff / (86400 * 30)); |
| | | |
| | | if ($avgHour > 11) { |
| | | |
| | | $time = $avgHour > 11 ? avgToYm($avgHour) : $avgHour; |
| | | |
| | | if (bcmod($avgHour, 12) > 0) { |
| | | |
| | | return $time . '个月'; |
| | | } else { |
| | | |
| | | return $time; |
| | | } |
| | | } else if($avgHour > 0){ |
| | | if ($avgHour > 0) { |
| | | |
| | | return $avgHour . '个月'; |
| | | } else { |
| | |
| | | |
| | | return $this -> select_once('resume_doc', $where, $field); |
| | | } |
| | | |
| | | //添加/修改 工作经历 |
| | | public function addResumeWork($addData,$data = array()){ |
| | | |
| | |
| | | } |
| | | return $info; |
| | | } |
| | | public function getFbList($type, $where) |
| | | { |
| | | |
| | | public function getFbList($type, $where) { |
| | | |
| | | $table = 'resume_'.$type; |
| | | |
| | |
| | | |
| | | return $list; |
| | | } |
| | | |
| | | /** |
| | | * 删除简历附表 |
| | | * @param string $table 'work' |
| | |
| | | return $success; |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 简历附表处理完成的返回值处理 |
| | | * @param string $fbName 'work' |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | //简历附表名称处理 |
| | | private function getFbName($fb){ |
| | | $tname = array( |
| | |
| | | $resumeInfo = $this -> select_once('user_resume', $whereData, $data['field']); |
| | | return $resumeInfo; |
| | | } |
| | | |
| | | /** |
| | | * 修改简历完整度 |
| | | * 参数格式 |
| | |
| | | $this->update_once('resume_expect',array('integrity'=>$integrity),array('id'=>$whereData['eid'])); |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * @desc 简历审核,个人不是已审核状态,弹出同步操作状态审核 |
| | | * @param int $id |
| | |
| | | * @param array $data |
| | | * @return mixed |
| | | */ |
| | | public function refreshResume($id) |
| | | { |
| | | public function refreshResume($id) { |
| | | |
| | | $id = @explode(',', $id); |
| | | |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 置顶简历 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 后台简历备注 |
| | | * @param string $id 格式:如1 ; |
| | |
| | | return $return; |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 删除简历 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | //删除简历时修改默认简历,并处理与uid相关数据 |
| | | private function upDefaults($list = array()){ |
| | | |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 后台个人认证审核 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 删除个人身份验证 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 后台个人头像审核 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 后台个人作品审核 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | }elseif($post['status'] == 0){ |
| | | $result = $this -> update_once('resume_show', $post, array('id'=>array('in',$idstr))); |
| | | } |
| | | |
| | | |
| | | |
| | | if ($result){ |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 修改个人头像 |
| | | * @param array $whereData |
| | | * @param array $data photo/需上传的图片文件; thumb/已处理好的缩略图; utype/操作的用户类型; base/需上传的base4图片; preview/pc预览即上传 |
| | | */ |
| | | public function upPhoto($whereData = array(),$data=array('photo'=>null,'thumb'=>null,'utype'=>null,'base'=>null,'preview'=>null)) |
| | | { |
| | | public function upPhoto($whereData = array(), $data = array('photo' => null, 'thumb' => null, 'utype' => null, 'base' => null, 'preview' => null)) { |
| | | |
| | | if (!empty($whereData['uid'])){ |
| | | |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 修改个人二维码 |
| | | * @param array $whereData |
| | | * @param array $data photo/需上传的图片文件; base/需上传的base4图片; preview/pc预览即上传 |
| | | */ |
| | | public function upEwm($whereData = array(),$data=array('photo'=>null,'base'=>null,'preview'=>null)) |
| | | { |
| | | public function upEwm($whereData = array(), $data = array('photo' => null, 'base' => null, 'preview' => null)) { |
| | | if (!empty($whereData['uid'])){ |
| | | |
| | | $uid = $whereData['uid']; |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 内容检测 |
| | | */ |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | return $pass; |
| | | } |
| | | |
| | | function infoConCheck($userdata,$data){ |
| | | |
| | | require_once('concheck.model.php'); |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | $check_con_data = array( |
| | | 'type' => 'text', |
| | | 'uid' => $data['uid'], |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | return $pass; |
| | | } |
| | | |
| | | /** |
| | | * 删除个人头像 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | * @param array $data |
| | | * @return array|bool|false|string|void |
| | | */ |
| | | public function getResumeShowList($whereData = array(), $data = array('field' => null, 'utype' => null)) |
| | | { |
| | | public function getResumeShowList($whereData = array(), $data = array('field' => null, 'utype' => null)) { |
| | | |
| | | $field = $data['field'] ? $data['field'] : '*'; |
| | | |
| | |
| | | * @param array $data |
| | | * @return bool |
| | | */ |
| | | public function addResumeShow($data = array()) |
| | | { |
| | | public function addResumeShow($data = array()) { |
| | | $post = $data['post']; |
| | | if(isset($data['file']) && $data['file']['tmp_name']!=''){ |
| | | // pc端上传 |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 处理单个图片上传 |
| | | * @param file/需上传文件; dir/上传目录; type/上传图片类型; base/需上传base64; preview/pc预览即上传 |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 处理搜索用简历多城市、多职位记录 |
| | | */ |
| | | private function city_job($eid, $uid, $lastupdate, $nowCity, $nowJob, $oldCity = '', $oldJob = '') |
| | | { |
| | | private function city_job($eid, $uid, $lastupdate, $nowCity, $nowJob, $oldCity = '', $oldJob = '') { |
| | | |
| | | $resume_city = $this->addCityclass($eid, $uid, $nowCity); |
| | | $resume_job = $this->addJobclass($eid, $uid, $nowJob); |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 获取职位、城市字段出现字数 |
| | | */ |
| | | private function getNum($id = '', $idarr = array(), $numarr = array()) |
| | | { |
| | | private function getNum($id = '', $idarr = array(), $numarr = array()) { |
| | | $num = in_array($id, $idarr) && isset($numarr[$id]) ? $numarr[$id] + 1 : 1; |
| | | |
| | | return $num; |
| | | } |
| | | |
| | | /** |
| | | * 处理简历多城市的添加、修改 |
| | | */ |
| | | private function addCityclass($eid, $uid, $nowCity, $oldCity = '') |
| | | { |
| | | private function addCityclass($eid, $uid, $nowCity, $oldCity = '') { |
| | | $resume_city = $city_sort = array(); |
| | | if (!empty($eid) && !empty($uid) && !empty($nowCity)){ |
| | | $cityArr = @explode(',', $nowCity); |
| | |
| | | } |
| | | return $resume_city; |
| | | } |
| | | |
| | | /** |
| | | * 处理简历多职位的添加、修改 |
| | | */ |
| | |
| | | } |
| | | return $resume_job; |
| | | } |
| | | public function getCityclassList($whereData = array(),$data=array()) |
| | | { |
| | | |
| | | public function getCityclassList($whereData = array(), $data = array()) { |
| | | $field = !empty($data['field']) ? $data['field'] : '*'; |
| | | $rows = $this -> select_all('resume_cityclass',$whereData,$field); |
| | | |
| | |
| | | return $rows; |
| | | } |
| | | |
| | | public function getJobclassList($whereData = array()) |
| | | { |
| | | public function getJobclassList($whereData = array()) { |
| | | |
| | | $rows = $this -> select_all('resume_jobclass',$whereData); |
| | | |
| | | return $rows; |
| | | } |
| | | private function getClass($options) |
| | | { |
| | | |
| | | private function getClass($options) { |
| | | if (!empty($options)){ |
| | | |
| | | include_once('cache.model.php'); |
| | |
| | | |
| | | return $List; |
| | | } |
| | | |
| | | //后台列表处理简历多城市/用户名、审核状态 |
| | | private function getDataList($List,$cache) |
| | | { |
| | | private function getDataList($List, $cache) { |
| | | foreach ($List as $v) { |
| | | |
| | | $uids[] = $v['uid']; |
| | |
| | | } |
| | | |
| | | //计算工作经历工作时长 |
| | | private function workTime($eid) |
| | | { |
| | | private function workTime($eid) { |
| | | $workList = $this -> getResumeWorks(array('eid'=>$eid),'sdate,edate'); |
| | | $whour = 0; |
| | | $hour = array(); |
| | |
| | | return $List; |
| | | |
| | | } |
| | | |
| | | /** |
| | | * @desc 收藏人才列表信息补充完善 |
| | | */ |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * @desc 收藏人才列表数量 |
| | | */ |
| | |
| | | return $this -> select_num('talent_pool',$whereData); |
| | | |
| | | } |
| | | |
| | | /** |
| | | * 收藏简历 |
| | | */ |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 添加收藏简历备注 |
| | | */ |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 添加收到简历备注 |
| | | */ |
| | |
| | | /** |
| | | * 设置姓名展示 |
| | | */ |
| | | public function setUsernameShow($data = array()) |
| | | { |
| | | public function setUsernameShow($data = array()) { |
| | | $resUserName = ''; |
| | | if(empty($this -> config['user_name']) || $this -> config['user_name'] == 1){ |
| | | |
| | |
| | | /** |
| | | * 设置简历头像展示 |
| | | */ |
| | | public function setResumePhotoShow($data = array()) |
| | | { |
| | | public function setResumePhotoShow($data = array()) { |
| | | $resumePhoto = ''; |
| | | $maleUrl = checkpic('',$this -> config['sy_member_icon']); |
| | | $femaleUrl = checkpic('',$this -> config['sy_member_iconv']); |
| | |
| | | } |
| | | return $resumePhoto; |
| | | } |
| | | |
| | | //更新职位点击率 |
| | | function addExpectHits($id){ |
| | | if($this -> config['sy_job_hits'] > 100 || !$this -> config['sy_job_hits']){ |
| | |
| | | * @param array $odata |
| | | * @return bool |
| | | */ |
| | | function upResumeTable($table, $whereData, $data, $odata = array()) |
| | | { |
| | | function upResumeTable($table, $whereData, $data, $odata = array()) { |
| | | |
| | | if (!empty($whereData)) { |
| | | |
| | |
| | | return $List; |
| | | |
| | | } |
| | | |
| | | /** |
| | | * 添加简历外发 |
| | | */ |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 删除简历外发记录 |
| | | * @param string $id 格式:单个,如1 ; 批量,如1,2,3 |
| | |
| | | } |
| | | return $return; |
| | | } |
| | | |
| | | //简历分布定价,按照时间分别定价 |
| | | function setDayprice($eid,$data=array()){ |
| | | |
| | |
| | | |
| | | return $type; |
| | | } |
| | | |
| | | /** |
| | | * 用户设置默认简历 |
| | | */ |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * 获取temporary_resume 详情 |
| | | * $whereData 查询条件 |
| | |
| | | } |
| | | return $Info; |
| | | } |
| | | |
| | | /** |
| | | * 删除temporary_resume 详情 |
| | | * $whereData 查询条件 |
| | |
| | | $nid = $this -> delete_all('temporary_resume', $whereData, ''); |
| | | return $nid; |
| | | } |
| | | |
| | | /** |
| | | * 添加temporary_resume |
| | | * $data 插入数据 |
| | |
| | | $nid = $this -> insert_into('temporary_resume',$data); |
| | | return $nid; |
| | | } |
| | | |
| | | // 简历置顶检测 |
| | | public function topResumeCheck($data = array('eid'=>null,'uid'=>null)){ |
| | | |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | /** |
| | | * @desc 简历匹配职位 |
| | | * @param array $data |
| | |
| | | 'field' => 'pre', //排序字段 |
| | | ); |
| | | $arrSort = array(); |
| | | foreach($job AS $uniqid => $row){ |
| | | foreach ($job as $uniqid => $row) { |
| | | |
| | | foreach($row AS $key=>$value){ |
| | | foreach ($row as $key => $value) { |
| | | |
| | | $arrSort[$key][$uniqid] = $value; |
| | | } |
| | |
| | | } |
| | | return $job; |
| | | } |
| | | |
| | | /*会员添加简历页面,添加前检查是否满足各项条件,例如简历数,并返回部分基本信息 |
| | | needcache:是否需要缓存,$from:默认pc:为pc端,wap:wap端,wxapp:小程序端 |
| | | **/ |
| | |
| | | } |
| | | |
| | | } |
| | | |
| | | /*会员添加简历页面,添加前检查是否满足各项条件,例如身份认证和简历数,并返回部分基本信息 |
| | | needcache:是否需要缓存,$from:默认pc:pc端,wap:wap端,wxapp:小程序端 |
| | | **/ |
| | |
| | | } |
| | | return $List; |
| | | } |
| | | |
| | | /* |
| | | * 获取简历的原始数据,类别汉字化处理,$data中定义获取哪些表,all=1为全部 |
| | | */ |
| | |
| | | |
| | | return $return; |
| | | } |
| | | |
| | | public function getResumeCityClassList($whereData,$data=array()){ |
| | | $field = $data['field'] ? $data['field'] : '*'; |
| | | $List = $this -> select_all('resume_cityclass',$whereData,$field); |
| | |
| | | } |
| | | |
| | | //发布工具搜索 |
| | | public function Getresume($where = array(),$data = array()) |
| | | { |
| | | public function Getresume($where = array(), $data = array()) { |
| | | |
| | | $lists = $this->select_all('resume_expect',$where,'`id`'); |
| | | |
| | |
| | | return $lists; |
| | | } |
| | | |
| | | public function updateExpect($data = array(), $where = array()) |
| | | { |
| | | public function updateExpect($data = array(), $where = array()) { |
| | | |
| | | if (!empty($where)) { |
| | | $this->update_once('resume_expect', $data, $where); |
| | | } |
| | | } |
| | | |
| | | public function setExpectState($data = array(), $where = array()) |
| | | { |
| | | public function setExpectState($data = array(), $where = array()) { |
| | | |
| | | if (!empty($where)) { |
| | | |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | ?> |