tussenopslag
This commit is contained in:
@@ -57,9 +57,10 @@ class Compactsop extends MY_Controller{
|
||||
echo json_encode($soort);
|
||||
}
|
||||
|
||||
function getSchooljaren(){
|
||||
function getSchooljarenEnOrgs(){
|
||||
if (!$this->userid) die;
|
||||
$schooljaren = $this->Schooljaren_model->getschooljaren();
|
||||
// $orgs = $this->
|
||||
echo json_encode($schooljaren);
|
||||
}
|
||||
|
||||
|
||||
@@ -9,6 +9,16 @@
|
||||
event: {change: fGetCompactSop}" >
|
||||
</select>
|
||||
</td>
|
||||
<!--ko if: orgsoortnummer < 4 -->
|
||||
<td style="padding-left: 30px;">
|
||||
<p>Selecteer een organisatie:</p>
|
||||
<select data-bind=" options: schooljaren,
|
||||
optionsText: 'naam',
|
||||
value: $root.selectedSchooljaar,
|
||||
event: {change: fGetCompactSop}" >
|
||||
</select>
|
||||
</td>
|
||||
<!--/ko -->
|
||||
|
||||
<td style="vertical-align: bottom; ">
|
||||
<button class="buttonCompact"
|
||||
|
||||
@@ -263,6 +263,7 @@ mh.initCompactSopModel = function(){
|
||||
else {
|
||||
mh.CompactSopModel = {
|
||||
schooljaren : ko.observableArray([]),
|
||||
organisaties : ko.observableArray([]),
|
||||
onderdelen : ko.observableArray([]),
|
||||
school : ko.observableArray([]),
|
||||
selectedOmvangJaren : ko.observableArray([]),
|
||||
@@ -349,12 +350,12 @@ mh.initCompactSopModel = function(){
|
||||
|
||||
initModel: function(){
|
||||
var self =mh.CompactSopModel;
|
||||
self.fGetSchooljaren(function(){self.fGetCompactSop()})
|
||||
self.fGetSchooljarenEnOrgs(function(){self.fGetCompactSop()})
|
||||
},
|
||||
|
||||
fGetSchooljaren: function(callback){
|
||||
fGetSchooljarenEnOrgs: function(callback){
|
||||
var self =mh.CompactSopModel;
|
||||
$.post("index.php/monpas/compactsop/getSchooljaren", function(data){
|
||||
$.post("index.php/monpas/compactsop/getSchooljarenEnOrgs", function(data){
|
||||
self.selectedSchooljaar(null)
|
||||
self.schooljaren.removeAll();
|
||||
self.toonOnderdelen(true)
|
||||
|
||||
Reference in New Issue
Block a user