Fix sort order
This commit is contained in:
parent
bab963ec07
commit
3cd21ee659
@ -367,6 +367,7 @@ if (!empty($debit)) $param.='&debit='.$debit;
|
||||
if (!empty($credit)) $param.='&credit='.$credit;
|
||||
if (!empty($account)) $param.='&account='.$account;
|
||||
if (!empty($search_num_releve)) $param.='&search_num_releve='.urlencode($search_num_releve);
|
||||
if ($search_conciliated != '') $param.='&search_conciliated='.urlencode($search_conciliated);
|
||||
if (!empty($bid)) $param.='&bid='.$bid;
|
||||
if (dol_strlen($search_dt_start) > 0) $param .= '&search_start_dtmonth=' . GETPOST('search_start_dtmonth', 'int') . '&search_start_dtday=' . GETPOST('search_start_dtday', 'int') . '&search_start_dtyear=' . GETPOST('search_start_dtyear', 'int');
|
||||
if (dol_strlen($search_dt_end) > 0) $param .= '&search_end_dtmonth=' . GETPOST('search_end_dtmonth', 'int') . '&search_end_dtday=' . GETPOST('search_end_dtday', 'int') . '&search_end_dtyear=' . GETPOST('search_end_dtyear', 'int');
|
||||
@ -446,7 +447,7 @@ if ($id > 0 || ! empty($ref))
|
||||
if ($object->canBeConciliated() > 0) {
|
||||
// If not cash account and can be reconciliate
|
||||
if ($user->rights->banque->consolidate) {
|
||||
print '<a class="butAction" href="'.DOL_URL_ROOT.'/compta/bank/bankentries.php?action=reconcile'.$param.'">'.$langs->trans("Conciliate").'</a>';
|
||||
print '<a class="butAction" href="'.DOL_URL_ROOT.'/compta/bank/bankentries.php?action=reconcile&search_conciliated=0'.$param.'">'.$langs->trans("Conciliate").'</a>';
|
||||
} else {
|
||||
print '<a class="butActionRefused" title="'.$langs->trans("NotEnoughPermissions").'" href="#">'.$langs->trans("Conciliate").'</a>';
|
||||
}
|
||||
|
||||
@ -122,7 +122,7 @@ if ($action=="dl" && $numref > 0)
|
||||
{
|
||||
// TODO Replace this with a standard builddoc action that use a document generation module to build the ZIP
|
||||
$log = '';
|
||||
|
||||
|
||||
$outdir = $conf->bank->dir_temp.'/'.$numref.'-'.$object->label;
|
||||
$outdirinvoices = $outdir.'/'.$langs->trans("BillsCustomers");
|
||||
$outdirsupplierinvoices = $outdir.'/'.$langs->trans("BillsSuppliers");
|
||||
@ -130,7 +130,7 @@ if ($action=="dl" && $numref > 0)
|
||||
dol_mkdir($outdir);
|
||||
dol_mkdir($outdirinvoices);
|
||||
dol_mkdir($outdirsupplierinvoices);
|
||||
|
||||
|
||||
//$zipname = $object->label.'-'.$numref . '.zip';
|
||||
//$zip = new ZipArchive();
|
||||
//$zip->open($zipname, ZipArchive::OVERWRITE);
|
||||
@ -138,7 +138,7 @@ if ($action=="dl" && $numref > 0)
|
||||
$sql = $sqlrequestforbankline;
|
||||
|
||||
$facturestatic=new Facture($db);
|
||||
|
||||
|
||||
$resd = $db->query($sql);
|
||||
if ($resd) {
|
||||
$numd = $db->num_rows($resd);
|
||||
@ -146,7 +146,7 @@ if ($action=="dl" && $numref > 0)
|
||||
if ($numd > 0)
|
||||
{
|
||||
$objd = $db->fetch_object($resd);
|
||||
|
||||
|
||||
$log.='Transaction '.$objd->rowid;
|
||||
$links = $object->get_url($objd->rowid);
|
||||
|
||||
@ -165,7 +165,7 @@ if ($action=="dl" && $numref > 0)
|
||||
{
|
||||
$facturestatic->fetch($billid);
|
||||
$subdir = get_exdir($facturestatic->id, 2, 0, 0, $facturestatic, 'invoice');
|
||||
|
||||
|
||||
$arrayofinclusion=array(); // TODO Find a way to get doc ODT or other
|
||||
// TODO Use get_exdir
|
||||
$arrayofinclusion[]=preg_quote($facturestatic->ref.'.pdf','/');
|
||||
@ -202,7 +202,7 @@ if ($action=="dl" && $numref > 0)
|
||||
{
|
||||
$facturestatic->fetch($billid);
|
||||
$subdir = get_exdir($facturestatic->id, 2, 0, 0, $facturestatic, 'invoice_supplier');
|
||||
|
||||
|
||||
$arrayofinclusion=array(); // TODO Find a way to get doc ODT or other
|
||||
// TODO Use get_exdir
|
||||
$arrayofinclusion[]=preg_quote($facturestatic->ref.'.pdf','/');
|
||||
@ -227,7 +227,7 @@ if ($action=="dl" && $numref > 0)
|
||||
dol_copy($srcfile, $destfile);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case "payment_expensereport":
|
||||
/*$subdir = dol_sanitizeFileName($objd->refe);
|
||||
@ -246,7 +246,7 @@ if ($action=="dl" && $numref > 0)
|
||||
}
|
||||
}
|
||||
$log.="\n";
|
||||
|
||||
|
||||
/*if (! empty($upload_dir))
|
||||
{
|
||||
$files = dol_dir_list($upload_dir, "files", 0, '', '(\.meta|_preview.*\.png)$', '', SORT_ASC, 1);
|
||||
@ -259,24 +259,24 @@ if ($action=="dl" && $numref > 0)
|
||||
} else {
|
||||
$log .= $key . ',' . $langs->trans("Nofile") . "\n";
|
||||
}
|
||||
|
||||
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$db->free($resd);
|
||||
|
||||
|
||||
|
||||
|
||||
//$zip->addFromString('log '.$numref.'.csv', $log);
|
||||
//$zip->close();
|
||||
|
||||
|
||||
// /Then download the zipped file.
|
||||
/*header('Content-Type: application/zip');
|
||||
header('Content-disposition: attachment; filename=' . $zipname);
|
||||
header('Content-Length: ' . filesize($zipname));
|
||||
|
||||
|
||||
readfile($zipname);
|
||||
|
||||
|
||||
exit;*/
|
||||
}
|
||||
|
||||
@ -329,18 +329,18 @@ if (empty($numref))
|
||||
dol_fiche_head($head,'statement',$langs->trans("FinancialAccount"),0,'account');
|
||||
|
||||
$linkback = '<a href="'.DOL_URL_ROOT.'/compta/bank/index.php">'.$langs->trans("BackToList").'</a>';
|
||||
|
||||
|
||||
dol_banner_tab($object, 'ref', $linkback, 1, 'ref', 'ref', $morehtmlref, '', 0, '', '', 1);
|
||||
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
|
||||
|
||||
print '<div class="tabsAction">';
|
||||
|
||||
if ($object->canBeConciliated() > 0) {
|
||||
// If not cash account and can be reconciliate
|
||||
if ($user->rights->banque->consolidate) {
|
||||
print '<a class="butAction" href="'.DOL_URL_ROOT.'/compta/bank/bankentries.php?action=reconcile'.$param.'">'.$langs->trans("Conciliate").'</a>';
|
||||
print '<a class="butAction" href="'.DOL_URL_ROOT.'/compta/bank/bankentries.php?action=reconcile&search_conciliated=0'.$param.'">'.$langs->trans("Conciliate").'</a>';
|
||||
} else {
|
||||
print '<a class="butActionRefused" title="'.$langs->trans("NotEnoughPermissions").'" href="#">'.$langs->trans("Conciliate").'</a>';
|
||||
}
|
||||
@ -348,7 +348,7 @@ if (empty($numref))
|
||||
|
||||
print '</div>';
|
||||
print '<br><br>';
|
||||
|
||||
|
||||
|
||||
print_barre_liste('', $page, $_SERVER["PHP_SELF"], "&account=".$object->id, $sortfield, $sortorder,'',$numrows);
|
||||
|
||||
@ -481,7 +481,7 @@ else
|
||||
//$mesprevnext.=' ';
|
||||
$mesprevnext.='<li class="pagination"><a class="paginationnext" href="'.$_SERVER["PHP_SELF"].'?rel=next&num='.$numref.'&ve='.$ve.'&account='.$object->id.'"><i class="fa fa-chevron-right" title="'.dol_escape_htmltag($langs->trans("Next")).'"></i></a></li>';
|
||||
$mesprevnext.='</ul></div>';
|
||||
|
||||
|
||||
$title=$langs->trans("AccountStatement").' '.$numref.', '.$langs->trans("BankAccount").' : '.$object->getNomUrl(0, 'receipts');
|
||||
print load_fiche_titre($title, $mesprevnext, 'title_bank.png');
|
||||
//print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, $massactionbutton, 0, $nbtotalofrecords, 'title_bank.png', 0, '', '', 0, 1);
|
||||
@ -520,7 +520,7 @@ else
|
||||
|
||||
// Recherche les ecritures pour le releve
|
||||
$sql = $sqlrequestforbankline;
|
||||
|
||||
|
||||
$result = $db->query($sql);
|
||||
if ($result)
|
||||
{
|
||||
@ -553,7 +553,7 @@ else
|
||||
print img_edit_add() ."</a>";
|
||||
print "</td>\n";
|
||||
print '<a class="ajax" href="'.$_SERVER['PHP_SELF'].'?action=dvnext&account='.$objp->bankid.'&rowid='.$objp->rowid.'">';
|
||||
|
||||
|
||||
// Type and num
|
||||
if ($objp->fk_type == 'SOLD') {
|
||||
$type_label=' ';
|
||||
@ -753,9 +753,9 @@ else
|
||||
print "</tr>\n";
|
||||
print "</table>";
|
||||
print "</div>";
|
||||
|
||||
|
||||
print "</form>\n";
|
||||
|
||||
|
||||
// Add a download button
|
||||
if ($conf->global->MAIN_FEATURES_LEVEL >= 2) // Started a rewrite to make this feature more Dolibarr compliant. Still need dev to be completed.
|
||||
{
|
||||
|
||||
Loading…
Reference in New Issue
Block a user