Skip to content

Commit

Permalink
Fix check of Member Status (#151)
Browse files Browse the repository at this point in the history
  • Loading branch information
Memurame authored Oct 2, 2024
1 parent c286c44 commit 5a61d59
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions app/Controllers/CronController.php
Original file line number Diff line number Diff line change
Expand Up @@ -441,12 +441,15 @@ public function telefonlist(){
// Alle Adressen durchschleifen
for($i = 0; $i < count($adressen); $i++){


// Prüfen on ein Zahldatum gesetzt ist.
// von Juli-Dezember die Mitgliederart anhand des Zahldatums anpassen
// NM welche im laufenden Jahr ab Juli bezahlt haben und über 70 % bezahlt haben, die Mitgliederart auf AM Wechseln

if(isset($adressDate) AND
$currentDate['year'] == $adressDateArray[2] AND
$adressDateArray = ($adressen[$i]['paid_date']) ? explode('-', $adressen[$i]['paid_date']) : null;

if(isset($adressDateArray) AND
$currentDate['year'] == $adressDateArray[0] AND
$currentDate['month'] >= 7 AND
$adressen[$i]['paid_percent'] >= 70 AND
$adressen[$i]['member_typ'] == "NM"){
Expand All @@ -469,7 +472,7 @@ public function telefonlist(){
else {
$adressen[$i]['Status'] = "keine Rechnung";
}

$kalahari = model('AbaAddressKalahariModel')
->select('kalahari')
->where('abacus', $adressen[$i]['abacus'])
Expand Down

0 comments on commit 5a61d59

Please sign in to comment.