public function actionList()
 {
     $pageSize = new resolveActiveForCurrentUserByType('listPageSize', get_class($this->getModule()));
     $savedReport = new SavedReport(false);
     $searchForm = new ReportsSearchForm($savedReport);
     $listAttributesSelector = new ListAttributesSelector('ReportsListView', get_class($this->getModule()));
     $searchForm->setListAttributesSelector($listAttributesSelector);
     $dataProvider = $this->resolveSearchDataProvider($searchForm, $pageSize, null, 'ReportsSearchView');
     $title = Zurmo::t('ReportsModule', 'Reports');
     $breadCrumbLinks = array($title);
     if (isset($_GET['ajax']) && $_GET['ajax'] == 'list-view') {
         $mixedView = $this->makeListView($searchForm, $dataProvider);
         $view = new ReportsPageView($mixedView);
     } else {
         $mixedView = $this->makeActionBarSearchAndListView($searchForm, $dataProvider, 'SecuredActionBarForReportsSearchAndListView');
         $view = new ReportsPageView(ZurmoDefaultViewUtil::makeViewWithBreadcrumbsForCurrentUser($this, $mixedView, $breadCrumbLinks, 'ReportBreadCrumbView'));
     }
     echo $view->render();
 }
 public function actionEdit($id, $isBeingCopied = false)
 {
     $savedReport = SavedReport::getById((int) $id);
     ControllerSecurityUtil::resolveCanCurrentUserAccessModule($savedReport->moduleClassName);
     if (!$isBeingCopied) {
         ControllerSecurityUtil::resolveAccessCanCurrentUserWriteModel($savedReport);
     }
     $breadCrumbLinks = array(strval($savedReport));
     $report = SavedReportToReportAdapter::makeReportBySavedReport($savedReport);
     $progressBarAndStepsView = ReportWizardViewFactory::makeStepsAndProgressBarViewFromReport($report);
     $reportWizardView = ReportWizardViewFactory::makeViewFromReport($report, (bool) $isBeingCopied);
     $view = new ReportsPageView(ZurmoDefaultViewUtil::makeTwoViewsWithBreadcrumbsForCurrentUser($this, $progressBarAndStepsView, $reportWizardView, $breadCrumbLinks, 'ReportBreadCrumbView'));
     echo $view->render();
 }