protected function buildApplicationCrumbs() { $crumbs = parent::buildApplicationCrumbs(); $can_create = $this->hasApplicationCapability(FundCreateInitiativesCapability::CAPABILITY); $crumbs->addAction(id(new PHUIListItemView())->setName(pht('Create Initiative'))->setHref($this->getApplicationURI('create/'))->setIcon('fa-plus-square')->setDisabled(!$can_create)->setWorkflow(!$can_create)); return $crumbs; }
protected function buildApplicationCrumbs() { $crumbs = parent::buildApplicationCrumbs(); $crumbs->addTextCrumb(pht('Backers'), $this->getApplicationURI('backers/')); if ($this->initiative) { $crumbs->addTextCrumb($this->initiative->getMonogram(), '/' . $this->initiative->getMonogram()); } return $crumbs; }
$end_date = $fund->get_end_date(); //CALCULATE DAYS LEFT $current_date = new DateTime(date('Y-m-d'), new DateTimeZone('Asia/Kathmandu')); $end_date = new DateTime($end_date, new DateTimeZone('Asia/Kathmandu')); $interval = $current_date->diff($end_date); $remaining = $interval->format('%a'); include_once ROOT_PATH . "fundraiser/views/container.php"; } else { header("Location: index.php?page=fund&m=index"); } } else { header("Location: index.php?page=fund&m=index"); } } } $fundcontroller = new FundController(); if (isset($_GET['m'])) { $method = $_GET['m']; } else { $method = "index"; } switch ($method) { case "index": $fundcontroller->index(); break; case "create": $fundcontroller->create(); break; case "campaign": $fundcontroller->campaign(); break;