diff --git a/html/style-print.css b/html/style-print.css index 6d3abaa86..136054b91 100644 --- a/html/style-print.css +++ b/html/style-print.css @@ -289,4 +289,5 @@ div.myfieldset } #info_div { display:none; -} \ No newline at end of file +} +p#breakhere {page-break-before: always} \ No newline at end of file diff --git a/html/style.css b/html/style.css index ec0ddb6cd..be56d8179 100644 --- a/html/style.css +++ b/html/style.css @@ -1348,4 +1348,4 @@ div#error_content_div { color:error; font-weight: bold; text-align: center; -} \ No newline at end of file +} diff --git a/include/action.common.inc.php b/include/action.common.inc.php index a1542c6a8..54117920f 100644 --- a/include/action.common.inc.php +++ b/include/action.common.inc.php @@ -41,23 +41,37 @@ $supl_hidden.=HtmlInput::hidden('ac', $_REQUEST['ac']); /*-----------------------------------------------------------------------------*/ /* For other action /*-----------------------------------------------------------------------------*/ -if ( isset ($_GET['other_action_bt'])) { - var_dump($_GET); +if ( isset ($_POST['other_action_bt'])) { /** * The action id are in the array mag_id * the tag to remove are vin the array remtag * the tag to add are in the array addtag * the state in ag_state */ - if ( isset ($_GET['ag_id'])) { - switch ($_GET['othact']) { + if ( isset ($_POST['mag_id'])) { + switch ($_POST['othact']) { case 'IMP': //Impression + Follow_Up::action_print($cn,$_POST); + exit(0); + break; case 'ST': // Etat + Follow_Up::action_set_state($cn, $_POST); + break; case 'ETIREM': //tag + Follow_Up::action_tag_remove($cn, $_POST); + break; case 'ETIADD': + Follow_Up::action_tag_add($cn, $_POST); + break; + case 'ETICLEAR': + Follow_Up::action_tag_clear($cn,$_POST); + break; + case 'DOCREM': + Follow_Up::action_remove($cn, $_POST); + break; } } } diff --git a/include/class_follow_up.php b/include/class_follow_up.php index 43272035a..6c8635663 100644 --- a/include/class_follow_up.php +++ b/include/class_follow_up.php @@ -87,10 +87,10 @@ class Follow_Up * \param p_cn database connection */ - function __construct($p_cn) + function __construct($p_cn,$p_id=0) { $this->db = $p_cn; - $this->ag_id=0; + $this->ag_id=$p_id; $this->f_id = 0; } static function sql_security_filter($cn,$p_mode) @@ -117,7 +117,7 @@ class Follow_Up * \note If ag_id is not equal to zero then it is an update otherwise * it is a new document * - * \param $p_view if set to true the form will be in readonly mode (value: true or false) + * \param $p_view form will be in readonly mode (value: READ, UPD or NEW ) * \param $p_gen true we show the tag for generating a doc (value : true or false) and adding files * \param $p_base is the ac parameter * \param $retour is the html code for the return button @@ -508,7 +508,7 @@ class Follow_Up $a_tag=$this->tag_get(); /* get template */ ob_start(); - require_once 'template/detail-action.php'; + require 'template/detail-action.php'; $content = ob_get_contents(); ob_end_clean(); $r.=$content; @@ -1209,7 +1209,7 @@ class Follow_Up */ $query = Follow_Up::create_query($cn); - echo '