Esempio n. 1
0
$export_deck_title->set_br(2);
$export_deck_title->set_color($_CAMILA['page_title_color'], $_CAMILA['page_title_boxcolor']);
$_CAMILA['page']->add_text($export_deck_title);
$form = new phpform('camila');
$form->submitbutton = camila_get_translation('camila.export.xml2pdf');
$form->drawrules = false;
$form->preservecontext = true;
global $_CAMILA;
$pos = strrpos($_CAMILA['page_url'], '?');
if ($pos !== false) {
    new form_hidden($form, substr($_CAMILA['page_url'], $pos + 1));
}
new form_template_file_listbox($form, 'xml2pdf', camila_get_translation('camila.export.template'), CAMILA_TMPL_DIR . '/' . $_CAMILA['lang'], false, $_CAMILA['adm_usergroup'], '', true);
new form_text_separator(&$form, camila_get_translation('camila.export.options'));
$nodata = 'n';
new form_checklist($form, xml2pdf_checklist_options, '', array(camila_get_translation('camila.export.nodata')), array('y'));
new form_text_separator(&$form, '');
$form->process();
$form->draw();
$export_format = 'camila_xml2pdf';
$url = $_SERVER['PHP_SELF'] . '?' . $_SERVER['QUERY_STRING'];
$url = ereg_replace("&" . $export_format, '', $url);
$url = ereg_replace("\\?" . $export_format, '', $url);
$myLink = new CHAW_link(camila_get_translation('camila.back.page'), $url);
$myImage = new HAW_image(CAMILA_IMG_DIR . 'wbmp/resultset_previous.wbmp', CAMILA_IMG_DIR . 'png/resultset_previous.png', '-');
$myLink->add_image($myImage);
$_CAMILA['page']->add_link($myLink);
$_CAMILA['page']->use_simulator(CAMILA_CSS_DIR . 'skin0.css');
require CAMILA_DIR . 'deck_settings.php';
require CAMILA_DIR . 'footer.php';
exit;
Esempio n. 2
0
 function draw_footer()
 {
     if (!$this->drawnavigationbox) {
         return;
     }
     global $_CAMILA;
     if ($this->rows > 0 && !$_CAMILA['page']->camila_exporting()) {
         if ($this->page > 2) {
             $myLink = new CHAW_link(camila_get_translation('camila.report.navbox.first'), basename($_SERVER['PHP_SELF']) . $this->urlappend . '&f0=' . $_REQUEST['f0'] . '&camila_pagnum=1');
             $myLink->set_br(0);
             $_CAMILA['page']->add_link($myLink);
             $text = new CHAW_text(' | ');
             $text->set_br(0);
             $_CAMILA['page']->add_text($text);
         }
         if ($this->page > 1) {
             $myLink = new CHAW_link(camila_get_translation('camila.report.navbox.prev'), basename($_SERVER['PHP_SELF']) . $this->urlappend . '&f0=' . $_REQUEST['f0'] . '&camila_pagnum=' . ($this->page - 1));
             $myLink->set_br(0);
             $_CAMILA['page']->add_link($myLink);
         }
         $text = new CHAW_text(' ' . camila_get_translation('camila.report.navbox.page') . ' ' . $this->page . '/' . ceil($this->totalrows / $this->rows) . ' ');
         $text->set_br(0);
         $_CAMILA['page']->add_text($text);
         if ($this->page < ceil($this->totalrows / $this->rows)) {
             $myLink = new CHAW_link(camila_get_translation('camila.report.navbox.next'), basename($_SERVER['PHP_SELF']) . $this->urlappend . '&f0=' . $_REQUEST['f0'] . '&camila_pagnum=' . ($this->page + 1));
             $myLink->set_br(0);
             $_CAMILA['page']->add_link($myLink);
         }
         if ($this->page < ceil($this->totalrows / $this->rows) - 1) {
             $text = new CHAW_text(' | ');
             $text->set_br(0);
             $_CAMILA['page']->add_text($text);
             $myLink = new CHAW_link(camila_get_translation('camila.report.navbox.last'), basename($_SERVER['PHP_SELF']) . $this->urlappend . '&f0=' . $_REQUEST['f0'] . '&camila_pagnum=' . ceil($this->totalrows / $this->rows));
             $myLink->set_br(0);
             $_CAMILA['page']->add_link($myLink);
         }
         $text = new CHAW_text(' | ');
         $text->set_br(0);
         $_CAMILA['page']->add_text($text);
         $myLink = new CHAW_link(camila_get_translation('camila.report.navbox.allpages') . ' (' . $this->totalrows . ' ' . camila_get_translation('camila.report.navbox.rows') . ')', basename($_SERVER['PHP_SELF']) . $this->urlappend . '&f0=' . $_REQUEST['f0'] . '&camila_pagnum=-1');
         $myLink->set_br(0);
         if ($this->page > 0) {
             $_CAMILA['page']->add_link($myLink);
         }
         $text = new CHAW_text(' | ');
         $text->set_br(0);
         $_CAMILA['page']->add_text($text);
         $myLink = new CHAW_link(camila_get_translation('camila.report.navbox.countorderby'), basename($_SERVER['PHP_SELF']) . $this->urlappend . '&f0=' . $_REQUEST['f0'] . '&camila_pagnum=-1&camila_countorderby');
         $myLink->set_br(0);
         if ($this->page > 0 && !$this->gbyconditionpresent) {
             $_CAMILA['page']->add_link($myLink);
         }
     }
     if (!$_CAMILA['page']->camila_exporting()) {
         if ($this->defaultfields != '') {
             $text = new CHAW_text(' | ');
             $text->set_br(0);
             if ($this->rows > 0 && !$this->gbyconditionpresent) {
                 $_CAMILA['page']->add_text($text);
             }
             $myLink = new CHAW_link(camila_get_translation('camila.report.navbox.addremcols'), basename($_SERVER['PHP_SELF']) . $this->urlappend . '&f0=' . $_REQUEST['f0'] . '&camila_pagnum=' . $this->page . '&camila_editcols=y');
             $myLink->set_br(0);
             if ($this->page > 0 && !$this->gbyconditionpresent) {
                 $_CAMILA['page']->add_link($myLink);
             }
         }
         if (isset($this->additional_links)) {
             foreach ($this->additional_links as $key => $value) {
                 $text = new CHAW_text(' | ');
                 $text->set_br(0);
                 $_CAMILA['page']->add_text($text);
                 $link = new CHAW_link($key, $value);
                 if (is_object($this->additional_links_images[$key])) {
                     $link->add_image($this->additional_links_images[$key]);
                 }
                 $link->set_br(0);
                 $_CAMILA['page']->add_link($link);
             }
         }
         $text = new CHAW_text('');
         $_CAMILA['page']->add_text($text);
     }
 }