noalyss  Version-6.9.1.8
 All Data Structures Namespaces Files Functions Variables Pages
class_periode.php
Go to the documentation of this file.
1 <?php
2 /*
3  * This file is part of NOALYSS.
4  *
5  * NOALYSS is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * NOALYSS is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13  * GNU General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with NOALYSS; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 */
19 
20 // Copyright Author Dany De Bontridder danydb@aevalys.eu
21 
22 /*!\file
23  * \brief definition of the class periode
24  */
25 /*!
26  * \brief For the periode tables parm_periode and jrn_periode
27  */
28 require_once NOALYSS_INCLUDE.'/lib/ac_common.php';
29 require_once NOALYSS_INCLUDE.'/lib/class_database.php';
30 class Periode
31 {
32  var $cn; /*!< database connection */
33  var $jrn_def_id; /*!< the jr, 0 means all the ledger*/
34  var $p_id; /*!< pk of parm_periode */
35  var $status; /*!< status is CL for closed, OP for
36  open and CE for centralized */
37  var $p_start; /*!< start of the periode */
38  var $p_end; /*!< end of the periode */
39  function __construct($p_cn,$p_id=0)
40  {
41  $this->p_id=$p_id;
42  $this->cn=$p_cn;
43  }
44  function set_jrn($p_jrn)
45  {
46  $this->jrn_def_id=$p_jrn;
47  }
48  function set_periode($pp_id)
49  {
50  $this->p_id=$pp_id;
51  }
52  /*!\brief return the p_id of the start and the end of the exercice
53  *into an array
54  *\param $p_exercice
55  *\return array [start]=>,[end]=>
56  */
58  {
59  $sql_start="select p_id from parm_periode where p_exercice=$1 order by p_start ASC limit 1";
60  $start=$this->cn->get_value($sql_start,array($p_exercice));
61  $sql_end="select p_id from parm_periode where p_exercice=$1 order by p_end DESC limit 1";
62  $end=$this->cn->get_value($sql_end,array($p_exercice));
63  return array("start"=>$start,"end"=>$end);
64  }
65  /*!\brief check if a periode is closed. If jrn_def_id is set to a no zero value then check only for this ledger
66  *\return 1 is the periode is closed otherwise return 0
67  */
68  function is_closed()
69  {
70  if ( $this->jrn_def_id != 0 )
71  $sql="select status from jrn_periode ".
72  " where jrn_def_id=".$this->jrn_def_id.
73  " and p_id =".$this->p_id;
74  else
75  $sql="select p_closed as status from parm_periode ".
76  " where ".
77  " p_id =".$this->p_id;
78  $res=$this->cn->exec_sql($sql);
80  if ( $status == 'CL' || $status=='t' ||$status=='CE')
81  return 1;
82  return 0;
83  }
84  ///Return 1 if the periode is open otherwise 0
85  //!\note For only a ledger you must set Periode::jrn_def_id to the ledger id
86  function is_open()
87  {
88  /* if jrn_Def_id == 0 then we check the global otherwise we check
89  a ledger */
90  if ( $this->jrn_def_id != 0 )
91  $sql="select status from jrn_periode ".
92  " where jrn_def_id=".$this->jrn_def_id.
93  " and p_id =".$this->p_id;
94  else
95  $sql="select p_closed as status from parm_periode ".
96  " where ".
97  " p_id =".$this->p_id;
98  $res=$this->cn->exec_sql($sql);
100  if ( $status == 'OP' || $status=='f' )
101  return 1;
102  return 0;
103  }
104  ///Return 1 if periode is centralized
105  //!\note deprecated , centralization not used anymore
106  function is_centralized()
107  {
108  if ( $this->jrn_def_id != 0 )
109  $sql="select status from jrn_periode ".
110  " where jrn_def_id=".$this->jrn_def_id.
111  " and p_id =".$this->p_id;
112  else
113  $sql="select p_centralized as status from parm_periode ".
114  " where ".
115  " p_id =".$this->p_id;
116  $res=$this->cn->exec_sql($sql);
118  if ( $status == 'CE' || $status=='t' )
119  return 1;
120  return 0;
121  }
122  function reopen()
123  {
124  if ( $this->jrn_def_id == 0 )
125  {
126  $this->cn->exec_sql("update parm_periode set p_closed='f',p_central='f' where p_id=$1",
127  array($_GET['p_per']));
128 
129  $this->cn->exec_sql("update jrn_periode set status='OP' ".
130  " where p_id = ".$this->p_id);
131 
132  return;
133  }
134  else
135  {
136  $this->cn->exec_sql("update jrn_periode set status='OP' ".
137  " where jrn_def_id=".$this->jrn_def_id." and ".
138  " p_id = ".$this->p_id);
139  /* if one ledger is open then the periode is open */
140  $this->cn->exec_sql("update parm_periode set p_closed=false where p_id=".$this->p_id);
141  return;
142  }
143 
144  }
145  ///Close a periode , if Periode::jrn_def_id is set to a different value
146  /// than 0 , it close only for this ledger id ; otherwise close for all
147  /// periode
148  function close()
149  {
150  if ( $this->jrn_def_id == 0 )
151  {
152  $this->cn->exec_sql("update parm_periode set p_closed=true where p_id=".
153  $this->p_id);
154  $this->cn->exec_sql("update jrn_periode set status='CL' ".
155  " where p_id = ".$this->p_id);
156 
157  return;
158  }
159  else
160  {
161  $this->cn->exec_sql("update jrn_periode set status='CL' ".
162  " where jrn_def_id=".$this->jrn_def_id." and ".
163  " p_id = ".$this->p_id);
164  /* if all ledgers have this periode closed then synchro with
165  the table parm_periode
166  */
167  $nJrn=$this->cn->count_sql( "select * from jrn_periode where ".
168  " p_id=".$this->p_id);
169  $nJrnPeriode=$this->cn->count_sql( "select * from jrn_periode where ".
170  " p_id=".$this->p_id." and status='CL'");
171 
172  if ( $nJrnPeriode==$nJrn)
173  $this->cn->exec_sql("update parm_periode set p_closed=true where p_id=".$this->p_id);
174  return;
175  }
176 
177  }
178  function centralized()
179  {
180  if ( $this->jrn_def_id == 0 )
181  {
182  $this->cn->exec_sql("update parm_periode set p_central=true");
183  return;
184  }
185  else
186  {
187  $this->cn->exec_sql("update jrn_periode set status='CE' ".
188  " where ".
189  " p_id = ".$this->p_id);
190  return;
191  }
192 
193  }
194  /*!
195  * \brief Display all the periode and their status
196  *
197  */
198 
200  {
201  $str_dossier=dossier::get();
202 
203  if ( $this->jrn_def_id==0 )
204  {
205  $Res=$this->cn->exec_sql("select p_id,to_char(p_start,'DD.MM.YYYY') as date_start,to_char(p_end,'DD.MM.YYYY') as date_end,p_central,p_closed,p_exercice,
206  (select count(jr_id) as count_op from jrn where jr_tech_per = p_id) as count_op
207  from parm_periode
208  order by p_start,p_end");
210  echo '<form id="periode_frm" method="POST" onsubmit="return confirm_box(this,\'Confirmez-vous la fermeture des périodes choisies ?\')" >';
211  echo HtmlInput::array_to_hidden(array('ac','gDossier','jrn_def_id','choose'), $_REQUEST);
212  echo '<TABLE ALIGN="CENTER">';
213  echo "</TR>";
214  echo '<th>'.ICheckBox::toggle_checkbox("per_toggle", "periode_frm")."</th>";
215  echo '<TH> Date d&eacute;but </TH>';
216  echo '<TH> Date fin </TH>';
217  echo '<TH> Exercice </TH>';
218  echo "</TR>";
219 
220  for ($i=0;$i<$Max;$i++)
221  {
222  $l_line=Database::fetch_array($Res,$i);
223  $class="even";
224  if ( $i % 2 == 0 )
225  $class="odd";
226  $style='';
227  if ( $l_line['p_closed'] == 't')
228  $style="color:red";
229  echo '<TR class="'.$class.'" style="'.$style.'">';
230  echo '<td>';
231  if ( $l_line['p_closed'] == 'f') {
232  $per_to_close=new ICheckBox('sel_per_close[]');
233  $per_to_close->value=$l_line['p_id'];
234  echo $per_to_close->input();
235  }
236  echo '</td>';
237 
238  echo '<TD ALIGN="CENTER"> '.$l_line['date_start'].'</TD>';
239  echo '<TD ALIGN="CENTER"> '.$l_line['date_end'].'</TD>';
240  echo '<TD ALIGN="CENTER"> '.$l_line['p_exercice'].'</TD>';
241 
242  if ( $l_line['p_closed'] == 't' )
243  {
244  $closed=($l_line['p_central']=='t')?'<TD>Centralis&eacute;e</TD>':'<TD>Ferm&eacute;e</TD>';
245  $change='<TD></TD>';
246  $remove=sprintf(_('Nombre opérations %d'),$l_line['count_op']);
247  $remove=td($remove,' class="mtitle" ');
248  $change=td ('<A class="mtitle" HREF="javascript:void(0)"'
249  . ' onclick="return confirm_box(null,\''._('Confirmez Réouverture').' ?\',function() {window.location=\'do.php?ac='.$_REQUEST['ac'].'&action=reopen&p_per='.$l_line['p_id'].'&'.$str_dossier.'\';} )"> Réouverture</A>',' class="mtitle"');
250 
251  }
252  else
253  {
254  if ($l_line['count_op'] == 0 )
255  {
256  $change=HtmlInput::display_periode($l_line['p_id']);
257  }
258  else
259  {
260  $change="Non modifiable";
261  }
262  $change=td($change,' class="mtitle" ');
263  $reopen=td("");
264 
265 
266  $remove='<TD class="mtitle">';
267 
268 
269  if ($l_line['count_op'] == 0 )
270  {
271  $go='do.php?'.http_build_query(array('ac'=>$_REQUEST['ac'],
272  'action'=>'delete_per',
273  'p_per'=>$l_line['p_id'],
274  'gDossier'=>Dossier::id()));
275 
276  $remove.='<A class="mtitle" HREF="javascript:void(0)" '
277  . 'onclick="return confirm_box (null,\''._('Confirmez effacement ?').'\',function() { window.location=\''.$go.'\'});" >'
278  . ' Efface</A>';
279  }
280  else
281  {
282  $remove.=sprintf(_('Nombre opérations %d'),$l_line['count_op']);
283  }
284  $remove.='</td>';
285  }
286  echo $change;
287 
288  echo $remove;
289 
290  echo '</TR>';
291 
292  }
293  echo '</table>';
294  echo '<p style="text-align:center">';
295  echo HtmlInput::hidden("close_per", 1);
296  echo HtmlInput::submit('close_per_bt','Fermeture des périodes sélectionnées');
297  echo '</p>';
298  echo '</form>';
299  $but=new IButton('show_per_add','Ajout d\'une période');
300  $but->javascript="$('periode_add_div').show();";
301  echo $but->input();
302  echo '<div class="inner_box" style="width:40%;" id="periode_add_div">';
303  echo HtmlInput::title_box("Ajout d'une période","periode_add_div","hide");
304  echo '<FORM METHOD="POST">';
305  echo dossier::hidden();
306  $istart=new IDate('p_date_start');
307  $iend=new IDate('p_date_end');
308  $iexercice=new INum('p_exercice');
309  $iexercice->size=5;
310  echo '<table>';
311  echo '<TR> ';
312  echo td('Date de début');
313  echo td($istart->input());
314  echo '</tr><tr>';
315  echo td('Date de fin');
316  echo td($iend->input());
317 
318  echo '</tr><tr>';
319  echo td('Exercice');
320  echo td($iexercice->input());
321 
322  echo '</TABLE>';
323 
324  echo HtmlInput::submit('add_per','Valider');
325  echo '</FORM>';
326  echo '</div>';
327  echo create_script("$('periode_add_div').hide();new Draggable('periode_add_div',{starteffect:function()
328  {
329  new Effect.Highlight(obj.id,{scroll:window,queue:'end'});
330  }}
331  );");
332  }
333  else
334  {
335  $Res=$this->cn->exec_sql("select p_id,to_char(p_start,'DD.MM.YYYY') as date_start,to_char(p_end,'DD.MM.YYYY') as date_end,status,p_exercice
336  from parm_periode join jrn_periode using (p_id) where jrn_def_id=".$this->jrn_def_id."
337  order by p_start,p_end");
338  $Max=Database::num_row($Res);
339  $r=$this->cn->exec_sql('select jrn_Def_name from jrn_Def where jrn_Def_id='.
340  $this->jrn_def_id);
341  $jrn_name=Database::fetch_result($r,0,0);
342  echo '<h2> Journal '.$jrn_name.'</h2>';
343  echo '<form id="periode_frm" method="POST" onsubmit="return confirm_box(this,\'Confirmez-vous la fermeture des périodes choisies ?\')" >';
344  echo HtmlInput::array_to_hidden(array('ac','gDossier','jrn_def_id','choose'), $_REQUEST);
345 
346  echo '<TABLE ALIGN="CENTER">';
347  echo "</TR>";
348  echo '<th>'.ICheckBox::toggle_checkbox("per_toggle", "periode_frm")."</th>";
349  echo '<TH> Date d&eacute;but </TH>';
350  echo '<TH> Date fin </TH>';
351  echo '<TH> Exercice </TH>';
352  echo "</TR>";
353 
354  for ($i=0;$i<$Max;$i++)
355  {
356  $l_line=Database::fetch_array($Res,$i);
357  if ( $l_line['status'] != 'OP' )
358  echo '<TR style="COLOR:RED">';
359  else
360  echo '<TR>';
361  echo '<td>';
362  if ( $l_line['status'] == 'OP') {
363  $per_to_close=new ICheckBox('sel_per_close[]');
364  $per_to_close->value=$l_line['p_id'];
365  echo $per_to_close->input();
366  }
367  echo '</td>';
368  echo '<TD ALIGN="CENTER"> '.$l_line['date_start'].'</TD>';
369  echo '<TD ALIGN="CENTER"> '.$l_line['date_end'].'</TD>';
370  echo '<TD ALIGN="CENTER"> '.$l_line['p_exercice'].'</TD>';
371  $closed="";
372  if ( $l_line['status'] != 'OP' )
373  {
374  $go='do.php?'.http_build_query(array('ac'=>$_REQUEST['ac'],
375  'action'=>'reopen',
376  'p_per'=>$l_line['p_id'],
377  'gDossier'=>Dossier::id(),
378  'jrn_def_id'=>$this->jrn_def_id));
379 
380  $closed=td ('<A class="mtitle" HREF="javascript:void(0)" '
381  . 'onclick="return confirm_box(null,\''._('Confirmez Réouverture').' ?\',function() {window.location=\''.$go.'\';} );"> Réouverture</A>',' class="mtitle"');
382  }
383 
384  echo "$closed";
385 
386  echo '</TR>';
387 
388  }
389  echo '</TABLE>';
390  echo '<p style="text-align:center">';
391  echo HtmlInput::submit('close_per','Fermeture des périodes sélectionnées');
392  echo '</p>';
393  echo '</form>';
394 
395  }
396  }
397  function insert($p_date_start,$p_date_end,$p_exercice)
398  {
399  try
400  {
401 
402  if (isDate($p_date_start) == null ||
403  isDate($p_date_end) == null ||
404  strlen (trim($p_exercice)) == 0 ||
405  (string) $p_exercice != (string)(int) $p_exercice
406  ||$p_exercice < COMPTA_MIN_YEAR || $p_exercice > COMPTA_MAX_YEAR)
407 
408  {
409  throw new Exception ("Paramètre invalide");
410  }
411  $p_id=$this->cn->get_next_seq('s_periode');
412  $sql=sprintf(" insert into parm_periode(p_id,p_start,p_end,p_closed,p_exercice)".
413  "values (%d,to_date('%s','DD.MM.YYYY'),to_date('%s','DD.MM.YYYY')".
414  ",'f','%s')",
415  $p_id,
416  $p_date_start,
417  $p_date_end,
418  $p_exercice);
419  $this->cn->start();
420  $Res=$this->cn->exec_sql($sql);
421  $Res=$this->cn->exec_sql("insert into jrn_periode (jrn_def_id,p_id,status) ".
422  "select jrn_def_id,$p_id,'OP' from jrn_def");
423  $this->cn->commit();
424  }
425  catch (Exception $e)
426  {
427  $this->cn->rollback();
428  return 1;
429  }
430  return 0;
431  }
432  /*!\brief load data from database
433  *\return 0 on success and -1 on error
434  */
435  function load()
436  {
437  if ($this->p_id == '') $this->p_id=-1;
438  $row=$this->cn->get_array("select p_start,p_end,p_exercice,p_closed,p_central from parm_periode where p_id=$1",
439  array($this->p_id));
440  if ($row == null ) return -1;
441 
442  $this->p_start=$row[0]['p_start'];
443  $this->p_end=$row[0]['p_end'];
444  $this->p_exercice=$row[0]['p_exercice'];
445  $this->p_closed=$row[0]['p_closed'];
446  $this->p_central=$row[0]['p_central'];
447  return 0;
448  }
449 
450  /*!\brief return the max and the min periode of the exercice given
451  *in parameter
452  *\param $p_exercice is the exercice
453  *\return an array of Periode object
454  */
455  function get_limit($p_exercice)
456  {
457 
458  $max=$this->cn->get_value("select p_id from parm_periode where p_exercice=$1 order by p_start asc limit 1",array($p_exercice));
459  $min=$this->cn->get_value("select p_id from parm_periode where p_exercice=$1 order by p_start desc limit 1",array($p_exercice));
460  $rMax=new Periode($this->cn);
461  $rMax->p_id=$max;
462  if ( $rMax->load() ) throw new Exception('Periode n\'existe pas');
463  $rMin=new Periode($this->cn);
464  $rMin->p_id=$min;
465  if ( $rMin->load() ) throw new Exception('Periode n\'existe pas');
466  return array($rMax,$rMin);
467  }
468  /*!
469  * \brief Give the start & end date of a periode
470  * \param $p_periode is the periode id, if omitted the value is the current object
471  * \return array containing the start date & the end date, index are p_start and p_end or NULL if
472  * nothing is found
473  \verbatim
474  $ret['p_start']=>'01.01.2009'
475  $ret['p_end']=>'31.01.2009'
476  \endverbatim
477  */
478  public function get_date_limit($p_periode = 0)
479  {
480  if ( $p_periode == 0 ) $p_periode=$this->p_id;
481  $sql="select to_char(p_start,'DD.MM.YYYY') as p_start,
482  to_char(p_end,'DD.MM.YYYY') as p_end
483  from parm_periode
484  where p_id=$1";
485  $Res=$this->cn->exec_sql($sql,array($p_periode));
486  if ( Database::num_row($Res) == 0) return null;
487  return Database::fetch_array($Res,0);
488 
489  }
490  /*!\brief return the first day of periode
491  *the this->p_id must be set
492  *\return a string with the date (DD.MM.YYYY)
493  */
494  public function first_day($p=0)
495  {
496  if ($p==0) $p=$this->p_id;
497  list($p_start,$p_end)=$this->get_date_limit($p);
498  return $p_start;
499  }
500  /*!\brief return the last day of periode
501  *the this->p_id must be set
502  *\return a string with the date (DD.MM.YYYY)
503  */
504  public function last_day($p=0)
505  {
506  if ($p==0) $p=$this->p_id;
507  list($p_start,$p_end)=$this->get_date_limit($p);
508  return $p_end;
509  }
510 
511  function get_exercice($p_id=0)
512  {
513  if ( $p_id == 0 ) $p_id=$this->p_id;
514  $sql="select p_exercice from parm_periode where p_id=".$p_id;
515  $Res=$this->cn->exec_sql($sql);
516  if ( Database::num_row($Res) == 0) return null;
517  return Database::fetch_result($Res,0,0);
518 
519  }
520  /*!\brief retrieve the periode thanks the date_end
521  *\param $p_date format DD.MM.YYYY
522  * \return the periode id
523  *\exception if not periode is found or if more than one periode is found
524  */
526  {
527  $sql="select p_id from parm_periode where p_start <= to_date($1,'DD.MM.YYYY') and p_end >= to_date($1,'DD.MM.YYYY') ";
528  $ret=$this->cn->exec_sql($sql,array($p_date));
529  $nb_periode=Database::num_row($ret);
530  if ( $nb_periode == 0 )
531  throw (new Exception('Aucune période trouvée',101));
532  if ( $nb_periode > 1 )
533  throw (new Exception("Trop de périodes trouvées $nb_periode pour $p_date",100));
535  $this->p_id=$per;
536  return $per;
537  }
538  /**
539  *add a exerice of 13 periode
540  */
541  function insert_exercice($p_exercice,$nb_periode)
542  {
543  try
544  {
545  if ( $nb_periode != 12 && $nb_periode != 13) throw new Exception ('Nombre de période incorrectes');
546  $this->cn->start();
547  for ($i=1;$i < 12;$i++)
548  {
549  $date_start=sprintf('01.%02d.%d',$i,$p_exercice);
550  $date_end=$this->cn->get_value("select to_char(to_date($1,'DD.MM.YYYY')+interval '1 month'-interval '1 day','DD.MM.YYYY')",array($date_start));
551  if ( $this->insert($date_start,$date_end,$p_exercice) != 0)
552  {
553  throw new Exception('Erreur insertion période');
554  }
555  }
556  if ( $nb_periode==12 && $this->insert('01.12.'.$p_exercice,'31.12.'.$p_exercice,$p_exercice) != 0 )
557  {
558  throw new Exception('Erreur insertion période');
559  }
560  if ( $nb_periode==13)
561  {
562  if ($this->insert('01.12.'.$p_exercice,'30.12.'.$p_exercice,$p_exercice) != 0 )
563  throw new Exception('Erreur insertion période');
564  if ($this->insert('31.12.'.$p_exercice,'31.12.'.$p_exercice,$p_exercice) != 0 )
565  throw new Exception('Erreur insertion période');
566  }
567 
568 
569  $this->cn->commit();
570  }
571  catch (Exception $e)
572  {
573  $this->cn->rollback();
574  }
575  }
576  static function test_me()
577  {
579  $obj=new Periode($cn);
580  $obj->set_jrn(1);
581  $obj->display_form_periode();
582  }
583 }
is_closed()
check if a periode is closed. If jrn_def_id is set to a no zero value then check only for this ledger...
$_GET['qcode']
function window
Definition: smoke.js:7
function confirm_box(p_obj, p_message, p_callback_true)
Confirm a form thanks a modal dialog Box, it returns true if we agree otherwise false.
Definition: scripts.js:2885
$opd_description style
find_periode($p_date)
retrieve the periode thanks the date_end
td($p_string='', $p_extra='')
surround the string with td
Definition: ac_common.php:83
set_periode($pp_id)
static num_row($ret)
wrapper for the function pg_NumRows
$class
h2($p_string, $p_class="", $raw="")
Definition: ac_common.php:68
th($p_string, $p_extra='', $raw='')
Definition: ac_common.php:58
is_open()
Return 1 if the periode is open otherwise 0.
$ret javascript
get_date_limit($p_periode=0)
Give the start & end date of a periode.
static test_me()
static fetch_array($ret, $p_indice=0)
wrapper for the function pg_fetch_array
set_jrn($p_jrn)
__construct($p_cn, $p_id=0)
Calendar prototype show
Shows the calendar.
Definition: calendar.js:1322
For the periode tables parm_periode and jrn_periode.
$str_dossier
Definition: anc_od.inc.php:38
get_exercice($p_id=0)
insert_exercice($p_exercice, $nb_periode)
add a exerice of 13 periode
display_form_periode()
Display all the periode and their status.
static array_to_hidden($array, $global_array)
transform request data to hidden
$date_start
$_REQUEST['ac']
$bilan from
close()
Close a periode , if Periode::jrn_def_id is set to a different value than 0 , it close only for this ...
$input_from cn
Definition: balance.inc.php:71
is_centralized()
Return 1 if periode is centralized.
static fetch_result($ret, $p_row=0, $p_col=0)
wrapper for the function pg_fetch_all
limit_year($p_exercice)
return the p_id of the start and the end of the exercice into an array
static connect()
vous n
Definition: modele.inc.php:258
tr($p_string, $p_extra='')
Definition: ac_common.php:88
$profile p_id
insert($p_date_start, $p_date_end, $p_exercice)
first_day($p=0)
return the first day of periode the this->p_id must be set
$select_type table
last_day($p=0)
return the last day of periode the this->p_id must be set
$p
Definition: array.php:34
$desc width
$obj