diff --git a/ChangeLog b/ChangeLog index 48ba5daa562..35696c2fd0f 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,33 +2,12 @@ English Dolibarr ChangeLog -------------------------------------------------------------- -***** ChangeLog for 13.0.4 compared to 13.0.2 ***** - -FIX: Allow disabling of a module (not a dangerous action) even if there is problem with token (due to bugged modules). -FIX: 13.0 - fatal - missing inclusion of ajax.lib.php for calling `ajax_autocompleter()` -FIX: #17919 pictures in docs. -FIX: #18006 -FIX: Accountancy - if we define a date start, automatic binding try to continue to solve old binding -FIX: Accoutancy Limit date payment not registered on purchases operations -FIX: Can't edit replacement invoice -FIX: deposit can create credit note in payment conf -FIX: division by zero on create -FIX: holiday: balances not updated correctly with pgsql because of case sensitivity field -FIX: holiday: status filter parameter has been renamed but not in links it was used -FIX: List and Create Companies Left Menus -FIX: method exists -FIX: need to add payment sum to getlibstatus function in object linked block -FIX: permission to close a proposal when using advanced permissions -FIX: Problem of z-index with popup and top menu -FIX: same thing on supplier orders -FIX: Status of invoice when making a replacement invoice -FIX: update contact birthday alert ***** ChangeLog for 14.0.0 compared to 13.0.0 ***** For users: ---------- -NEW: Module Recruitement to follow application to job positions is now stable. +NEW: Module Recruitment to follow application to job positions is now stable. NEW: Feature to make Stock Inventories NEW: Several security issues after a second private bug hunting campaign. NEW: A lot of fix into english text after a small proofreading campaign (still not perfect, but really better) @@ -71,7 +50,7 @@ NEW: Make public bookmarks editable by admin users only NEW: If main logo not defined, can use the squarred logo on login page NEW: The manifest file can use the squared image if available NEW: Enhance the multicurrency rate editor -NEW: Normalyse Type company field with ajax combobox +NEW: Normalise Type company field with ajax combobox NEW: preload product description on selection for customer propal/order/invoice NEW: Search usergroups & resources NEW: Setup Page for module creation with module builder enhancement #FoundationFunding @@ -88,14 +67,15 @@ NEW: #16378 more E-Mail Contact substitution Values for better salutation NEW: option to keep the "Automatically create the payment" checkbox empty on the tax creation page Accountancy -NEW: Accountancy - Add FEC import -NEW: Accountancy - Add a confirmation form with options on export -NEW: Accountancy - Add select date from/to in already bind customer and supplier list -NEW: Accountancy - Format FEC - Add new field DateLimitReglmt -NEW: Accountancy - In ledger & journals, show link on bank transaction -NEW: Accountancy - Possibility to filter on journals in balance -NEW: Accountancy - Add a page to list subledger accounts -NEW: Multiselect ledger account code filter on book keeping list +NEW: Add FEC import +NEW: Add a confirmation form with options on export (for notified export and validate operations) +NEW: Add select date from/to in already bind customer and supplier list +NEW: FEC / FEC2 export - Add new field DateLimitReglmt +NEW: In ledger & journals, show link on bank transaction +NEW: Possibility to filter on journals in balance +NEW: Add a page to list subledger accounts +NEW: Multiselect journal code filter on journal / balance / ledger +NEW: Add first step to close fiscal year Agenda NEW: add support for Friday as a non working day @@ -114,7 +94,7 @@ NEW: can filter files in ECM/GED on status Shared / Not shared NEW: add a check to avoid an invoice date in the future NEW: add the total of margin in invoice list NEW: can set a percentage when creating an invoice from another object -NEW: Support down payment on supplier invoice (& somes ajustments) +NEW: Support down payment on supplier invoice (& some adjustments) Margin NEW: add the total of margin in invoice list @@ -183,7 +163,7 @@ NEW: Add a security center page with all information and advices related to the NEW: Add a performance center page with all information and advices related to the performance of your instance Modules -NEW: Module Recruitement is now stable +NEW: Module Recruitment is now stable NEW: start new experimental module Event Organization Management NEW: start new experimental module Partnership Management NEW: start new experimental module Knowledge Management @@ -192,11 +172,14 @@ NEW: Check update availability for externals modules using a button on module pa Module SimplePOS is deprecated - TakePOS is recommended for the future new Options -NEW: add option CONTRACT_ALLOW_EXTERNAL_DOWNLOAD to make generated doc automatically shared -NEW: add option SUPPLIER_PROPOSAL_ALLOW_EXTERNAL_DOWNLOAD to make generated doc automatically shared -NEW: add option MAIN_SECURITY_ANTI_SSRF_SERVER_IP to define list of IPs that are local IPs -NEW: add option SOCIETE_DISABLE_WORKFORCE to hide staff field -NEW: add constant MAIN_BUGTRACK_URL to set a custom url to redirect to when clicking on link "declare a bug" +NEW: add option CONTRACT_ALLOW_EXTERNAL_DOWNLOAD to make generated doc automatically shared +NEW: add option SUPPLIER_PROPOSAL_ALLOW_EXTERNAL_DOWNLOAD to make generated doc automatically shared +NEW: add option MAIN_SECURITY_ANTI_SSRF_SERVER_IP to define list of IPs that are local IPs +NEW: add option SOCIETE_DISABLE_WORKFORCE to hide staff field +NEW: add constant MAIN_BUGTRACK_URL to set a custom url to redirect to when clicking on link "declare a bug" +NEW: add constant ACCOUNTANCY_USE_PRODUCT_ACCOUNT_ON_THIRDPARTY to manage binding with accountancy account declared on thirdparty card +NEW: add constant MAIN_PRODUCT_PERENTITY_SHARED to manage some informations (Accounting account) when product is shared on several entities +NEW: add constant MAIN_COMPANY_PERENTITY_SHARED to manage some informations (Accounting account) when company is shared on several entities For developers: @@ -230,7 +213,7 @@ NEW: hook printFieldListTitle for cabyprodserv.php NEW: hook to allow external modules to add their own shortlist of recent objects NEW: SQL-altering hooks in the turnover by product report NEW: add form confirm hook on company card -NEW: add hook addSectionECMAuto method to add custom diretory into ECM auto files +NEW: add hook addSectionECMAuto method to add custom directory into ECM auto files WARNING: @@ -240,15 +223,38 @@ Following changes may create regressions for some external modules, but were nec * The ICS value for direct debit or credit transfer is now stored on each bank account instead of into the global setup. * API /setup/shipment_methods has been replaced with API /setup/shipping_methods * Field "total" renamed into "total_ht" for table llx_facture, llx_facture_rec for better field name consistency -* Field "tva" renamed into "total_tva" for table llx_propal, llx_supplier_proposal, llx_commande, llx_commande_fournisseur for better field name consistency +* Field "tva" renamed into "total_tva" for llx_facture, table llx_propal, llx_supplier_proposal, llx_commande, llx_commande_fournisseur for better field name consistency * Field "total" renamed into "total_ttc" for table llx_propal, llx_supplier_proposal for better field name consistency * If your database is PostgreSQL, you must use version 9.1.0 or more (Dolibarr need the SQL function CONCAT) * If your database is MySQL or MariaDB, you need at least version 5.1 * Function set_price_level() has been renamed into setPriceLevel() to follow camelcase rules -* removed deprecated subtituion key __REFCLIENT__ (replaced with __REF_CLIENT__) +* removed deprecated substitution key __REFCLIENT__ (replaced with __REF_CLIENT__) * Removed constant MAIN_COUNTRIES_IN_EEC. You can now set if country is in Europe or not from the dictionary of countries. +***** ChangeLog for 13.0.4 compared to 13.0.3 ***** + +FIX: Allow disabling of a module (not a dangerous action) even if there is problem with token (due to bugged modules). +FIX: 13.0 - fatal - missing inclusion of ajax.lib.php for calling `ajax_autocompleter()` +FIX: #17919 pictures in docs. +FIX: #18006 +FIX: Accountancy - if we define a date start, automatic binding try to continue to solve old binding +FIX: Accoutancy Limit date payment not registered on purchases operations +FIX: Can't edit replacement invoice +FIX: deposit can create credit note in payment conf +FIX: division by zero on create +FIX: holiday: balances not updated correctly with pgsql because of case sensitivity field +FIX: holiday: status filter parameter has been renamed but not in links it was used +FIX: List and Create Companies Left Menus +FIX: method exists +FIX: need to add payment sum to getlibstatus function in object linked block +FIX: permission to close a proposal when using advanced permissions +FIX: Problem of z-index with popup and top menu +FIX: same thing on supplier orders +FIX: Status of invoice when making a replacement invoice +FIX: update contact birthday alert + + ***** ChangeLog for 13.0.3 compared to 13.0.2 ***** FIX: 13.0 warning - missing quotes around 'label' diff --git a/htdocs/accountancy/admin/index.php b/htdocs/accountancy/admin/index.php index 98320613bfc..f8c0c95d3c1 100644 --- a/htdocs/accountancy/admin/index.php +++ b/htdocs/accountancy/admin/index.php @@ -91,7 +91,6 @@ if ($action == 'update') { if (!$error) { foreach ($list as $constname) { $constvalue = GETPOST($constname, 'alpha'); - var_dump($constname); if (!dolibarr_set_const($db, $constname, $constvalue, 'chaine', 0, '', $conf->entity)) { $error++; } diff --git a/htdocs/accountancy/bookkeeping/card.php b/htdocs/accountancy/bookkeeping/card.php index 4c7194b2255..c156a388735 100644 --- a/htdocs/accountancy/bookkeeping/card.php +++ b/htdocs/accountancy/bookkeeping/card.php @@ -637,6 +637,8 @@ if ($action == 'create') { print_liste_field_titre("Credit", "", "", "", "", 'class="right"'); if (empty($object->date_validation)) { print_liste_field_titre("Action", "", "", "", "", 'width="60" class="center"'); + } else { + print_liste_field_titre(""); } print "\n"; @@ -683,8 +685,8 @@ if ($action == 'create') { print '
| '.$langs->trans("ServiceStatus").': '.$object->lines[$cursorline - 1]->getLibStatut(4).' | '; + print ''.$object->lines[$cursorline - 1]->getLibStatut(4).' | '; print '';
if ($user->socid == 0) {
if ($object->statut > 0 && $action != 'activateline' && $action != 'unactivateline') {
diff --git a/htdocs/core/actions_dellink.inc.php b/htdocs/core/actions_dellink.inc.php
index a7ac035506f..fbecacce515 100644
--- a/htdocs/core/actions_dellink.inc.php
+++ b/htdocs/core/actions_dellink.inc.php
@@ -27,17 +27,42 @@
// $permissiondellink must be defined
$dellinkid = GETPOST('dellinkid', 'int');
+$addlink = GETPOST('addlink', 'alpha');
$addlinkid = GETPOST('idtolinkto', 'int');
+$addlinkref = GETPOST('reftolinkto', 'alpha');
+$cancellink = GETPOST('cancel', 'alpha');
// Link invoice to order
-if ($action == 'addlink' && !empty($permissiondellink) && !GETPOST('cancel', 'alpha') && $id > 0 && $addlinkid > 0) {
+if ($action == 'addlink' && !empty($permissiondellink) && !$cancellink && $id > 0 && $addlinkid > 0) {
$object->fetch($id);
$object->fetch_thirdparty();
- $result = $object->add_object_linked(GETPOST('addlink', 'alpha'), $addlinkid);
+ $result = $object->add_object_linked($addlink, $addlinkid);
+}
+
+// Link by reference
+if ($action == 'addlinkbyref' && ! empty($permissiondellink) && !$cancellink && $id > 0 && !empty($addlinkref) && !empty($conf->global->MAIN_LINK_BY_REF_IN_LINKTO)) {
+ $element_prop = getElementProperties($addlink);
+ if (is_array($element_prop)) {
+ dol_include_once('/' . $element_prop['classpath'] . '/' . $element_prop['classfile'] . '.class.php');
+
+ $objecttmp = new $element_prop['classname']($db);
+ $ret = $objecttmp->fetch(0, $addlinkref);
+ if ($ret > 0) {
+ $object->fetch($id);
+ $object->fetch_thirdparty();
+ $result = $object->add_object_linked($addlink, $objecttmp->id);
+ if (isset($_POST['reftolinkto'])) unset($_POST['reftolinkto']);
+ } elseif ($ret < 0) {
+ setEventMessages($objecttmp->error, $objecttmp->errors, 'errors');
+ } else {
+ $langs->load('errors');
+ setEventMessage($langs->trans('ErrorRecordNotFound'), 'errors');
+ }
+ }
}
// Delete link
-if ($action == 'dellink' && !empty($permissiondellink) && !GETPOST('cancel', 'alpha') && $dellinkid > 0) {
+if ($action == 'dellink' && !empty($permissiondellink) && !$cancellink && $dellinkid > 0) {
$result = $object->deleteObjectLinked(0, '', 0, '', $dellinkid);
if ($result < 0) {
setEventMessages($object->error, $object->errors, 'errors');
diff --git a/htdocs/core/actions_massactions.inc.php b/htdocs/core/actions_massactions.inc.php
index e5d4de26278..8d70f7c3042 100644
--- a/htdocs/core/actions_massactions.inc.php
+++ b/htdocs/core/actions_massactions.inc.php
@@ -1547,7 +1547,7 @@ if (!$error && ($massaction == 'disable' || ($action == 'disable' && $confirm ==
$parameters['toselect'] = $toselect;
$parameters['uploaddir'] = $uploaddir;
$parameters['massaction'] = $massaction;
-$parameters['diroutputmassaction'] = $diroutputmassaction;
+$parameters['diroutputmassaction'] = isset($diroutputmassaction) ? $diroutputmassaction : null;
$reshook = $hookmanager->executeHooks('doMassActions', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
if ($reshook < 0) {
diff --git a/htdocs/core/actions_sendmails.inc.php b/htdocs/core/actions_sendmails.inc.php
index 83a823edeb2..e5c75a2e7c3 100644
--- a/htdocs/core/actions_sendmails.inc.php
+++ b/htdocs/core/actions_sendmails.inc.php
@@ -182,10 +182,15 @@ if (($action == 'send' || $action == 'relance') && !$_POST['addfile'] && !$_POST
$tmparray = array();
if (trim($_POST['sendto'])) {
- // Recipients are provided into free text
+ // Recipients are provided into free text field
$tmparray[] = trim($_POST['sendto']);
}
+ if (trim($_POST['tomail'])) {
+ // Recipients are provided into free hidden text field
+ $tmparray[] = trim($_POST['tomail']);
+ }
+
if (count($receiver) > 0) {
// Recipient was provided from combo list
foreach ($receiver as $key => $val) {
diff --git a/htdocs/core/class/CMailFile.class.php b/htdocs/core/class/CMailFile.class.php
index 5683c8e6a07..33db393bbc6 100644
--- a/htdocs/core/class/CMailFile.class.php
+++ b/htdocs/core/class/CMailFile.class.php
@@ -1628,7 +1628,7 @@ class CMailFile
* @return array array of email => name
* @see getValidAddress()
*/
- public function getArrayAddress($address)
+ public static function getArrayAddress($address)
{
global $conf;
diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php
index ceac7015065..36df3b1a7b9 100644
--- a/htdocs/core/class/commonobject.class.php
+++ b/htdocs/core/class/commonobject.class.php
@@ -3791,7 +3791,6 @@ abstract class CommonObject
} elseif ($objecttype == 'contact') {
$module = 'societe';
}
-
// Set classfile
$classfile = strtolower($subelement);
$classname = ucfirst($subelement);
@@ -3823,6 +3822,11 @@ abstract class CommonObject
$classfile = 'conferenceorboothattendee';
$classname = 'ConferenceOrBoothAttendee';
$module = 'eventorganization';
+ } elseif ($objecttype == 'conferenceorbooth') {
+ $classpath = 'eventorganization/class';
+ $classfile = 'conferenceorbooth';
+ $classname = 'ConferenceOrBooth';
+ $module = 'eventorganization';
}
// Here $module, $classfile and $classname are set
diff --git a/htdocs/core/class/dolreceiptprinter.class.php b/htdocs/core/class/dolreceiptprinter.class.php
index 45c87401416..a3ddb3d7c7f 100644
--- a/htdocs/core/class/dolreceiptprinter.class.php
+++ b/htdocs/core/class/dolreceiptprinter.class.php
@@ -680,9 +680,7 @@ class dolReceiptPrinter extends Printer
foreach ($object->lines as $line) {
$total_localtax1 += $line->total_localtax1;
}
- foreach ($vatarray as $vatkey => $vatvalue) {
- $this->printer->text(str_pad(price($total_localtax1), 10, ' ', STR_PAD_LEFT)."\n");
- }
+ $this->printer->text(str_pad(price($total_localtax1), 10, ' ', STR_PAD_LEFT)."\n");
break;
case 'DOL_PRINT_OBJECT_TAX2':
//var_dump($object);
@@ -690,9 +688,7 @@ class dolReceiptPrinter extends Printer
foreach ($object->lines as $line) {
$total_localtax2 += $line->total_localtax2;
}
- foreach ($vatarray as $vatkey => $vatvalue) {
- $this->printer->text(str_pad(price($total_localtax2), 10, ' ', STR_PAD_LEFT)."\n");
- }
+ $this->printer->text(str_pad(price($total_localtax2), 10, ' ', STR_PAD_LEFT)."\n");
break;
case 'DOL_PRINT_OBJECT_TOTAL':
$title = $langs->trans('TotalHT');
diff --git a/htdocs/core/class/hookmanager.class.php b/htdocs/core/class/hookmanager.class.php
index 5e24ee03fa4..45643e26e4c 100644
--- a/htdocs/core/class/hookmanager.class.php
+++ b/htdocs/core/class/hookmanager.class.php
@@ -193,6 +193,7 @@ class HookManager
'getFormatedSupplierRef',
'getIdProfUrl',
'getInputIdProf',
+ 'menuLeftMenuItems',
'moveUploadedFile',
'moreHtmlStatus',
'pdf_build_address',
diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php
index 178404da973..54e5b19b25c 100644
--- a/htdocs/core/class/html.form.class.php
+++ b/htdocs/core/class/html.form.class.php
@@ -1332,7 +1332,7 @@ class Form
}
// We search companies
- $sql = "SELECT s.rowid, s.nom as name, s.name_alias, s.client, s.fournisseur, s.code_client, s.code_fournisseur";
+ $sql = "SELECT s.rowid, s.nom as name, s.name_alias, s.tva_intra, s.client, s.fournisseur, s.code_client, s.code_fournisseur";
if (!empty($conf->global->COMPANY_SHOW_ADDRESS_SELECTLIST)) {
$sql .= ", s.address, s.zip, s.town";
$sql .= ", dictp.code as country_code";
@@ -1384,6 +1384,7 @@ class Form
$sql .= " OR s.barcode LIKE '".$this->db->escape($prefix.$filterkey)."%'";
}
$sql .= " OR s.code_client LIKE '".$this->db->escape($prefix.$filterkey)."%' OR s.code_fournisseur LIKE '".$this->db->escape($prefix.$filterkey)."%'";
+ $sql .= " OR s.name_alias LIKE '".$this->db->escape($prefix.$filterkey)."%' OR s.tva_intra LIKE '".$this->db->escape($prefix.$filterkey)."%'";
$sql .= ")";
}
$sql .= $this->db->order("nom", "ASC");
@@ -6974,13 +6975,15 @@ class Form
// Search data
$sql = "SELECT t.rowid, ".$fieldstoshow." FROM ".MAIN_DB_PREFIX.$objecttmp->table_element." as t";
- if (isset($objecttmp->ismultientitymanaged) && !is_numeric($objecttmp->ismultientitymanaged)) {
- $tmparray = explode('@', $objecttmp->ismultientitymanaged);
- $sql .= ' INNER JOIN '.MAIN_DB_PREFIX.$tmparray[1].' as parenttable ON parenttable.rowid = t.'.$tmparray[0];
- }
- if ($objecttmp->ismultientitymanaged == 'fk_soc@societe') {
- if (!$user->rights->societe->client->voir && !$user->socid) {
- $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
+ if (isset($objecttmp->ismultientitymanaged)) {
+ if (!is_numeric($objecttmp->ismultientitymanaged)) {
+ $tmparray = explode('@', $objecttmp->ismultientitymanaged);
+ $sql .= ' INNER JOIN '.MAIN_DB_PREFIX.$tmparray[1].' as parenttable ON parenttable.rowid = t.'.$tmparray[0];
+ }
+ if ($objecttmp->ismultientitymanaged == 'fk_soc@societe') {
+ if (!$user->rights->societe->client->voir && !$user->socid) {
+ $sql .= ", ".MAIN_DB_PREFIX."societe_commerciaux as sc";
+ }
}
}
@@ -6991,27 +6994,29 @@ class Form
$sql .= $hookmanager->resPrint;
} else {
$sql .= " WHERE 1=1";
- if (isset($objecttmp->ismultientitymanaged) && $objecttmp->ismultientitymanaged == 1) {
- $sql .= " AND t.entity IN (".getEntity($objecttmp->table_element).")";
- }
- if (isset($objecttmp->ismultientitymanaged) && !is_numeric($objecttmp->ismultientitymanaged)) {
- $sql .= ' AND parenttable.entity = t.'.$tmparray[0];
- }
- if ($objecttmp->ismultientitymanaged == 1 && !empty($user->socid)) {
- if ($objecttmp->element == 'societe') {
- $sql .= " AND t.rowid = ".$user->socid;
- } else {
- $sql .= " AND t.fk_soc = ".$user->socid;
+ if (isset($objecttmp->ismultientitymanaged)) {
+ if ($objecttmp->ismultientitymanaged == 1) {
+ $sql .= " AND t.entity IN (".getEntity($objecttmp->table_element).")";
+ }
+ if (!is_numeric($objecttmp->ismultientitymanaged)) {
+ $sql .= ' AND parenttable.entity = t.'.$tmparray[0];
+ }
+ if ($objecttmp->ismultientitymanaged == 1 && !empty($user->socid)) {
+ if ($objecttmp->element == 'societe') {
+ $sql .= " AND t.rowid = ".$user->socid;
+ } else {
+ $sql .= " AND t.fk_soc = ".$user->socid;
+ }
+ }
+ if ($objecttmp->ismultientitymanaged == 'fk_soc@societe') {
+ if (!$user->rights->societe->client->voir && !$user->socid) {
+ $sql .= " AND t.rowid = sc.fk_soc AND sc.fk_user = ".$user->id;
+ }
}
}
if ($searchkey != '') {
$sql .= natural_search(explode(',', $fieldstoshow), $searchkey);
}
- if ($objecttmp->ismultientitymanaged == 'fk_soc@societe') {
- if (!$user->rights->societe->client->voir && !$user->socid) {
- $sql .= " AND t.rowid = sc.fk_soc AND sc.fk_user = ".$user->id;
- }
- }
if ($objecttmp->filter) { // Syntax example "(t.ref:like:'SO-%') and (t.date_creation:<:'20160101')"
/*if (! DolibarrApi::_checkFilters($objecttmp->filter))
{
@@ -7848,6 +7853,10 @@ class Form
$tplpath = 'expensereport';
} elseif ($objecttype == 'subscription') {
$tplpath = 'adherents';
+ } elseif ($objecttype == 'conferenceorbooth') {
+ $tplpath = 'eventorganization';
+ } elseif ($objecttype == 'conferenceorboothattendee') {
+ $tplpath = 'eventorganization';
}
global $linkedObjectBlock;
@@ -7970,6 +7979,21 @@ class Form
if (!empty($possiblelink['perms']) && (empty($restrictlinksto) || in_array($key, $restrictlinksto)) && (empty($excludelinksto) || !in_array($key, $excludelinksto))) {
print ' use_javascript_ajax) ? '' : ' style="display:none"').'>';
+
+ if (!empty($conf->global->MAIN_LINK_BY_REF_IN_LINKTO)) {
+ print ' ';
//$linktoelem.=($linktoelem?' ':'');
- if ($num > 0) {
+ if ($num > 0 || !empty($conf->global->MAIN_LINK_BY_REF_IN_LINKTO)) {
$linktoelemlist .= ''; + } + $sql = $possiblelink['sql']; $resqllist = $this->db->query($sql); @@ -8027,7 +8051,7 @@ class Form print ' ';
$out .= ' ';
diff --git a/htdocs/core/class/notify.class.php b/htdocs/core/class/notify.class.php
index 6b32799bc89..2e0a71460ba 100644
--- a/htdocs/core/class/notify.class.php
+++ b/htdocs/core/class/notify.class.php
@@ -65,7 +65,7 @@ class Notify
// Les codes actions sont definis dans la table llx_notify_def
// codes actions supported are
- // @todo defined also into interface_50_modNotificiation_Notificiation.class.php
+ // @todo defined also into interface_50_modNotification_Notification.class.php
public $arrayofnotifsupported = array(
'BILL_VALIDATE',
'BILL_PAYED',
@@ -80,8 +80,8 @@ class Notify
'SHIPPING_VALIDATE',
'EXPENSE_REPORT_VALIDATE',
'EXPENSE_REPORT_APPROVE',
- 'HOLIDAY_VALIDATE',
- 'HOLIDAY_APPROVE',
+ 'HOLIDAY_VALIDATE',
+ 'HOLIDAY_APPROVE',
'ACTION_CREATE'
);
@@ -546,7 +546,7 @@ class Notify
$object_type = 'holiday';
$labeltouse = $conf->global->HOLIDAY_APPROVE_TEMPLATE;
$mesg = $outputlangs->transnoentitiesnoconv("EMailTextHolidayApproved", $link);
- break;
+ break;
case 'ACTION_CREATE':
$link = ''.$newref.'';
$dir_output = $conf->agenda->dir_output;
@@ -567,10 +567,10 @@ class Notify
$subject = make_substitutions($arraydefaultmessage->topic, $substitutionarray, $outputlangs);
$message = make_substitutions($arraydefaultmessage->content, $substitutionarray, $outputlangs);
} else {
- $message = $outputlangs->transnoentities("YouReceiveMailBecauseOfNotification", $application, $mysoc->name)."\n";
- $message .= $outputlangs->transnoentities("YouReceiveMailBecauseOfNotification2", $application, $mysoc->name)."\n";
- $message .= "\n";
- $message .= $mesg;
+ $message = $outputlangs->transnoentities("YouReceiveMailBecauseOfNotification", $application, $mysoc->name)."\n";
+ $message .= $outputlangs->transnoentities("YouReceiveMailBecauseOfNotification2", $application, $mysoc->name)."\n";
+ $message .= "\n";
+ $message .= $mesg;
}
$ref = dol_sanitizeFileName($newref);
@@ -687,7 +687,7 @@ class Notify
break;
case 'BILL_PAYED':
$link = ''.$newref.'';
- $dir_output = $$conf->facture->dir_output."/".get_exdir(0, 0, 0, 1, $object, 'invoice');
+ $dir_output = $conf->facture->dir_output."/".get_exdir(0, 0, 0, 1, $object, 'invoice');
$object_type = 'facture';
$mesg = $langs->transnoentitiesnoconv("EMailTextInvoicePayed", $link);
break;
@@ -782,7 +782,7 @@ class Notify
$dir_output = $conf->holiday->dir_output;
$object_type = 'holiday';
$mesg = $langs->transnoentitiesnoconv("EMailTextHolidayApproved", $link);
- break;
+ break;
case 'ACTION_CREATE':
$link = ''.$newref.'';
$dir_output = $conf->agenda->dir_output;
diff --git a/htdocs/core/js/lib_notification.js.php b/htdocs/core/js/lib_notification.js.php
index 616463b944d..ee41555119a 100644
--- a/htdocs/core/js/lib_notification.js.php
+++ b/htdocs/core/js/lib_notification.js.php
@@ -131,8 +131,8 @@ function check_events() {
if (value.type == 'agenda')
{
- url = '' + value.id_agenda;
- title = 'trans('EventReminder')) ?>';
+ url = '' + value.id_agenda;
+ title = 'transnoentities('EventReminder')) ?>';
}
var extra = {
icon: '',
diff --git a/htdocs/core/js/timesheet.js b/htdocs/core/js/timesheet.js
index 0c8c9ff3245..e9e66787aa0 100644
--- a/htdocs/core/js/timesheet.js
+++ b/htdocs/core/js/timesheet.js
@@ -1,5 +1,6 @@
/* Copyright (C) 2014 delcroip '; - $out .= ' Autodetect if we scan a product barcode or a lot/serial barcode '; - $out .= ' Scan a product barcode '; - $out .= ' Scan a product lot or serial number '; + $out .= ' Autodetect if we scan a product barcode or a lot/serial barcode '; + $out .= ' Scan a product barcode '; + $out .= ' Scan a product lot or serial number '; $out .= $langs->trans("QtyToAddAfterBarcodeScan").' '; $out .= ''; @@ -88,13 +88,16 @@ class FormOther */ $out .= ' '; $out .= ' '; - $out .= ''.$langs->trans("FeatureNotYetAvailable").''; - - // TODO Add call of javascript $jstoexecuteonadd so each scan will add qty into the inventory page + an ajax save. + $out .= ''; $out .= ' |
| '.$langs->trans("EventOrganizationICSLink").' | '; - print ''; + // Define $urlwithroot + $urlwithouturlroot = preg_replace('/'.preg_quote(DOL_URL_ROOT, '/').'$/i', '', trim($dolibarr_main_url_root)); + $urlwithroot = $urlwithouturlroot.DOL_URL_ROOT; + + // Show message + $message = 'entity : ""); + $message .= '&exportkey='.($conf->global->MAIN_AGENDA_XCAL_EXPORTKEY ?urlencode($conf->global->MAIN_AGENDA_XCAL_EXPORTKEY) : '...'); + $message .= "&project=".$projectstatic->id.'&module='.urlencode('@eventorganization').'&status='.ConferenceOrBooth::STATUS_CONFIRMED.'">'.$langs->trans('DownloadICSLink').''; + print $message; print " |