338 |
} |
} |
339 |
} |
} |
340 |
|
|
341 |
|
function regle($regle){ |
342 |
|
$temp = explode ("+",$regle); |
343 |
|
echo '/'.$regle.sizeof($temp); |
344 |
|
if(sizeof($temp)==1) |
345 |
|
if($temp[0]=="archive_date_depot") |
346 |
|
return $this->$regle; |
347 |
|
else |
348 |
|
return $this->valF[$regle]; |
349 |
|
else{ |
350 |
|
if($temp[0]=="archive_date_depot") |
351 |
|
if(is_numeric($temp[1])) |
352 |
|
return $this->moisdate($this->$temp[0], $temp[1]); |
353 |
|
else |
354 |
|
return $this->moisdate($this->$temp[0], $this->valF[$temp[1]]); |
355 |
|
if(is_numeric($temp[1])) |
356 |
|
return $this->moisdate($this->valF[$temp[0]], $temp[1]); |
357 |
|
else |
358 |
|
return $this->moisdate($this->valF[$temp[0]], $this->valF[$temp[1]]); |
359 |
|
} |
360 |
|
} |
361 |
|
|
362 |
|
|
363 |
|
|
364 |
// ================================================================== |
// ================================================================== |
365 |
// valeur dossier apres modification [values dossier after action] |
// valeur dossier apres modification [values dossier after action] |
366 |
// ================================================================== |
// ================================================================== |
368 |
// mise a null au lieu de "" / voir compatibilite mysql |
// mise a null au lieu de "" / voir compatibilite mysql |
369 |
// voir parametrage CU en dur |
// voir parametrage CU en dur |
370 |
// voir parametrage des actions en dur |
// voir parametrage des actions en dur |
371 |
$param=0; |
$param=1; |
372 |
|
|
373 |
if($param==1){ |
if($param==1){ |
374 |
$sql="select * from action where action = '".$this->valF['action']."'"; |
$sql="select * from action where action = '".$this->valF['action']."'"; |
377 |
die($res->getMessage()); |
die($res->getMessage()); |
378 |
while ($row=& $res->fetchRow(DB_FETCHMODE_ASSOC)){ |
while ($row=& $res->fetchRow(DB_FETCHMODE_ASSOC)){ |
379 |
if($row['regle_etat']!=''){ |
if($row['regle_etat']!=''){ |
380 |
$valF['etat']= $this->valF[$row['regle_etat']]; |
$valF['etat']= $this->regle($row['regle_etat']); |
381 |
} |
} |
382 |
if($row['regle_delai']!=''){ |
if($row['regle_delai']!=''){ |
383 |
$valF['delai']= $this->valF[$row['regle_delai']]; |
$valF['delai']= $this->regle($row['regle_delai']); |
384 |
} |
} |
385 |
if($row['regle_accord_tacite']!=''){ |
if($row['regle_accord_tacite']!=''){ |
386 |
$valF['accord_tacite']= $this->valF[$row['regle_accord_tacite']]; |
$valF['accord_tacite']= $this->regle($row['regle_accord_tacite']); |
387 |
} |
} |
388 |
if($row['regle_date_limite']!=''){ |
if($row['regle_date_limite']!=''){ |
389 |
$temp = explode ("+",$row['regle_date_limite']); |
$valF['date_limite']= $this->regle($row['regle_date_limite']); |
390 |
//if(substr($row['temp'],0,7)=='archive') |
} |
391 |
if(isnumeric($temp[1])) |
if($row['regle_date_complet']!=''){ |
392 |
$valF['date_limite']= $this->moisdate($this->valF[$temp[0]], |
$valF['date_complet']= $this->regle($row['regle_date_complet']); |
393 |
$temp[1]); |
} |
394 |
else |
if($row['regle_date_notification_delai']!=''){ |
395 |
$valF['date_limite']= $this->moisdate($this->valF[$temp[0]], |
$valF['date_notification_delai']= $this->regle($row['regle_date_notification_delai']); |
396 |
$this->valF[$temp[1]]); |
} |
|
} |
|
397 |
} |
} |
398 |
}else{ |
}else{ |
399 |
|
|
500 |
}// end switch |
}// end switch |
501 |
} // end param |
} // end param |
502 |
// mise à jour dossier [modify dossier] |
// mise à jour dossier [modify dossier] |
503 |
|
print_r($valF); |
504 |
if($valF!=""){ |
if($valF!=""){ |
505 |
$cle= " dossier = '".$this->valF['dossier']."'"; |
$cle= " dossier = '".$this->valF['dossier']."'"; |
506 |
$res1= $db->autoExecute('dossier',$valF,DB_AUTOQUERY_UPDATE,$cle); |
$res1= $db->autoExecute('dossier',$valF,DB_AUTOQUERY_UPDATE,$cle); |