From 8c2628e75d59e7ad9c6031212b7d17f515cce0d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20M=C3=BCller?= Date: Thu, 24 Apr 2014 10:12:06 +0200 Subject: [PATCH] ueberschriften --- app/Controller/PdfController.php | 5 +++-- app/View/Layouts/pdf.ctp | 4 ++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/app/Controller/PdfController.php b/app/Controller/PdfController.php index 072f067..cb67553 100644 --- a/app/Controller/PdfController.php +++ b/app/Controller/PdfController.php @@ -10,7 +10,7 @@ class PdfController extends AppController { $this->MiconwareSession->init($this); $this->MiconwareSession->initWeb($this); - $this->response->type('application/pdf'); + $WORKER = $this->MiconwareSession->getWorker(); $COMPANY = $self = $this->MiconwareSession->getCompany(); $application = null; @@ -25,6 +25,7 @@ class PdfController extends AppController { $this->set('error', 'dreamjob.error.noPermision'); $this->render('/Home/error'); }else{ + $this->response->type('application/pdf'); $this->set('application',$application); $cv = $this->DreamjobCvEntry->find('all',array('conditions' => array('worker_id'=> $application['DreamjobJobApplication']['worker_id']))); $this->set("cv",$cv); @@ -39,13 +40,13 @@ class PdfController extends AppController { $this->MiconwareSession->init($this); $this->MiconwareSession->initWeb($this); - $this->response->type('application/pdf'); $WORKER = $this->MiconwareSession->getWorker(); if(!is_array($WORKER) or count($WORKER) <= 0){ $this->set('error', 'dreamjob.error.noPermision'); $this->render('/Home/error'); }else{ + $this->response->type('application/pdf'); $cv = $this->DreamjobCvEntry->find('all',array('conditions' => array('worker_id'=> $WORKER['AppUser']['id']))); $this->set("cv",$cv); $cvp0 = $this->DreamjobListCvCategory->find('first',array('conditions' => array('DreamjobListCvCategory.position' => 0))); diff --git a/app/View/Layouts/pdf.ctp b/app/View/Layouts/pdf.ctp index 9e6e842..9c4e246 100644 --- a/app/View/Layouts/pdf.ctp +++ b/app/View/Layouts/pdf.ctp @@ -1,4 +1,4 @@