Inheritance: extends Flake\Core\Model\Db
コード例 #1
0
ファイル: Dashboard.php プロジェクト: paolomainardi/Baikal
 public function render()
 {
     $oView = new \BaikalAdmin\View\Dashboard();
     $oView->setData("BAIKAL_VERSION", BAIKAL_VERSION);
     # Services status
     $oView->setData("BAIKAL_CAL_ENABLED", BAIKAL_CAL_ENABLED);
     $oView->setData("BAIKAL_CARD_ENABLED", BAIKAL_CARD_ENABLED);
     # Statistics: Users
     $iNbUsers = \Baikal\Model\User::getBaseRequester()->count();
     $oView->setData("nbusers", $iNbUsers);
     # Statistics: CalDAV
     $iNbCalendars = \Baikal\Model\Calendar::getBaseRequester()->count();
     $oView->setData("nbcalendars", $iNbCalendars);
     $iNbEvents = \Baikal\Model\Calendar\Event::getBaseRequester()->count();
     $oView->setData("nbevents", $iNbEvents);
     # Statistics: CardDAV
     $iNbBooks = \Baikal\Model\AddressBook::getBaseRequester()->count();
     $oView->setData("nbbooks", $iNbBooks);
     $iNbContacts = \Baikal\Model\AddressBook\Contact::getBaseRequester()->count();
     $oView->setData("nbcontacts", $iNbContacts);
     return $oView->render();
 }
コード例 #2
0
ファイル: User.php プロジェクト: Zyko0/Baikal
 public function getAddressBooksBaseRequester()
 {
     $oBaseRequester = \Baikal\Model\AddressBook::getBaseRequester();
     $oBaseRequester->addClauseEquals("principaluri", "principals/" . $this->get("username"));
     return $oBaseRequester;
 }
コード例 #3
0
 function linkDeleteConfirm(\Baikal\Model\AddressBook $oModel)
 {
     return self::buildRoute(["user" => $this->currentUserId(), "delete" => $oModel->get("id"), "confirm" => 1]) . "#message";
 }