X-Git-Url: http://git.roojs.org/?p=Pman.Core;a=blobdiff_plain;f=Notify.php;h=3f3321c37bc69a318e15893547c9f1771bc30aff;hp=648e1d60f8818c7429a581a7f6beaec2ebe0f0d0;hb=5ff4d5ffbdad938aed7d97018e967941dea16348;hpb=e08f55bb42ae6bee1a7bf1542b5afe701ebdfdfd diff --git a/Notify.php b/Notify.php index 648e1d60..3f3321c3 100644 --- a/Notify.php +++ b/Notify.php @@ -296,7 +296,32 @@ class Pman_Core_Notify extends Pman { // this should check each module for 'GenerateNotifications.php' class.. //and run it if found.. + + + $modules = array_reverse($this->modulesList()); + + // move 'project' one to the end... + foreach ($modules as $module){ + if(in_array($module, $this->disabled)){ + continue; + } + $file = $this->rootDir. "/Pman/$module/GenerateNotifications.php"; + if(!file_exists($file)){ + continue; + } + + require_once $file; + $class = "Pman_{$module}_GenerateNotifications"; + $x = new $class; + if(!method_exists($x, 'generate')){ + continue; + }; + //echo "$module\n"; + $x->updateData(); + } + + } }