Skip to content
Snippets Groups Projects
Commit f320ed92 authored by Marcos García de La Fuente's avatar Marcos García de La Fuente
Browse files

Translated and upper-cased export formats, improved es_ES translations

fr_FR exports translations were made by @fhenry and Manuel Pintor (contact@idl-mp.com)
Little refactor too
parent b6cd8b63
Branches
Tags
No related merge requests found
Showing
with 94 additions and 59 deletions
......@@ -60,7 +60,7 @@ class ExportCsv extends ModeleExports
$this->enclosure='"';
$this->id='csv'; // Same value then xxx in file name export_xxx.modules.php
$this->label='Csv'; // Label of driver
$this->label = 'CSV'; // Label of driver
$this->desc=$langs->trans("CSVFormatDesc",$this->separator,$this->enclosure,$this->escape);
$this->extension='csv'; // Extension for generated file by this driver
$this->picto='mime/other'; // Picto
......
<?php
/* Copyright (C) 2006-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2012 Marcos García <marcosgdf@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -54,12 +55,12 @@ class ExportExcel extends ModeleExports
*/
function __construct($db)
{
global $conf;
global $conf, $langs;
$this->db = $db;
$this->id='excel'; // Same value then xxx in file name export_xxx.modules.php
$this->label='Excel 95'; // Label of driver
$this->desc='<b>Excel</b> file format (.xls)<br>This is native Excel 95 format (BIFF5).';
$this->desc = $langs->trans('Excel95FormatDesc');
$this->extension='xls'; // Extension for generated file by this driver
$this->picto='mime/xls'; // Picto
$this->version='1.30'; // Driver version
......
<?php
/* Copyright (C) 2006-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2012 Marcos García <marcosgdf@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -55,12 +56,12 @@ class ExportExcel2007 extends ExportExcel
*/
function __construct($db)
{
global $conf;
global $conf, $langs;
$this->db = $db;
$this->id='excel2007'; // Same value then xxx in file name export_xxx.modules.php
$this->label='Excel 2007'; // Label of driver
$this->desc='<b>Excel</b> file format (.xlsx)<br>This is native Excel 2007 format (SpreadsheetML).';
$this->desc = $langs->trans('Excel2007FormatDesc');
$this->extension='xlsx'; // Extension for generated file by this driver
$this->picto='mime/xls'; // Picto
$this->version='1.30'; // Driver version
......
<?php
/* Copyright (C) 2006-2008 Laurent Destailleur <eldy@users.sourceforge.net>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* Copyright (C) 2012 Marcos García <marcosgdf@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**
......@@ -51,12 +52,12 @@ class ExportTsv extends ModeleExports
*/
function __construct($db)
{
global $conf;
global $conf, $langs;
$this->db = $db;
$this->id='tsv'; // Same value then xxx in file name export_xxx.modules.php
$this->label='Tsv'; // Label of driver
$this->desc='<b>Tab Separated Value</b> file format (.tsv)<br>This is a text file format where fields are separated by separator [tab].';
$this->label = 'TSV'; // Label of driver
$this->desc = $langs->trans('TsvFormatDesc');
$this->extension='tsv'; // Extension for generated file by this driver
$this->picto='mime/other'; // Picto
$this->version='1.15'; // Driver version
......
......@@ -173,7 +173,7 @@ class modCommande extends DolibarrModules
$this->export_code[$r]=$this->rights_class.'_'.$r;
$this->export_label[$r]='CustomersOrdersAndOrdersLines'; // Translation key (used only if key ExportDataset_xxx_z not found)
$this->export_permission[$r]=array(array("commande","commande","export"));
$this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.cp'=>'Zip','s.ville'=>'Town','s.fk_pays'=>'Country','s.tel'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','c.rowid'=>"Id",'c.ref'=>"Ref",'c.ref_client'=>"RefClient",'c.fk_soc'=>"IdCompany",'c.date_creation'=>"DateCreation",'c.date_commande'=>"DateOrder",'c.amount_ht'=>"Amount",'c.remise_percent'=>"GlobalDiscount",'c.total_ht'=>"TotalHT",'c.total_ttc'=>"TotalTTC",'c.facture'=>"OrderShortStatusInvoicee",'c.fk_statut'=>'Status','c.note'=>"Note",'c.date_livraison'=>'DeliveryDate','cd.rowid'=>'LineId','cd.description'=>"LineDescription",'cd.product_type'=>'TypeOfLineServiceOrProduct','cd.tva_tx'=>"LineVATRate",'cd.qty'=>"LineQty",'cd.total_ht'=>"LineTotalHT",'cd.total_tva'=>"LineTotalVAT",'cd.total_ttc'=>"LineTotalTTC",'p.rowid'=>'ProductId','p.ref'=>'ProductRef','p.label'=>'Label');
$this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.cp'=>'Zip','s.ville'=>'Town','s.fk_pays'=>'Country','s.tel'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','c.rowid'=>"Id",'c.ref'=>"Ref",'c.ref_client'=>"RefCustomer",'c.fk_soc'=>"IdCompany",'c.date_creation'=>"DateCreation",'c.date_commande'=>"DateOrder",'c.amount_ht'=>"Amount",'c.remise_percent'=>"GlobalDiscount",'c.total_ht'=>"TotalHT",'c.total_ttc'=>"TotalTTC",'c.facture'=>"OrderShortStatusInvoicee",'c.fk_statut'=>'Status','c.note'=>"Note",'c.date_livraison'=>'DeliveryDate','cd.rowid'=>'LineId','cd.description'=>"LineDescription",'cd.product_type'=>'TypeOfLineServiceOrProduct','cd.tva_tx'=>"LineVATRate",'cd.qty'=>"LineQty",'cd.total_ht'=>"LineTotalHT",'cd.total_tva'=>"LineTotalVAT",'cd.total_ttc'=>"LineTotalTTC",'p.rowid'=>'ProductId','p.ref'=>'ProductRef','p.label'=>'Label');
$this->export_entities_array[$r]=array('s.rowid'=>"company",'s.nom'=>'company','s.address'=>'company','s.cp'=>'company','s.ville'=>'company','s.fk_pays'=>'company','s.tel'=>'company','s.siren'=>'company','s.ape'=>'company','s.idprof4'=>'company','s.siret'=>'company','c.rowid'=>"order",'c.ref'=>"order",'c.ref_client'=>"order",'c.fk_soc'=>"order",'c.date_creation'=>"order",'c.date_commande'=>"order",'c.amount_ht'=>"order",'c.remise_percent'=>"order",'c.total_ht'=>"order",'c.total_ttc'=>"order",'c.facture'=>"order",'c.fk_statut'=>"order",'c.note'=>"order",'c.date_livraison'=>"order",'cd.rowid'=>'order_line','cd.description'=>"order_line",'cd.product_type'=>'order_line','cd.tva_tx'=>"order_line",'cd.qty'=>"order_line",'cd.total_ht'=>"order_line",'cd.total_tva'=>"order_line",'cd.total_ttc'=>"order_line",'p.rowid'=>'product','p.ref'=>'product','p.label'=>'product');
$this->export_dependencies_array[$r]=array('order_line'=>'cd.rowid','product'=>'cd.rowid'); // To add unique key if we ask a field of a child to avoid the DISTINCT to discard them
......
......@@ -169,7 +169,7 @@ class modPropale extends DolibarrModules
$this->export_code[$r]=$this->rights_class.'_'.$r;
$this->export_label[$r]='ProposalsAndProposalsLines'; // Translation key (used only if key ExportDataset_xxx_z not found)
$this->export_permission[$r]=array(array("propale","export"));
$this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.cp'=>'Zip','s.ville'=>'Town','cp.code'=>'Country','s.tel'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','c.rowid'=>"Id",'c.ref'=>"Ref",'c.ref_client'=>"RefClient",'c.fk_soc'=>"IdCompany",'c.datec'=>"DateCreation",'c.datep'=>"DatePropal",'c.fin_validite'=>"DateEndPropal",'c.remise_percent'=>"GlobalDiscount",'c.total_ht'=>"TotalHT",'c.total'=>"TotalTTC",'c.fk_statut'=>'Status','c.note'=>"Note",'c.date_livraison'=>'DeliveryDate','cd.rowid'=>'LineId','cd.description'=>"LineDescription",'cd.product_type'=>'TypeOfLineServiceOrProduct','cd.tva_tx'=>"LineVATRate",'cd.qty'=>"LineQty",'cd.total_ht'=>"LineTotalHT",'cd.total_tva'=>"LineTotalVAT",'cd.total_ttc'=>"LineTotalTTC",'p.rowid'=>'ProductId','p.ref'=>'ProductRef','p.label'=>'Label');
$this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.cp'=>'Zip','s.ville'=>'Town','cp.code'=>'Country','s.tel'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','c.rowid'=>"Id",'c.ref'=>"Ref",'c.ref_client'=>"RefCustomer",'c.fk_soc'=>"IdCompany",'c.datec'=>"DateCreation",'c.datep'=>"DatePropal",'c.fin_validite'=>"DateEndPropal",'c.remise_percent'=>"GlobalDiscount",'c.total_ht'=>"TotalHT",'c.total'=>"TotalTTC",'c.fk_statut'=>'Status','c.note'=>"Note",'c.date_livraison'=>'DeliveryDate','cd.rowid'=>'LineId','cd.description'=>"LineDescription",'cd.product_type'=>'TypeOfLineServiceOrProduct','cd.tva_tx'=>"LineVATRate",'cd.qty'=>"LineQty",'cd.total_ht'=>"LineTotalHT",'cd.total_tva'=>"LineTotalVAT",'cd.total_ttc'=>"LineTotalTTC",'p.rowid'=>'ProductId','p.ref'=>'ProductRef','p.label'=>'Label');
$this->export_entities_array[$r]=array('s.rowid'=>"company",'s.nom'=>'company','s.address'=>'company','s.cp'=>'company','s.ville'=>'company','cp.code'=>'company','s.tel'=>'company','s.siren'=>'company','s.ape'=>'company','s.idprof4'=>'company','s.siret'=>'company','c.rowid'=>"propal",'c.ref'=>"propal",'c.ref_client'=>"propal",'c.fk_soc'=>"propal",'c.datec'=>"propal",'c.datep'=>"propal",'c.fin_validite'=>"propal",'c.remise_percent'=>"propal",'c.total_ht'=>"propal",'c.total'=>"propal",'c.fk_statut'=>"propal",'c.note'=>"propal",'c.date_livraison'=>"propal",'cd.rowid'=>'propal_line','cd.description'=>"propal_line",'cd.product_type'=>'propal_line','cd.tva_tx'=>"propal_line",'cd.qty'=>"propal_line",'cd.total_ht'=>"propal_line",'cd.total_tva'=>"propal_line",'cd.total_ttc'=>"propal_line",'p.rowid'=>'product','p.ref'=>'product','p.label'=>'product');
$this->export_dependencies_array[$r]=array('propal_line'=>'cd.rowid','product'=>'cd.rowid'); // To add unique key if we ask a field of a child to avoid the DISTINCT to discard them
......
<?php
/* Copyright (C) 2005-2011 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2009 Regis Houssin <regis@dolibarr.fr>
* Copyright (C) 2012 Marcos García <marcosgdf@gmail.com>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -34,34 +35,56 @@ $langs->load("exports");
//if (! $user->admin)
// accessforbidden();
$entitytoicon=array(
'invoice'=>'bill','invoice_line'=>'bill',
'order'=>'order' ,'order_line'=>'order',
'propal'=>'propal', 'propal_line'=>'propal',
'intervention'=>'intervention' ,'inter_line'=>'intervention',
'member'=>'user' ,'member_type'=>'group','subscription'=>'payment',
'tax'=>'generic' ,'tax_type'=>'generic',
'account'=>'account',
'payment'=>'payment',
'product'=>'product','stock'=>'generic','warehouse'=>'stock',
'category'=>'category',
'other'=>'generic',
);
$entitytolang=array( // Translation code
'user'=>'User',
'company'=>'Company','contact'=>'Contact',
'invoice'=>'Bill','invoice_line'=>'InvoiceLine',
'order'=>'Order','order_line'=>'OrderLine',
'propal'=>'Proposal','propal_line'=>'ProposalLine',
'intervention'=>'Intervention' ,'inter_line'=>'InterLine',
'member'=>'Member','member_type'=>'MemberType','subscription'=>'Subscription',
'tax'=>'SocialContribution','tax_type'=>'DictionnarySocialContributions',
'account'=>'BankTransactions',
'payment'=>'Payment',
'product'=>'Product','stock'=>'Stock','warehouse'=>'Warehouse',
'category'=>'Category',
'other'=>'Other'
);
$entitytoicon = array(
'invoice' => 'bill',
'invoice_line' => 'bill',
'order' => 'order',
'order_line' => 'order',
'propal' => 'propal',
'propal_line' => 'propal',
'intervention' => 'intervention',
'inter_line' => 'intervention',
'member' => 'user',
'member_type' => 'group',
'subscription' => 'payment',
'payment' => 'payment',
'tax' => 'generic',
'tax_type' => 'generic',
'stock' => 'generic',
'other' => 'generic',
'account' => 'account',
'product' => 'product',
'warehouse' => 'stock',
'category' => 'category',
);
// Translation code
$entitytolang = array(
'user' => 'User',
'company' => 'Company',
'contact' => 'Contact',
'invoice' => 'Bill',
'invoice_line' => 'InvoiceLine',
'order' => 'Order',
'order_line' => 'OrderLine',
'propal' => 'Proposal',
'propal_line' => 'ProposalLine',
'intervention' => 'Intervention',
'inter_line' => 'InterLine',
'member' => 'Member',
'member_type' => 'MemberType',
'subscription' => 'Subscription',
'tax' => 'SocialContribution',
'tax_type' => 'DictionnarySocialContributions',
'account' => 'BankTransactions',
'payment' => 'Payment',
'product' => 'Product',
'stock' => 'Stock',
'warehouse' => 'Warehouse',
'category' => 'Category',
'other' => 'Other',
'trip' => 'TripsAndExpenses'
);
$array_selected=isset($_SESSION["export_selected_fields"])?$_SESSION["export_selected_fields"]:array();
$datatoexport=GETPOST("datatoexport");
......
......@@ -112,4 +112,7 @@ SourceExample=Example of possible data value
ExampleAnyRefFoundIntoElement=Any ref found for element <b>%s</b>
ExampleAnyCodeOrIdFoundIntoDictionnary=Any code (or id) found into dictionnary <b>%s</b>
CSVFormatDesc=<b>Comma Separated Value</b> file format (.csv).<br>This is a text file format where fields are separated by separator [ %s ]. If separator is found inside a field content, field is rounded by round character [ %s ]. Escape character to escape round character is [ %s ].
Excel95FormatDesc=<b>Excel</b> file format (.xls)<br>This is native Excel 95 format (BIFF5).
Excel2007FormatDesc=<b>Excel</b> file format (.xlsx)<br>This is native Excel 2007 format (SpreadsheetML).
TsvFormatDesc=<b>Tab Separated Value</b> file format (.tsv)<br>This is a text file format where fields are separated by a tabulator [tab].
ExportFieldAutomaticallyAdded=Field <b>%s</b> was automatically added. It will avoid you to have similar lines to be treated as duplicate records (with this field added, all ligne will own its own id and will differ).
\ No newline at end of file
......@@ -670,9 +670,9 @@ DictionnaryCompanyJuridicalType=Formas jurídicas
DictionnaryProspectLevel=Perspectiva nivel cliente potencial
DictionnaryCanton=Departamentos/Provincias/Zonas
DictionnaryRegion=Regiones
DictionnaryCountry=Paises
DictionnaryCountry=Países
DictionnaryCurrency=Monedas
DictionnaryCivility=Título cortesía
DictionnaryCivility=Títulos de cortesía
DictionnaryActions=Tipos de eventos de la agenda
DictionnarySocialContributions=Tipos de cargas sociales
DictionnaryVAT=Tasa de IVA (Impuesto sobre ventas en EEUU)
......@@ -680,7 +680,7 @@ DictionnaryPaymentConditions=Condiciones de pago
DictionnaryPaymentModes=Modos de pago
DictionnaryTypeContact=Tipos de contactos/direcciones
DictionnaryEcotaxe=Baremos CEcoParticipación (DEEE)
DictionnaryPaperFormat=Formatos papel
DictionnaryPaperFormat=Formatos de papel
DictionnaryFees=Tipo de desplazamientos y honorarios
DictionnarySendingMethods=Métodos de expedición
DictionnaryStaff=Empleados
......
......@@ -58,8 +58,8 @@ Name=Nombre
Lastname=Apellidos
Firstname=Nombre
PostOrFunction=Puesto/función
UserTitle=Título cortesía
Surname=Pseudonimo
UserTitle=Título de cortesía
Surname=Seudónimo
Address=Dirección
State=Provincia
Region=Región
......
......@@ -32,7 +32,7 @@ FieldOrder=Orden del campo
FieldTitle=Título campo
ChooseExportFormat=Elija el formato de exportación
NowClickToGenerateToBuildExportFile=Ahora, seleccione el formato de exportación de la lista desplegable y haga clic en "Generar" para generar el archivo exportación...
AvailableFormats=Formatos dispo.
AvailableFormats=Formatos disponibles
LibraryShort=Librería
LibraryUsed=Librería utilizada
LibraryVersion=Versión
......@@ -112,4 +112,7 @@ SourceExample=Ejemplo de datos de origen posibles
ExampleAnyRefFoundIntoElement=Todas las referencias encontradas para los elementos <b>%s</b>
ExampleAnyCodeOrIdFoundIntoDictionnary=Todos los códigos (o id) encontrados en el diccionario <b>%s</b>
CSVFormatDesc=Archivo con formato <b>Valores separados por coma</b> (.csv).<br>Es un fichero con formato de texto en el que los campos son separados por el carácter [ %s ]. Si el separador se encuentra en el contenido de un campo, El campo debe de estar acotado por el carácter [ %s ]. El carácter de escape para incluir un carácter de entorno en un dato es [ %s ].
Excel95FormatDesc=Archivo con formato <b>Excel</b> (.xls)<br>Este es el formato nativo de Excel 95 (BIFF5).
Excel2007FormatDesc=Archivo con formato <b>Excel</b> (.xlsx)<br>Este es el formato nativo de Excel 2007 (SpreadsheetML).
TsvFormatDesc=Archivo con formato <b>Valores separados por tabulador</b> (.tsv)<br>Este es un formato de archivo de texto en el que los campos son separados por un tabulador [tab].
ExportFieldAutomaticallyAdded=Se ha añadido automáticamente el campo <b>%s</b>, ya que evitará que líneas idénticas sean consideradas como duplicadas (con este campo, cada línea tendrá un id propio).
\ No newline at end of file
......@@ -34,7 +34,7 @@ ErrorFileNotUploaded=El archivo no se ha podido transferir
ErrorInternalErrorDetected=Error detectado
ErrorNoRequestRan=Ninguna petición realizada
ErrorWrongHostParameter=Parámetro Servidor inválido
ErrorYourCountryIsNotDefined=Su país no está definido. Corrígalo yendo a Inicio-Configuración-Empresa/Institución-Editar
ErrorYourCountryIsNotDefined=Su país no está definido. Corríjalo yendo a Inicio-Configuración-Empresa/Institución-Editar
ErrorRecordIsUsedByChild=Imposible de suprimir este registro. Esta siendo utilizado como padre por al menos un registro hijo.
ErrorWrongValue=Valor incorrecto
ErrorWrongValueForParameterX=Valor incorrecto del parámetro %s
......
......@@ -17,7 +17,7 @@ SupplierOrder=Pedido a proveedor
SuppliersOrders=Pedidos a proveedor
SuppliersOrdersRunning=Pedidos a proveedor en curso
CustomerOrder=Pedido de cliente
CustomersOrders=Pedidos de cliente
CustomersOrders=Pedidos de clientes
CustomersOrdersRunning=Pedidos de cliente en curso
CustomersOrdersAndOrdersLines=Pedidos de cliente y líneas de pedido
OrdersToValid=Pedidos de clientes a validar
......
......@@ -112,4 +112,7 @@ SourceExample=Exemple de donnée source possible
ExampleAnyRefFoundIntoElement=Toute réf trouvée pour les éléments <b>%s</b>
ExampleAnyCodeOrIdFoundIntoDictionnary=Tout code (ou id) trouvée dans le dictionnaire <b>%s</b>
CSVFormatDesc=Fichier au format <b>Comma Separated Value</b> (.csv).<br>C'est un fichier au format texte dans lequel les champs sont séparés par le caractère [ %s ]. Si le séparateur est trouvé dans le contenu d'un champ, le champ doit être entouré du caractère [ %s ]. Le caractère d'échappement pour inclure un caractère de contour dans une donnée est [ %s ].
Excel95FormatDesc=Format <b>Excel</b> (.xls).<br>Format Excel 95 (BIFF5).
Excel2007FormatDesc=Format <b>Excel</b> (.xls).<br>Format standard Excel 2007 (SpreadsheetML).
TsvFormatDesc=Format de fichier à <b>Valeurs Séparées par des Tabulations</b> (.tsv).<br>C'est un fichier texte dont les champs sont séparés par des tabulations [tab].
ExportFieldAutomaticallyAdded=Le champ <b>%s</b> a été ajouté automatiquement car il évitera que des lignes identiques soient considérées comme des doublons (avec ce champ, aucune ligne ne sera identique mais aura un id propre).
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment