2
0
forked from Wavyzz/dolibarr

Postgresql compatibility patch + cosmetic

This commit is contained in:
Sebastien Bechet
2016-03-22 10:09:41 +01:00
parent 10f30cf569
commit 82f74ceb38
6 changed files with 14 additions and 19 deletions

View File

@@ -175,7 +175,7 @@ $tabsql[24]= "SELECT rowid as rowid, code, label, active FROM ".MAIN_DB_PREFIX
$tabsql[25]= "SELECT rowid as rowid, label, type_template, private, position, topic, content, active FROM ".MAIN_DB_PREFIX."c_email_templates"; $tabsql[25]= "SELECT rowid as rowid, label, type_template, private, position, topic, content, active FROM ".MAIN_DB_PREFIX."c_email_templates";
$tabsql[26]= "SELECT rowid as rowid, code, label, short_label, active FROM ".MAIN_DB_PREFIX."c_units"; $tabsql[26]= "SELECT rowid as rowid, code, label, short_label, active FROM ".MAIN_DB_PREFIX."c_units";
$tabsql[27]= "SELECT id as rowid, code, libelle, active FROM ".MAIN_DB_PREFIX."c_stcomm"; $tabsql[27]= "SELECT id as rowid, code, libelle, active FROM ".MAIN_DB_PREFIX."c_stcomm";
$tabsql[28]= "SELECT h.rowid as rowid, h.code, h.label, h.affect, h.delay, h.newByMonth, h.fk_country as country_id, c.code as country_code, c.label as country, h.active FROM ".MAIN_DB_PREFIX."c_holiday_types as h LEFT JOIN ".MAIN_DB_PREFIX."c_country as c ON h.fk_country=c.rowid"; $tabsql[28]= "SELECT h.rowid as rowid, h.code, h.label, h.affect, h.delay, h.newbymonth, h.fk_country as country_id, c.code as country_code, c.label as country, h.active FROM ".MAIN_DB_PREFIX."c_holiday_types as h LEFT JOIN ".MAIN_DB_PREFIX."c_country as c ON h.fk_country=c.rowid";
$tabsql[29]= "SELECT rowid as rowid, code, label, percent, position, active FROM ".MAIN_DB_PREFIX."c_lead_status"; $tabsql[29]= "SELECT rowid as rowid, code, label, percent, position, active FROM ".MAIN_DB_PREFIX."c_lead_status";
$tabsql[30]= "SELECT rowid, code, name, paper_size, orientation, metric, leftmargin, topmargin, nx, ny, spacex, spacey, width, height, font_size, custom_x, custom_y, active FROM ".MAIN_DB_PREFIX."c_format_cards"; $tabsql[30]= "SELECT rowid, code, name, paper_size, orientation, metric, leftmargin, topmargin, nx, ny, spacex, spacey, width, height, font_size, custom_x, custom_y, active FROM ".MAIN_DB_PREFIX."c_format_cards";
@@ -241,7 +241,7 @@ $tabfield[24]= "code,label";
$tabfield[25]= "label,type_template,position,topic,content"; $tabfield[25]= "label,type_template,position,topic,content";
$tabfield[26]= "code,label,short_label"; $tabfield[26]= "code,label,short_label";
$tabfield[27]= "code,libelle"; $tabfield[27]= "code,libelle";
$tabfield[28]= "code,label,affect,delay,newByMonth,country_id,country"; $tabfield[28]= "code,label,affect,delay,newbymonth,country_id,country";
$tabfield[29]= "code,label,percent,position"; $tabfield[29]= "code,label,percent,position";
$tabfield[30]= "code,name,paper_size,orientation,metric,leftmargin,topmargin,nx,ny,spacex,spacey,width,height,font_size,custom_x,custom_y"; $tabfield[30]= "code,name,paper_size,orientation,metric,leftmargin,topmargin,nx,ny,spacex,spacey,width,height,font_size,custom_x,custom_y";
@@ -274,7 +274,7 @@ $tabfieldvalue[24]= "code,label";
$tabfieldvalue[25]= "label,type_template,position,topic,content"; $tabfieldvalue[25]= "label,type_template,position,topic,content";
$tabfieldvalue[26]= "code,label,short_label"; $tabfieldvalue[26]= "code,label,short_label";
$tabfieldvalue[27]= "code,libelle"; $tabfieldvalue[27]= "code,libelle";
$tabfieldvalue[28]= "code,label,affect,delay,newByMonth,country"; $tabfieldvalue[28]= "code,label,affect,delay,newbymonth,country";
$tabfieldvalue[29]= "code,label,percent,position"; $tabfieldvalue[29]= "code,label,percent,position";
$tabfieldvalue[30]= "code,name,paper_size,orientation,metric,leftmargin,topmargin,nx,ny,spacex,spacey,width,height,font_size,custom_x,custom_y"; $tabfieldvalue[30]= "code,name,paper_size,orientation,metric,leftmargin,topmargin,nx,ny,spacex,spacey,width,height,font_size,custom_x,custom_y";
@@ -307,7 +307,7 @@ $tabfieldinsert[24]= "code,label";
$tabfieldinsert[25]= "label,type_template,position,topic,content"; $tabfieldinsert[25]= "label,type_template,position,topic,content";
$tabfieldinsert[26]= "code,label,short_label"; $tabfieldinsert[26]= "code,label,short_label";
$tabfieldinsert[27]= "code,libelle"; $tabfieldinsert[27]= "code,libelle";
$tabfieldinsert[28]= "code,label,affect,delay,newByMonth,fk_country"; $tabfieldinsert[28]= "code,label,affect,delay,newbymonth,fk_country";
$tabfieldinsert[29]= "code,label,percent,position"; $tabfieldinsert[29]= "code,label,percent,position";
$tabfieldinsert[30]= "code,name,paper_size,orientation,metric,leftmargin,topmargin,nx,ny,spacex,spacey,width,height,font_size,custom_x,custom_y"; $tabfieldinsert[30]= "code,name,paper_size,orientation,metric,leftmargin,topmargin,nx,ny,spacex,spacey,width,height,font_size,custom_x,custom_y";
@@ -408,7 +408,7 @@ $tabhelp[24] = array('code'=>$langs->trans("EnterAnyCode"));
$tabhelp[25] = array('topic'=>$langs->trans('SeeSubstitutionVars'),'content'=>$langs->trans('SeeSubstitutionVars'),'type_template'=>$langs->trans("TemplateForElement"),'private'=>$langs->trans("TemplateIsVisibleByOwnerOnly"), 'position'=>$langs->trans("PositionIntoComboList")); $tabhelp[25] = array('topic'=>$langs->trans('SeeSubstitutionVars'),'content'=>$langs->trans('SeeSubstitutionVars'),'type_template'=>$langs->trans("TemplateForElement"),'private'=>$langs->trans("TemplateIsVisibleByOwnerOnly"), 'position'=>$langs->trans("PositionIntoComboList"));
$tabhelp[26] = array('code'=>$langs->trans("EnterAnyCode")); $tabhelp[26] = array('code'=>$langs->trans("EnterAnyCode"));
$tabhelp[27] = array('code'=>$langs->trans("EnterAnyCode")); $tabhelp[27] = array('code'=>$langs->trans("EnterAnyCode"));
$tabhelp[28] = array('affect'=>$langs->trans("FollowedByACounter"),'delay'=>$langs->trans("MinimumNoticePeriod"), 'newByMonth'=>$langs->trans("NbAddedAutomatically")); $tabhelp[28] = array('affect'=>$langs->trans("FollowedByACounter"),'delay'=>$langs->trans("MinimumNoticePeriod"), 'newbymonth'=>$langs->trans("NbAddedAutomatically"));
$tabhelp[29] = array('code'=>$langs->trans("EnterAnyCode"), 'percent'=>$langs->trans("OpportunityPercent"), 'position'=>$langs->trans("PositionIntoComboList")); $tabhelp[29] = array('code'=>$langs->trans("EnterAnyCode"), 'percent'=>$langs->trans("OpportunityPercent"), 'position'=>$langs->trans("PositionIntoComboList"));
$tabhelp[30] = array('code'=>$langs->trans("EnterAnyCode"), 'name'=>$langs->trans("LabelName"), 'paper_size'=>$langs->trans("LabelPaperSize")); $tabhelp[30] = array('code'=>$langs->trans("EnterAnyCode"), 'name'=>$langs->trans("LabelName"), 'paper_size'=>$langs->trans("LabelPaperSize"));

