26require_once NOALYSS_INCLUDE.
'/database/default_menu_sql.class.php';
49 $idx = $tmenu->getp(
'md_code');
50 $this->a_menu_def[
$idx] = $tmenu->getp(
'me_code');
52 $this->code = explode(
',',
'code_follow,code_invoice,code_feenote',);
57 $code_invoice =
new IText(
'code_invoice', $this->a_menu_def[
'code_invoice']);
58 $code_follow =
new IText(
'code_follow', $this->a_menu_def[
'code_follow']);
59 $code_feenote =
new IText(
'code_feenote', $this->a_menu_def[
'code_feenote']);
60 echo
'<div class="form-group">';
61 echo
'<div class="form-text">' .
'<label for="code_invoice">'._(
'Code AD pour création facture depuis gestion').
62 "</label>".
"</div>".
'<div class="form-text">' .$code_invoice->input() .
'</div>';
64 echo
'<div class="form-text">' .
'<label for="code_follow">'._(
'Code AD pour appel gestion').
65 "</label>".
"</div>".
'<div class="form-text">' .$code_follow->input() .
'</div>';
67 echo
'<div class="form-text">' .
'<label for="code_feenote">'._(
'Code AD pour création note de frais ou facture achat').
68 "</label>".
"</div>".
'<div class="form-text">' .$code_feenote->input() .
'</div>';
75 $count =
$cn->get_value(
'select count(*) from v_menu_description_favori where '
76 .
'code = $1', array($p_string));
79 throw new Exception(
'code_inexistant');
85 foreach ($this->code as
$code)
91 function set($p_string, $p_value)
93 if (in_array($p_string, $this->code) ==
false)
95 throw new Exception(
"code_invalid");
97 $this->a_menu_def[$p_string] = $p_value;
99 function get ($p_string)
101 return $this->a_menu_def[$p_string];
110 foreach ($this->code as $key =>
$value)
112 $cn->exec_sql(
'update menu_default set me_code=$1 where
115 }
catch (Exception
$e)
118 echo
$e->getMessage();
127 echo
h2(
'Constructor',
'');
130 if (count(
$a->a_menu_def) != 2)
134 echo
h2(
"input_value",
"");
139 echo
h2(
'Verify must failed');
140 $a->set(
'code_follow',
'MEMNU/MEMEM/');
142 }
catch (Exception
$e) {
145 echo
h2(
'Verify must succeed');
147 $a->set(
'code_follow',
'GESTION/FOLLOW');
150 }
catch (Exception
$e)
157 echo ( assert(
$a->get(
'code_follow')==
'GESTION/FOLLOW') )?
$g_succeed.$a->get(
'code_follow'):
$g_failed.$a->get(
'code_follow');
158 echo ( assert(
$a->get(
'code_invoice')==
'COMPTA/VENMENU/VEN') )?
$g_succeed.$a->get(
'code_invoice'):
$g_failed.$a->get(
'code_invoice');
159 echo
$a->get(
'code_invoice');
h2($p_string, $p_class="", $raw="")
record_log($p_message)
Record an error message into the log file of the server.
global $g_user
if no group available , then stop
static num_row($ret)
wrapper for the function pg_num_rows