optie niet van toepassing niet meetellen
als gekozen is voor scoretype 4 bij een orgversie (ja,nee, nvt) de optie nvt niet meetellen in het gemiddelde als bij een ijkpunt in een filledversion voor alle opties nvt is gekozen. De optie elf wordt dan grijs
This commit is contained in:
@@ -128,6 +128,10 @@ class Gemiddeldescores
|
||||
private function setLeerkrachtScores(){
|
||||
if (!$this->leerkrachten) return;
|
||||
foreach ($this->leerkrachten as $index => $this->leerkracht) {
|
||||
if($this->scoretype == 4) $this->leerkracht->scores = $this->CI->Scores_model->calculateindividualscorestype4(
|
||||
$this->orgversieid, $this->orgid, $this->leerkracht->user_id);
|
||||
|
||||
else
|
||||
$this->leerkracht->scores = $this->CI->Scores_model->calculateindividualscores(
|
||||
$this->orgversieid, $this->orgid, $this->leerkracht->user_id);
|
||||
}
|
||||
@@ -190,6 +194,7 @@ class Gemiddeldescores
|
||||
private function loopIJkpunten()
|
||||
{
|
||||
foreach ($this->ijkpunten as $index => $this->ijkpunt) {
|
||||
$this->aantalnvt = 0;
|
||||
$this->ijkpunt->disablenvt = 'F';
|
||||
$this->ijkpunt->totaal = 0;
|
||||
$this->ijkpunt->aantallkrtn = 0;
|
||||
@@ -244,8 +249,9 @@ class Gemiddeldescores
|
||||
private function setIJkpuntTotaal()
|
||||
{
|
||||
if ($this->score->nummer == $this->ijkpunt->nummer) {
|
||||
if ($this->score->num > 0) {
|
||||
$lkrtscore = $this->score->somscore / $this->score->num;
|
||||
if ($this->score->num> 0) {
|
||||
if($this->scoretype == 4) $lkrtscore = round($this->score->somscore);
|
||||
else $lkrtscore = round($this->score->somscore / $this->score->num);
|
||||
$this->ijkpunt->totaal = $this->ijkpunt->totaal + $lkrtscore;
|
||||
$this->ijkpunt->aantallkrtn++;
|
||||
$this->slaover = true;
|
||||
@@ -256,7 +262,7 @@ class Gemiddeldescores
|
||||
private function telNietvanToepassing(){
|
||||
if($this->score->scoretype != 4) return;
|
||||
if ($this->score->nummer == $this->ijkpunt->nummer) {
|
||||
if($this->score->aantalnvt == $this->score->aantalvier )
|
||||
if($this->score->disablenvt == 'T' )
|
||||
$this->aantalnvt++;
|
||||
|
||||
}
|
||||
@@ -270,7 +276,7 @@ class Gemiddeldescores
|
||||
}
|
||||
|
||||
private function setNietVanToepassing(){
|
||||
if($this->ijkpunt->aantallkrtn == $this->aantalnvt){
|
||||
if( $this->aantalnvt == $this->metingen->aantal ){
|
||||
$this->ijkpunt->disablenvt = 'T';
|
||||
}
|
||||
}
|
||||
@@ -340,7 +346,7 @@ class Gemiddeldescores
|
||||
if(!isset($this->ijkpunt->score)){continue;};
|
||||
if(! $this->ijkpunt->score) $this->ijkpuntscore = 0;
|
||||
$this->setScorenummer();
|
||||
$this->rondScoresAf();
|
||||
// $this->rondScoresAf();
|
||||
$this->setScoreKleuren();
|
||||
$this->addGewensteScores($index);
|
||||
$this->setWenskleuren();
|
||||
|
||||
@@ -98,7 +98,10 @@ class Schoolscores
|
||||
}
|
||||
|
||||
private function setScores(){
|
||||
$this->scores = $this->CI->Scores_model->getgemscores($this->orgversieid, $this->orgstring);
|
||||
if($this->scoretype == 4) $this->scores = $this->CI->Scores_model->getgemscorestype4($this->orgversieid, $this->orgstring);
|
||||
else $this->scores = $this->CI->Scores_model->getgemscores($this->orgversieid, $this->orgstring);
|
||||
|
||||
|
||||
}
|
||||
|
||||
private function setMetingen(){
|
||||
@@ -291,7 +294,7 @@ class Schoolscores
|
||||
$this->gemiddelde->gem = 0;
|
||||
$this->gemiddelde->score = 0;
|
||||
$deler = $this->aantalY - $this->aantaldisablenvt;
|
||||
if($deler > 0) $this->gemiddelde->gem = round($this->somscore / $deler);
|
||||
if($deler > 0) $this->gemiddelde->gem = round(round($this->somscore) / $deler);
|
||||
|
||||
$this->gemiddelde->disabled = 'F';
|
||||
$this->gemiddelde->disablenvt = 'F';
|
||||
|
||||
@@ -79,7 +79,8 @@ class Individuelescores
|
||||
}
|
||||
|
||||
private function setScores(){
|
||||
$this->scores = $this->CI->Scores_model->calculateindividualscores($this->orgversieid, $this->orgid, $this->userid);
|
||||
if($this->scoretype ==4 )$this->scores = $this->CI->Scores_model->calculateindividualscorestype4($this->orgversieid, $this->orgid, $this->userid);
|
||||
else $this->scores = $this->CI->Scores_model->calculateindividualscores($this->orgversieid, $this->orgid, $this->userid);
|
||||
}
|
||||
|
||||
|
||||
@@ -141,10 +142,8 @@ class Individuelescores
|
||||
}
|
||||
|
||||
private function setNietVanToepassing(){
|
||||
if(! isset($this->scores) || $this->scores == false ) return;
|
||||
$this->score->disablenvt = 'F';
|
||||
if($this->score->aantalvier> 0 && $this->score->aantalvier == $this->score->aantalnvt){
|
||||
$this->score->disablenvt = 'T';
|
||||
if(! isset($this->scores) || $this->scores == false || $this->scoretype != 4 ) return;
|
||||
if($this->score->disablenvt == 'T'){
|
||||
$this->aantaldisablenvt++;
|
||||
}
|
||||
|
||||
@@ -152,9 +151,12 @@ class Individuelescores
|
||||
|
||||
private function setGem(){
|
||||
if(! isset($this->scores) || $this->scores == false ) return;
|
||||
$this->score->gem = 0;
|
||||
if(isset($this->score->somscore) && $this->score->num > 0) {
|
||||
$this->score->gem = round($this->score->somscore/$this->score->num);
|
||||
if($this->scoretype == 4) $this->score->gem = round($this->score->somscore);
|
||||
else {
|
||||
$this->score->gem = 0;
|
||||
if (isset($this->score->somscore) && $this->score->num > 0) {
|
||||
$this->score->gem = round($this->score->somscore / $this->score->num);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -176,7 +178,7 @@ class Individuelescores
|
||||
}
|
||||
|
||||
private function telIJkpuntenok(){
|
||||
if($this->score->disabled == 'F' && $this->score->disablenvt == 'F') {
|
||||
if($this->ambities && $this->score->disabled == 'F' && $this->score->disablenvt == 'F') {
|
||||
if ($this->score->gem >= $this->ambities->zprocent) {
|
||||
$this->ijkpuntenok++;
|
||||
}
|
||||
|
||||
@@ -86,7 +86,7 @@ class Userlijsten
|
||||
if(!isset($this->scores) || !$this->scores) return;
|
||||
$bestuurid = $this->organisatie->valtonder_id;
|
||||
$orgid = $this->CI->Organisaties_model->get_fieldvalue(['id'=>$bestuurid], 'valtonder_id');
|
||||
$this->vergelijkingen = (new Schoolscores($this->orgversieid, $orgid, 2, 'T'))->getResults() ;
|
||||
$this->vergelijkingen = (new Schoolscores($this->orgversieid, $orgid, $this->lijst->orgversie->scoretype, 'T'))->getResults() ;
|
||||
}
|
||||
|
||||
private function setVergelijkingScores(){
|
||||
|
||||
Reference in New Issue
Block a user