View File

@@ -63,7 +63,6 @@ CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_adherent FOR EACH RO
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_adherent_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_adherent_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_adherent_type FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_adherent_type FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_adherent_type_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_adherent_type_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_advtargetemailing FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_askpricesupplier FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_askpricesupplier FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_askpricesupplier_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_askpricesupplier_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_askpricesupplierdet_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_askpricesupplierdet_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
@@ -96,7 +95,6 @@ CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_cronjob FOR EACH ROW
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_deplacement FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_deplacement FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_don FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_don FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_don_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_don_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_ecm_documents FOR EACH ROW EXECUTE PROCEDURE update_modified_column_date_u();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_element_resources FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_element_resources FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_entrepot FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_entrepot FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_events FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_events FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
@@ -128,7 +126,6 @@ CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_payment_donation FOR
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_payment_expensereport FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_payment_expensereport FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_payment_loan FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_payment_loan FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_payment_salary FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_payment_salary FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_printer_ipp FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_printing FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_printing FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_product FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_product FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_product_batch FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_product_batch FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
@@ -155,8 +152,6 @@ CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_societe_rib FOR EACH
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_socpeople FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_socpeople FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_socpeople_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_socpeople_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_stock_mouvement FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_stock_mouvement FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_time_basket FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_timebasket_counter FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_tva FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_tva FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_user FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_user FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();
CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_user_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms(); CREATE TRIGGER update_customer_modtime BEFORE UPDATE ON llx_user_extrafields FOR EACH ROW EXECUTE PROCEDURE update_modified_column_tms();

