From a0fb27bd80dcd528ee740f514166e82e97dddda8 Mon Sep 17 00:00:00 2001 From: Florian HENRY Date: Tue, 15 Sep 2015 14:34:49 +0200 Subject: [PATCH 01/30] FIX : Can create Proposal on close thridparty #3526 --- htdocs/comm/card.php | 12 ++++++------ htdocs/comm/propal.php | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/htdocs/comm/card.php b/htdocs/comm/card.php index 450a462c751..75e102b96bb 100644 --- a/htdocs/comm/card.php +++ b/htdocs/comm/card.php @@ -828,25 +828,25 @@ if ($id > 0) print '
'; - if (! empty($conf->propal->enabled) && $user->rights->propal->creer) + if (! empty($conf->propal->enabled) && $user->rights->propal->creer && $object->status==1) { $langs->load("propal"); print ''; } - if (! empty($conf->commande->enabled) && $user->rights->commande->creer) + if (! empty($conf->commande->enabled) && $user->rights->commande->creer && $object->status==1) { $langs->load("orders"); print ''; } - if ($user->rights->contrat->creer) + if ($user->rights->contrat->creer && $object->status==1) { $langs->load("contracts"); print ''; } - if (! empty($conf->ficheinter->enabled) && $user->rights->ficheinter->creer) + if (! empty($conf->ficheinter->enabled) && $user->rights->ficheinter->creer && $object->status==1) { $langs->load("fichinter"); print ''; @@ -855,7 +855,7 @@ if ($id > 0) // Add invoice if ($user->societe_id == 0) { - if (! empty($conf->deplacement->enabled)) + if (! empty($conf->deplacement->enabled) && $object->status==1) { $langs->load("trips"); print ''; @@ -863,7 +863,7 @@ if ($id > 0) if (! empty($conf->facture->enabled)) { - if ($user->rights->facture->creer) + if ($user->rights->facture->creer && $object->status==1) { $langs->load("bills"); $langs->load("orders"); diff --git a/htdocs/comm/propal.php b/htdocs/comm/propal.php index b5302063a65..5fef6f8ae29 100644 --- a/htdocs/comm/propal.php +++ b/htdocs/comm/propal.php @@ -1267,7 +1267,7 @@ if ($action == 'create') print ''; } else { print ''; - print $form->select_company('', 'socid', 's.client = 1 OR s.client = 2 OR s.client = 3', 1); + print $form->select_company('', 'socid', '(s.client = 1 OR s.client = 2 OR s.client = 3) AND status=1', 1); print ''; } print '' . "\n"; From 8fd9d2a7cefc5b932ea2c908258207776036b920 Mon Sep 17 00:00:00 2001 From: Florian HENRY Date: Wed, 16 Sep 2015 10:21:32 +0200 Subject: [PATCH 02/30] FIX : #3530 --- htdocs/fourn/facture/paiement.php | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/htdocs/fourn/facture/paiement.php b/htdocs/fourn/facture/paiement.php index ba3f82c78e0..81fe1d6b345 100644 --- a/htdocs/fourn/facture/paiement.php +++ b/htdocs/fourn/facture/paiement.php @@ -5,11 +5,8 @@ * Copyright (C) 2004 Christophe Combelles * Copyright (C) 2005 Marc Barilley / Ocebo * Copyright (C) 2005-2012 Regis Houssin -<<<<<<< HEAD * Copyright (C) 2014 Teddy Andreotti <125155@supinfo.com> -======= * Copyright (C) 2015 Marcos García ->>>>>>> refs/remotes/origin/3.6 * * 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 @@ -46,6 +43,7 @@ $confirm = GETPOST('confirm'); $facid=GETPOST('facid','int'); $socid=GETPOST('socid','int'); +$accountid = GETPOST('accountid'); $sortfield = GETPOST("sortfield",'alpha'); $sortorder = GETPOST("sortorder",'alpha'); @@ -200,7 +198,7 @@ if (empty($reshook)) if (! $error) { - $result=$paiement->addPaymentToBank($user,'payment_supplier','(SupplierInvoicePayment)',$_POST['accountid'],'',''); + $result=$paiement->addPaymentToBank($user,'payment_supplier','(SupplierInvoicePayment)',$accountid,'',''); if ($result < 0) { setEventMessage($paiement->error, 'errors'); @@ -304,7 +302,7 @@ if ($action == 'create' || $action == 'confirm_paiement' || $action == 'add_paie if (! empty($conf->banque->enabled)) { print ''.$langs->trans('Account').''; - $form->select_comptes(empty($_POST['accountid'])?'':$_POST['accountid'],'accountid',0,'',2); + $form->select_comptes(empty($accountid)?'':$accountid,'accountid',0,'',2); print ''; } else From cb31ab3e2b925a0feabdd511b78da063c7e22b3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Doursenaud?= Date: Wed, 16 Sep 2015 19:53:32 +0200 Subject: [PATCH 03/30] FIX Syntax error in Debian Apache configuration This issue prevented Apache from starting after dolibarr deb package installation with the following error: Syntax error on line 30 of /etc/apache2/conf.d/dolibarr.conf: order takes one argument, 'allow,deny', 'deny,allow', or 'mutual-failure' --- build/debian/apache/dolibarr.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/build/debian/apache/dolibarr.conf b/build/debian/apache/dolibarr.conf index 95eaae21190..bdbb6e1b4c3 100644 --- a/build/debian/apache/dolibarr.conf +++ b/build/debian/apache/dolibarr.conf @@ -15,7 +15,7 @@ Alias /dolibarr /usr/share/dolibarr/htdocs # Require all granted # # -# Order allow, deny +# Order allow,deny # Allow from all # # @@ -27,7 +27,7 @@ Alias /dolibarr /usr/share/dolibarr/htdocs Require all granted - Order allow, deny + Order allow,deny Allow from all From f8f24f7b29d1d60164cf634362cfbd6ac89f46be Mon Sep 17 00:00:00 2001 From: AlainRnet Date: Thu, 17 Sep 2015 10:35:18 +0200 Subject: [PATCH 04/30] Update categorie.php MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit la navigation entre membre depuis sa catégorie ne fonctionne pas sans ajouter "&type=3" à l'URL --- htdocs/categories/categorie.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/categories/categorie.php b/htdocs/categories/categorie.php index 083edbf6b7e..43803d045bb 100644 --- a/htdocs/categories/categorie.php +++ b/htdocs/categories/categorie.php @@ -419,7 +419,7 @@ else if ($id || $ref) // Ref print ''.$langs->trans("Ref").''; print ''; - print $form->showrefnav($member,'id'); + print $form->showrefnav($member,'id','','1','rowid','ref','','&type=3'); print ''; // Login From 148e8a2c233d354d58ef8565001b8895a714c8fb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rapha=C3=ABl=20Doursenaud?= Date: Thu, 17 Sep 2015 20:38:48 +0200 Subject: [PATCH 05/30] Used OOP for mysqli connector Better error handling Slightly more readable codebase --- htdocs/core/db/mysqli.class.php | 120 +++++++++++++++----------------- 1 file changed, 55 insertions(+), 65 deletions(-) diff --git a/htdocs/core/db/mysqli.class.php b/htdocs/core/db/mysqli.class.php index 4033dc01117..068cd410326 100644 --- a/htdocs/core/db/mysqli.class.php +++ b/htdocs/core/db/mysqli.class.php @@ -31,6 +31,8 @@ require_once DOL_DOCUMENT_ROOT .'/core/db/DoliDB.class.php'; */ class DoliDBMysqli extends DoliDB { + /** @var mysqli Database object */ + public $db; //! Database type public $type='mysqli'; //! Database label @@ -81,29 +83,26 @@ class DoliDBMysqli extends DoliDB $this->connected = false; $this->ok = false; $this->error=$langs->trans("ErrorWrongHostParameter"); - dol_syslog(get_class($this)."::DoliDBMysqli : Erreur Connect, wrong host parameters",LOG_ERR); + dol_syslog(get_class($this)."::DoliDBMysqli : Connect error, wrong host parameters",LOG_ERR); return $this->ok; } - // Essai connexion serveur - // We do not try to connect to database, only to server. Connect to database is done later in constrcutor - $this->db = $this->connect($host, $user, $pass, '', $port); + // Try server connection + // We do not try to connect to database, only to server. Connect to database is done later in constrcutor + $this->db = $this->connect($host, $user, $pass, '', $port); - if ($this->db) - { - $this->connected = true; - $this->ok = true; - } - else - { - // host, login ou password incorrect - $this->connected = false; - $this->ok = false; - $this->error=mysqli_connect_error(); - dol_syslog(get_class($this)."::DoliDBMysqli : Erreur Connect mysqli_connect_error=".$this->error,LOG_ERR); - } + if ($this->db->connect_errno) { + $this->connected = false; + $this->ok = false; + $this->error = $this->db->connect_error; + dol_syslog(get_class($this) . "::DoliDBMysqli Connect error: " . $this->error, LOG_ERR); + return $this->ok; + } else { + $this->connected = true; + $this->ok = true; + } - // Si connexion serveur ok et si connexion base demandee, on essaie connexion base + // If server connection is ok, we try to connect to the database if ($this->connected && $name) { if ($this->select_db($name)) @@ -116,7 +115,7 @@ class DoliDBMysqli extends DoliDB $clientmustbe=''; if (preg_match('/UTF-8/i',$conf->file->character_set_client)) $clientmustbe='utf8'; if (preg_match('/ISO-8859-1/i',$conf->file->character_set_client)) $clientmustbe='latin1'; - if (mysqli_character_set_name($this->db) != $clientmustbe) + if ($this->db->character_set_name() != $clientmustbe) { $this->query("SET NAMES '".$clientmustbe."'", $this->db); //$this->query("SET CHARACTER SET ". $this->forcecharset); @@ -128,7 +127,7 @@ class DoliDBMysqli extends DoliDB $this->database_name = ''; $this->ok = false; $this->error=$this->error(); - dol_syslog(get_class($this)."::DoliDBMysqli : Erreur Select_db ".$this->error,LOG_ERR); + dol_syslog(get_class($this)."::DoliDBMysqli : Select_db error ".$this->error,LOG_ERR); } } else @@ -142,7 +141,7 @@ class DoliDBMysqli extends DoliDB $clientmustbe=''; if (preg_match('/UTF-8/i',$conf->file->character_set_client)) $clientmustbe='utf8'; if (preg_match('/ISO-8859-1/i',$conf->file->character_set_client)) $clientmustbe='latin1'; - if (mysqli_character_set_name($this->db) != $clientmustbe) + if ($this->db->character_set_name() != $clientmustbe) { $this->query("SET NAMES '".$clientmustbe."'", $this->db); //$this->query("SET CHARACTER SET ". $this->forcecharset); @@ -175,36 +174,27 @@ class DoliDBMysqli extends DoliDB function select_db($database) { dol_syslog(get_class($this)."::select_db database=".$database, LOG_DEBUG); - return mysqli_select_db($this->db,$database); + return $this->db->select_db($database); } - /** - * Connexion to server + /** + * Connect to server * - * @param string $host database server host - * @param string $login login - * @param string $passwd password - * @param string $name name of database (not used for mysql, used for pgsql) - * @param integer $port Port of database server - * @return mysqli Database access handler - * @see close - */ - function connect($host, $login, $passwd, $name, $port=0) - { - dol_syslog(get_class($this)."::connect host=$host, port=$port, login=$login, passwd=--hidden--, name=$name",LOG_DEBUG); + * @param string $host database server host + * @param string $login login + * @param string $passwd password + * @param string $name name of database (not used for mysql, used for pgsql) + * @param integer $port Port of database server + * @return mysqli Database access object + * @see close + */ + function connect($host, $login, $passwd, $name, $port = 0) + { + dol_syslog(get_class($this) . "::connect host=$host, port=$port, login=$login, passwd=--hidden--, name=$name", LOG_DEBUG); - $newhost=$host; - $newport=$port; - - // With mysqli, port must be in connect parameters - if (! $newport) $newport=3306; - - $this->db = @mysqli_connect($newhost, $login, $passwd, $name, $newport); - - //print "Resultat fonction connect: ".$this->db; - return $this->db; - } + return new mysqli($host, $login, $passwd, $name, $port); + } /** * Return version of database server @@ -213,7 +203,7 @@ class DoliDBMysqli extends DoliDB */ function getVersion() { - return mysqli_get_server_info($this->db); + return $this->db->get_server_info(); } /** @@ -221,10 +211,10 @@ class DoliDBMysqli extends DoliDB * * @return string Version string */ - function getDriverInfo() - { - return mysqli_get_client_info($this->db); - } + function getDriverInfo() + { + return $this->db->get_client_info(); + } /** @@ -239,7 +229,7 @@ class DoliDBMysqli extends DoliDB { if ($this->transaction_opened > 0) dol_syslog(get_class($this)."::close Closing a connection with an opened transaction depth=".$this->transaction_opened,LOG_ERR); $this->connected=false; - return mysqli_close($this->db); + return $this->db->close(); } return false; } @@ -264,11 +254,11 @@ class DoliDBMysqli extends DoliDB if (! $this->database_name) { // Ordre SQL ne necessitant pas de connexion a une base (exemple: CREATE DATABASE) - $ret = mysqli_query($this->db,$query); + $ret = $this->db->query($query); } else { - $ret = mysqli_query($this->db,$query); + $ret = $this->db->query($query); } if (! preg_match("/^COMMIT/i",$query) && ! preg_match("/^ROLLBACK/i",$query)) @@ -300,7 +290,7 @@ class DoliDBMysqli extends DoliDB { // Si le resultset n'est pas fourni, on prend le dernier utilise sur cette connexion if (! is_object($resultset)) { $resultset=$this->_results; } - return mysqli_fetch_object($resultset); + return $resultset->fetch_object(); } @@ -314,7 +304,7 @@ class DoliDBMysqli extends DoliDB { // If resultset not provided, we take the last used by connexion if (! is_object($resultset)) { $resultset=$this->_results; } - return mysqli_fetch_array($resultset); + return $resultset->fetch_array(); } /** @@ -329,7 +319,7 @@ class DoliDBMysqli extends DoliDB if (! is_bool($resultset)) { if (! is_object($resultset)) { $resultset=$this->_results; } - return mysqli_fetch_row($resultset); + return $resultset->fetch_row(); } else { @@ -349,7 +339,7 @@ class DoliDBMysqli extends DoliDB { // If resultset not provided, we take the last used by connexion if (! is_object($resultset)) { $resultset=$this->_results; } - return mysqli_num_rows($resultset); + return $resultset->num_rows; } /** @@ -365,7 +355,7 @@ class DoliDBMysqli extends DoliDB if (! is_object($resultset)) { $resultset=$this->_results; } // mysql necessite un link de base pour cette fonction contrairement // a pqsql qui prend un resultset - return mysqli_affected_rows($this->db); + return $this->db->affected_rows; } @@ -380,7 +370,7 @@ class DoliDBMysqli extends DoliDB // If resultset not provided, we take the last used by connexion if (! is_object($resultset)) { $resultset=$this->_results; } // Si resultset en est un, on libere la memoire - if (is_object($resultset)) mysqli_free_result($resultset); + if (is_object($resultset)) $resultset->free_result(); } /** @@ -436,10 +426,10 @@ class DoliDBMysqli extends DoliDB 1451 => 'DB_ERROR_CHILD_EXISTS' ); - if (isset($errorcode_map[mysqli_errno($this->db)])) { - return $errorcode_map[mysqli_errno($this->db)]; + if (isset($errorcode_map[$this->db->errno])) { + return $errorcode_map[$this->db->errno]; } - $errno=mysqli_errno($this->db); + $errno=$this->db->errno; return ($errno?'DB_ERROR_'.$errno:'0'); } } @@ -456,7 +446,7 @@ class DoliDBMysqli extends DoliDB return 'Not connected. Check setup parameters in conf/conf.php file and your mysql client and server versions'; } else { - return mysqli_error($this->db); + return $this->db->error; } } @@ -469,7 +459,7 @@ class DoliDBMysqli extends DoliDB */ function last_insert_id($tab,$fieldid='rowid') { - return mysqli_insert_id($this->db); + return $this->db->insert_id; } /** From 8dd843ab8f7e1947cabc359cf0ebcc41fde634c7 Mon Sep 17 00:00:00 2001 From: AlainRnet Date: Thu, 17 Sep 2015 23:23:18 +0200 Subject: [PATCH 06/30] Update categorie.php MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit voir https://github.com/Dolibarr/dolibarr/pull/3540/files (je n'avais pas vu dans quelle branche j'étais) --- htdocs/categories/categorie.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/categories/categorie.php b/htdocs/categories/categorie.php index 0746475ecec..9e780223d0e 100644 --- a/htdocs/categories/categorie.php +++ b/htdocs/categories/categorie.php @@ -410,7 +410,7 @@ else if ($id || $ref) // Ref print ''.$langs->trans("Ref").''; print ''; - print $form->showrefnav($member,'id'); + print $form->showrefnav($member,'id','','1','rowid','ref','','&type=3'); print ''; // Login From 1901b2fb3bed1bab01dc96bc9234a60db79f27b8 Mon Sep 17 00:00:00 2001 From: aspangaro Date: Sat, 19 Sep 2015 07:15:13 +0200 Subject: [PATCH 07/30] Missing translations in checks deposits exports --- htdocs/core/modules/modBanque.class.php | 2 +- htdocs/langs/en_US/bills.lang | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/htdocs/core/modules/modBanque.class.php b/htdocs/core/modules/modBanque.class.php index efb242aca94..5103e76b4e7 100644 --- a/htdocs/core/modules/modBanque.class.php +++ b/htdocs/core/modules/modBanque.class.php @@ -164,7 +164,7 @@ class modBanque extends DolibarrModules $this->export_code[$r]=$this->rights_class.'_'.$r; $this->export_label[$r]='Bordereaux remise Chq/Fact'; $this->export_permission[$r]=array(array("banque","export")); - $this->export_fields_array[$r]=array("bch.rowid"=>"bordereauid","bch.number"=>"Numero","bch.ref_ext"=>"RefExt",'ba.ref'=>'AccountRef','ba.label'=>'AccountLabel','b.datev'=>'DateValue','b.num_chq'=>'ChequeOrTransferNumber','b.amount'=>'Credit','b.num_releve'=>'AccountStatement','b.datec'=>"DateCreation", + $this->export_fields_array[$r]=array("bch.rowid"=>"depositid","bch.number"=>"Numero","bch.ref_ext"=>"RefExt",'ba.ref'=>'AccountRef','ba.label'=>'AccountLabel','b.datev'=>'DateValue','b.num_chq'=>'ChequeOrTransferNumber','b.amount'=>'Credit','b.num_releve'=>'AccountStatement','b.datec'=>"DateCreation", "bch.date_bordereau"=>"Date","bch.amount"=>"Total","bch.nbcheque"=>"NbCheque","bu.url_id"=>"IdThirdParty","s.nom"=>"ThirdParty","f.facnumber"=>"InvoiceRef" ); $this->export_TypeFields_array[$r]=array('ba.ref'=>'Text','ba.label'=>'Text','b.datev'=>'Date','b.num_chq'=>'Text','b.amount'=>'Numeric','b.num_releve'=>'Text','b.datec'=>"Date", diff --git a/htdocs/langs/en_US/bills.lang b/htdocs/langs/en_US/bills.lang index a78ff96511e..54a626b5ae9 100644 --- a/htdocs/langs/en_US/bills.lang +++ b/htdocs/langs/en_US/bills.lang @@ -383,6 +383,8 @@ ChequesReceipts=Checks receipts ChequesArea=Checks deposits area ChequeDeposits=Checks deposits Cheques=Checks +DepositId=Id deposit +NbCheque=Number of checks CreditNoteConvertedIntoDiscount=This credit note or deposit invoice has been converted into %s UsBillingContactAsIncoiveRecipientIfExist=Use customer billing contact address instead of third party address as recipient for invoices ShowUnpaidAll=Show all unpaid invoices From 49f671eb1d430b0b2850942c11dc3e17a89a7da3 Mon Sep 17 00:00:00 2001 From: aspangaro Date: Sat, 19 Sep 2015 07:24:32 +0200 Subject: [PATCH 08/30] Correct name --- htdocs/core/modules/modBanque.class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/modules/modBanque.class.php b/htdocs/core/modules/modBanque.class.php index 5103e76b4e7..aa83133bc08 100644 --- a/htdocs/core/modules/modBanque.class.php +++ b/htdocs/core/modules/modBanque.class.php @@ -164,7 +164,7 @@ class modBanque extends DolibarrModules $this->export_code[$r]=$this->rights_class.'_'.$r; $this->export_label[$r]='Bordereaux remise Chq/Fact'; $this->export_permission[$r]=array(array("banque","export")); - $this->export_fields_array[$r]=array("bch.rowid"=>"depositid","bch.number"=>"Numero","bch.ref_ext"=>"RefExt",'ba.ref'=>'AccountRef','ba.label'=>'AccountLabel','b.datev'=>'DateValue','b.num_chq'=>'ChequeOrTransferNumber','b.amount'=>'Credit','b.num_releve'=>'AccountStatement','b.datec'=>"DateCreation", + $this->export_fields_array[$r]=array("bch.rowid"=>"DepositId","bch.number"=>"Numero","bch.ref_ext"=>"RefExt",'ba.ref'=>'AccountRef','ba.label'=>'AccountLabel','b.datev'=>'DateValue','b.num_chq'=>'ChequeOrTransferNumber','b.amount'=>'Credit','b.num_releve'=>'AccountStatement','b.datec'=>"DateCreation", "bch.date_bordereau"=>"Date","bch.amount"=>"Total","bch.nbcheque"=>"NbCheque","bu.url_id"=>"IdThirdParty","s.nom"=>"ThirdParty","f.facnumber"=>"InvoiceRef" ); $this->export_TypeFields_array[$r]=array('ba.ref'=>'Text','ba.label'=>'Text','b.datev'=>'Date','b.num_chq'=>'Text','b.amount'=>'Numeric','b.num_releve'=>'Text','b.datec'=>"Date", From de04f3022c3150f905d75a855d20129f32add9c8 Mon Sep 17 00:00:00 2001 From: Regis Houssin Date: Sun, 20 Sep 2015 09:05:52 +0200 Subject: [PATCH 09/30] Fix: use get instead getJSON for avoid freezing --- htdocs/ecm/tpl/enablefiletreeajax.tpl.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/ecm/tpl/enablefiletreeajax.tpl.php b/htdocs/ecm/tpl/enablefiletreeajax.tpl.php index b348cb03c72..7b2145d0f93 100644 --- a/htdocs/ecm/tpl/enablefiletreeajax.tpl.php +++ b/htdocs/ecm/tpl/enablefiletreeajax.tpl.php @@ -51,7 +51,7 @@ $(document).ready(function() { $('#refreshbutton').click( function() { $.pleaseBePatient("trans('PleaseBePatient'); ?>"); - $.getJSON( "", { + $.get( "", { action: "build", element: "ecm" }, From 7d4a9b17b6d08d041637e25322dd4aacc1e992ec Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 21 Sep 2015 13:59:22 +0200 Subject: [PATCH 10/30] FIX Creation of tables or keys must not be done with a random order. --- htdocs/core/modules/DolibarrModules.class.php | 28 +++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/htdocs/core/modules/DolibarrModules.class.php b/htdocs/core/modules/DolibarrModules.class.php index c886741fc41..0de1c7ab4ab 100644 --- a/htdocs/core/modules/DolibarrModules.class.php +++ b/htdocs/core/modules/DolibarrModules.class.php @@ -623,8 +623,14 @@ abstract class DolibarrModules { $dirfound++; - // Run llx_mytable.sql files + // Run llx_mytable.sql files, then llx_mytable_*.sql + $files = array(); while (($file = readdir($handle))!==false) + { + $files[] = $file; + } + sort($files); + foreach ($files as $file) { if (preg_match('/\.sql$/i',$file) && ! preg_match('/\.key\.sql$/i',$file) && substr($file,0,4) == 'llx_' && substr($file,0,4) != 'data') { @@ -635,8 +641,14 @@ abstract class DolibarrModules rewinddir($handle); - // Run llx_mytable.key.sql files (Must be done after llx_mytable.sql) + // Run llx_mytable.key.sql files (Must be done after llx_mytable.sql) then then llx_mytable_*.key.sql + $files = array(); while (($file = readdir($handle))!==false) + { + $files[] = $file; + } + sort($files); + foreach ($files as $file) { if (preg_match('/\.key\.sql$/i',$file) && substr($file,0,4) == 'llx_' && substr($file,0,4) != 'data') { @@ -648,7 +660,13 @@ abstract class DolibarrModules rewinddir($handle); // Run data_xxx.sql files (Must be done after llx_mytable.key.sql) + $files = array(); while (($file = readdir($handle))!==false) + { + $files[] = $file; + } + sort($files); + foreach ($files as $file) { if (preg_match('/\.sql$/i',$file) && ! preg_match('/\.key\.sql$/i',$file) && substr($file,0,4) == 'data') { @@ -660,7 +678,13 @@ abstract class DolibarrModules rewinddir($handle); // Run update_xxx.sql files + $files = array(); while (($file = readdir($handle))!==false) + { + $files[] = $file; + } + sort($files); + foreach ($files as $file) { if (preg_match('/\.sql$/i',$file) && ! preg_match('/\.key\.sql$/i',$file) && substr($file,0,6) == 'update') { From f2e2edbc64311e744e7d6e11bef519e1e20050af Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 21 Sep 2015 15:10:52 +0200 Subject: [PATCH 11/30] FIX not closing CSS. --- htdocs/theme/eldy/style.css.php | 1 - 1 file changed, 1 deletion(-) diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index a3734e1e1ab..7ecf63b1000 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -3669,7 +3669,6 @@ border-top-right-radius: 6px; .public_border { border: 1px solid #888; } -.public_liste_titre { From 2df47ff99c23b3318756e669d7d6776f6393f8bd Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 21 Sep 2015 15:18:29 +0200 Subject: [PATCH 12/30] Better responsive top menu --- htdocs/theme/eldy/style.css.php | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index df537296646..97551cd250e 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -551,6 +551,12 @@ td.showDragHandle { #id-right { /* This must stay id-right ant not be replaced with echo $right */ width: 100%; } +#id-left { + background-color: #fff; + border-right: 1px #888 solid; +/* height: calc(100% - 50px);*/ +} + div.fiche { margin-: global->MAIN_MENU_USE_JQUERY_LAYOUT))?($dol_hide_leftmenu?'4':'20'):'24')); ?>px; @@ -3674,7 +3680,6 @@ border-top-right-radius: 6px; .public_border { border: 1px solid #888; } -.public_liste_titre { @@ -3686,6 +3691,17 @@ border-top-right-radius: 6px; } @media only screen and (max-width: 767px) { + .mainmenuaspan { + display: none; + } + li.tmenu, li.tmenusel { + min-width: 34px; + } + div.mainmenu { + min-width: auto; + background-position-y: 8px; + height: 34px; + } .imgopensurveywizard { width:95%; height: auto; } } From c0ef8baa9dc51ea9abe9e6ed9efdeff3a9c9785b Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 21 Sep 2015 15:38:17 +0200 Subject: [PATCH 13/30] A better error message --- htdocs/api/class/api_access.class.php | 7 +++++-- htdocs/public/api/index.php | 5 ++++- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/htdocs/api/class/api_access.class.php b/htdocs/api/class/api_access.class.php index 027c9dcf5f4..3a130fe35d2 100644 --- a/htdocs/api/class/api_access.class.php +++ b/htdocs/api/class/api_access.class.php @@ -60,7 +60,8 @@ class DolibarrApiAccess implements iAuthenticate $userClass = Defaults::$userIdentifierClass; - if (isset($_GET['api_key'])) { + if (isset($_GET['api_key'])) + { $sql = "SELECT u.login, u.datec, u.api_key, "; $sql.= " u.tms as date_modification, u.entity"; $sql.= " FROM ".MAIN_DB_PREFIX."user as u"; @@ -100,7 +101,9 @@ class DolibarrApiAccess implements iAuthenticate } else { - return false; + throw new RestException(401, "Failed to login to API. No parameter 'api_key' provided"); + //dol_syslog("Failed to login to API. No parameter key provided", LOG_DEBUG); + //return false; } $userClass::setCacheIdentifier(static::$role); diff --git a/htdocs/public/api/index.php b/htdocs/public/api/index.php index ae8e977bf74..ac9a8f9b2a3 100644 --- a/htdocs/public/api/index.php +++ b/htdocs/public/api/index.php @@ -110,8 +110,11 @@ foreach ($modulesdir as $dir) { $classname=$reg[1]; $classname = str_replace('Api_','',ucwords($reg[1])).'Api'; + $classname = ucfirst($classname); require_once $dir_part.$file_searched; - if(class_exists($classname)) { + if (class_exists($classname)) + { + dol_syslog("Found API classname=".$classname); $api->r->addAPIClass($classname,''); } } From fd90ac517f751b80a52f5fbea687fa16c431a162 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 21 Sep 2015 15:43:37 +0200 Subject: [PATCH 14/30] Add ignore file --- htdocs/public/api/.gitignore | 1 + 1 file changed, 1 insertion(+) create mode 100644 htdocs/public/api/.gitignore diff --git a/htdocs/public/api/.gitignore b/htdocs/public/api/.gitignore new file mode 100644 index 00000000000..0a2101fab9b --- /dev/null +++ b/htdocs/public/api/.gitignore @@ -0,0 +1 @@ +/cache/ From 58a734cb172310148cf11204d8cf8e1289d95aba Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Mon, 21 Sep 2015 17:28:11 +0200 Subject: [PATCH 15/30] Firstname only on login --- htdocs/core/class/commonobject.class.php | 2 +- htdocs/core/lib/functions.lib.php | 6 +++++- htdocs/main.inc.php | 6 +++--- htdocs/theme/md_exp/img/title_hrm.png | Bin 0 -> 1028 bytes htdocs/theme/md_exp/style.css.php | 1 + htdocs/user/class/user.class.php | 5 +++-- 6 files changed, 13 insertions(+), 7 deletions(-) create mode 100644 htdocs/theme/md_exp/img/title_hrm.png diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index 135635ed94d..383723eefd3 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -389,7 +389,7 @@ abstract class CommonObject * * @param Translate $langs Language object for translation of civility * @param int $option 0=No option, 1=Add civility - * @param int $nameorder -1=Auto, 0=Lastname+Firstname, 1=Firstname+Lastname + * @param int $nameorder -1=Auto, 0=Lastname+Firstname, 1=Firstname+Lastname, 2=Firstname * @param int $maxlen Maximum length * @return string String with full name */ diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php index 8649528d883..1e256effa5f 100644 --- a/htdocs/core/lib/functions.lib.php +++ b/htdocs/core/lib/functions.lib.php @@ -4297,12 +4297,16 @@ function dolGetFirstLastname($firstname,$lastname,$nameorder=-1) $ret=''; // If order not defined, we use the setup if ($nameorder < 0) $nameorder=(empty($conf->global->MAIN_FIRSTNAME_NAME_POSITION)); - if ($nameorder) + if ($nameorder && $nameorder != '2') { $ret.=$firstname; if ($firstname && $lastname) $ret.=' '; $ret.=$lastname; } + else if ($nameorder == 2) + { + $ret.=$firstname; + } else { $ret.=$lastname; diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index 7c682756edd..f1f15fc0f06 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -1390,8 +1390,8 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a ' . "\n"; // Raven.js for client-side Sentry logging support - if (array_key_exists('mod_syslog_sentry', $conf->loghandlers) && ! empty($conf->global->SYSLOG_SENTRY_DSN)) { - + if (array_key_exists('mod_syslog_sentry', $conf->loghandlers) && ! empty($conf->global->SYSLOG_SENTRY_DSN)) + { // Filter out secret key $dsn = parse_url($conf->global->SYSLOG_SENTRY_DSN); $public_dsn = $dsn['scheme'] . '://' . $dsn['user'] .'@' . $dsn['host'] . $dsn['path']; @@ -1465,7 +1465,7 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a // Login name with tooltip $toprightmenu.='
'; $toprightmenu.='
'; diff --git a/htdocs/theme/md_exp/img/title_hrm.png b/htdocs/theme/md_exp/img/title_hrm.png new file mode 100644 index 0000000000000000000000000000000000000000..de788526bc1e458293e2c957066e54695c1d44f3 GIT binary patch literal 1028 zcmV+f1pE7mP)Px#24YJ`L;(K){{a7>y{D4^000SaNLh0L01FcU01FcV0GgZ_00007bV*G`2j2!1 z7C8iN#ivsM00V?cL_t(o!|j+$PZLoXhM$>&(gFg4fEP4)A)+Lj8ob1~FuHK*MiX}? z#$Vun@IUw;bYQa}wY=k&9o^LnM2Xq6wfV94`4QK%7ff3;2Rsr7#+yE{Cdw~qlBu(iX4&VX> z;3x0{cmzBIW;X+T7jPc90-OPcL?n**z+2!c@C10QUD*&x1GfdhU#GqY?f@5nmW=>^ zTq|Y+DM{_$?C}y%w8mZo*MRMDL8Ph#p8`68exThlLq}ko3g+or<2}GdzyqGe0ntz; z_#AK#xDV_E_K3uFAS-8W)cg*x3ao{gg=4I|qXlV;3!+-^YrwQLm?xtUco^sqnKs}o z@CKLwE{klSjn=Mw0P;zL4@>WWOSAkPy z#&;;W1=1dOVmD#nO>#i5%sVCd1VHoutbCH-9hptu02e09a@Y=K;KD}Rd^rL^Traos zbJa{92YlLi&rU!^IjbM>-)7^TnoAt;gTO(N$O}wSWAnflU_8Pk_scB)Y!>)o;1)0- z+bzif8-Xd{0dO~B?xQNcW|IIP$6;RppB0nWwCb*|-DSd{qj9f{StY*muYfV&L`Yfd zsLn}gN7_Vi(J(JRsb~CcSgqNrqLU z^oJxE$1pEM$df-6L@p1^$eg~Zhs^=Mjj&sD@JD3pL%;#6%kd-bqx`0%n7^d!f^=SF zCXEuiYVavJ=zx+_pPC3K0;F$^MLiQjwkZFZ)v3aab|VM;s#K)ety+tYFHQo-B0fk6 zD8ItHmB!59ipneFBCrw^ciC*#8yy|>!s2`@a9U9!9TMLBm_XL^ZgAf#MLRJqU&(2Q z{sEs=L@8RpYYnj6Z__fPjFR1|d?F{)@}e^An4&|_TiT~xDP5B!<0-sO8PRObP(RA% zUA1Hxqw9B#vEbR&c!NPQcupB4UE_bYZ`kKLK`F7Ma5|afai41(ZP?dT1Q9}j7Yz;C y#T7*vFDdYG=Z!je3UkuL3b?w|r7m?@pZo=NH7Uu*yF-lt0000getFullName($langs,'',-1,$maxlen) . $linkend . $companylink; + $result.= $link . $this->getFullName($langs,'',($mode == 'firstname' ? 2 : -1),$maxlen) . $linkend . $companylink; return $result; } From 23f6464999fe66753a6e75d2b28701a325490916 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 22 Sep 2015 01:25:06 +0200 Subject: [PATCH 16/30] Work on CSS --- htdocs/main.inc.php | 2 +- htdocs/theme/eldy/style.css.php | 14 +- htdocs/theme/md_exp/img/info_black.png | Bin 0 -> 312 bytes htdocs/theme/md_exp/style.css.php | 385 +++++++++++++++++++------ htdocs/user/class/user.class.php | 5 +- 5 files changed, 315 insertions(+), 91 deletions(-) create mode 100644 htdocs/theme/md_exp/img/info_black.png diff --git a/htdocs/main.inc.php b/htdocs/main.inc.php index f1f15fc0f06..003ed350243 100644 --- a/htdocs/main.inc.php +++ b/htdocs/main.inc.php @@ -1465,7 +1465,7 @@ function top_menu($head, $title='', $target='', $disablejs=0, $disablehead=0, $a // Login name with tooltip $toprightmenu.='
'; $toprightmenu.=''; diff --git a/htdocs/theme/eldy/style.css.php b/htdocs/theme/eldy/style.css.php index 97551cd250e..1ddfc921438 100644 --- a/htdocs/theme/eldy/style.css.php +++ b/htdocs/theme/eldy/style.css.php @@ -107,7 +107,7 @@ $colorbacklinepair2=(250+round($isred/3)).','.(250+round($isgreen/3)).','.(250+r $colorbacklinepairhover=(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9)); // line pair $colorbackbody='243,243,243'; $colortext='40,40,40'; -$fontsize='12'; +$fontsize='13'; $fontsizesmaller='11'; $usegradient=1; @@ -487,6 +487,11 @@ div.confirmmessage { z-index: 999999; } */ +.googlerefreshcal { + padding-top: 4px; + padding-bottom: 4px; +} + /* ============================================================================== */ /* Styles to hide objects */ @@ -1042,9 +1047,10 @@ div.login_block_other { padding-top: 3px; text-align: right; } height: 16px; } .alogin, .alogin:hover { - color: #888 !important; + color: # !important; font-weight: normal !important; font-size: px !important; + padding-top: 2px; } .alogin:hover { text-decoration:underline !important; @@ -3695,12 +3701,10 @@ border-top-right-radius: 6px; display: none; } li.tmenu, li.tmenusel { - min-width: 34px; + min-width: 32px; } div.mainmenu { min-width: auto; - background-position-y: 8px; - height: 34px; } .imgopensurveywizard { width:95%; height: auto; } } diff --git a/htdocs/theme/md_exp/img/info_black.png b/htdocs/theme/md_exp/img/info_black.png new file mode 100644 index 0000000000000000000000000000000000000000..741dabd5e193196549a2a1296760643eb9b11c00 GIT binary patch literal 312 zcmeAS@N?(olHy`uVBq!ia0vp^d?3uh0wlLOK8*rWjKx9jP7LeL$-D$|n3BBRT^Rni z_n+Ah4nJa0`PlBg3pY5H=O_WNwC98#)D5_NBYLVG-2977~7*IqF6 zVonrbeUN|6Axd=X2B9E{3w{DREQ%Y#KS)_NKJT=2(y?i3HCxo$+pBa;ueayu`*&%M zHBV=Mf3{chpJPCNg+X42$cGmhA7dvvCwKY_PmWOfd|`rDVB6B%-DNpHg&0?vJve;g z%-5#tZL7Ta+~zH{F4`=~R~Id6^VG98d;jyCLeb}XrxsninRM;$rSmN-GtFNab^lxQ zzmsvNQGasgdDVM+IlqTpn|@`_1a|X(I#ZT!T=$LHw@3HYiK9o_f&O6dboFyt=akR{ E0M8qG+W-In literal 0 HcmV?d00001 diff --git a/htdocs/theme/md_exp/style.css.php b/htdocs/theme/md_exp/style.css.php index 0dec78afeb9..e20bb51c97b 100644 --- a/htdocs/theme/md_exp/style.css.php +++ b/htdocs/theme/md_exp/style.css.php @@ -1,5 +1,5 @@ +/* Copyright (C) 2004-2015 Laurent Destailleur * Copyright (C) 2006 Rodolphe Quiedeville * Copyright (C) 2007-2012 Regis Houssin * Copyright (C) 2011 Philippe Grand @@ -94,7 +94,6 @@ $isblue=max(0,(2*$colblue-$colred-$colgreen)/2); // 0 - 255 $colorbackhmenu1=($colred-3).','.($colgreen-3).','.($colblue-3); // topmenu $colorbackhmenu2=($colred+5).','.($colgreen+5).','.($colblue+5); $colorbackvmenu1=($colred+15).','.($colgreen+16).','.($colblue+17); // vmenu -$colorbackvmenu1b=($colred+5).','.($colgreen+6).','.($colblue+7); // vmenu (not menu) $colorbackvmenu2=($colred-15).','.($colgreen-15).','.($colblue-15); $colorbacktitle1=($colred-5).','.($colgreen-5).','.($colblue-5); // title of array $colorbacktitle2=($colred-15).','.($colgreen-15).','.($colblue-15); @@ -107,26 +106,30 @@ $colorbacklineimpairhover=(230+round(($isred+$isgreen+$isblue)/9)).','.(230+roun $colorbacklinepair1=(244+round($isred/3)).','.(244+round($isgreen/3)).','.(244+round($isblue/3)); // line pair $colorbacklinepair2=(250+round($isred/3)).','.(250+round($isgreen/3)).','.(250+round($isblue/3)); // line pair $colorbacklinepairhover=(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9)); // line pair -$colorbackbody='#f0f0f0'; +$colorbackbody='243,243,243'; $colortext='40,40,40'; $fontsize='13'; $fontsizesmaller='11'; +$usegradient=1; // Eldy colors if (empty($conf->global->THEME_ELDY_ENABLE_PERSONALIZED)) { - // 90A4AE, 607D8B, 455A64, 37474F + // Case of option always editable + if (! isset($conf->global->THEME_ELDY_TOPMENU_BACK1)) $conf->global->THEME_ELDY_TOPMENU_BACK1='140,150,180'; // topmenu (140,160,185) + if (! isset($conf->global->THEME_ELDY_BACKTITLE1)) $conf->global->THEME_ELDY_BACKTITLE1='140,150,180'; // title of arrays TO MATCH ELDY (140,160,185) + //if (! isset($conf->global->THEME_ELDY_BACKTITLE1)) $conf->global->THEME_ELDY_BACKTITLE1='230,230,230'; // title of arrays TO MATCH BOOTSTRAP + + // 90A4AE, 607D8B, 455A64, 37474F $conf->global->THEME_ELDY_TOPMENU_BACK1=join(',',colorStringToArray('#37474F')); // topmenu #607D8B $conf->global->THEME_ELDY_TOPMENU_BACK2='236,236,236'; $conf->global->THEME_ELDY_VERMENU_BACK1='255,255,255'; // vmenu - $conf->global->THEME_ELDY_VERMENU_BACK1b='230,232,232'; // vmenu (not menu) $conf->global->THEME_ELDY_VERMENU_BACK2='240,240,240'; - $conf->global->THEME_ELDY_BACKTITLE1=join(',',colorStringToArray('#607D8B')); // title of arrays $conf->global->THEME_ELDY_BACKTITLE2='230,230,230'; - $conf->global->THEME_ELDY_BACKTABCARD2='255,255,255'; // card - $conf->global->THEME_ELDY_BACKTABCARD1='234,234,234'; + $conf->global->THEME_ELDY_BACKTABCARD1='255,255,255'; // card + $conf->global->THEME_ELDY_BACKTABCARD2='234,234,234'; $conf->global->THEME_ELDY_BACKTABACTIVE='234,234,234'; - $conf->global->THEME_ELDY_BACKBODY='#f0f0f0;'; + $conf->global->THEME_ELDY_BACKBODY='243,243,243'; $conf->global->THEME_ELDY_LINEPAIR1='242,242,242'; $conf->global->THEME_ELDY_LINEPAIR2='248,248,248'; $conf->global->THEME_ELDY_LINEPAIRHOVER='238,246,252'; @@ -134,12 +137,14 @@ if (empty($conf->global->THEME_ELDY_ENABLE_PERSONALIZED)) $conf->global->THEME_ELDY_LINEIMPAIR2='255,255,255'; $conf->global->THEME_ELDY_LINEIMPAIRHOVER='238,246,252'; $conf->global->THEME_ELDY_TEXT='50,50,130'; + $conf->global->THEME_ELDY_FONT_SIZE1='13'; + $conf->global->THEME_ELDY_FONT_SIZE2='11'; } +// Cas of option availables only if THEME_ELDY_ENABLE_PERSONALIZED is on $colorbackhmenu1 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TOPMENU_BACK1)?$colorbackhmenu1:$conf->global->THEME_ELDY_TOPMENU_BACK1) :(empty($user->conf->THEME_ELDY_TOPMENU_BACK1)?$colorbackhmenu1:$user->conf->THEME_ELDY_TOPMENU_BACK1); $colorbackhmenu2 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TOPMENU_BACK2)?$colorbackhmenu2:$conf->global->THEME_ELDY_TOPMENU_BACK2) :(empty($user->conf->THEME_ELDY_TOPMENU_BACK2)?$colorbackhmenu2:$user->conf->THEME_ELDY_TOPMENU_BACK2); $colorbackvmenu1 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_VERMENU_BACK1)?$colorbackvmenu1:$conf->global->THEME_ELDY_VERMENU_BACK1) :(empty($user->conf->THEME_ELDY_VERMENU_BACK1)?$colorbackvmenu1:$user->conf->THEME_ELDY_VERMENU_BACK1); -$colorbackvmenu1b =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_VERMENU_BACK1b)?$colorbackvmenu1:$conf->global->THEME_ELDY_VERMENU_BACK1b) :(empty($user->conf->THEME_ELDY_VERMENU_BACK1b)?$colorbackvmenu1b:$user->conf->THEME_ELDY_VERMENU_BACK1b); $colorbackvmenu2 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_VERMENU_BACK2)?$colorbackvmenu2:$conf->global->THEME_ELDY_VERMENU_BACK2) :(empty($user->conf->THEME_ELDY_VERMENU_BACK2)?$colorbackvmenu2:$user->conf->THEME_ELDY_VERMENU_BACK2); $colorbacktitle1 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_BACKTITLE1) ?$colorbacktitle1:$conf->global->THEME_ELDY_BACKTITLE1) :(empty($user->conf->THEME_ELDY_BACKTITLE1)?$colorbacktitle1:$user->conf->THEME_ELDY_BACKTITLE1); $colorbacktitle2 =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_BACKTITLE2) ?$colorbacktitle2:$conf->global->THEME_ELDY_BACKTITLE2) :(empty($user->conf->THEME_ELDY_BACKTITLE2)?$colorbacktitle2:$user->conf->THEME_ELDY_BACKTITLE2); @@ -156,19 +161,21 @@ $colorbackbody =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty( $colortext =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_TEXT) ?$colortext:$conf->global->THEME_ELDY_TEXT) :(empty($user->conf->THEME_ELDY_TEXT)?$colortext:$user->conf->THEME_ELDY_TEXT); $fontsize =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_FONT_SIZE1) ?$fontsize:$conf->global->THEME_ELDY_FONT_SIZE1) :(empty($user->conf->THEME_ELDY_FONT_SIZE1)?$fontsize:$user->conf->THEME_ELDY_FONT_SIZE1); $fontsizesmaller =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_FONT_SIZE2) ?$fontsize:$conf->global->THEME_ELDY_FONT_SIZE2) :(empty($user->conf->THEME_ELDY_FONT_SIZE2)?$fontsize:$user->conf->THEME_ELDY_FONT_SIZE2); -// No hover by default, we keep only if we set var THEME_ELDY_USE_HOVER -if ((! empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED) && empty($user->conf->THEME_ELDY_USE_HOVER)) - || (empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED) && empty($conf->global->THEME_ELDY_USE_HOVER))) + +// Hover can be disabled with THEME_ELDY_USE_HOVER=0 +if ((! empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED) && (isset($user->conf->THEME_ELDY_USE_HOVER) && $user->conf->THEME_ELDY_USE_HOVER == '0')) + || (empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED) && (isset($conf->global->THEME_ELDY_USE_HOVER) && $conf->global->THEME_ELDY_USE_HOVER == '0'))) { $colorbacklineimpairhover=''; $colorbacklinepairhover=''; } // Format color value to match expected format (may be 'FFFFFF' or '255,255,255') -$colorbacktabcard1=join(',',colorStringToArray($colorbacktabcard1)); -$colorbacktabcard2=join(',',colorStringToArray($colorbacktabcard2)); - -// Format color value to match expected format (may be 'FFFFFF' or '255,255,255') +$colorbackbody=join(',',colorStringToArray($colorbackbody)); +$colorbackhmenu1=join(',',colorStringToArray($colorbackhmenu1)); +$colorbackhmenu2=join(',',colorStringToArray($colorbackhmenu2)); +$colorbackvmenu1=join(',',colorStringToArray($colorbackvmenu1)); +$colorbackvmenu2=join(',',colorStringToArray($colorbackvmenu2)); $colorbacktabcard1=join(',',colorStringToArray($colorbacktabcard1)); $colorbacktabcard2=join(',',colorStringToArray($colorbacktabcard2)); @@ -194,6 +201,10 @@ else { $colortextbacktab='111'; } print '/*'."\n"; print 'colred='.$colred.' colgreen='.$colgreen.' colblue='.$colblue."\n"; print 'isred='.$isred.' isgreen='.$isgreen.' isblue='.$isblue."\n"; +print 'colorbackbody='.$colorbackbody."\n"; +print 'colorbackvmenu1='.$colorbackvmenu1."\n"; +print 'colorbackhmenu1='.$colorbackhmenu1."\n"; +print 'colorbacktitle1='.$colorbacktitle1."\n"; print 'colorbacklineimpair1='.$colorbacklineimpair1."\n"; print 'colorbacklineimpair2='.$colorbacklineimpair2."\n"; print 'colorbacklineimpairhover='.$colorbacklineimpairhover."\n"; @@ -221,7 +232,7 @@ body { background-color: #FFFFFF; - background: ; + background: rgb(); color: #101010; font-size: px; @@ -266,6 +277,11 @@ input, textarea, select { margin-bottom:1px; margin-top:1px; } +input.removedassigned { + padding: 2px !important; + vertical-align: text-bottom; + margin-bottom: -3px; +} select.flat, form.flat select { @@ -281,6 +297,7 @@ input.liste_titre { input.removedfile { padding: 0px !important; border: 0px !important; + vertical-align: text-bottom; } textarea:disabled { background:#f4f4f4; @@ -389,6 +406,9 @@ th .button { -webkit-border-radius:0px !important; border-radius:0px !important; } +.maxwidthsearch { /* Max width of column with the search picto */ + width: 54px; +} .valignmiddle { vertical-align: middle; @@ -401,6 +421,7 @@ textarea.centpercent { } .center { text-align: center; + margin: 0px auto; } .left { text-align: ; @@ -448,12 +469,38 @@ textarea.centpercent { #formuserfile_link { margin-left: 1px; } - +.listofinvoicetype { + height: 28px; + vertical-align: middle; +} +div.divsearchfield { + float: ; + margin-: 12px; +} +div.confirmmessage { + padding-top: 6px; +} +/* Style to move picto into left of button */ +/* +.buttonactionview { + padding-left: 15px; +} +.pictoactionview { + padding-left: 10px; + margin-right: -24px; + z-index: 999999; +} +*/ +.googlerefreshcal { + padding-top: 4px; + padding-bottom: 4px; +} /* ============================================================================== */ /* Styles to hide objects */ /* ============================================================================== */ +.clearboth { clear:both; } .hideobject { display: none; } .minwidth100 { min-width: 100px; } .minwidth200 { min-width: 200px; } @@ -516,17 +563,17 @@ td.showDragHandle { #id-left { min-height: 100%; position: relative; - width: 183px; + width: 193px; } #id-right { /* This must stay id-right and not be replaced with echo $right */ width: 100%; - padding-left: 184px; + padding-left: 194px; padding-top: 12px; } .side-nav { background: #FFF; - border-right: 1px solid rgba(0,0,0,0.14); + border-right: 1px solid rgba(0,0,0,0.2); bottom: 0; color: #333; display: block; @@ -562,12 +609,12 @@ td.showDragHandle { overflow-y: auto; } .side-nav-vert { - margin-left: 184px; + margin-left: 194px; } div.fiche { - margin-: global->MAIN_MENU_USE_JQUERY_LAYOUT))?($dol_hide_leftmenu?'4':'12'):'24')); ?>px; + margin-: global->MAIN_MENU_USE_JQUERY_LAYOUT))?($dol_hide_leftmenu?'4':'20'):'24')); ?>px; margin-: dol_optimize_smallscreen)?'12':'4')); ?>px; dol_hide_leftmenu) && ! empty($conf->dol_hide_topmenu)) print 'margin-top: 4px;'; ?> } @@ -611,6 +658,19 @@ margin : 0px auto; padding-left: 2px; padding-right: 2px; } +.pictowarning { + padding-left: 3px; +} +.colorthumb { + padding-left: 1px !important; + padding-right: 1px; + padding-top: 1px; + padding-bottom: 1px; +} +div.attacharea { + padding-top: 10px; + padding-bottom: 10px; +} /* ============================================================================== */ @@ -621,15 +681,16 @@ margin : 0px auto; $minwidthtmenu=66; $heightmenu=48; /* height of top menu, part with image */ $heightmenu2=48; /* height of top menu, ârt with login */ +$disableimages = 0; +$maxwidthloginblock = 110; +if (! empty($conf->global->THEME_ELDY_DISABLE_IMAGE) || $dol_optimize_smallscreen) { $disableimages = 1; $maxwidthloginblock = 180; } ?> div#tmenu_tooltip { display:none; - /* padding-: 100px; */ - background: ; - /*box-shadow: 0 0 6px rgba(0, 0, 0, .4) !important;*/ + background: rgb(); background-image: linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(128,128,128,.3) 100%); background-image: -o-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(128,128,128,.3) 100%); background-image: -moz-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(128,128,128,.3) 100%); @@ -639,6 +700,14 @@ div#tmenu_tooltip { } +div#tmenu_tooltip { + + display:none; + + /* padding-: px; */ + +} + div.tmenudiv { display:none; @@ -727,6 +796,7 @@ li.tmenusel, li.tmenu:hover { /* background: url() 50% 0 repeat-x !important; Nicer but problem when menu wrap on 2 lines */ } .tmenuend .tmenuleft { width: 0px; } +/* .tmenuend { display: none; } */ div.tmenuleft { float: ; @@ -745,6 +815,9 @@ div.tmenucenter height: px; width: 100%; } +div.menu_titre { + padding-bottom: 2px; +} .mainmenuaspan { padding-right: 4px; @@ -885,6 +958,9 @@ foreach($mainmenuusedarray as $val) .tmenuimage { padding:0 0 0 0 !important; margin:0 0px 0 0 !important; + + display: none; + } @@ -913,8 +989,7 @@ form#login { text-shadow: 1px 1px 1px #FFF; } .login_table { - margin-left: 10px; - margin-right: 10px; + margin: 0px auto; /* Center */ padding-left:6px; padding-right:6px; padding-top:16px; @@ -974,10 +1049,10 @@ table.login_table_securitycode tr td { } div.login_block { + border-right: 1px solid rgba(0,0,0,0.3); padding-top: 8px; position: absolute; - : 5px; - left: 0; + : 0; top: 0px; position: fixed; font-weight: bold; @@ -985,7 +1060,7 @@ div.login_block { text-align: center; vertical-align: middle; background: #FFF; - width: 183px; + width: 193px; height: 42px; display: none; @@ -1029,6 +1104,9 @@ img.login, img.printer, img.entity { color: white; font-weight: bold; } +img.loginphoto { + border-radius: 2px; +} .span-icon-user { background: url() no-repeat scroll 7px 7px; @@ -1092,7 +1170,7 @@ div.blockvmenupair, div.blockvmenuimpair, div.blockvmenubookmarks margin: 1px 0px 8px 0px; padding-bottom: 10px; - border-bottom: 1px solid #f4f4f4; + border-bottom: 1px solid #e0e0e0; } div.blockvmenusearch @@ -1405,8 +1483,6 @@ img.toolbarbutton { /* Onglets */ /* ============================================================================== */ div.tabs { -/* margin: 0px 0px 2px 6px; - padding: 0px 6px 3px 0px; */ text-align: ; margin-left: 6px !important; margin-right: 6px !important; @@ -1431,7 +1507,7 @@ div.tabBar { border-top: 1px solid #CCC; width: auto; - background: rgb(); + background: rgb(); -moz-box-shadow: 3px 3px 4px #f4f4f4; @@ -1486,6 +1562,12 @@ a.tab:link, a.tab:visited, a.tab:hover, a.tab#active { } .tabactive, a.tab#active { + color: # !important; + background: rgb() !important; + -moz-box-shadow: 0 -1px 4px rgba(0,0,0,.1); + -webkit-box-shadow: 0 -1px 4px rgba(0,0,0,.1); + box-shadow: 0 -1px 4px rgba(0,0,0,.1); + border-right: 1px solid #CCCCCC; border-left: 1px solid #f4f4f4; border-top: 1px solid #D8D8D8; @@ -1494,12 +1576,6 @@ a.tab:link, a.tab:visited, a.tab:hover, a.tab#active { -webkit-border-radius:3px 3px 0px 0px; border-radius:3px 3px 0px 0px; - -moz-box-shadow: 0 -1px 4px rgba(0,0,0,.1); - -webkit-box-shadow: 0 -1px 4px rgba(0,0,0,.1); - box-shadow: 0 -1px 4px rgba(0,0,0,.1); - - background: rgb() !important; - color: #; } a.tab:hover { @@ -1509,11 +1585,6 @@ a.tab:hover */ text-decoration: underline; } -a.tab:link, a.tab:visited -{ - /* color: #888; */ - /* font-weight: normal !important; */ -} a.tabimage { color: #434956; font-family: ; @@ -1816,7 +1887,7 @@ table.nobordernopadding tr { } table.nobordernopadding tr td { border: 0px; - padding: 0 3px 0 0 !important; + padding: 0 3px 0 0; } table.border tr td table.nobordernopadding tr td { padding-top: 0px; @@ -1946,7 +2017,7 @@ div.pagination .disabled a:focus { background-color: #fff; border-color: #ddd; } -div.pagination li .active { +div.pagination li.pagination .active { text-decoration: underline; } div.pagination li.paginationafterarrows { @@ -1980,35 +2051,49 @@ div.pagination li.paginationafterarrows { } */ -.impair:hover, td.nohover { - 0) { ?> - background: rgb(); +/* Set the color for hover lines */ +.odd:hover, .impair:hover, .even:hover, .pair:hover, .even:hover, .pair:hover, table.dataTable tr.even:hover, table.dataTable tr.odd:hover, .box_pair:hover, .box_impair:hover +{ + + background: rgb() !important; background: rgba(0, 0, 0, 0.05) !important; - + } -.odd, .impair, .nohover .odd:hover, .nohover .impair:hover, tr.odd td.nohover, tr.impair td.nohover { +.odd, .impair, .nohover .odd:hover, .nohover .impair:hover, tr.odd td.nohover, tr.impair td.nohover, tr.box_pair td.nohover, tr.box_impair td.nohover +{ font-family: ; border: 0px; margin-bottom: 1px; color: #202020; min-height: 18px; /* seems to not be used */ - background: #ffffff; + background: #; +} +#GanttChartDIV { + background: #; } .even, .pair, .nohover .even:hover, .nohover .pair:hover, tr.even td.nohover, tr.pair td.nohover { font-family: ; - border: 0px; margin-bottom: 1px; color: #202020; - background-color: #f9f9f9; + background-color: #; } table.dataTable tr.odd { - background-color: #f9f9f9 !important; + background-color: # !important; } + +/* For no hover style */ +table.nohover tr.impair, table.nohover tr.pair, table.nohover tr.impair td, table.nohover tr.pair td, tr.nohover td { + background-color: # !important; +} +tr.nohoverpair td { + background-color: # !important; +} + table.dataTable td { padding: 5px 2px 5px 3px !important; } @@ -2034,18 +2119,23 @@ tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, tabl } div.liste_titre, tr.liste_titre, tr.liste_titre_sel, form.liste_titre, form.liste_titre_sel, table.dataTable thead tr { - background: rgb(); - background-repeat: repeat-x; + /* TO MATCH BOOTSTRAP */ + background: #ddd; + color: #000 !important; + /* TO MATCH ELDY */ /* - background-image: -o-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); + background: rgb(); + + background-image: -o-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); background-image: -moz-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); background-image: -webkit-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); background-image: -ms-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); background-image: linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); - */ + font-weight: bold; - + */ + color: #; font-family: ; border-bottom: 1px solid #FDFFFF; @@ -2059,7 +2149,6 @@ tr.liste_titre th, th.liste_titre, tr.liste_titre td, td.liste_titre, form.liste { font-family: ; font-weight: bold; - text-shadow: 1px 0px 1px #; vertical-align: middle; } tr.liste_titre th a, th.liste_titre a, tr.liste_titre td a, td.liste_titre a, form.liste_titre div a, div.liste_titre a { @@ -2098,7 +2187,6 @@ input.liste_titre { .tableforservicepart1 .impair, .tableforservicepart1 .pair, .tableforservicepart2 .impair, .tableforservicepart2 .pair { - //background: none; background: #FFF; } .tableforservicepart1 tbody tr td, .tableforservicepart2 tbody tr td { @@ -2139,6 +2227,9 @@ div.tabBar .noborder { text-align: center; border-radius: 2px; } +.boxstats:hover { + background-color: #; +} .boxtable { -moz-box-shadow: 3px 3px 4px #f4f4f4; @@ -2156,10 +2247,25 @@ div.tabBar .noborder { tr.box_titre { height: 26px !important; - background: rgb(); + + /* TO MATCH BOOTSTRAP */ + background: #ddd; + color: #000 !important; + + /* TO MATCH ELDY */ + /* + background: rgb(); + + background-image: -o-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); + background-image: -moz-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); + background-image: -webkit-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); + background-image: -ms-linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); + background-image: linear-gradient(bottom, rgba(0,0,0,0.3) 0%, rgba(250,250,250,0.3) 100%); + + */ + background-repeat: repeat-x; color: #; - text-shadow: 1px 0px 1px #; font-family: , sans-serif; font-weight: bold; border-bottom: 1px solid #FDFFFF; @@ -2180,12 +2286,6 @@ tr.box_impair { } tr.box_pair { - background: -o-linear-gradient(bottom, rgb() 85%, rgb() 100%); - background: -moz-linear-gradient(bottom, rgb() 85%, rgb() 100%); - background: -webkit-linear-gradient(bottom, rgb() 85%, rgb() 100%); - background: -ms-linear-gradient(bottom, rgb() 85%, rgb() 100%); - background: linear-gradient(bottom, rgb() 85%, rgb() 100%); - font-family: ; background-color: #f9f9f9; @@ -2289,6 +2389,8 @@ a.impayee:hover { font-weight: bold; color: #550000; } .legendColorBox, .legendLabel { border: none !important; } div.dolgraph div.legend, div.dolgraph div.legend div { background-color: rgba(255,255,255,0) !important; } div.dolgraph div.legend table tbody tr { height: auto; } +td.legendColorBox { padding: 2px 2px 2px 0 !important; } +td.legendLabel { padding: 2px 2px 2px 0 !important; } .photo { border: 0px; @@ -2298,16 +2400,18 @@ div.dolgraph div.legend table tbody tr { height: auto; } margin-top: 2px; } .photointooltip { - -webkit-box-shadow: 0px 0px 5px #777; - -moz-box-shadow: 0px 0px 5px #777; - box-shadow: 0px 0px 6px #777; margin-top: 8px; float: left; + /*text-align: center; */ +} +.photodelete { + margin-top: 6px !important; } .logo_setup { content:url(); + display: inline-block; } div.titre { @@ -2552,6 +2656,8 @@ table.cal_month { border-spacing: 0px; } .cal_today_peruser_peruserleft { background: #FDFDF0; border-left: solid 3px #6C7C7B; border-right: solid 1px #E0E0E0; border-bottom: solid 1px #E0E0E0; padding-: 2px; padding-: 1px; padding-top: 0px; padding-bottom: 0px; } .cal_past { } .cal_peruser { padding: 0px; } +.cal_impair { background: #F8F8F8; } +.cal_today_peruser_impair { background: #F8F8F0; } .peruser_busy { background: #CC8888; } .peruser_notbusy { background: #EEDDDD; opacity: 0.5; } table.cal_event { border: none; border-collapse: collapse; margin-bottom: 1px; -webkit-border-radius: 3px; border-radius: 3px; @@ -3041,10 +3147,21 @@ div.dolEventError h1, div.dolEventError h2 { /* Datatable */ /* ============================================================================== */ -.sorting_asc { background: url('') no-repeat center right; } -.sorting_desc { background: url('') no-repeat center right; } -.sorting_asc_disabled { background: url('') no-repeat center right; } -.sorting_desc_disabled { background: url('') no-repeat center right; } +table.dataTable tr.odd td.sorting_1, table.dataTable tr.even td.sorting_1 { + background: none !important; +} +.sorting_asc { background: url('') no-repeat center right !important; } +.sorting_desc { background: url('') no-repeat center right !important; } +.sorting_asc_disabled { background: url('') no-repeat center right !important; } +.sorting_desc_disabled { background: url('') no-repeat center right !important; } +.dataTables_paginate { + margin-top: 8px; +} +.paginate_button_disabled { + opacity: 1 !important; + color: #888 !important; + cursor: default !important; +} .paginate_disabled_previous:hover, .paginate_enabled_previous:hover, .paginate_disabled_next:hover, .paginate_enabled_next:hover { font-weight: normal; @@ -3053,9 +3170,34 @@ div.dolEventError h1, div.dolEventError h2 { { text-decoration: underline !important; } +.paginate_active +{ + text-decoration: underline !important; +} .paginate_button { font-weight: normal !important; + text-decoration: none !important; +} +.paging_full_numbers { + height: inherit !important; +} +.paging_full_numbers a.paginate_active:hover, .paging_full_numbers a.paginate_button:hover { + background-color: #DDD !important; +} +.paging_full_numbers, .paging_full_numbers a.paginate_active, .paging_full_numbers a.paginate_button { + background-color: #FFF !important; + border-radius: inherit !important; +} +.paging_full_numbers a.paginate_button_disabled:hover { + background-color: #FFF !important; +} +.paginate_button, .paginate_active { + border: 1px solid #ddd !important; + padding: 6px 12px !important; + margin-left: -1px !important; + line-height: 1.42857143 !important; + margin: 0 0 !important; } /* For jquery plugin combobox */ @@ -3097,6 +3239,8 @@ a span.select2-chosen } .select2-container .select2-choice { background-image: none; + height: 24px; + line-height: 24px; } .select2-choices .select2-search-choice { border: 1px solid #aaa !important; @@ -3112,8 +3256,48 @@ a span.select2-chosen cursor: default; } .select2-container-multi .select2-choices .select2-search-choice { - margin-top: 2px; - margin-bottom: 2px; + margin-bottom: 3px; +} +/* To emulate select 2 style */ +.select2-container-multi-dolibarr .select2-choices-dolibarr .select2-search-choice-dolibarr { + padding: 2px 5px 1px 5px; + margin: 0 0 2px 3px; + position: relative; + line-height: 13px; + color: #333; + cursor: default; + border: 1px solid #aaaaaa; + border-radius: 3px; + -webkit-box-shadow: 0 0 2px #fff inset, 0 1px 0 rgba(0, 0, 0, 0.05); + box-shadow: 0 0 2px #fff inset, 0 1px 0 rgba(0, 0, 0, 0.05); + background-clip: padding-box; + -webkit-touch-callout: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + background-color: #e4e4e4; + filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#eeeeee', endColorstr='#f4f4f4', GradientType=0); + background-image: -webkit-gradient(linear, 0% 0%, 0% 100%, color-stop(20%, #f4f4f4), color-stop(50%, #f0f0f0), color-stop(52%, #e8e8e8), color-stop(100%, #eee)); + background-image: -webkit-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eee 100%); + background-image: -moz-linear-gradient(top, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eee 100%); + background-image: linear-gradient(to bottom, #f4f4f4 20%, #f0f0f0 50%, #e8e8e8 52%, #eee 100%); +} +.select2-container-multi-dolibarr .select2-choices-dolibarr .select2-search-choice-dolibarr a { + font-weight: normal; +} +.select2-container-multi-dolibarr .select2-choices-dolibarr li { + float: left; + list-style: none; +} +.select2-container-multi-dolibarr .select2-choices-dolibarr { + height: auto !important; + height: 1%; + margin: 0; + padding: 0 5px 0 0; + position: relative; + cursor: text; + overflow: hidden; } @@ -3254,7 +3438,9 @@ ul.ulmenu { color: # !important; text-shadow: 1px 0px 1px #; } - +.ui-btn-icon-right { + border-right: 1px solid #ccc !important; +} .ui-body-c { border: 1px solid #ccc; text-shadow: none; @@ -3299,5 +3485,38 @@ border-top-right-radius: 6px; padding-left: 54px; } + + +/* The theme for public pages */ +.public_body { + margin: 20px; +} +.public_border { + border: 1px solid #888; +} + + + +/* CSS style used for small screen */ + +.imgopensurveywizard +{ + padding: 0 4px 0 4px; +} +@media only screen and (max-width: 767px) +{ + .mainmenuaspan { + display: none; + } + li.tmenu, li.tmenusel { + min-width: 32px; + } + div.mainmenu { + min-width: auto; + } + .imgopensurveywizard { width:95%; height: auto; } +} + + close(); diff --git a/htdocs/user/class/user.class.php b/htdocs/user/class/user.class.php index d291ee58010..34c3084e12d 100644 --- a/htdocs/user/class/user.class.php +++ b/htdocs/user/class/user.class.php @@ -1837,9 +1837,10 @@ class User extends CommonObject * @param int $maxlen Max length of visible user name * @param int $hidethirdpartylogo Hide logo of thirdparty if user is external user * @param string $mode 'firstname'=Show only firstname + * @param string $morecss Add more css on link * @return string String with URL */ - function getNomUrl($withpicto=0, $option='', $infologin=0, $notooltip=0, $maxlen=24, $hidethirdpartylogo=0, $mode='') + function getNomUrl($withpicto=0, $option='', $infologin=0, $notooltip=0, $maxlen=24, $hidethirdpartylogo=0, $mode='',$morecss='') { global $langs, $conf, $db; global $dolibarr_main_authentication, $dolibarr_main_demo; @@ -1897,7 +1898,7 @@ class User extends CommonObject $link = ' Date: Tue, 22 Sep 2015 11:24:31 +0200 Subject: [PATCH 17/30] Enhance CSS capabilities --- htdocs/admin/ihm.php | 2 +- htdocs/core/menus/standard/auguria.lib.php | 2 +- htdocs/core/menus/standard/eldy.lib.php | 15 +++--- htdocs/langs/en_US/admin.lang | 3 +- htdocs/main.inc.php | 4 +- htdocs/theme/eldy/style.css.php | 58 ++++++++++++++++------ htdocs/theme/md_exp/style.css.php | 13 +++-- 7 files changed, 67 insertions(+), 30 deletions(-) diff --git a/htdocs/admin/ihm.php b/htdocs/admin/ihm.php index 20e05482685..f3260070fd7 100644 --- a/htdocs/admin/ihm.php +++ b/htdocs/admin/ihm.php @@ -343,7 +343,7 @@ else // Show print ($conf->global->MAIN_LANG_DEFAULT=='auto'?$langs->trans("AutoDetectLang"):$langs->trans("Language_".$conf->global->MAIN_LANG_DEFAULT)); print ''; print ''; - if ($user->admin && $conf->global->MAIN_LANG_DEFAULT!='auto') print info_admin($langs->trans("SubmitTranslation",$conf->global->MAIN_LANG_DEFAULT),1); + if ($user->admin && $conf->global->MAIN_LANG_DEFAULT!='auto') print info_admin($langs->trans("SubmitTranslation".($conf->global->MAIN_LANG_DEFAULT=='en_US'?'ENUS':''),$conf->global->MAIN_LANG_DEFAULT),1); print ''; print ""; diff --git a/htdocs/core/menus/standard/auguria.lib.php b/htdocs/core/menus/standard/auguria.lib.php index 9624bf66341..1cafd091521 100644 --- a/htdocs/core/menus/standard/auguria.lib.php +++ b/htdocs/core/menus/standard/auguria.lib.php @@ -235,7 +235,7 @@ function print_left_auguria_menu($db,$menu_array_before,$menu_array_after,&$tabM } $title=$langs->trans("GoIntoSetupToChangeLogo"); print "\n".''."\n"; - print '
'."\n"; + print '