lebenslauf <-> profil-Kopf

This commit is contained in:
Martin Müller 2014-04-13 20:39:12 +02:00
parent af2fd20f7e
commit cf44a07942
2 changed files with 15 additions and 12 deletions

View File

@ -81,9 +81,11 @@ class UserController extends AppController {
}else{
if(isset($profil['DreamjobWorker'])){
$cv = $this->DreamjobCvEntry->find('all',array('conditions' => array('worker_id'=> $profil['AppUser']['id'])));
if(!$self_company and $profil['AppUser']['id']==$self['AppUser']['id'])
$this->request->data = $cv;
$this->set("cv",$cv);
if(!$self_company and $profil['AppUser']['id']==$self['AppUser']['id']){
$cvp0 = $this->DreamjobListCvCategory->find('first',array('conditions' => array('DreamjobListCvCategory.position' => 0)));
$this->set('cvp0', $cvp0);
$this->set("cv",$cv);
}
}
}
}

View File

@ -18,13 +18,15 @@ if($edit){
$inCat= -1;
foreach($cv as $cvc){
if ( $inCat != $cvc['DreamjobListCvCategory']['id'] ){
if($inCat == -1){
if($cvp0['DreamjobListCvCategory']['id'] != $cvc['DreamjobListCvCategory']['id']){
?>
</table>
<?php } ?>
<h4><?=$cvc['DreamjobListCvCategory']['name'];?></h4>
<table class="cv">
<?php if($cvc['DreamjobListCvCategory']['position'] == 0){ ?>
<?php
}else{
?>
<h4><?=$cvp0['DreamjobListCvCategory']['name'];?></h4>
<table class="cv">
<tr>
<td><?=__("dreamjob.bday");?></td>
<td>
@ -48,11 +50,10 @@ if($edit){
<td><?=__("dreamjob.country.worker");?></td>
<td><?=$profil['DreamjobWorker']['country'];?></td>
</tr>
<?php
}
$inCat = $cvc['DreamjobListCvCategory']['id'];
}
?>
<?php }
$inCat = $cvc['DreamjobListCvCategory']['id'];
}
?>
<tr>
<?php
if($cvc['DreamjobListCvCategory']['startdate'] and $cvc['DreamjobListCvCategory']['enddate'] and $cvc['DreamjobListCvCategory']['place']){