28if (!defined(
'ALLOWED'))
29 die(
'Appel direct ne sont pas permis');
30require_once NOALYSS_INCLUDE.
'/database/poste_analytique_sql.class.php';
46 if ($new->isAppend()==
true)
48 $ret.=
'<div style="position:absolute;top:25%" id="anc_div_add" class="inner_box">';
50 $ret.=
'<form method="post">';
51 $ret.=dossier::hidden();
52 $ret.= $new->form_new();
61 $ret.=
'<div class="content">'.
62 '<h2 class="notice">'.
63 _(
"Maximum de plan analytique est atteint").
74 if ($new->isAppend()==
false)
76 $ret.=
'<h2 class="notice">'.
77 _(
"Maximum de plan analytique est atteint").
83 $new->name=
$http->post(
"pa_name");
84 $new->description=
$http->post(
"pa_description");
112 $ret.=
'<div class="content">';
116 $ret.=
'<form method="GET" action="export.php" style="display:inline">';
123 'onclick="return confirm_box(\'remove_analytic_plan\',\'Effacer ?\',function () {window.location=\'do.php?ac='.
$_REQUEST[
'ac'].
'&pa_id='.
$_GET[
'pa_id'].
'&sa=pa_delete&'.
$str_dossier.
'\';})
"',
128 //---------------------------------------------------------------------
131 //---------------------------------------------------------------------
134 $new=new Anc_Plan($cn, $pa_id);
136 $ret.='<div class="content" style="margin-top:1rem
">';
137 $anc=new Poste_analytique_SQL($cn);
139 $accounting=new Anc_Account_Table($anc);
140 $accounting->set_callback("ajax_misc.php
");
141 $accounting->add_json_param("op
", "anc_accounting
");
142 $accounting->add_json_param("pa_id", $pa_id);
143 $accounting->set_sort_column("po_name
");
145 $accounting->create_js_script();
146 $accounting->display_table(" where
pa_id = $1 order by po_name
",array($pa_id));
147 $ret.=ob_get_clean();
151//---------------------------------------------------------------------------
154//---------------------------------------------------------------------------
158 $obj=new Anc_Plan($cn);
159 $list=$obj->get_list();
162 $ac=$http->request("ac
");
166 $url=http_build_query(array("sa
"=>"add_pa
","ac
"=>$ac,
167 "gDossier
"=>Dossier::id()));
169 echo '<TABLE class="vert_mtitle
">';
170 echo '<TR><TD class="first
">';
171 echo '<a href="?
'.$url.'">'._("Ajout d
'un plan analytique").'</a>
';
176 if (!isset($_REQUEST['sa
']))
177 echo '<div
class=
"notice">
'.
178 _("Aucun plan analytique n'est défini
").
183 $url=http_build_query(array("sa
"=>"add_pa
","ac
"=>$ac,
184 "gDossier
"=>Dossier::id()));
187 echo '<table class="vert_mtitle
">';
188 if ($obj->isAppend()==true)
190 echo '<TR><TD class="first
">';
191 echo '<a href="?
'.$url.'">'._("Ajout d
'un plan analytique").'</a>
';
194 foreach ($list as $line)
196 $url=http_build_query(array("sa"=>"pa_detail","ac"=>$ac,"pa_id"=>$line['id'],
197 "gDossier"=>Dossier::id()));
200 '<a href=
"?'.$url.'">
'.
203 echo h($line['description
'])."</a>";
213//---------------------------------------------------------------------------
214// show the content part
217//---------------------------------------------------------------------------
else $card content[$j]['j_montant']
Concerns the Analytic plan (table plan_analytique)
static get()
return a string to put to gDossier into a GET
static hidden()
return a string to set gDossier into a FORM