/** * Browse all PDF Page Formats. * * @param null $action * * @return void */ public function browse($action = NULL) { // Get list of configured PDF Page Formats $pdfFormatList = CRM_Core_BAO_PdfFormat::getList(); // Add action links to each of the PDF Page Formats $action = array_sum(array_keys($this->links())); foreach ($pdfFormatList as &$format) { $format['action'] = CRM_Core_Action::formLink(self::links(), $action, array('id' => $format['id']), ts('more'), FALSE, 'pdfFormat.manage.action', 'PdfFormat', $format['id']); } // Order Label Formats by weight $returnURL = CRM_Utils_System::url(self::userContext()); CRM_Core_BAO_PdfFormat::addOrder($pdfFormatList, $returnURL); $this->assign('rows', $pdfFormatList); }