geenondersteuning so en sbo
This commit is contained in:
@@ -28,19 +28,8 @@ class Ondersteuning extends MY_Controller{
|
||||
$orgid = $this->uri->segment(4);
|
||||
$schooljaarnr = $this->uri->segment(5);
|
||||
$groepen = $this->Groepen_model->getgroepenSboSo($orgid, $schooljaarnr);
|
||||
$ondersteuning = 'T';
|
||||
if ($groepen){
|
||||
foreach($groepen as $groep) {
|
||||
if (isset($groep->ondersteuning)) {
|
||||
if ($groep->ondersteuning === 'F') {
|
||||
$ondersteuning = 'F';
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
echo json_encode(['groepen'=>$groepen, 'ondersteuning'=>$ondersteuning]);
|
||||
echo json_encode($groepen);
|
||||
}
|
||||
|
||||
function meldondersteuning(){
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
<div class="col-sm-12 mainpagina" id ="pagdiversiteitso">
|
||||
<!--<div class="row" data-bind="visible: groepen().length <=0">-->
|
||||
<!-- Er zijn (nog) geen groepsgegevens ingevoerd.-->
|
||||
<!--</div> -->
|
||||
<!-- <div data-bind="text: groepen[0].naam"></div>-->
|
||||
<div class="row" data-bind="visible: groepen().length > 0">
|
||||
<div class="row" data-bind="visible: groepen().length <=0">
|
||||
Er zijn (nog) geen groepsgegevens ingevoerd.
|
||||
</div>
|
||||
|
||||
<div class="row" data-bind="visible: groepen().length > 0">
|
||||
<h4>Diversiteitomvang
|
||||
<button class="printer" style="margin-left: 30px" data-bind="click: fPrintDiversiteitMatrix"></button>
|
||||
</h4>
|
||||
@@ -229,13 +229,12 @@
|
||||
</div>
|
||||
</div>
|
||||
<hr/>
|
||||
<div class="row" data-bind="visible: !toonMatrix()">
|
||||
<div class="col-sm-12" >
|
||||
<h4>Ondersteuningsmatrix</h4>
|
||||
<p style="margin-top: 15px;">Geen ondersteuning</p>
|
||||
<div class="row" >
|
||||
<div class="col-sm-12" data-bind="visible: ondersteuningSchool() == false">
|
||||
<p style="margin-top: 15px;">Geen ondersteuning voor groepen</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row" data-bind="visible: toonMatrix()">
|
||||
<div class="row" data-bind="visible: ondersteuningSchool()">
|
||||
<div class="col-sm-12" >
|
||||
<h4>Ondersteuningsmatrix
|
||||
<button class="printer" style="margin-left: 30px" data-bind="click: fPrintOndersteuningsmatrix"></button>
|
||||
@@ -313,7 +312,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<hr/>
|
||||
<div class= "row" data-bind="visible: toonMatrix()">
|
||||
<div class= "row" data-bind="visible: ondersteuningSchool()">
|
||||
<div class="col-sm-12">
|
||||
<h4>Totalen per soort ondersteuning
|
||||
<button class="printer" style="margin-left: 30px" data-bind="click: fPrintOndersteuningstotalen"></button>
|
||||
|
||||
@@ -1,6 +1,18 @@
|
||||
<div class="col-sm-12 mainpagina" id ="pagondersteuningso">
|
||||
|
||||
<div data-bind="visible: ondersteuning()">
|
||||
<div data-bind="visible: groepen().length == 0">
|
||||
<p>Er zijn nog geen groepen ingevuld</p>
|
||||
</div>
|
||||
|
||||
<div data-bind="visible:groepen().length > 0">
|
||||
|
||||
<p>
|
||||
<span class="glyphicon glyphicon-unchecked" data-bind="visible: !geenOndersteuning(), click: fMeldOndersteuning" style="display: none;"></span>
|
||||
<span class="glyphicon glyphicon-check" style="margin-right: 5px;" data-bind="visible: geenOndersteuning(), click: fMeldOndersteuning"></span>
|
||||
geen ondersteuning voor groepen
|
||||
</p>
|
||||
|
||||
<div data-bind="visible: geenOndersteuning() == false">
|
||||
<span>Selecteer een groep:</span>
|
||||
<select data-bind=" options : groepen,
|
||||
optionsText : 'naam',
|
||||
@@ -50,10 +62,11 @@
|
||||
<p style="font-size: 0.8em; margin-top:20px">* Ondersteuning in de groep</p>
|
||||
<p style="font-size: 0.8em">** Ondersteuning aan een subgroep buiten de groep </p>
|
||||
<p style="font-size: 0.8em">*** Ondersteuning aan een individuele leerling buiten de groep</p>
|
||||
</div>
|
||||
</div>
|
||||
<br>
|
||||
<br>
|
||||
<button style="margin-bottom: 20px"data-bind="click: fWijzigOndersteuning, visible: ondersteuning()">Geen ondersteuning</button>
|
||||
<button style="margin-bottom: 20px;"data-bind="click: fWijzigOndersteuning, visible: !ondersteuning()">Toon ondersteuning</button>
|
||||
<!-- <br>-->
|
||||
<!-- <br>-->
|
||||
<!-- <button style="margin-bottom: 20px"data-bind="click: fWijzigOndersteuning, visible: ondersteuning()">Geen ondersteuning</button>-->
|
||||
<!-- <button style="margin-bottom: 20px;"data-bind="click: fWijzigOndersteuning, visible: !ondersteuning()">Toon ondersteuning</button>-->
|
||||
|
||||
</div>
|
||||
|
||||
@@ -113,6 +113,7 @@ mh.initDiversiteitSOModel = function(){
|
||||
// combifactor3 : ko.observable(2.5),
|
||||
addtoschool : ko.observable(false),
|
||||
toonMatrix : ko.observable(true),
|
||||
ondersteuningSchool : ko.observable(true),
|
||||
|
||||
initBindings :function(){
|
||||
var self = mh.DiversiteitSOModel;
|
||||
@@ -160,11 +161,15 @@ mh.initDiversiteitSOModel = function(){
|
||||
self.schoolDQ(0);
|
||||
self.schoolTijd(0);
|
||||
self.aantalgroepen(0);
|
||||
self.ondersteuningSchool(true);
|
||||
self.ondersteuningsvormen.removeAll();
|
||||
if (data){
|
||||
|
||||
if(data.groepen) {
|
||||
$.each(data.groepen, function (i, p) {
|
||||
if(p.ondersteuning == 'F'){
|
||||
self.ondersteuningSchool(false);
|
||||
}
|
||||
self.groepen.push(new fAddGroep(p));
|
||||
|
||||
});//each
|
||||
|
||||
@@ -65,8 +65,8 @@ ls.initOndersteuningModel = function(module){
|
||||
self.dagen.removeAll();
|
||||
if (result){
|
||||
$.each(result, function(i,p){
|
||||
self.groepen.push(new fAddGroep(p));
|
||||
if(p.ondersteuning == 'F') self.geenOndersteuning(true);
|
||||
self.groepen.push(new fAddGroep(p));
|
||||
});//each
|
||||
self.selectedGroep(self.groepen()[0]);
|
||||
// self.fGetUren();
|
||||
|
||||
@@ -31,7 +31,7 @@ mh.initOndersteuningSOModel = function(){
|
||||
selectedGroep : ko.observable(),
|
||||
dagen : ko.observableArray([]),
|
||||
writer : ko.observable(false),
|
||||
ondersteuning : ko.observable(true),
|
||||
geenOndersteuning : ko.observable(false),
|
||||
// toonInvoer : ko.computed(function () {
|
||||
// return mh.OndersteuningSOModel.ondersteuning();
|
||||
// }),
|
||||
@@ -61,47 +61,42 @@ mh.initOndersteuningSOModel = function(){
|
||||
self.groepen.removeAll();
|
||||
self.selectedGroep(null);
|
||||
self.dagen.removeAll();
|
||||
if (result.groepen){
|
||||
$.each(result.groepen, function(i,p){
|
||||
if (result){
|
||||
$.each(result, function(i,p){
|
||||
self.groepen.push(new fAddGroep(p));
|
||||
if(p.ondersteuning == 'F') self.geenOndersteuning(true);
|
||||
});//each
|
||||
self.selectedGroep(self.groepen()[0]);
|
||||
// self.fGetUren();
|
||||
}
|
||||
if(result.ondersteuning){
|
||||
if(result.ondersteuning == 'F'){
|
||||
self.ondersteuning(false);
|
||||
}
|
||||
else{
|
||||
self.ondersteuning();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
},'json');
|
||||
|
||||
|
||||
},
|
||||
|
||||
fWijzigOndersteuning: function(){
|
||||
var self = mh.OndersteuningSOModel;
|
||||
self.ondersteuning(!self.ondersteuning());
|
||||
var middelen = 'T';
|
||||
if(!self.ondersteuning()){
|
||||
middelen = 'F';
|
||||
}
|
||||
var submitData = {
|
||||
'ondersteuning' : middelen,
|
||||
'orgid' : self.schoolid(),
|
||||
'schooljaar' : self.schooljaarnr(),
|
||||
}
|
||||
$.post("index.php/monpas/ondersteuning/saveondersteuning/", submitData, function(result){
|
||||
fMeldOndersteuning(){
|
||||
var self = mh.OndersteuningSOModel;
|
||||
self.geenOndersteuning(! self.geenOndersteuning())
|
||||
var ondersteuning = 'T';
|
||||
if(self.geenOndersteuning()) ondersteuning = 'F'
|
||||
|
||||
},'json');
|
||||
var submitData = {
|
||||
'schoolid' : self.schoolid(),
|
||||
'schooljaar' : self.schooljaarnr(),
|
||||
'module' : 270,
|
||||
'ondersteuning' : ondersteuning,
|
||||
}
|
||||
console.log(submitData)
|
||||
|
||||
$.post("index.php/monpas/ondersteuning/meldondersteuning", submitData , function(result){
|
||||
console.log(result, "result")
|
||||
},'json');
|
||||
|
||||
|
||||
|
||||
},
|
||||
|
||||
},
|
||||
fGetUren : function(){
|
||||
var self = mh.OndersteuningSOModel;
|
||||
if (!self.selectedGroep()) return;
|
||||
|
||||
Reference in New Issue
Block a user