Debug CashFence feature

This commit is contained in:
Laurent Destailleur 2019-12-22 20:02:18 +01:00
parent 3036ff637f
commit daae053e39

View File

@ -330,7 +330,7 @@ if ($action == "create" || $action == "start")
print '<table class="noborder centpercent">'; print '<table class="noborder centpercent">';
print '<tr class="liste_titre">'; print '<tr class="liste_titre">';
print '<td>'.$langs->trans("Module").'</td>'; print '<td>'.$langs->trans("Module").'</td>';
print '<td>'.$langs->trans("CashDesk").' ID</td>'; print '<td>'.$langs->trans("Terminal").'</td>';
print '<td>'.$langs->trans("Year").'</td>'; print '<td>'.$langs->trans("Year").'</td>';
print '<td>'.$langs->trans("Month").'</td>'; print '<td>'.$langs->trans("Month").'</td>';
print '<td>'.$langs->trans("Day").'</td>'; print '<td>'.$langs->trans("Day").'</td>';
@ -343,7 +343,11 @@ if ($action == "create" || $action == "start")
print '<tr class="oddeven">'; print '<tr class="oddeven">';
print '<td>'.$form->selectarray('posmodule', $arrayofposavailable, GETPOST('posmodule', 'alpha'), (count($arrayofposavailable) > 1 ? 1 : 0)).'</td>'; print '<td>'.$form->selectarray('posmodule', $arrayofposavailable, GETPOST('posmodule', 'alpha'), (count($arrayofposavailable) > 1 ? 1 : 0)).'</td>';
print '<td>'; print '<td>';
$array = array(1=>"1", 2=>"2", 3=>"3", 4=>"4", 5=>"5", 6=>"6", 7=>"7", 8=>"8", 9=>"9");
$array = array();
for($i = 1; $i <= max(1, $conf->global->TAKEPOS_NUM_TERMINALS); $i++) {
$array[$i] = $i;
}
$selectedposnumber = 0; $showempty = 1; $selectedposnumber = 0; $showempty = 1;
if ($conf->global->TAKEPOS_NUM_TERMINALS == '1') if ($conf->global->TAKEPOS_NUM_TERMINALS == '1')
{ {
@ -502,10 +506,14 @@ if ($action == "create" || $action == "start")
if (empty($action) || $action == "view") if (empty($action) || $action == "view")
{ {
$object->fetch($id); $result = $object->fetch($id);
llxHeader('', $langs->trans("CashControl")); llxHeader('', $langs->trans("CashControl"));
if ($result <= 0) {
print $langs->trans("ErrorRecordNotFound");
}
else {
$head = array(); $head = array();
$head[0][0] = DOL_URL_ROOT.'/compta/cashcontrol/cashcontrol_card.php?id='.$object->id; $head[0][0] = DOL_URL_ROOT.'/compta/cashcontrol/cashcontrol_card.php?id='.$object->id;
$head[0][1] = $langs->trans("Card"); $head[0][1] = $langs->trans("Card");
@ -589,6 +597,7 @@ if (empty($action) || $action == "view")
print '<center><iframe src="report.php?id='.$id.'" width="60%" height="800"></iframe></center>'; print '<center><iframe src="report.php?id='.$id.'" width="60%" height="800"></iframe></center>';
} }
}
// End of page // End of page
llxFooter(); llxFooter();