tussenopslag
This commit is contained in:
@@ -138,10 +138,11 @@ class Compactsop extends MY_Controller{
|
|||||||
$compacteonderdelen = $compact->getCompacteOnderdelen();
|
$compacteonderdelen = $compact->getCompacteOnderdelen();
|
||||||
$schoolID = $this->globorgid;
|
$schoolID = $this->globorgid;
|
||||||
$html = (new Compactepaginas($compacteonderdelen, $paginas))->getHtml();
|
$html = (new Compactepaginas($compacteonderdelen, $paginas))->getHtml();
|
||||||
|
$padnaam = $schoolID . $schooljaarnr;
|
||||||
|
file_put_contents(MYROOTPATH.'public/tmp/temp'.$schoolID.$schooljaarnr.'.html', $html);
|
||||||
|
|
||||||
file_put_contents(MYROOTPATH.'public/tmp/temp'.$schoolID.'.html', $html);
|
|
||||||
|
|
||||||
echo json_encode($this->globorgid);
|
echo json_encode($padnaam);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function uploadLogo($schoolID)
|
public function uploadLogo($schoolID)
|
||||||
@@ -158,14 +159,18 @@ class Compactsop extends MY_Controller{
|
|||||||
//TODO: unlink eventueel oud logo
|
//TODO: unlink eventueel oud logo
|
||||||
$logo = $this->Schooldetails_model->getLogo($schoolID);
|
$logo = $this->Schooldetails_model->getLogo($schoolID);
|
||||||
$padNaam = $savePath.$logo;
|
$padNaam = $savePath.$logo;
|
||||||
|
|
||||||
// unlink($padNaam);
|
// unlink($padNaam);
|
||||||
$this->Schooldetails_model->update_record_where(['logo'=>$filename], ['organisatie_id' =>$schoolID]);
|
$this->Schooldetails_model->update_record_where(['logo'=>$filename], ['organisatie_id' =>$schoolID]);
|
||||||
}
|
}
|
||||||
|
|
||||||
function getLogo(){
|
function getLogo(){
|
||||||
$schoolID = $this->clean_input('schoolID');
|
$schoolID = $this->clean_input('schoolID');
|
||||||
|
$savePath = MYROOTPATH.'public/images/logos/';
|
||||||
$logo =$this->Schooldetails_model->getLogo($schoolID);
|
$logo =$this->Schooldetails_model->getLogo($schoolID);
|
||||||
$this->json($logo);
|
$padNaam = $savePath.$logo;
|
||||||
|
chmod($padNaam, '0777');
|
||||||
|
$this->json($padNaam);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -99,7 +99,7 @@ class Compacteonderdelen
|
|||||||
$logo = false;
|
$logo = false;
|
||||||
if($this->details && $this->details->logo) {
|
if($this->details && $this->details->logo) {
|
||||||
// $logo = $this->CI->config->item('vendor_url') . '/images/logos/' . $this->details->logo;
|
// $logo = $this->CI->config->item('vendor_url') . '/images/logos/' . $this->details->logo;
|
||||||
$logo = $_ENV['BASE_URL']. '/images/logos/' . $this->details->logo;
|
$logo = $_ENV['VENDOR_URL']. '/images/logos/' . $this->details->logo;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -37,7 +37,7 @@ class Schooldetails_model extends MY_Model{
|
|||||||
}
|
}
|
||||||
|
|
||||||
function getLogo($orgid){
|
function getLogo($orgid){
|
||||||
$this->sql = "SELECT concat('../images/logos/', logo) as logo
|
$this->sql = "SELECT logo
|
||||||
FROM tb_schooldetails
|
FROM tb_schooldetails
|
||||||
WHERE organisatie_id={$orgid}";
|
WHERE organisatie_id={$orgid}";
|
||||||
return $this->get_query_row('logo');
|
return $this->get_query_row('logo');
|
||||||
|
|||||||
@@ -716,14 +716,10 @@
|
|||||||
<div class="container" id='compactSopPdf' >
|
<div class="container" id='compactSopPdf' >
|
||||||
|
|
||||||
<?php if ($schoolgegevens) { ?>
|
<?php if ($schoolgegevens) { ?>
|
||||||
<img style="max-width:45px;"
|
<img style="max-width:45px; "
|
||||||
src="<?=$schoolgegevens['data']['logo']?>"/>
|
src="<?=$schoolgegevens['data']['logo']?>"/>
|
||||||
<?php } else { ?>
|
<?php } ?>
|
||||||
<img style="max-width:45px; height: 0px; "
|
|
||||||
src="http://app.monpas.nl/images/logos/monpaslogo.png"/>
|
|
||||||
<?php } ?>
|
|
||||||
<img style="max-width:50%; height: 0px;"
|
|
||||||
src="http://app.monpas.nl/images/logos/frameworklogo.png"/>
|
|
||||||
##PLACEHOLDER##
|
##PLACEHOLDER##
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -11,7 +11,6 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
|
|
||||||
<table style="width: 90%;" data-bind="foreach: $root.school">
|
<table style="width: 90%;" data-bind="foreach: $root.school">
|
||||||
<tr >
|
<tr >
|
||||||
<td style="width: 20%" data-bind="text: $root.orgsoort() "></td>
|
<td style="width: 20%" data-bind="text: $root.orgsoort() "></td>
|
||||||
@@ -63,7 +62,7 @@
|
|||||||
|
|
||||||
<td style="vertical-align: top;">Logo</td>
|
<td style="vertical-align: top;">Logo</td>
|
||||||
<td >
|
<td >
|
||||||
<!-- ko if: $root.school() && $root.school()[0] && $root.school()[0].logo() -->
|
<!-- ko if: $root.schoolasobject() && $root.schoolasobject().logo() -->
|
||||||
<img data-bind="attr:{src: $root.schoolasobject().logo(),
|
<img data-bind="attr:{src: $root.schoolasobject().logo(),
|
||||||
alt: $root.schoolasobject().logo() } "
|
alt: $root.schoolasobject().logo() } "
|
||||||
|
|
||||||
@@ -93,7 +92,7 @@
|
|||||||
overflow:hidden " />
|
overflow:hidden " />
|
||||||
<label class="btn btn-small btn-info"
|
<label class="btn btn-small btn-info"
|
||||||
|
|
||||||
for="image_file">Selecteer</label>
|
for="image_file">Selecteer logo</label>
|
||||||
<!-- ko if: uploadLogoNaam()-->
|
<!-- ko if: uploadLogoNaam()-->
|
||||||
<i>gekozen: <span data-bind="text:showLogoNaam"></span></i>
|
<i>gekozen: <span data-bind="text:showLogoNaam"></span></i>
|
||||||
<!-- /ko -->
|
<!-- /ko -->
|
||||||
|
|||||||
Reference in New Issue
Block a user