Fix example of number for holiday
This commit is contained in:
parent
f1193ad3dd
commit
773e2da4cc
@ -75,8 +75,8 @@ else if ($action == 'specimen') // For contract
|
||||
{
|
||||
$modele= GETPOST('module','alpha');
|
||||
|
||||
$contract = new Contrat($db);
|
||||
$contract->initAsSpecimen();
|
||||
$holiday = new Holiday($db);
|
||||
$holiday->initAsSpecimen();
|
||||
|
||||
// Search template files
|
||||
$file=''; $classname=''; $filefound=0;
|
||||
@ -98,7 +98,7 @@ else if ($action == 'specimen') // For contract
|
||||
|
||||
$module = new $classname($db);
|
||||
|
||||
if ($module->write_file($contract,$langs) > 0)
|
||||
if ($module->write_file($holiday,$langs) > 0)
|
||||
{
|
||||
header("Location: ".DOL_URL_ROOT."/document.php?modulepart=holiday&file=SPECIMEN.pdf");
|
||||
return;
|
||||
@ -271,7 +271,7 @@ foreach ($dirmodels as $reldir)
|
||||
// Info
|
||||
$htmltooltip='';
|
||||
$htmltooltip.=''.$langs->trans("Version").': <b>'.$module->getVersion().'</b><br>';
|
||||
$nextval=$module->getNextValue($mysoc,$contract);
|
||||
$nextval=$module->getNextValue($mysoc,$holiday);
|
||||
if ("$nextval" != $langs->trans("NotAvailable")) { // Keep " on nextval
|
||||
$htmltooltip.=''.$langs->trans("NextValue").': ';
|
||||
if ($nextval) {
|
||||
|
||||
@ -2171,8 +2171,10 @@ class Holiday extends CommonObject
|
||||
$this->description='SPECIMEN description';
|
||||
$this->date_debut=dol_now();
|
||||
$this->date_fin=dol_now()+(24*3600);
|
||||
$this->date_valid=dol_now();
|
||||
$this->fk_validator=1;
|
||||
$this->halfday=0;
|
||||
$this->fk_type=1;
|
||||
$this->statut=Holiday::STATUS_VALIDATED;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user