Merge branch 'develop' of github.com:Dolibarr/dolibarr into NEW_AgendaEvent_Remind_Part2
This commit is contained in:
commit
f8c79db4a9
4
.github/workflows/stale-issues-safe.yml
vendored
4
.github/workflows/stale-issues-safe.yml
vendored
@ -14,11 +14,11 @@ jobs:
|
||||
- uses: Dolibarr/stale@staleunstale
|
||||
with:
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
stale-message: 'This issue is stale because it has been open 1 year with no activity. If this is a bug, please comment to confirm it is still present on latest stable version. if this is a feature request, please comment to notify the request is still relevant and not yet covered by latest stable version. This issue may be closed automatically by stale bot in 15 days (you should still be able to re-open it if required).'
|
||||
stale-message: 'This issue is stale because it has been open 1 year with no activity. If this is a bug, please comment to confirm it is still present on latest stable version. if this is a feature request, please comment to notify the request is still relevant and not yet covered by latest stable version. This issue may be closed automatically by stale bot in 10 days (you should still be able to re-open it if required).'
|
||||
stale-label: 'Issue Stale (automatic label)'
|
||||
exempt-labels: 'Priority High / Blocking,Priority Top Strategic,Priority Medium,Hacktoberfest,good first issue,Bug Security (CVE),Analysis of PR in progres'
|
||||
days-before-stale: 365
|
||||
days-before-close: 15
|
||||
days-before-close: 10
|
||||
operations-per-run: 100
|
||||
dry-run: false
|
||||
|
||||
@ -345,10 +345,10 @@ Only people that installed Dolibarr using the all-in-one autoinstaller for Windo
|
||||
|
||||
* DoliWAMP autoinstaller for Windows is not more available on 32bits systems. Use standard package if you need to use such architecture.
|
||||
* It is not possible to migrate from an installation done with the old DoliWAMP autoinstaller for Windows by using this new one. You must make a backup
|
||||
of your database, make a fresh installation using the new installer and reload.
|
||||
* Don't forget that DoliWAMP is a good solution to make a quick test of Dolibarr on your local computer but was never recommanded as a production
|
||||
solution on a local desktop since a desktop computer has not a backup and security policy as good as on a server (when there is one).
|
||||
DoliWAMP remains a solution for fast test or demo purposes.
|
||||
of your database, make a fresh installation using the new installer and reload your backup. Don't forget that DoliWAMP is a good solution to make a
|
||||
quick test of Dolibarr on your local computer but was never recommanded as a production solution on a local desktop since a desktop computer has not
|
||||
a backup and security policy as good as on a server (when there is one).
|
||||
DoliWAMP remains a solution for fast test or demo purposes. Prefer using standard package for production.
|
||||
|
||||
|
||||
***** ChangeLog for 11.0.5 compared to 11.0.4 *****
|
||||
|
||||
105
SECURITY.md
105
SECURITY.md
@ -1,13 +1,108 @@
|
||||
# Security Policy
|
||||
|
||||
## Supported Versions
|
||||
This file contains some policies about the security reports on Dolibarr ERP CRM project, one of the most popular Open Source ERP and CRM in the world.
|
||||
|
||||
## Supported Versions for security reports
|
||||
|
||||
| Version | Supported |
|
||||
| --------- | ------------------ |
|
||||
| <= 9.0.* | :x: |
|
||||
| >= 10.0.* | :white_check_mark: |
|
||||
|
||||
| Version | Supported |
|
||||
| -------- | ------------------ |
|
||||
| <= 8.0.* | :x: |
|
||||
| >= 9.0.* | :white_check_mark: |
|
||||
|
||||
## Reporting a Vulnerability
|
||||
|
||||
To report a vulnerability, please send an email to security@dolibarr.org
|
||||
In most cases, after fixing the security, we make an answer by email to say the issue has been fixed.
|
||||
|
||||
|
||||
## Hunting vulnerabilities on Dolibarr
|
||||
|
||||
We believe that future of software is online SaaS. This means software are more and more critical and no technology is perfect. Working with skilled security researchers is crucial in identifying weaknesses in our technology.
|
||||
|
||||
If you believe you've found a security bug in our service, we are happy to work with you to resolve the issue promptly and ensure you are fairly rewarded for your discovery.
|
||||
|
||||
Any type of denial of service attacks is strictly forbidden, as well as any interference with network equipment and Dolibarr infrastructure.
|
||||
|
||||
We recommand to install Dolibarr ERP CRM on you own server (as most Open Source software, download and use is free: https://www.dolibarr.org/download) to get access on every side of application.
|
||||
|
||||
### User Agent
|
||||
|
||||
If you try to find bug on Dolibarr, we recommend to append to your user-agent header the following value: '-BugHunting-dolibarr'.
|
||||
|
||||
### Account access
|
||||
|
||||
You can install the web application yourself on your own platform/server so you get full access to application and sources. Download the zip of the files to put into your own web server virtual host from https://www.dolibarr.org/download
|
||||
|
||||
|
||||
## Eligibility and Responsible Disclosure
|
||||
|
||||
We are happy to thank everyone who submits valid reports which help us improve the security of Dolibarr however, only those that meet the following eligibility requirements may receive a monetary reward:
|
||||
|
||||
You must be the first reporter of a vulnerability.
|
||||
|
||||
The vulnerability must be a qualifying vulnerability (see below)
|
||||
|
||||
Any vulnerability found must be reported no later than 24 hours after discovery
|
||||
|
||||
You must send a clear textual description of the report along with steps to reproduce the issue, include attachments such as screenshots or proof of concept code as necessary.
|
||||
|
||||
You must avoid tests that could cause degradation or interruption of our service (refrain from using automated tools, and limit yourself about requests per second), that's why we recommand to install softwate on your own platform.
|
||||
|
||||
You must not leak, manipulate, or destroy any user data.
|
||||
|
||||
You must not be a former or current employee of Dolibarr or one of its contractor.
|
||||
|
||||
Reports about vulnerabilities are examined by our security analysts.
|
||||
|
||||
Our analysis is always based on worst case exploitation of the vulnerability, as is the reward we pay.
|
||||
|
||||
No vulnerability disclosure, including partial is allowed for the moment.
|
||||
|
||||
|
||||
## Scope for qualified vulnerabilities
|
||||
|
||||
ONLY vulnerabilities discovered when the following setup is used are accepted:
|
||||
|
||||
* $dolibarr_main_prod must be 1 into conf.php
|
||||
* $dolibarr_nocsrfcheck must not be set to 0 (should be 1 by default) into conf.php
|
||||
* The constant MAIN_SECURITY_CSRF_WITH_TOKEN must be set to 1 into backoffice menu Home - Setup - Other (this value should be switched soon to 1 by default)
|
||||
* ONLY security reports on "stable" modules are allowed (troubles into experimental and developement modules are not accepted).
|
||||
|
||||
Scope is the web application (back office) and the APIs.
|
||||
|
||||
|
||||
## Qualifying vulnerabilities for Bug bounty programs
|
||||
* Remote code execution (RCE)
|
||||
* Local files access and manipulation (LFI, RFI, XXE, SSRF, XSPA)
|
||||
* Code injections (HTML, JS, SQL, PHP, ...)
|
||||
* Cross-Site Scripting (XSS)
|
||||
* Cross-Site Requests Forgery (CSRF) with real security impact
|
||||
* Open redirect
|
||||
* Broken authentication & session management
|
||||
* Insecure direct object references
|
||||
* CORS with real security impact
|
||||
* Horizontal and vertical privilege escalation
|
||||
* "HTTP Host Header" XSS
|
||||
|
||||
|
||||
## Non-qualifying vulnerabilities for Bug bounty programs, but qualified for reporting
|
||||
* "Self" XSS
|
||||
* Missing cookie flags
|
||||
* SSL/TLS best practices
|
||||
* Mixed content warnings
|
||||
* Denial of Service attacks
|
||||
* Clickjacking/UI redressing
|
||||
* Software version disclosure
|
||||
* Stack traces or path disclosure
|
||||
* Physical or social engineering attempts
|
||||
* Recently disclosed 0-day vulnerabilities
|
||||
* Presence of autocomplete attribute on web forms
|
||||
* Vulnerabilities affecting outdated browsers or platforms
|
||||
* Issues that require physical access to a victim’s computer/device
|
||||
* Logout and other instances of low-severity Cross-Site Request Forgery
|
||||
* Missing security-related HTTP headers which do not lead directly to a vulnerability
|
||||
* Reports from automated web vulnerability scanners (Acunetix, Vega, etc.) that have not been validated
|
||||
* Invalid or missing SPF (Sender Policy Framework) records (Incomplete or missing SPF/DKIM/DMARC)
|
||||
* Reports on features flagged as experimental
|
||||
|
||||
|
||||
@ -292,7 +292,7 @@ if ($action == 'setjournal') {
|
||||
}
|
||||
|
||||
if ($action == 'setdocref') {
|
||||
$refdoc = trim(GETPOST('doc_ref', 'alpha'));
|
||||
$refdoc = GETPOST('doc_ref', 'alpha');
|
||||
$result = $object->updateByMvt($piece_num, 'doc_ref', $refdoc, $mode);
|
||||
if ($result < 0) {
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
|
||||
@ -2,8 +2,8 @@
|
||||
/* Copyright (C) 2016 Neil Orley <neil.orley@oeris.fr>
|
||||
* Copyright (C) 2013-2016 Olivier Geffroy <jeff@jeffinfo.com>
|
||||
* Copyright (C) 2013-2016 Florian Henry <florian.henry@open-concept.pro>
|
||||
* Copyright (C) 2013-2018 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2013-2020 Alexandre Spangaro <aspangaro@open-dsi.fr>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
*
|
||||
* 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
|
||||
@ -31,6 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/bookkeeping.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/accountancy/class/accountingjournal.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formaccounting.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
@ -289,6 +290,7 @@ if ($action == 'delmouvconfirm' && $user->rights->accounting->mouvements->suppri
|
||||
*/
|
||||
|
||||
$formaccounting = new FormAccounting($db);
|
||||
$formfile = new FormFile($db);
|
||||
$formother = new FormOther($db);
|
||||
$form = new Form($db);
|
||||
|
||||
|
||||
@ -231,7 +231,7 @@ print '</table>';
|
||||
|
||||
dol_fiche_end();
|
||||
|
||||
print '<div class="center"><input class="button" type="submit" name="save" value="'.dol_escape_htmltag($langs->trans("Save")).'"></div>';
|
||||
//print '<div class="center"><input class="button" type="submit" name="save" value="'.dol_escape_htmltag($langs->trans("Save")).'"></div>';
|
||||
|
||||
print '</form>';
|
||||
|
||||
|
||||
@ -108,7 +108,7 @@ if ($actionsave)
|
||||
// Save colors
|
||||
while ($i <= 2)
|
||||
{
|
||||
$color = trim(GETPOST('BANK_COLORIZE_MOVEMENT_COLOR'.$i, 'alpha'));
|
||||
$color = GETPOST('BANK_COLORIZE_MOVEMENT_COLOR'.$i, 'alpha');
|
||||
if ($color == '-1') $color = '';
|
||||
|
||||
$res = dolibarr_set_const($db, 'BANK_COLORIZE_MOVEMENT_COLOR'.$i, $color, 'chaine', 0, '', $conf->entity);
|
||||
|
||||
@ -62,7 +62,7 @@ $extrafields->fetch_name_optionals_label($object->table_element);
|
||||
$search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val) {
|
||||
if (GETPOST('search_'.$key, 'alpha')) $search[$key] = GETPOST('search_'.$key, 'alpha');
|
||||
@ -660,12 +660,18 @@ if ($object->id > 0 && (empty($action) || ($action != 'edit' && $action != 'crea
|
||||
|
||||
if (empty($reshook))
|
||||
{
|
||||
// Edit
|
||||
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=edit">'.$langs->trans("Edit").'</a></div>';
|
||||
|
||||
// Clone
|
||||
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'&socid='.$object->socid.'&action=clone&object=order">'.$langs->trans("ToClone").'</a></div>';
|
||||
|
||||
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=collect">'.$langs->trans("CollectNow").'</a></div>';
|
||||
// Collect now
|
||||
if (count($object->actions) > 0) {
|
||||
print '<div class="inline-block divButAction"><a class="butAction" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=collect">'.$langs->trans("CollectNow").'</a></div>';
|
||||
} else {
|
||||
print '<div class="inline-block divButAction"><a class="butActionRefused" href="#" title="'.dol_escape_htmltag($langs->trans("NoOperations")).'">'.$langs->trans("CollectNow").'</a></div>';
|
||||
}
|
||||
|
||||
print '<div class="inline-block divButAction"><a class="butActionDelete" href="'.$_SERVER["PHP_SELF"].'?id='.$object->id.'&action=delete">'.$langs->trans('Delete').'</a></div>';
|
||||
}
|
||||
|
||||
@ -86,7 +86,7 @@ if ($user->socid > 0) // Protection if external user
|
||||
//$result = restrictedArea($user, 'emailcollector', $id, '');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val)
|
||||
{
|
||||
|
||||
@ -80,7 +80,7 @@ if ($user->socid > 0) // Protection if external user
|
||||
//$result = restrictedArea($user, 'mymodule', $id, '');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val)
|
||||
{
|
||||
|
||||
@ -52,7 +52,7 @@ if ($action == 'update' && !$cancel)
|
||||
{
|
||||
dolibarr_set_const($db, "MAIN_DISABLE_ALL_SMS", GETPOST("MAIN_DISABLE_ALL_SMS", 'alphanohtml'), 'chaine', 0, '', $conf->entity);
|
||||
|
||||
dolibarr_set_const($db, "MAIN_SMS_SENDMODE", GETPOST("MAIN_SMS_SENDMODE", 'alphahtml'), 'chaine', 0, '', $conf->entity);
|
||||
dolibarr_set_const($db, "MAIN_SMS_SENDMODE", GETPOST("MAIN_SMS_SENDMODE", 'alphanohtml'), 'chaine', 0, '', $conf->entity);
|
||||
|
||||
dolibarr_set_const($db, "MAIN_MAIL_SMS_FROM", GETPOST("MAIN_MAIL_SMS_FROM", 'alphanohtml'), 'chaine', 0, '', $conf->entity);
|
||||
|
||||
@ -300,12 +300,12 @@ if ($action == 'edit')
|
||||
$formsms = new FormSms($db);
|
||||
$formsms->fromtype = 'user';
|
||||
$formsms->fromid = $user->id;
|
||||
$formsms->fromsms = (isset($_POST['fromsms']) ? $_POST['fromsms'] : ($conf->global->MAIN_MAIL_SMS_FROM ? $conf->global->MAIN_MAIL_SMS_FROM : $user->user_mobile));
|
||||
$formsms->fromsms = (GETPOSTISSET('fromsms') ? $_POST['fromsms'] : ($conf->global->MAIN_MAIL_SMS_FROM ? $conf->global->MAIN_MAIL_SMS_FROM : $user->user_mobile));
|
||||
$formsms->withfromreadonly = 0;
|
||||
$formsms->withsubstit = 0;
|
||||
$formsms->withfrom = 1;
|
||||
$formsms->withto = (isset($_POST['sendto']) ? $_POST['sendto'] : $user->user_mobile ? $user->user_mobile : 1);
|
||||
$formsms->withbody = (isset($_POST['message']) ? (empty($_POST['message']) ? 1 : $_POST['message']) : $langs->trans("ThisIsATestMessage"));
|
||||
$formsms->withto = (GETPOSTISSET('sendto') ? $_POST['sendto'] : ($user->user_mobile ? $user->user_mobile : 1));
|
||||
$formsms->withbody = (GETPOSTISSET('message') ? (empty($_POST['message']) ? 1 : $_POST['message']) : $langs->trans("ThisIsATestMessage"));
|
||||
$formsms->withbodyreadonly = 0;
|
||||
$formsms->withcancel = 1;
|
||||
// Tableau des substitutions
|
||||
|
||||
@ -498,6 +498,12 @@ if ($virtualdiffersfromphysical)
|
||||
print '<br>';
|
||||
}
|
||||
|
||||
print '<form>';
|
||||
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="warehouse">';
|
||||
|
||||
|
||||
/*
|
||||
@ -648,9 +654,15 @@ foreach ($dirmodels as $reldir)
|
||||
|
||||
print '</table>';
|
||||
|
||||
print '</form>';
|
||||
|
||||
|
||||
// Other
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER['PHP_SELF'].'">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
print '<input type="hidden" name="action" value="warehouse">';
|
||||
|
||||
print load_fiche_titre($langs->trans("Other"), '', '');
|
||||
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
@ -33,7 +33,7 @@ $langs->load("admin");
|
||||
$action = GETPOST('action', 'alpha');
|
||||
$what = GETPOST('what', 'alpha');
|
||||
$export_type = GETPOST('export_type', 'alpha');
|
||||
$file = trim(GETPOST('zipfilename_template', 'alpha'));
|
||||
$file = GETPOST('zipfilename_template', 'alpha');
|
||||
$compression = GETPOST('compression');
|
||||
|
||||
$file = dol_sanitizeFileName($file);
|
||||
|
||||
@ -28,7 +28,7 @@ require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
||||
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array("admin", "workflow", "propal", "workflow", "orders", "supplier_proposals", "receptions"));
|
||||
$langs->loadLangs(array("admin", "workflow", "propal", "workflow", "orders", "supplier_proposal", "receptions"));
|
||||
|
||||
if (!$user->admin) accessforbidden();
|
||||
|
||||
@ -80,16 +80,22 @@ $workflowcodes = array(
|
||||
// Automatic classification of proposal
|
||||
'WORKFLOW_ORDER_CLASSIFY_BILLED_PROPAL'=>array('family'=>'classify_proposal', 'position'=>30, 'enabled'=>'! empty($conf->propal->enabled) && ! empty($conf->commande->enabled)', 'picto'=>'propal', 'warning'=>''),
|
||||
'WORKFLOW_INVOICE_CLASSIFY_BILLED_PROPAL'=>array('family'=>'classify_proposal', 'position'=>31, 'enabled'=>'! empty($conf->propal->enabled) && ! empty($conf->facture->enabled)', 'picto'=>'propal', 'warning'=>''),
|
||||
'separator2'=>array('family'=>'separator', 'position'=>35),
|
||||
// Automatic classification of order
|
||||
'WORKFLOW_ORDER_CLASSIFY_SHIPPED_SHIPPING'=>array('family'=>'classify_order', 'position'=>40, 'enabled'=>'! empty($conf->expedition->enabled) && ! empty($conf->commande->enabled)', 'picto'=>'order'),
|
||||
'WORKFLOW_INVOICE_AMOUNT_CLASSIFY_BILLED_ORDER'=>array('family'=>'classify_order', 'position'=>41, 'enabled'=>'! empty($conf->facture->enabled) && ! empty($conf->commande->enabled)', 'picto'=>'order', 'warning'=>''), // For this option, if module invoice is disabled, it does not exists, so "Classify billed" for order must be done manually from order card.
|
||||
'separator2'=>array('family'=>'separator', 'position'=>50),
|
||||
'separator3'=>array('family'=>'separator', 'position'=>50),
|
||||
// Automatic classification supplier proposal
|
||||
'WORKFLOW_ORDER_CLASSIFY_BILLED_SUPPLIER_PROPOSAL'=>array('family'=>'classify_supplier_proposal', 'position'=>60, 'enabled'=>'! empty($conf->supplier_proposal->enabled) && (!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled))', 'picto'=>'propal', 'warning'=>''),
|
||||
'separator4'=>array('family'=>'separator', 'position'=>61),
|
||||
// Automatic classification supplier order
|
||||
'WORKFLOW_INVOICE_AMOUNT_CLASSIFY_BILLED_SUPPLIER_ORDER'=>array('family'=>'classify_supplier_order', 'position'=>62, 'enabled'=>'!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled)', 'picto'=>'order', 'warning'=>''),
|
||||
//Automatic classification reception
|
||||
'separator5'=>array('family'=>'separator', 'position'=>63),
|
||||
// Automatic classification reception
|
||||
'WORKFLOW_BILL_ON_RECEPTION'=>array('family'=>'classify_reception', 'position'=>64, 'enabled'=>'! empty($conf->reception->enabled) && (!empty($conf->fournisseur->enabled) && empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) || !empty($conf->supplier_order->enabled) || !empty($conf->supplier_invoice->enabled))', 'picto'=>'bill'),
|
||||
'separator6'=>array('family'=>'separator', 'position'=>90),
|
||||
// Automatic classification of intervention
|
||||
'WORKFLOW_TICKET_CLOSE_INTERVENTION'=>array('family'=>'classify_intervention', 'position'=>100, 'enabled'=>'! empty($conf->ticket->enabled) && !empty($conf->ficheinter->enabled)', 'picto'=>'intervention'),
|
||||
);
|
||||
|
||||
if (!empty($conf->modules_parts['workflow']) && is_array($conf->modules_parts['workflow']))
|
||||
@ -131,8 +137,8 @@ foreach ($workflowcodes as $key => $params)
|
||||
{
|
||||
print '<tr class="liste_titre">'."\n";
|
||||
print ' <td>';
|
||||
if ($family == 'create')
|
||||
{
|
||||
$reg = array();
|
||||
if ($family == 'create') {
|
||||
print $langs->trans("AutomaticCreation");
|
||||
} elseif (preg_match('/classify_(.*)/', $family, $reg))
|
||||
{
|
||||
@ -142,17 +148,18 @@ foreach ($workflowcodes as $key => $params)
|
||||
if ($reg[1] == 'supplier_proposal') print ' - '.$langs->trans('SupplierProposal');
|
||||
if ($reg[1] == 'supplier_order') print ' - '.$langs->trans('SupplierOrder');
|
||||
if ($reg[1] == 'reception') print ' - '.$langs->trans('Reception');
|
||||
if ($reg[1] == 'intervention') print ' - '.$langs->trans('Intervention');
|
||||
} else {
|
||||
print $langs->trans("Description");
|
||||
}
|
||||
print '</td>';
|
||||
print ' <td align="center">'.$langs->trans("Status").'</td>';
|
||||
print ' <td class="center" width="90px">'.$langs->trans("Status").'</td>';
|
||||
print "</tr>\n";
|
||||
$oldfamily = $family;
|
||||
}
|
||||
|
||||
print "<tr class=\"oddeven\">\n";
|
||||
print "<td>".img_object('', $picto).$langs->trans('desc'.$key);
|
||||
print "<td>".img_object('', $picto, 'class="paddingright"').$langs->trans('desc'.$key);
|
||||
if (!empty($params['warning']))
|
||||
{
|
||||
$langs->load("errors");
|
||||
|
||||
@ -53,7 +53,7 @@ $extrafields->fetch_name_optionals_label($object->table_element);
|
||||
$search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val)
|
||||
{
|
||||
|
||||
@ -331,7 +331,7 @@ class Asset extends CommonObject
|
||||
$label .= '<br>';
|
||||
$label .= '<b>'.$langs->trans('Ref').':</b> '.$this->ref;
|
||||
|
||||
$url = dol_buildpath('/assets/card.php', 1).'?id='.$this->id;
|
||||
$url = dol_buildpath('/asset/card.php', 1).'?id='.$this->id;
|
||||
|
||||
if ($option != 'nolink')
|
||||
{
|
||||
|
||||
@ -81,7 +81,7 @@ if ($user->socid > 0) // Protection if external user
|
||||
//$result = restrictedArea($user, 'asset', $id,'');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val)
|
||||
{
|
||||
@ -271,7 +271,7 @@ if ($num == 1 && !empty($conf->global->MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE) && $
|
||||
{
|
||||
$obj = $db->fetch_object($resql);
|
||||
$id = $obj->rowid;
|
||||
header("Location: ".DOL_URL_ROOT.'/assets/card.php?id='.$id);
|
||||
header("Location: ".DOL_URL_ROOT.'/asset/card.php?id='.$id);
|
||||
exit;
|
||||
}
|
||||
|
||||
|
||||
@ -77,6 +77,7 @@ if (GETPOST('button_removefilter_x', 'alpha') || GETPOST('button_removefilter_x'
|
||||
// Initialize technical object to manage hooks of page. Note that conf->hooks_modules contains array of hook context
|
||||
$hookmanager->initHooks(array('assettypecard', 'globalcard'));
|
||||
|
||||
$permissiontoadd = $user->rights->asset->setup_advance;
|
||||
|
||||
/*
|
||||
* Actions
|
||||
@ -211,14 +212,6 @@ if (!$rowid && $action != 'create' && $action != 'edit')
|
||||
|
||||
$param = '';
|
||||
|
||||
$newcardbutton = '';
|
||||
if ($user->rights->asset->configurer)
|
||||
{
|
||||
$newcardbutton = '<a class="butActionNew" href="'.DOL_URL_ROOT.'/asset/type.php?action=create"><span class="valignmiddle text-plus-circle">'.$langs->trans('NewAssetType').'</span>';
|
||||
$newcardbutton .= '<span class="fa fa-plus-circle valignmiddle"></span>';
|
||||
$newcardbutton .= '</a>';
|
||||
}
|
||||
|
||||
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||
if ($optioncss != '') print '<input type="hidden" name="optioncss" value="'.$optioncss.'">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
@ -228,6 +221,8 @@ if (!$rowid && $action != 'create' && $action != 'edit')
|
||||
print '<input type="hidden" name="page" value="'.$page.'">';
|
||||
print '<input type="hidden" name="sortorder" value="'.$sortorder.'">';
|
||||
|
||||
$newcardbutton = dolGetButtonTitle($langs->trans('NewAssetType'), '', 'fa fa-plus-circle', dol_buildpath('/asset/type.php', 1).'?action=create&backtopage='.urlencode($_SERVER['PHP_SELF']), '', $permissiontoadd);
|
||||
|
||||
print_barre_liste($langs->trans("AssetsTypes"), $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num, $nbtotalofrecords, 'accountancy', 0, $newcardbutton, '', $limit);
|
||||
|
||||
$moreforfilter = '';
|
||||
@ -238,9 +233,9 @@ if (!$rowid && $action != 'create' && $action != 'edit')
|
||||
print '<tr class="liste_titre">';
|
||||
print '<th>'.$langs->trans("Ref").'</th>';
|
||||
print '<th>'.$langs->trans("Label").'</th>';
|
||||
print '<th align="center">'.$langs->trans("AccountancyCodeAsset").'</th>';
|
||||
print '<th align="center">'.$langs->trans("AccountancyCodeDepreciationAsset").'</th>';
|
||||
print '<th align="center">'.$langs->trans("AccountancyCodeDepreciationExpense").'</th>';
|
||||
print '<th class="center">'.$langs->trans("AccountancyCodeAsset").'</th>';
|
||||
print '<th class="center">'.$langs->trans("AccountancyCodeDepreciationAsset").'</th>';
|
||||
print '<th class="center">'.$langs->trans("AccountancyCodeDepreciationExpense").'</th>';
|
||||
print '<th> </th>';
|
||||
print "</tr>\n";
|
||||
|
||||
@ -267,7 +262,7 @@ if (!$rowid && $action != 'create' && $action != 'edit')
|
||||
$accountingaccount = new AccountingAccount($db);
|
||||
$accountingaccount->fetch('', $objp->accountancy_code_asset, 1);
|
||||
|
||||
print $accountingaccount->getNomUrl(0, 0, 0, '', 0);
|
||||
print $accountingaccount->getNomUrl(0, 1, 1, '', 0);
|
||||
} else {
|
||||
print $objp->accountancy_code_asset;
|
||||
}
|
||||
@ -279,7 +274,7 @@ if (!$rowid && $action != 'create' && $action != 'edit')
|
||||
$accountingaccount2 = new AccountingAccount($db);
|
||||
$accountingaccount2->fetch('', $objp->accountancy_code_depreciation_asset, 1);
|
||||
|
||||
print $accountingaccount2->getNomUrl(0, 0, 0, '', 0);
|
||||
print $accountingaccount2->getNomUrl(0, 1, 1, '', 0);
|
||||
} else {
|
||||
print $objp->accountancy_code_depreciation_asset;
|
||||
}
|
||||
@ -291,7 +286,7 @@ if (!$rowid && $action != 'create' && $action != 'edit')
|
||||
$accountingaccount3 = new AccountingAccount($db);
|
||||
$accountingaccount3->fetch('', $objp->accountancy_code_depreciation_expense, 1);
|
||||
|
||||
print $accountingaccount3->getNomUrl(0, 0, 0, '', 0);
|
||||
print $accountingaccount3->getNomUrl(0, 1, 1, '', 0);
|
||||
} else {
|
||||
print $objp->accountancy_code_depreciation_expense;
|
||||
}
|
||||
|
||||
@ -57,7 +57,7 @@ $extrafields->fetch_name_optionals_label($object->table_element);
|
||||
$search_array_options = $extrafields->getOptionalsFromPost($object->table_element, '', 'search_');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val)
|
||||
{
|
||||
|
||||
@ -81,7 +81,7 @@ if ($user->socid > 0) // Protection if external user
|
||||
//$result = restrictedArea($user, 'bom', $id, '');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val)
|
||||
{
|
||||
|
||||
@ -251,7 +251,7 @@ if ($id > 0 && !preg_match('/^add/i', $action))
|
||||
print '</span>';
|
||||
}
|
||||
print '</td><td>';
|
||||
if ($action == 'edit') print '<input class="flat" name="url" size="80" value="'.(isset($_POST["url"]) ? $_POST["url"] : $object->url).'">';
|
||||
if ($action == 'edit') print '<input class="flat minwidth500" name="url" value="'.(isset($_POST["url"]) ? $_POST["url"] : $object->url).'">';
|
||||
else print '<a href="'.(preg_match('/^http/i', $object->url) ? $object->url : DOL_URL_ROOT.$object->url).'"'.($object->target ? ' target="_blank"' : '').'>'.$object->url.'</a>';
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
@ -257,10 +257,10 @@ if (empty($reshook) && $action == 'add')
|
||||
if (!$error)
|
||||
{
|
||||
// Initialisation objet actioncomm
|
||||
$object->priority = GETPOST("priority") ? GETPOST("priority") : 0;
|
||||
$object->priority = GETPOSTISSET("priority") ? GETPOST("priority", "int") : 0;
|
||||
$object->fulldayevent = (!empty($fulldayevent) ? 1 : 0);
|
||||
$object->location = GETPOST("location");
|
||||
$object->label = trim(GETPOST('label'));
|
||||
$object->location = GETPOST("location", 'alphanohtml');
|
||||
$object->label = GETPOST('label', 'alphanohtml');
|
||||
$object->fk_element = GETPOST("fk_element", 'int');
|
||||
$object->elementtype = GETPOST("elementtype", 'alpha');
|
||||
if (!GETPOST('label'))
|
||||
@ -487,7 +487,7 @@ if (empty($reshook) && $action == 'update')
|
||||
$object->datep = $datep;
|
||||
$object->datef = $datef;
|
||||
$object->percentage = $percentage;
|
||||
$object->priority = GETPOST("priority", "alphanohtml");
|
||||
$object->priority = GETPOST("priority", "int");
|
||||
$object->fulldayevent = GETPOST("fullday") ? 1 : 0;
|
||||
$object->location = GETPOST('location', "alphanohtml");
|
||||
$object->socid = GETPOST("socid", "int");
|
||||
@ -839,7 +839,6 @@ if ($action == 'create')
|
||||
$("#p2").removeAttr("disabled");
|
||||
}
|
||||
}
|
||||
setdatefields();
|
||||
$("#fullday").change(function() {
|
||||
console.log("setdatefields");
|
||||
setdatefields();
|
||||
@ -853,11 +852,25 @@ if ($action == 'create')
|
||||
{
|
||||
$("#doneby").val(-1);
|
||||
}
|
||||
});
|
||||
$("#actioncode").change(function() {
|
||||
});
|
||||
$("#actioncode").change(function() {
|
||||
if ($("#actioncode").val() == \'AC_RDV\') $("#dateend").addClass("fieldrequired");
|
||||
else $("#dateend").removeClass("fieldrequired");
|
||||
});
|
||||
});
|
||||
$("#aphour,#apmin").change(function() {
|
||||
if ($("#actioncode").val() == \'AC_RDV\') {
|
||||
console.log("Start date was changed, we modify end date "+(parseInt($("#aphour").val()))+" "+$("#apmin").val()+" -> "+("00" + (parseInt($("#aphour").val()) + 1)).substr(-2,2));
|
||||
$("#p2hour").val(("00" + (parseInt($("#aphour").val()) + 1)).substr(-2,2));
|
||||
$("#p2min").val($("#apmin").val());
|
||||
$("#p2day").val($("#apday").val());
|
||||
$("#p2month").val($("#apmonth").val());
|
||||
$("#p2year").val($("#apyear").val());
|
||||
$("#p2").val($("#ap").val());
|
||||
}
|
||||
});
|
||||
if ($("#actioncode").val() == \'AC_RDV\') $("#dateend").addClass("fieldrequired");
|
||||
else $("#dateend").removeClass("fieldrequired");
|
||||
setdatefields();
|
||||
})';
|
||||
print '</script>'."\n";
|
||||
}
|
||||
@ -880,8 +893,8 @@ if ($action == 'create')
|
||||
if (!empty($conf->global->AGENDA_USE_EVENT_TYPE))
|
||||
{
|
||||
print '<tr><td class="titlefieldcreate"><span class="fieldrequired">'.$langs->trans("Type").'</span></b></td><td>';
|
||||
$default = (empty($conf->global->AGENDA_USE_EVENT_TYPE_DEFAULT) ? '' : $conf->global->AGENDA_USE_EVENT_TYPE_DEFAULT);
|
||||
$formactions->select_type_actions(GETPOST("actioncode", 'aZ09') ?GETPOST("actioncode", 'aZ09') : ($object->type_code ? $object->type_code : $default), "actioncode", "systemauto", 0, -1);
|
||||
$default = (empty($conf->global->AGENDA_USE_EVENT_TYPE_DEFAULT) ? 'AC_RDV' : $conf->global->AGENDA_USE_EVENT_TYPE_DEFAULT);
|
||||
$formactions->select_type_actions(GETPOSTISSET("actioncode") ? GETPOST("actioncode", 'aZ09') : ($object->type_code ? $object->type_code : $default), "actioncode", "systemauto", 0, -1);
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
@ -1132,14 +1145,16 @@ if ($action == 'create')
|
||||
}
|
||||
|
||||
// Priority
|
||||
print '<tr><td class="titlefieldcreate nowrap">'.$langs->trans("Priority").'</td><td colspan="3">';
|
||||
print '<input type="text" name="priority" value="'.(GETPOST('priority') ?GETPOST('priority') : ($object->priority ? $object->priority : '')).'" size="5">';
|
||||
print '</td></tr>';
|
||||
if (! empty($conf->global->AGENDA_SUPPORT_PRIORITY_IN_EVENTS)) {
|
||||
print '<tr><td class="titlefieldcreate nowrap">'.$langs->trans("Priority").'</td><td colspan="3">';
|
||||
print '<input type="text" name="priority" value="'.(GETPOSTISSET('priority') ? GETPOST('priority', 'int') : ($object->priority ? $object->priority : '')).'" size="5">';
|
||||
print '</td></tr>';
|
||||
}
|
||||
|
||||
// Description
|
||||
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td><td>';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php';
|
||||
$doleditor = new DolEditor('note', (GETPOST('note', 'none') ? GETPOST('note', 'none') : $object->note_private), '', 180, 'dolibarr_notes', 'In', true, true, $conf->fckeditor->enabled, ROWS_4, '90%');
|
||||
$doleditor = new DolEditor('note', (GETPOSTISSET('note') ? GETPOST('note', 'none') : $object->note_private), '', 180, 'dolibarr_notes', 'In', true, true, $conf->fckeditor->enabled, ROWS_4, '90%');
|
||||
$doleditor->Create();
|
||||
print '</td></tr>';
|
||||
|
||||
@ -1175,7 +1190,7 @@ if ($action == 'create')
|
||||
|
||||
//Time Type
|
||||
print '<tr><td class="titlefieldcreate nowrap">'.$langs->trans("TimeType").'</td><td colspan="3">';
|
||||
print $form->select_type_duration('offsetunit');
|
||||
print $form->selectTypeDuration('offsetunit');
|
||||
print '</td></tr>';
|
||||
|
||||
//Reminder Type
|
||||
@ -1188,7 +1203,7 @@ if ($action == 'create')
|
||||
|
||||
//Mail Model
|
||||
print '<tr><td class="titlefieldcreate nowrap">'.$langs->trans("EMailTemplates").'</td><td colspan="3">';
|
||||
print $form->select_model_mail('actioncommsend', 'actioncomm_send');
|
||||
print $form->selectModelMail('actioncommsend', 'actioncomm_send');
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
@ -1204,15 +1219,15 @@ if ($action == 'create')
|
||||
$(".reminderparameters").hide();
|
||||
}
|
||||
});
|
||||
|
||||
$("#selectremindertype").click(function(){
|
||||
|
||||
$("#selectremindertype").click(function(){
|
||||
var selected_option = $("#selectremindertype option:selected").val();
|
||||
if(selected_option == "email") {
|
||||
$("#select_actioncommsendmodel_mail").closest("tr").show();
|
||||
} else {
|
||||
$("#select_actioncommsendmodel_mail").closest("tr").hide();
|
||||
};
|
||||
});
|
||||
});
|
||||
})';
|
||||
print '</script>'."\n";
|
||||
}
|
||||
@ -1893,7 +1908,7 @@ if ($id > 0)
|
||||
}
|
||||
|
||||
// Description
|
||||
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td><td colspan="3">';
|
||||
print '<tr><td class="tdtop">'.$langs->trans("Description").'</td><td colspan="3" class="wordbreak">';
|
||||
print dol_string_onlythesehtmltags(dol_htmlentitiesbr($object->note_private));
|
||||
print '</td></tr>';
|
||||
|
||||
|
||||
@ -672,12 +672,13 @@ class ActionComm extends CommonObject
|
||||
/**
|
||||
* Load object from database
|
||||
*
|
||||
* @param int $id Id of action to get
|
||||
* @param string $ref Ref of action to get
|
||||
* @param string $ref_ext Ref ext to get
|
||||
* @return int <0 if KO, >0 if OK
|
||||
* @param int $id Id of action to get
|
||||
* @param string $ref Ref of action to get
|
||||
* @param string $ref_ext Ref ext to get
|
||||
* @param string $email_msgid Email msgid
|
||||
* @return int <0 if KO, >0 if OK
|
||||
*/
|
||||
public function fetch($id, $ref = '', $ref_ext = '')
|
||||
public function fetch($id, $ref = '', $ref_ext = '', $email_msgid = '')
|
||||
{
|
||||
global $langs;
|
||||
|
||||
@ -698,6 +699,7 @@ class ActionComm extends CommonObject
|
||||
$sql .= " a.fk_contact, a.percent as percentage,";
|
||||
$sql .= " a.fk_element as elementid, a.elementtype,";
|
||||
$sql .= " a.priority, a.fulldayevent, a.location, a.transparency,";
|
||||
$sql .= " a.email_msgid, a.email_subject, a.email_from, a.email_to, a.email_tocc, a.email_tobcc, a.errors_to,";
|
||||
$sql .= " c.id as type_id, c.code as type_code, c.libelle as type_label, c.color as type_color, c.picto as type_picto,";
|
||||
$sql .= " s.nom as socname,";
|
||||
$sql .= " u.firstname, u.lastname as lastname";
|
||||
@ -706,9 +708,10 @@ class ActionComm extends CommonObject
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."user as u on u.rowid = a.fk_user_author";
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s on s.rowid = a.fk_soc";
|
||||
$sql .= " WHERE ";
|
||||
if ($ref) $sql .= " a.id=".$ref; // No field ref, we use id
|
||||
elseif ($ref_ext) $sql .= " a.ref_ext='".$this->db->escape($ref_ext)."'";
|
||||
else $sql .= " a.id=".$id;
|
||||
if ($ref) $sql .= " a.id = ".((int) $ref); // No field ref, we use id
|
||||
elseif ($ref_ext) $sql .= " a.ref_ext = '".$this->db->escape($ref_ext)."'";
|
||||
elseif ($email_msgid) $sql .= " a.email_msgid = '".$this->db->escape($email_msgid)."'";
|
||||
else $sql .= " a.id = ".((int) $id);
|
||||
|
||||
dol_syslog(get_class($this)."::fetch", LOG_DEBUG);
|
||||
$resql = $this->db->query($sql);
|
||||
@ -1396,6 +1399,8 @@ class ActionComm extends CommonObject
|
||||
$tooltip .= '<br><b>'.$langs->trans('Type').':</b> '.$labeltype;
|
||||
if (!empty($this->location))
|
||||
$tooltip .= '<br><b>'.$langs->trans('Location').':</b> '.$this->location;
|
||||
if (isset($this->transparency))
|
||||
$tooltip .= '<br><b>'.$langs->trans('Busy').':</b> '.yn($this->transparency);
|
||||
if (!empty($this->note_private))
|
||||
$tooltip .= '<br><b>'.$langs->trans('Note').':</b> '.(dol_textishtml($this->note_private) ? str_replace(array("\r", "\n"), "", $this->note_private) : str_replace(array("\r", "\n"), '<br>', $this->note_private));
|
||||
$linkclose = '';
|
||||
|
||||
@ -1061,12 +1061,21 @@ if (count($listofextcals))
|
||||
$event->id = $icalevent['UID'];
|
||||
$event->ref = $event->id;
|
||||
|
||||
$userId = $userstatic->findUserIdByEmail($namecal);
|
||||
if (!empty($userId) && $userId > 0)
|
||||
{
|
||||
$event->userassigned[$userId] = $userId;
|
||||
$event->percentage = -1;
|
||||
}
|
||||
else {
|
||||
$event->type_code = "ICALEVENT";
|
||||
}
|
||||
|
||||
$event->icalname = $namecal;
|
||||
$event->icalcolor = $colorcal;
|
||||
$usertime = 0; // We dont modify date because we want to have date into memory datep and datef stored as GMT date. Compensation will be done during output.
|
||||
$event->datep = $datestart + $usertime;
|
||||
$event->datef = $dateend + $usertime;
|
||||
$event->type_code = "ICALEVENT";
|
||||
|
||||
if ($icalevent['SUMMARY']) $event->label = $icalevent['SUMMARY'];
|
||||
elseif ($icalevent['DESCRIPTION']) $event->label = dol_nl2br($icalevent['DESCRIPTION'], 1);
|
||||
@ -1204,7 +1213,7 @@ if (empty($action) || $action == 'show_month') // View by month
|
||||
$i = 0;
|
||||
while ($i < 7)
|
||||
{
|
||||
print ' <td align="center">';
|
||||
print ' <td class="center bold uppercase">';
|
||||
$numdayinweek = (($i + (isset($conf->global->MAIN_START_WEEK) ? $conf->global->MAIN_START_WEEK : 1)) % 7);
|
||||
if (!empty($conf->dol_optimize_smallscreen))
|
||||
{
|
||||
@ -1284,7 +1293,7 @@ if (empty($action) || $action == 'show_month') // View by month
|
||||
print ' <tr class="liste_titre">';
|
||||
$i = 0;
|
||||
while ($i < 7) {
|
||||
echo ' <td align="center">'.$langs->trans("Day".(($i + (isset($conf->global->MAIN_START_WEEK) ? $conf->global->MAIN_START_WEEK : 1)) % 7))."</td>\n";
|
||||
echo ' <td class="center bold uppercase">'.$langs->trans("Day".(($i + (isset($conf->global->MAIN_START_WEEK) ? $conf->global->MAIN_START_WEEK : 1)) % 7))."</td>\n";
|
||||
$i++;
|
||||
}
|
||||
echo " </tr>\n";
|
||||
@ -1344,7 +1353,7 @@ if (empty($action) || $action == 'show_month') // View by month
|
||||
|
||||
echo ' <tr class="tagtr liste_titre">';
|
||||
echo ' <td class="tagtd width100"></td>';
|
||||
echo ' <td class="tagtd center">'.$langs->trans("Day".$arraytimestamp['wday'])."</td>\n";
|
||||
echo ' <td class="tagtd center bold uppercase">'.$langs->trans("Day".$arraytimestamp['wday'])."</td>\n";
|
||||
echo " </td>\n";
|
||||
|
||||
/*
|
||||
@ -1448,7 +1457,7 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa
|
||||
if ($nonew <= 0)
|
||||
{
|
||||
print '<div class="tagtr"><div class="nowrap float">';
|
||||
print '<a style="color: #666" href="'.DOL_URL_ROOT.'/comm/action/index.php?';
|
||||
print '<a class="dayevent-aday" style="color: #666" href="'.DOL_URL_ROOT.'/comm/action/index.php?';
|
||||
print 'action=show_day&day='.str_pad($day, 2, "0", STR_PAD_LEFT).'&month='.str_pad($month, 2, "0", STR_PAD_LEFT).'&year='.$year;
|
||||
print $newparam;
|
||||
print '">';
|
||||
@ -1615,10 +1624,12 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa
|
||||
// If colortouse is similar than background, we force to change it.
|
||||
if (empty($event->transparency) && empty($conf->global->AGENDA_NO_TRANSPARENT_ON_NOT_BUSY))
|
||||
{
|
||||
print 'border: 2px solid #'.$colortouse.';';
|
||||
print 'background: #f0f0f0;';
|
||||
print 'border-left: 5px solid #'.$colortouse.';';
|
||||
} else {
|
||||
print 'background: #'.$colortouse.';';
|
||||
print 'background: -webkit-gradient(linear, left top, left bottom, from(#'.dol_color_minus($colortouse, -3).'), to(#'.dol_color_minus($colortouse, -1).'));';
|
||||
print 'background: #f0f0f0;';
|
||||
print 'border-left: 5px solid #'.dol_color_minus($colortouse, -3).';';
|
||||
//print 'background: -webkit-gradient(linear, left top, left bottom, from(#'.dol_color_minus($colortouse, -3).'), to(#'.dol_color_minus($colortouse, -1).'));';
|
||||
}
|
||||
//print 'background: #'.$colortouse.';';
|
||||
//print 'background: -webkit-gradient(linear, left top, left bottom, from(#'.dol_color_minus($color, -3).'), to(#'.dol_color_minus($color, -1).'));';
|
||||
@ -1697,7 +1708,7 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa
|
||||
$event->label = $titletoshow;
|
||||
$event->libelle = $titletoshow;
|
||||
// Note: List of users are inside $event->userassigned. Link may be clickable depending on permissions of user.
|
||||
$titletoshow = $event->getNomUrl(0, $maxnbofchar, 'cal_event', '', 0, 0);
|
||||
$titletoshow = $event->getNomUrl(0, $maxnbofchar, 'cal_event cal_event_title', '', 0, 0);
|
||||
$event->label = $savlabel;
|
||||
$event->libelle = $savlabel;
|
||||
}
|
||||
|
||||
@ -688,7 +688,35 @@ while ($currentdaytoshow < $lastdaytoshow) {
|
||||
echo '<table width="100%" class="noborder nocellnopadd cal_month">';
|
||||
|
||||
echo '<tr class="liste_titre">';
|
||||
echo '<td></td>';
|
||||
echo '<td class="nopaddingtopimp nopaddingbottomimp">';
|
||||
|
||||
if ($canedit && $action == 'show_peruser')
|
||||
{
|
||||
// Filter on hours
|
||||
print img_picto('', 'clock', 'class="fawidth30 inline-block paddingleft"');
|
||||
print '<span class="hideonsmartphone" title="'.$langs->trans("VisibleTimeRange").'">'.$langs->trans("Hours").'</span>';
|
||||
print "\n".'<div class="ui-grid-a inline-block"><div class="ui-block-a">';
|
||||
print '<input type="number" class="short" name="begin_h" value="'.$begin_h.'" min="0" max="23">';
|
||||
if (empty($conf->dol_use_jmobile)) print ' - ';
|
||||
else print '</div><div class="ui-block-b">';
|
||||
print '<input type="number" class="short" name="end_h" value="'.$end_h.'" min="1" max="24">';
|
||||
if (empty($conf->dol_use_jmobile)) print ' '.$langs->trans("H");
|
||||
print '</div></div>';
|
||||
|
||||
print '<br>';
|
||||
|
||||
// Filter on days
|
||||
print img_picto('', 'clock', 'class="fawidth30 inline-block paddingleft"');
|
||||
print '<span class="hideonsmartphone" title="'.$langs->trans("VisibleDaysRange").'">'.$langs->trans("DaysOfWeek").'</span>';
|
||||
print "\n".'<div class="ui-grid-a inline-block"><div class="ui-block-a">';
|
||||
print '<input type="number" class="short" name="begin_d" value="'.$begin_d.'" min="1" max="7">';
|
||||
if (empty($conf->dol_use_jmobile)) print ' - ';
|
||||
else print '</div><div class="ui-block-b">';
|
||||
print '<input type="number" class="short" name="end_d" value="'.$end_d.'" min="1" max="7">';
|
||||
print '</div></div>';
|
||||
}
|
||||
|
||||
print '</td>';
|
||||
$i = 0; // 0 = sunday,
|
||||
while ($i < 7)
|
||||
{
|
||||
@ -698,7 +726,7 @@ while ($currentdaytoshow < $lastdaytoshow) {
|
||||
continue;
|
||||
}
|
||||
echo '<td align="center" colspan="'.($end_h - $begin_h).'">';
|
||||
echo '<span class="opacitymedium spandayofweek">'.$langs->trans("Day".(($i + (isset($conf->global->MAIN_START_WEEK) ? $conf->global->MAIN_START_WEEK : 1)) % 7)).'</span>';
|
||||
echo '<span class="bold spandayofweek">'.$langs->trans("Day".(($i + (isset($conf->global->MAIN_START_WEEK) ? $conf->global->MAIN_START_WEEK : 1)) % 7)).'</span>';
|
||||
print "<br>";
|
||||
if ($i) print dol_print_date(dol_time_plus_duree($currentdaytoshow, $i, 'd'), 'day');
|
||||
else print dol_print_date($currentdaytoshow, 'day');
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2004-2015 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2004-2020 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2004 Eric Seigne <eric.seigne@ryxeo.com>
|
||||
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
|
||||
* Copyright (C) 2005-2017 Regis Houssin <regis.houssin@inodbox.com>
|
||||
@ -64,7 +64,6 @@ if ($user->socid > 0) $id = $user->socid;
|
||||
$result = restrictedArea($user, 'societe', $id, '&societe');
|
||||
|
||||
$action = GETPOST('action', 'aZ09');
|
||||
$mode = GETPOST("mode");
|
||||
|
||||
$limit = GETPOST('limit', 'int') ? GETPOST('limit', 'int') : $conf->liste_limit;
|
||||
$sortfield = GETPOST("sortfield", 'alpha');
|
||||
|
||||
@ -1556,12 +1556,12 @@ if ($action == 'create')
|
||||
|
||||
// Terms of payment
|
||||
print '<tr><td class="nowrap">'.$langs->trans('PaymentConditionsShort').'</td><td>';
|
||||
$form->select_conditions_paiements($soc->cond_reglement_id, 'cond_reglement_id', -1, 1);
|
||||
$form->select_conditions_paiements((GETPOSTISSET('cond_reglement_id') ? GETPOST('cond_reglement_id', 'int') : $soc->cond_reglement_id), 'cond_reglement_id', -1, 1);
|
||||
print '</td></tr>';
|
||||
|
||||
// Mode of payment
|
||||
print '<tr><td>'.$langs->trans('PaymentMode').'</td><td>';
|
||||
$form->select_types_paiements($soc->mode_reglement_id, 'mode_reglement_id');
|
||||
$form->select_types_paiements((GETPOSTISSET('mode_reglement_id') ? GETPOST('mode_reglement_id', 'int') : $soc->mode_reglement_id), 'mode_reglement_id');
|
||||
print '</td></tr>';
|
||||
|
||||
// Bank Account
|
||||
|
||||
@ -78,7 +78,7 @@ $search_login = GETPOST('search_login', 'alpha');
|
||||
$search_product_category = GETPOST('search_product_category', 'int');
|
||||
$search_town = GETPOST('search_town', 'alpha');
|
||||
$search_zip = GETPOST('search_zip', 'alpha');
|
||||
$search_state = trim(GETPOST("search_state"));
|
||||
$search_state = GETPOST("search_state");
|
||||
$search_country = GETPOST("search_country", 'int');
|
||||
$search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
|
||||
$search_date_start = dol_mktime(0, 0, 0, GETPOST('search_date_startmonth', 'int'), GETPOST('search_date_startday', 'int'), GETPOST('search_date_startyear', 'int'));
|
||||
@ -88,7 +88,7 @@ $search_dateend_end = dol_mktime(23, 59, 59, GETPOST('search_dateend_endmonth',
|
||||
$search_datedelivery_start = dol_mktime(0, 0, 0, GETPOST('search_datedelivery_startmonth', 'int'), GETPOST('search_datedelivery_startday', 'int'), GETPOST('search_datedelivery_startyear', 'int'));
|
||||
$search_datedelivery_end = dol_mktime(23, 59, 59, GETPOST('search_datedelivery_endmonth', 'int'), GETPOST('search_datedelivery_endday', 'int'), GETPOST('search_datedelivery_endyear', 'int'));
|
||||
$search_availability = GETPOST('search_availability', 'int');
|
||||
$search_categ_cus = trim(GETPOST("search_categ_cus", 'int'));
|
||||
$search_categ_cus = GETPOST("search_categ_cus", 'int');
|
||||
$search_btn = GETPOST('button_search', 'alpha');
|
||||
$search_remove_btn = GETPOST('button_removefilter', 'alpha');
|
||||
|
||||
|
||||
@ -65,7 +65,7 @@ $search_ref_customer = GETPOST('search_ref_customer', 'alpha');
|
||||
$search_company = GETPOST('search_company', 'alpha');
|
||||
$search_town = GETPOST('search_town', 'alpha');
|
||||
$search_zip = GETPOST('search_zip', 'alpha');
|
||||
$search_state = trim(GETPOST("search_state"));
|
||||
$search_state = GETPOST("search_state");
|
||||
$search_country = GETPOST("search_country", 'int');
|
||||
$search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
|
||||
$sall = trim((GETPOST('search_all', 'alphanohtml') != '') ?GETPOST('search_all', 'alphanohtml') : GETPOST('sall', 'alphanohtml'));
|
||||
@ -82,7 +82,7 @@ $search_multicurrency_montant_ht = GETPOST('search_multicurrency_montant_ht', 'a
|
||||
$search_multicurrency_montant_vat = GETPOST('search_multicurrency_montant_vat', 'alpha');
|
||||
$search_multicurrency_montant_ttc = GETPOST('search_multicurrency_montant_ttc', 'alpha');
|
||||
$search_login = GETPOST('search_login', 'alpha');
|
||||
$search_categ_cus = trim(GETPOST("search_categ_cus", 'int'));
|
||||
$search_categ_cus = GETPOST("search_categ_cus", 'int');
|
||||
$optioncss = GETPOST('optioncss', 'alpha');
|
||||
$billed = GETPOST('billed', 'int');
|
||||
$search_status = GETPOST('search_status', 'int');
|
||||
@ -210,6 +210,7 @@ if (empty($reshook))
|
||||
$search_total_ht = '';
|
||||
$search_total_vat = '';
|
||||
$search_total_ttc = '';
|
||||
$search_warehouse = '';
|
||||
$search_multicurrency_code = '';
|
||||
$search_multicurrency_tx = '';
|
||||
$search_multicurrency_montant_ht = '';
|
||||
|
||||
@ -217,7 +217,7 @@ if ((GETPOST('confirm_savestatement', 'alpha') || GETPOST('confirm_reconcile', '
|
||||
$error = 0;
|
||||
|
||||
// Definition, nettoyage parametres
|
||||
$num_releve = trim(GETPOST("num_releve", "alpha"));
|
||||
$num_releve = GETPOST("num_releve", "alpha");
|
||||
|
||||
if ($num_releve)
|
||||
{
|
||||
|
||||
@ -98,7 +98,7 @@ if ($user->socid > 0) // Protection if external user
|
||||
//$result = restrictedArea($user, 'monmodule', $id, '');
|
||||
|
||||
// Initialize array of search criterias
|
||||
$search_all = trim(GETPOST("search_all", 'alpha'));
|
||||
$search_all = GETPOST("search_all", 'alpha');
|
||||
$search = array();
|
||||
foreach ($object->fields as $key => $val)
|
||||
{
|
||||
|
||||
@ -100,7 +100,7 @@ $search_module_source = GETPOST('search_module_source', 'alpha');
|
||||
$search_pos_source = GETPOST('search_pos_source', 'alpha');
|
||||
$search_town = GETPOST('search_town', 'alpha');
|
||||
$search_zip = GETPOST('search_zip', 'alpha');
|
||||
$search_state = trim(GETPOST("search_state"));
|
||||
$search_state = GETPOST("search_state");
|
||||
$search_country = GETPOST("search_country", 'int');
|
||||
$search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
|
||||
$search_user = GETPOST('search_user', 'int');
|
||||
@ -111,7 +111,7 @@ $search_date_valid_start = dol_mktime(0, 0, 0, GETPOST('search_date_valid_startm
|
||||
$search_date_valid_end = dol_mktime(23, 59, 59, GETPOST('search_date_valid_endmonth', 'int'), GETPOST('search_date_valid_endday', 'int'), GETPOST('search_date_valid_endyear', 'int'));
|
||||
$search_datelimit_start = dol_mktime(0, 0, 0, GETPOST('search_datelimit_startmonth', 'int'), GETPOST('search_datelimit_startday', 'int'), GETPOST('search_datelimit_startyear', 'int'));
|
||||
$search_datelimit_end = dol_mktime(23, 59, 59, GETPOST('search_datelimit_endmonth', 'int'), GETPOST('search_datelimit_endday', 'int'), GETPOST('search_datelimit_endyear', 'int'));
|
||||
$search_categ_cus = trim(GETPOST("search_categ_cus", 'int'));
|
||||
$search_categ_cus = GETPOST("search_categ_cus", 'int');
|
||||
$search_btn = GETPOST('button_search', 'alpha');
|
||||
$search_remove_btn = GETPOST('button_removefilter', 'alpha');
|
||||
|
||||
@ -1206,7 +1206,7 @@ if ($resql)
|
||||
// Ref
|
||||
if (!empty($arrayfields['f.ref']['checked']))
|
||||
{
|
||||
print '<td class="nowrap">';
|
||||
print '<td class="nowraponall">';
|
||||
|
||||
print '<table class="nobordernopadding"><tr class="nocellnopadd">';
|
||||
|
||||
@ -1242,7 +1242,7 @@ if ($resql)
|
||||
// Type
|
||||
if (!empty($arrayfields['f.type']['checked']))
|
||||
{
|
||||
print '<td class="nowrap">';
|
||||
print '<td class="nowraponall tdoverflowmax100" title="'.$facturestatic->getLibType().'">';
|
||||
print $facturestatic->getLibType();
|
||||
print "</td>";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
@ -1251,7 +1251,7 @@ if ($resql)
|
||||
// Date
|
||||
if (!empty($arrayfields['f.date']['checked']))
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td align="center" class="nowraponall">';
|
||||
print dol_print_date($db->jdate($obj->df), 'day');
|
||||
print '</td>';
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
@ -1260,7 +1260,7 @@ if ($resql)
|
||||
// Date
|
||||
if (!empty($arrayfields['f.date_valid']['checked']))
|
||||
{
|
||||
print '<td align="center" class="nowrap">';
|
||||
print '<td align="center" class="nowraponall">';
|
||||
print dol_print_date($db->jdate($obj->date_valid), 'day');
|
||||
print '</td>';
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
@ -1269,7 +1269,7 @@ if ($resql)
|
||||
// Date limit
|
||||
if (!empty($arrayfields['f.date_lim_reglement']['checked']))
|
||||
{
|
||||
print '<td align="center" class="nowrap">'.dol_print_date($datelimit, 'day');
|
||||
print '<td align="center" class="nowraponall">'.dol_print_date($datelimit, 'day');
|
||||
if ($facturestatic->hasDelay())
|
||||
{
|
||||
print img_warning($langs->trans('Alert').' - '.$langs->trans('Late'));
|
||||
@ -1281,7 +1281,7 @@ if ($resql)
|
||||
// Project ref
|
||||
if (!empty($arrayfields['p.ref']['checked']))
|
||||
{
|
||||
print '<td class="nocellnopadd nowrap">';
|
||||
print '<td class="nocellnopadd nowraponall">';
|
||||
if ($obj->project_id > 0)
|
||||
{
|
||||
print $projectstatic->getNomUrl(1);
|
||||
@ -1293,7 +1293,7 @@ if ($resql)
|
||||
// Project title
|
||||
if (!empty($arrayfields['p.title']['checked']))
|
||||
{
|
||||
print '<td class="nowrap">';
|
||||
print '<td class="nowraponall">';
|
||||
if ($obj->project_id > 0)
|
||||
{
|
||||
print $projectstatic->title;
|
||||
@ -1326,7 +1326,7 @@ if ($resql)
|
||||
// Zip
|
||||
if (!empty($arrayfields['s.zip']['checked']))
|
||||
{
|
||||
print '<td>';
|
||||
print '<td class="nowraponall">';
|
||||
print $obj->zip;
|
||||
print '</td>';
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
@ -1368,7 +1368,7 @@ if ($resql)
|
||||
// Payment mode
|
||||
if (!empty($arrayfields['f.fk_mode_reglement']['checked']))
|
||||
{
|
||||
print '<td>';
|
||||
print '<td class="tdoverflowmax100">';
|
||||
$form->form_modes_reglement($_SERVER['PHP_SELF'], $obj->fk_mode_reglement, 'none', '', -1);
|
||||
print '</td>';
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
@ -1404,7 +1404,7 @@ if ($resql)
|
||||
// Amount HT
|
||||
if (!empty($arrayfields['f.total_ht']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->total_ht)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->total_ht)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
if (!$i) $totalarray['pos'][$totalarray['nbfield']] = 'f.total_ht';
|
||||
$totalarray['val']['f.total_ht'] += $obj->total_ht;
|
||||
@ -1412,7 +1412,7 @@ if ($resql)
|
||||
// Amount VAT
|
||||
if (!empty($arrayfields['f.total_vat']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->total_vat)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->total_vat)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
if (!$i) $totalarray['pos'][$totalarray['nbfield']] = 'f.total_vat';
|
||||
$totalarray['val']['f.total_vat'] += $obj->total_vat;
|
||||
@ -1420,7 +1420,7 @@ if ($resql)
|
||||
// Amount LocalTax1
|
||||
if (!empty($arrayfields['f.total_localtax1']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->total_localtax1)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->total_localtax1)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
if (!$i) $totalarray['pos'][$totalarray['nbfield']] = 'f.total_localtax1';
|
||||
$totalarray['val']['f.total_localtax1'] += $obj->total_localtax1;
|
||||
@ -1428,7 +1428,7 @@ if ($resql)
|
||||
// Amount LocalTax2
|
||||
if (!empty($arrayfields['f.total_localtax2']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->total_localtax2)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->total_localtax2)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
if (!$i) $totalarray['pos'][$totalarray['nbfield']] = 'f.total_localtax2';
|
||||
$totalarray['val']['f.total_localtax2'] += $obj->total_localtax2;
|
||||
@ -1436,7 +1436,7 @@ if ($resql)
|
||||
// Amount TTC
|
||||
if (!empty($arrayfields['f.total_ttc']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->total_ttc)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->total_ttc)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
if (!$i) $totalarray['pos'][$totalarray['nbfield']] = 'f.total_ttc';
|
||||
$totalarray['val']['f.total_ttc'] += $obj->total_ttc;
|
||||
@ -1461,7 +1461,7 @@ if ($resql)
|
||||
|
||||
if (!empty($arrayfields['dynamount_payed']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.(!empty($totalpay) ?price($totalpay, 0, $langs) : ' ').'</td>'; // TODO Use a denormalized field
|
||||
print '<td class="right nowraponall">'.(!empty($totalpay) ?price($totalpay, 0, $langs) : ' ').'</td>'; // TODO Use a denormalized field
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
if (!$i) $totalarray['pos'][$totalarray['nbfield']] = 'totalam';
|
||||
$totalarray['val']['totalam'] += $totalpay;
|
||||
@ -1470,7 +1470,7 @@ if ($resql)
|
||||
// Pending amount
|
||||
if (!empty($arrayfields['rtp']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">';
|
||||
print '<td class="right nowraponall">';
|
||||
print (!empty($remaintopay) ? price($remaintopay, 0, $langs) : ' ');
|
||||
print '</td>'; // TODO Use a denormalized field
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
@ -1482,14 +1482,14 @@ if ($resql)
|
||||
// Currency
|
||||
if (!empty($arrayfields['f.multicurrency_code']['checked']))
|
||||
{
|
||||
print '<td class="nowrap">'.$obj->multicurrency_code.' - '.$langs->trans('Currency'.$obj->multicurrency_code)."</td>\n";
|
||||
print '<td class="nowraponall">'.$obj->multicurrency_code.' - '.$langs->trans('Currency'.$obj->multicurrency_code)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
// Currency rate
|
||||
if (!empty($arrayfields['f.multicurrency_tx']['checked']))
|
||||
{
|
||||
print '<td class="nowrap">';
|
||||
print '<td class="nowraponall">';
|
||||
$form->form_multicurrency_rate($_SERVER['PHP_SELF'].'?id='.$obj->rowid, $obj->multicurrency_tx, 'none', $obj->multicurrency_code);
|
||||
print "</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
@ -1497,31 +1497,31 @@ if ($resql)
|
||||
// Amount HT
|
||||
if (!empty($arrayfields['f.multicurrency_total_ht']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->multicurrency_total_ht)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->multicurrency_total_ht)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
}
|
||||
// Amount VAT
|
||||
if (!empty($arrayfields['f.multicurrency_total_vat']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->multicurrency_total_vat)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->multicurrency_total_vat)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
}
|
||||
// Amount TTC
|
||||
if (!empty($arrayfields['f.multicurrency_total_ttc']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.price($obj->multicurrency_total_ttc)."</td>\n";
|
||||
print '<td class="right nowraponall">'.price($obj->multicurrency_total_ttc)."</td>\n";
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
}
|
||||
if (!empty($arrayfields['multicurrency_dynamount_payed']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">'.(!empty($multicurrency_totalpay) ?price($multicurrency_totalpay, 0, $langs) : ' ').'</td>'; // TODO Use a denormalized field
|
||||
print '<td class="right nowraponall">'.(!empty($multicurrency_totalpay) ?price($multicurrency_totalpay, 0, $langs) : ' ').'</td>'; // TODO Use a denormalized field
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
}
|
||||
|
||||
// Pending amount
|
||||
if (!empty($arrayfields['multicurrency_rtp']['checked']))
|
||||
{
|
||||
print '<td class="right nowrap">';
|
||||
print '<td class="right nowraponall">';
|
||||
print (!empty($multicurrency_remaintopay) ? price($multicurrency_remaintopay, 0, $langs) : ' ');
|
||||
print '</td>'; // TODO Use a denormalized field
|
||||
if (!$i) $totalarray['nbfield']++;
|
||||
|
||||
@ -88,7 +88,7 @@ if (empty($local))
|
||||
}
|
||||
|
||||
|
||||
|
||||
$calc = 0;
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
@ -120,11 +120,11 @@ $calc = $conf->global->MAIN_INFO_LOCALTAX_CALC.$local;
|
||||
if ($calc == 0 || $calc == 1) // Calculate on invoice for goods and services
|
||||
{
|
||||
$calcmode = $calc == 0 ? $langs->trans("CalcModeLT".$local) : $langs->trans("CalcModeLT".$local."Rec");
|
||||
$calcmode .= '<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')';
|
||||
$calcmode .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')</span>';
|
||||
$period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0);
|
||||
if (!empty($conf->global->MAIN_MODULE_COMPTABILITE)) $description .= '<br>'.$langs->trans("WarningDepositsNotIncluded");
|
||||
$description .= $fsearch;
|
||||
$description .= '<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')';
|
||||
$description .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')</span>';
|
||||
$builddate = dol_now();
|
||||
|
||||
$elementcust = $langs->trans("CustomersInvoices");
|
||||
@ -137,11 +137,11 @@ if ($calc == 0 || $calc == 1) // Calculate on invoice for goods and services
|
||||
if ($calc == 2) // Invoice for goods, payment for services
|
||||
{
|
||||
$calcmode = $langs->trans("CalcModeLT2Debt");
|
||||
$calcmode .= '<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')';
|
||||
$calcmode .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')</span>';
|
||||
$period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0);
|
||||
if (!empty($conf->global->MAIN_MODULE_COMPTABILITE)) $description .= '<br>'.$langs->trans("WarningDepositsNotIncluded");
|
||||
$description .= $fsearch;
|
||||
$description .= '<br>('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')';
|
||||
$description .= '<span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')</span>';
|
||||
$builddate = dol_now();
|
||||
|
||||
$elementcust = $langs->trans("CustomersInvoices");
|
||||
@ -157,10 +157,12 @@ report_header($name, '', $period, $periodlink, $description, $builddate, $export
|
||||
$vatcust = $langs->transcountry($local == 1 ? "LT1" : "LT2", $mysoc->country_code);
|
||||
$vatsup = $langs->transcountry($local == 1 ? "LT1" : "LT2", $mysoc->country_code);
|
||||
|
||||
print '<div class="div-table-responsive">';
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
// IRPF that the customer has retained me
|
||||
if ($calc == 0 || $calc == 2)
|
||||
{
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td class="left">'.$langs->trans("Num").'</td>';
|
||||
print '<td class="left">'.$langs->trans("Customer").'</td>';
|
||||
@ -235,7 +237,6 @@ if ($calc == 0 || $calc == 2)
|
||||
|
||||
// IRPF I retained my supplier
|
||||
if ($calc == 0 || $calc == 1) {
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td class="left">'.$langs->trans("Num")."</td>";
|
||||
print '<td class="left">'.$langs->trans("Supplier")."</td>";
|
||||
@ -291,8 +292,6 @@ if ($calc == 0 || $calc == 1) {
|
||||
print '<td class="nowrap right">'.price($totalamount).'</td>';
|
||||
print '<td class="nowrap right">'.price($total).'</td>';
|
||||
print '</tr>';
|
||||
|
||||
print '</table>';
|
||||
} else {
|
||||
$langs->load("errors");
|
||||
if ($coll_list == -1)
|
||||
@ -305,15 +304,18 @@ if ($calc == 0 || $calc == 1) {
|
||||
|
||||
if ($calc == 0) {
|
||||
// Total to pay
|
||||
print '<br><br>';
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr><td colspan="5"></td></tr>';
|
||||
|
||||
$diff = $x_coll_sum - $x_paye_sum;
|
||||
print '<tr class="liste_total">';
|
||||
print '<td class="liste_total" colspan="4">'.$langs->trans("TotalToPay").($q ? ', '.$langs->trans("Quadri").' '.$q : '').'</td>';
|
||||
print '<td class="liste_total nowrap right"><b>'.price(price2num($diff, 'MT'))."</b></td>\n";
|
||||
print "</tr>\n";
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
print '</div>';
|
||||
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
|
||||
@ -227,10 +227,10 @@ $fsearch .= '<input type="hidden" name="modetax" value="'.$modetax.'">';
|
||||
$description = $fsearch;
|
||||
|
||||
// Show report header
|
||||
$name = $langs->trans("ReportByMonth");
|
||||
$name = $langs->transcountry($localTaxType == 1 ? "LT1ReportByMonth" : "LT2ReportByMonth", $mysoc->country_code);
|
||||
$description .= $langs->trans($LT);
|
||||
$calcmode = $langs->trans("LTReportBuildWithOptionDefinedInModule").' ';
|
||||
$calcmode .= '('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')<br>';
|
||||
$calcmode .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRulesLT", DOL_URL_ROOT.'/admin/company.php').')</span>';
|
||||
|
||||
//if (! empty($conf->global->MAIN_MODULE_ACCOUNTING)) $description.='<br>'.$langs->trans("ThisIsAnEstimatedValue");
|
||||
|
||||
|
||||
@ -134,7 +134,7 @@ $calcmode = '';
|
||||
if ($modetax == 0) $calcmode = $langs->trans('OptionVATDefault');
|
||||
if ($modetax == 1) $calcmode = $langs->trans('OptionVATDebitOption');
|
||||
if ($modetax == 2) $calcmode = $langs->trans('OptionPaymentForProductAndServices');
|
||||
$calcmode .= '<br>('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')';
|
||||
$calcmode .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')</span>';
|
||||
// Set period
|
||||
$period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0);
|
||||
$prevyear = $year_start;
|
||||
@ -200,12 +200,13 @@ if ($local == 1) {
|
||||
}
|
||||
|
||||
// VAT Received and paid
|
||||
print '<div class="div-table-responsive">';
|
||||
echo '<table class="noborder centpercent">';
|
||||
|
||||
$y = $year_current;
|
||||
$total = 0;
|
||||
$i = 0;
|
||||
$columns = 5;
|
||||
$columns = 4;
|
||||
|
||||
// Load arrays of datas
|
||||
$x_coll = tax_by_rate('localtax'.$local, $db, 0, 0, $date_start, $date_end, $modetax, 'sell');
|
||||
@ -310,8 +311,9 @@ if (!is_array($x_coll) || !is_array($x_paye))
|
||||
$x_paye_sum = 0;
|
||||
$x_paye_ht = 0;
|
||||
|
||||
$span = $columns;
|
||||
if ($modetax != 1) $span += 2;
|
||||
$span = $columns - 1;
|
||||
if ($modetax != 2) $span += 1;
|
||||
if ($modetax != 1) $span += 1;
|
||||
|
||||
// Customers invoices
|
||||
print '<tr class="liste_titre">';
|
||||
@ -467,10 +469,10 @@ if (!is_array($x_coll) || !is_array($x_paye))
|
||||
|
||||
// Blank line
|
||||
print '<tr><td colspan="'.($span + 1).'"> </td></tr>';
|
||||
print '</table>';
|
||||
//print '</table>';
|
||||
$diff = $x_coll_sum;
|
||||
|
||||
echo '<table class="noborder centpercent">';
|
||||
//echo '<table class="noborder centpercent">';
|
||||
//print table headers for this quadri - expenses now
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td class="left">'.$elementsup.'</td>';
|
||||
@ -617,11 +619,7 @@ if (!is_array($x_coll) || !is_array($x_paye))
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
|
||||
// Total to pay
|
||||
print '<br><br>';
|
||||
print '<table class="noborder centpercent">';
|
||||
$diff = $x_coll_sum - $x_paye_sum;
|
||||
print '<tr class="liste_total">';
|
||||
print '<td class="liste_total" colspan="'.$span.'">'.$langs->trans("TotalToPay").($q ? ', '.$langs->trans("Quadri").' '.$q : '').'</td>';
|
||||
@ -630,7 +628,9 @@ if (!is_array($x_coll) || !is_array($x_paye))
|
||||
|
||||
$i++;
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
print '</div>';
|
||||
|
||||
// End of page
|
||||
llxFooter();
|
||||
|
||||
@ -107,7 +107,7 @@ if (empty($reshook))
|
||||
if (substr($key, 0, 7) == 'amount_' && GETPOST($key) != '')
|
||||
{
|
||||
$cursorfacid = substr($key, 7);
|
||||
$amounts[$cursorfacid] = price2num(trim(GETPOST($key)));
|
||||
$amounts[$cursorfacid] = price2num(GETPOST($key));
|
||||
$totalpayment = $totalpayment + $amounts[$cursorfacid];
|
||||
if (!empty($amounts[$cursorfacid])) $atleastonepaymentnotnull++;
|
||||
$result = $tmpinvoice->fetch($cursorfacid);
|
||||
@ -134,7 +134,7 @@ if (empty($reshook))
|
||||
} elseif (substr($key, 0, 21) == 'multicurrency_amount_')
|
||||
{
|
||||
$cursorfacid = substr($key, 21);
|
||||
$multicurrency_amounts[$cursorfacid] = price2num(trim(GETPOST($key)));
|
||||
$multicurrency_amounts[$cursorfacid] = price2num(GETPOST($key));
|
||||
$multicurrency_totalpayment += $multicurrency_amounts[$cursorfacid];
|
||||
if (!empty($multicurrency_amounts[$cursorfacid])) $atleastonepaymentnotnull++;
|
||||
$result = $tmpinvoice->fetch($cursorfacid);
|
||||
|
||||
@ -9,6 +9,7 @@
|
||||
* Copyright (C) 2018 Ferran Marcet <fmarcet@2byte.es>
|
||||
* Copyright (C) 2018 Thibault FOUCART <support@ptibogxiv.net>
|
||||
* Copyright (C) 2018 Frédéric France <frederic.france@netlogic.fr>
|
||||
* Copyright (C) 2020 Andreu Bisquerra Gaya <jove@bisquerra.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -73,6 +74,8 @@ class Paiement extends CommonObject
|
||||
public $amounts = array(); // array: invoice ID => amount for that invoice (in the main currency)>
|
||||
public $multicurrency_amounts = array(); // array: invoice ID => amount for that invoice (in the invoice's currency)>
|
||||
|
||||
public $pos_change = 0; // Excess received in TakePOS cash payment
|
||||
|
||||
public $author;
|
||||
public $paiementid; // Type of payment. Id saved into fields fk_paiement on llx_paiement
|
||||
public $paiementcode; // Code of payment.
|
||||
@ -288,8 +291,9 @@ class Paiement extends CommonObject
|
||||
$num_payment = ($this->num_payment ? $this->num_payment : $this->num_paiement);
|
||||
$note = ($this->note_public ? $this->note_public : $this->note);
|
||||
|
||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."paiement (entity, ref, datec, datep, amount, multicurrency_amount, fk_paiement, num_paiement, note, ext_payment_id, ext_payment_site, fk_user_creat)";
|
||||
$sql .= " VALUES (".$conf->entity.", '".$this->db->escape($this->ref)."', '".$this->db->idate($now)."', '".$this->db->idate($this->datepaye)."', ".$total.", ".$mtotal.", ".$this->paiementid.", '".$this->db->escape($num_payment)."', '".$this->db->escape($note)."', ".($this->ext_payment_id ? "'".$this->db->escape($this->ext_payment_id)."'" : "null").", ".($this->ext_payment_site ? "'".$this->db->escape($this->ext_payment_site)."'" : "null").", ".$user->id.")";
|
||||
$sql = "INSERT INTO ".MAIN_DB_PREFIX."paiement (entity, ref, datec, datep, amount, multicurrency_amount, fk_paiement, num_paiement, note, ext_payment_id, ext_payment_site, fk_user_creat, pos_change)";
|
||||
$sql .= " VALUES (".$conf->entity.", '".$this->db->escape($this->ref)."', '".$this->db->idate($now)."', '".$this->db->idate($this->datepaye)."', ".$total.", ".$mtotal.", ".$this->paiementid.", ";
|
||||
$sql .= "'".$this->db->escape($num_payment)."', '".$this->db->escape($note)."', ".($this->ext_payment_id ? "'".$this->db->escape($this->ext_payment_id)."'" : "null").", ".($this->ext_payment_site ? "'".$this->db->escape($this->ext_payment_site)."'" : "null").", ".$user->id.", ".((int) $this->pos_change).")";
|
||||
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql)
|
||||
|
||||
@ -47,7 +47,7 @@ $optioncss = GETPOST('optioncss', 'aZ'); // Option for the css output (always '
|
||||
$type = GETPOST('type', 'aZ09');
|
||||
|
||||
$search_facture = GETPOST('search_facture', 'alpha');
|
||||
$search_societe = trim(GETPOST('search_societe', 'alpha'));
|
||||
$search_societe = GETPOST('search_societe', 'alpha');
|
||||
|
||||
// Load variable for pagination
|
||||
$limit = GETPOST('limit', 'int') ?GETPOST('limit', 'int') : $conf->liste_limit;
|
||||
|
||||
@ -181,6 +181,7 @@ $limit = 5;
|
||||
$sql = "SELECT p.rowid, p.ref, p.amount, p.datec, p.statut";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."prelevement_bons as p";
|
||||
$sql .= " WHERE p.type = 'debit-order'";
|
||||
$sql .= " AND entity IN (" . getEntity('prelevement') . ")";
|
||||
$sql .= " ORDER BY datec DESC";
|
||||
$sql .= $db->plimit($limit);
|
||||
|
||||
|
||||
@ -124,6 +124,7 @@ $product_static = new Product($db);
|
||||
$payment_static = new Paiement($db);
|
||||
$paymentfourn_static = new PaiementFourn($db);
|
||||
$paymentexpensereport_static = new PaymentExpenseReport($db);
|
||||
$user_static = new User($db);
|
||||
|
||||
$morequerystring = '';
|
||||
$listofparams = array('date_startmonth', 'date_startyear', 'date_startday', 'date_endmonth', 'date_endyear', 'date_endday');
|
||||
@ -151,7 +152,7 @@ $calcmode = '';
|
||||
if ($modetax == 0) $calcmode = $langs->trans('OptionVATDefault');
|
||||
if ($modetax == 1) $calcmode = $langs->trans('OptionVATDebitOption');
|
||||
if ($modetax == 2) $calcmode = $langs->trans('OptionPaymentForProductAndServices');
|
||||
$calcmode .= '<br>('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')';
|
||||
$calcmode .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')</span>';
|
||||
// Set period
|
||||
$period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0);
|
||||
$prevyear = $year_start;
|
||||
@ -216,7 +217,7 @@ $vatsup = $langs->trans("VATPaid");
|
||||
|
||||
|
||||
// VAT Received
|
||||
|
||||
print '<div class="div-table-responsive">';
|
||||
print "<table class=\"noborder\" width=\"100%\">";
|
||||
|
||||
$y = $year_current;
|
||||
@ -743,14 +744,12 @@ if (!is_array($x_coll) || !is_array($x_paye))
|
||||
print '</tr>';
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
|
||||
// Total to pay
|
||||
print '<br><br>';
|
||||
print '<table class="noborder centpercent">';
|
||||
print '<tr><td colspan="'.($span+2).'"></td></tr>';
|
||||
|
||||
$diff = $x_coll_sum - $x_paye_sum;
|
||||
print '<tr class="liste_total">';
|
||||
print '<td class="liste_total" colspan="'.$span.'">'.$langs->trans("TotalToPay").($q ? ', '.$langs->trans("Quadri").' '.$q : '').'</td>';
|
||||
print '<td class="liste_total" colspan="'.($span+1).'">'.$langs->trans("TotalToPay").($q ? ', '.$langs->trans("Quadri").' '.$q : '').'</td>';
|
||||
print '<td class="liste_total nowrap right"><b>'.price(price2num($diff, 'MT'))."</b></td>\n";
|
||||
print "</tr>\n";
|
||||
|
||||
@ -758,7 +757,7 @@ if (!is_array($x_coll) || !is_array($x_paye))
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
|
||||
print '</div>';
|
||||
|
||||
llxFooter();
|
||||
|
||||
|
||||
@ -220,12 +220,12 @@ $fsearch .= '<input type="hidden" name="modetax" value="'.$modetax.'">';
|
||||
$description = $fsearch;
|
||||
|
||||
// Show report header
|
||||
$name = $langs->trans("ReportByMonth");
|
||||
$name = $langs->trans("VATReportByMonth");
|
||||
$calcmode = '';
|
||||
if ($modetax == 0) $calcmode = $langs->trans('OptionVATDefault');
|
||||
if ($modetax == 1) $calcmode = $langs->trans('OptionVATDebitOption');
|
||||
if ($modetax == 2) $calcmode = $langs->trans('OptionPaymentForProductAndServices');
|
||||
$calcmode .= '<br>('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')';
|
||||
$calcmode .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')</span>';
|
||||
|
||||
$description .= $langs->trans("VATSummary").'<br>';
|
||||
if ($conf->global->TAX_MODE_SELL_PRODUCT == 'invoice') $description .= $langs->trans("RulesVATDueProducts");
|
||||
|
||||
@ -152,7 +152,7 @@ $calcmode = '';
|
||||
if ($modetax == 0) $calcmode = $langs->trans('OptionVATDefault');
|
||||
if ($modetax == 1) $calcmode = $langs->trans('OptionVATDebitOption');
|
||||
if ($modetax == 2) $calcmode = $langs->trans('OptionPaymentForProductAndServices');
|
||||
$calcmode .= '<br>('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')';
|
||||
$calcmode .= ' <span class="opacitymedium">('.$langs->trans("TaxModuleSetupToModifyRules", DOL_URL_ROOT.'/admin/taxes.php').')</span>';
|
||||
// Set period
|
||||
$period = $form->selectDate($date_start, 'date_start', 0, 0, 0, '', 1, 0).' - '.$form->selectDate($date_end, 'date_end', 0, 0, 0, '', 1, 0);
|
||||
$prevyear = $year_start; $prevquarter = $q;
|
||||
@ -213,6 +213,7 @@ $vatexpensereport = $langs->trans("VATPaid");
|
||||
|
||||
|
||||
// VAT Received and paid
|
||||
print '<div class="div-table-responsive">';
|
||||
print '<table class="noborder centpercent">';
|
||||
|
||||
$y = $year_current;
|
||||
@ -719,6 +720,7 @@ if (!is_array($x_coll) || !is_array($x_paye))
|
||||
}
|
||||
|
||||
print '</table>';
|
||||
print '</div>';
|
||||
|
||||
// Total to pay
|
||||
print '<br><br>';
|
||||
|
||||
@ -62,7 +62,7 @@ $sall = trim((GETPOST('search_all', 'alphanohtml') != '') ?GETPOST('search_all',
|
||||
$search_cti = preg_replace('/^0+/', '', preg_replace('/[^0-9]/', '', GETPOST('search_cti', 'alphanohtml'))); // Phone number without any special chars
|
||||
$search_phone = GETPOST("search_phone", 'alpha');
|
||||
|
||||
$search_id = trim(GETPOST("search_id", "int"));
|
||||
$search_id = GETPOST("search_id", "int");
|
||||
$search_firstlast_only = GETPOST("search_firstlast_only", 'alpha');
|
||||
$search_lastname = GETPOST("search_lastname", 'alpha');
|
||||
$search_firstname = GETPOST("search_firstname", 'alpha');
|
||||
|
||||
@ -1897,7 +1897,7 @@ if ($action == 'create')
|
||||
print '</tr>';
|
||||
|
||||
print '<tr class="oddeven">';
|
||||
print '<td class="nohover">'.$langs->trans("Comment").'</td><td colspan="3" class="nohover" colspan="'.($conf->margin->enabled ? 4 : 3).'"><input size="80" type="text" name="comment" value="'.$_POST["comment"].'"></td>';
|
||||
print '<td class="nohover">'.$langs->trans("Comment").'</td><td colspan="3" class="nohover" colspan="'.($conf->margin->enabled ? 4 : 3).'"><input type="text" class="minwidth300" name="comment" value="'.GETPOST("comment", 'alphanohtml').'"></td>';
|
||||
print '<td class="nohover right">';
|
||||
print '<input type="submit" class="button" name="activate" value="'.$langs->trans("Activate").'"> ';
|
||||
print '<input type="submit" class="button" name="cancel" value="'.$langs->trans("Cancel").'">';
|
||||
|
||||
@ -50,13 +50,13 @@ $search_name = GETPOST('search_name', 'alpha');
|
||||
$search_email = GETPOST('search_email', 'alpha');
|
||||
$search_town = GETPOST('search_town', 'alpha');
|
||||
$search_zip = GETPOST('search_zip', 'alpha');
|
||||
$search_state = trim(GETPOST("search_state", 'alpha'));
|
||||
$search_state = GETPOST("search_state", 'alpha');
|
||||
$search_country = GETPOST("search_country", 'int');
|
||||
$search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
|
||||
$search_contract = GETPOST('search_contract', 'alpha');
|
||||
$search_ref_customer = GETPOST('search_ref_customer', 'alpha');
|
||||
$search_ref_supplier = GETPOST('search_ref_supplier', 'alpha');
|
||||
$sall = trim((GETPOST('search_all', 'alphanohtml') != '') ?GETPOST('search_all', 'alphanohtml') : GETPOST('sall', 'alphanohtml'));
|
||||
$sall = (GETPOST('search_all', 'alphanohtml') != '') ? GETPOST('search_all', 'alphanohtml') : GETPOST('sall', 'alphanohtml');
|
||||
$search_status = GETPOST('search_status', 'alpha');
|
||||
$socid = GETPOST('socid', 'int');
|
||||
$search_user = GETPOST('search_user', 'int');
|
||||
|
||||
@ -199,7 +199,7 @@ $now = dol_now();
|
||||
|
||||
$form = new Form($db);
|
||||
|
||||
$sql = "SELECT c.rowid as cid, c.ref, c.statut as cstatut,";
|
||||
$sql = "SELECT c.rowid as cid, c.ref, c.statut as cstatut, c.ref_customer, c.ref_supplier,";
|
||||
$sql .= " s.rowid as socid, s.nom as name, s.email, s.client, s.fournisseur,";
|
||||
$sql .= " cd.rowid, cd.description, cd.statut,";
|
||||
$sql .= " p.rowid as pid, p.ref as pref, p.label as label, p.fk_product_type as ptype, p.entity as pentity,";
|
||||
@ -564,6 +564,8 @@ while ($i < min($num, $limit))
|
||||
|
||||
$contractstatic->id = $obj->cid;
|
||||
$contractstatic->ref = $obj->ref ? $obj->ref : $obj->cid;
|
||||
$contractstatic->ref_customer = $obj->ref_customer;
|
||||
$contractstatic->ref_supplier = $obj->ref_supplier;
|
||||
|
||||
$companystatic->id = $obj->socid;
|
||||
$companystatic->name = $obj->name;
|
||||
|
||||
@ -186,7 +186,7 @@ class dolReceiptPrinter extends Printer
|
||||
'dol_value_month' => 'DOL_VALUE_MONTH',
|
||||
'dol_value_day' => 'DOL_VALUE_DAY',
|
||||
'dol_value_day_letters' => 'DOL_VALUE_DAY',
|
||||
//'dol_print_payment',
|
||||
'dol_print_payment' => 'DOL_PRINT_PAYMENT',
|
||||
'dol_print_logo' => 'DOL_PRINT_LOGO',
|
||||
'dol_print_logo_old' => 'DOL_PRINT_LOGO_OLD',
|
||||
'dol_value_object_id' => 'InvoiceID',
|
||||
@ -775,6 +775,35 @@ class dolReceiptPrinter extends Printer
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'DOL_PRINT_PAYMENT':
|
||||
$sql = "SELECT p.pos_change as pos_change, p.datep as date, p.fk_paiement, p.num_paiement as num, pf.amount as amount, pf.multicurrency_amount,";
|
||||
$sql .= " cp.code";
|
||||
$sql .= " FROM ".MAIN_DB_PREFIX."paiement_facture as pf, ".MAIN_DB_PREFIX."paiement as p";
|
||||
$sql .= " LEFT JOIN ".MAIN_DB_PREFIX."c_paiement as cp ON p.fk_paiement = cp.id";
|
||||
$sql .= " WHERE pf.fk_paiement = p.rowid AND pf.fk_facture = ".$object->id;
|
||||
$sql .= " ORDER BY p.datep";
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
$num = $this->db->num_rows($resql);
|
||||
$i = 0;
|
||||
while ($i < $num) {
|
||||
$row = $this->db->fetch_object($resql);
|
||||
$spacestoadd = $nbcharactbyline - strlen($langs->transnoentitiesnoconv("PaymentTypeShort".$row->code)) - 12;
|
||||
$spaces = str_repeat(' ', $spacestoadd);
|
||||
$amount_payment=($conf->multicurrency->enabled && $object->multicurrency_tx != 1) ? $row->multicurrency_amount : $row->amount;
|
||||
if ($row->code == "LIQ") $amount_payment = $amount_payment + $row->pos_change; // Show amount with excess received if is cash payment
|
||||
$this->printer->text($spaces.$langs->transnoentitiesnoconv("PaymentTypeShort".$row->code).' '.str_pad(price($amount_payment), 10, ' ', STR_PAD_LEFT)."\n");
|
||||
if ($row->code == "LIQ" && $row->pos_change>0) // Print change only in cash payments
|
||||
{
|
||||
$spacestoadd = $nbcharactbyline - strlen($langs->trans("Change")) - 12;
|
||||
$spaces = str_repeat(' ', $spacestoadd);
|
||||
$this->printer->text($spaces.$langs->trans("Change").' '.str_pad(price($row->pos_change), 10, ' ', STR_PAD_LEFT)."\n");
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
$this->printer->text($vals[$tplline]['tag']);
|
||||
$this->printer->text($vals[$tplline]['value']);
|
||||
|
||||
@ -199,12 +199,12 @@ class Form
|
||||
if (preg_match('/^(string|safehtmlstring|email)/', $typeofdata))
|
||||
{
|
||||
$tmp = explode(':', $typeofdata);
|
||||
$ret .= '<input type="text" id="'.$htmlname.'" name="'.$htmlname.'" value="'.($editvalue ? $editvalue : $value).'"'.($tmp[1] ? ' size="'.$tmp[1].'"' : '').'>';
|
||||
$ret .= '<input type="text" id="'.$htmlname.'" name="'.$htmlname.'" value="'.($editvalue ? $editvalue : $value).'"'.($tmp[1] ? ' size="'.$tmp[1].'"' : '').' autofocus>';
|
||||
} elseif (preg_match('/^(numeric|amount)/', $typeofdata))
|
||||
{
|
||||
$tmp = explode(':', $typeofdata);
|
||||
$valuetoshow = price2num($editvalue ? $editvalue : $value);
|
||||
$ret .= '<input type="text" id="'.$htmlname.'" name="'.$htmlname.'" value="'.($valuetoshow != '' ?price($valuetoshow) : '').'"'.($tmp[1] ? ' size="'.$tmp[1].'"' : '').'>';
|
||||
$ret .= '<input type="text" id="'.$htmlname.'" name="'.$htmlname.'" value="'.($valuetoshow != '' ?price($valuetoshow) : '').'"'.($tmp[1] ? ' size="'.$tmp[1].'"' : '').' autofocus>';
|
||||
} elseif (preg_match('/^text/', $typeofdata) || preg_match('/^note/', $typeofdata)) // if wysiwyg is enabled $typeofdata = 'ckeditor'
|
||||
{
|
||||
$tmp = explode(':', $typeofdata);
|
||||
@ -217,7 +217,7 @@ class Form
|
||||
}
|
||||
|
||||
$valuetoshow = ($editvalue ? $editvalue : $value);
|
||||
$ret .= '<textarea id="'.$htmlname.'" name="'.$htmlname.'" wrap="soft" rows="'.($tmp[1] ? $tmp[1] : '20').'"'.($cols ? ' cols="'.$cols.'"' : 'class="quatrevingtpercent"').$morealt.'">';
|
||||
$ret .= '<textarea id="'.$htmlname.'" name="'.$htmlname.'" wrap="soft" rows="'.($tmp[1] ? $tmp[1] : '20').'"'.($cols ? ' cols="'.$cols.'"' : 'class="quatrevingtpercent"').$morealt.'" autofocus>';
|
||||
// textarea convert automatically entities chars into simple chars.
|
||||
// So we convert & into & so a string like 'a < <b>b</b><br>é<br><script>alert('X');<script>' stay a correct html and is not converted by textarea component when wysiwig is off.
|
||||
$valuetoshow = str_replace('&', '&', $valuetoshow);
|
||||
@ -1753,43 +1753,39 @@ class Form
|
||||
$out .= $userstatic->getFullName($langs, $fullNameMode, -1, $maxlength);
|
||||
|
||||
// Complete name with more info
|
||||
$moreinfo = 0;
|
||||
$moreinfo = '';
|
||||
if (!empty($conf->global->MAIN_SHOW_LOGIN))
|
||||
{
|
||||
$out .= ($moreinfo ? ' - ' : ' (').$obj->login;
|
||||
$moreinfo++;
|
||||
$moreinfo .= ($moreinfo ? ' - ' : ' (').$obj->login;
|
||||
}
|
||||
if ($showstatus >= 0)
|
||||
{
|
||||
if ($obj->statut == 1 && $showstatus == 1)
|
||||
{
|
||||
$out .= ($moreinfo ? ' - ' : ' (').$langs->trans('Enabled');
|
||||
$moreinfo++;
|
||||
$moreinfo .= ($moreinfo ? ' - ' : ' (').$langs->trans('Enabled');
|
||||
}
|
||||
if ($obj->statut == 0)
|
||||
{
|
||||
$out .= ($moreinfo ? ' - ' : ' (').$langs->trans('Disabled');
|
||||
$moreinfo++;
|
||||
$moreinfo .= ($moreinfo ? ' - ' : ' (').$langs->trans('Disabled');
|
||||
}
|
||||
}
|
||||
if (!empty($conf->multicompany->enabled) && empty($conf->global->MULTICOMPANY_TRANSVERSE_MODE) && $conf->entity == 1 && $user->admin && !$user->entity)
|
||||
{
|
||||
if (!$obj->entity)
|
||||
{
|
||||
$out .= ($moreinfo ? ' - ' : ' (').$langs->trans("AllEntities");
|
||||
$moreinfo++;
|
||||
$moreinfo .= ($moreinfo ? ' - ' : ' (').$langs->trans("AllEntities");
|
||||
} else {
|
||||
$out .= ($moreinfo ? ' - ' : ' (').($obj->label ? $obj->label : $langs->trans("EntityNameNotDefined"));
|
||||
$moreinfo++;
|
||||
$moreinfo .= ($moreinfo ? ' - ' : ' (').($obj->label ? $obj->label : $langs->trans("EntityNameNotDefined"));
|
||||
}
|
||||
}
|
||||
$out .= ($moreinfo ? ')' : '');
|
||||
$moreinfo .= ($moreinfo ? ')' : '');
|
||||
if ($disableline && $disableline != '1')
|
||||
{
|
||||
$out .= ' - '.$disableline; // This is text from $enableonlytext parameter
|
||||
$moreinfo .= ' - '.$disableline; // This is text from $enableonlytext parameter
|
||||
}
|
||||
$out .= $moreinfo;
|
||||
$out .= '</option>';
|
||||
$outarray[$userstatic->id] = $userstatic->getFullName($langs, $fullNameMode, -1, $maxlength);
|
||||
$outarray[$userstatic->id] = $userstatic->getFullName($langs, $fullNameMode, -1, $maxlength).$moreinfo;
|
||||
|
||||
$i++;
|
||||
}
|
||||
@ -5598,9 +5594,11 @@ class Form
|
||||
if ($addnowlink == 1)
|
||||
{
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'hour\').val(\''.dol_print_date(dol_now(), '%H', 'tzuser').'\');';
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'hour\').change();';
|
||||
} elseif ($addnowlink == 2)
|
||||
{
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'hour\').val(d.getHours().pad());';
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'hour\').change();';
|
||||
}
|
||||
|
||||
if ($fullday) $reset_scripts .= ' } ';
|
||||
@ -5613,9 +5611,11 @@ class Form
|
||||
if ($addnowlink == 1)
|
||||
{
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'min\').val(\''.dol_print_date(dol_now(), '%M', 'tzuser').'\');';
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'min\').change();';
|
||||
} elseif ($addnowlink == 2)
|
||||
{
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'min\').val(d.getMinutes().pad());';
|
||||
$reset_scripts .= 'jQuery(\'#'.$prefix.'min\').change();';
|
||||
}
|
||||
if ($fullday) $reset_scripts .= ' } ';
|
||||
}
|
||||
@ -5673,30 +5673,30 @@ class Form
|
||||
return $retstring;
|
||||
}
|
||||
|
||||
public function select_type_duration($prefix, $selected = 'minute'){
|
||||
|
||||
global $langs;
|
||||
|
||||
$retstring = '';
|
||||
/**
|
||||
* selectTypeDuration
|
||||
*
|
||||
* @param string $prefix Prefix
|
||||
* @param string $selected Selected type
|
||||
* @return string HTML select string
|
||||
*/
|
||||
public function selectTypeDuration($prefix, $selected = 'minute')
|
||||
{
|
||||
global $langs;
|
||||
|
||||
$TDurationTypes = array('year'=>$langs->trans('Years'), 'month'=>$langs->trans('Month'), 'week'=>$langs->trans('Weeks'), 'day'=>$langs->trans('Days'), 'hour'=>$langs->trans('Hours'), 'minute'=>$langs->trans('Minutes'));
|
||||
|
||||
$retstring .= '<select class="flat" id="select_'.$prefix.'type_duration" name="'.$prefix.'type_duration">';
|
||||
|
||||
foreach($TDurationTypes as $key=>$typeduration){
|
||||
|
||||
$retstring = '<select class="flat" id="select_'.$prefix.'type_duration" name="'.$prefix.'type_duration">';
|
||||
foreach ($TDurationTypes as $key=>$typeduration) {
|
||||
$retstring .= '<option value="'.$key.'"';
|
||||
if($key == $selected)
|
||||
{
|
||||
if ($key == $selected) {
|
||||
$retstring .= " selected";
|
||||
}
|
||||
$retstring .= ">".$typeduration."</option>";
|
||||
}
|
||||
|
||||
$retstring .= "</select>";
|
||||
|
||||
print $retstring;
|
||||
return;
|
||||
return $retstring;
|
||||
}
|
||||
|
||||
// phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps
|
||||
@ -6404,7 +6404,7 @@ class Form
|
||||
* @param string $htmlname Name of select
|
||||
* @param array $array Array with key+value
|
||||
* @param array $selected Array with key+value preselected
|
||||
* @param int $key_in_label 1 pour afficher la key dans la valeur "[key] value"
|
||||
* @param int $key_in_label 1 to show key like in "[key] value"
|
||||
* @param int $value_as_key 1 to use value as key
|
||||
* @param string $morecss Add more css style
|
||||
* @param int $translate Translate and encode value
|
||||
@ -6430,7 +6430,7 @@ class Form
|
||||
// Add code for jquery to use multiselect
|
||||
if (!empty($conf->global->MAIN_USE_JQUERY_MULTISELECT) || defined('REQUIRE_JQUERY_MULTISELECT'))
|
||||
{
|
||||
$out .= "\n".'<!-- JS CODE TO ENABLE '.$tmpplugin.' for id '.$htmlname.' -->
|
||||
$out .= "\n".'<!-- JS CODE TO ENABLE select for id '.$htmlname.' -->
|
||||
<script>'."\n";
|
||||
if ($addjscombo == 1)
|
||||
{
|
||||
@ -6491,15 +6491,16 @@ class Form
|
||||
{
|
||||
foreach ($array as $key => $value)
|
||||
{
|
||||
$newval = ($translate ? $langs->trans($value) : $value);
|
||||
$newval = ($key_in_label ? $key.' - '.$newval : $newval);
|
||||
|
||||
$out .= '<option value="'.$key.'"';
|
||||
if (is_array($selected) && !empty($selected) && in_array((string) $key, $selected) && ((string) $key != ''))
|
||||
{
|
||||
$out .= ' selected';
|
||||
}
|
||||
$out .= ' data-html="'.$newval.'"';
|
||||
$out .= '>';
|
||||
|
||||
$newval = ($translate ? $langs->trans($value) : $value);
|
||||
$newval = ($key_in_label ? $key.' - '.$newval : $newval);
|
||||
$out .= dol_htmlentitiesbr($newval);
|
||||
$out .= '</option>'."\n";
|
||||
}
|
||||
@ -7971,8 +7972,15 @@ class Form
|
||||
return $ret;
|
||||
}
|
||||
|
||||
public function select_model_mail($prefix, $modelType = ''){
|
||||
|
||||
/**
|
||||
* selectModelMail
|
||||
*
|
||||
* @param string $prefix Prefix
|
||||
* @param string $modelType Model type
|
||||
* @return string HTML select string
|
||||
*/
|
||||
public function selectModelMail($prefix, $modelType = '')
|
||||
{
|
||||
global $langs, $db, $user;
|
||||
|
||||
$retstring = '';
|
||||
@ -7983,24 +7991,21 @@ class Form
|
||||
$formmail = new FormMail($db);
|
||||
$result = $formmail->fetchAllEMailTemplate($modelType, $user, $langs);
|
||||
|
||||
if($result > 0){
|
||||
|
||||
foreach($formmail->lines_model as $model){
|
||||
if ($result > 0) {
|
||||
foreach ($formmail->lines_model as $model){
|
||||
$TModels[$model->id] = $model->label;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
$retstring .= '<select class="flat" id="select_'.$prefix.'model_mail" name="'.$prefix.'model_mail">';
|
||||
|
||||
foreach($TModels as $id_model=>$label_model){
|
||||
foreach ($TModels as $id_model=>$label_model){
|
||||
$retstring .= '<option value="'.$id_model.'"';
|
||||
$retstring .= ">".$label_model."</option>";
|
||||
}
|
||||
|
||||
$retstring .= "</select>";
|
||||
|
||||
print $retstring;
|
||||
return;
|
||||
return $retstring;
|
||||
}
|
||||
}
|
||||
|
||||
@ -58,9 +58,10 @@ class FormContract
|
||||
* @param string $htmlname Nom de la zone html
|
||||
* @param int $maxlength Maximum length of label
|
||||
* @param int $showempty Show empty line
|
||||
* @param int $showRef Show customer and supplier reference on each contract (when found)
|
||||
* @return int Nbr of project if OK, <0 if KO
|
||||
*/
|
||||
public function select_contract($socid = -1, $selected = '', $htmlname = 'contrattid', $maxlength = 16, $showempty = 1)
|
||||
public function select_contract($socid = -1, $selected = '', $htmlname = 'contrattid', $maxlength = 16, $showempty = 1, $showRef = 0)
|
||||
{
|
||||
// phpcs:enable
|
||||
global $db, $user, $conf, $langs;
|
||||
@ -69,7 +70,8 @@ class FormContract
|
||||
if (!empty($conf->global->CONTRACT_HIDE_UNSELECTABLES)) $hideunselectables = true;
|
||||
|
||||
// Search all contacts
|
||||
$sql = 'SELECT c.rowid, c.ref, c.fk_soc, c.statut';
|
||||
$sql = 'SELECT c.rowid, c.ref, c.fk_soc, c.statut,';
|
||||
$sql .= ' c.ref_customer, c.ref_supplier';
|
||||
$sql .= ' FROM '.MAIN_DB_PREFIX.'contrat as c';
|
||||
$sql .= " WHERE c.entity = ".$conf->entity;
|
||||
//if ($contratListId) $sql.= " AND c.rowid IN (".$contratListId.")";
|
||||
@ -105,6 +107,13 @@ class FormContract
|
||||
// Do nothing
|
||||
} else {
|
||||
$labeltoshow = dol_trunc($obj->ref, 18);
|
||||
|
||||
if ($showRef)
|
||||
{
|
||||
if ($obj->ref_customer) $labeltoshow = $labeltoshow." - ".$obj->ref_customer;
|
||||
if ($obj->ref_supplier) $labeltoshow = $labeltoshow." - ".$obj->ref_supplier;
|
||||
}
|
||||
|
||||
//if ($obj->public) $labeltoshow.=' ('.$langs->trans("SharedProject").')';
|
||||
//else $labeltoshow.=' ('.$langs->trans("Private").')';
|
||||
if (!empty($selected) && $selected == $obj->rowid && $obj->statut > 0)
|
||||
@ -166,9 +175,10 @@ class FormContract
|
||||
* @param string $htmlname Nom de la zone html
|
||||
* @param int $maxlength Maximum length of label
|
||||
* @param int $showempty Show empty line
|
||||
* @param int $showRef Show customer and supplier reference on each contract (when found)
|
||||
* @return int Nbr of project if OK, <0 if KO
|
||||
*/
|
||||
public function formSelectContract($page, $socid = -1, $selected = '', $htmlname = 'contrattid', $maxlength = 16, $showempty = 1)
|
||||
public function formSelectContract($page, $socid = -1, $selected = '', $htmlname = 'contrattid', $maxlength = 16, $showempty = 1, $showRef = 0)
|
||||
{
|
||||
global $langs;
|
||||
|
||||
@ -176,7 +186,7 @@ class FormContract
|
||||
print '<form method="post" action="'.$page.'">';
|
||||
print '<input type="hidden" name="action" value="setcontract">';
|
||||
print '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
$this->select_contract($socid, $selected, $htmlname, $maxlength, $showempty);
|
||||
$this->select_contract($socid, $selected, $htmlname, $maxlength, $showempty, $showRef);
|
||||
print '<input type="submit" class="button valignmiddle" value="'.$langs->trans("Modify").'">';
|
||||
print '</form>';
|
||||
}
|
||||
|
||||
@ -903,7 +903,7 @@ class FormTicket
|
||||
print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionarySetup"), 1);
|
||||
}
|
||||
print ' ';
|
||||
print '<input class="button" type="submit" value="'.$langs->trans('Use').'" name="modelselected" id="modelselected">';
|
||||
print '<input class="button" type="submit" value="'.$langs->trans('Apply').'" name="modelselected" id="modelselected">';
|
||||
print '</div></td>';
|
||||
}
|
||||
|
||||
@ -919,8 +919,7 @@ class FormTicket
|
||||
|
||||
// Subject
|
||||
print '<tr class="email_line"><td class="titlefieldcreate">'.$langs->trans('Subject').'</td>';
|
||||
$label_title = empty($conf->global->MAIN_APPLICATION_TITLE) ? $mysoc->name : $conf->global->MAIN_APPLICATION_TITLE;
|
||||
print '<td><input type="text" class="text" size="80" name="subject" value="['.$label_title.' - '.$langs->trans("Ticket").' #'.$this->ref.'] '.$langs->trans('TicketNewMessage').'" />';
|
||||
print '<td><input type="text" class="text minwidth500" name="subject" value="[' . $conf->global->MAIN_INFO_SOCIETE_NOM . ' - ' . $langs->trans("Ticket") . ' ' . $this->ref . '] '.$langs->trans('TicketNewMessage').'" />';
|
||||
print '</td></tr>';
|
||||
|
||||
// Destinataires
|
||||
|
||||
@ -41,7 +41,7 @@ class InfoBox
|
||||
{
|
||||
return array(
|
||||
0 => 'Home',
|
||||
27 => 'Accountancy Home'
|
||||
27 => 'AccountancyHome'
|
||||
);
|
||||
} else {
|
||||
return array(
|
||||
@ -72,7 +72,7 @@ class InfoBox
|
||||
24 => 'expensereportindex',
|
||||
25 => 'mailingindex',
|
||||
26 => 'opensurveyindex',
|
||||
27 => 'Accountancy Home'
|
||||
27 => 'AccountancyHome'
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@ -140,34 +140,6 @@ function print_actions_filter($form, $canedit, $status, $year, $month, $day, $sh
|
||||
print '</div>';
|
||||
}
|
||||
|
||||
if ($canedit && $action == 'show_peruser')
|
||||
{
|
||||
print '<div class="divsearchfield">';
|
||||
// Filter on hours
|
||||
print img_picto('', 'clock', 'class="fawidth30 inline-block"');
|
||||
print '<span class="hideonsmartphone">'.$langs->trans("VisibleTimeRange").'</span>';
|
||||
print "\n".'<div class="ui-grid-a inline-block"><div class="ui-block-a">';
|
||||
print '<input type="number" class="short" name="begin_h" value="'.$begin_h.'" min="0" max="23">';
|
||||
if (empty($conf->dol_use_jmobile)) print ' - ';
|
||||
else print '</div><div class="ui-block-b">';
|
||||
print '<input type="number" class="short" name="end_h" value="'.$end_h.'" min="1" max="24">';
|
||||
if (empty($conf->dol_use_jmobile)) print ' '.$langs->trans("H");
|
||||
print '</div></div>';
|
||||
print '</div>';
|
||||
|
||||
// Filter on days
|
||||
print '<div class="divsearchfield">';
|
||||
print img_picto('', 'clock', 'class="fawidth30 inline-block"');
|
||||
print '<span class="hideonsmartphone">'.$langs->trans("VisibleDaysRange").'</span>';
|
||||
print "\n".'<div class="ui-grid-a inline-block"><div class="ui-block-a">';
|
||||
print '<input type="number" class="short" name="begin_d" value="'.$begin_d.'" min="1" max="7">';
|
||||
if (empty($conf->dol_use_jmobile)) print ' - ';
|
||||
else print '</div><div class="ui-block-b">';
|
||||
print '<input type="number" class="short" name="end_d" value="'.$end_d.'" min="1" max="7">';
|
||||
print '</div></div>';
|
||||
print '</div>';
|
||||
}
|
||||
|
||||
// Hooks
|
||||
$parameters = array('canedit'=>$canedit, 'pid'=>$pid, 'socid'=>$socid);
|
||||
$object = null;
|
||||
|
||||
@ -88,10 +88,10 @@ function asset_prepare_head(Asset $object)
|
||||
// Show more tabs from modules
|
||||
// Entries must be declared in modules descriptor with line
|
||||
//$this->tabs = array(
|
||||
// 'entity:+tabname:Title:@assets:/assets/mypage.php?id=__ID__'
|
||||
// 'entity:+tabname:Title:@assets:/asset/mypage.php?id=__ID__'
|
||||
//); // to add new tab
|
||||
//$this->tabs = array(
|
||||
// 'entity:-tabname:Title:@assets:/assets/mypage.php?id=__ID__'
|
||||
// 'entity:-tabname:Title:@assets:/asset/mypage.php?id=__ID__'
|
||||
//); // to remove a tab
|
||||
complete_head_from_modules($conf, $langs, $object, $head, $h, 'assets');
|
||||
|
||||
|
||||
@ -2068,7 +2068,7 @@ function pdf_getTotalQty($object, $type, $outputlangs)
|
||||
*/
|
||||
function pdf_getLinkedObjects($object, $outputlangs)
|
||||
{
|
||||
global $hookmanager;
|
||||
global $db, $hookmanager;
|
||||
|
||||
$linkedobjects = array();
|
||||
|
||||
@ -2130,8 +2130,13 @@ function pdf_getLinkedObjects($object, $outputlangs)
|
||||
// We concat this record info into fields xxx_value. title is overwrote.
|
||||
if (empty($object->linkedObjects['commande']) && $object->element != 'commande') // There is not already a link to order and object is not the order, so we show also info with order
|
||||
{
|
||||
$elementobject->fetchObjectLinked();
|
||||
if (!empty($elementobject->linkedObjects['commande'])) $order = reset($elementobject->linkedObjects['commande']);
|
||||
$elementobject->fetchObjectLinked(null, '', null, '', 'OR', 1, 'sourcetype', 0);
|
||||
if (! empty($elementobject->linkedObjectsIds['commande'])){
|
||||
include_once DOL_DOCUMENT_ROOT.'/commande/class/commande.class.php';
|
||||
$order = new Commande($db);
|
||||
$ret = $order->fetch(reset($elementobject->linkedObjectsIds['commande']));
|
||||
if ($ret < 1) { $order=null; }
|
||||
}
|
||||
}
|
||||
if (!is_object($order))
|
||||
{
|
||||
|
||||
@ -2144,7 +2144,8 @@ function print_projecttasks_array($db, $form, $socid, $projectsListId, $mytasks
|
||||
if (empty($arrayidofprojects)) $arrayidofprojects[0] = -1;
|
||||
|
||||
// Get list of project with calculation on tasks
|
||||
$sql2 = "SELECT p.rowid as projectid, p.ref, p.title, p.fk_soc, s.nom as socname, p.fk_user_creat, p.public, p.fk_statut as status, p.fk_opp_status as opp_status, p.opp_percent, p.opp_amount,";
|
||||
$sql2 = "SELECT p.rowid as projectid, p.ref, p.title, p.fk_soc, s.nom as socname, s.email, s.client, s.fournisseur,";
|
||||
$sql2 .= " p.fk_user_creat, p.public, p.fk_statut as status, p.fk_opp_status as opp_status, p.opp_percent, p.opp_amount,";
|
||||
$sql2 .= " p.dateo, p.datee,";
|
||||
$sql2 .= " COUNT(t.rowid) as nb, SUM(t.planned_workload) as planned_workload, SUM(t.planned_workload * t.progress / 100) as declared_progess_workload";
|
||||
$sql2 .= " FROM ".MAIN_DB_PREFIX."projet as p";
|
||||
@ -2197,7 +2198,6 @@ function print_projecttasks_array($db, $form, $socid, $projectsListId, $mytasks
|
||||
if ($userAccess >= 0)
|
||||
{
|
||||
$projectstatic->ref = $objp->ref;
|
||||
$projectstatic->statut = $objp->status; // deprecated
|
||||
$projectstatic->status = $objp->status;
|
||||
$projectstatic->title = $objp->title;
|
||||
$projectstatic->datee = $db->jdate($objp->datee);
|
||||
@ -2216,6 +2216,9 @@ function print_projecttasks_array($db, $form, $socid, $projectsListId, $mytasks
|
||||
$thirdpartystatic->id = $objp->fk_soc;
|
||||
$thirdpartystatic->ref = $objp->socname;
|
||||
$thirdpartystatic->name = $objp->socname;
|
||||
$thirdpartystatic->client = $objp->client;
|
||||
$thirdpartystatic->fournisseur = $objp->fournisseur;
|
||||
$thirdpartystatic->email = $objp->email;
|
||||
print $thirdpartystatic->getNomUrl(1);
|
||||
}
|
||||
print '</td>';
|
||||
|
||||
@ -69,7 +69,7 @@ function report_header($reportname, $notused, $period, $periodlink, $description
|
||||
|
||||
// Ligne de titre
|
||||
print '<tr>';
|
||||
print '<td width="110">'.$langs->trans("ReportName").'</td>';
|
||||
print '<td width="150">'.$langs->trans("ReportName").'</td>';
|
||||
print '<td>';
|
||||
print $reportname;
|
||||
print '</td>';
|
||||
@ -80,7 +80,7 @@ function report_header($reportname, $notused, $period, $periodlink, $description
|
||||
if ($calcmode)
|
||||
{
|
||||
print '<tr>';
|
||||
print '<td width="110">'.$langs->trans("CalculationMode").'</td>';
|
||||
print '<td width="150">'.$langs->trans("CalculationMode").'</td>';
|
||||
print '<td>';
|
||||
print $calcmode;
|
||||
if ($variante) print '<td></td>';
|
||||
|
||||
@ -316,7 +316,7 @@ insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, left
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->asset->enabled && $leftmenu=="asset"', __HANDLER__, 'left', 3001__+MAX_llx_menu__, 'asset', '', 3000__+MAX_llx_menu__, '/asset/card.php?mainmenu=accountancy&leftmenu=asset&action=create', 'MenuNewAsset', 2, 'assets', '$user->rights->asset->write', '', 0, 21, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->asset->enabled && $leftmenu=="asset"', __HANDLER__, 'left', 3003__+MAX_llx_menu__, 'asset', '', 3000__+MAX_llx_menu__, '/asset/list.php?mainmenu=accountancy&leftmenu=asset', 'MenuListAssets', 2, 'assets', '$user->rights->asset->read', '', 0, 22, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->asset->enabled && $leftmenu=="asset"', __HANDLER__, 'left', 3004__+MAX_llx_menu__, 'asset', 'asset_type', 3000__+MAX_llx_menu__, '/asset/type.php?mainmenu=accountancy&leftmenu=asset', 'MenuTypeAssets', 2, 'assets', '$user->rights->asset->read', '', 0, 23, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->asset->enabled && $leftmenu=="asset"', __HANDLER__, 'left', 3005__+MAX_llx_menu__, 'asset', '', 3004__+MAX_llx_menu__, '/asset/type.php?mainmenu=accountancy&action=create', 'MenuNewTypeAssets', 3, 'assets', '$user->rights->asset->configurer', '', 0, 24, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->asset->enabled && $leftmenu=="asset"', __HANDLER__, 'left', 3005__+MAX_llx_menu__, 'asset', '', 3004__+MAX_llx_menu__, '/asset/type.php?mainmenu=accountancy&action=create', 'MenuNewTypeAssets', 3, 'assets', '$user->rights->asset->setup_advance', '', 0, 24, __ENTITY__);
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', '$conf->asset->enabled && $leftmenu=="asset"', __HANDLER__, 'left', 3006__+MAX_llx_menu__, 'asset', '', 3004__+MAX_llx_menu__, '/asset/type.php?mainmenu=accountancy', 'MenuListTypeAssets', 3, 'assets', '$user->rights->asset->read', '', 0, 25, __ENTITY__);
|
||||
-- Check deposit
|
||||
insert into llx_menu (module, enabled, menu_handler, type, rowid, mainmenu, leftmenu, fk_menu, url, titre, level, langs, perms, target, usertype, position, entity) values ('', 'empty($conf->global->BANK_DISABLE_CHECK_DEPOSIT) && ! empty($conf->banque->enabled) && (! empty($conf->facture->enabled) || ! empty($conf->global->MAIN_MENU_CHEQUE_DEPOSIT_ON))', __HANDLER__, 'left', 1711__+MAX_llx_menu__, 'accountancy', 'checks', 14__+MAX_llx_menu__, '/compta/paiement/cheque/index.php?mainmenu=bank&leftmenu=checks', 'MenuChequeDeposits', 0, 'bills', '$user->rights->banque->lire', '', 2, 9, __ENTITY__);
|
||||
|
||||
@ -1446,7 +1446,7 @@ function print_left_eldy_menu($db, $menu_array_before, $menu_array_after, &$tabM
|
||||
$newmenu->add("/asset/list.php?leftmenu=asset&mainmenu=accountancy", $langs->trans("MenuListAssets"), 1, $user->rights->asset->read);
|
||||
$newmenu->add("/asset/type.php?leftmenu=asset_type", $langs->trans("MenuTypeAssets"), 1, $user->rights->asset->read, '', $mainmenu, 'asset_type');
|
||||
if ($usemenuhider || empty($leftmenu) || preg_match('/asset_type/', $leftmenu)) {
|
||||
$newmenu->add("/asset/type.php?leftmenu=asset_type&action=create", $langs->trans("MenuNewTypeAssets"), 2, (empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->write) || (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->setup_advance));
|
||||
$newmenu->add("/asset/type.php?leftmenu=asset_type&action=create", $langs->trans("MenuNewTypeAssets"), 2, (!empty($conf->global->MAIN_USE_ADVANCED_PERMS) && $user->rights->asset->setup_advance));
|
||||
$newmenu->add("/asset/type.php?leftmenu=asset_type", $langs->trans("MenuListTypeAssets"), 2, $user->rights->asset->read);
|
||||
}
|
||||
}
|
||||
|
||||
@ -354,7 +354,7 @@ class pdf_standard extends ModeleExpenseReport
|
||||
$pdf->SetTextColor(0, 0, 0);
|
||||
|
||||
$pdf->setTopMargin($tab_top_newpage);
|
||||
if (empty($showpricebeforepagebreak)) {
|
||||
if (empty($showpricebeforepagebreak) && ($i !== ($nblines - 1))) {
|
||||
$pdf->setPageOrientation('', 1, $heightforfooter); // The only function to edit the bottom margin of current page to set it.
|
||||
} else {
|
||||
$pdf->setPageOrientation('', 1, $heightforfooter + $heightforfreetext + $heightforinfotot); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
@ -81,7 +81,7 @@ class modAsset extends DolibarrModules
|
||||
// Example: this->dirs = array("/asset/temp","/asset/subdir");
|
||||
$this->dirs = array();
|
||||
|
||||
// Config pages. Put here list of php page, stored into assets/admin directory, to use to setup module.
|
||||
// Config pages. Put here list of php page, stored into asset/admin directory, to use to setup module.
|
||||
$this->config_page_url = array("setup.php@asset");
|
||||
|
||||
// Dependencies
|
||||
@ -115,8 +115,8 @@ class modAsset extends DolibarrModules
|
||||
// Array to add new pages in new tabs
|
||||
$this->tabs = array();
|
||||
// Example:
|
||||
// $this->tabs[] = array('data'=>'objecttype:+tabname1:Title1:mylangfile@assets:$user->rights->assets->read:/assets/mynewtab1.php?id=__ID__'); // To add a new tab identified by code tabname1
|
||||
// $this->tabs[] = array('data'=>'objecttype:+tabname2:SUBSTITUTION_Title2:mylangfile@assets:$user->rights->othermodule->read:/assets/mynewtab2.php?id=__ID__', // To add another new tab identified by code tabname2. Label will be result of calling all substitution functions on 'Title2' key.
|
||||
// $this->tabs[] = array('data'=>'objecttype:+tabname1:Title1:mylangfile@assets:$user->rights->assets->read:/asset/mynewtab1.php?id=__ID__'); // To add a new tab identified by code tabname1
|
||||
// $this->tabs[] = array('data'=>'objecttype:+tabname2:SUBSTITUTION_Title2:mylangfile@assets:$user->rights->othermodule->read:/asset/mynewtab2.php?id=__ID__', // To add another new tab identified by code tabname2. Label will be result of calling all substitution functions on 'Title2' key.
|
||||
// $this->tabs[] = array('data'=>'objecttype:-tabname:NU:conditiontoremove'); // To remove an existing tab identified by code tabname
|
||||
//
|
||||
// Where objecttype can be
|
||||
@ -146,7 +146,7 @@ class modAsset extends DolibarrModules
|
||||
|
||||
|
||||
// Boxes/Widgets
|
||||
// Add here list of php file(s) stored in assets/core/boxes that contains class to show a widget.
|
||||
// Add here list of php file(s) stored in asset/core/boxes that contains class to show a widget.
|
||||
$this->boxes = array(
|
||||
//0=>array('file'=>'assetswidget1.php@asset','note'=>'Widget provided by Assets','enabledbydefaulton'=>'Home'),
|
||||
//1=>array('file'=>'assetswidget2.php@asset','note'=>'Widget provided by Assets'),
|
||||
|
||||
@ -392,7 +392,7 @@ class modEmailCollector extends DolibarrModules
|
||||
$sqlforexampleFilterC3 .= " VALUES ((SELECT rowid FROM ".MAIN_DB_PREFIX."emailcollector_emailcollector WHERE ref = 'Collect_Candidatures' and entity = ".$conf->entity."), 'to', 'jobs@example.com', '".$this->db->idate(dol_now())."', ".$user->id.", 1)";
|
||||
|
||||
$sqlforexampleC4 = "INSERT INTO ".MAIN_DB_PREFIX."emailcollector_emailcollectoraction (fk_emailcollector, type, actionparam, date_creation, fk_user_creat, status)";
|
||||
$sqlforexampleC4 .= " VALUES ((SELECT rowid FROM ".MAIN_DB_PREFIX."emailcollector_emailcollector WHERE ref = 'Collect_Candidatures' and entity = ".$conf->entity."), 'candidature', 'tmp_from=EXTRACT:HEADER:^From:(.*)<.*>;fk_recruitmentjobposition=EXTRACT:HEADER:^To:[^\n]*\+([^\n]*);description=EXTRACT:BODY:(.*);lastname=SET:__tmp_from__', '".$this->db->idate(dol_now())."', ".$user->id.", 1)";
|
||||
$sqlforexampleC4 .= " VALUES ((SELECT rowid FROM ".MAIN_DB_PREFIX."emailcollector_emailcollector WHERE ref = 'Collect_Candidatures' and entity = ".$conf->entity."), 'candidature', 'tmp_from=EXTRACT:HEADER:^From:(.*)(<.*>)?;fk_recruitmentjobposition=EXTRACT:HEADER:^To:[^\n]*\+([^\n]*);description=EXTRACT:BODY:(.*);lastname=SET:__tmp_from__', '".$this->db->idate(dol_now())."', ".$user->id.", 1)";
|
||||
|
||||
$sql[] = $sqlforexampleC1;
|
||||
$sql[] = $sqlforexampleFilterC1;
|
||||
|
||||
@ -261,13 +261,15 @@ class modSociete extends DolibarrModules
|
||||
$this->export_icon[$r] = 'company';
|
||||
$this->export_permission[$r] = array(array("societe", "export"));
|
||||
$this->export_fields_array[$r] = array(
|
||||
's.rowid'=>"Id", 's.nom'=>"Name", 's.name_alias'=>"AliasNameShort", 's.status'=>"Status", 's.client'=>"Customer", 's.fournisseur'=>"Supplier", 's.datec'=>"DateCreation", 's.tms'=>"DateLastModification",
|
||||
's.rowid'=>"Id", 's.nom'=>"Name", 's.name_alias'=>"AliasNameShort", 'ps.nom'=>"ParentCompany",
|
||||
's.status'=>"Status", 's.client'=>"Customer", 's.fournisseur'=>"Supplier", 's.datec'=>"DateCreation", 's.tms'=>"DateLastModification",
|
||||
's.code_client'=>"CustomerCode", 's.code_fournisseur'=>"SupplierCode", 's.code_compta'=>"AccountancyCode", 's.code_compta_fournisseur'=>"SupplierAccountancyCode",
|
||||
's.address'=>"Address", 's.zip'=>"Zip", 's.town'=>"Town", 'd.nom'=>'State', 'r.nom' => 'Region', 'c.label'=>"Country", 'c.code'=>"CountryCode", 's.phone'=>"Phone", 's.fax'=>"Fax",
|
||||
's.address'=>"Address", 's.zip'=>"Zip", 's.town'=>"Town", 'd.nom'=>'State', 'r.nom'=>'Region', 'c.label'=>"Country", 'c.code'=>"CountryCode", 's.phone'=>"Phone", 's.fax'=>"Fax",
|
||||
's.url'=>"Url", 's.email'=>"Email", 's.default_lang'=>"DefaultLang", 's.siren'=>"ProfId1", 's.siret'=>"ProfId2", 's.ape'=>"ProfId3", 's.idprof4'=>"ProfId4",
|
||||
's.idprof5'=>"ProfId5", 's.idprof6'=>"ProfId6", 's.tva_intra'=>"VATIntraShort", 's.capital'=>"Capital", 's.note_private'=>"NotePrivate", 's.note_public'=>"NotePublic",
|
||||
't.libelle'=>"ThirdPartyType", 'ce.code'=>"Staff", "cfj.libelle"=>"JuridicalStatus", 's.fk_prospectlevel'=>'ProspectLevel',
|
||||
'st.code'=>'ProspectStatus', 'payterm.libelle'=>'PaymentConditions', 'paymode.libelle'=>'PaymentMode'
|
||||
'st.code'=>'ProspectStatus', 'payterm.libelle'=>'PaymentConditions', 'paymode.libelle'=>'PaymentMode',
|
||||
's.outstanding_limit'=>'OutstandingBill', 'pbacc.ref'=>'PaymentBankAccount', 'incoterm.code'=>'IncotermLabel'
|
||||
);
|
||||
if (!empty($conf->global->SOCIETE_USEPREFIX)) $this->export_fields_array[$r]['s.prefix'] = 'Prefix';
|
||||
if (!empty($conf->global->PRODUIT_MULTIPRICES)) $this->export_fields_array[$r]['s.price_level'] = 'PriceLevel';
|
||||
@ -280,6 +282,7 @@ class modSociete extends DolibarrModules
|
||||
$keyforselect = 'societe'; $keyforelement = 'company'; $keyforaliasextra = 'extra';
|
||||
include DOL_DOCUMENT_ROOT.'/core/extrafieldsinexport.inc.php';
|
||||
$this->export_fields_array[$r] += array('u.login'=>'SaleRepresentativeLogin', 'u.firstname'=>'SaleRepresentativeFirstname', 'u.lastname'=>'SaleRepresentativeLastname');
|
||||
|
||||
//$this->export_TypeFields_array[$r]=array(
|
||||
// 's.rowid'=>"List:societe:nom",'s.nom'=>"Text",'s.status'=>"Text",'s.client'=>"Boolean",'s.fournisseur'=>"Boolean",'s.datec'=>"Date",'s.tms'=>"Date",
|
||||
// 's.code_client'=>"Text",'s.code_fournisseur'=>"Text",'s.address'=>"Text",'s.zip'=>"Text",'s.town'=>"Text",'c.label'=>"List:c_country:label:label",
|
||||
@ -289,15 +292,17 @@ class modSociete extends DolibarrModules
|
||||
// 's.fk_stcomm'=>'List:c_stcomm:libelle:code','d.nom'=>'List:c_departements:nom:rowid'
|
||||
//);
|
||||
$this->export_TypeFields_array[$r] = array(
|
||||
's.rowid'=>"Numeric", 's.nom'=>"Text", 's.name_alias'=>"Text", 's.status'=>"Numeric", 's.client'=>"Numeric", 's.fournisseur'=>"Boolean", 's.datec'=>"Date", 's.tms'=>"Date",
|
||||
's.code_client'=>"Text", 's.code_fournisseur'=>"Text", 's.code_compta'=>"Text", 's.code_compta_fournisseur'=>"Text", 's.address'=>"Text", 's.zip'=>"Text",
|
||||
's.town'=>"Text", 'c.label'=>"List:c_country:label:label", 'c.code'=>"Text", 's.phone'=>"Text", 's.fax'=>"Text", 's.url'=>"Text", 's.email'=>"Text",
|
||||
's.default_lang'=>"Text", 's.siret'=>"Text", 's.siren'=>"Text", 's.ape'=>"Text", 's.idprof4'=>"Text", 's.idprof5'=>"Text", 's.idprof6'=>"Text",
|
||||
's.tva_intra'=>"Text", 's.capital'=>"Numeric", 's.note_private'=>"Text", 's.note_public'=>"Text", 't.libelle'=>"Text",
|
||||
'ce.code'=>"List:c_effectif:libelle:code", "cfj.libelle"=>"Text", 's.fk_prospectlevel'=>'List:c_prospectlevel:label:code',
|
||||
'st.code'=>'List:c_stcomm:libelle:code', 'd.nom'=>'Text', 'r.nom' => 'Text', 'u.login'=>'Text', 'u.firstname'=>'Text', 'u.lastname'=>'Text', 'payterm.libelle'=>'Text',
|
||||
'paymode.libelle'=>'Text', 's.entity'=>'Numeric',
|
||||
's.price_level'=>'Numeric'
|
||||
's.rowid'=>"Numeric", 's.nom'=>"Text", 's.name_alias'=>"Text", 'ps.nom'=>"Text",
|
||||
's.status'=>"Numeric", 's.client'=>"Numeric", 's.fournisseur'=>"Boolean", 's.datec'=>"Date", 's.tms'=>"Date",
|
||||
's.code_client'=>"Text", 's.code_fournisseur'=>"Text", 's.code_compta'=>"Text", 's.code_compta_fournisseur'=>"Text",
|
||||
's.address'=>"Text", 's.zip'=>"Text",'s.town'=>"Text", 'd.nom'=>'Text', 'r.nom'=>'Text', 'c.label'=>"List:c_country:label:label", 'c.code'=>"Text", 's.phone'=>"Text", 's.fax'=>"Text",
|
||||
's.url'=>"Text", 's.email'=>"Text", 's.default_lang'=>"Text", 's.siret'=>"Text", 's.siren'=>"Text", 's.ape'=>"Text", 's.idprof4'=>"Text",
|
||||
's.idprof5'=>"Text", 's.idprof6'=>"Text", 's.tva_intra'=>"Text", 's.capital'=>"Numeric", 's.note_private'=>"Text", 's.note_public'=>"Text",
|
||||
't.libelle'=>"Text", 'ce.code'=>"List:c_effectif:libelle:code", "cfj.libelle"=>"Text", 's.fk_prospectlevel'=>'List:c_prospectlevel:label:code',
|
||||
'st.code'=>'List:c_stcomm:libelle:code', 'payterm.libelle'=>'Text', 'paymode.libelle'=>'Text',
|
||||
's.outstanding_limit'=>'Numeric', 'pbacc.ref'=>'Text', 'incoterm.code'=>'Text',
|
||||
'u.login'=>'Text', 'u.firstname'=>'Text', 'u.lastname'=>'Text',
|
||||
's.entity'=>'Numeric', 's.price_level'=>'Numeric'
|
||||
);
|
||||
|
||||
$this->export_entities_array[$r] = array('u.login'=>'user', 'u.firstname'=>'user', 'u.lastname'=>'user'); // We define here only fields that use another picto
|
||||
@ -305,16 +310,19 @@ class modSociete extends DolibarrModules
|
||||
$this->export_sql_start[$r] = 'SELECT DISTINCT ';
|
||||
$this->export_sql_end[$r] = ' FROM '.MAIN_DB_PREFIX.'societe as s';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_extrafields as extra ON s.rowid = extra.fk_object';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe as ps ON s.parent = ps.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_typent as t ON s.fk_typent = t.id';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_country as c ON s.fk_pays = c.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_effectif as ce ON s.fk_effectif = ce.id';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_forme_juridique as cfj ON s.fk_forme_juridique = cfj.code';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_departements as d ON s.fk_departement = d.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'c_regions as r ON r.code_region = d.fk_region AND r.fk_pays = s.fk_pays';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_regions as r ON r.code_region = d.fk_region AND r.fk_pays = s.fk_pays';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_stcomm as st ON s.fk_stcomm = st.id';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_commerciaux as sc ON sc.fk_soc = s.rowid LEFT JOIN '.MAIN_DB_PREFIX.'user as u ON sc.fk_user = u.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_payment_term as payterm ON s.cond_reglement = payterm.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_paiement as paymode ON s.mode_reglement = paymode.id';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'bank_account as pbacc ON s.fk_account = pbacc.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_incoterms as incoterm ON s.fk_incoterms = incoterm.rowid';
|
||||
$this->export_sql_end[$r] .= ' WHERE s.entity IN ('.getEntity('societe').')';
|
||||
if (is_object($user) && empty($user->rights->societe->client->voir)) {
|
||||
$this->export_sql_end[$r] .= ' AND (sc.fk_user = '.$user->id.' ';
|
||||
@ -334,7 +342,7 @@ class modSociete extends DolibarrModules
|
||||
$this->export_fields_array[$r] = array(
|
||||
'c.rowid'=>"IdContact", 'c.civility'=>"CivilityCode", 'c.lastname'=>'Lastname', 'c.firstname'=>'Firstname', 'c.poste'=>'PostOrFunction',
|
||||
'c.datec'=>"DateCreation", 'c.tms'=>"DateLastModification", 'c.priv'=>"ContactPrivate", 'c.address'=>"Address", 'c.zip'=>"Zip", 'c.town'=>"Town",
|
||||
'd.nom'=>'State', 'r.nom' => 'Region', 'co.label'=>"Country", 'co.code'=>"CountryCode", 'c.phone'=>"Phone", 'c.fax'=>"Fax", 'c.phone_mobile'=>"Mobile", 'c.email'=>"EMail",
|
||||
'd.nom'=>'State', 'r.nom'=>'Region', 'co.label'=>"Country", 'co.code'=>"CountryCode", 'c.phone'=>"Phone", 'c.fax'=>"Fax", 'c.phone_mobile'=>"Mobile", 'c.email'=>"EMail",
|
||||
'c.statut'=>"Status",
|
||||
's.rowid'=>"IdCompany", 's.nom'=>"CompanyName", 's.status'=>"Status", 's.code_client'=>"CustomerCode", 's.code_fournisseur'=>"SupplierCode",
|
||||
's.code_compta'=>"AccountancyCode", 's.code_compta_fournisseur'=>"SupplierAccountancyCode",
|
||||
@ -345,7 +353,7 @@ class modSociete extends DolibarrModules
|
||||
$this->export_examplevalues_array[$r] = array('s.client'=>'0 (no customer no prospect)/1 (customer)/2 (prospect)/3 (customer and prospect)', 's.fournisseur'=>'0 (not a supplier) or 1 (supplier)');
|
||||
$this->export_TypeFields_array[$r] = array(
|
||||
'c.civility'=>"List:c_civility:label:code", 'c.lastname'=>'Text', 'c.firstname'=>'Text', 'c.poste'=>'Text', 'c.datec'=>"Date", 'c.priv'=>"Boolean",
|
||||
'c.address'=>"Text", 'c.zip'=>"Text", 'c.town'=>"Text", 'd.nom'=>'Text', 'r.nom' => 'Text', 'co.label'=>"List:c_country:label:rowid", 'co.code'=>"Text", 'c.phone'=>"Text",
|
||||
'c.address'=>"Text", 'c.zip'=>"Text", 'c.town'=>"Text", 'd.nom'=>'Text', 'r.nom'=>'Text', 'co.label'=>"List:c_country:label:rowid", 'co.code'=>"Text", 'c.phone'=>"Text",
|
||||
'c.fax'=>"Text", 'c.email'=>"Text",
|
||||
'c.statut'=>"Status",
|
||||
's.rowid'=>"List:societe:nom::thirdparty", 's.nom'=>"Text", 's.status'=>"Status", 's.code_client'=>"Text", 's.code_fournisseur'=>"Text",
|
||||
@ -376,7 +384,7 @@ class modSociete extends DolibarrModules
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_extrafields as extrasoc ON s.rowid = extrasoc.fk_object';
|
||||
if (is_object($user) && empty($user->rights->societe->client->voir)) $this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'societe_commerciaux as sc ON sc.fk_soc = s.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_departements as d ON c.fk_departement = d.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN ' . MAIN_DB_PREFIX . 'c_regions as r ON r.code_region = d.fk_region AND r.fk_pays = c.fk_pays';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_regions as r ON r.code_region = d.fk_region AND r.fk_pays = c.fk_pays';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_country as co ON c.fk_pays = co.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'socpeople_extrafields as extra ON extra.fk_object = c.rowid';
|
||||
$this->export_sql_end[$r] .= ' LEFT JOIN '.MAIN_DB_PREFIX.'c_typent as t ON s.fk_typent = t.id';
|
||||
@ -409,6 +417,7 @@ class modSociete extends DolibarrModules
|
||||
$this->import_fields_array[$r] = array(//field order as per structure of table llx_societe
|
||||
's.nom' => "Name*",
|
||||
's.name_alias' => "AliasNameShort",
|
||||
's.parent' => "ParentCompany",
|
||||
's.status' => "Status",
|
||||
's.code_client' => "CustomerCode",
|
||||
's.code_fournisseur' => "SupplierCode",
|
||||
@ -445,6 +454,9 @@ class modSociete extends DolibarrModules
|
||||
's.cond_reglement' => "PaymentTermsCustomer",
|
||||
's.mode_reglement_supplier' => 'PaymentTypeSupplier',
|
||||
's.cond_reglement_supplier' => "PaymentTermsSupplier",
|
||||
's.outstanding_limit'=>'OutstandingBill',
|
||||
's.fk_account'=>'PaymentBankAccount',
|
||||
's.fk_incoterms'=>'IncotermLabel',
|
||||
's.tva_assuj' => 'VATIsUsed',
|
||||
's.barcode' => 'BarCode',
|
||||
's.default_lang' => 'DefaultLanguage',
|
||||
@ -498,6 +510,29 @@ class modSociete extends DolibarrModules
|
||||
),
|
||||
's.capital' => array('rule' => 'numeric'),
|
||||
's.fk_stcomm' => array('rule' => 'zeroifnull'),
|
||||
's.parent' => array(
|
||||
'rule' => 'fetchidfromref',
|
||||
'file' => '/societe/class/societe.class.php',
|
||||
'class' => 'Societe',
|
||||
'method' => 'fetch',
|
||||
'element' => 'ThirdParty'
|
||||
),
|
||||
's.outstanding_limit' => array('rule' => 'numeric'),
|
||||
's.fk_account' => array(
|
||||
'rule' => 'fetchidfromcodeid',
|
||||
'classfile' => '/compta/bank/class/account.class.php',
|
||||
'class' => 'Account',
|
||||
'method' => 'fetch',
|
||||
'element' => 'BankAccount'
|
||||
// ),
|
||||
// TODO
|
||||
// 's.fk_incoterms' => array(
|
||||
// 'rule' => 'fetchidfromcodeid',
|
||||
// 'classfile' => '/core/class/cincoterm.class.php',
|
||||
// 'class' => 'Cincoterm',
|
||||
// 'method' => 'fetch',
|
||||
// 'dict' => 'IncotermLabel'
|
||||
)
|
||||
);
|
||||
//$this->import_convertvalue_array[$r]=array('s.fk_soc'=>array('rule'=>'lastrowid',table='t');
|
||||
$this->import_regex_array[$r] = array(//field order as per structure of table llx_societe
|
||||
@ -509,6 +544,7 @@ class modSociete extends DolibarrModules
|
||||
's.cond_reglement' => 'rowid@'.MAIN_DB_PREFIX.'c_payment_term',
|
||||
's.mode_reglement_supplier' => 'id@'.MAIN_DB_PREFIX.'c_paiement',
|
||||
's.cond_reglement_supplier' => 'rowid@'.MAIN_DB_PREFIX.'c_payment_term',
|
||||
's.fk_incoterms' => 'rowid@'.MAIN_DB_PREFIX.'c_incoterms',
|
||||
's.tva_assuj' => '^[0|1]',
|
||||
's.fk_multicurrency' => '^[0|1]',
|
||||
's.datec' => '^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]( [0-9][0-9]:[0-9][0-9]:[0-9][0-9])?$',
|
||||
@ -518,6 +554,7 @@ class modSociete extends DolibarrModules
|
||||
$this->import_examplevalues_array[$r] = array(//field order as per structure of table llx_societe
|
||||
's.nom' => "TPBigCompany",
|
||||
's.name_alias' => "Alias for TPBigCompany",
|
||||
's.parent' => "TPMotherCompany",
|
||||
's.status' => "0 (closed) / 1 (active)",
|
||||
's.code_client' => 'eg. CU01-0001 / empty / "auto"',
|
||||
's.code_fournisseur' => 'eg. SU01-0001 / empty / "auto"',
|
||||
@ -554,6 +591,9 @@ class modSociete extends DolibarrModules
|
||||
's.cond_reglement' => '1/2/3...matches field "rowid" in table "'.MAIN_DB_PREFIX.'c_payment_term"',
|
||||
's.mode_reglement_supplier' => '1/2/3...matches field "id" in table "'.MAIN_DB_PREFIX.'c_paiement"',
|
||||
's.cond_reglement_supplier' => '1/2/3...matches field "rowid" in table "'.MAIN_DB_PREFIX.'c_payment_term"',
|
||||
's.outstanding_limit' => "5000",
|
||||
's.fk_account' => "rowid or ref",
|
||||
's.fk_incoterms' => '1/2/3...matches field "rowid" in table "'.MAIN_DB_PREFIX.'c_incoterms"',
|
||||
's.tva_assuj' => '0 (VAT not used) / 1 (VAT used)',
|
||||
's.barcode' => '123456789',
|
||||
's.default_lang' => 'en_US / es_ES etc...matches a language directory in htdocs/langs/',
|
||||
|
||||
@ -44,7 +44,7 @@ if (!empty($actionsave))
|
||||
|
||||
$db->begin();
|
||||
|
||||
$i += dolibarr_set_const($db, 'CRON_KEY', trim(GETPOST("CRON_KEY")), 'chaine', 0, '', 0);
|
||||
$i += dolibarr_set_const($db, 'CRON_KEY', GETPOST("CRON_KEY"), 'chaine', 0, '', 0);
|
||||
|
||||
if ($i >= 1)
|
||||
{
|
||||
|
||||
@ -120,9 +120,9 @@ if ($action == 'add' && $permtoadd)
|
||||
}
|
||||
}
|
||||
|
||||
$ref = trim(GETPOST("ref", 'alpha'));
|
||||
$label = trim(GETPOST("label", 'alpha'));
|
||||
$desc = trim(GETPOST("desc", 'alpha'));
|
||||
$ref = GETPOST("ref", 'alpha');
|
||||
$label = GETPOST("label", 'alpha');
|
||||
$desc = GETPOST("desc", 'alpha');
|
||||
$catParent = GETPOST("catParent", 'alpha'); // Can be an int (with ECM) or a string (with generic filemanager)
|
||||
if ($catParent == '-1') $catParent = 0;
|
||||
|
||||
|
||||
@ -246,7 +246,36 @@ class EmailCollector extends CommonObject
|
||||
*/
|
||||
public function create(User $user, $notrigger = false)
|
||||
{
|
||||
return $this->createCommon($user, $notrigger);
|
||||
$id = $this->createCommon($user, $notrigger);
|
||||
|
||||
if (is_array($this->filters) && count($this->filters)) {
|
||||
$emailcollectorfilter = new EmailCollectorFilter($this->db);
|
||||
|
||||
foreach ($this->filters as $filter) {
|
||||
$emailcollectorfilter->type = $filter['type'];
|
||||
$emailcollectorfilter->rulevalue = $filter['rulevalue'];
|
||||
$emailcollectorfilter->fk_emailcollector = $this->id;
|
||||
$emailcollectorfilter->status = $filter['status'];
|
||||
|
||||
$emailcollectorfilter->create($user);
|
||||
}
|
||||
}
|
||||
|
||||
if (is_array($this->filters) && count($this->filters)) {
|
||||
$emailcollectoroperation = new EmailCollectorAction($this->db);
|
||||
|
||||
foreach ($this->actions as $operation) {
|
||||
$emailcollectoroperation->type = $operation['type'];
|
||||
$emailcollectoroperation->actionparam = $operation['actionparam'];
|
||||
$emailcollectoroperation->fk_emailcollector = $this->id;
|
||||
$emailcollectoroperation->status = $operation['status'];
|
||||
$emailcollectoroperation->position = $operation['position'];
|
||||
|
||||
$emailcollectoroperation->create($user);
|
||||
}
|
||||
}
|
||||
|
||||
return $id;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -269,6 +298,10 @@ class EmailCollector extends CommonObject
|
||||
|
||||
// Load source object
|
||||
$object->fetchCommon($fromid);
|
||||
|
||||
$object->fetchFilters(); // Rules
|
||||
$object->fetchActions(); // Operations
|
||||
|
||||
// Reset some properties
|
||||
unset($object->id);
|
||||
unset($object->fk_user_creat);
|
||||
@ -295,7 +328,7 @@ class EmailCollector extends CommonObject
|
||||
|
||||
// Create clone
|
||||
$object->context['createfromclone'] = 'createfromclone';
|
||||
$result = $object->createCommon($user);
|
||||
$result = $object->create($user);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
$this->error = $object->error;
|
||||
@ -605,6 +638,7 @@ class EmailCollector extends CommonObject
|
||||
* Fetch filters
|
||||
*
|
||||
* @return int <0 if KO, >0 if OK
|
||||
* @see fetchActions()
|
||||
*/
|
||||
public function fetchFilters()
|
||||
{
|
||||
@ -636,6 +670,7 @@ class EmailCollector extends CommonObject
|
||||
* Fetch actions
|
||||
*
|
||||
* @return int <0 if KO, >0 if OK
|
||||
* @see fetchFilters()
|
||||
*/
|
||||
public function fetchActions()
|
||||
{
|
||||
@ -1085,7 +1120,7 @@ class EmailCollector extends CommonObject
|
||||
|
||||
dol_syslog("Start of loop on email", LOG_INFO, 1);
|
||||
|
||||
$i = 0;
|
||||
$iforemailloop = 0;
|
||||
foreach ($arrayofemail as $imapemail)
|
||||
{
|
||||
if ($nbemailprocessed > 1000)
|
||||
@ -1093,7 +1128,7 @@ class EmailCollector extends CommonObject
|
||||
break; // Do not process more than 1000 email per launch (this is a different protection than maxnbcollectedpercollect
|
||||
}
|
||||
|
||||
$i++;
|
||||
$iforemailloop++;
|
||||
|
||||
$header = imap_fetchheader($connection, $imapemail, 0);
|
||||
$header = preg_replace('/\r\n\s+/m', ' ', $header); // When a header line is on several lines, merge lines
|
||||
@ -1107,9 +1142,12 @@ class EmailCollector extends CommonObject
|
||||
if (!empty($headers['in-reply-to']) && empty($headers['In-Reply-To'])) { $headers['In-Reply-To'] = $headers['in-reply-to']; }
|
||||
if (!empty($headers['references']) && empty($headers['References'])) { $headers['References'] = $headers['references']; }
|
||||
if (!empty($headers['message-id']) && empty($headers['Message-ID'])) { $headers['Message-ID'] = $headers['message-id']; }
|
||||
|
||||
$headers['Subject'] = $this->decodeSMTPSubject($headers['Subject']);
|
||||
|
||||
dol_syslog("** Process email ".$i." References: ".$headers['References']);
|
||||
|
||||
dol_syslog("** Process email ".$iforemailloop." References: ".$headers['References']);
|
||||
//print "Process mail ".$iforemailloop." Subject: ".dol_escape_htmltag($headers['Subject'])." References: ".dol_escape_htmltag($headers['References'])." In-Reply-To: ".dol_escape_htmltag($headers['In-Reply-To'])."<br>\n";
|
||||
|
||||
// If there is a filter on trackid
|
||||
if ($searchfilterdoltrackid > 0)
|
||||
@ -1135,6 +1173,17 @@ class EmailCollector extends CommonObject
|
||||
$nbemailprocessed++;
|
||||
continue; // Exclude email
|
||||
}
|
||||
// Note: we can have
|
||||
// Message-ID=A, In-Reply-To=B, References=B and message can BE an answer or NOT (a transfer rewriten)
|
||||
$isanswer = 0;
|
||||
if (preg_match('/Re\s*:\s+/i', $headers['Subject'])) $isanswer = 1;
|
||||
//if ($headers['In-Reply-To'] != $headers['Message-ID'] && empty($headers['References'])) $isanswer = 1; // If in-reply-to differs of message-id, this is a reply
|
||||
//if ($headers['In-Reply-To'] != $headers['Message-ID'] && !empty($headers['References']) && strpos($headers['References'], $headers['Message-ID']) !== false) $isanswer = 1;
|
||||
|
||||
if (!$isanswer) {
|
||||
$nbemailprocessed++;
|
||||
continue; // Exclude email
|
||||
}
|
||||
}
|
||||
if ($searchfilterisnotanswer > 0) {
|
||||
if (!empty($headers['In-Reply-To']))
|
||||
@ -1142,7 +1191,7 @@ class EmailCollector extends CommonObject
|
||||
// Note: we can have
|
||||
// Message-ID=A, In-Reply-To=B, References=B and message can BE an answer or NOT (a transfer rewriten)
|
||||
$isanswer = 0;
|
||||
if (preg_match('/Re:\s+/i', $headers['Subject'])) $isanswer = 1;
|
||||
if (preg_match('/Re\s*:\s+/i', $headers['Subject'])) $isanswer = 1;
|
||||
//if ($headers['In-Reply-To'] != $headers['Message-ID'] && empty($headers['References'])) $isanswer = 1; // If in-reply-to differs of message-id, this is a reply
|
||||
//if ($headers['In-Reply-To'] != $headers['Message-ID'] && !empty($headers['References']) && strpos($headers['References'], $headers['Message-ID']) !== false) $isanswer = 1;
|
||||
if ($isanswer) {
|
||||
@ -1152,6 +1201,7 @@ class EmailCollector extends CommonObject
|
||||
}
|
||||
}
|
||||
|
||||
//print "Process mail ".$iforemailloop." Subject: ".dol_escape_htmltag($headers['Subject'])." selected<br>\n";
|
||||
|
||||
$thirdpartystatic = new Societe($this->db);
|
||||
$contactstatic = new Contact($this->db);
|
||||
@ -1175,6 +1225,7 @@ class EmailCollector extends CommonObject
|
||||
dol_syslog("msgid=".$overview[0]->message_id." date=".dol_print_date($overview[0]->udate, 'dayrfc', 'gmt')." from=".$overview[0]->from." to=".$overview[0]->to." subject=".$overview[0]->subject);
|
||||
|
||||
$overview[0]->subject = $this->decodeSMTPSubject($overview[0]->subject);
|
||||
|
||||
$overview[0]->from = $this->decodeSMTPSubject($overview[0]->from);
|
||||
|
||||
// Removed emojis
|
||||
@ -1264,6 +1315,7 @@ class EmailCollector extends CommonObject
|
||||
}
|
||||
$fk_element_id = 0; $fk_element_type = '';
|
||||
|
||||
|
||||
$contactid = 0; $thirdpartyid = 0; $projectid = 0; $ticketid = 0;
|
||||
|
||||
// Analyze TrackId in field References. For example:
|
||||
@ -1277,10 +1329,12 @@ class EmailCollector extends CommonObject
|
||||
$reg = array();
|
||||
if (!empty($headers['References']))
|
||||
{
|
||||
$arrayofreferences = preg_split('/\s+/', $headers['References']);
|
||||
$arrayofreferences = preg_split('/(,|\s+)/', $headers['References']);
|
||||
//var_dump($headers['References']);
|
||||
//var_dump($arrayofreferences);
|
||||
|
||||
foreach ($arrayofreferences as $reference) {
|
||||
//print "Process reference ".dol_escape_htmltag($reference)."<br>\n";
|
||||
//print "Process mail ".$iforemailloop." email_msgid ".$msgid.", date ".dol_print_date($date, 'dayhour').", subject ".$subject.", reference ".dol_escape_htmltag($reference)."<br>\n";
|
||||
if (preg_match('/dolibarr-([a-z]+)([0-9]+)@'.preg_quote($host, '/').'/', $reference, $reg)) {
|
||||
// This is a Dolibarr reference
|
||||
$trackid = $reg[1].$reg[2];
|
||||
@ -1459,6 +1513,7 @@ class EmailCollector extends CommonObject
|
||||
|
||||
// Make Operation
|
||||
dol_syslog("Execute action ".$operation['type']." actionparam=".$operation['actionparam'].' thirdpartystatic->id='.$thirdpartystatic->id.' contactstatic->id='.$contactstatic->id.' projectstatic->id='.$projectstatic->id);
|
||||
dol_syslog("Execute action fk_element_id=".$fk_element_id." fk_element_type=".$fk_element_type);
|
||||
|
||||
$actioncode = 'EMAIL_IN';
|
||||
// If we scan the Sent box, we use the code for out email
|
||||
@ -1590,10 +1645,10 @@ class EmailCollector extends CommonObject
|
||||
// Create event
|
||||
elseif ($operation['type'] == 'recordevent')
|
||||
{
|
||||
$alreadycreated = 0;
|
||||
// TODO Check if $msgid already in database for $conf->entity
|
||||
$actioncomm = new ActionComm($this->db);
|
||||
|
||||
if (!$alreadycreated)
|
||||
$alreadycreated = $actioncomm->fetch(0, '', '', $msgid);
|
||||
if ($alreadycreated == 0)
|
||||
{
|
||||
if ($projectstatic->id > 0)
|
||||
{
|
||||
@ -1619,7 +1674,6 @@ class EmailCollector extends CommonObject
|
||||
$descriptionfull = dol_concatdesc($descriptionfull, $header);
|
||||
|
||||
// Insert record of emails sent
|
||||
$actioncomm = new ActionComm($this->db);
|
||||
$actioncomm->type_code = 'AC_OTH_AUTO'; // Type of event ('AC_OTH', 'AC_OTH_AUTO', 'AC_XXX'...)
|
||||
$actioncomm->code = 'AC_'.$actioncode;
|
||||
$actioncomm->label = $langs->trans("ActionAC_".$actioncode).' - '.$langs->trans("MailFrom").' '.$from;
|
||||
@ -1646,7 +1700,11 @@ class EmailCollector extends CommonObject
|
||||
if (!in_array($fk_element_type, array('societe', 'contact', 'project', 'user')))
|
||||
{
|
||||
$actioncomm->fk_element = $fk_element_id;
|
||||
$actioncomm->elementid = $fk_element_id;
|
||||
$actioncomm->elementtype = $fk_element_type;
|
||||
if (is_object($objectemail) && $objectemail->module) {
|
||||
$actioncomm->elementtype .= '@'.$objectemail->module;
|
||||
}
|
||||
}
|
||||
|
||||
//$actioncomm->extraparams = $extraparams;
|
||||
@ -1654,6 +1712,13 @@ class EmailCollector extends CommonObject
|
||||
// Overwrite values with values extracted from source email
|
||||
$errorforthisaction = $this->overwritePropertiesOfObject($actioncomm, $operation['actionparam'], $messagetext, $subject, $header);
|
||||
|
||||
/*var_dump($fk_element_id);
|
||||
var_dump($fk_element_type);
|
||||
var_dump($alreadycreated);
|
||||
var_dump($operation['type']);
|
||||
var_dump($actioncomm);
|
||||
exit;*/
|
||||
|
||||
if ($errorforthisaction)
|
||||
{
|
||||
$errorforactions++;
|
||||
@ -1672,7 +1737,7 @@ class EmailCollector extends CommonObject
|
||||
{
|
||||
$projecttocreate = new Project($this->db);
|
||||
|
||||
$alreadycreated = $projecttocreate->fetch(0, '', $msgid);
|
||||
$alreadycreated = $projecttocreate->fetch(0, '', '', $msgid);
|
||||
if ($alreadycreated == 0)
|
||||
{
|
||||
if ($thirdpartystatic->id > 0)
|
||||
@ -2276,10 +2341,14 @@ class EmailCollector extends CommonObject
|
||||
}
|
||||
|
||||
/**
|
||||
* Decode a subject string
|
||||
* Decode a subject string according to RFC2047
|
||||
* Example: '=?Windows-1252?Q?RE=A0:_ABC?=' => 'RE : ABC...'
|
||||
* Example: '=?UTF-8?Q?A=C3=A9B?=' => 'AéB'
|
||||
* Example: '=?UTF-8?B?2KLYstmF2KfbjNi0?=' =>
|
||||
* Example: '=?utf-8?B?UkU6IG1vZHVsZSBkb2xpYmFyciBnZXN0aW9ubmFpcmUgZGUgZmljaGllcnMg?= =?utf-8?B?UsOpZsOpcmVuY2UgZGUgbGEgY29tbWFuZGUgVFVHRURJSklSIOKAkyBwYXNz?= =?utf-8?B?w6llIGxlIDIyLzA0LzIwMjA=?='
|
||||
*
|
||||
* @param string $subject Subject
|
||||
* @return string Decoded subject
|
||||
* @return string Decoded subject (in UTF-8)
|
||||
*/
|
||||
protected function decodeSMTPSubject($subject)
|
||||
{
|
||||
@ -2287,20 +2356,21 @@ class EmailCollector extends CommonObject
|
||||
// Can use also imap_mime_header_decode($str)
|
||||
// Can use also mb_decode_mimeheader($str)
|
||||
// Can use also iconv_mime_decode($str, ICONV_MIME_DECODE_CONTINUE_ON_ERROR, 'UTF-8')
|
||||
if (function_exists('iconv_mime_decode')) {
|
||||
$subject = iconv_mime_decode($subject, ICONV_MIME_DECODE_CONTINUE_ON_ERROR, 'UTF-8');
|
||||
} elseif (function_exists('imap_mime_header_decode')) {
|
||||
if (function_exists('imap_mime_header_decode') && function_exists('iconv_mime_decode')) {
|
||||
$elements = imap_mime_header_decode($subject);
|
||||
$newstring = '';
|
||||
if (!empty($elements)) {
|
||||
$num = count($elements);
|
||||
for ($i = 0; $i < $num; $i++) {
|
||||
$newstring .= ($newstring ? ' ' : '').$elements[$i]->text;
|
||||
$stringinutf8 = (in_array(strtoupper($elements[$i]->charset), array('DEFAULT', 'UTF-8')) ? $elements[$i]->text : iconv_mime_decode($elements[$i]->text, ICONV_MIME_DECODE_CONTINUE_ON_ERROR, $elements[$i]->charset));
|
||||
$newstring .= $stringinutf8;
|
||||
}
|
||||
$subject = $newstring;
|
||||
}
|
||||
} elseif (function_exists('mb_decode_mimeheader')) {
|
||||
$subject = mb_decode_mimeheader($subject);
|
||||
} elseif (!function_exists('mb_decode_mimeheader')) {
|
||||
$subject = mb_decode_mimeheader($subject);
|
||||
} elseif (function_exists('iconv_mime_decode')) {
|
||||
$subject = iconv_mime_decode($subject, ICONV_MIME_DECODE_CONTINUE_ON_ERROR, 'UTF-8');
|
||||
}
|
||||
|
||||
return $subject;
|
||||
|
||||
@ -169,7 +169,7 @@ class EmailCollectorFilter extends CommonObject
|
||||
{
|
||||
$langs->load("errors");
|
||||
$this->errors[] = $langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("SearchString"));
|
||||
return -1;
|
||||
return -2;
|
||||
}
|
||||
|
||||
return $this->createCommon($user, $notrigger);
|
||||
|
||||
@ -59,7 +59,7 @@ $search_company = GETPOST("search_company", 'alpha');
|
||||
$search_tracking = GETPOST("search_tracking", 'alpha');
|
||||
$search_town = GETPOST('search_town', 'alpha');
|
||||
$search_zip = GETPOST('search_zip', 'alpha');
|
||||
$search_state = trim(GETPOST("search_state"));
|
||||
$search_state = GETPOST("search_state");
|
||||
$search_country = GETPOST("search_country", 'int');
|
||||
$search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
|
||||
$search_billed = GETPOST("search_billed", 'int');
|
||||
@ -71,7 +71,7 @@ $sall = trim((GETPOST('search_all', 'alphanohtml') != '') ?GETPOST('search_all',
|
||||
$socid = GETPOST('socid', 'int');
|
||||
$search_user = GETPOST('search_user', 'int');
|
||||
$search_sale = GETPOST('search_sale', 'int');
|
||||
$search_categ_cus = trim(GETPOST("search_categ_cus", 'int'));
|
||||
$search_categ_cus = GETPOST("search_categ_cus", 'int');
|
||||
$search_product_category = GETPOST('search_product_category', 'int');
|
||||
$optioncss = GETPOST('optioncss', 'alpha');
|
||||
|
||||
|
||||
@ -906,7 +906,7 @@ if ($action == 'create')
|
||||
{
|
||||
$langs->load("contracts");
|
||||
print '<tr><td>'.$langs->trans("Contract").'</td><td>';
|
||||
$numcontrat = $formcontract->select_contract($soc->id, GETPOST('contratid', 'int'), 'contratid', 0, 1);
|
||||
$numcontrat = $formcontract->select_contract($soc->id, GETPOST('contratid', 'int'), 'contratid', 0, 1, 1);
|
||||
if ($numcontrat == 0)
|
||||
{
|
||||
print ' <a href="'.DOL_URL_ROOT.'/contrat/card.php?socid='.$soc->id.'&action=create"><span class="fa fa-plus-circle valignmiddle paddingleft" title="'.$langs->trans("AddContract").'"></span></a>';
|
||||
@ -1238,7 +1238,7 @@ if ($action == 'create')
|
||||
if ($action == 'contrat')
|
||||
{
|
||||
$formcontract = new Formcontract($db);
|
||||
$formcontract->formSelectContract($_SERVER["PHP_SELF"].'?id='.$object->id, $object->socid, $object->fk_contrat, 'contratid', 0, 1);
|
||||
$formcontract->formSelectContract($_SERVER["PHP_SELF"].'?id='.$object->id, $object->socid, $object->fk_contrat, 'contratid', 0, 1, 1);
|
||||
} else {
|
||||
if ($object->fk_contrat)
|
||||
{
|
||||
|
||||
@ -652,7 +652,9 @@ if (empty($reshook))
|
||||
*/
|
||||
if ($action == 'updateline' && $usercancreate && !GETPOST('cancel', 'alpha'))
|
||||
{
|
||||
$vat_rate = (GETPOST('tva_tx') ?GETPOST('tva_tx') : 0);
|
||||
$db->begin();
|
||||
|
||||
$vat_rate = (GETPOST('tva_tx') ? GETPOST('tva_tx') : 0);
|
||||
|
||||
if ($lineid)
|
||||
{
|
||||
@ -780,7 +782,11 @@ if (empty($reshook))
|
||||
$result = $object->generateDocument($model, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
if ($result < 0) dol_print_error($db, $result);
|
||||
}
|
||||
|
||||
$db->commit();
|
||||
} else {
|
||||
$db->rollback();
|
||||
|
||||
dol_print_error($db, $object->error);
|
||||
exit;
|
||||
}
|
||||
@ -789,6 +795,8 @@ if (empty($reshook))
|
||||
// Remove a product line
|
||||
if ($action == 'confirm_deleteline' && $confirm == 'yes' && $usercancreate)
|
||||
{
|
||||
$db->begin();
|
||||
|
||||
$result = $object->deleteline($lineid);
|
||||
if ($result > 0)
|
||||
{
|
||||
@ -807,19 +815,28 @@ if (empty($reshook))
|
||||
$ret = $object->fetch($object->id); // Reload to get new records
|
||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
}
|
||||
} else {
|
||||
$error++;
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
// Reset action to avoid asking again confirmation on failure
|
||||
$action = '';
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$db->commit();
|
||||
|
||||
header('Location: '.$_SERVER["PHP_SELF"].'?id='.$object->id);
|
||||
exit;
|
||||
} else {
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
/* Fix bug 1485 : Reset action to avoid asking again confirmation on failure */
|
||||
$action = '';
|
||||
$db->rollback();
|
||||
}
|
||||
}
|
||||
|
||||
// Validate
|
||||
if ($action == 'confirm_valid' && $confirm == 'yes' && $usercanvalidate)
|
||||
{
|
||||
$db->begin();
|
||||
|
||||
$object->date_commande = dol_now();
|
||||
$result = $object->valid($user);
|
||||
if ($result >= 0)
|
||||
@ -839,21 +856,33 @@ if (empty($reshook))
|
||||
$ret = $object->fetch($id); // Reload to get new records
|
||||
|
||||
$result = $object->generateDocument($model, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
if ($result < 0) dol_print_error($db, $result);
|
||||
if ($result < 0) {
|
||||
$error++;
|
||||
dol_print_error($db, $result);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$error++;
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
|
||||
// If we have permission, and if we don't need to provide the idwarehouse, we go directly on approved step
|
||||
if (empty($conf->global->SUPPLIER_ORDER_NO_DIRECT_APPROVE) && $usercanapprove && !(!empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) && $object->hasProductsOrServices(1)))
|
||||
if (!$error && empty($conf->global->SUPPLIER_ORDER_NO_DIRECT_APPROVE) && $usercanapprove && !(!empty($conf->global->STOCK_CALCULATE_ON_SUPPLIER_VALIDATE_ORDER) && $object->hasProductsOrServices(1)))
|
||||
{
|
||||
$action = 'confirm_approve'; // can make standard or first level approval also if permission is set
|
||||
}
|
||||
|
||||
if (! $error) {
|
||||
$db->commit();
|
||||
} else {
|
||||
$db->rollback();
|
||||
}
|
||||
}
|
||||
|
||||
if (($action == 'confirm_approve' || $action == 'confirm_approve2') && $confirm == 'yes' && $usercanapprove)
|
||||
{
|
||||
$db->begin();
|
||||
|
||||
$idwarehouse = GETPOST('idwarehouse', 'int');
|
||||
|
||||
$qualified_for_stock_change = 0;
|
||||
@ -891,12 +920,20 @@ if (empty($reshook))
|
||||
}
|
||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
}
|
||||
header("Location: ".$_SERVER["PHP_SELF"]."?id=".$object->id);
|
||||
exit;
|
||||
} else {
|
||||
$error++;
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$db->commit();
|
||||
|
||||
header("Location: ".$_SERVER["PHP_SELF"]."?id=".$object->id);
|
||||
exit;
|
||||
} else {
|
||||
$db->rollback();
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'confirm_refuse' && $confirm == 'yes' && $usercanapprove)
|
||||
@ -923,6 +960,8 @@ if (empty($reshook))
|
||||
|
||||
if ($action == 'confirm_commande' && $confirm == 'yes' && $usercanorder)
|
||||
{
|
||||
$db->begin();
|
||||
|
||||
$result = $object->commande($user, GETPOST("datecommande"), GETPOST("methode", 'int'), GETPOST('comment', 'alphanohtml'));
|
||||
if ($result > 0)
|
||||
{
|
||||
@ -939,10 +978,18 @@ if (empty($reshook))
|
||||
$object->generateDocument($object->modelpdf, $outputlangs, $hidedetails, $hidedesc, $hideref);
|
||||
}
|
||||
$action = '';
|
||||
} else {
|
||||
$error++;
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
|
||||
if (!$error) {
|
||||
$db->commit();
|
||||
|
||||
header("Location: ".$_SERVER["PHP_SELF"]."?id=".$object->id);
|
||||
exit;
|
||||
} else {
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
$db->rollback();
|
||||
}
|
||||
}
|
||||
|
||||
@ -987,6 +1034,8 @@ if (empty($reshook))
|
||||
// Set status of reception (complete, partial, ...)
|
||||
if ($action == 'livraison' && $usercanreceived)
|
||||
{
|
||||
$db->begin();
|
||||
|
||||
if (GETPOST("type") != '')
|
||||
{
|
||||
$date_liv = dol_mktime(GETPOST('rehour'), GETPOST('remin'), GETPOST('resec'), GETPOST("remonth"), GETPOST("reday"), GETPOST("reyear"));
|
||||
@ -999,13 +1048,22 @@ if (empty($reshook))
|
||||
$action = '';
|
||||
} elseif ($result == -3)
|
||||
{
|
||||
$error++;
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
} else {
|
||||
$error++;
|
||||
setEventMessages($object->error, $object->errors, 'errors');
|
||||
}
|
||||
} else {
|
||||
$error++;
|
||||
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentities("Delivery")), null, 'errors');
|
||||
}
|
||||
|
||||
if (! $error) {
|
||||
$db->commit();
|
||||
} else {
|
||||
$db->rollback();
|
||||
}
|
||||
}
|
||||
|
||||
if ($action == 'confirm_cancel' && $confirm == 'yes' && $usercanorder)
|
||||
@ -1907,7 +1965,7 @@ if ($action == 'create')
|
||||
$morehtmlref .= '<form method="post" action="'.$_SERVER['PHP_SELF'].'?id='.$object->id.'">';
|
||||
$morehtmlref .= '<input type="hidden" name="action" value="classin">';
|
||||
$morehtmlref .= '<input type="hidden" name="token" value="'.newToken().'">';
|
||||
$morehtmlref .= $formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $object->socid : -1), $object->fk_project, 'projectid', $maxlength, 0, 1, 0, 1, 0, 0, '', 1);
|
||||
$morehtmlref .= $formproject->select_projects((empty($conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS) ? $object->socid : -1), $object->fk_project, 'projectid', 0, 0, 1, 0, 1, 0, 0, '', 1, 0, 'maxwidth500');
|
||||
$morehtmlref .= '<input type="submit" class="button valignmiddle" value="'.$langs->trans("Modify").'">';
|
||||
$morehtmlref .= '</form>';
|
||||
} else {
|
||||
|
||||
@ -66,7 +66,7 @@ $search_refsupp = GETPOST('search_refsupp', 'alpha');
|
||||
$search_company = GETPOST('search_company', 'alpha');
|
||||
$search_town = GETPOST('search_town', 'alpha');
|
||||
$search_zip = GETPOST('search_zip', 'alpha');
|
||||
$search_state = trim(GETPOST("search_state", 'alpha'));
|
||||
$search_state = GETPOST("search_state", 'alpha');
|
||||
$search_country = GETPOST("search_country", 'int');
|
||||
$search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
|
||||
$search_user = GETPOST('search_user', 'int');
|
||||
|
||||
@ -1771,7 +1771,9 @@ if ($action == 'create')
|
||||
print '</td></tr>';
|
||||
|
||||
// Ref supplier
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans('RefSupplier').'</td><td><input name="ref_supplier" value="'.(isset($_POST['ref_supplier']) ? $_POST['ref_supplier'] : $objectsrc->ref_supplier).'" type="text"></td>';
|
||||
print '<tr><td class="fieldrequired">'.$langs->trans('RefSupplier').'</td><td><input name="ref_supplier" value="'.(isset($_POST['ref_supplier']) ? $_POST['ref_supplier'] : $objectsrc->ref_supplier).'" type="text"';
|
||||
if ($societe->id > 0) print ' autofocus';
|
||||
print '></td>';
|
||||
print '</tr>';
|
||||
|
||||
print '<tr><td class="tdtop fieldrequired">'.$langs->trans('Type').'</td><td>';
|
||||
|
||||
@ -94,7 +94,7 @@ $search_status = GETPOST('search_status', 'int');
|
||||
$search_paymentmode = GETPOST('search_paymentmode', 'int');
|
||||
$search_town = GETPOST('search_town', 'alpha');
|
||||
$search_zip = GETPOST('search_zip', 'alpha');
|
||||
$search_state = trim(GETPOST("search_state"));
|
||||
$search_state = GETPOST("search_state");
|
||||
$search_country = GETPOST("search_country", 'int');
|
||||
$search_type_thirdparty = GETPOST("search_type_thirdparty", 'int');
|
||||
$search_user = GETPOST('search_user', 'int');
|
||||
|
||||
@ -129,7 +129,8 @@ if (empty($reshook))
|
||||
$datepaye = dol_mktime(12, 0, 0, GETPOST('remonth'), GETPOST('reday'), GETPOST('reyear'));
|
||||
$paiement_id = 0;
|
||||
$totalpayment = 0;
|
||||
$atleastonepaymentnotnull = 0;
|
||||
$atleastonepaymentnotnull = 0;
|
||||
$multicurrency_totalpayment = 0;
|
||||
|
||||
// Generate payment array and check if there is payment higher than invoice and payment date before invoice date
|
||||
$tmpinvoice = new FactureFournisseur($db);
|
||||
@ -138,7 +139,7 @@ if (empty($reshook))
|
||||
if (substr($key, 0, 7) == 'amount_')
|
||||
{
|
||||
$cursorfacid = substr($key, 7);
|
||||
$amounts[$cursorfacid] = price2num(trim(GETPOST($key)));
|
||||
$amounts[$cursorfacid] = price2num(GETPOST($key));
|
||||
if (!empty($amounts[$cursorfacid])) {
|
||||
$atleastonepaymentnotnull++;
|
||||
if (is_numeric($amounts[$cursorfacid])) {
|
||||
@ -171,7 +172,7 @@ if (empty($reshook))
|
||||
} elseif (substr($key, 0, 21) == 'multicurrency_amount_')
|
||||
{
|
||||
$cursorfacid = substr($key, 21);
|
||||
$multicurrency_amounts[$cursorfacid] = price2num(trim(GETPOST($key)));
|
||||
$multicurrency_amounts[$cursorfacid] = (GETPOST($key) ? price2num(GETPOST($key)) : 0);
|
||||
$multicurrency_totalpayment += $multicurrency_amounts[$cursorfacid];
|
||||
if (!empty($multicurrency_amounts[$cursorfacid])) $atleastonepaymentnotnull++;
|
||||
$result = $tmpinvoice->fetch($cursorfacid);
|
||||
|
||||
@ -144,7 +144,7 @@ if (empty($reshook))
|
||||
elseif ($endhalfday == 'morning') $halfday = 1;
|
||||
|
||||
$valideur = GETPOST('valideur', 'int');
|
||||
$description = trim(GETPOST('description'));
|
||||
$description = trim(GETPOST('description', 'none'));
|
||||
|
||||
// If no type
|
||||
if ($type <= 0)
|
||||
|
||||
@ -242,7 +242,7 @@ class DoliStorage implements TokenStorageInterface
|
||||
$sql.= " WHERE service='".$this->db->escape($service)."'";
|
||||
$resql = $this->db->query($sql);
|
||||
$result = $this->db->fetch_array($resql);
|
||||
$states[$service] = $result[state];
|
||||
$states[$service] = $result['state'];
|
||||
$this->states[$service] = $states[$service];
|
||||
|
||||
return is_array($states)
|
||||
|
||||
@ -74,7 +74,11 @@ create table llx_mrp_mo_extrafields
|
||||
import_key varchar(14) -- import key
|
||||
) ENGINE=innodb;
|
||||
|
||||
ALTER TABLE llx_mrp_mo_extrafields ADD INDEX idx_fk_object(fk_object);
|
||||
ALTER TABLE llx_mrp_mo_extrafields DROP INDEX idx_fk_object;
|
||||
|
||||
ALTER TABLE llx_mrp_mo_extrafields ADD INDEX idx_mrp_mo_fk_object(fk_object);
|
||||
|
||||
|
||||
|
||||
-- This var is per entity now, so we remove const if global if exists
|
||||
delete from llx_const where name in ('PROJECT_HIDE_TASKS', 'MAIN_BUGTRACK_ENABLELINK', 'MAIN_HELP_DISABLELINK') and entity = 0;
|
||||
|
||||
@ -35,9 +35,23 @@ ALTER TABLE llx_prelevement_bons ADD COLUMN type varchar(16) DEFAULT 'debit-orde
|
||||
ALTER TABLE llx_prelevement_facture_demande ADD INDEX idx_prelevement_facture_demande_fk_facture (fk_facture);
|
||||
ALTER TABLE llx_prelevement_facture_demande ADD INDEX idx_prelevement_facture_demande_fk_facture_fourn (fk_facture_fourn);
|
||||
|
||||
ALTER TABLE llx_document_model MODIFY COLUMN type varchar(64);
|
||||
|
||||
ALTER TABLE llx_bom_bom MODIFY COLUMN duration double(24,8);
|
||||
|
||||
ALTER TABLE llx_document_model MODIFY COLUMN type varchar(64);
|
||||
ALTER TABLE llx_bom_bom_extrafields ADD INDEX idx_bom_bom_extrafields_fk_object (fk_object);
|
||||
|
||||
create table llx_mrp_mo_extrafields
|
||||
(
|
||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||
tms timestamp,
|
||||
fk_object integer NOT NULL,
|
||||
import_key varchar(14) -- import key
|
||||
) ENGINE=innodb;
|
||||
|
||||
ALTER TABLE llx_mrp_mo_extrafields DROP INDEX idx_fk_object;
|
||||
|
||||
ALTER TABLE llx_mrp_mo_extrafields ADD INDEX idx_mrp_mo_fk_object(fk_object);
|
||||
|
||||
|
||||
-- For v13
|
||||
@ -138,7 +152,7 @@ create table llx_recruitment_recruitmentjobposition_extrafields
|
||||
import_key varchar(14) -- import key
|
||||
) ENGINE=innodb;
|
||||
|
||||
ALTER TABLE llx_recruitment_recruitmentjobposition_extrafields ADD INDEX idx_fk_object(fk_object);
|
||||
ALTER TABLE llx_recruitment_recruitmentjobposition_extrafields ADD INDEX idx_recruitmentjobposition_fk_object(fk_object);
|
||||
|
||||
|
||||
|
||||
@ -186,12 +200,13 @@ create table llx_recruitment_recruitmentcandidature_extrafields
|
||||
import_key varchar(14) -- import key
|
||||
) ENGINE=innodb;
|
||||
|
||||
ALTER TABLE llx_recruitment_recruitmentcandidature_extrafields ADD INDEX idx_fk_object(fk_object);
|
||||
ALTER TABLE llx_recruitment_recruitmentcandidature_extrafields ADD INDEX idx_recruitmentcandidature_fk_object(fk_object);
|
||||
|
||||
ALTER TABLE llx_recruitment_recruitmentcandidature ADD UNIQUE INDEX uk_recruitmentcandidature_email_msgid(email_msgid);
|
||||
|
||||
|
||||
|
||||
|
||||
CREATE TABLE llx_product_attribute_combination_price_level
|
||||
(
|
||||
rowid INTEGER PRIMARY KEY NOT NULL AUTO_INCREMENT,
|
||||
@ -261,6 +276,8 @@ ALTER TABLE llx_projet ADD COLUMN email_msgid varchar(255);
|
||||
ALTER TABLE llx_ticket ADD COLUMN email_msgid varchar(255);
|
||||
ALTER TABLE llx_actioncomm ADD COLUMN reply_to varchar(255);
|
||||
|
||||
ALTER TABLE llx_paiement ADD pos_change DOUBLE(24,8) DEFAULT 0 AFTER fk_export_compta;
|
||||
|
||||
insert into llx_c_action_trigger (code,label,description,elementtype,rang) values ('CONTACT_CREATE','Contact address created','Executed when a contact is created','contact',50);
|
||||
insert into llx_c_action_trigger (code,label,description,elementtype,rang) values ('CONTACT_SENTBYMAIL','Mails sent from third party card','Executed when you send email from contact adress card','contact',51);
|
||||
insert into llx_c_action_trigger (code,label,description,elementtype,rang) values ('CONTACT_DELETE','Contact address deleted','Executed when a contact is deleted','contact',52);
|
||||
|
||||
21
htdocs/install/mysql/tables/llx_bom_bom_extrafields.key.sql
Normal file
21
htdocs/install/mysql/tables/llx_bom_bom_extrafields.key.sql
Normal file
@ -0,0 +1,21 @@
|
||||
-- ===================================================================
|
||||
-- Copyright (C) 2014 Florian Henry <florian.henry@open-concept.pro>
|
||||
--
|
||||
-- This program is free software; you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
-- the Free Software Foundation; either version 3 of the License, or
|
||||
-- (at your option) any later version.
|
||||
--
|
||||
-- This program is distributed in the hope that it will be useful,
|
||||
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
-- GNU General Public License for more details.
|
||||
--
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
--
|
||||
-- ===================================================================
|
||||
|
||||
|
||||
ALTER TABLE llx_bom_bom_extrafields ADD INDEX idx_bom_bom_extrafields_fk_object (fk_object);
|
||||
|
||||
@ -15,5 +15,5 @@
|
||||
|
||||
|
||||
-- BEGIN MODULEBUILDER INDEXES
|
||||
ALTER TABLE llx_mrp_myobject_extrafields ADD INDEX idx_fk_object(fk_object);
|
||||
ALTER TABLE llx_mrp_mo_extrafields ADD INDEX idx_mrp_mo_fk_object(fk_object);
|
||||
-- END MODULEBUILDER INDEXES
|
||||
|
||||
@ -13,7 +13,7 @@
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program. If not, see http://www.gnu.org/licenses/.
|
||||
|
||||
create table llx_mrp_myobject_extrafields
|
||||
create table llx_mrp_mo_extrafields
|
||||
(
|
||||
rowid integer AUTO_INCREMENT PRIMARY KEY,
|
||||
tms timestamp,
|
||||
|
||||
@ -37,5 +37,6 @@ create table llx_paiement
|
||||
fk_user_creat integer, -- utilisateur qui a cree l'info
|
||||
fk_user_modif integer, -- utilisateur qui a modifie l'info
|
||||
statut smallint DEFAULT 0 NOT NULL, -- Satut, 0 ou 1, 1 n'est plus supprimable
|
||||
fk_export_compta integer DEFAULT 0 NOT NULL -- fk_export_compta 0 pas exporte
|
||||
fk_export_compta integer DEFAULT 0 NOT NULL, -- fk_export_compta 0 pas exporte
|
||||
pos_change double(24,8) DEFAULT 0 -- Excess received in TakePOS cash payment
|
||||
)ENGINE=innodb;
|
||||
|
||||
@ -14,13 +14,14 @@
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
--
|
||||
-- Table to store all product variants of a parent product
|
||||
-- ============================================================================
|
||||
|
||||
CREATE TABLE llx_product_attribute_combination
|
||||
(
|
||||
rowid INTEGER PRIMARY KEY NOT NULL AUTO_INCREMENT,
|
||||
fk_product_parent INTEGER NOT NULL,
|
||||
fk_product_child INTEGER NOT NULL,
|
||||
fk_product_parent INTEGER NOT NULL, -- id of product id that is parent product
|
||||
fk_product_child INTEGER NOT NULL, -- id of product id that is variant (child) product
|
||||
variation_price DOUBLE(24,8) NOT NULL,
|
||||
variation_price_percentage INTEGER NULL,
|
||||
variation_weight REAL NOT NULL,
|
||||
|
||||
@ -0,0 +1,21 @@
|
||||
-- ============================================================================
|
||||
-- Copyright (C) 2020 John BOTELLA <john.botella@atm-consulting.fr>
|
||||
--
|
||||
-- This program is free software; you can redistribute it and/or modify
|
||||
-- it under the terms of the GNU General Public License as published by
|
||||
-- the Free Software Foundation; either version 3 of the License, or
|
||||
-- (at your option) any later version.
|
||||
--
|
||||
-- This program is distributed in the hope that it will be useful,
|
||||
-- but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
-- GNU General Public License for more details.
|
||||
--
|
||||
-- You should have received a copy of the GNU General Public License
|
||||
-- along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
--
|
||||
-- ============================================================================
|
||||
|
||||
|
||||
ALTER TABLE llx_product_attribute_combination_price_level ADD UNIQUE( fk_product_attribute_combination, fk_price_level);
|
||||
|
||||
@ -25,4 +25,3 @@ CREATE TABLE llx_product_attribute_combination_price_level
|
||||
variation_price_percentage INTEGER NULL
|
||||
)ENGINE=innodb;
|
||||
|
||||
ALTER TABLE llx_product_attribute_combination_price_level ADD UNIQUE( fk_product_attribute_combination, fk_price_level);
|
||||
|
||||
@ -15,5 +15,5 @@
|
||||
|
||||
|
||||
-- BEGIN MODULEBUILDER INDEXES
|
||||
ALTER TABLE llx_recruitment_recruitmentcandidature_extrafields ADD INDEX idx_fk_object(fk_object);
|
||||
ALTER TABLE llx_recruitment_recruitmentcandidature_extrafields ADD INDEX idx_recruitmentcandidature_fk_object(fk_object);
|
||||
-- END MODULEBUILDER INDEXES
|
||||
|
||||
@ -15,5 +15,5 @@
|
||||
|
||||
|
||||
-- BEGIN MODULEBUILDER INDEXES
|
||||
ALTER TABLE llx_recruitment_recruitmentjobposition_extrafields ADD INDEX idx_fk_object(fk_object);
|
||||
ALTER TABLE llx_recruitment_recruitmentjobposition_extrafields ADD INDEX idx_recruitmentjobposition_fk_object(fk_object);
|
||||
-- END MODULEBUILDER INDEXES
|
||||
|
||||
@ -149,6 +149,7 @@ ACCOUNTING_MANAGE_ZERO=Allow to manage different number of zeros at the end of a
|
||||
BANK_DISABLE_DIRECT_INPUT=Disable direct recording of transaction in bank account
|
||||
ACCOUNTING_ENABLE_EXPORT_DRAFT_JOURNAL=Enable draft export on journal
|
||||
ACCOUNTANCY_COMBO_FOR_AUX=Enable combo list for subsidiary account (may be slow if you have a lot of third parties)
|
||||
ACCOUNTING_DATE_START_BINDING=Define a date to start binding & transfer in accountancy. Below this date, the transactions will not be transferred to accounting.
|
||||
|
||||
ACCOUNTING_SELL_JOURNAL=Sell journal
|
||||
ACCOUNTING_PURCHASE_JOURNAL=Purchase journal
|
||||
@ -284,6 +285,7 @@ ShowTutorial=Show Tutorial
|
||||
NotReconciled=Not reconciled
|
||||
|
||||
## Admin
|
||||
BindingOptions=Binding options
|
||||
ApplyMassCategories=Apply mass categories
|
||||
AddAccountFromBookKeepingWithNoCategories=Available account not yet in the personalized group
|
||||
CategoryDeleted=Category for the accounting account has been removed
|
||||
|
||||
@ -300,8 +300,9 @@ MAIN_MAIL_DEFAULT_FROMTYPE=Default sender email for manual sending (User email o
|
||||
UserEmail=User email
|
||||
CompanyEmail=Company Email
|
||||
FeatureNotAvailableOnLinux=Feature not available on Unix like systems. Test your sendmail program locally.
|
||||
FixOnTransifex=Fix the translation on the online translation platform of project
|
||||
SubmitTranslation=If the translation for this language is not complete or you find errors, you can correct this by editing files in directory <b>langs/%s</b> and submit your change to www.transifex.com/dolibarr-association/dolibarr/
|
||||
SubmitTranslationENUS=If translation for this language is not complete or you find errors, you can correct this by editing files into directory <b>langs/%s</b> and submit modified files on dolibarr.org/forum or for developers on github.com/Dolibarr/dolibarr.
|
||||
SubmitTranslationENUS=If translation for this language is not complete or you find errors, you can correct this by editing files into directory <b>langs/%s</b> and submit modified files on dolibarr.org/forum or, if you are a developer, with a PR on github.com/Dolibarr/dolibarr
|
||||
ModuleSetup=Module setup
|
||||
ModulesSetup=Modules/Application setup
|
||||
ModuleFamilyBase=System
|
||||
@ -386,12 +387,12 @@ ModuleMustBeEnabledFirst=Module <b>%s</b> must be enabled first if you need this
|
||||
SecurityToken=Key to secure URLs
|
||||
NoSmsEngine=No SMS sender manager available. A SMS sender manager is not installed with the default distribution because they depend on an external vendor, but you can find some on %s
|
||||
PDF=PDF
|
||||
PDFDesc=Global options for PDF generation.
|
||||
PDFAddressForging=Rules for address boxes
|
||||
PDFDesc=Global options for PDF generation
|
||||
PDFAddressForging=Rules for address section
|
||||
HideAnyVATInformationOnPDF=Hide all information related to Sales Tax / VAT
|
||||
PDFRulesForSalesTax=Rules for Sales Tax / VAT
|
||||
PDFLocaltax=Rules for %s
|
||||
HideLocalTaxOnPDF=Hide %s rate in column Tax Sale
|
||||
HideLocalTaxOnPDF=Hide %s rate in column Sale Tax / VAT
|
||||
HideDescOnPDF=Hide products description
|
||||
HideRefOnPDF=Hide products ref.
|
||||
HideDetailsOnPDF=Hide product lines details
|
||||
@ -408,7 +409,9 @@ PriceBaseTypeToChange=Modify on prices with base reference value defined on
|
||||
MassConvert=Launch bulk conversion
|
||||
PriceFormatInCurrentLanguage=Price Format In Current Language
|
||||
String=String
|
||||
String1Line=String (1 line)
|
||||
TextLong=Long text
|
||||
TextLongNLines=Long text (n lines)
|
||||
HtmlText=Html text
|
||||
Int=Integer
|
||||
Float=Float
|
||||
@ -543,9 +546,9 @@ Module54Desc=Management of contracts (services or recurring subscriptions)
|
||||
Module55Name=Barcodes
|
||||
Module55Desc=Barcode management
|
||||
Module56Name=Payment by credit transfer
|
||||
Module56Desc=Management of payment of suppliers by credit transfer orders. It includes generation of SEPA file for European countries.
|
||||
Module57Name=Bank Direct Debit payments
|
||||
Module57Desc=Management of Direct Debit payment orders. It includes generation of SEPA file for European countries.
|
||||
Module56Desc=Management of payment of suppliers by Credit Transfer orders. It includes generation of SEPA file for European countries.
|
||||
Module57Name=Payments by Direct Debit
|
||||
Module57Desc=Management of Direct Debit orders. It includes generation of SEPA file for European countries.
|
||||
Module58Name=ClickToDial
|
||||
Module58Desc=Integration of a ClickToDial system (Asterisk, ...)
|
||||
Module59Name=Bookmark4u
|
||||
@ -836,9 +839,16 @@ Permission532=Create/modify services
|
||||
Permission534=Delete services
|
||||
Permission536=See/manage hidden services
|
||||
Permission538=Export services
|
||||
Permission561=Read payment orders by credit transfer
|
||||
Permission562=Create/modify payment order by credit transfer
|
||||
Permission563=Send/Transmit payment order by credit transfer
|
||||
Permission564=Record Debits/Rejections of credit transfer
|
||||
Permission650=Read Bills of Materials
|
||||
Permission651=Create/Update Bills of Materials
|
||||
Permission652=Delete Bills of Materials
|
||||
Permission660=Read Manufacturing Order (MO)
|
||||
Permission661=Create/Update Manufacturing Order (MO)
|
||||
Permission662=Delete Manufacturing Order (MO)
|
||||
Permission701=Read donations
|
||||
Permission702=Create/modify donations
|
||||
Permission703=Delete donations
|
||||
@ -848,6 +858,8 @@ Permission773=Delete expense reports
|
||||
Permission774=Read all expense reports (even for user not subordinates)
|
||||
Permission775=Approve expense reports
|
||||
Permission776=Pay expense reports
|
||||
Permission777=Read expense reports of everybody
|
||||
Permission778=Create/modify expense reports of everybody
|
||||
Permission779=Export expense reports
|
||||
Permission1001=Read stocks
|
||||
Permission1002=Create/modify warehouses
|
||||
@ -900,6 +912,7 @@ Permission2515=Setup documents directories
|
||||
Permission2801=Use FTP client in read mode (browse and download only)
|
||||
Permission2802=Use FTP client in write mode (delete or upload files)
|
||||
Permission3200=Read archived events and fingerprints
|
||||
Permission3301=Generate new modules
|
||||
Permission4001=See employees
|
||||
Permission4002=Create employees
|
||||
Permission4003=Delete employees
|
||||
@ -947,7 +960,8 @@ Permission63003=Delete resources
|
||||
Permission63004=Link resources to agenda events
|
||||
DictionaryCompanyType=Third-party types
|
||||
DictionaryCompanyJuridicalType=Third-party legal entities
|
||||
DictionaryProspectLevel=Prospect potential
|
||||
DictionaryProspectLevel=Prospect potential level for companies
|
||||
DictionaryProspectContactLevel=Prospect potential level for contacts
|
||||
DictionaryCanton=States/Provinces
|
||||
DictionaryRegion=Regions
|
||||
DictionaryCountry=Countries
|
||||
@ -977,7 +991,8 @@ DictionaryEMailTemplates=Email Templates
|
||||
DictionaryUnits=Units
|
||||
DictionaryMeasuringUnits=Measuring Units
|
||||
DictionarySocialNetworks=Social Networks
|
||||
DictionaryProspectStatus=Prospect status
|
||||
DictionaryProspectStatus=Prospect status for companies
|
||||
DictionaryProspectContactStatus=Prospect status for contacts
|
||||
DictionaryHolidayTypes=Types of leave
|
||||
DictionaryOpportunityStatus=Lead status for project/lead
|
||||
DictionaryExpenseTaxCat=Expense report - Transportation categories
|
||||
@ -1076,7 +1091,7 @@ LoginPage=Login page
|
||||
BackgroundImageLogin=Background image
|
||||
PermanentLeftSearchForm=Permanent search form on left menu
|
||||
DefaultLanguage=Default language
|
||||
EnableMultilangInterface=Enable multilanguage support
|
||||
EnableMultilangInterface=Enable multilanguage support for customer or vendor relationships
|
||||
EnableShowLogo=Show the company logo in the menu
|
||||
CompanyInfo=Company/Organization
|
||||
CompanyIds=Company/Organization identities
|
||||
@ -1240,7 +1255,8 @@ WarningAtLeastKeyOrTranslationRequired=A search criteria is required at least fo
|
||||
NewTranslationStringToShow=New translation string to show
|
||||
OriginalValueWas=The original translation is overwritten. Original value was:<br><br>%s
|
||||
TransKeyWithoutOriginalValue=You forced a new translation for the translation key '<strong>%s</strong>' that does not exist in any language files
|
||||
TotalNumberOfActivatedModules=Activated application/modules: <b>%s</b> / <b>%s</b>
|
||||
TitleNumberOfActivatedModules=Activated modules
|
||||
TotalNumberOfActivatedModules=Activated modules: <b>%s</b> / <b>%s</b>
|
||||
YouMustEnableOneModule=You must at least enable 1 module
|
||||
ClassNotFoundIntoPathWarning=Class %s not found in PHP path
|
||||
YesInSummer=Yes in summer
|
||||
@ -1678,7 +1694,7 @@ AGENDA_USE_EVENT_TYPE=Use events types (managed in menu Setup -> Dictionaries ->
|
||||
AGENDA_USE_EVENT_TYPE_DEFAULT=Automatically set this default value for type of event in event create form
|
||||
AGENDA_DEFAULT_FILTER_TYPE=Automatically set this type of event in search filter of agenda view
|
||||
AGENDA_DEFAULT_FILTER_STATUS=Automatically set this status for events in search filter of agenda view
|
||||
AGENDA_DEFAULT_VIEW=Which tab do you want to open by default when selecting menu Agenda
|
||||
AGENDA_DEFAULT_VIEW=Which view do you want to open by default when selecting menu Agenda
|
||||
AGENDA_REMINDER_EMAIL=Enable event reminder <b>by emails</b> (remind option/delay can be defined on each event). Note: Module <strong>%s</strong> must be enabled and correctly setup to have reminder sent at the correct frequency.
|
||||
AGENDA_REMINDER_BROWSER=Enable event reminder <b>on user's browser</b> (when event date is reached, each user is able to refuse this from the browser confirmation question)
|
||||
AGENDA_REMINDER_BROWSER_SOUND=Enable sound notification
|
||||
@ -1686,7 +1702,7 @@ AGENDA_SHOW_LINKED_OBJECT=Show linked object into agenda view
|
||||
##### Clicktodial #####
|
||||
ClickToDialSetup=Click To Dial module setup
|
||||
ClickToDialUrlDesc=Url called when a click on phone picto is done. In URL, you can use tags<br><b>__PHONETO__</b> that will be replaced with the phone number of person to call<br><b>__PHONEFROM__</b> that will be replaced with phone number of calling person (yours)<br><b>__LOGIN__</b> that will be replaced with clicktodial login (defined on user card)<br><b>__PASS__</b> that will be replaced with clicktodial password (defined on user card).
|
||||
ClickToDialDesc=This module makea phone numbers clickable links. A click on the icon will make your phone call the number. This can be used to call a call-center system from Dolibarr that can call the phone number on a SIP system for example.
|
||||
ClickToDialDesc=This module change phone numbers, when using a desktop computer, into clickable links. A click will call the number. This can be used to start the phone call when using a soft phone on your desktop or when using a CTI system based on SIP protocol for example. Note: When using a smartphone, phone numbers are always clickable.
|
||||
ClickToDialUseTelLink=Use just a link "tel:" on phone numbers
|
||||
ClickToDialUseTelLinkDesc=Use this method if your users have a softphone or a software interface installed on the same computer as the browser, and called when you click on a link in your browser that starts with "tel:". If you need a full server solution (no need of local software installation), you must set this to "No" and fill next field.
|
||||
##### Point Of Sale (CashDesk) #####
|
||||
@ -1817,6 +1833,7 @@ EnterAnyCode=This field contains a reference to identify line. Enter any value o
|
||||
Enter0or1=Enter 0 or 1
|
||||
UnicodeCurrency=Enter here between braces, list of byte number that represent the currency symbol. For example: for $, enter [36] - for brazil real R$ [82,36] - for €, enter [8364]
|
||||
ColorFormat=The RGB color is in HEX format, eg: FF0000
|
||||
PictoHelp=Icon name in dolibarr format ('image.png' if into the current theme directory, 'image.png@nom_du_module' if into the directory /img/ of a module)
|
||||
PositionIntoComboList=Position of line into combo lists
|
||||
SellTaxRate=Sale tax rate
|
||||
RecuperableOnly=Yes for VAT "Not Perceived but Recoverable" dedicated for some state in France. Keep value to "No" in all other cases.
|
||||
@ -1843,6 +1860,7 @@ MailToSendSupplierRequestForQuotation=Quotation request
|
||||
MailToSendSupplierOrder=Purchase orders
|
||||
MailToSendSupplierInvoice=Vendor invoices
|
||||
MailToSendContract=Contracts
|
||||
MailToSendReception=Receptions
|
||||
MailToThirdparty=Third parties
|
||||
MailToMember=Members
|
||||
MailToUser=Users
|
||||
@ -1856,6 +1874,7 @@ ExampleOfNewsMessageForMajorRelease=Dolibarr ERP & CRM %s is available. Version
|
||||
ExampleOfNewsMessageForMaintenanceRelease=Dolibarr ERP & CRM %s is available. Version %s is a maintenance version, so contains only bug fixes. We recommend all users to upgrade to this version. A maintenance release does not introduce new features or changes to the database. You may download it from the download area of https://www.dolibarr.org portal (subdirectory Stable versions). You can read the <a href="https://github.com/Dolibarr/dolibarr/blob/develop/ChangeLog">ChangeLog</a> for complete list of changes.
|
||||
MultiPriceRuleDesc=When option "Several levels of prices per product/service" is enabled, you can define different prices (one per price level) for each product. To save you time, here you may enter a rule to autocalculate a price for each level based on the price of the first level, so you will have to only enter a price for the first level for each product. This page is designed to save you time but is useful only if your prices for each level are relative to first level. You can ignore this page in most cases.
|
||||
ModelModulesProduct=Templates for product documents
|
||||
WarehouseModelModules=Templates for documents of warehouses
|
||||
ToGenerateCodeDefineAutomaticRuleFirst=To be able to generate codes automatically, you must first define a manager to auto-define the barcode number.
|
||||
SeeSubstitutionVars=See * note for list of possible substitution variables
|
||||
SeeChangeLog=See ChangeLog file (english only)
|
||||
@ -1894,6 +1913,7 @@ MAIN_PDF_MARGIN_LEFT=Left margin on PDF
|
||||
MAIN_PDF_MARGIN_RIGHT=Right margin on PDF
|
||||
MAIN_PDF_MARGIN_TOP=Top margin on PDF
|
||||
MAIN_PDF_MARGIN_BOTTOM=Bottom margin on PDF
|
||||
MAIN_DOCUMENTS_LOGO_HEIGHT=Height for logo on PDF
|
||||
NothingToSetup=There is no specific setup required for this module.
|
||||
SetToYesIfGroupIsComputationOfOtherGroups=Set this to yes if this group is a computation of other groups
|
||||
EnterCalculationRuleIfPreviousFieldIsYes=Enter calculation rule if previous field was set to Yes (For example 'CODEGRP1+CODEGRP2')
|
||||
@ -1933,13 +1953,14 @@ NothingProcessed=Nothing done
|
||||
XEmailsDoneYActionsDone=%s emails qualified, %s emails successfully processed (for %s record/actions done)
|
||||
RecordEvent=Record email event
|
||||
CreateLeadAndThirdParty=Create lead (and third party if necessary)
|
||||
CreateTicketAndThirdParty=Create ticket (and third party if necessary)
|
||||
CreateTicketAndThirdParty=Create ticket (and link to third party if it was loaded by a previous operation)
|
||||
CodeLastResult=Latest result code
|
||||
NbOfEmailsInInbox=Number of emails in source directory
|
||||
LoadThirdPartyFromName=Load third party searching on %s (load only)
|
||||
LoadThirdPartyFromNameOrCreate=Load third party searching on %s (create if not found)
|
||||
WithDolTrackingID=Dolibarr Reference found in Message ID
|
||||
WithoutDolTrackingID=Dolibarr Reference not found in Message ID
|
||||
WithDolTrackingID=Message from a conversation initiated by a first email sent from Dolibarr
|
||||
WithoutDolTrackingID=Message from a conversation initiated by a first email NOT sent from Dolibarr
|
||||
CreateCandidature=Create candidature
|
||||
FormatZip=Zip
|
||||
MainMenuCode=Menu entry code (mainmenu)
|
||||
ECMAutoTree=Show automatic ECM tree
|
||||
@ -1981,7 +2002,7 @@ ImportSetup=Setup of module Import
|
||||
InstanceUniqueID=Unique ID of the instance
|
||||
SmallerThan=Smaller than
|
||||
LargerThan=Larger than
|
||||
IfTrackingIDFoundEventWillBeLinked=Note that If a tracking ID is found into incoming email, the event will be automatically linked to the related objects.
|
||||
IfTrackingIDFoundEventWillBeLinked=Note that If a tracking ID of an object is found into incoming email, or if the email is an answer of an email aready collected and linked to an object, the event will be automatically linked to the known related object too.
|
||||
WithGMailYouCanCreateADedicatedPassword=With a GMail account, if you enabled the 2 steps validation, it is recommanded to create a dedicated second password for the application instead of using your own account passsword from https://myaccount.google.com/.
|
||||
EmailCollectorTargetDir=It may be a desired behaviour to move the email into another tag/directory when it was processed successfully. Just set name of directory here to use this feature (Do NOT use special characters in name). Note that you must also use a read/write login account.
|
||||
EmailCollectorLoadThirdPartyHelp=You can use this action to use the email content to find and load an existing thirdparty in your database. The found (or created) thirdparty will be used for following actions that need it. In the parameter field you can use for example 'EXTRACT:BODY:Name:\\s([^\\s]*)' if you want to extract the name of the thirdparty from a string 'Name: name to find' found into the body.
|
||||
@ -2005,3 +2026,7 @@ RssNote=Note: Each RSS feed definition provides a widget that you must enable to
|
||||
JumpToBoxes=Jump to Setup -> Widgets
|
||||
MeasuringUnitTypeDesc=Use here a value like "size", "surface", "volume", "weight", "time"
|
||||
MeasuringScaleDesc=The scale is the number of places you have to move the decimal part to match the default reference unit. For "time" unit type, it is the number of seconds. Values between 80 and 99 are reserved values.
|
||||
TemplateAdded=Template added
|
||||
TemplateUpdated=Template updated
|
||||
TemplateDeleted=Template deleted
|
||||
MailToSendEventPush=Template for event reminder emails
|
||||
|
||||
@ -14,7 +14,7 @@ EventsNb=Number of events
|
||||
ListOfActions=List of events
|
||||
EventReports=Event reports
|
||||
Location=Location
|
||||
ToUserOfGroup=To any user in group
|
||||
ToUserOfGroup=Event assigned to any user in group
|
||||
EventOnFullDay=Event on all day(s)
|
||||
MenuToDoActions=All incomplete events
|
||||
MenuDoneActions=All terminated events
|
||||
@ -86,6 +86,8 @@ ProposalDeleted=Proposal deleted
|
||||
OrderDeleted=Order deleted
|
||||
InvoiceDeleted=Invoice deleted
|
||||
DraftInvoiceDeleted=Draft invoice deleted
|
||||
CONTACT_CREATEInDolibarr=Contact %s created
|
||||
CONTACT_DELETEInDolibarr=Contact %s deleted
|
||||
PRODUCT_CREATEInDolibarr=Product %s created
|
||||
PRODUCT_MODIFYInDolibarr=Product %s modified
|
||||
PRODUCT_DELETEInDolibarr=Product %s deleted
|
||||
@ -158,3 +160,9 @@ DateStartPlusOne=Date start + 1 hour
|
||||
SetAllEventsToTodo=Set all events to todo
|
||||
SetAllEventsToInProgress=Set all events to in progress
|
||||
SetAllEventsToFinished=Set all events to finished
|
||||
ReminderTime=Reminder period before the event
|
||||
TimeType=Duration type
|
||||
ReminderType=Callback type
|
||||
AddReminder=Create an automatic reminder notification for this event
|
||||
ErrorReminderActionCommCreation=Error creating the reminder notification for this event
|
||||
BrowserPush=Browser Notification
|
||||
|
||||
@ -83,6 +83,8 @@ BoxTitleLatestModifiedSupplierOrders=Vendor Orders: last %s modified
|
||||
BoxTitleLastModifiedCustomerBills=Customer Invoices: last %s modified
|
||||
BoxTitleLastModifiedCustomerOrders=Sales Orders: last %s modified
|
||||
BoxTitleLastModifiedPropals=Latest %s modified proposals
|
||||
BoxTitleLatestModifiedJobPositions=Latest %s modified jobs
|
||||
BoxTitleLatestModifiedCandidatures=Latest %s modified candidatures
|
||||
ForCustomersInvoices=Customers invoices
|
||||
ForCustomersOrders=Customers orders
|
||||
ForProposals=Proposals
|
||||
@ -100,3 +102,5 @@ SuspenseAccountNotDefined=Suspense account isn't defined
|
||||
BoxLastCustomerShipments=Last customer shipments
|
||||
BoxTitleLastCustomerShipments=Latest %s customer shipments
|
||||
NoRecordedShipments=No recorded customer shipment
|
||||
# Pages
|
||||
AccountancyHome=Accountancy
|
||||
|
||||
@ -77,7 +77,7 @@ POSModule=POS Module
|
||||
BasicPhoneLayout=Use basic layout for phones
|
||||
SetupOfTerminalNotComplete=Setup of terminal %s is not complete
|
||||
DirectPayment=Direct payment
|
||||
DirectPaymentButton=Direct cash payment button
|
||||
DirectPaymentButton=Add a "Direct cash payment" button
|
||||
InvoiceIsAlreadyValidated=Invoice is already validated
|
||||
NoLinesToBill=No lines to bill
|
||||
CustomReceipt=Custom Receipt
|
||||
@ -94,12 +94,12 @@ TakeposConnectorMethodDescription=External module with extra features. Posibilit
|
||||
PrintMethod=Print method
|
||||
ReceiptPrinterMethodDescription=Powerful method with a lot of parameters. Full customizable with templates. Cannot print from the cloud.
|
||||
ByTerminal=By terminal
|
||||
TakeposNumpadUsePaymentIcon=Use payment icon on numpad
|
||||
TakeposNumpadUsePaymentIcon=Use icon instead of text on payment buttons of numpad
|
||||
CashDeskRefNumberingModules=Numbering module for POS sales
|
||||
CashDeskGenericMaskCodes6 = <br><b>{TN}</b> tag is used to add the terminal number
|
||||
TakeposGroupSameProduct=Group same products lines
|
||||
StartAParallelSale=Start a new parallel sale
|
||||
ControlCashOpening=Control cash box at opening pos
|
||||
ControlCashOpening=Control cash box at opening POS
|
||||
CloseCashFence=Close cash fence
|
||||
CashReport=Cash report
|
||||
MainPrinterToUse=Main printer to use
|
||||
@ -115,5 +115,10 @@ ScanToOrder=Scan QR code to order
|
||||
Appearance=Appearance
|
||||
HideCategoryImages=Hide Category Images
|
||||
HideProductImages=Hide Product Images
|
||||
NumberOfLinesToShow=Number of lines to show in image box
|
||||
DefineTablePlan=Define table plan
|
||||
NumberOfLinesToShow=Number of lines of images to show
|
||||
DefineTablePlan=Define tables plan
|
||||
GiftReceiptButton=Add a "Gift receipt" button
|
||||
GiftReceipt=Gift receipt
|
||||
ModuleReceiptPrinterMustBeEnabled=Module Receipt printer must have been enabled first
|
||||
AllowDelayedPayment=Allow delayed payment
|
||||
PrintPaymentMethodOnReceipts=Print payment method on tickets|receipts
|
||||
|
||||
@ -69,6 +69,7 @@ SocialContribution=Social or fiscal tax
|
||||
SocialContributions=Social or fiscal taxes
|
||||
SocialContributionsDeductibles=Deductible social or fiscal taxes
|
||||
SocialContributionsNondeductibles=Nondeductible social or fiscal taxes
|
||||
DateOfSocialContribution=Date of social or fiscal tax
|
||||
LabelContrib=Label contribution
|
||||
TypeContrib=Type contribution
|
||||
MenuSpecialExpenses=Special expenses
|
||||
|
||||
@ -28,7 +28,7 @@ MenuRunningServices=Running services
|
||||
MenuExpiredServices=Expired services
|
||||
MenuClosedServices=Closed services
|
||||
NewContract=New contract
|
||||
NewContractSubscription=New contract/subscription
|
||||
NewContractSubscription=New contract or subscription
|
||||
AddContract=Create contract
|
||||
DeleteAContract=Delete a contract
|
||||
ActivateAllOnContract=Activate all services
|
||||
|
||||
@ -136,7 +136,8 @@ ErrorNewValueCantMatchOldValue=New value can't be equal to old one
|
||||
ErrorFailedToValidatePasswordReset=Failed to reinit password. May be the reinit was already done (this link can be used only one time). If not, try to restart the reinit process.
|
||||
ErrorToConnectToMysqlCheckInstance=Connect to database fails. Check database server is running (for example, with mysql/mariadb, you can launch it from command line with 'sudo service mysql start').
|
||||
ErrorFailedToAddContact=Failed to add contact
|
||||
ErrorDateMustBeBeforeToday=The date cannot be greater than today
|
||||
ErrorDateMustBeBeforeToday=The date must be lower than today
|
||||
ErrorDateMustBeInFuture=The date must be greater than today
|
||||
ErrorPaymentModeDefinedToWithoutSetup=A payment mode was set to type %s but setup of module Invoice was not completed to define information to show for this payment mode.
|
||||
ErrorPHPNeedModule=Error, your PHP must have module <b>%s</b> installed to use this feature.
|
||||
ErrorOpenIDSetupNotComplete=You setup Dolibarr config file to allow OpenID authentication, but URL of OpenID service is not defined into constant %s
|
||||
@ -239,6 +240,9 @@ ErrorBatchNoFoundEnoughQuantityForProductInWarehouse=No enough quantity for this
|
||||
ErrorOnlyOneFieldForGroupByIsPossible=Only 1 field for the 'Group by' is possible (others are discarded)
|
||||
ErrorTooManyDifferentValueForSelectedGroupBy=Found too many different value (more than <b>%s</b>) for the field '<b>%s</b>', so we can't use it as a 'Group by' for graphics. The field 'Group By' has been removed. May be you wanted to use it as an X-Axis ?
|
||||
ErrorReplaceStringEmpty=Error, the string to replace into is empty
|
||||
ErrorProductNeedBatchNumber=Error, product '<b>%s</b>' need a lot/serial number
|
||||
ErrorProductDoesNotNeedBatchNumber=Error, product '<b>%s</b>' does not accept a lot/serial number
|
||||
ErrorFailedToReadObject=Error, failed to read object of type <b>%s</b>
|
||||
# Warnings
|
||||
WarningParamUploadMaxFileSizeHigherThanPostMaxSize=Your PHP parameter upload_max_filesize (%s) is higher than PHP parameter post_max_size (%s). This is not a consistent setup.
|
||||
WarningPasswordSetWithNoAccount=A password was set for this member. However, no user account was created. So this password is stored but can't be used to login to Dolibarr. It may be used by an external module/interface but if you don't need to define any login nor password for a member, you can disable option "Manage a login for each member" from Member module setup. If you need to manage a login but don't need any password, you can keep this field empty to avoid this warning. Note: Email can also be used as a login if the member is linked to a user.
|
||||
|
||||
@ -1,8 +1,11 @@
|
||||
# Dolibarr language file - Source file is en_US - languages
|
||||
Language_am_ET=Ethiopian
|
||||
Language_ar_AR=Arabic
|
||||
Language_ar_EG=Arabic (Egypt)
|
||||
Language_ar_SA=Arabic
|
||||
Language_az_AZ=Azerbaijani
|
||||
Language_bn_BD=Bengali
|
||||
Language_bn_IN=Bengali (India)
|
||||
Language_bg_BG=Bulgarian
|
||||
Language_bs_BA=Bosnian
|
||||
Language_ca_ES=Catalan
|
||||
@ -20,6 +23,7 @@ Language_en_GB=English (United Kingdom)
|
||||
Language_en_IN=English (India)
|
||||
Language_en_NZ=English (New Zealand)
|
||||
Language_en_SA=English (Saudi Arabia)
|
||||
Language_en_SG=English (Singapore)
|
||||
Language_en_US=English (United States)
|
||||
Language_en_ZA=English (South Africa)
|
||||
Language_es_ES=Spanish
|
||||
@ -29,6 +33,7 @@ Language_es_CL=Spanish (Chile)
|
||||
Language_es_CO=Spanish (Colombia)
|
||||
Language_es_DO=Spanish (Dominican Republic)
|
||||
Language_es_EC=Spanish (Ecuador)
|
||||
Language_es_GT=Spanish (Guatemala)
|
||||
Language_es_HN=Spanish (Honduras)
|
||||
Language_es_MX=Spanish (Mexico)
|
||||
Language_es_PA=Spanish (Panama)
|
||||
@ -36,6 +41,7 @@ Language_es_PY=Spanish (Paraguay)
|
||||
Language_es_PE=Spanish (Peru)
|
||||
Language_es_PR=Spanish (Puerto Rico)
|
||||
Language_es_UY=Spanish (Uruguay)
|
||||
Language_es_GT=Spanish (Guatemala)
|
||||
Language_es_VE=Spanish (Venezuela)
|
||||
Language_et_EE=Estonian
|
||||
Language_eu_ES=Basque
|
||||
@ -44,15 +50,22 @@ Language_fi_FI=Finnish
|
||||
Language_fr_BE=French (Belgium)
|
||||
Language_fr_CA=French (Canada)
|
||||
Language_fr_CH=French (Switzerland)
|
||||
Language_fr_CI=French (Cost Ivory)
|
||||
Language_fr_CM=French (Cameroun)
|
||||
Language_fr_FR=French
|
||||
Language_fr_GA=French (Gabon)
|
||||
Language_fr_NC=French (New Caledonia)
|
||||
Language_fr_SN=French (Senegal)
|
||||
Language_fy_NL=Frisian
|
||||
Language_gl_ES=Galician
|
||||
Language_he_IL=Hebrew
|
||||
Language_hi_IN=Hindi (India)
|
||||
Language_hr_HR=Croatian
|
||||
Language_hu_HU=Hungarian
|
||||
Language_id_ID=Indonesian
|
||||
Language_is_IS=Icelandic
|
||||
Language_it_IT=Italian
|
||||
Language_it_CH=Italian (Switzerland)
|
||||
Language_ja_JP=Japanese
|
||||
Language_ka_GE=Georgian
|
||||
Language_km_KH=Khmer
|
||||
@ -64,6 +77,7 @@ Language_lv_LV=Latvian
|
||||
Language_mk_MK=Macedonian
|
||||
Language_mn_MN=Mongolian
|
||||
Language_nb_NO=Norwegian (Bokmål)
|
||||
Language_ne_NP=Nepali
|
||||
Language_nl_BE=Dutch (Belgium)
|
||||
Language_nl_NL=Dutch
|
||||
Language_pl_PL=Polish
|
||||
@ -86,4 +100,5 @@ Language_uz_UZ=Uzbek
|
||||
Language_vi_VN=Vietnamese
|
||||
Language_zh_CN=Chinese
|
||||
Language_zh_TW=Chinese (Traditional)
|
||||
Language_zh_HK=Chinese (Hong Kong)
|
||||
Language_bh_MY=Malay
|
||||
|
||||
@ -168,3 +168,7 @@ OutGoingEmailSetupForEmailing=Outgoing email setup (for module %s)
|
||||
DefaultOutgoingEmailSetup=Default outgoing email setup
|
||||
Information=Information
|
||||
ContactsWithThirdpartyFilter=Contacts with third-party filter
|
||||
Unanswered=Unanswered
|
||||
Answered=Answered
|
||||
IsNotAnAnswer=Is not answer (initial email)
|
||||
IsAnAnswer=Is an answer of an initial email
|
||||
|
||||
@ -355,8 +355,8 @@ PriceUTTC=U.P. (inc. tax)
|
||||
Amount=Amount
|
||||
AmountInvoice=Invoice amount
|
||||
AmountInvoiced=Amount invoiced
|
||||
AmountInvoicedHT=Amount invoiced (incl. tax)
|
||||
AmountInvoicedTTC=Amount invoiced (excl. tax)
|
||||
AmountInvoicedHT=Amount invoiced (excl. tax)
|
||||
AmountInvoicedTTC=Amount invoiced (inc. tax)
|
||||
AmountPayment=Payment amount
|
||||
AmountHTShort=Amount (excl.)
|
||||
AmountTTCShort=Amount (inc. tax)
|
||||
@ -485,6 +485,7 @@ Categories=Tags/categories
|
||||
Category=Tag/category
|
||||
By=By
|
||||
From=From
|
||||
FromDate=From
|
||||
FromLocation=From
|
||||
to=to
|
||||
To=to
|
||||
@ -687,6 +688,7 @@ Method=Method
|
||||
Receive=Receive
|
||||
CompleteOrNoMoreReceptionExpected=Complete or nothing more expected
|
||||
ExpectedValue=Expected Value
|
||||
ExpectedQty=Expected Qty
|
||||
PartialWoman=Partial
|
||||
TotalWoman=Total
|
||||
NeverReceived=Never received
|
||||
@ -703,6 +705,7 @@ MenuECM=Documents
|
||||
MenuAWStats=AWStats
|
||||
MenuMembers=Members
|
||||
MenuAgendaGoogle=Google agenda
|
||||
MenuTaxesAndSpecialExpenses=Taxes | Special expenses
|
||||
ThisLimitIsDefinedInSetup=Dolibarr limit (Menu home-setup-security): %s Kb, PHP limit: %s Kb
|
||||
NoFileFound=No documents saved in this directory
|
||||
CurrentUserLanguage=Current language
|
||||
@ -725,7 +728,7 @@ Page=Page
|
||||
Notes=Notes
|
||||
AddNewLine=Add new line
|
||||
AddFile=Add file
|
||||
FreeZone=Not a predefined product/service
|
||||
FreeZone=Free-text product
|
||||
FreeLineOfType=Free-text item, type:
|
||||
CloneMainAttributes=Clone object with its main attributes
|
||||
ReGeneratePDF=Re-generate PDF
|
||||
@ -942,6 +945,39 @@ ShortThursday=T
|
||||
ShortFriday=F
|
||||
ShortSaturday=S
|
||||
ShortSunday=S
|
||||
one=one
|
||||
two=two
|
||||
three=three
|
||||
four=four
|
||||
five=five
|
||||
six=six
|
||||
seven=seven
|
||||
eight=eight
|
||||
nine=nine
|
||||
ten=ten
|
||||
eleven=eleven
|
||||
twelve=twelve
|
||||
thirteen=thirdteen
|
||||
fourteen=fourteen
|
||||
fifteen=fifteen
|
||||
sixteen=sixteen
|
||||
seventeen=seventeen
|
||||
eighteen=eighteen
|
||||
nineteen=nineteen
|
||||
twenty=twenty
|
||||
thirty=thirty
|
||||
forty=forty
|
||||
fifty=fifty
|
||||
sixty=sixty
|
||||
seventy=seventy
|
||||
eighty=eighty
|
||||
ninety=ninety
|
||||
hundred=hundred
|
||||
thousand=thousand
|
||||
million=million
|
||||
billion=billion
|
||||
trillion=trillion
|
||||
quadrillion=quadrillion
|
||||
SelectMailModel=Select an email template
|
||||
SetRef=Set ref
|
||||
Select2ResultFoundUseArrows=Some results found. Use arrows to select.
|
||||
@ -1039,3 +1075,11 @@ SwitchInEditModeToAddTranslation=Switch in edit mode to add translations for thi
|
||||
NotUsedForThisCustomer=Not used for this customer
|
||||
AmountMustBePositive=Amount must be positive
|
||||
ByStatus=By status
|
||||
InformationMessage=Information
|
||||
Used=Used
|
||||
ASAP=As Soon As Possible
|
||||
CREATEInDolibarr=Record %s create
|
||||
MODIFYInDolibarr=Record %s modified
|
||||
DELETEInDolibarr=Record %s deleted
|
||||
VALIDATEInDolibarr=Record %s validated
|
||||
APPROVEDInDolibarr=Record %s approved
|
||||
|
||||
@ -81,7 +81,7 @@ DeleteType=Delete
|
||||
VoteAllowed=Vote allowed
|
||||
Physical=Physical
|
||||
Moral=Moral
|
||||
MorPhy=Moral/Physical
|
||||
MorPhy=Nature
|
||||
Reenable=Reenable
|
||||
ResiliateMember=Terminate a member
|
||||
ConfirmResiliateMember=Are you sure you want to terminate this member?
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
Mrp=Manufacturing Orders
|
||||
MO=Manufacturing Order
|
||||
MOs=Manufacturing orders
|
||||
MRPDescription=Module to manage production and Manufacturing Orders (MO).
|
||||
MRPArea=MRP Area
|
||||
MrpSetupPage=Setup of module MRP
|
||||
|
||||
@ -97,10 +97,8 @@ PredefinedMailContentSendSupplierOrder=__(Hello)__\n\nPlease find our order __RE
|
||||
PredefinedMailContentSendSupplierInvoice=__(Hello)__\n\nPlease find invoice __REF__ attached\n\n\n__(Sincerely)__\n\n__USER_SIGNATURE__
|
||||
PredefinedMailContentSendShipping=__(Hello)__\n\nPlease find shipping __REF__ attached\n\n\n__(Sincerely)__\n\n__USER_SIGNATURE__
|
||||
PredefinedMailContentSendFichInter=__(Hello)__\n\nPlease find intervention __REF__ attached\n\n\n__(Sincerely)__\n\n__USER_SIGNATURE__
|
||||
PredefinedMailContentThirdparty=__(Hello)__\n\n\n__(Sincerely)__\n\n__USER_SIGNATURE__
|
||||
PredefinedMailContentContact=__(Hello)__\n\n\n__(Sincerely)__\n\n__USER_SIGNATURE__
|
||||
PredefinedMailContentUser=__(Hello)__\n\n\n__(Sincerely)__\n\n__USER_SIGNATURE__
|
||||
PredefinedMailContentLink=You can click on the link below to make your payment if it is not already done.\n\n%s\n\n
|
||||
PredefinedMailContentGeneric=__(Hello)__\n\n\n__(Sincerely)__\n\n__USER_SIGNATURE__
|
||||
DemoDesc=Dolibarr is a compact ERP/CRM supporting several business modules. A demo showcasing all modules makes no sense as this scenario never occurs (several hundred available). So, several demo profiles are available.
|
||||
ChooseYourDemoProfil=Choose the demo profile that best suits your needs...
|
||||
ChooseYourDemoProfilMore=...or build your own profile<br>(manual module selection)
|
||||
@ -255,7 +253,10 @@ YourPasswordHasBeenReset=Your password has been reset successfully
|
||||
ApplicantIpAddress=IP address of applicant
|
||||
SMSSentTo=SMS sent to %s
|
||||
MissingIds=Missing ids
|
||||
RecordCreatedByEmailCollector=Record created by email collector from email MSGID %s
|
||||
ThirdPartyCreatedByEmailCollector=Third party created by email collector from email MSGID %s
|
||||
ContactCreatedByEmailCollector=Contact/address created by email collector from email MSGID %s
|
||||
ProjectCreatedByEmailCollector=Project created by email collector from email MSGID %s
|
||||
TicketCreatedByEmailCollector=Ticket created by email collector from email MSGID %s
|
||||
OpeningHoursFormatDesc=Use a - to separate opening and closing hours.<br>Use a space to enter different ranges.<br>Example: 8-12 14-18
|
||||
|
||||
##### Export #####
|
||||
@ -277,7 +278,9 @@ LinesToImport=Lines to import
|
||||
|
||||
MemoryUsage=Memory usage
|
||||
RequestDuration=Duration of request
|
||||
ProductsPerPopularity=Products/Services by popularity
|
||||
PopuProp=Products/Services by popularity in Proposals
|
||||
PopuCom=Products/Services by popularity in Orders
|
||||
ProductStatistics=Products/Services Statistics
|
||||
NbOfQtyInOrders=Qty in orders
|
||||
SelectTheTypeOfObjectToAnalyze=Select the type of object to analyze...
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user