CompanyPro Table + systemwide fix
This commit is contained in:
parent
809554fcc8
commit
32c041b795
|
@ -19,8 +19,11 @@ class JobController extends AppController {
|
||||||
* @throws NotFoundException When the view file could not be found
|
* @throws NotFoundException When the view file could not be found
|
||||||
* or MissingViewException in debug mode.
|
* or MissingViewException in debug mode.
|
||||||
*/
|
*/
|
||||||
private $OPENING_COUNT_GAP = 2;
|
private $OPENING_COUNT_GAP = 1;
|
||||||
|
|
||||||
|
private function allowOpening($c,$diff=0){
|
||||||
|
return ((count($c['DreamjobJobOpening'])+$diff) >= (($this->OPENING_COUNT_GAP < $c['Pro']['opening_count'])?$c['Pro']['opening_count']:$this->OPENING_COUNT_GAP));
|
||||||
|
}
|
||||||
|
|
||||||
public function openingList() {
|
public function openingList() {
|
||||||
$this->MiconwareSession->init($this);
|
$this->MiconwareSession->init($this);
|
||||||
|
@ -60,7 +63,7 @@ class JobController extends AppController {
|
||||||
if ($this->request->is('post')) {
|
if ($this->request->is('post')) {
|
||||||
$this->DreamjobJobOpening->create($this->request->data);
|
$this->DreamjobJobOpening->create($this->request->data);
|
||||||
$this->DreamjobJobOpening->data['DreamjobJobOpening']['company_id'] = $c['AppUser']['id'];
|
$this->DreamjobJobOpening->data['DreamjobJobOpening']['company_id'] = $c['AppUser']['id'];
|
||||||
if(count($c['DreamjobJobOpening']) >= $this->OPENING_COUNT_GAP and !(strlen($c['DreamjobCompany']['bank_details'])>0)){
|
if(!$this->allowOpening($c)){
|
||||||
$this->DreamjobJobOpening->data['DreamjobJobOpening']['active'] = false;
|
$this->DreamjobJobOpening->data['DreamjobJobOpening']['active'] = false;
|
||||||
}
|
}
|
||||||
if ($this->DreamjobJobOpening->save()) {
|
if ($this->DreamjobJobOpening->save()) {
|
||||||
|
@ -71,9 +74,7 @@ class JobController extends AppController {
|
||||||
$this->MiconwareSession->setFlash(__('dreamjob.opening.save.error'), 'flash', array('alert' => 'danger'));
|
$this->MiconwareSession->setFlash(__('dreamjob.opening.save.error'), 'flash', array('alert' => 'danger'));
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
if(strlen($c['DreamjobCompany']['bank_details']) > 0){
|
if(!$this->allowOpening($c,-1))
|
||||||
$this->MiconwareSession->setFlash(__('dreamjob.opening.count.thanks'), 'flash', array('alert' => 'success'));
|
|
||||||
}else if(count($c['DreamjobJobOpening']) >= $this->OPENING_COUNT_GAP)
|
|
||||||
$this->MiconwareSession->setFlash(__('dreamjob.opening.count'), 'flash', array('alert' => 'danger'));
|
$this->MiconwareSession->setFlash(__('dreamjob.opening.count'), 'flash', array('alert' => 'danger'));
|
||||||
$this->request->data['DreamjobJobOpening']['active']=true;
|
$this->request->data['DreamjobJobOpening']['active']=true;
|
||||||
}
|
}
|
||||||
|
@ -111,10 +112,13 @@ class JobController extends AppController {
|
||||||
$this->DreamjobJobOpening->create($this->request->data);
|
$this->DreamjobJobOpening->create($this->request->data);
|
||||||
$this->DreamjobJobOpening->data['DreamjobJobOpening']['id'] = $this->request->params['id'];
|
$this->DreamjobJobOpening->data['DreamjobJobOpening']['id'] = $this->request->params['id'];
|
||||||
$this->DreamjobJobOpening->data['DreamjobJobOpening']['company_id'] = $cid;
|
$this->DreamjobJobOpening->data['DreamjobJobOpening']['company_id'] = $cid;
|
||||||
if(count($a['DreamjobJobOpening']) > $this->OPENING_COUNT_GAP and !($this->DreamjobJobOpening->data['DreamjobJobOpening']['active']) or (strlen($a['DreamjobCompany']['bank_details']) > 0)){
|
if(!$this->allowOpening($a)){
|
||||||
$this->DreamjobJobOpening->data['DreamjobJobOpening']['active'] = false;
|
$this->DreamjobJobOpening->data['DreamjobJobOpening']['active'] = false;
|
||||||
}
|
}
|
||||||
if ($this->DreamjobJobOpening->save($this->DreamjobJobOpening->data)) {
|
if ($this->DreamjobJobOpening->save($this->DreamjobJobOpening->data)) {
|
||||||
|
if(!$this->allowOpening($a))
|
||||||
|
$this->MiconwareSession->setFlash(__('dreamjob.opening.save.count'), 'flash', array('alert' => 'info'));
|
||||||
|
else
|
||||||
$this->MiconwareSession->setFlash(__('dreamjob.opening.save.success'), 'flash', array('alert' => 'success'));
|
$this->MiconwareSession->setFlash(__('dreamjob.opening.save.success'), 'flash', array('alert' => 'success'));
|
||||||
if($this->request->data['DreamjobJobOpening']['active'] and $this->request->data['DreamjobJobOpening']['startdate'] <= date("Y-m-d") and $this->request->data['DreamjobJobOpening']['enddate'] >= date("Y-m-d", strtotime("+1 day") ))
|
if($this->request->data['DreamjobJobOpening']['active'] and $this->request->data['DreamjobJobOpening']['startdate'] <= date("Y-m-d") and $this->request->data['DreamjobJobOpening']['enddate'] >= date("Y-m-d", strtotime("+1 day") ))
|
||||||
return $this->redirect(array('action' => 'openingGet','id'=>$this->request->params['id']));
|
return $this->redirect(array('action' => 'openingGet','id'=>$this->request->params['id']));
|
||||||
|
|
|
@ -46,9 +46,7 @@ class UserController extends AppController {
|
||||||
$self = $this->MiconwareSession->getCompany();
|
$self = $this->MiconwareSession->getCompany();
|
||||||
$self_company = true;
|
$self_company = true;
|
||||||
|
|
||||||
$_pro = decbin($self['DreamjobCompany']['pro_user']);
|
$self_company_pro = $self['Pro']['worker_profil'];
|
||||||
$_pro_l = strlen($_pro);
|
|
||||||
$self_company_pro = !empty($_pro[$_pro_l-1]);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
//get Profil
|
//get Profil
|
||||||
|
|
|
@ -49,8 +49,6 @@ class AppUser extends AppModel {
|
||||||
$result = false;
|
$result = false;
|
||||||
} else {
|
} else {
|
||||||
$result = $this->saveField('avatar', str_replace(DS, "/", str_replace(WWW_ROOT.$this->uploadDir.DS, "", $filename) ));
|
$result = $this->saveField('avatar', str_replace(DS, "/", str_replace(WWW_ROOT.$this->uploadDir.DS, "", $filename) ));
|
||||||
if($data["AppUser"]['take_systemwide'])
|
|
||||||
$result = $this->User->saveField('avatar', str_replace(DS, "/", str_replace(WWW_ROOT.$this->uploadDir.DS, "", $filename) ));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($result) {
|
if ($result) {
|
||||||
|
|
|
@ -4,7 +4,6 @@ App::uses('CakeEmail', 'Network/Email');
|
||||||
/**
|
/**
|
||||||
* DreamjobCompany Model
|
* DreamjobCompany Model
|
||||||
*
|
*
|
||||||
* TODO
|
|
||||||
*
|
*
|
||||||
* @property
|
* @property
|
||||||
*/
|
*/
|
||||||
|
@ -141,17 +140,7 @@ class DreamjobCompany extends AppModel {
|
||||||
if($result)
|
if($result)
|
||||||
$result = $this->AppUser->saveField('take_systemwide',$data['AppUser']['take_systemwide']);
|
$result = $this->AppUser->saveField('take_systemwide',$data['AppUser']['take_systemwide']);
|
||||||
|
|
||||||
if($result and $data['AppUser']['take_systemwide']){
|
|
||||||
$result = $this->User->saveField('nickname',$data['AppUser']['nickname']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('first_name',$data['AppUser']['first_name']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('last_name',$data['AppUser']['last_name']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('bday',$data['AppUser']['bday']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('mannerofaddress_id',$data['AppUser']['mannerofaddress_id']);
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($result) {
|
if ($result) {
|
||||||
$dataSource->commit();
|
$dataSource->commit();
|
||||||
|
@ -215,16 +204,6 @@ class DreamjobCompany extends AppModel {
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
'pro_user' => array(
|
|
||||||
'numeric' => array(
|
|
||||||
'rule' => array('numeric'),
|
|
||||||
//'message' => 'Your custom message here',
|
|
||||||
//'allowEmpty' => false,
|
|
||||||
//'required' => false,
|
|
||||||
//'last' => false, // Stop validation after this rule
|
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
);
|
||||||
public $belongsTo = array(
|
public $belongsTo = array(
|
||||||
'DreamjobListBranch' => array(
|
'DreamjobListBranch' => array(
|
||||||
|
@ -262,6 +241,11 @@ class DreamjobCompany extends AppModel {
|
||||||
'conditions' => array('DreamjobCompany.djaccount_ptr_id=AppUser.id and User.id = AppUser.user_id'),
|
'conditions' => array('DreamjobCompany.djaccount_ptr_id=AppUser.id and User.id = AppUser.user_id'),
|
||||||
'limit' => 1
|
'limit' => 1
|
||||||
),
|
),
|
||||||
|
'Pro' => array(
|
||||||
|
'className' => 'DreamjobCompanyPro',
|
||||||
|
'foreignKey' => 'company_id',
|
||||||
|
'limit' => 1
|
||||||
|
),
|
||||||
'DreamjobListCity' => array(
|
'DreamjobListCity' => array(
|
||||||
'className' => 'DreamjobListCity',
|
'className' => 'DreamjobListCity',
|
||||||
'foreignKey' => false,
|
'foreignKey' => false,
|
||||||
|
|
|
@ -160,19 +160,6 @@ class DreamjobWorker extends AppModel {
|
||||||
if($result)
|
if($result)
|
||||||
$result = $this->AppUser->saveField('take_systemwide',$data['AppUser']['take_systemwide']);
|
$result = $this->AppUser->saveField('take_systemwide',$data['AppUser']['take_systemwide']);
|
||||||
|
|
||||||
if($result and $data['AppUser']['take_systemwide']){
|
|
||||||
$result = $this->User->saveField('nickname',$data['AppUser']['nickname']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('first_name',$data['AppUser']['first_name']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('last_name',$data['AppUser']['last_name']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('bday',$data['AppUser']['bday']);
|
|
||||||
if($result)
|
|
||||||
$result = $this->User->saveField('mannerofaddress_id',$data['AppUser']['mannerofaddress_id']);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if ($result) {
|
if ($result) {
|
||||||
$dataSource->commit();
|
$dataSource->commit();
|
||||||
|
|
|
@ -149,36 +149,6 @@ class User extends AppModel {
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
'first_name' => array(
|
|
||||||
'notEmpty' => array(
|
|
||||||
'rule' => array('notEmpty'),
|
|
||||||
//'message' => 'Your custom message here',
|
|
||||||
//'allowEmpty' => false,
|
|
||||||
//'required' => false,
|
|
||||||
//'last' => false, // Stop validation after this rule
|
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
|
||||||
),
|
|
||||||
),
|
|
||||||
'last_name' => array(
|
|
||||||
'notEmpty' => array(
|
|
||||||
'rule' => array('notEmpty'),
|
|
||||||
//'message' => 'Your custom message here',
|
|
||||||
//'allowEmpty' => false,
|
|
||||||
//'required' => false,
|
|
||||||
//'last' => false, // Stop validation after this rule
|
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
|
||||||
),
|
|
||||||
),
|
|
||||||
'is_staff' => array(
|
|
||||||
'boolean' => array(
|
|
||||||
'rule' => array('boolean'),
|
|
||||||
//'message' => 'Your custom message here',
|
|
||||||
//'allowEmpty' => false,
|
|
||||||
//'required' => false,
|
|
||||||
//'last' => false, // Stop validation after this rule
|
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
|
||||||
),
|
|
||||||
),
|
|
||||||
'is_active' => array(
|
'is_active' => array(
|
||||||
'boolean' => array(
|
'boolean' => array(
|
||||||
'rule' => array('boolean'),
|
'rule' => array('boolean'),
|
||||||
|
@ -252,36 +222,6 @@ class User extends AppModel {
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
'avatar' => array(
|
|
||||||
'url' => array(
|
|
||||||
'rule' => array('url'),
|
|
||||||
//'message' => 'Your custom message here',
|
|
||||||
//'allowEmpty' => false,
|
|
||||||
//'required' => false,
|
|
||||||
//'last' => false, // Stop validation after this rule
|
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
|
||||||
),
|
|
||||||
),
|
|
||||||
'bday' => array(
|
|
||||||
'date' => array(
|
|
||||||
'rule' => array('date'),
|
|
||||||
//'message' => 'Your custom message here',
|
|
||||||
//'allowEmpty' => false,
|
|
||||||
//'required' => false,
|
|
||||||
//'last' => false, // Stop validation after this rule
|
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
|
||||||
),
|
|
||||||
),
|
|
||||||
'comment' => array(
|
|
||||||
'notEmpty' => array(
|
|
||||||
'rule' => array('notEmpty'),
|
|
||||||
//'message' => 'Your custom message here',
|
|
||||||
//'allowEmpty' => false,
|
|
||||||
//'required' => false,
|
|
||||||
//'last' => false, // Stop validation after this rule
|
|
||||||
//'on' => 'create', // Limit validation to 'create' or 'update' operations
|
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
);
|
||||||
|
|
||||||
//The Associations below have been created with all possible keys, those that are not needed can be removed
|
//The Associations below have been created with all possible keys, those that are not needed can be removed
|
||||||
|
@ -291,15 +231,6 @@ class User extends AppModel {
|
||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
public $belongsTo = array(
|
|
||||||
'Mannerofaddress' => array(
|
|
||||||
'className' => 'Mannerofaddress',
|
|
||||||
'foreignKey' => 'mannerofaddress_id',
|
|
||||||
'conditions' => '',
|
|
||||||
'fields' => '',
|
|
||||||
'order' => ''
|
|
||||||
),
|
|
||||||
);
|
|
||||||
public $hasMany = array(
|
public $hasMany = array(
|
||||||
'AppUser' => array(
|
'AppUser' => array(
|
||||||
'className' => 'AppUser',
|
'className' => 'AppUser',
|
||||||
|
|
|
@ -4,17 +4,11 @@
|
||||||
*/
|
*/
|
||||||
$avatar = false;
|
$avatar = false;
|
||||||
$url = '';
|
$url = '';
|
||||||
if($company['AppUser']['take_systemwide']){
|
if($company['AppUser']['avatar']){
|
||||||
if($company['User']['avatar']){
|
|
||||||
$url = $MEDIA.DS.$company['User']['avatar'];
|
|
||||||
$avatar = true;
|
|
||||||
}
|
|
||||||
}else{
|
|
||||||
if($company['AppUser']['avatar']){
|
|
||||||
$url = $MEDIA.DS.$company['AppUser']['avatar'];
|
$url = $MEDIA.DS.$company['AppUser']['avatar'];
|
||||||
$avatar = true;
|
$avatar = true;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<div class="openingitem">
|
<div class="openingitem">
|
||||||
|
|
|
@ -19,17 +19,11 @@
|
||||||
|
|
||||||
$avatar = false;
|
$avatar = false;
|
||||||
$url = '';
|
$url = '';
|
||||||
if($opening['AppUser']['take_systemwide']){
|
if($opening['AppUser']['avatar']){
|
||||||
if($opening['User']['avatar']){
|
|
||||||
$url = $MEDIA.DS.$opening['User']['avatar'];
|
|
||||||
$avatar = true;
|
|
||||||
}
|
|
||||||
}else{
|
|
||||||
if($opening['AppUser']['avatar']){
|
|
||||||
$url = $MEDIA.DS.$opening['AppUser']['avatar'];
|
$url = $MEDIA.DS.$opening['AppUser']['avatar'];
|
||||||
$avatar = true;
|
$avatar = true;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<?php if(!empty($opening_MINI) or !($opening_in_app or $opening_in_fav)){ ?>
|
<?php if(!empty($opening_MINI) or !($opening_in_app or $opening_in_fav)){ ?>
|
||||||
<div class="openingitem">
|
<div class="openingitem">
|
||||||
|
|
|
@ -22,14 +22,7 @@ if($edit){
|
||||||
<table class="cv">
|
<table class="cv">
|
||||||
<tr>
|
<tr>
|
||||||
<td><?=__("dreamjob.bday");?></td>
|
<td><?=__("dreamjob.bday");?></td>
|
||||||
<td>
|
<td><?=$this->Time->format('d.m.Y', $profil['AppUser']['bday']);?></td>
|
||||||
<?php
|
|
||||||
if($profil['AppUser']['take_systemwide'])
|
|
||||||
echo $this->Time->format('d.m.Y', $profil['User']['bday']);
|
|
||||||
else
|
|
||||||
echo $this->Time->format('d.m.Y', $profil['AppUser']['bday']);
|
|
||||||
?>
|
|
||||||
</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><?=__("dreamjob.workexperience");?></td>
|
<td><?=__("dreamjob.workexperience");?></td>
|
||||||
|
|
|
@ -25,14 +25,7 @@ echo $this->Html->link($text,array('controller'=>'user','action'=>'profil'),arra
|
||||||
<?php if($cvc_item['DreamjobListCvCategory']['position'] == 0){ ?>
|
<?php if($cvc_item['DreamjobListCvCategory']['position'] == 0){ ?>
|
||||||
<tr>
|
<tr>
|
||||||
<td><?=__("dreamjob.bday");?></td>
|
<td><?=__("dreamjob.bday");?></td>
|
||||||
<td>
|
<td><?=$this->Time->format('d.m.Y', $profil['AppUser']['bday']);?></td>
|
||||||
<?php
|
|
||||||
if($profil['AppUser']['take_systemwide'])
|
|
||||||
echo $this->Time->format('d.m.Y', $profil['User']['bday']);
|
|
||||||
else
|
|
||||||
echo $this->Time->format('d.m.Y', $profil['AppUser']['bday']);
|
|
||||||
?>
|
|
||||||
</td>
|
|
||||||
<td></td>
|
<td></td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
|
|
@ -26,14 +26,7 @@
|
||||||
<table class="cv">
|
<table class="cv">
|
||||||
<tr>
|
<tr>
|
||||||
<td><?=__("dreamjob.bday");?></td>
|
<td><?=__("dreamjob.bday");?></td>
|
||||||
<td>
|
<td><?=$this->Time->format('d.m.Y', $profil['AppUser']['bday']);?></td>
|
||||||
<?php
|
|
||||||
if($profil['AppUser']['take_systemwide'])
|
|
||||||
echo $this->Time->format('d.m.Y', $profil['User']['bday']);
|
|
||||||
else
|
|
||||||
echo $this->Time->format('d.m.Y', $profil['AppUser']['bday']);
|
|
||||||
?>
|
|
||||||
</td>
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><?=__("dreamjob.workexperience");?></td>
|
<td><?=__("dreamjob.workexperience");?></td>
|
||||||
|
|
|
@ -7,10 +7,6 @@
|
||||||
<div class="bar avatar">
|
<div class="bar avatar">
|
||||||
<?php
|
<?php
|
||||||
$url='/img/icon_user.png';
|
$url='/img/icon_user.png';
|
||||||
if($profil['AppUser']['take_systemwide']){
|
|
||||||
if($profil['User']['avatar'])
|
|
||||||
$url = $MEDIA.DS.$profil['User']['avatar'];
|
|
||||||
}else
|
|
||||||
if($profil['AppUser']['avatar'])
|
if($profil['AppUser']['avatar'])
|
||||||
$url = $MEDIA.DS.$profil['AppUser']['avatar'];
|
$url = $MEDIA.DS.$profil['AppUser']['avatar'];
|
||||||
|
|
||||||
|
@ -26,25 +22,14 @@
|
||||||
<?php endif; ?>
|
<?php endif; ?>
|
||||||
</div>
|
</div>
|
||||||
<div class="bar">
|
<div class="bar">
|
||||||
<h1>
|
<h1><?=$profil['AppUser']['first_name'].' '.$profil['AppUser']['last_name'];?></h1>
|
||||||
<?php
|
|
||||||
if($profil['AppUser']['take_systemwide'])
|
|
||||||
echo $profil['User']['first_name'].' '.$profil['User']['last_name'];
|
|
||||||
else
|
|
||||||
echo $profil['AppUser']['first_name'].' '.$profil['AppUser']['last_name'];
|
|
||||||
?>
|
|
||||||
</h1>
|
|
||||||
<br/>
|
<br/>
|
||||||
<p>
|
<p>
|
||||||
<?=__("dreamjob.iam");?>:<br/>
|
<?=__("dreamjob.iam");?>:<br/>
|
||||||
<?=$profil['DreamjobWorker']['iam'];?>
|
<?=$profil['DreamjobWorker']['iam'];?>
|
||||||
</p>
|
</p>
|
||||||
<?php
|
<?php
|
||||||
$pro = '00000000'.decbin($COMPANY['DreamjobCompany']['pro_user']);
|
if(!empty($WORKER) and is_array($WORKER) and count($WORKER) > 0 and !isset($application) or $isLoggedin and !empty($COMPANY['Pro']['worker_mail'])){
|
||||||
$pro_l = strlen($pro);
|
|
||||||
$pro_user = !empty($pro[$pro_l-2]);
|
|
||||||
|
|
||||||
if(!empty($WORKER) and is_array($WORKER) and count($WORKER) > 0 and !isset($application) or $isLoggedin and $pro_user){
|
|
||||||
?>
|
?>
|
||||||
<h3><?=__("dreamjob.mail");?></h3>
|
<h3><?=__("dreamjob.mail");?></h3>
|
||||||
<a href="mailto:<?=$profil['User']['mail'];?>">
|
<a href="mailto:<?=$profil['User']['mail'];?>">
|
||||||
|
|
|
@ -15,21 +15,10 @@
|
||||||
// echo var_dump($profil);
|
// echo var_dump($profil);
|
||||||
?>
|
?>
|
||||||
<div class="openingitem">
|
<div class="openingitem">
|
||||||
<h3>
|
<h3><?=$profil[$AppUser]['first_name'].' '.$profil[$AppUser]['last_name'];?></h3>
|
||||||
<?php
|
|
||||||
if($profil[$AppUser]['take_systemwide'])
|
|
||||||
echo $profil[$User]['first_name'].' '.$profil[$User]['last_name'];
|
|
||||||
else
|
|
||||||
echo $profil[$AppUser]['first_name'].' '.$profil[$AppUser]['last_name'];
|
|
||||||
?>
|
|
||||||
</h3>
|
|
||||||
<div class="icon">
|
<div class="icon">
|
||||||
<?php
|
<?php
|
||||||
$url='/img/icon_user.png';
|
$url='/img/icon_user.png';
|
||||||
if($profil[$AppUser]['take_systemwide']){
|
|
||||||
if($profil[$User]['avatar'])
|
|
||||||
$url = $MEDIA.DS.$profil[$User]['avatar'];
|
|
||||||
}else
|
|
||||||
if($profil[$AppUser]['avatar'])
|
if($profil[$AppUser]['avatar'])
|
||||||
$url = $MEDIA.DS.$profil[$AppUser]['avatar'];
|
$url = $MEDIA.DS.$profil[$AppUser]['avatar'];
|
||||||
|
|
||||||
|
|
|
@ -23,11 +23,7 @@ $tcpdf->SetTextColor(0, 0, 0);
|
||||||
$tcpdf->SetFont($tcpdf->font);
|
$tcpdf->SetFont($tcpdf->font);
|
||||||
|
|
||||||
$url=WWW_ROOT.DS.'img'.DS.'icon_user.png';
|
$url=WWW_ROOT.DS.'img'.DS.'icon_user.png';
|
||||||
if($application['AppUserWorker']['take_systemwide']){
|
if($profil['AppUserWorker']['avatar'])
|
||||||
if($application['WorkerUser']['avatar'])
|
|
||||||
$url = WWW_ROOT.DS.'uploads'.DS.$application['WorkerUser']['avatar'];
|
|
||||||
}else
|
|
||||||
if($profil['AppUserWorker']['avatar'])
|
|
||||||
$url = WWW_ROOT.DS.'uploads'.DS.$application['AppUserWorker']['avatar'];
|
$url = WWW_ROOT.DS.'uploads'.DS.$application['AppUserWorker']['avatar'];
|
||||||
|
|
||||||
$tcpdf->Image($url,0,40,0,140,'','','','',300,'L');
|
$tcpdf->Image($url,0,40,0,140,'','','','',300,'L');
|
||||||
|
|
|
@ -24,11 +24,7 @@ $tcpdf->SetTextColor(0, 0, 0);
|
||||||
$tcpdf->SetFont($tcpdf->font);
|
$tcpdf->SetFont($tcpdf->font);
|
||||||
|
|
||||||
$url=WWW_ROOT.DS.'img'.DS.'icon_user.png';
|
$url=WWW_ROOT.DS.'img'.DS.'icon_user.png';
|
||||||
if($application['AppUserWorker']['take_systemwide']){
|
if($profil['AppUserWorker']['avatar'])
|
||||||
if($application['WorkerUser']['avatar'])
|
|
||||||
$url = WWW_ROOT.DS.'uploads'.DS.$application['WorkerUser']['avatar'];
|
|
||||||
}else
|
|
||||||
if($profil['AppUserWorker']['avatar'])
|
|
||||||
$url = WWW_ROOT.DS.'uploads'.DS.$application['AppUserWorker']['avatar'];
|
$url = WWW_ROOT.DS.'uploads'.DS.$application['AppUserWorker']['avatar'];
|
||||||
|
|
||||||
$tcpdf->Image($url,0,40,0,140,'','','','',300,'L');
|
$tcpdf->Image($url,0,40,0,140,'','','','',300,'L');
|
||||||
|
|
|
@ -24,11 +24,7 @@ $tcpdf->SetTextColor(0, 0, 0);
|
||||||
$tcpdf->SetFont($tcpdf->font);
|
$tcpdf->SetFont($tcpdf->font);
|
||||||
|
|
||||||
$url=WWW_ROOT.DS.'img'.DS.'icon_user.png';
|
$url=WWW_ROOT.DS.'img'.DS.'icon_user.png';
|
||||||
if($WORKER['AppUser']['take_systemwide']){
|
if($profil['AppUser']['avatar'])
|
||||||
if($WORKER['User']['avatar'])
|
|
||||||
$url = WWW_ROOT.DS.'uploads'.DS.$WORKER['User']['avatar'];
|
|
||||||
}else
|
|
||||||
if($profil['AppUser']['avatar'])
|
|
||||||
$url = WWW_ROOT.DS.'uploads'.DS.$WORKER['AppUser']['avatar'];
|
$url = WWW_ROOT.DS.'uploads'.DS.$WORKER['AppUser']['avatar'];
|
||||||
$tcpdf->Image($url,0,40,0,140,'','','','',300,'L');
|
$tcpdf->Image($url,0,40,0,140,'','','','',300,'L');
|
||||||
$tcpdf->SetY(185);
|
$tcpdf->SetY(185);
|
||||||
|
|
|
@ -3,22 +3,15 @@
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
$avatar = false;
|
$avatar = false;
|
||||||
if($profil['AppUser']['take_systemwide']){
|
|
||||||
if($profil['User']['avatar'])
|
|
||||||
$avatar = true;
|
|
||||||
}else{
|
|
||||||
if($profil['AppUser']['avatar'])
|
if($profil['AppUser']['avatar'])
|
||||||
$avatar = true;
|
$avatar = true;
|
||||||
}
|
|
||||||
?>
|
?>
|
||||||
<div class="box-extra">
|
<div class="box-extra">
|
||||||
<?php if($avatar or $edit){ ?>
|
<?php if($avatar or $edit){ ?>
|
||||||
<div class="box-extra-left infofield">
|
<div class="box-extra-left infofield">
|
||||||
<div class="box">
|
<div class="box">
|
||||||
<?php
|
<?php
|
||||||
if($profil['AppUser']['take_systemwide'])
|
|
||||||
$url = $MEDIA.DS.$profil['User']['avatar'];
|
|
||||||
else
|
|
||||||
$url = $MEDIA.DS.$profil['AppUser']['avatar'];
|
$url = $MEDIA.DS.$profil['AppUser']['avatar'];
|
||||||
if($edit and !isset($url))
|
if($edit and !isset($url))
|
||||||
$url = 'img/icon_company.png';
|
$url = 'img/icon_company.png';
|
||||||
|
|
|
@ -2,14 +2,6 @@
|
||||||
/*
|
/*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
$avatar = false;
|
|
||||||
if($profil['AppUser']['take_systemwide']){
|
|
||||||
if($profil['User']['avatar'])
|
|
||||||
$avatar = true;
|
|
||||||
}else{
|
|
||||||
if($profil['AppUser']['avatar'])
|
|
||||||
$avatar = true;
|
|
||||||
}
|
|
||||||
?>
|
?>
|
||||||
<div class="box">
|
<div class="box">
|
||||||
<div class="tabs-below">
|
<div class="tabs-below">
|
||||||
|
|
|
@ -2,14 +2,7 @@
|
||||||
/*
|
/*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
$avatar = false;
|
|
||||||
if($profil['AppUser']['take_systemwide']){
|
|
||||||
if($profil['User']['avatar'])
|
|
||||||
$avatar = true;
|
|
||||||
}else{
|
|
||||||
if($profil['AppUser']['avatar'])
|
|
||||||
$avatar = true;
|
|
||||||
}
|
|
||||||
?>
|
?>
|
||||||
<div class="box">
|
<div class="box">
|
||||||
<div class="tabs-below">
|
<div class="tabs-below">
|
||||||
|
|
|
@ -2,14 +2,6 @@
|
||||||
/*
|
/*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
$avatar = false;
|
|
||||||
if($profil['AppUser']['take_systemwide']){
|
|
||||||
if($profil['User']['avatar'])
|
|
||||||
$avatar = true;
|
|
||||||
}else{
|
|
||||||
if($profil['AppUser']['avatar'])
|
|
||||||
$avatar = true;
|
|
||||||
}
|
|
||||||
|
|
||||||
$this->startIfEmpty('scriptEnd');
|
$this->startIfEmpty('scriptEnd');
|
||||||
?>
|
?>
|
||||||
|
|
|
@ -9,12 +9,8 @@
|
||||||
?>
|
?>
|
||||||
</div>
|
</div>
|
||||||
<?php
|
<?php
|
||||||
$pro = '00000000'.decbin($COMPANY['DreamjobCompany']['pro_user']);
|
|
||||||
$pro_l = strlen($pro);
|
|
||||||
$pro_user = !empty($pro[$pro_l-1]);
|
|
||||||
|
|
||||||
|
if(( !empty($COMPANY) and is_array($COMPANY) and count($COMPANY) > 0 and $COMPANY['Pro']['worker_profil'] )
|
||||||
if(( !empty($COMPANY) and is_array($COMPANY) and count($COMPANY) > 0 and $pro_user )
|
|
||||||
or ( !empty($WORKER) and is_array($WORKER) and count($WORKER) > 0 )
|
or ( !empty($WORKER) and is_array($WORKER) and count($WORKER) > 0 )
|
||||||
){
|
){
|
||||||
?>
|
?>
|
||||||
|
|
Loading…
Reference in New Issue