diff --git a/htdocs/comm/action/class/actioncomm.class.php b/htdocs/comm/action/class/actioncomm.class.php index 04b631b7ee1..7fd294b89b2 100644 --- a/htdocs/comm/action/class/actioncomm.class.php +++ b/htdocs/comm/action/class/actioncomm.class.php @@ -382,6 +382,7 @@ class ActionComm extends CommonObject */ const EVENT_FINISHED = 100; + /** * Constructor * @@ -752,7 +753,7 @@ class ActionComm extends CommonObject $sql .= " a.durationp,"; // deprecated $sql .= " a.datec,"; $sql .= " a.tms as datem,"; - $sql .= " a.code, a.label, a.note,"; + $sql .= " a.code, a.label, a.note as note_private,"; $sql .= " a.fk_soc,"; $sql .= " a.fk_project,"; $sql .= " a.fk_user_author, a.fk_user_mod,"; @@ -811,8 +812,8 @@ class ActionComm extends CommonObject $this->datec = $this->db->jdate($obj->datec); $this->datem = $this->db->jdate($obj->datem); - $this->note = $obj->note; // deprecated - $this->note_private = $obj->note; + $this->note = $obj->note_private; // deprecated + $this->note_private = $obj->note_private; $this->percentage = $obj->percentage; $this->authorid = $obj->fk_user_author; @@ -1822,7 +1823,7 @@ class ActionComm extends CommonObject $sql .= " a.datep2,"; // End $sql .= " a.durationp,"; // deprecated $sql .= " a.datec, a.tms as datem,"; - $sql .= " a.label, a.code, a.note, a.fk_action as type_id,"; + $sql .= " a.label, a.code, a.note as note_private, a.fk_action as type_id,"; $sql .= " a.fk_soc,"; $sql .= " a.fk_user_author, a.fk_user_mod,"; $sql .= " a.fk_user_action,"; @@ -1950,7 +1951,7 @@ class ActionComm extends CommonObject $duration = ($datestart && $dateend) ? ($dateend - $datestart) : 0; $event['summary'] = $obj->label.($obj->socname ? " (".$obj->socname.")" : ""); - $event['desc'] = $obj->note; + $event['desc'] = $obj->note_private; $event['startdate'] = $datestart; $event['enddate'] = $dateend; // Not required with type 'journal' $event['duration'] = $duration; // Not required with type 'journal' diff --git a/htdocs/comm/action/list.php b/htdocs/comm/action/list.php index 8bf35df622d..e95cc3366c5 100644 --- a/htdocs/comm/action/list.php +++ b/htdocs/comm/action/list.php @@ -391,7 +391,7 @@ $reshook = $hookmanager->executeHooks('printFieldListSelect', $parameters); // N $sql .= $hookmanager->resPrint; $sql .= " FROM ".MAIN_DB_PREFIX."actioncomm as a"; -$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."actioncomm_extrafields as ef ON (a.id = ef.fk_object) "; +$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."actioncomm_extrafields as ef ON (a.id = ef.fk_object)"; if (!$user->rights->societe->client->voir && !$socid) { $sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe_commerciaux as sc ON a.fk_soc = sc.fk_soc"; } @@ -578,8 +578,8 @@ if ($resql) { //print dol_get_fiche_end(); // Add link to show birthdays - $link = ''; /* + $link = ''; if (empty($conf->use_javascript_ajax)) { $newparam=$param; // newparam is for birthday links @@ -841,7 +841,7 @@ if ($resql) { // Ref if (!empty($arrayfields['a.id']['checked'])) { - print '
| ';
- $out .= ' ';
+ $out .= ' ';
}
if (!empty($head['text'])) {
$s = dol_trunc($head['text'], isset($head['limit']) ? $head['limit'] : $MAXLENGTHBOX);
diff --git a/htdocs/core/lib/functions.lib.php b/htdocs/core/lib/functions.lib.php
index 380a50a22fe..915282ed0d8 100644
--- a/htdocs/core/lib/functions.lib.php
+++ b/htdocs/core/lib/functions.lib.php
@@ -5672,16 +5672,16 @@ function getLocalTaxesFromRate($vatrate, $local, $buyer, $seller, $firstparamisi
}
/**
- * Return vat rate of a product in a particular selling country or default country vat if product is unknown
- * Function called by get_default_tva
+ * Return vat rate of a product in a particular country, or default country vat if product is unknown.
+ * Function called by get_default_tva().
*
* @param int $idprod Id of product or 0 if not a predefined product
- * @param Societe $thirdparty_seller Thirdparty with a ->country_code defined (FR, US, IT, ...)
+ * @param Societe $thirdpartytouse Thirdparty with a ->country_code defined (FR, US, IT, ...)
* @param int $idprodfournprice Id product_fournisseur_price (for "supplier" proposal/order/invoice)
* @return float|string Vat rate to use with format 5.0 or '5.0 (XXX)'
* @see get_product_localtax_for_country()
*/
-function get_product_vat_for_country($idprod, $thirdparty_seller, $idprodfournprice = 0)
+function get_product_vat_for_country($idprod, $thirdpartytouse, $idprodfournprice = 0)
{
global $db, $conf, $mysoc;
@@ -5695,7 +5695,7 @@ function get_product_vat_for_country($idprod, $thirdparty_seller, $idprodfournpr
$product = new Product($db);
$result = $product->fetch($idprod);
- if ($mysoc->country_code == $thirdparty_seller->country_code) { // If selling country is ours
+ if ($mysoc->country_code == $thirdpartytouse->country_code) { // If country to consider is ours
if ($idprodfournprice > 0) { // We want vat for product for a "supplier" object
$product->get_buyprice($idprodfournprice, 0, 0, 0);
$ret = $product->vatrate_supplier;
@@ -5710,8 +5710,8 @@ function get_product_vat_for_country($idprod, $thirdparty_seller, $idprodfournpr
}
$found = 1;
} else {
- // TODO Read default product vat according to countrycode and product. Vat for couple countrycode/product is a feature not implemeted yet.
- // May be usefull/required if hidden option SERVICE_ARE_ECOMMERCE_200238EC is on
+ // TODO Read default product vat according to product and another countrycode.
+ // Vat for couple anothercountrycode/product is data that is not managed and store yet, so we will fallback on next rule.
}
}
@@ -5720,7 +5720,7 @@ function get_product_vat_for_country($idprod, $thirdparty_seller, $idprodfournpr
// If vat of product for the country not found or not defined, we return the first higher vat of country.
$sql = "SELECT t.taux as vat_rate, t.code as default_vat_code";
$sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c";
- $sql .= " WHERE t.active=1 AND t.fk_pays = c.rowid AND c.code='".$db->escape($thirdparty_seller->country_code)."'";
+ $sql .= " WHERE t.active=1 AND t.fk_pays = c.rowid AND c.code='".$db->escape($thirdpartytouse->country_code)."'";
$sql .= " ORDER BY t.taux DESC, t.code ASC, t.recuperableonly ASC";
$sql .= $db->plimit(1);
@@ -5747,15 +5747,15 @@ function get_product_vat_for_country($idprod, $thirdparty_seller, $idprodfournpr
}
/**
- * Return localtax vat rate of a product in a particular selling country or default country vat if product is unknown
+ * Return localtax vat rate of a product in a particular country or default country vat if product is unknown
*
* @param int $idprod Id of product
* @param int $local 1 for localtax1, 2 for localtax 2
- * @param Societe $thirdparty_seller Thirdparty with a ->country_code defined (FR, US, IT, ...)
+ * @param Societe $thirdpartytouse Thirdparty with a ->country_code defined (FR, US, IT, ...)
* @return int <0 if KO, Vat rate if OK
* @see get_product_vat_for_country()
*/
-function get_product_localtax_for_country($idprod, $local, $thirdparty_seller)
+function get_product_localtax_for_country($idprod, $local, $thirdpartytouse)
{
global $db, $mysoc;
@@ -5771,14 +5771,15 @@ function get_product_localtax_for_country($idprod, $local, $thirdparty_seller)
$product = new Product($db);
$result = $product->fetch($idprod);
- if ($mysoc->country_code == $thirdparty_seller->country_code) { // If selling country is ours
+ if ($mysoc->country_code == $thirdpartytouse->country_code) { // If selling country is ours
/* Not defined yet, so we don't use this
if ($local==1) $ret=$product->localtax1_tx;
elseif ($local==2) $ret=$product->localtax2_tx;
$found=1;
*/
} else {
- // TODO Read default product vat according to countrycode and product
+ // TODO Read default product vat according to product and another countrycode.
+ // Vat for couple anothercountrycode/product is data that is not managed and store yet, so we will fallback on next rule.
}
}
@@ -5786,7 +5787,7 @@ function get_product_localtax_for_country($idprod, $local, $thirdparty_seller)
// If vat of product for the country not found or not defined, we return higher vat of country.
$sql = "SELECT taux as vat_rate, localtax1, localtax2";
$sql .= " FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c";
- $sql .= " WHERE t.active=1 AND t.fk_pays = c.rowid AND c.code='".$db->escape($thirdparty_seller->country_code)."'";
+ $sql .= " WHERE t.active=1 AND t.fk_pays = c.rowid AND c.code='".$db->escape($thirdpartytouse->country_code)."'";
$sql .= " ORDER BY t.taux DESC, t.recuperableonly ASC";
$sql .= $db->plimit(1);
diff --git a/htdocs/theme/eldy/global.inc.php b/htdocs/theme/eldy/global.inc.php
index d223a70fbc9..7847088dfa1 100644
--- a/htdocs/theme/eldy/global.inc.php
+++ b/htdocs/theme/eldy/global.inc.php
@@ -1136,6 +1136,12 @@ select.flat.selectlimit {
text-overflow: ellipsis;
white-space: nowrap;
}
+.tdoverflowmax250 { /* For tdoverflow, the max-midth become a minimum ! */
+ max-width: 250px;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+}
.tdoverflowmax300 { /* For tdoverflow, the max-midth become a minimum ! */
max-width: 300px;
overflow: hidden;
@@ -6064,6 +6070,9 @@ dl.dropdown {
display:inline-block;
padding: 0 3px 2px 0;
}
+.maxwidthsearch .dropdown dt a span, .multiSel span {
+ padding: 0 3px 2px 3px;
+}
.dropdown span.value {
display:none;
}
diff --git a/htdocs/theme/md/style.css.php b/htdocs/theme/md/style.css.php
index 5027c1501e9..9e7501f58ec 100644
--- a/htdocs/theme/md/style.css.php
+++ b/htdocs/theme/md/style.css.php
@@ -1211,6 +1211,12 @@ select.flat.selectlimit {
text-overflow: ellipsis;
white-space: nowrap;
}
+.tdoverflowmax250 { /* For tdoverflow, the max-midth become a minimum ! */
+ max-width: 250px;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ white-space: nowrap;
+}
.tdoverflowmax300 { /* For tdoverflow, the max-midth become a minimum ! */
max-width: 300px;
overflow: hidden;
@@ -5931,6 +5937,9 @@ dl.dropdown {
display:inline-block;
padding: 0 3px 2px 0;
}
+.maxwidthsearch .dropdown dt a span, .multiSel span {
+ padding: 0 3px 2px 3px;
+}
.dropdown span.value {
display:none;
}
|