Subversion Repositories oidplus

Rev

Rev 284 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 284 Rev 288
Line 49... Line 49...
49
                                $out['text'] = $this->showRAInfo($ra_email);
49
                                $out['text'] = $this->showRAInfo($ra_email);
50
                        }
50
                        }
51
 
51
 
52
                        $out['text'] .= '<br><br>';
52
                        $out['text'] .= '<br><br>';
53
 
53
 
54
                        foreach (OIDplusObject::getRaRoots($ra_email) as $loc_root) {
54
                        $ra_roots = OIDplusObject::getRaRoots($ra_email);
-
 
55
                        if (count($ra_roots) == 0) {
-
 
56
                                if (empty($ra_email)) {
-
 
57
                                        $out['text'] .= '<p><i>None</i></p>';
-
 
58
                                } else {
-
 
59
                                        $out['text'] .= '<p><i>This RA has no objects</i></p>';
-
 
60
                                }
-
 
61
                        } else {
-
 
62
                                foreach ($ra_roots as $loc_root) {
55
                                $ico = $loc_root->getIcon();
63
                                        $ico = $loc_root->getIcon();
56
                                $icon = !is_null($ico) ? $ico : OIDplus::webpath(__DIR__).'treeicon_link.png';
64
                                        $icon = !is_null($ico) ? $ico : OIDplus::webpath(__DIR__).'treeicon_link.png';
57
                                $out['text'] .= '<p><a '.OIDplus::gui()->link($loc_root->nodeId()).'><img src="'.$icon.'"> Jump to RA root '.$loc_root->objectTypeTitleShort().' '.$loc_root->crudShowId(OIDplusObject::parse($loc_root::root())).'</a></p>';
65
                                        $out['text'] .= '<p><a '.OIDplus::gui()->link($loc_root->nodeId()).'><img src="'.$icon.'"> Jump to RA root '.$loc_root->objectTypeTitleShort().' '.$loc_root->crudShowId(OIDplusObject::parse($loc_root::root())).'</a></p>';
58
                        }
66
                                }
-
 
67
                        }
59
 
68
 
60
                        if (!empty($ra_email)) {
69
                        if (!empty($ra_email)) {
61
                                $res = OIDplus::db()->query("select * from ###ra where email = ?", array($ra_email));
70
                                $res = OIDplus::db()->query("select * from ###ra where email = ?", array($ra_email));
62
                                if ($res->num_rows() > 0) {
71
                                if ($res->num_rows() > 0) {
63
                                        if (OIDplus::authUtils()::isRALoggedIn($ra_email) || OIDplus::authUtils()::isAdminLoggedIn()) {
72
                                        if (OIDplus::authUtils()::isRALoggedIn($ra_email) || OIDplus::authUtils()::isAdminLoggedIn()) {