diff --git a/htdocs/compta/bank/fiche.php b/htdocs/compta/bank/fiche.php
index 72c03e3b2e8..9cc9bd60d78 100644
--- a/htdocs/compta/bank/fiche.php
+++ b/htdocs/compta/bank/fiche.php
@@ -202,6 +202,7 @@ if ($_GET["action"] == 'create')
$form->select_currency($selectedcode, 'account_currency_code');
*/
print $langs->trans("Currency".$conf->monnaie);
+ print '';
print '';
// Pays
@@ -320,6 +321,7 @@ else
$form->select_currency($selectedcode, 'account_currency_code');
*/
print $langs->trans("Currency".$conf->monnaie);
+ print '';
print '';
print '
| '.$langs->trans("BalanceMinimalAllowed").' | ';
@@ -430,6 +432,7 @@ else
$form->select_currency($selectedcode, 'account_currency_code');
*/
print $langs->trans("Currency".$conf->monnaie);
+ print '';
print '
';
print '| '.$langs->trans("BalanceMinimalAllowed").' | ';
diff --git a/htdocs/includes/boxes/box_commandes.php b/htdocs/includes/boxes/box_commandes.php
index d6ffa24d329..cf8a76db001 100644
--- a/htdocs/includes/boxes/box_commandes.php
+++ b/htdocs/includes/boxes/box_commandes.php
@@ -71,7 +71,7 @@ class box_commandes extends ModeleBoxes {
{
$sql = "SELECT s.nom, s.rowid as socid,";
- $sql.= " p.ref, ".$db->pdate("p.date_commande")." as dp, p.rowid,";
+ $sql.= " p.ref, p.tms, p.rowid,";
$sql.= " p.fk_statut, p.facture";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", sc.fk_soc, sc.fk_user";
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."commande as p";
@@ -105,9 +105,14 @@ class box_commandes extends ModeleBoxes {
$this->info_box_contents[$i][1] = array('align' => 'left',
'text' => $objp->nom,
'url' => DOL_URL_ROOT."/comm/fiche.php?socid=".$objp->socid);
+
+ $this->info_box_contents[$i][2] = array('align' => 'right',
+ 'text' => dolibarr_print_date($objp->tms,'day'),
+ );
- $this->info_box_contents[$i][2] = array(
+ $this->info_box_contents[$i][3] = array(
'align' => 'right',
+ 'width' => 18,
'text' => $commandestatic->LibStatut($objp->fk_statut,$objp->facturee,3));
$i++;
@@ -122,11 +127,13 @@ class box_commandes extends ModeleBoxes {
$this->info_box_contents[$i][1] = array('text'=>' ');
$this->info_box_contents[$i][2] = array('text'=>' ');
$this->info_box_contents[$i][3] = array('text'=>' ');
+ $this->info_box_contents[$i][4] = array('text'=>' ');
} else {
$this->info_box_contents[$i][0] = array('text'=>' ');
$this->info_box_contents[$i][1] = array('text'=>' ');
$this->info_box_contents[$i][2] = array('text'=>' ');
$this->info_box_contents[$i][3] = array('text'=>' ');
+ $this->info_box_contents[$i][4] = array('text'=>' ');
}
$i++;
}
diff --git a/htdocs/includes/boxes/box_comptes.php b/htdocs/includes/boxes/box_comptes.php
index 43e9aa138f1..38559091286 100644
--- a/htdocs/includes/boxes/box_comptes.php
+++ b/htdocs/includes/boxes/box_comptes.php
@@ -61,14 +61,13 @@ class box_comptes extends ModeleBoxes {
*/
function loadBox($max=5)
{
- global $user, $langs, $db;
- $langs->load("boxes");
+ global $user, $langs, $db, $conf;
$this->info_box_head = array('text' => $langs->trans("BoxTitleCurrentAccounts"));
if ($user->rights->banque->lire)
{
- $sql = "SELECT rowid, label, bank, number";
+ $sql = "SELECT rowid, label, bank, number, currency_code";
$sql .= " FROM ".MAIN_DB_PREFIX."bank_account";
$sql .= " WHERE clos = 0 AND courant = 1";
$sql .= " ORDER BY label";
@@ -92,19 +91,21 @@ class box_comptes extends ModeleBoxes {
$this->info_box_contents[$i][0] = array('align' => 'left',
'logo' => $this->boximg,
- 'text' => stripslashes($objp->label),
+ 'text' => $objp->label,
'url' => DOL_URL_ROOT."/compta/bank/account.php?account=".$objp->rowid);
+ /*
$this->info_box_contents[$i][1] = array('align' => 'left',
- 'text' => stripslashes($objp->bank)
+ 'text' => $objp->bank
+ );
+ */
+
+ $this->info_box_contents[$i][1] = array('align' => 'left',
+ 'text' => $objp->number
);
- $this->info_box_contents[$i][2] = array('align' => 'left',
- 'text' => stripslashes($objp->number)
- );
-
- $this->info_box_contents[$i][3] = array('align' => 'right',
- 'text' => price($acc->solde())
+ $this->info_box_contents[$i][2] = array('align' => 'right',
+ 'text' => price($acc->solde()).' '.$langs->trans("Currency".$objp->currency_code)
);
$i++;
@@ -115,14 +116,14 @@ class box_comptes extends ModeleBoxes {
$this->info_box_contents[$i][0] = array('align' => 'right',
//'width' => '75%',
- 'colspan' => '4',
+ 'colspan' => '3',
'class' => 'liste_total',
'text' => $langs->trans('Total')
);
$this->info_box_contents[$i][1] = array('align' => 'right',
'class' => 'liste_total',
- 'text' => price($solde_total)
+ 'text' => price($solde_total).' '.$langs->trans("Currency".$conf->monnaie)
);
}
diff --git a/htdocs/includes/boxes/box_factures.php b/htdocs/includes/boxes/box_factures.php
index 0f514686be1..c4fb07fc187 100644
--- a/htdocs/includes/boxes/box_factures.php
+++ b/htdocs/includes/boxes/box_factures.php
@@ -72,7 +72,7 @@ class box_factures extends ModeleBoxes {
if ($user->rights->facture->lire)
{
$sql = "SELECT f.rowid as facid, f.facnumber, f.type, f.amount, ".$db->pdate("f.datef")." as df,";
- $sql.= " f.paye, f.fk_statut,";
+ $sql.= " f.paye, f.fk_statut, f.datec,";
$sql.= " s.nom, s.rowid as socid";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", sc.fk_soc, sc.fk_user";
$sql.= " FROM ".MAIN_DB_PREFIX."societe as s,".MAIN_DB_PREFIX."facture as f";
@@ -109,11 +109,16 @@ class box_factures extends ModeleBoxes {
$this->info_box_contents[$i][1] = array('align' => 'left',
'text' => $objp->nom,
- 'maxlength'=>44,
+ 'maxlength'=>40,
'url' => DOL_URL_ROOT."/comm/fiche.php?socid=".$objp->socid);
- $this->info_box_contents[$i][2] = array(
+ $this->info_box_contents[$i][2] = array('align' => 'right',
+ 'text' => dolibarr_print_date($objp->datec,'day'),
+ );
+
+ $this->info_box_contents[$i][3] = array(
'align' => 'right',
+ 'width' => 18,
'text' => $facturestatic->LibStatut($objp->paye,$objp->fk_statut,3));
$i++;
@@ -128,11 +133,13 @@ class box_factures extends ModeleBoxes {
$this->info_box_contents[$i][1] = array('text'=>' ');
$this->info_box_contents[$i][2] = array('text'=>' ');
$this->info_box_contents[$i][3] = array('text'=>' ');
+ $this->info_box_contents[$i][4] = array('text'=>' ');
} else {
$this->info_box_contents[$i][0] = array('text'=>' ');
$this->info_box_contents[$i][1] = array('text'=>' ');
$this->info_box_contents[$i][2] = array('text'=>' ');
$this->info_box_contents[$i][3] = array('text'=>' ');
+ $this->info_box_contents[$i][4] = array('text'=>' ');
}
$i++;
}
diff --git a/htdocs/includes/boxes/box_factures_fourn.php b/htdocs/includes/boxes/box_factures_fourn.php
index c29e822f8fc..3cf69eaf97d 100644
--- a/htdocs/includes/boxes/box_factures_fourn.php
+++ b/htdocs/includes/boxes/box_factures_fourn.php
@@ -1,6 +1,6 @@
- * Copyright (C) 2004-2005 Laurent Destailleur
+ * Copyright (C) 2004-2007 Laurent Destailleur
*
* 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
@@ -73,8 +73,8 @@ class box_factures_fourn extends ModeleBoxes {
if ($user->rights->fournisseur->facture->lire)
{
$sql = "SELECT s.nom, s.rowid as socid,";
- $sql.= " f.facnumber, f.amount,".$db->pdate("f.datef")." as df,";
- $sql.= " f.paye, f.fk_statut, f.rowid as facid";
+ $sql.= " f.rowid as facid, f.facnumber, f.amount,".$db->pdate("f.datef")." as df,";
+ $sql.= " f.paye, f.fk_statut, f.datec";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", sc.fk_soc, sc.fk_user";
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s,".MAIN_DB_PREFIX."facture_fourn as f";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
@@ -108,8 +108,13 @@ class box_factures_fourn extends ModeleBoxes {
'text' => $objp->nom,
'url' => DOL_URL_ROOT."/fourn/fiche.php?socid=".$objp->socid);
- $this->info_box_contents[$i][2] = array(
+ $this->info_box_contents[$i][2] = array(
'align' => 'right',
+ 'text' => dolibarr_print_date($objp->datec,'day'));
+
+ $this->info_box_contents[$i][3] = array(
+ 'align' => 'right',
+ 'width' => 18,
'text' => $facturestatic->LibStatut($objp->paye,$objp->fk_statut,3));
$i++;
diff --git a/htdocs/includes/boxes/box_produits.php b/htdocs/includes/boxes/box_produits.php
index 8e979ef6414..bc035edb829 100644
--- a/htdocs/includes/boxes/box_produits.php
+++ b/htdocs/includes/boxes/box_produits.php
@@ -1,6 +1,6 @@
- * Copyright (C) 2004-2005 Laurent Destailleur
+ * Copyright (C) 2004-2007 Laurent Destailleur
*
* 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
@@ -18,7 +18,6 @@
*
* $Id$
* $Source$
- *
*/
/**
@@ -62,7 +61,6 @@ class box_produits extends ModeleBoxes {
function loadBox($max=5)
{
global $user, $langs, $db, $conf;
- $langs->load("boxes");
$productstatic=new Product($db);
@@ -70,7 +68,7 @@ class box_produits extends ModeleBoxes {
if ($user->rights->produit->lire)
{
- $sql = "SELECT p.label, p.rowid, p.price, p.fk_product_type, p.envente";
+ $sql = "SELECT p.rowid, p.label, p.price, p.price_base_type, p.price_ttc, p.fk_product_type, p.tms, p.envente";
$sql .= " FROM ".MAIN_DB_PREFIX."product as p";
if ($conf->categorie->enabled && !$user->rights->categorie->voir)
{
@@ -111,12 +109,32 @@ class box_produits extends ModeleBoxes {
'text' => $objp->label,
'url' => DOL_URL_ROOT."/product/fiche.php?id=".$objp->rowid);
- $this->info_box_contents[$i][1] = array(
+ if ($objp->price_base_type == 'HT')
+ {
+ $price=price($objp->price);
+ $price_base_type=$langs->trans("HT");
+ }
+ else
+ {
+ $price=price($objp->price_ttc);
+ $price_base_type=$langs->trans("TTC");
+ }
+ $this->info_box_contents[$i][1] = array(
'align' => 'right',
- 'text' => price($objp->price));
+ 'text' => $price);
- $this->info_box_contents[$i][2] = array(
+ $this->info_box_contents[$i][2] = array(
+ 'align' => 'center',
+ 'width' => 20,
+ 'text' => $price_base_type);
+
+ $this->info_box_contents[$i][3] = array(
'align' => 'right',
+ 'text' => dolibarr_print_date($objp->tms,'day'));
+
+ $this->info_box_contents[$i][4] = array(
+ 'align' => 'right',
+ 'width' => 18,
'text' => $productstatic->LibStatut($objp->envente,3));
$i++;
diff --git a/htdocs/includes/boxes/box_propales.php b/htdocs/includes/boxes/box_propales.php
index b6a2a9f3621..0dfad768e6c 100644
--- a/htdocs/includes/boxes/box_propales.php
+++ b/htdocs/includes/boxes/box_propales.php
@@ -73,7 +73,7 @@ class box_propales extends ModeleBoxes {
{
$sql = "SELECT s.nom, s.rowid as socid,";
- $sql.= " p.ref, p.fk_statut, ".$db->pdate("p.datep")." as dp, p.rowid";
+ $sql.= " p.rowid, p.ref, p.fk_statut, ".$db->pdate("p.datep")." as dp, p.datec";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", sc.fk_soc, sc.fk_user";
$sql .= " FROM ".MAIN_DB_PREFIX."societe as s,".MAIN_DB_PREFIX."propal as p";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
@@ -109,6 +109,11 @@ class box_propales extends ModeleBoxes {
$this->info_box_contents[$i][2] = array(
'align' => 'right',
+ 'text' => dolibarr_print_date($objp->datec,'day'));
+
+ $this->info_box_contents[$i][3] = array(
+ 'align' => 'right',
+ 'width' => 18,
'text' => $propalstatic->LibStatut($objp->fk_statut,3));
$i++;
@@ -123,11 +128,13 @@ class box_propales extends ModeleBoxes {
$this->info_box_contents[$i][1] = array('text'=>' ');
$this->info_box_contents[$i][2] = array('text'=>' ');
$this->info_box_contents[$i][3] = array('text'=>' ');
+ $this->info_box_contents[$i][4] = array('text'=>' ');
} else {
$this->info_box_contents[$i][0] = array('text'=>' ');
$this->info_box_contents[$i][1] = array('text'=>' ');
$this->info_box_contents[$i][2] = array('text'=>' ');
$this->info_box_contents[$i][3] = array('text'=>' ');
+ $this->info_box_contents[$i][4] = array('text'=>' ');
}
$i++;
}
diff --git a/htdocs/includes/boxes/box_prospect.php b/htdocs/includes/boxes/box_prospect.php
index eb7a47e1f60..2ba6ab04b67 100644
--- a/htdocs/includes/boxes/box_prospect.php
+++ b/htdocs/includes/boxes/box_prospect.php
@@ -63,7 +63,6 @@ class box_prospect extends ModeleBoxes {
function loadBox($max=5)
{
global $user, $langs, $db;
- $langs->load("boxes");
$this->info_box_head = array('text' => $langs->trans("BoxTitleLastProspects",$max));
@@ -99,10 +98,11 @@ class box_prospect extends ModeleBoxes {
'text' => stripslashes($objp->nom),
'url' => DOL_URL_ROOT."/comm/prospect/fiche.php?id=".$objp->socid);
- $this->info_box_contents[$i][1] = array('align' => 'ce,ter',
+ $this->info_box_contents[$i][1] = array('align' => 'right',
'text' => dolibarr_print_date($objp->dc, "day"));
$this->info_box_contents[$i][2] = array('align' => 'right',
+ 'width' => 18,
'text' => $prospectstatic->LibStatut($objp->fk_stcomm,3));
$i++;
diff --git a/htdocs/includes/boxes/box_services_vendus.php b/htdocs/includes/boxes/box_services_vendus.php
index 2819d857be5..aff0b36c0a8 100644
--- a/htdocs/includes/boxes/box_services_vendus.php
+++ b/htdocs/includes/boxes/box_services_vendus.php
@@ -1,6 +1,6 @@
- * Copyright (C) 2005-2006 Laurent Destailleur
+ * Copyright (C) 2005-2007 Laurent Destailleur
* Copyright (C) 2005-2006 Regis Houssin
*
* This program is free software; you can redistribute it and/or modify
@@ -61,22 +61,27 @@ class box_services_vendus extends ModeleBoxes {
function loadBox($max=5)
{
global $user, $langs, $db, $conf;
- $langs->load("boxes");
+
+ include_once(DOL_DOCUMENT_ROOT."/contrat/contrat.class.php");
+ $contratlignestatic=new ContratLigne($db);
$this->info_box_head = array('text' => $langs->trans("BoxLastProductsInContract",$max));
if ($user->rights->produit->lire && $user->rights->contrat->lire)
{
- $sql = "SELECT s.nom, s.rowid as socid, c.rowid, cd.rowid as cdid, p.rowid as pid, p.label, p.fk_product_type";
+ $sql = "SELECT s.nom, s.rowid as socid,";
+ $sql.= " c.rowid,";
+ $sql.= " cd.rowid as cdid, cd.tms as datem, cd.statut,";
+ $sql.= " p.rowid as pid, p.label, p.fk_product_type";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", sc.fk_soc, sc.fk_user";
- $sql .= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."contrat as c, ".MAIN_DB_PREFIX."contratdet as cd, ".MAIN_DB_PREFIX."product as p";
+ $sql.= " FROM ".MAIN_DB_PREFIX."societe as s, ".MAIN_DB_PREFIX."contrat as c, ".MAIN_DB_PREFIX."contratdet as cd, ".MAIN_DB_PREFIX."product as p";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
if ($conf->categorie->enabled && !$user->rights->categorie->voir)
{
- $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."categorie_product as cp ON cp.fk_product = p.rowid";
- $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as ca ON cp.fk_categorie = ca.rowid";
+ $sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie_product as cp ON cp.fk_product = p.rowid";
+ $sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as ca ON cp.fk_categorie = ca.rowid";
}
- $sql .= " WHERE s.rowid = c.fk_soc AND c.rowid = cd.fk_contrat AND cd.fk_product = p.rowid";
+ $sql.= " WHERE s.rowid = c.fk_soc AND c.rowid = cd.fk_contrat AND cd.fk_product = p.rowid";
if (!$user->rights->commercial->client->voir && !$user->societe_id) $sql .= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
if ($conf->categorie->enabled && !$user->rights->categorie->voir)
{
@@ -84,10 +89,10 @@ class box_services_vendus extends ModeleBoxes {
}
if($user->societe_id)
{
- $sql .= " AND s.rowid = ".$user->societe_id;
+ $sql.= " AND s.rowid = ".$user->societe_id;
}
- $sql .= " ORDER BY c.tms DESC ";
- $sql .= $db->plimit($max, 0);
+ $sql.= " ORDER BY c.tms DESC ";
+ $sql.= $db->plimit($max, 0);
$result = $db->query($sql);
@@ -126,7 +131,15 @@ class box_services_vendus extends ModeleBoxes {
'text' => $objp->nom,
'maxlength' => 40,
'url' => DOL_URL_ROOT."/comm/fiche.php?socid=".$objp->socid);
-
+
+ $this->info_box_contents[$i][2] = array('align' => 'right',
+ 'text' => dolibarr_print_date($objp->datem,'day'));
+
+ $this->info_box_contents[$i][3] = array('align' => 'right',
+ 'text' => $contratlignestatic->LibStatut($objp->statut,3),
+ 'width' => 18
+ );
+
$i++;
}
}
diff --git a/htdocs/langs/en_US/boxes.lang b/htdocs/langs/en_US/boxes.lang
index c226edead9a..0323db55b73 100644
--- a/htdocs/langs/en_US/boxes.lang
+++ b/htdocs/langs/en_US/boxes.lang
@@ -19,8 +19,8 @@ BoxTotalUnpayedSuppliersBills=Total unpayed supplier's invoices
BoxTitleLastBooks=Last %s recorded books
BoxTitleNbOfCustomers=Nombre de client
BoxTitleLastRssInfos=Last %s news from %s
-BoxTitleLastProducts=Last %s recorded products/services
-BoxTitleLastCustomerOrders=Last %s customer orders
+BoxTitleLastProducts=Last %s modified products/services
+BoxTitleLastCustomerOrders=Last %s modified customer orders
BoxTitleLastSuppliers=Last %s recorded suppliers
BoxTitleLastCustomers=Last %s recorded customers
BoxTitleLastPropals=Last %s recorded proposals
diff --git a/htdocs/langs/en_US/main.lang b/htdocs/langs/en_US/main.lang
index dabef17d62d..a3159c8dd52 100644
--- a/htdocs/langs/en_US/main.lang
+++ b/htdocs/langs/en_US/main.lang
@@ -391,6 +391,7 @@ CountryCA=Canada
Currencyeuros=Euros
CurrencyCHF=Swiss Francs
CurrencyEUR=Euros
+CurrencyFRF=Francs Français
CurrencyGBP=GB Pounds
CurrencyUSD=Dollar US
# Week day
diff --git a/htdocs/langs/fr_BE/boxes.lang b/htdocs/langs/fr_BE/boxes.lang
index 7759ed466cb..7a9a9cb0724 100644
--- a/htdocs/langs/fr_BE/boxes.lang
+++ b/htdocs/langs/fr_BE/boxes.lang
@@ -19,7 +19,7 @@ BoxTotalUnpayedSuppliersBills=Total des factures fournisseurs impay
BoxTitleLastBooks=Derniers % livres enregistrés
BoxTitleNbOfCustomers=Nombre de clients
BoxTitleLastRssInfos=%s dernières nouvelles sur %s
-BoxTitleLastProducts=%s derniers produits/services enregistrés
+BoxTitleLastProducts=%s derniers produits/services modifiés
BoxTitleLastCustomerOrders=%s dernières commandes clients
BoxTitleLastSuppliers=%s derniers fournisseurs enregistrés
BoxTitleLastCustomers=%s derniers clients enregistrés
diff --git a/htdocs/langs/fr_BE/main.lang b/htdocs/langs/fr_BE/main.lang
index 70f297fd8ac..88376a47564 100644
--- a/htdocs/langs/fr_BE/main.lang
+++ b/htdocs/langs/fr_BE/main.lang
@@ -355,3 +355,4 @@ CurrencyCHF=Francs suisses
CurrencyEUR=Euros
CurrencyGBP=Livre sterling
CurrencyUSD=Dollar US
+CurrencyFRF=Francs Français
diff --git a/htdocs/langs/fr_FR/boxes.lang b/htdocs/langs/fr_FR/boxes.lang
index b2f22bfcae8..1a6b1172f86 100644
--- a/htdocs/langs/fr_FR/boxes.lang
+++ b/htdocs/langs/fr_FR/boxes.lang
@@ -20,7 +20,7 @@ BoxTitleLastBooks=Les %s derniers ouvrages enregistr
BoxTitleNbOfCustomers=Nombre de clients
BoxTitleLastRssInfos=Les %s dernières infos de %s
BoxTitleLastProducts=Les %s derniers produits/services enregistrés
-BoxTitleLastCustomerOrders=Les %s dernières commandes clients
+BoxTitleLastCustomerOrders=Les %s dernières commandes clients modifiées
BoxTitleLastSuppliers=Les %s derniers fournisseurs enregistrés
BoxTitleLastCustomers=Les %s derniers clients enregistrés
BoxTitleLastPropals=Les %s dernières propositions enregistrés
diff --git a/htdocs/langs/fr_FR/main.lang b/htdocs/langs/fr_FR/main.lang
index a40591b41fe..92314ef498e 100644
--- a/htdocs/langs/fr_FR/main.lang
+++ b/htdocs/langs/fr_FR/main.lang
@@ -392,6 +392,7 @@ CountryCA=Canada
Currencyeuros=Euros
CurrencyCHF=Francs suisses
CurrencyEUR=Euros
+CurrencyFRF=Francs Français
CurrencyGBP=Livre sterling
CurrencyUSD=Dollar US
# Week day
diff --git a/mysql/migration/2.1.0-2.2.0.sql b/mysql/migration/2.1.0-2.2.0.sql
index c5a60f033cc..f6233571d36 100644
--- a/mysql/migration/2.1.0-2.2.0.sql
+++ b/mysql/migration/2.1.0-2.2.0.sql
@@ -11,6 +11,10 @@
-- Nettoyage champ ref table llx_bank_account
update llx_bank_account set ref=concat('ACCOUNT',rowid) where (ref='' or ref is null);
+update llx_bank_account set currency_code='EU' where (currency_code IS NULL or currency_code='');
+alter table llx_bank_account modify currency_code varchar(3) NOT NULL;
+update llx_bank_account set currency_code='EUR' where (currency_code IS NULL or currency_code='' or currency_code='EU');
+
-- Sequence de requete pour nettoyage et correction champ type table llx_bank_url
update llx_bank_url set type='company' where (type is null or type = '') and url like '%compta/fiche.php?socid=%';
alter table llx_bank_url modify `type` enum("","?","company","payment","payment_supplier","member","subscription","donation","sc","payment_sc");
diff --git a/mysql/tables/llx_bank_account.sql b/mysql/tables/llx_bank_account.sql
index c7b7e0713db..50da3eee496 100644
--- a/mysql/tables/llx_bank_account.sql
+++ b/mysql/tables/llx_bank_account.sql
@@ -1,6 +1,6 @@
-- =============================================================================
-- Copyright (C) 2000-2004 Rodolphe Quiedeville
--- Copyright (C) 2004-2006 Laurent Destailleur
+-- Copyright (C) 2004-2007 Laurent Destailleur
--
-- 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
@@ -47,7 +47,7 @@ create table llx_bank_account
rappro smallint DEFAULT 1,
url varchar(128),
account_number varchar(8),
- currency_code varchar(2) NOT NULL,
+ currency_code varchar(3) NOT NULL,
min_allowed integer DEFAULT 0,
min_desired integer DEFAULT 0,
comment varchar(254)