View File

@@ -37,8 +37,8 @@ Module2660Desc=Activer le client Dolibarr de services Web (peut être utilisé p
Module3100Desc=Ajouter un bouton Skype dans la carte des utilisateurs / tiers / contacts / membres Module3100Desc=Ajouter un bouton Skype dans la carte des utilisateurs / tiers / contacts / membres
Module4000Name=Gestion des ressources humaines Module4000Name=Gestion des ressources humaines
Module4000Desc=Ressources humaines Module4000Desc=Ressources humaines
Module20000Name=Gestion des demandes de congès Module20000Name=Gestion des demandes de congés
Module20000Desc=Déclaration et suivi des congès des employés Module20000Desc=Déclaration et suivi des congés des employés
Module39000Name=Lot/Série du produit Module39000Name=Lot/Série du produit
Module55000Name=Sondage, enquête ou vote Module55000Name=Sondage, enquête ou vote
Module55000Desc=Module pour faire des sondages en ligne, des enquêtes ou des votes (comme Doodle , Studs , Rdvz , ... ) Module55000Desc=Module pour faire des sondages en ligne, des enquêtes ou des votes (comme Doodle , Studs , Rdvz , ... )

View File

@@ -836,7 +836,7 @@ DictionaryAccountancysystem=Modèles de plan comptable
DictionaryEMailTemplates=Modèles des courriels DictionaryEMailTemplates=Modèles des courriels
DictionaryUnits=Unités DictionaryUnits=Unités
DictionaryProspectStatus=Statuts de prospection DictionaryProspectStatus=Statuts de prospection
DictionaryHolidayTypes=Type de congès DictionaryHolidayTypes=Type de congés
DictionaryOpportunityStatus=Statut d'opportunités pour les affaires/projets DictionaryOpportunityStatus=Statut d'opportunités pour les affaires/projets
SetupSaved=Configuration sauvegardée SetupSaved=Configuration sauvegardée
BackToModuleList=Retour liste des modules BackToModuleList=Retour liste des modules

View File

@@ -3,7 +3,7 @@ HRM=GRH
Holidays=Congés Holidays=Congés
CPTitreMenu=Congés CPTitreMenu=Congés
MenuReportMonth=État mensuel MenuReportMonth=État mensuel
MenuAddCP=Créer demande de congès MenuAddCP=Créer demande de congés
NotActiveModCP=Vous devez activer le module Congés pour afficher cette page. NotActiveModCP=Vous devez activer le module Congés pour afficher cette page.
NotConfigModCP=Vous devez configurer le module Congés pour afficher cette page. Pour effectuer cette opération, <a href="./admin/holiday.php?leftmenu=setup&mainmenu=home" style="font-weight: normal; color: red; text-decoration: underline;">cliquer ici</a>. NotConfigModCP=Vous devez configurer le module Congés pour afficher cette page. Pour effectuer cette opération, <a href="./admin/holiday.php?leftmenu=setup&mainmenu=home" style="font-weight: normal; color: red; text-decoration: underline;">cliquer ici</a>.
NoCPforUser=Vous n'avez plus de jours disponibles NoCPforUser=Vous n'avez plus de jours disponibles
@@ -22,7 +22,7 @@ ReviewedByCP=Sera approuvé par
DescCP=Description DescCP=Description
SendRequestCP=Créer une demande de congés SendRequestCP=Créer une demande de congés
DelayToRequestCP=Les demandes de congés doivent être faites au moins <b>%s jour(s)</b> avant la date de ceux-ci. DelayToRequestCP=Les demandes de congés doivent être faites au moins <b>%s jour(s)</b> avant la date de ceux-ci.
MenuConfCP=Solde des congès MenuConfCP=Solde des congés
UpdateAllCP=Mettre à jour les congés UpdateAllCP=Mettre à jour les congés
SoldeCPUser=Solde de congés: <b>%s jours</b>. SoldeCPUser=Solde de congés: <b>%s jours</b>.
ErrorEndDateCP=Vous devez choisir une date de fin supérieur à la date de début. ErrorEndDateCP=Vous devez choisir une date de fin supérieur à la date de début.
@@ -80,7 +80,7 @@ alreadyCPexist=Une demande de congés a déjà été faite sur cette période.
UserName=Nom Prénom UserName=Nom Prénom
FirstDayOfHoliday=Premier jour de congés FirstDayOfHoliday=Premier jour de congés
LastDayOfHoliday=Dernier jours de congés LastDayOfHoliday=Dernier jours de congés
BoxTitleLastLeaveRequests=Les %s dernières demandes de congès modifiées BoxTitleLastLeaveRequests=Les %s dernières demandes de congés modifiées
HolidaysMonthlyUpdate=Mise à jour mensuelle HolidaysMonthlyUpdate=Mise à jour mensuelle
ManualUpdate=Mise à jour manuelle ManualUpdate=Mise à jour manuelle
HolidaysCancelation=Annulation de la demande de congés HolidaysCancelation=Annulation de la demande de congés
@@ -92,7 +92,7 @@ ValueOptionCP=Valeur
GroupToValidateCP=Groupe ayant la possibilité d'approuver les congés GroupToValidateCP=Groupe ayant la possibilité d'approuver les congés
ConfirmConfigCP=Valider la configuration ConfirmConfigCP=Valider la configuration
LastUpdateCP=Dernière mise à jour automatique de l'allocation des congés LastUpdateCP=Dernière mise à jour automatique de l'allocation des congés
MonthOfLastMonthlyUpdate=Mois de la dernière mise à jour automatique des attributions de congès MonthOfLastMonthlyUpdate=Mois de la dernière mise à jour automatique des attributions de congés
UpdateConfCPOK=Mise à jour effectuée avec succès. UpdateConfCPOK=Mise à jour effectuée avec succès.
ErrorUpdateConfCP=Une erreur à eu lieu durant la mise à jour, merci de réessayer. ErrorUpdateConfCP=Une erreur à eu lieu durant la mise à jour, merci de réessayer.
AddCPforUsers=Veuillez ajouter le solde des congés des utilisateurs en <a href="../define_holiday.php" style="font-weight: normal; color: red; text-decoration: underline;">cliquant ici</a>. AddCPforUsers=Veuillez ajouter le solde des congés des utilisateurs en <a href="../define_holiday.php" style="font-weight: normal; color: red; text-decoration: underline;">cliquant ici</a>.

View File

@@ -393,7 +393,7 @@ class Resource extends CommonObject
} }
} }
} }
$sql.= " GROUP BY t.rowid"; $sql.= " GROUP BY t.rowid, ty.label";
$sql.= $this->db->order($sortfield,$sortorder); $sql.= $this->db->order($sortfield,$sortorder);
$this->num_all = 0; $this->num_all = 0;
if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST)) if (empty($conf->global->MAIN_DISABLE_FULL_SCANLIST))
@@ -473,7 +473,7 @@ class Resource extends CommonObject
} }
} }
} }
$sql.= " GROUP BY t.rowid"; $sql.= " GROUP BY t.rowid, ty.label";
$sql.= $this->db->order($sortfield,$sortorder); $sql.= $this->db->order($sortfield,$sortorder);
if ($limit) $sql.= $this->db->plimit($limit+1,$offset); if ($limit) $sql.= $this->db->plimit($limit+1,$offset);
dol_syslog(get_class($this)."::fetch_all", LOG_DEBUG); dol_syslog(get_class($this)."::fetch_all", LOG_DEBUG);