From 36090643bcecc9c4d0f5bcf312b670783a2e2a9c Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 22 May 2011 20:37:05 +0000 Subject: [PATCH] Filter on files --- htdocs/ecm/index.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/ecm/index.php b/htdocs/ecm/index.php index 95974a0265e..08f9e1f10ec 100644 --- a/htdocs/ecm/index.php +++ b/htdocs/ecm/index.php @@ -1,5 +1,5 @@ +/* Copyright (C) 2008-2011 Laurent Destailleur * Copyright (C) 2008-2010 Regis Houssin * * This program is free software; you can redistribute it and/or modify @@ -812,7 +812,7 @@ if ($module == 'invoice_supplier') // Auto area for suppliers invoices { $relativepath='facture'; $upload_dir = $conf->fournisseur->dir_output.'/'.$relativepath; - $filearray=dol_dir_list($upload_dir,"files",1,'','\.meta$',$sortfield,(strtolower($sortorder)=='desc'?SORT_ASC:SORT_DESC),1); + $filearray=dol_dir_list($upload_dir,"files",1,'',array('^\.','\.meta$','^temp$','^CVS$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_ASC:SORT_DESC),1); $param='&module='.$module; $textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("ECMSelectASection"))); @@ -823,7 +823,7 @@ else // Manual area { $relativepath=$ecmdir->getRelativePath(); $upload_dir = $conf->ecm->dir_output.'/'.$relativepath; - $filearray=dol_dir_list($upload_dir,"files",0,'','\.meta$',$sortfield,(strtolower($sortorder)=='desc'?SORT_ASC:SORT_DESC),1); + $filearray=dol_dir_list($upload_dir,"files",0,'',array('^\.','\.meta$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_ASC:SORT_DESC),1); $param='&section='.$section; $textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("ECMSelectASection")));