Fix #7123 - getting abra ready to test
[Pman.Xtuple] / Pman.php
1 <?php
2
3
4 class Pman_Xtuple_Pman extends Pman {
5     
6     
7     function getAuth() {
8         $this->jerr("access denied");
9     }
10     
11     function init($pman = flase)
12     {   
13         // add the offices to the uiConfig.
14         if (empty($pman->uiConfig)) {
15             $pman->uiConfig = array();
16         }
17         
18         // scan the root directory for xx.php
19         foreach(scandir($pman->rootDir) as $fn) {
20             if (!is_file($pman->rootDir.'/'.$fn)) {
21                 continue;
22             }
23             if (!preg_match('/^[a-z]{2}\.php$/',$fn)) {
24                 continue;
25             }
26             $offices[] = preg_replace('/\.php$/', '', $fn);
27             
28             
29         };
30         $pman->uiConfig['xtuple_offices'] = $offices;
31         
32         // add the default config..
33         if(!empty($pman->bootLoader->uiConfig)){
34             foreach ($pman->bootLoader->uiConfig as $k => $v){
35                 $pman->uiConfig[$k] = $v;
36             }
37         }
38         
39     }
40     
41 }