Merge branch 'develop' of https://github.com/Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
3fdc57cc56
70
ChangeLog
70
ChangeLog
@ -4,6 +4,7 @@ English Dolibarr ChangeLog
|
|||||||
|
|
||||||
***** ChangeLog for 3.4 compared to 3.3.2 *****
|
***** ChangeLog for 3.4 compared to 3.3.2 *****
|
||||||
For users:
|
For users:
|
||||||
|
- New: Can use ODS templates as document templates.
|
||||||
- New: Add link to autofill/reset with quantity to ship when creating a
|
- New: Add link to autofill/reset with quantity to ship when creating a
|
||||||
delivery receipt.
|
delivery receipt.
|
||||||
- New: Event into calendar use different colors for different users.
|
- New: Event into calendar use different colors for different users.
|
||||||
@ -11,45 +12,48 @@ For users:
|
|||||||
- New: Add a tab "consumption" on thirdparties to list products bought/sells.
|
- New: Add a tab "consumption" on thirdparties to list products bought/sells.
|
||||||
- New: Some performance enhancements.
|
- New: Some performance enhancements.
|
||||||
- New: Can attach files onto trip and expenses modules.
|
- New: Can attach files onto trip and expenses modules.
|
||||||
- New: Add option MAIN_PDF_TITLE_BACKGROUND_COLOR.
|
- New: Add hidden option MAIN_PDF_TITLE_BACKGROUND_COLOR.
|
||||||
- New: Merge tab customer and prospect.
|
- New: Merge tab customer and prospect.
|
||||||
- New: Add ES formated address country rule.
|
- New: Add ES formated address country rule.
|
||||||
- New: Can define a hierarchical responsible on user.
|
- New: Can define a hierarchical responsible on user and add a tree view to
|
||||||
- New: Add a hierarchical view for users.
|
see hierarchy of users.
|
||||||
- New: Can expand/collapse menus, categories and users list.
|
- New: Can expand/collapse menus, categories and users list.
|
||||||
- New: extra parameters are supported into ODT templates.
|
- New: extra parameters are supported into ODT/ODS templates.
|
||||||
- New: total per vat rate are available as tags for ODT templates.
|
- New: total per vat rate are available as tags for ODT/ODS templates.
|
||||||
- New: Add more types for extra parameters (lists, phone, emails, checkbox, prices).
|
|
||||||
- New: Some part of interface use more CSS3 (ie: agenda)
|
- New: Some part of interface use more CSS3 (ie: agenda)
|
||||||
- New: [ task #707 ] Create option ProfIdx are mandatory to validate a invoice.
|
- New: [ task #707 ] Create option "ProfIdx is mandatory to validate a invoice".
|
||||||
- New: Can define if we want to use VAT or not for subscriptions (foundation module).
|
- New: Can define if we want to use VAT or not for subscriptions (foundation module).
|
||||||
- New: Can define a default choice for choice "More action when recording
|
- New: Can define a default choice for "More action when recording a
|
||||||
a subscription" (foundation module).
|
subscription" (foundation module).
|
||||||
- New: Add link to check professional id for india.
|
- New: Add link to check professional id for India.
|
||||||
- New: [ task #731 ] Uniformize ref generation
|
- New: [ task #731 ] Uniformize ref generation
|
||||||
- New: [ task #748 ] Add a link "Dolibarr" into left menu
|
- New: [ task #748 ] Add a link "Dolibarr" into left menu
|
||||||
- New: Script email_unpaid_invoices_to_representative accepts now a parameter test
|
- New: Script email_unpaid_invoices_to_representative accepts now a parameter "test"
|
||||||
and a delay.
|
and a "late delay".
|
||||||
- New: Can define a different clicktodial setup per user.
|
- New: Can define different clicktodial setups for each user.
|
||||||
- New: Add option INVOICE_CAN_NEVER_BE_REMOVED.
|
- New: Add hidden option INVOICE_CAN_NEVER_BE_REMOVED.
|
||||||
- New: Enhance agenda module to reach RFC2445 (add busy information).
|
- New: Enhance agenda module to reach RFC2445 ("type" not enabled by default and add
|
||||||
|
"busy" information).
|
||||||
- New: Add module Opensurvey.
|
- New: Add module Opensurvey.
|
||||||
- New: Default aprrover for holidays i sby default hierchical parent.
|
- New: Default approver for holidays is set by default to hierchical parent.
|
||||||
- First change to prepare feature "click to print" (IPP) for PDF.
|
- First change to prepare feature "click to print" (IPP) for PDF.
|
||||||
- New: [ task #350 ] Merge tab customer and prospect
|
- New: [ task #350 ] Merge tab customer and prospect.
|
||||||
- New: [ task #710 ] Add substitution into mailing send (and HTML is now valid)
|
- New: [ task #710 ] Add substitution into mailing send (and HTML is now valid).
|
||||||
- New: [ task #711 ] Add combobox for contact as done for product/thirdparty
|
- New: [ task #711 ] Add combobox for contact, as done for product/thirdparty.
|
||||||
- New: [ task #714 ] In Emailing module admin autogenerate security key of READRECIEPT
|
- New: [ task #714 ] In Emailing module admin autogenerate security key of READRECEIPT.
|
||||||
- New: [ task #743 ] GED : Add aministration option to disabled autotree to display
|
- New: [ task #743 ] GED : Add aministration option to disable autotree display.
|
||||||
- New: [ task #767 ] Customer Address fallback when a contact doesn't have an address
|
- New: [ task #767 ] Customer Address fallback when a contact doesn't have an address.
|
||||||
- New: [ task #768 ] WYSIWYG for all mail
|
- New: [ task #768 ] WYSIWYG for all mails.
|
||||||
- New: [ task #773 ] Add Project document in GED(ECM) modules
|
- New: [ task #773 ] Add Project document in GED(ECM) modules.
|
||||||
- New: [ task #783 ] Add checkbox and radio into extrafield feature
|
- New: [ task #783 ] Add more types for extra parameters (lists, phone, emails, checkbox,
|
||||||
- New: [ task #798 ] Add range limit date on product/services as it is done on order and invoice
|
prices, radio).
|
||||||
- New: [ task #814 ] Add extrafield feature into Project/project tasks module
|
- New: [ task #798 ] Add range limit date on product/services as it is done on order
|
||||||
- New: [ task #770 ] Add ODT document generation for Projects module
|
and invoice.
|
||||||
- New: [ task #741 ] Add intervention box
|
- New: [ task #814 ] Add extrafield feature for projects ands tasks.
|
||||||
- New: [ task #826 ] Optionnal increase stock when deleting an invoice already validated
|
- New: [ task #770 ] Add ODT document generation for Projects module.
|
||||||
|
- New: [ task #741 ] Add intervention box.
|
||||||
|
- New: [ task #826 ] Optionnal increase stock when deleting an invoice already validated.
|
||||||
|
- New: [ task #823 ] Shipping_validate email notification.
|
||||||
|
|
||||||
For translators:
|
For translators:
|
||||||
- Update language files.
|
- Update language files.
|
||||||
@ -59,7 +63,7 @@ For developers:
|
|||||||
- An external module can force its theme.
|
- An external module can force its theme.
|
||||||
- Add function dol_set_focus('#xxx').
|
- Add function dol_set_focus('#xxx').
|
||||||
- A mymodule can bring its own core/modules/mymodule/modules_mymodule.php file.
|
- A mymodule can bring its own core/modules/mymodule/modules_mymodule.php file.
|
||||||
- Removed not used libraries.
|
- Removed some not used libraries.
|
||||||
- More web services.
|
- More web services.
|
||||||
- Renamed some database fields, code variables and parameters from french to english.
|
- Renamed some database fields, code variables and parameters from french to english.
|
||||||
- First change to manage margins on contracts.
|
- First change to manage margins on contracts.
|
||||||
@ -87,7 +91,7 @@ WARNING: If you used external modules, some of them may need to be upgraded due
|
|||||||
|
|
||||||
***** ChangeLog for 3.3.2 compared to 3.3.1 *****
|
***** ChangeLog for 3.3.2 compared to 3.3.1 *****
|
||||||
|
|
||||||
- Fix: Ducth (nl_NL) translation
|
- Fix: Dutch (nl_NL) translation
|
||||||
- Fix: [ bug #790 ] Spanish localtax RE not being correctly calculated
|
- Fix: [ bug #790 ] Spanish localtax RE not being correctly calculated
|
||||||
- Generalize fix: file with a specific mask not found, again
|
- Generalize fix: file with a specific mask not found, again
|
||||||
- Fix: translations and BILL_SUPPLIER_BUILDDOC trigger
|
- Fix: translations and BILL_SUPPLIER_BUILDDOC trigger
|
||||||
@ -100,9 +104,9 @@ WARNING: If you used external modules, some of them may need to be upgraded due
|
|||||||
- Fix: [ bug #806 ] Margins module with orders2invoice does not respect cost price
|
- Fix: [ bug #806 ] Margins module with orders2invoice does not respect cost price
|
||||||
- Fix: Orderstoinvoice didn't act as expected when no order was checked
|
- Fix: Orderstoinvoice didn't act as expected when no order was checked
|
||||||
- Fix: Bad link to all proposals into Third party card if customer is prospect
|
- Fix: Bad link to all proposals into Third party card if customer is prospect
|
||||||
|
- Fix: [ bug #774 ] Bug on creating event with box "all day" crossed
|
||||||
- Fix: [ bug #789 ] VAT not being calculated in POS
|
- Fix: [ bug #789 ] VAT not being calculated in POS
|
||||||
- Fix: [ bug #794 ] Lost filter on zipcode in prospect list
|
- Fix: [ bug #794 ] Lost filter on zipcode in prospect list
|
||||||
- Fix: [ bug #774 ] Bug on creating event with box "all day" crossed
|
|
||||||
- Fix: [ bug #810 ] Cannot update ODT template path
|
- Fix: [ bug #810 ] Cannot update ODT template path
|
||||||
- Fix: [ bug #824 ] MAIN_DB_PREFIX not use into dictionnary
|
- Fix: [ bug #824 ] MAIN_DB_PREFIX not use into dictionnary
|
||||||
- Fix: [ bug #828 ] Error when code_region is not a number in llx_c_regions (with postgres)
|
- Fix: [ bug #828 ] Error when code_region is not a number in llx_c_regions (with postgres)
|
||||||
|
|||||||
@ -133,7 +133,11 @@ class modMyModule extends DolibarrModules
|
|||||||
$this->tabs = array();
|
$this->tabs = array();
|
||||||
|
|
||||||
// Dictionnaries
|
// Dictionnaries
|
||||||
if (! isset($conf->mymodule->enabled)) $conf->mymodule->enabled=0;
|
if (! isset($conf->mymodule->enabled))
|
||||||
|
{
|
||||||
|
$conf->mymodule=new stdClass();
|
||||||
|
$conf->mymodule->enabled=0;
|
||||||
|
}
|
||||||
$this->dictionnaries=array();
|
$this->dictionnaries=array();
|
||||||
/* Example:
|
/* Example:
|
||||||
if (! isset($conf->mymodule->enabled)) $conf->mymodule->enabled=0; // This is to avoid warnings
|
if (! isset($conf->mymodule->enabled)) $conf->mymodule->enabled=0; // This is to avoid warnings
|
||||||
|
|||||||
@ -1520,6 +1520,11 @@ class Adherent extends CommonObject
|
|||||||
$lien = '<a href="'.DOL_URL_ROOT.'/adherents/card_subscriptions.php?rowid='.$this->id.'">';
|
$lien = '<a href="'.DOL_URL_ROOT.'/adherents/card_subscriptions.php?rowid='.$this->id.'">';
|
||||||
$lienfin='</a>';
|
$lienfin='</a>';
|
||||||
}
|
}
|
||||||
|
if ($option == 'category')
|
||||||
|
{
|
||||||
|
$lien = '<a href="'.DOL_URL_ROOT.'/categories/categorie.php?id='.$this->id.'&type=3">';
|
||||||
|
$lienfin='</a>';
|
||||||
|
}
|
||||||
|
|
||||||
$picto='user';
|
$picto='user';
|
||||||
$label=$langs->trans("ShowMember");
|
$label=$langs->trans("ShowMember");
|
||||||
|
|||||||
@ -125,7 +125,7 @@ if (preg_match('/del_(.*)/',$action,$reg))
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Affichage du formulaire de saisie
|
* View
|
||||||
*/
|
*/
|
||||||
|
|
||||||
llxHeader();
|
llxHeader();
|
||||||
@ -184,48 +184,7 @@ print "</center>";
|
|||||||
|
|
||||||
print "</form>\n";
|
print "</form>\n";
|
||||||
|
|
||||||
print '</div>';
|
dol_fiche_end();
|
||||||
|
|
||||||
/*
|
|
||||||
* Other options
|
|
||||||
*/
|
|
||||||
|
|
||||||
print_titre($langs->trans("OtherOptions"));
|
|
||||||
|
|
||||||
$var=true;
|
|
||||||
|
|
||||||
print '<table class="noborder allwidth">'."\n";
|
|
||||||
print '<tr class="liste_titre">'."\n";
|
|
||||||
print '<td>'.$langs->trans("Parameters").'</td>'."\n";
|
|
||||||
print '<td align="center" width="20"> </td>'."\n";
|
|
||||||
print '<td align="center" width="100">'.$langs->trans("Value").'</td>'."\n";
|
|
||||||
print '</tr>'."\n";
|
|
||||||
|
|
||||||
// Manual or automatic
|
|
||||||
$var=!$var;
|
|
||||||
print '<tr '.$bc[$var].'>'."\n";
|
|
||||||
print '<td>'.$langs->trans("AGENDA_USE_EVENT_TYPE").'</td>'."\n";
|
|
||||||
print '<td align="center" width="20"> </td>'."\n";
|
|
||||||
|
|
||||||
print '<td align="center" width="100">'."\n";
|
|
||||||
if ($conf->use_javascript_ajax)
|
|
||||||
{
|
|
||||||
print ajax_constantonoff('AGENDA_USE_EVENT_TYPE');
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if($conf->global->AGENDA_USE_EVENT_TYPE == 0)
|
|
||||||
{
|
|
||||||
print '<a href="'.$_SERVER['PHP_SELF'].'?action=set_AGENDA_USE_EVENT_TYPE">'.img_picto($langs->trans("Disabled"),'off').'</a>';
|
|
||||||
}
|
|
||||||
else if($conf->global->BUSINESS_VISIBLE_TO_ALL_BY_DEFAULT == 1)
|
|
||||||
{
|
|
||||||
print '<a href="'.$_SERVER['PHP_SELF'].'?action=del_AGENDA_USE_EVENT_TYPE">'.img_picto($langs->trans("Enabled"),'on').'</a>';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
print '</td></tr>'."\n";
|
|
||||||
|
|
||||||
print '</table>';
|
|
||||||
|
|
||||||
print "<br>";
|
print "<br>";
|
||||||
|
|
||||||
|
|||||||
135
htdocs/admin/agenda_other.php
Normal file
135
htdocs/admin/agenda_other.php
Normal file
@ -0,0 +1,135 @@
|
|||||||
|
<?php
|
||||||
|
/* Copyright (C) 2008-2010 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
|
* Copyright (C) 2011 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
|
* Copyright (C) 2011-2012 Juanjo Menent <jmenent@2byte.es>
|
||||||
|
*
|
||||||
|
* 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 <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \file htdocs/admin/agenda.php
|
||||||
|
* \ingroup agenda
|
||||||
|
* \brief Autocreate actions for agenda module setup page
|
||||||
|
*/
|
||||||
|
|
||||||
|
require '../main.inc.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/agenda.lib.php';
|
||||||
|
|
||||||
|
if (!$user->admin)
|
||||||
|
accessforbidden();
|
||||||
|
|
||||||
|
$langs->load("admin");
|
||||||
|
$langs->load("other");
|
||||||
|
|
||||||
|
$action = GETPOST('action','alpha');
|
||||||
|
$cancel = GETPOST('cancel','alpha');
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Actions
|
||||||
|
*/
|
||||||
|
|
||||||
|
if (preg_match('/set_(.*)/',$action,$reg))
|
||||||
|
{
|
||||||
|
$code=$reg[1];
|
||||||
|
$value=(GETPOST($code) ? GETPOST($code) : 1);
|
||||||
|
if (dolibarr_set_const($db, $code, $value, 'chaine', 0, '', $conf->entity) > 0)
|
||||||
|
{
|
||||||
|
Header("Location: ".$_SERVER["PHP_SELF"]);
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dol_print_error($db);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (preg_match('/del_(.*)/',$action,$reg))
|
||||||
|
{
|
||||||
|
$code=$reg[1];
|
||||||
|
if (dolibarr_del_const($db, $code, $conf->entity) > 0)
|
||||||
|
{
|
||||||
|
Header("Location: ".$_SERVER["PHP_SELF"]);
|
||||||
|
exit;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
dol_print_error($db);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* View
|
||||||
|
*/
|
||||||
|
|
||||||
|
llxHeader();
|
||||||
|
|
||||||
|
$linkback='<a href="'.DOL_URL_ROOT.'/admin/modules.php">'.$langs->trans("BackToModuleList").'</a>';
|
||||||
|
print_fiche_titre($langs->trans("AgendaSetup"),$linkback,'setup');
|
||||||
|
print "<br>\n";
|
||||||
|
|
||||||
|
|
||||||
|
$head=agenda_prepare_head();
|
||||||
|
|
||||||
|
dol_fiche_head($head, 'other', $langs->trans("Agenda"));
|
||||||
|
|
||||||
|
print_titre($langs->trans("OtherOptions"));
|
||||||
|
|
||||||
|
$var=true;
|
||||||
|
|
||||||
|
print '<table class="noborder allwidth">'."\n";
|
||||||
|
print '<tr class="liste_titre">'."\n";
|
||||||
|
print '<td>'.$langs->trans("Parameters").'</td>'."\n";
|
||||||
|
print '<td align="center" width="20"> </td>'."\n";
|
||||||
|
print '<td align="center" width="100">'.$langs->trans("Value").'</td>'."\n";
|
||||||
|
print '</tr>'."\n";
|
||||||
|
|
||||||
|
// Manual or automatic
|
||||||
|
$var=!$var;
|
||||||
|
print '<tr '.$bc[$var].'>'."\n";
|
||||||
|
print '<td>'.$langs->trans("AGENDA_USE_EVENT_TYPE").'</td>'."\n";
|
||||||
|
print '<td align="center" width="20"> </td>'."\n";
|
||||||
|
|
||||||
|
print '<td align="center" width="100">'."\n";
|
||||||
|
if ($conf->use_javascript_ajax)
|
||||||
|
{
|
||||||
|
print ajax_constantonoff('AGENDA_USE_EVENT_TYPE');
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if($conf->global->AGENDA_USE_EVENT_TYPE == 0)
|
||||||
|
{
|
||||||
|
print '<a href="'.$_SERVER['PHP_SELF'].'?action=set_AGENDA_USE_EVENT_TYPE">'.img_picto($langs->trans("Disabled"),'off').'</a>';
|
||||||
|
}
|
||||||
|
else if($conf->global->BUSINESS_VISIBLE_TO_ALL_BY_DEFAULT == 1)
|
||||||
|
{
|
||||||
|
print '<a href="'.$_SERVER['PHP_SELF'].'?action=del_AGENDA_USE_EVENT_TYPE">'.img_picto($langs->trans("Enabled"),'on').'</a>';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
print '</td></tr>'."\n";
|
||||||
|
|
||||||
|
print '</table>';
|
||||||
|
|
||||||
|
dol_fiche_end();
|
||||||
|
|
||||||
|
print "<br>";
|
||||||
|
|
||||||
|
dol_htmloutput_mesg($mesg);
|
||||||
|
|
||||||
|
llxFooter();
|
||||||
|
|
||||||
|
$db->close();
|
||||||
|
?>
|
||||||
@ -391,7 +391,7 @@ if ($id == 11)
|
|||||||
|
|
||||||
// Define localtax_typeList (used for dictionnary "c_tva")
|
// Define localtax_typeList (used for dictionnary "c_tva")
|
||||||
$localtax_typeList = array();
|
$localtax_typeList = array();
|
||||||
if (GETPOST("id") == 10)
|
if ($id == 10)
|
||||||
{
|
{
|
||||||
$localtax_typeList = array(
|
$localtax_typeList = array(
|
||||||
"0" => $langs->trans("No"),
|
"0" => $langs->trans("No"),
|
||||||
@ -441,22 +441,32 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
|||||||
if ($fieldnamekey == 'position') $fieldnamekey = 'Position';
|
if ($fieldnamekey == 'position') $fieldnamekey = 'Position';
|
||||||
if ($fieldnamekey == 'unicode') $fieldnamekey = 'Unicode';
|
if ($fieldnamekey == 'unicode') $fieldnamekey = 'Unicode';
|
||||||
|
|
||||||
$msg.=$langs->trans("ErrorFieldRequired",$langs->transnoentities($fieldnamekey)).'<br>';
|
$msg.=$langs->transnoentities("ErrorFieldRequired", $langs->transnoentities($fieldnamekey)).'<br>';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Other checks
|
// Other checks
|
||||||
if ($tabname[$id] == MAIN_DB_PREFIX."c_actioncomm" && isset($_POST["type"]) && in_array($_POST["type"],array('system','systemauto'))) {
|
if ($tabname[$id] == MAIN_DB_PREFIX."c_actioncomm" && isset($_POST["type"]) && in_array($_POST["type"],array('system','systemauto'))) {
|
||||||
$ok=0;
|
$ok=0;
|
||||||
$msg.="Value 'system' and 'systemauto' for type is reserved. You can use 'user' as value to add your own record.<br>";
|
$msg.= $langs->transnoentities('ErrorReservedTypeSystemSystemAuto').'<br>';
|
||||||
}
|
}
|
||||||
if (isset($_POST["code"]) && $_POST["code"]=='0') {
|
if (isset($_POST["code"]))
|
||||||
|
{
|
||||||
|
if ($_POST["code"]=='0')
|
||||||
|
{
|
||||||
$ok=0;
|
$ok=0;
|
||||||
$msg.="Code can't contains value 0<br>";
|
$msg.= $langs->transnoentities('ErrorCodeCantContainZero').'<br>';
|
||||||
|
}
|
||||||
|
if (!is_numeric($_POST['code']))
|
||||||
|
{
|
||||||
|
$ok = 0;
|
||||||
|
$msg .= $langs->transnoentities('ErrorFieldFormat', $langs->transnoentities('Code')).'<br />';
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (isset($_POST["country"]) && $_POST["country"]=='0') {
|
if (isset($_POST["country"]) && $_POST["country"]=='0') {
|
||||||
$ok=0;
|
$ok=0;
|
||||||
$msg.=$langs->trans("ErrorFieldRequired",$langs->trans("Country")).'<br>';
|
$msg.=$langs->transnoentities("ErrorFieldRequired",$langs->transnoentities("Country")).'<br>';
|
||||||
}
|
}
|
||||||
|
|
||||||
// Clean some parameters
|
// Clean some parameters
|
||||||
if (isset($_POST["localtax1"]) && empty($_POST["localtax1"])) $_POST["localtax1"]='0'; // If empty, we force to 0
|
if (isset($_POST["localtax1"]) && empty($_POST["localtax1"])) $_POST["localtax1"]='0'; // If empty, we force to 0
|
||||||
if (isset($_POST["localtax2"]) && empty($_POST["localtax2"])) $_POST["localtax2"]='0'; // If empty, we force to 0
|
if (isset($_POST["localtax2"]) && empty($_POST["localtax2"])) $_POST["localtax2"]='0'; // If empty, we force to 0
|
||||||
@ -518,7 +528,7 @@ if (GETPOST('actionadd') || GETPOST('actionmodify'))
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
if ($db->errno() == 'DB_ERROR_RECORD_ALREADY_EXISTS') {
|
if ($db->errno() == 'DB_ERROR_RECORD_ALREADY_EXISTS') {
|
||||||
$msg=$langs->trans("ErrorRecordAlreadyExists").'<br>';
|
$msg=$langs->transnoentities("ErrorRecordAlreadyExists").'<br>';
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
dol_print_error($db);
|
dol_print_error($db);
|
||||||
@ -588,7 +598,7 @@ if ($action == 'confirm_delete' && $confirm == 'yes') // delete
|
|||||||
{
|
{
|
||||||
if ($db->errno() == 'DB_ERROR_CHILD_EXISTS')
|
if ($db->errno() == 'DB_ERROR_CHILD_EXISTS')
|
||||||
{
|
{
|
||||||
$msg='<div class="error">'.$langs->trans("ErrorRecordIsUsedByChild").'</div>';
|
$msg='<div class="error">'.$langs->transnoentities("ErrorRecordIsUsedByChild").'</div>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -994,6 +1004,7 @@ if ($id)
|
|||||||
$valuetoshow=($obj->code && $key != "Civility".strtoupper($obj->code)?$key:$obj->$fieldlist[$field]);
|
$valuetoshow=($obj->code && $key != "Civility".strtoupper($obj->code)?$key:$obj->$fieldlist[$field]);
|
||||||
}
|
}
|
||||||
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_type_contact') {
|
else if ($fieldlist[$field]=='libelle' && $tabname[$id]==MAIN_DB_PREFIX.'c_type_contact') {
|
||||||
|
$langs->load('agenda');
|
||||||
$key=$langs->trans("TypeContact_".$obj->element."_".$obj->source."_".strtoupper($obj->code));
|
$key=$langs->trans("TypeContact_".$obj->element."_".$obj->source."_".strtoupper($obj->code));
|
||||||
$valuetoshow=($obj->code && $key != "TypeContact_".$obj->element."_".$obj->source."_".strtoupper($obj->code)?$key:$obj->$fieldlist[$field]);
|
$valuetoshow=($obj->code && $key != "TypeContact_".$obj->element."_".$obj->source."_".strtoupper($obj->code)?$key:$obj->$fieldlist[$field]);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -29,6 +29,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/menubase.class.php';
|
|||||||
|
|
||||||
|
|
||||||
$langs->load("admin");
|
$langs->load("admin");
|
||||||
|
$langs->load('other');
|
||||||
|
|
||||||
if (! $user->admin) accessforbidden();
|
if (! $user->admin) accessforbidden();
|
||||||
|
|
||||||
|
|||||||
@ -99,7 +99,7 @@ $error=$hookmanager->error; $errors=array_merge($errors, (array) $hookmanager->e
|
|||||||
|
|
||||||
if (empty($reshook))
|
if (empty($reshook))
|
||||||
{
|
{
|
||||||
//Suppression d'un objet d'une categorie
|
// Remove element from category
|
||||||
if ($removecat > 0)
|
if ($removecat > 0)
|
||||||
{
|
{
|
||||||
if ($type==0 && ($user->rights->produit->creer || $user->rights->service->creer))
|
if ($type==0 && ($user->rights->produit->creer || $user->rights->service->creer))
|
||||||
@ -113,17 +113,20 @@ if (empty($reshook))
|
|||||||
{
|
{
|
||||||
$object = new Societe($db);
|
$object = new Societe($db);
|
||||||
$result = $object->fetch($objectid);
|
$result = $object->fetch($objectid);
|
||||||
|
$elementtype = 'fournisseur';
|
||||||
}
|
}
|
||||||
if ($type==2 && $user->rights->societe->creer)
|
if ($type==2 && $user->rights->societe->creer)
|
||||||
{
|
{
|
||||||
$object = new Societe($db);
|
$object = new Societe($db);
|
||||||
$result = $object->fetch($objectid);
|
$result = $object->fetch($objectid);
|
||||||
|
$elementtype = 'societe';
|
||||||
}
|
}
|
||||||
if ($type == 3 && $user->rights->adherent->creer)
|
if ($type == 3 && $user->rights->adherent->creer)
|
||||||
{
|
{
|
||||||
require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php';
|
require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php';
|
||||||
$object = new Adherent($db);
|
$object = new Adherent($db);
|
||||||
$result = $object->fetch($objectid);
|
$result = $object->fetch($objectid);
|
||||||
|
$elementtype = 'member';
|
||||||
}
|
}
|
||||||
$cat = new Categorie($db);
|
$cat = new Categorie($db);
|
||||||
$result=$cat->fetch($removecat);
|
$result=$cat->fetch($removecat);
|
||||||
@ -507,7 +510,7 @@ function formCategory($db,$object,$typeid,$socid=0)
|
|||||||
//print $c->getNomUrl(1);
|
//print $c->getNomUrl(1);
|
||||||
print img_object('','category').' '.$way."</td>";
|
print img_object('','category').' '.$way."</td>";
|
||||||
|
|
||||||
// Lien supprimer
|
// Link to delete from category
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
$permission=0;
|
$permission=0;
|
||||||
if ($typeid == 0) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
if ($typeid == 0) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
|
|||||||
@ -420,6 +420,7 @@ class Categorie
|
|||||||
$sql .= " WHERE fk_categorie = ".$this->id;
|
$sql .= " WHERE fk_categorie = ".$this->id;
|
||||||
$sql .= " AND fk_".($type=='fournisseur'?'societe':$type)." = ".$obj->id;
|
$sql .= " AND fk_".($type=='fournisseur'?'societe':$type)." = ".$obj->id;
|
||||||
|
|
||||||
|
dol_syslog(get_class($this).'::del_type sql='.$sql);
|
||||||
if ($this->db->query($sql))
|
if ($this->db->query($sql))
|
||||||
{
|
{
|
||||||
return 1;
|
return 1;
|
||||||
|
|||||||
@ -36,6 +36,7 @@ $ref=GETPOST('ref');
|
|||||||
$type=GETPOST('type');
|
$type=GETPOST('type');
|
||||||
$action=GETPOST('action');
|
$action=GETPOST('action');
|
||||||
$confirm=GETPOST('confirm');
|
$confirm=GETPOST('confirm');
|
||||||
|
$removeelem = GETPOST('removeelem','int');
|
||||||
|
|
||||||
if ($id == "")
|
if ($id == "")
|
||||||
{
|
{
|
||||||
@ -61,6 +62,40 @@ $type=$object->type;
|
|||||||
* Actions
|
* Actions
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
// Remove element from category
|
||||||
|
if ($id > 0 && $removeelem > 0)
|
||||||
|
{
|
||||||
|
if ($type==0 && ($user->rights->produit->creer || $user->rights->service->creer))
|
||||||
|
{
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php';
|
||||||
|
$tmpobject = new Product($db);
|
||||||
|
$result = $tmpobject->fetch($removeelem);
|
||||||
|
$elementtype = 'product';
|
||||||
|
}
|
||||||
|
if ($type==1 && $user->rights->societe->creer)
|
||||||
|
{
|
||||||
|
$tmpobject = new Societe($db);
|
||||||
|
$result = $tmpobject->fetch($removeelem);
|
||||||
|
$elementtype = 'fournisseur';
|
||||||
|
}
|
||||||
|
if ($type==2 && $user->rights->societe->creer)
|
||||||
|
{
|
||||||
|
$tmpobject = new Societe($db);
|
||||||
|
$result = $tmpobject->fetch($removeelem);
|
||||||
|
$elementtype = 'societe';
|
||||||
|
}
|
||||||
|
if ($type == 3 && $user->rights->adherent->creer)
|
||||||
|
{
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/adherents/class/adherent.class.php';
|
||||||
|
$tmpobject = new Adherent($db);
|
||||||
|
$result = $tmpobject->fetch($removeelem);
|
||||||
|
$elementtype = 'member';
|
||||||
|
}
|
||||||
|
|
||||||
|
$result=$object->del_type($tmpobject,$elementtype);
|
||||||
|
if ($result < 0) dol_print_error('',$object->error);
|
||||||
|
}
|
||||||
|
|
||||||
if ($user->rights->categorie->supprimer && $action == 'confirm_delete' && $confirm == 'yes')
|
if ($user->rights->categorie->supprimer && $action == 'confirm_delete' && $confirm == 'yes')
|
||||||
{
|
{
|
||||||
if ($object->delete($user) >= 0)
|
if ($object->delete($user) >= 0)
|
||||||
@ -214,7 +249,7 @@ if ($object->type == 0)
|
|||||||
{
|
{
|
||||||
print "<br>";
|
print "<br>";
|
||||||
print "<table class='noborder' width='100%'>\n";
|
print "<table class='noborder' width='100%'>\n";
|
||||||
print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("ProductsAndServices")."</td></tr>\n";
|
print '<tr class="liste_titre"><td colspan="3">'.$langs->trans("ProductsAndServices")."</td></tr>\n";
|
||||||
|
|
||||||
if (count($prods) > 0)
|
if (count($prods) > 0)
|
||||||
{
|
{
|
||||||
@ -224,10 +259,24 @@ if ($object->type == 0)
|
|||||||
$var=!$var;
|
$var=!$var;
|
||||||
print "\t<tr ".$bc[$var].">\n";
|
print "\t<tr ".$bc[$var].">\n";
|
||||||
print '<td nowrap="nowrap" valign="top">';
|
print '<td nowrap="nowrap" valign="top">';
|
||||||
if ($prod->type == 1) print img_object($langs->trans("ShowService"),"service");
|
print $prod->getNomUrl(1,'category');
|
||||||
else print img_object($langs->trans("ShowProduct"),"product");
|
print "</td>\n";
|
||||||
print " <a href='".DOL_URL_ROOT."/product/fiche.php?id=".$prod->id."'>".$prod->ref."</a></td>\n";
|
|
||||||
print '<td valign="top">'.$prod->libelle."</td>\n";
|
print '<td valign="top">'.$prod->libelle."</td>\n";
|
||||||
|
// Link to delete from category
|
||||||
|
print '<td align="right">';
|
||||||
|
$typeid=$object->type;
|
||||||
|
$permission=0;
|
||||||
|
if ($typeid == 0) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
|
if ($typeid == 1) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 2) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 3) $permission=$user->rights->adherent->creer;
|
||||||
|
if ($permission)
|
||||||
|
{
|
||||||
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$prod->id."'>";
|
||||||
|
print img_delete($langs->trans("DeleteFromCat")).' ';
|
||||||
|
print $langs->trans("DeleteFromCat")."</a>";
|
||||||
|
}
|
||||||
|
print '</td>';
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -249,8 +298,8 @@ if ($object->type == 1)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
print "<br>";
|
print "<br>";
|
||||||
print "<table class='noborder' width='100%'>\n";
|
print '<table class="noborder" width="100%">'."\n";
|
||||||
print "<tr class='liste_titre'><td>".$langs->trans("Suppliers")."</td></tr>\n";
|
print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("Suppliers")."</td></tr>\n";
|
||||||
|
|
||||||
if (count($socs) > 0)
|
if (count($socs) > 0)
|
||||||
{
|
{
|
||||||
@ -261,8 +310,23 @@ if ($object->type == 1)
|
|||||||
print "\t<tr ".$bc[$var].">\n";
|
print "\t<tr ".$bc[$var].">\n";
|
||||||
|
|
||||||
print '<td nowrap="nowrap" valign="top">';
|
print '<td nowrap="nowrap" valign="top">';
|
||||||
print $soc->getNomUrl(1);
|
print $soc->getNomUrl(1,'category_supplier');
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
|
// Link to delete from category
|
||||||
|
print '<td align="right">';
|
||||||
|
$typeid=$object->type;
|
||||||
|
$permission=0;
|
||||||
|
if ($typeid == 0) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
|
if ($typeid == 1) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 2) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 3) $permission=$user->rights->adherent->creer;
|
||||||
|
if ($permission)
|
||||||
|
{
|
||||||
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$soc->id."'>";
|
||||||
|
print img_delete($langs->trans("DeleteFromCat")).' ';
|
||||||
|
print $langs->trans("DeleteFromCat")."</a>";
|
||||||
|
}
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
@ -285,8 +349,8 @@ if($object->type == 2)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
print "<br>";
|
print "<br>";
|
||||||
print "<table class='noborder' width='100%'>\n";
|
print '<table class="noborder" width="100%">'."\n";
|
||||||
print "<tr class='liste_titre'><td>".$langs->trans("Customers")."</td></tr>\n";
|
print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("Customers")."</td></tr>\n";
|
||||||
|
|
||||||
if (count($socs) > 0)
|
if (count($socs) > 0)
|
||||||
{
|
{
|
||||||
@ -298,9 +362,23 @@ if($object->type == 2)
|
|||||||
$var=!$var;
|
$var=!$var;
|
||||||
print "\t<tr ".$bc[$var].">\n";
|
print "\t<tr ".$bc[$var].">\n";
|
||||||
print '<td nowrap="nowrap" valign="top">';
|
print '<td nowrap="nowrap" valign="top">';
|
||||||
print $soc->getNomUrl(1);
|
print $soc->getNomUrl(1,'category');
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
|
// Link to delete from category
|
||||||
|
print '<td align="right">';
|
||||||
|
$typeid=$object->type;
|
||||||
|
$permission=0;
|
||||||
|
if ($typeid == 0) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
|
if ($typeid == 1) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 2) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 3) $permission=$user->rights->adherent->creer;
|
||||||
|
if ($permission)
|
||||||
|
{
|
||||||
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$soc->id."'>";
|
||||||
|
print img_delete($langs->trans("DeleteFromCat")).' ';
|
||||||
|
print $langs->trans("DeleteFromCat")."</a>";
|
||||||
|
}
|
||||||
|
print '</td>';
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -326,7 +404,7 @@ if ($object->type == 3)
|
|||||||
{
|
{
|
||||||
print "<br>";
|
print "<br>";
|
||||||
print "<table class='noborder' width='100%'>\n";
|
print "<table class='noborder' width='100%'>\n";
|
||||||
print '<tr class="liste_titre"><td colspan="3">'.$langs->trans("Member")."</td></tr>\n";
|
print '<tr class="liste_titre"><td colspan="4">'.$langs->trans("Member")."</td></tr>\n";
|
||||||
|
|
||||||
if (count($prods) > 0)
|
if (count($prods) > 0)
|
||||||
{
|
{
|
||||||
@ -336,10 +414,25 @@ if ($object->type == 3)
|
|||||||
$var=!$var;
|
$var=!$var;
|
||||||
print "\t<tr ".$bc[$var].">\n";
|
print "\t<tr ".$bc[$var].">\n";
|
||||||
print '<td nowrap="nowrap" valign="top">';
|
print '<td nowrap="nowrap" valign="top">';
|
||||||
print $member->getNomUrl(1);
|
$member->ref=$member->login;
|
||||||
|
print $member->getNomUrl(1,0,'category');
|
||||||
print "</td>\n";
|
print "</td>\n";
|
||||||
print '<td valign="top">'.$member->lastname."</td>\n";
|
print '<td valign="top">'.$member->lastname."</td>\n";
|
||||||
print '<td valign="top">'.$member->firstname."</td>\n";
|
print '<td valign="top">'.$member->firstname."</td>\n";
|
||||||
|
// Link to delete from category
|
||||||
|
print '<td align="right">';
|
||||||
|
$typeid=$object->type;
|
||||||
|
$permission=0;
|
||||||
|
if ($typeid == 0) $permission=($user->rights->produit->creer || $user->rights->service->creer);
|
||||||
|
if ($typeid == 1) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 2) $permission=$user->rights->societe->creer;
|
||||||
|
if ($typeid == 3) $permission=$user->rights->adherent->creer;
|
||||||
|
if ($permission)
|
||||||
|
{
|
||||||
|
print "<a href= '".$_SERVER['PHP_SELF']."?".(empty($socid)?'id':'socid')."=".$object->id."&type=".$typeid."&removeelem=".$member->id."'>";
|
||||||
|
print img_delete($langs->trans("DeleteFromCat")).' ';
|
||||||
|
print $langs->trans("DeleteFromCat")."</a>";
|
||||||
|
}
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -51,6 +51,19 @@ if ($user->societe_id > 0)
|
|||||||
$socid = $user->societe_id;
|
$socid = $user->societe_id;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$act = new ActionComm($db);
|
||||||
|
|
||||||
|
if ($objectid > 0)
|
||||||
|
{
|
||||||
|
$ret = $act->fetch($objectid);
|
||||||
|
if ($ret > 0) {
|
||||||
|
$company=new Societe($db);
|
||||||
|
$company->fetch($act->societe->id);
|
||||||
|
$act->societe=$company; // For backward compatibility
|
||||||
|
$act->thirdparty=$company;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Get parameters
|
// Get parameters
|
||||||
$sortfield = GETPOST("sortfield",'alpha');
|
$sortfield = GETPOST("sortfield",'alpha');
|
||||||
$sortorder = GETPOST("sortorder",'alpha');
|
$sortorder = GETPOST("sortorder",'alpha');
|
||||||
@ -79,7 +92,7 @@ if ($action == 'delete')
|
|||||||
{
|
{
|
||||||
$upload_dir = $conf->agenda->dir_output.'/'.dol_sanitizeFileName($objectid);
|
$upload_dir = $conf->agenda->dir_output.'/'.dol_sanitizeFileName($objectid);
|
||||||
$file = $upload_dir . '/' . $_GET['urlfile']; // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
|
$file = $upload_dir . '/' . $_GET['urlfile']; // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
|
||||||
$ret=dol_delete_file($file);
|
$ret=dol_delete_file($file,0,0,0,$act);
|
||||||
if ($ret) setEventMessage($langs->trans("FileWasRemoved", GETPOST('urlfile')));
|
if ($ret) setEventMessage($langs->trans("FileWasRemoved", GETPOST('urlfile')));
|
||||||
else setEventMessage($langs->trans("ErrorFailToDeleteFile", GETPOST('urlfile')), 'errors');
|
else setEventMessage($langs->trans("ErrorFailToDeleteFile", GETPOST('urlfile')), 'errors');
|
||||||
$action='';
|
$action='';
|
||||||
@ -96,17 +109,10 @@ $help_url='EN:Module_Agenda_En|FR:Module_Agenda|ES:M&omodulodulo_Agenda';
|
|||||||
llxHeader('',$langs->trans("Agenda"),$help_url);
|
llxHeader('',$langs->trans("Agenda"),$help_url);
|
||||||
|
|
||||||
|
|
||||||
if ($objectid > 0)
|
if ($act->id > 0)
|
||||||
{
|
|
||||||
$act = new ActionComm($db);
|
|
||||||
if ($act->fetch($objectid))
|
|
||||||
{
|
{
|
||||||
$upload_dir = $conf->agenda->dir_output.'/'.dol_sanitizeFileName($objectid);
|
$upload_dir = $conf->agenda->dir_output.'/'.dol_sanitizeFileName($objectid);
|
||||||
|
|
||||||
$company=new Societe($db);
|
|
||||||
$company->fetch($act->societe->id);
|
|
||||||
$act->societe=$company;
|
|
||||||
|
|
||||||
$author=new User($db);
|
$author=new User($db);
|
||||||
$author->fetch($act->author->id);
|
$author->fetch($act->author->id);
|
||||||
$act->author=$author;
|
$act->author=$author;
|
||||||
@ -263,7 +269,7 @@ if ($objectid > 0)
|
|||||||
|
|
||||||
// Affiche formulaire upload
|
// Affiche formulaire upload
|
||||||
$formfile=new FormFile($db);
|
$formfile=new FormFile($db);
|
||||||
$formfile->form_attach_new_file(DOL_URL_ROOT.'/comm/action/document.php?id='.$act->id,'',0,0,($user->rights->agenda->myactions->create||$user->rights->agenda->allactions->create));
|
$formfile->form_attach_new_file(DOL_URL_ROOT.'/comm/action/document.php?id='.$act->id,'',0,0,($user->rights->agenda->myactions->create||$user->rights->agenda->allactions->create),50,$act);
|
||||||
|
|
||||||
|
|
||||||
// List of document
|
// List of document
|
||||||
@ -271,11 +277,6 @@ if ($objectid > 0)
|
|||||||
$formfile->list_of_documents($filearray,$act,'actions',$param,0,'',$user->rights->agenda->myactions->create);
|
$formfile->list_of_documents($filearray,$act,'actions',$param,0,'',$user->rights->agenda->myactions->create);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
|
||||||
dol_print_error($db);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
{
|
||||||
print $langs->trans("UnkownError");
|
print $langs->trans("UnkownError");
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2005 Simon TOSSER <simon@kornog-computing.com>
|
* Copyright (C) 2005 Simon TOSSER <simon@kornog-computing.com>
|
||||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2010 Juanjo Menent <jmenent@2byte.es>
|
* Copyright (C) 2010 Juanjo Menent <jmenent@2byte.es>
|
||||||
@ -663,7 +663,6 @@ if ($id > 0)
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
$head=actions_prepare_head($act);
|
$head=actions_prepare_head($act);
|
||||||
dol_fiche_head($head, 'card', $langs->trans("Action"),0,'action');
|
|
||||||
|
|
||||||
$now=dol_now();
|
$now=dol_now();
|
||||||
$delay_warning=$conf->global->MAIN_DELAY_ACTIONS_TODO*24*60*60;
|
$delay_warning=$conf->global->MAIN_DELAY_ACTIONS_TODO*24*60*60;
|
||||||
@ -711,6 +710,8 @@ if ($id > 0)
|
|||||||
print '<input type="hidden" name="ref_ext" value="'.$act->ref_ext.'">';
|
print '<input type="hidden" name="ref_ext" value="'.$act->ref_ext.'">';
|
||||||
if ($backtopage) print '<input type="hidden" name="backtopage" value="'.($backtopage != '1'? $backtopage : $_SERVER["HTTP_REFERER"]).'">';
|
if ($backtopage) print '<input type="hidden" name="backtopage" value="'.($backtopage != '1'? $backtopage : $_SERVER["HTTP_REFERER"]).'">';
|
||||||
|
|
||||||
|
dol_fiche_head($head, 'card', $langs->trans("Action"),0,'action');
|
||||||
|
|
||||||
print '<table class="border" width="100%">';
|
print '<table class="border" width="100%">';
|
||||||
|
|
||||||
// Ref
|
// Ref
|
||||||
@ -836,7 +837,9 @@ if ($id > 0)
|
|||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
print '<center><br><input type="submit" class="button" name="edit" value="'.$langs->trans("Save").'">';
|
dol_fiche_end();
|
||||||
|
|
||||||
|
print '<center><input type="submit" class="button" name="edit" value="'.$langs->trans("Save").'">';
|
||||||
print ' <input type="submit" class="button" name="cancel" value="'.$langs->trans("Cancel").'">';
|
print ' <input type="submit" class="button" name="cancel" value="'.$langs->trans("Cancel").'">';
|
||||||
print '</center>';
|
print '</center>';
|
||||||
|
|
||||||
@ -844,6 +847,8 @@ if ($id > 0)
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
dol_fiche_head($head, 'card', $langs->trans("Action"),0,'action');
|
||||||
|
|
||||||
// Affichage fiche action en mode visu
|
// Affichage fiche action en mode visu
|
||||||
print '<table class="border" width="100%">';
|
print '<table class="border" width="100%">';
|
||||||
|
|
||||||
@ -1021,14 +1026,13 @@ if ($id > 0)
|
|||||||
}
|
}
|
||||||
print '</table><br><br>';
|
print '</table><br><br>';
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
print "</div>\n";
|
dol_fiche_end();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Barre d'actions
|
* Barre d'actions
|
||||||
*
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
print '<div class="tabsAction">';
|
print '<div class="tabsAction">';
|
||||||
|
|||||||
@ -1534,7 +1534,7 @@ else
|
|||||||
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
||||||
$notify=new Notify($db);
|
$notify=new Notify($db);
|
||||||
$text.='<br>';
|
$text.='<br>';
|
||||||
$text.=$notify->confirmMessage('NOTIFY_VAL_PROPAL',$object->socid);
|
$text.=$notify->confirmMessage('PROPAL_VALIDATE',$object->socid);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! $error) $formconfirm=$form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ValidateProp'), $text, 'confirm_validate','',0,1);
|
if (! $error) $formconfirm=$form->formconfirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ValidateProp'), $text, 'confirm_validate','',0,1);
|
||||||
|
|||||||
@ -1784,7 +1784,7 @@ else
|
|||||||
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
||||||
$notify=new Notify($db);
|
$notify=new Notify($db);
|
||||||
$text.='<br>';
|
$text.='<br>';
|
||||||
$text.=$notify->confirmMessage('NOTIFY_VAL_ORDER',$object->socid);
|
$text.=$notify->confirmMessage('ORDER_VALIDATE',$object->socid);
|
||||||
}
|
}
|
||||||
$formquestion=array();
|
$formquestion=array();
|
||||||
if (! empty($conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER) && $object->hasProductsOrServices(1))
|
if (! empty($conf->global->STOCK_CALCULATE_ON_VALIDATE_ORDER) && $object->hasProductsOrServices(1))
|
||||||
|
|||||||
@ -2523,7 +2523,7 @@ else if ($id > 0 || ! empty($ref))
|
|||||||
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
||||||
$notify=new Notify($db);
|
$notify=new Notify($db);
|
||||||
$text.='<br>';
|
$text.='<br>';
|
||||||
$text.=$notify->confirmMessage('NOTIFY_VAL_FAC',$object->socid);
|
$text.=$notify->confirmMessage('BILL_VALIDATE',$object->socid);
|
||||||
}
|
}
|
||||||
$formquestion=array();
|
$formquestion=array();
|
||||||
|
|
||||||
|
|||||||
@ -30,7 +30,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/commonobject.class.php';
|
|||||||
*/
|
*/
|
||||||
class ChargeSociales extends CommonObject
|
class ChargeSociales extends CommonObject
|
||||||
{
|
{
|
||||||
public $element='rowid';
|
public $element='chargesociales';
|
||||||
public $table='chargesociales';
|
public $table='chargesociales';
|
||||||
public $table_element='chargesociales';
|
public $table_element='chargesociales';
|
||||||
|
|
||||||
|
|||||||
@ -79,7 +79,7 @@ if (GETPOST("sendit") && ! empty($conf->global->MAIN_UPLOAD_DOC))
|
|||||||
if ($action == 'delete')
|
if ($action == 'delete')
|
||||||
{
|
{
|
||||||
$file = $upload_dir . '/' . GETPOST("urlfile"); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
|
$file = $upload_dir . '/' . GETPOST("urlfile"); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
|
||||||
$ret=dol_delete_file($file);
|
$ret=dol_delete_file($file,0,0,0,$object);
|
||||||
if ($ret) setEventMessage($langs->trans("FileWasRemoved", GETPOST('urlfile')));
|
if ($ret) setEventMessage($langs->trans("FileWasRemoved", GETPOST('urlfile')));
|
||||||
else setEventMessage($langs->trans("ErrorFailToDeleteFile", GETPOST('urlfile')), 'errors');
|
else setEventMessage($langs->trans("ErrorFailToDeleteFile", GETPOST('urlfile')), 'errors');
|
||||||
}
|
}
|
||||||
@ -172,7 +172,7 @@ if ($object->id)
|
|||||||
|
|
||||||
// Affiche formulaire upload
|
// Affiche formulaire upload
|
||||||
$formfile=new FormFile($db);
|
$formfile=new FormFile($db);
|
||||||
$formfile->form_attach_new_file(DOL_URL_ROOT.'/compta/sociales/document.php?id='.$object->id,'',0,0,$user->rights->tax->charges->creer);
|
$formfile->form_attach_new_file(DOL_URL_ROOT.'/compta/sociales/document.php?id='.$object->id,'',0,0,$user->rights->tax->charges->creer,50,$object);
|
||||||
|
|
||||||
|
|
||||||
// List of document
|
// List of document
|
||||||
|
|||||||
390
htdocs/compta/stats/cabyprodserv.php
Normal file
390
htdocs/compta/stats/cabyprodserv.php
Normal file
@ -0,0 +1,390 @@
|
|||||||
|
<?php
|
||||||
|
/* Copyright (C) 2013 Antoine Iauch <aiauch@gpcsolutions.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 <http://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**
|
||||||
|
* \file htdocs/compta/stats/cabyprodserv.php
|
||||||
|
* \brief Page reporting TO by Products & Services
|
||||||
|
*/
|
||||||
|
|
||||||
|
require '../../main.inc.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/report.lib.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/tax.lib.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||||
|
|
||||||
|
$langs->load("products");
|
||||||
|
$langs->load("categories");
|
||||||
|
$langs->load("errors");
|
||||||
|
|
||||||
|
// Security pack (data & check)
|
||||||
|
$socid = GETPOST('socid','int');
|
||||||
|
|
||||||
|
if ($user->societe_id > 0) $socid = $user->societe_id;
|
||||||
|
if (! empty($conf->comptabilite->enabled)) $result=restrictedArea($user,'compta','','','resultat');
|
||||||
|
if (! empty($conf->accounting->enabled)) $result=restrictedArea($user,'accounting','','','comptarapport');
|
||||||
|
|
||||||
|
// Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES')
|
||||||
|
$modecompta = $conf->global->COMPTA_MODE;
|
||||||
|
if (GETPOST("modecompta")) $modecompta=GETPOST("modecompta");
|
||||||
|
|
||||||
|
$sortorder=isset($_GET["sortorder"])?$_GET["sortorder"]:$_POST["sortorder"];
|
||||||
|
$sortfield=isset($_GET["sortfield"])?$_GET["sortfield"]:$_POST["sortfield"];
|
||||||
|
if (! $sortorder) $sortorder="asc";
|
||||||
|
if (! $sortfield) $sortfield="name";
|
||||||
|
|
||||||
|
// Category
|
||||||
|
$selected_cat = (int)GETPOST('search_categ', 'int');
|
||||||
|
$subcat = false;
|
||||||
|
if (GETPOST('subcat', 'alpha') === 'yes') {
|
||||||
|
$subcat = true;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Date range
|
||||||
|
$year=GETPOST("year");
|
||||||
|
$month=GETPOST("month");
|
||||||
|
$date_startyear = GETPOST("date_startyear");
|
||||||
|
$date_startmonth = GETPOST("date_startmonth");
|
||||||
|
$date_startday = GETPOST("date_startday");
|
||||||
|
$date_endyear = GETPOST("date_endyear");
|
||||||
|
$date_endmonth = GETPOST("date_endmonth");
|
||||||
|
$date_endday = GETPOST("date_endday");
|
||||||
|
if (empty($year))
|
||||||
|
{
|
||||||
|
$year_current = strftime("%Y",dol_now());
|
||||||
|
$month_current = strftime("%m",dol_now());
|
||||||
|
$year_start = $year_current;
|
||||||
|
} else {
|
||||||
|
$year_current = $year;
|
||||||
|
$month_current = strftime("%m",dol_now());
|
||||||
|
$year_start = $year;
|
||||||
|
}
|
||||||
|
$date_start=dol_mktime(0,0,0,$_REQUEST["date_startmonth"],$_REQUEST["date_startday"],$_REQUEST["date_startyear"]);
|
||||||
|
$date_end=dol_mktime(23,59,59,$_REQUEST["date_endmonth"],$_REQUEST["date_endday"],$_REQUEST["date_endyear"]);
|
||||||
|
// Quarter
|
||||||
|
if (empty($date_start) || empty($date_end)) // We define date_start and date_end
|
||||||
|
{
|
||||||
|
$q=GETPOST("q")?GETPOST("q"):0;
|
||||||
|
if ($q==0)
|
||||||
|
{
|
||||||
|
// We define date_start and date_end
|
||||||
|
$month_start=GETPOST("month")?GETPOST("month"):($conf->global->SOCIETE_FISCAL_MONTH_START?($conf->global->SOCIETE_FISCAL_MONTH_START):1);
|
||||||
|
$year_end=$year_start;
|
||||||
|
$month_end=$month_start;
|
||||||
|
if (! GETPOST("month")) // If month not forced
|
||||||
|
{
|
||||||
|
if (! GETPOST('year') && $month_start > $month_current)
|
||||||
|
{
|
||||||
|
$year_start--;
|
||||||
|
$year_end--;
|
||||||
|
}
|
||||||
|
$month_end=$month_start-1;
|
||||||
|
if ($month_end < 1) $month_end=12;
|
||||||
|
else $year_end++;
|
||||||
|
}
|
||||||
|
$date_start=dol_get_first_day($year_start,$month_start,false); $date_end=dol_get_last_day($year_end,$month_end,false);
|
||||||
|
}
|
||||||
|
if ($q==1) { $date_start=dol_get_first_day($year_start,1,false); $date_end=dol_get_last_day($year_start,3,false); }
|
||||||
|
if ($q==2) { $date_start=dol_get_first_day($year_start,4,false); $date_end=dol_get_last_day($year_start,6,false); }
|
||||||
|
if ($q==3) { $date_start=dol_get_first_day($year_start,7,false); $date_end=dol_get_last_day($year_start,9,false); }
|
||||||
|
if ($q==4) { $date_start=dol_get_first_day($year_start,10,false); $date_end=dol_get_last_day($year_start,12,false); }
|
||||||
|
} else {
|
||||||
|
// TODO We define q
|
||||||
|
}
|
||||||
|
|
||||||
|
$commonparams=array();
|
||||||
|
$commonparams['modecompta']=$modecompta;
|
||||||
|
$commonparams['sortorder'] = $sortorder;
|
||||||
|
$commonparams['sortfield'] = $sortfield;
|
||||||
|
|
||||||
|
$headerparams = array();
|
||||||
|
$headerparams['date_startyear'] = $date_startyear;
|
||||||
|
$headerparams['date_startmonth'] = $date_startmonth;
|
||||||
|
$headerparams['date_startday'] = $date_startday;
|
||||||
|
$headerparams['date_endyear'] = $date_endyear;
|
||||||
|
$headerparams['date_endmonth'] = $date_endmonth;
|
||||||
|
$headerparams['date_endday'] = $date_endday;
|
||||||
|
$headerparams['q'] = $q;
|
||||||
|
|
||||||
|
$tableparams = array();
|
||||||
|
$tableparams['search_categ'] = $selected_cat;
|
||||||
|
$tableparams['subcat'] = ($subcat === true)?'yes':'';
|
||||||
|
|
||||||
|
// Adding common parameters
|
||||||
|
$allparams = array_merge($commonparams, $headerparams, $tableparams);
|
||||||
|
$headerparams = array_merge($commonparams, $headerparams);
|
||||||
|
$tableparams = array_merge($commonparams, $tableparams);
|
||||||
|
|
||||||
|
foreach($allparams as $key => $value) {
|
||||||
|
$paramslink .= '&' . $key . '=' . $value;
|
||||||
|
}
|
||||||
|
/*
|
||||||
|
* View
|
||||||
|
*/
|
||||||
|
llxHeader();
|
||||||
|
$form=new Form($db);
|
||||||
|
$formother = new FormOther($db);
|
||||||
|
|
||||||
|
// Show report header
|
||||||
|
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByProductsAndServices");
|
||||||
|
|
||||||
|
if ($modecompta=="CREANCES-DETTES") {
|
||||||
|
$nom.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')';
|
||||||
|
|
||||||
|
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
||||||
|
|
||||||
|
$description=$langs->trans("RulesCADue");
|
||||||
|
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
|
||||||
|
$description.= $langs->trans("DepositsAreNotIncluded");
|
||||||
|
} else {
|
||||||
|
$description.= $langs->trans("DepositsAreIncluded");
|
||||||
|
}
|
||||||
|
|
||||||
|
$builddate=time();
|
||||||
|
} else {
|
||||||
|
$nom.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
|
||||||
|
|
||||||
|
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
||||||
|
|
||||||
|
$description=$langs->trans("RulesCAIn");
|
||||||
|
$description.= $langs->trans("DepositsAreIncluded");
|
||||||
|
|
||||||
|
$builddate=time();
|
||||||
|
}
|
||||||
|
|
||||||
|
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,$tableparams);
|
||||||
|
|
||||||
|
|
||||||
|
// SQL request
|
||||||
|
$catotal=0;
|
||||||
|
|
||||||
|
if ($modecompta == 'CREANCES-DETTES') {
|
||||||
|
$sql = "SELECT DISTINCT p.rowid as rowid, p.ref as ref, p.label as label,";
|
||||||
|
$sql.= " sum(DISTINCT l.total_ht) as amount, sum(DISTINCT l.total_ttc) as amount_ttc";
|
||||||
|
$sql.= " FROM ".MAIN_DB_PREFIX."product as p";
|
||||||
|
$sql.= " JOIN ".MAIN_DB_PREFIX."facturedet as l";
|
||||||
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."facture as f ON l.fk_facture = f.rowid";
|
||||||
|
if ($selected_cat === -2) {
|
||||||
|
$sql.=" LEFT OUTER JOIN ".MAIN_DB_PREFIX."categorie_product as cp ON p.rowid = cp.fk_product";
|
||||||
|
}
|
||||||
|
if ($selected_cat && $selected_cat !== -2) {
|
||||||
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as c ON c.rowid = " . $selected_cat;
|
||||||
|
if ($subcat) {
|
||||||
|
$sql.=" OR c.fk_parent = " . $selected_cat;
|
||||||
|
}
|
||||||
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie_product as cp ON cp.fk_categorie = c.rowid";
|
||||||
|
}
|
||||||
|
$sql.= " WHERE l.fk_product = p.rowid";
|
||||||
|
$sql.= " AND f.fk_statut in (1,2)";
|
||||||
|
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
|
||||||
|
$sql.= " AND f.type IN (0,1,2)";
|
||||||
|
} else {
|
||||||
|
$sql.= " AND f.type IN (0,1,2,3)";
|
||||||
|
}
|
||||||
|
if ($date_start && $date_end) {
|
||||||
|
$sql.= " AND f.datef >= '".$db->idate($date_start)."' AND f.datef <= '".$db->idate($date_end)."'";
|
||||||
|
}
|
||||||
|
if ($selected_cat === -2) {
|
||||||
|
$sql.=" AND cp.fk_product is null";
|
||||||
|
}
|
||||||
|
if ($selected_cat && $selected_cat !== -2) {
|
||||||
|
$sql.= " AND cp.fk_product = p.rowid";
|
||||||
|
}
|
||||||
|
$sql.= " AND f.entity = ".$conf->entity;
|
||||||
|
$sql.= " GROUP BY p.rowid ";
|
||||||
|
$sql.= "ORDER BY p.ref ";
|
||||||
|
|
||||||
|
$result = $db->query($sql);
|
||||||
|
if ($result) {
|
||||||
|
$num = $db->num_rows($result);
|
||||||
|
$i=0;
|
||||||
|
while ($i < $num) {
|
||||||
|
$obj = $db->fetch_object($result);
|
||||||
|
$amount_ht[$obj->rowid] = $obj->amount;
|
||||||
|
$amount[$obj->rowid] = $obj->amount_ttc;
|
||||||
|
$name[$obj->rowid] = $obj->ref . ' - ' . $obj->label;
|
||||||
|
$catotal_ht+=$obj->amount;
|
||||||
|
$catotal+=$obj->amount_ttc;
|
||||||
|
$i++;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
dol_print_error($db);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Show Array
|
||||||
|
$i=0;
|
||||||
|
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||||
|
// Extra parameters management
|
||||||
|
foreach($headerparams as $key => $value)
|
||||||
|
{
|
||||||
|
print '<input type="hidden" name="'.$key.'" value="'.$value.'">';
|
||||||
|
}
|
||||||
|
|
||||||
|
print '<table class="noborder" width="100%">';
|
||||||
|
// Category filter
|
||||||
|
print '<tr class="liste_titre">';
|
||||||
|
print '<td>';
|
||||||
|
print $langs->trans("Category") . ': ' . $formother->select_categories(0, $selected_cat, 'search_categ', true);
|
||||||
|
print ' ';
|
||||||
|
print $langs->trans("SubCats") . '? ';
|
||||||
|
print '<input type="checkbox" name="subcat" value="yes"';
|
||||||
|
if ($subcat) {
|
||||||
|
print ' checked';
|
||||||
|
}
|
||||||
|
print '></td>';
|
||||||
|
print '<td colspan="3" align="right">';
|
||||||
|
print '<input type="image" class="liste_titre" name="button_search" src="'.DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/search.png" value="'.dol_escape_htmltag($langs->trans("Search")).'" title="'.dol_escape_htmltag($langs->trans("Search")).'">';
|
||||||
|
print '</td></tr>';
|
||||||
|
// Array header
|
||||||
|
print "<tr class=\"liste_titre\">";
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("Product"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"name",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
"",
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans('AmountHT'),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ht",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("AmountTTC"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ttc",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("Percentage"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ttc",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
// TODO: statistics?
|
||||||
|
print "</tr>\n";
|
||||||
|
|
||||||
|
// Array Data
|
||||||
|
$var=true;
|
||||||
|
|
||||||
|
if (count($amount)) {
|
||||||
|
$arrayforsort=$name;
|
||||||
|
// defining arrayforsort
|
||||||
|
if ($sortfield == 'nom' && $sortorder == 'asc') {
|
||||||
|
asort($name);
|
||||||
|
$arrayforsort=$name;
|
||||||
|
}
|
||||||
|
if ($sortfield == 'nom' && $sortorder == 'desc') {
|
||||||
|
arsort($name);
|
||||||
|
$arrayforsort=$name;
|
||||||
|
}
|
||||||
|
if ($sortfield == 'amount_ht' && $sortorder == 'asc') {
|
||||||
|
asort($amount_ht);
|
||||||
|
$arrayforsort=$amount_ht;
|
||||||
|
}
|
||||||
|
if ($sortfield == 'amount_ht' && $sortorder == 'desc') {
|
||||||
|
arsort($amount_ht);
|
||||||
|
$arrayforsort=$amount_ht;
|
||||||
|
}
|
||||||
|
if ($sortfield == 'amount_ttc' && $sortorder == 'asc') {
|
||||||
|
asort($amount);
|
||||||
|
$arrayforsort=$amount;
|
||||||
|
}
|
||||||
|
if ($sortfield == 'amount_ttc' && $sortorder == 'desc') {
|
||||||
|
arsort($amount);
|
||||||
|
$arrayforsort=$amount;
|
||||||
|
}
|
||||||
|
foreach($arrayforsort as $key=>$value) {
|
||||||
|
$var=!$var;
|
||||||
|
print "<tr ".$bc[$var].">";
|
||||||
|
|
||||||
|
// Third party
|
||||||
|
$fullname=$name[$key];
|
||||||
|
if ($key >= 0) {
|
||||||
|
$linkname='<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$key.'">'.img_object($langs->trans("ShowProduct"),'product').' '.$fullname.'</a>';
|
||||||
|
} else {
|
||||||
|
$linkname=$langs->trans("PaymentsNotLinkedToProduct");
|
||||||
|
}
|
||||||
|
|
||||||
|
print "<td>".$linkname."</td>\n";
|
||||||
|
|
||||||
|
// Amount w/o VAT
|
||||||
|
print '<td align="right">';
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?productid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="#">';
|
||||||
|
}
|
||||||
|
print price($amount_ht[$key]);
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
|
// Amount with VAT
|
||||||
|
print '<td align="right">';
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?productid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="#">';
|
||||||
|
}
|
||||||
|
print price($amount[$key]);
|
||||||
|
print '</a>';
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
|
// Percent;
|
||||||
|
print '<td align="right">'.($catotal > 0 ? round(100 * $amount[$key] / $catotal, 2).'%' : ' ').'</td>';
|
||||||
|
|
||||||
|
// TODO: statistics?
|
||||||
|
|
||||||
|
print "</tr>\n";
|
||||||
|
$i++;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Total
|
||||||
|
print '<tr class="liste_total">';
|
||||||
|
print '<td>'.$langs->trans("Total").'</td>';
|
||||||
|
print '<td align="right">'.price($catotal_ht).'</td>';
|
||||||
|
print '<td align="right">'.price($catotal).'</td>';
|
||||||
|
print '<td> </td>';
|
||||||
|
print '</tr>';
|
||||||
|
|
||||||
|
$db->free($result);
|
||||||
|
}
|
||||||
|
print "</table>";
|
||||||
|
print '</form>';
|
||||||
|
} else {
|
||||||
|
// $modecompta != 'CREANCES-DETTES'
|
||||||
|
// TODO: better message
|
||||||
|
print '<div class="warning">' . $langs->trans("WarningNotRelevant") . '</div>';
|
||||||
|
}
|
||||||
|
|
||||||
|
llxFooter();
|
||||||
|
$db->close();
|
||||||
|
?>
|
||||||
@ -2,6 +2,7 @@
|
|||||||
/* Copyright (C) 2001-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2001-2003 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
|
* Copyright (C) 2013 Antoine Iauch <aiauch@gpcsolutions.fr>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -46,6 +47,12 @@ if (! $sortfield) $sortfield="name";
|
|||||||
// Date range
|
// Date range
|
||||||
$year=GETPOST("year");
|
$year=GETPOST("year");
|
||||||
$month=GETPOST("month");
|
$month=GETPOST("month");
|
||||||
|
$date_startyear = GETPOST("date_startyear");
|
||||||
|
$date_startmonth = GETPOST("date_startmonth");
|
||||||
|
$date_startday = GETPOST("date_startday");
|
||||||
|
$date_endyear = GETPOST("date_endyear");
|
||||||
|
$date_endmonth = GETPOST("date_endmonth");
|
||||||
|
$date_endday = GETPOST("date_endday");
|
||||||
if (empty($year))
|
if (empty($year))
|
||||||
{
|
{
|
||||||
$year_current = strftime("%Y",dol_now());
|
$year_current = strftime("%Y",dol_now());
|
||||||
@ -89,9 +96,34 @@ if (empty($date_start) || empty($date_end)) // We define date_start and date_end
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
// TODO We define q
|
// TODO We define q
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$commonparams=array();
|
||||||
|
$commonparams['modecompta']=$modecompta;
|
||||||
|
$commonparams['sortorder'] = $sortorder;
|
||||||
|
$commonparams['sortfield'] = $sortfield;
|
||||||
|
|
||||||
|
$headerparams = array();
|
||||||
|
$headerparams['date_startyear'] = $date_startyear;
|
||||||
|
$headerparams['date_startmonth'] = $date_startmonth;
|
||||||
|
$headerparams['date_startday'] = $date_startday;
|
||||||
|
$headerparams['date_endyear'] = $date_endyear;
|
||||||
|
$headerparams['date_endmonth'] = $date_endmonth;
|
||||||
|
$headerparams['date_endday'] = $date_endday;
|
||||||
|
$headerparams['q'] = $q;
|
||||||
|
|
||||||
|
$tableparams = array();
|
||||||
|
$tableparams['search_categ'] = $selected_cat;
|
||||||
|
$tableparams['subcat'] = ($subcat === true)?'yes':'';
|
||||||
|
|
||||||
|
// Adding common parameters
|
||||||
|
$allparams = array_merge($commonparams, $headerparams, $tableparams);
|
||||||
|
$headerparams = array_merge($commonparams, $headerparams);
|
||||||
|
$tableparams = array_merge($commonparams, $tableparams);
|
||||||
|
|
||||||
|
foreach($allparams as $key => $value) {
|
||||||
|
$paramslink .= '&' . $key . '=' . $value;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* View
|
* View
|
||||||
@ -102,9 +134,8 @@ llxHeader();
|
|||||||
|
|
||||||
$form=new Form($db);
|
$form=new Form($db);
|
||||||
|
|
||||||
// Affiche en-tete du rapport
|
// Show report header
|
||||||
if ($modecompta=="CREANCES-DETTES")
|
if ($modecompta=="CREANCES-DETTES") {
|
||||||
{
|
|
||||||
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
|
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
|
||||||
$nom.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')';
|
$nom.='<br>('.$langs->trans("SeeReportInInputOutputMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=RECETTES-DEPENSES">','</a>').')';
|
||||||
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
||||||
@ -114,8 +145,7 @@ if ($modecompta=="CREANCES-DETTES")
|
|||||||
else $description.= $langs->trans("DepositsAreIncluded");
|
else $description.= $langs->trans("DepositsAreIncluded");
|
||||||
$builddate=time();
|
$builddate=time();
|
||||||
//$exportlink=$langs->trans("NotYetAvailable");
|
//$exportlink=$langs->trans("NotYetAvailable");
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
|
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByUserAuthorOfInvoice");
|
||||||
$nom.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
|
$nom.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
|
||||||
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
||||||
@ -131,20 +161,29 @@ if (! empty($modecompta)) $moreparam['modecompta']=$modecompta;
|
|||||||
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,$moreparam);
|
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,$moreparam);
|
||||||
|
|
||||||
|
|
||||||
// Charge tableau
|
// Show array
|
||||||
$catotal=0;
|
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||||
if ($modecompta == 'CREANCES-DETTES')
|
// Extra parameters management
|
||||||
|
foreach($headerparams as $key => $value)
|
||||||
{
|
{
|
||||||
|
print '<input type="hidden" name="'.$key.'" value="'.$value.'">';
|
||||||
|
}
|
||||||
|
|
||||||
|
$catotal=0;
|
||||||
|
if ($modecompta == 'CREANCES-DETTES') {
|
||||||
$sql = "SELECT u.rowid as rowid, u.lastname as name, u.firstname as firstname, sum(f.total) as amount, sum(f.total_ttc) as amount_ttc";
|
$sql = "SELECT u.rowid as rowid, u.lastname as name, u.firstname as firstname, sum(f.total) as amount, sum(f.total_ttc) as amount_ttc";
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."user as u";
|
$sql.= " FROM ".MAIN_DB_PREFIX."user as u";
|
||||||
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."facture as f ON f.fk_user_author = u.rowid";
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."facture as f ON f.fk_user_author = u.rowid";
|
||||||
$sql.= " WHERE f.fk_statut in (1,2)";
|
$sql.= " WHERE f.fk_statut in (1,2)";
|
||||||
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $sql.= " AND f.type IN (0,1,2)";
|
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
|
||||||
else $sql.= " AND f.type IN (0,1,2,3)";
|
$sql.= " AND f.type IN (0,1,2)";
|
||||||
if ($date_start && $date_end) $sql.= " AND f.datef >= '".$db->idate($date_start)."' AND f.datef <= '".$db->idate($date_end)."'";
|
} else {
|
||||||
|
$sql.= " AND f.type IN (0,1,2,3)";
|
||||||
}
|
}
|
||||||
else
|
if ($date_start && $date_end) {
|
||||||
{
|
$sql.= " AND f.datef >= '".$db->idate($date_start)."' AND f.datef <= '".$db->idate($date_end)."'";
|
||||||
|
}
|
||||||
|
} else {
|
||||||
/*
|
/*
|
||||||
* Liste des paiements (les anciens paiements ne sont pas vus par cette requete car, sur les
|
* Liste des paiements (les anciens paiements ne sont pas vus par cette requete car, sur les
|
||||||
* vieilles versions, ils n'etaient pas lies via paiement_facture. On les ajoute plus loin)
|
* vieilles versions, ils n'etaient pas lies via paiement_facture. On les ajoute plus loin)
|
||||||
@ -155,7 +194,9 @@ else
|
|||||||
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."paiement_facture as pf ON pf.fk_facture = f.rowid";
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."paiement_facture as pf ON pf.fk_facture = f.rowid";
|
||||||
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."paiement as p ON p.rowid = pf.fk_paiement";
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."paiement as p ON p.rowid = pf.fk_paiement";
|
||||||
$sql.= " WHERE 1=1";
|
$sql.= " WHERE 1=1";
|
||||||
if ($date_start && $date_end) $sql.= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
if ($date_start && $date_end) {
|
||||||
|
$sql.= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
$sql.= " AND f.entity = ".$conf->entity;
|
$sql.= " AND f.entity = ".$conf->entity;
|
||||||
if ($socid) $sql.= " AND f.fk_soc = ".$socid;
|
if ($socid) $sql.= " AND f.fk_soc = ".$socid;
|
||||||
@ -163,27 +204,25 @@ $sql .= " GROUP BY u.rowid, u.lastname, u.firstname";
|
|||||||
$sql .= " ORDER BY u.rowid";
|
$sql .= " ORDER BY u.rowid";
|
||||||
|
|
||||||
$result = $db->query($sql);
|
$result = $db->query($sql);
|
||||||
if ($result)
|
if ($result) {
|
||||||
{
|
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($result);
|
||||||
$i=0;
|
$i=0;
|
||||||
while ($i < $num)
|
while ($i < $num) {
|
||||||
{
|
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($result);
|
||||||
|
$amount_ht[$obj->rowid] = $obj->amount;
|
||||||
$amount[$obj->rowid] = $obj->amount_ttc;
|
$amount[$obj->rowid] = $obj->amount_ttc;
|
||||||
$name[$obj->rowid] = $obj->lastname.' '.$obj->firstname;
|
$name[$obj->rowid] = $obj->name.' '.$obj->firstname;
|
||||||
|
$catotal_ht+=$obj->amount;
|
||||||
$catotal+=$obj->amount_ttc;
|
$catotal+=$obj->amount_ttc;
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
dol_print_error($db);
|
dol_print_error($db);
|
||||||
}
|
}
|
||||||
|
|
||||||
// On ajoute les paiements ancienne version, non lies par paiement_facture donc sans user
|
// Adding old-version payments, non-bound by "paiement_facture" then without User
|
||||||
if ($modecompta != 'CREANCES-DETTES')
|
if ($modecompta != 'CREANCES-DETTES') {
|
||||||
{
|
$sql = "SELECT -1 as rowidx, '' as name, '' as firstname, sum(DISTINCT p.amount) as amount_ttc";
|
||||||
$sql = "SELECT -1 as rowidx, '' as lastname, '' as firstname, sum(p.amount) as amount_ttc";
|
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."bank as b";
|
$sql.= " FROM ".MAIN_DB_PREFIX."bank as b";
|
||||||
$sql.= ", ".MAIN_DB_PREFIX."bank_account as ba";
|
$sql.= ", ".MAIN_DB_PREFIX."bank_account as ba";
|
||||||
$sql.= ", ".MAIN_DB_PREFIX."paiement as p";
|
$sql.= ", ".MAIN_DB_PREFIX."paiement as p";
|
||||||
@ -192,42 +231,86 @@ if ($modecompta != 'CREANCES-DETTES')
|
|||||||
$sql.= " AND p.fk_bank = b.rowid";
|
$sql.= " AND p.fk_bank = b.rowid";
|
||||||
$sql.= " AND b.fk_account = ba.rowid";
|
$sql.= " AND b.fk_account = ba.rowid";
|
||||||
$sql.= " AND ba.entity = ".$conf->entity;
|
$sql.= " AND ba.entity = ".$conf->entity;
|
||||||
if ($date_start && $date_end) $sql.= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
if ($date_start && $date_end) {
|
||||||
|
$sql.= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
||||||
|
}
|
||||||
$sql.= " GROUP BY rowidx, name, firstname";
|
$sql.= " GROUP BY rowidx, name, firstname";
|
||||||
$sql.= " ORDER BY rowidx";
|
$sql.= " ORDER BY rowidx";
|
||||||
|
|
||||||
$result = $db->query($sql);
|
$result = $db->query($sql);
|
||||||
if ($result)
|
if ($result) {
|
||||||
{
|
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($result);
|
||||||
$i=0;
|
$i=0;
|
||||||
while ($i < $num)
|
while ($i < $num) {
|
||||||
{
|
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($result);
|
||||||
$amount[$obj->rowidx] = $obj->amount_ttc;
|
$amount[$obj->rowidx] = $obj->amount_ttc;
|
||||||
$name[$obj->rowidx] = $obj->lastname.' '.$obj->firstname;
|
$name[$obj->rowidx] = $obj->name.' '.$obj->firstname;
|
||||||
$catotal+=$obj->amount_ttc;
|
$catotal+=$obj->amount_ttc;
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
dol_print_error($db);
|
dol_print_error($db);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$i = 0;
|
$i = 0;
|
||||||
print "<table class=\"noborder\" width=\"100%\">";
|
print "<table class=\"noborder\" width=\"100%\">";
|
||||||
print "<tr class=\"liste_titre\">";
|
print "<tr class=\"liste_titre\">";
|
||||||
print_liste_field_titre($langs->trans("User"),$_SERVER["PHP_SELF"],"name","",'&year='.($year).'&modecompta='.$modecompta,"",$sortfield,$sortorder);
|
print_liste_field_titre(
|
||||||
print_liste_field_titre($langs->trans("AmountTTC"),$_SERVER["PHP_SELF"],"amount_ttc","",'&year='.($year).'&modecompta='.$modecompta,'align="right"',$sortfield,$sortorder);
|
$langs->trans("User"),
|
||||||
print_liste_field_titre($langs->trans("Percentage"),$_SERVER["PHP_SELF"],"amount_ttc","",'&year='.($year).'&modecompta='.$modecompta,'align="right"',$sortfield,$sortorder);
|
$_SERVER["PHP_SELF"],
|
||||||
print_liste_field_titre($langs->trans("OtherStatistics"),$_SERVER["PHP_SELF"],"","","",'align="center" width="20%"');
|
"name",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
"",
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
if ($modecompta == 'CREANCES-DETTES') {
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans('AmountHT'),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ht",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
print '<td colspan="1"></td>';
|
||||||
|
}
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("AmountTTC"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ttc",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("Percentage"),
|
||||||
|
$_SERVER["PHP_SELF"],"amount_ttc",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("OtherStatistics"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"",
|
||||||
|
"",
|
||||||
|
"",
|
||||||
|
'align="center" width="20%"'
|
||||||
|
);
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
$var=true;
|
$var=true;
|
||||||
|
|
||||||
if (count($amount))
|
if (count($amount)) {
|
||||||
{
|
|
||||||
$arrayforsort=$name;
|
$arrayforsort=$name;
|
||||||
|
|
||||||
// We define arrayforsort
|
// We define arrayforsort
|
||||||
@ -239,6 +322,14 @@ if (count($amount))
|
|||||||
arsort($name);
|
arsort($name);
|
||||||
$arrayforsort=$name;
|
$arrayforsort=$name;
|
||||||
}
|
}
|
||||||
|
if ($sortfield == 'amount_ht' && $sortorder == 'asc') {
|
||||||
|
asort($amount_ht);
|
||||||
|
$arrayforsort=$amount_ht;
|
||||||
|
}
|
||||||
|
if ($sortfield == 'amount_ht' && $sortorder == 'desc') {
|
||||||
|
arsort($amount_ht);
|
||||||
|
$arrayforsort=$amount_ht;
|
||||||
|
}
|
||||||
if ($sortfield == 'amount_ttc' && $sortorder == 'asc') {
|
if ($sortfield == 'amount_ttc' && $sortorder == 'asc') {
|
||||||
asort($amount);
|
asort($amount);
|
||||||
$arrayforsort=$amount;
|
$arrayforsort=$amount;
|
||||||
@ -248,8 +339,7 @@ if (count($amount))
|
|||||||
$arrayforsort=$amount;
|
$arrayforsort=$amount;
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach($arrayforsort as $key => $value)
|
foreach($arrayforsort as $key => $value) {
|
||||||
{
|
|
||||||
$var=!$var;
|
$var=!$var;
|
||||||
print "<tr ".$bc[$var].">";
|
print "<tr ".$bc[$var].">";
|
||||||
|
|
||||||
@ -257,23 +347,44 @@ if (count($amount))
|
|||||||
$fullname=$name[$key];
|
$fullname=$name[$key];
|
||||||
if ($key >= 0) {
|
if ($key >= 0) {
|
||||||
$linkname='<a href="'.DOL_URL_ROOT.'/user/fiche.php?id='.$key.'">'.img_object($langs->trans("ShowUser"),'user').' '.$fullname.'</a>';
|
$linkname='<a href="'.DOL_URL_ROOT.'/user/fiche.php?id='.$key.'">'.img_object($langs->trans("ShowUser"),'user').' '.$fullname.'</a>';
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$linkname=$langs->trans("PaymentsNotLinkedToUser");
|
$linkname=$langs->trans("PaymentsNotLinkedToUser");
|
||||||
}
|
}
|
||||||
print "<td>".$linkname."</td>\n";
|
print "<td>".$linkname."</td>\n";
|
||||||
|
|
||||||
// Amount
|
// Amount w/o VAT
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
if ($modecompta != 'CREANCES-DETTES')
|
if ($modecompta != 'CREANCES-DETTES')
|
||||||
{
|
{
|
||||||
if ($key > 0) print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid='.$key.'">';
|
if ($key > 0) {
|
||||||
else print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid=-1">';
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid=-1">';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?userid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="#">';
|
||||||
|
}
|
||||||
|
print price($amount_ht[$key]);
|
||||||
|
}
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
|
// Amount with VAT
|
||||||
|
print '<td align="right">';
|
||||||
|
if ($modecompta != 'CREANCES-DETTES') {
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid=-1">';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?userid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="#">';
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
if ($key > 0) print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?userid='.$key.'">';
|
|
||||||
else print '<a href="#">';
|
|
||||||
}
|
}
|
||||||
print price($amount[$key]);
|
print price($amount[$key]);
|
||||||
print '</td>';
|
print '</td>';
|
||||||
@ -283,17 +394,30 @@ if (count($amount))
|
|||||||
|
|
||||||
// Other stats
|
// Other stats
|
||||||
print '<td align="center">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->propal->enabled) && $key>0) print ' <a href="'.DOL_URL_ROOT.'/comm/propal/stats/index.php?userid='.$key.'">'.img_picto($langs->trans("ProposalStats"),"stats").'</a> ';
|
if (! empty($conf->propal->enabled) && $key>0) {
|
||||||
if (! empty($conf->commande->enabled) && $key>0) print ' <a href="'.DOL_URL_ROOT.'/commande/stats/index.php?userid='.$key.'">'.img_picto($langs->trans("OrderStats"),"stats").'</a> ';
|
print ' <a href="'.DOL_URL_ROOT.'/comm/propal/stats/index.php?userid='.$key.'">'.img_picto($langs->trans("ProposalStats"),"stats").'</a> ';
|
||||||
if (! empty($conf->facture->enabled) && $key>0) print ' <a href="'.DOL_URL_ROOT.'/compta/facture/stats/index.php?userid='.$key.'">'.img_picto($langs->trans("InvoiceStats"),"stats").'</a> ';
|
}
|
||||||
|
if (! empty($conf->commande->enabled) && $key>0) {
|
||||||
|
print ' <a href="'.DOL_URL_ROOT.'/commande/stats/index.php?userid='.$key.'">'.img_picto($langs->trans("OrderStats"),"stats").'</a> ';
|
||||||
|
}
|
||||||
|
if (! empty($conf->facture->enabled) && $key>0) {
|
||||||
|
print ' <a href="'.DOL_URL_ROOT.'/compta/facture/stats/index.php?userid='.$key.'">'.img_picto($langs->trans("InvoiceStats"),"stats").'</a> ';
|
||||||
|
}
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Total
|
// Total
|
||||||
print '<tr class="liste_total"><td>'.$langs->trans("Total").'</td><td align="right">'.price($catotal).'</td><td> </td>';
|
print '<tr class="liste_total">';
|
||||||
|
print '<td>'.$langs->trans("Total").'</td>';
|
||||||
|
if ($modecompta != 'CREANCES-DETTES') {
|
||||||
|
print '<td colspan="1"></td>';
|
||||||
|
} else {
|
||||||
|
print '<td align="right">'.price($catotal_ht).'</td>';
|
||||||
|
}
|
||||||
|
print '<td align="right">'.price($catotal).'</td>';
|
||||||
|
print '<td> </td>';
|
||||||
print '<td> </td>';
|
print '<td> </td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
|
|||||||
@ -3,6 +3,7 @@
|
|||||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
||||||
|
* Copyright (C) 2013 Antoine Iauch <aiauch@gpcsolutions.fr>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -27,8 +28,10 @@ require '../../main.inc.php';
|
|||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/report.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/report.lib.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/tax.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/tax.lib.php';
|
||||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||||
|
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||||
|
|
||||||
$langs->load("companies");
|
$langs->load("companies");
|
||||||
|
$langs->load("categories");
|
||||||
|
|
||||||
// Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES')
|
// Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES')
|
||||||
$modecompta = $conf->global->COMPTA_MODE;
|
$modecompta = $conf->global->COMPTA_MODE;
|
||||||
@ -41,6 +44,13 @@ if (! $sortfield) $sortfield="nom";
|
|||||||
|
|
||||||
$socid = GETPOST('socid','int');
|
$socid = GETPOST('socid','int');
|
||||||
|
|
||||||
|
// Category
|
||||||
|
$selected_cat = (int)GETPOST('search_categ', 'int');
|
||||||
|
$subcat = false;
|
||||||
|
if (GETPOST('subcat', 'alpha') === 'yes') {
|
||||||
|
$subcat = true;
|
||||||
|
}
|
||||||
|
|
||||||
// Security check
|
// Security check
|
||||||
if ($user->societe_id > 0) $socid = $user->societe_id;
|
if ($user->societe_id > 0) $socid = $user->societe_id;
|
||||||
if (! empty($conf->comptabilite->enabled)) $result=restrictedArea($user,'compta','','','resultat');
|
if (! empty($conf->comptabilite->enabled)) $result=restrictedArea($user,'compta','','','resultat');
|
||||||
@ -49,6 +59,12 @@ if (! empty($conf->accounting->enabled)) $result=restrictedArea($user,'accountin
|
|||||||
// Date range
|
// Date range
|
||||||
$year=GETPOST("year");
|
$year=GETPOST("year");
|
||||||
$month=GETPOST("month");
|
$month=GETPOST("month");
|
||||||
|
$date_startyear = GETPOST("date_startyear");
|
||||||
|
$date_startmonth = GETPOST("date_startmonth");
|
||||||
|
$date_startday = GETPOST("date_startday");
|
||||||
|
$date_endyear = GETPOST("date_endyear");
|
||||||
|
$date_endmonth = GETPOST("date_endmonth");
|
||||||
|
$date_endday = GETPOST("date_endday");
|
||||||
if (empty($year))
|
if (empty($year))
|
||||||
{
|
{
|
||||||
$year_current = strftime("%Y",dol_now());
|
$year_current = strftime("%Y",dol_now());
|
||||||
@ -92,10 +108,34 @@ if (empty($date_start) || empty($date_end)) // We define date_start and date_end
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
// TODO We define q
|
// TODO We define q
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$commonparams=array();
|
||||||
|
$commonparams['modecompta']=$modecompta;
|
||||||
|
$commonparams['sortorder'] = $sortorder;
|
||||||
|
$commonparams['sortfield'] = $sortfield;
|
||||||
|
|
||||||
|
$headerparams = array();
|
||||||
|
$headerparams['date_startyear'] = $date_startyear;
|
||||||
|
$headerparams['date_startmonth'] = $date_startmonth;
|
||||||
|
$headerparams['date_startday'] = $date_startday;
|
||||||
|
$headerparams['date_endyear'] = $date_endyear;
|
||||||
|
$headerparams['date_endmonth'] = $date_endmonth;
|
||||||
|
$headerparams['date_endday'] = $date_endday;
|
||||||
|
$headerparams['q'] = $q;
|
||||||
|
|
||||||
|
$tableparams = array();
|
||||||
|
$tableparams['search_categ'] = $selected_cat;
|
||||||
|
$tableparams['subcat'] = ($subcat === true)?'yes':'';
|
||||||
|
|
||||||
|
// Adding common parameters
|
||||||
|
$allparams = array_merge($commonparams, $headerparams, $tableparams);
|
||||||
|
$headerparams = array_merge($commonparams, $headerparams);
|
||||||
|
$tableparams = array_merge($commonparams, $tableparams);
|
||||||
|
|
||||||
|
foreach($allparams as $key => $value) {
|
||||||
|
$paramslink .= '&' . $key . '=' . $value;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* View
|
* View
|
||||||
@ -105,8 +145,9 @@ llxHeader();
|
|||||||
|
|
||||||
$form=new Form($db);
|
$form=new Form($db);
|
||||||
$thirdparty_static=new Societe($db);
|
$thirdparty_static=new Societe($db);
|
||||||
|
$formother = new FormOther($db);
|
||||||
|
|
||||||
// Affiche en-tete de rapport
|
// Show report header
|
||||||
if ($modecompta=="CREANCES-DETTES")
|
if ($modecompta=="CREANCES-DETTES")
|
||||||
{
|
{
|
||||||
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
|
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
|
||||||
@ -118,8 +159,7 @@ if ($modecompta=="CREANCES-DETTES")
|
|||||||
else $description.= $langs->trans("DepositsAreIncluded");
|
else $description.= $langs->trans("DepositsAreIncluded");
|
||||||
$builddate=time();
|
$builddate=time();
|
||||||
//$exportlink=$langs->trans("NotYetAvailable");
|
//$exportlink=$langs->trans("NotYetAvailable");
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
|
$nom=$langs->trans("SalesTurnover").', '.$langs->trans("ByThirdParties");
|
||||||
$nom.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
|
$nom.='<br>('.$langs->trans("SeeReportInDueDebtMode",'<a href="'.$_SERVER["PHP_SELF"].'?year='.$year.'&modecompta=CREANCES-DETTES">','</a>').')';
|
||||||
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
$period=$form->select_date($date_start,'date_start',0,0,0,'',1,0,1).' - '.$form->select_date($date_end,'date_end',0,0,0,'',1,0,1);
|
||||||
@ -129,26 +169,44 @@ else {
|
|||||||
$builddate=time();
|
$builddate=time();
|
||||||
//$exportlink=$langs->trans("NotYetAvailable");
|
//$exportlink=$langs->trans("NotYetAvailable");
|
||||||
}
|
}
|
||||||
$moreparam=array();
|
|
||||||
if (! empty($modecompta)) $moreparam['modecompta']=$modecompta;
|
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,$tableparams);
|
||||||
report_header($nom,$nomlink,$period,$periodlink,$description,$builddate,$exportlink,$moreparam);
|
|
||||||
|
|
||||||
|
|
||||||
// Charge tableau
|
// Show Array
|
||||||
$catotal=0;
|
$catotal=0;
|
||||||
if ($modecompta == 'CREANCES-DETTES')
|
if ($modecompta == 'CREANCES-DETTES') {
|
||||||
{
|
$sql = "SELECT DISTINCT s.rowid as socid, s.nom as name,";
|
||||||
$sql = "SELECT s.rowid as socid, s.nom as name, sum(f.total) as amount, sum(f.total_ttc) as amount_ttc";
|
$sql.= " sum(DISTINCT f.total) as amount, sum(DISTINCT f.total_ttc) as amount_ttc";
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."societe as s";
|
$sql.= " FROM ".MAIN_DB_PREFIX."societe as s";
|
||||||
$sql.= ", ".MAIN_DB_PREFIX."facture as f";
|
$sql.= " JOIN ".MAIN_DB_PREFIX."facture as f";
|
||||||
$sql.= " WHERE f.fk_statut in (1,2)";
|
if ($selected_cat === -2) {
|
||||||
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) $sql.= " AND f.type IN (0,1,2)";
|
$sql.= " LEFT OUTER JOIN ".MAIN_DB_PREFIX."categorie_societe as cs ON s.rowid = cs.fk_societe";
|
||||||
else $sql.= " AND f.type IN (0,1,2,3)";
|
|
||||||
$sql.= " AND f.fk_soc = s.rowid";
|
|
||||||
if ($date_start && $date_end) $sql.= " AND f.datef >= '".$db->idate($date_start)."' AND f.datef <= '".$db->idate($date_end)."'";
|
|
||||||
}
|
}
|
||||||
else
|
if ($selected_cat && $selected_cat !== -2) {
|
||||||
{
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie as c ON c.rowid = ".$selected_cat;
|
||||||
|
if (subcat) {
|
||||||
|
$sql.=" OR c.fk_parent = " . $selected_cat;
|
||||||
|
}
|
||||||
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."categorie_societe as cs ON cs.fk_categorie = c.rowid";
|
||||||
|
}
|
||||||
|
$sql.= " WHERE f.fk_statut in (1,2)";
|
||||||
|
if (! empty($conf->global->FACTURE_DEPOSITS_ARE_JUST_PAYMENTS)) {
|
||||||
|
$sql.= " AND f.type IN (0,1,2)";
|
||||||
|
} else {
|
||||||
|
$sql.= " AND f.type IN (0,1,2,3)";
|
||||||
|
}
|
||||||
|
$sql.= " AND f.fk_soc = s.rowid";
|
||||||
|
if ($date_start && $date_end) {
|
||||||
|
$sql.= " AND f.datef >= '".$db->idate($date_start)."' AND f.datef <= '".$db->idate($date_end)."'";
|
||||||
|
}
|
||||||
|
if ($selected_cat === -2) {
|
||||||
|
$sql.=" AND cs.fk_societe is null";
|
||||||
|
}
|
||||||
|
if ($selected_cat && $selected_cat !== -2) {
|
||||||
|
$sql.= " AND cs.fk_societe = s.rowid";
|
||||||
|
}
|
||||||
|
} else {
|
||||||
/*
|
/*
|
||||||
* Liste des paiements (les anciens paiements ne sont pas vus par cette requete car, sur les
|
* Liste des paiements (les anciens paiements ne sont pas vus par cette requete car, sur les
|
||||||
* vieilles versions, ils n'etaient pas lies via paiement_facture. On les ajoute plus loin)
|
* vieilles versions, ils n'etaient pas lies via paiement_facture. On les ajoute plus loin)
|
||||||
@ -161,7 +219,9 @@ else
|
|||||||
$sql .= " WHERE p.rowid = pf.fk_paiement";
|
$sql .= " WHERE p.rowid = pf.fk_paiement";
|
||||||
$sql.= " AND pf.fk_facture = f.rowid";
|
$sql.= " AND pf.fk_facture = f.rowid";
|
||||||
$sql.= " AND f.fk_soc = s.rowid";
|
$sql.= " AND f.fk_soc = s.rowid";
|
||||||
if ($date_start && $date_end) $sql.= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
if ($date_start && $date_end) {
|
||||||
|
$sql.= " AND p.datep >= '".$db->idate($date_start)."' AND p.datep <= '".$db->idate($date_end)."'";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
$sql.= " AND f.entity = ".$conf->entity;
|
$sql.= " AND f.entity = ".$conf->entity;
|
||||||
if ($socid) $sql.= " AND f.fk_soc = ".$socid;
|
if ($socid) $sql.= " AND f.fk_soc = ".$socid;
|
||||||
@ -169,27 +229,26 @@ $sql.= " GROUP BY s.rowid, s.nom";
|
|||||||
$sql.= " ORDER BY s.rowid";
|
$sql.= " ORDER BY s.rowid";
|
||||||
|
|
||||||
$result = $db->query($sql);
|
$result = $db->query($sql);
|
||||||
if ($result)
|
if ($result) {
|
||||||
{
|
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($result);
|
||||||
$i=0;
|
$i=0;
|
||||||
while ($i < $num)
|
while ($i < $num) {
|
||||||
{
|
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($result);
|
||||||
$amount[$obj->socid] += $obj->amount_ttc;
|
$amount_ht[$obj->socid] = $obj->amount;
|
||||||
$name[$obj->socid] = $obj->name;
|
$amount[$obj->socid] = $obj->amount_ttc;
|
||||||
|
$name[$obj->socid] = $obj->name.' '.$obj->firstname;
|
||||||
|
$catotal_ht+=$obj->amount;
|
||||||
$catotal+=$obj->amount_ttc;
|
$catotal+=$obj->amount_ttc;
|
||||||
$i++;
|
$i++;
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
dol_print_error($db);
|
dol_print_error($db);
|
||||||
}
|
}
|
||||||
|
|
||||||
// On ajoute les paiements anciennes version, non lies par paiement_facture
|
// On ajoute les paiements anciennes version, non lies par paiement_facture
|
||||||
if ($modecompta != 'CREANCES-DETTES')
|
if ($modecompta != 'CREANCES-DETTES') {
|
||||||
{
|
$sql = "SELECT '0' as socid, 'Autres' as name, sum(DISTINCT p.amount) as amount_ttc";
|
||||||
$sql = "SELECT '0' as socid, 'Autres' as name, sum(p.amount) as amount_ttc";
|
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."bank as b";
|
$sql.= " FROM ".MAIN_DB_PREFIX."bank as b";
|
||||||
$sql.= ", ".MAIN_DB_PREFIX."bank_account as ba";
|
$sql.= ", ".MAIN_DB_PREFIX."bank_account as ba";
|
||||||
$sql.= ", ".MAIN_DB_PREFIX."paiement as p";
|
$sql.= ", ".MAIN_DB_PREFIX."paiement as p";
|
||||||
@ -203,20 +262,17 @@ if ($modecompta != 'CREANCES-DETTES')
|
|||||||
$sql.= " ORDER BY name";
|
$sql.= " ORDER BY name";
|
||||||
|
|
||||||
$result = $db->query($sql);
|
$result = $db->query($sql);
|
||||||
if ($result)
|
if ($result) {
|
||||||
{
|
|
||||||
$num = $db->num_rows($result);
|
$num = $db->num_rows($result);
|
||||||
$i=0;
|
$i=0;
|
||||||
while ($i < $num)
|
while ($i < $num) {
|
||||||
{
|
|
||||||
$obj = $db->fetch_object($result);
|
$obj = $db->fetch_object($result);
|
||||||
$amount[$obj->rowid] += $obj->amount_ttc;
|
$amount[$obj->rowid] += $obj->amount_ttc;
|
||||||
$name[$obj->rowid] = $obj->name;
|
$name[$obj->rowid] = $obj->name;
|
||||||
$catotal+=$obj->amount_ttc;
|
$catotal+=$obj->amount_ttc;
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
dol_print_error($db);
|
dol_print_error($db);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -224,20 +280,87 @@ if ($modecompta != 'CREANCES-DETTES')
|
|||||||
|
|
||||||
// Show array
|
// Show array
|
||||||
$i = 0;
|
$i = 0;
|
||||||
|
print '<form method="POST" action="'.$_SERVER["PHP_SELF"].'">';
|
||||||
|
// Extra parameters management
|
||||||
|
foreach($headerparams as $key => $value)
|
||||||
|
{
|
||||||
|
print '<input type="hidden" name="'.$key.'" value="'.$value.'">';
|
||||||
|
}
|
||||||
print "<table class=\"noborder\" width=\"100%\">";
|
print "<table class=\"noborder\" width=\"100%\">";
|
||||||
print "<tr class=\"liste_titre\">";
|
// Category filter
|
||||||
print_liste_field_titre($langs->trans("Company"),$_SERVER["PHP_SELF"],"nom","",'&year='.($year).'&modecompta='.$modecompta,"",$sortfield,$sortorder);
|
print '<tr class="liste_titre">';
|
||||||
print_liste_field_titre($langs->trans("AmountTTC"),$_SERVER["PHP_SELF"],"amount_ttc","",'&year='.($year).'&modecompta='.$modecompta,'align="right"',$sortfield,$sortorder);
|
print '<td>';
|
||||||
print_liste_field_titre($langs->trans("Percentage"),$_SERVER["PHP_SELF"],"amount_ttc","",'&year='.($year).'&modecompta='.$modecompta,'align="right"',$sortfield,$sortorder);
|
print $langs->trans("Category") . ': ' . $formother->select_categories(2, $selected_cat, 'search_categ', true);
|
||||||
print_liste_field_titre($langs->trans("OtherStatistics"),$_SERVER["PHP_SELF"],"","","",'align="center" width="20%"');
|
print ' ';
|
||||||
|
print $langs->trans("SubCats") . '? ';
|
||||||
|
print '<input type="checkbox" name="subcat" value="yes"';
|
||||||
|
if ($subcat) {
|
||||||
|
print ' checked="checked"';
|
||||||
|
}
|
||||||
|
print'></td>';
|
||||||
|
print '<td colspan="4" align="right">';
|
||||||
|
print '<input type="image" class="liste_titre" name="button_search" src="'.DOL_URL_ROOT.'/theme/'.$conf->theme.'/img/search.png" value="'.dol_escape_htmltag($langs->trans("Search")).'" title="'.dol_escape_htmltag($langs->trans("Search")).'">';
|
||||||
|
print '</td>';
|
||||||
|
print '</tr>';
|
||||||
|
// Array titles
|
||||||
|
print "<tr class='liste_titre'>";
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("Company"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"nom",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
"",
|
||||||
|
$sortfield,$sortorder
|
||||||
|
);
|
||||||
|
if ($modecompta == 'CREANCES-DETTES') {
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans('AmountHT'),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ht",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
} else {
|
||||||
|
print '<td colspan="1"></td>';
|
||||||
|
}
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("AmountTTC"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ttc",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("Percentage"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"amount_ttc",
|
||||||
|
"",
|
||||||
|
$paramslink,
|
||||||
|
'align="right"',
|
||||||
|
$sortfield,
|
||||||
|
$sortorder
|
||||||
|
);
|
||||||
|
print_liste_field_titre(
|
||||||
|
$langs->trans("OtherStatistics"),
|
||||||
|
$_SERVER["PHP_SELF"],
|
||||||
|
"",
|
||||||
|
"",
|
||||||
|
"",
|
||||||
|
'align="center" width="20%"'
|
||||||
|
);
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
$var=true;
|
$var=true;
|
||||||
|
|
||||||
if (count($amount))
|
if (count($amount)) {
|
||||||
{
|
|
||||||
$arrayforsort=$name;
|
$arrayforsort=$name;
|
||||||
|
// Defining array arrayforsort
|
||||||
// On definit tableau arrayforsort
|
|
||||||
if ($sortfield == 'nom' && $sortorder == 'asc') {
|
if ($sortfield == 'nom' && $sortorder == 'asc') {
|
||||||
asort($name);
|
asort($name);
|
||||||
$arrayforsort=$name;
|
$arrayforsort=$name;
|
||||||
@ -246,6 +369,14 @@ if (count($amount))
|
|||||||
arsort($name);
|
arsort($name);
|
||||||
$arrayforsort=$name;
|
$arrayforsort=$name;
|
||||||
}
|
}
|
||||||
|
if ($sortfield == 'amount_ht' && $sortorder == 'asc') {
|
||||||
|
asort($amount_ht);
|
||||||
|
$arrayforsort=$amount_ht;
|
||||||
|
}
|
||||||
|
if ($sortfield == 'amount_ht' && $sortorder == 'desc') {
|
||||||
|
arsort($amount_ht);
|
||||||
|
$arrayforsort=$amount_ht;
|
||||||
|
}
|
||||||
if ($sortfield == 'amount_ttc' && $sortorder == 'asc') {
|
if ($sortfield == 'amount_ttc' && $sortorder == 'asc') {
|
||||||
asort($amount);
|
asort($amount);
|
||||||
$arrayforsort=$amount;
|
$arrayforsort=$amount;
|
||||||
@ -255,8 +386,7 @@ if (count($amount))
|
|||||||
$arrayforsort=$amount;
|
$arrayforsort=$amount;
|
||||||
}
|
}
|
||||||
|
|
||||||
foreach($arrayforsort as $key=>$value)
|
foreach($arrayforsort as $key=>$value) {
|
||||||
{
|
|
||||||
$var=!$var;
|
$var=!$var;
|
||||||
print "<tr ".$bc[$var].">";
|
print "<tr ".$bc[$var].">";
|
||||||
|
|
||||||
@ -267,23 +397,43 @@ if (count($amount))
|
|||||||
$thirdparty_static->name=$fullname;
|
$thirdparty_static->name=$fullname;
|
||||||
$thirdparty_static->client=1;
|
$thirdparty_static->client=1;
|
||||||
$linkname=$thirdparty_static->getNomUrl(1,'customer');
|
$linkname=$thirdparty_static->getNomUrl(1,'customer');
|
||||||
}
|
} else {
|
||||||
else {
|
|
||||||
$linkname=$langs->trans("PaymentsNotLinkedToInvoice");
|
$linkname=$langs->trans("PaymentsNotLinkedToInvoice");
|
||||||
}
|
}
|
||||||
print "<td>".$linkname."</td>\n";
|
print "<td>".$linkname."</td>\n";
|
||||||
|
|
||||||
// Amount
|
// Amount w/o VAT
|
||||||
print '<td align="right">';
|
print '<td align="right">';
|
||||||
if ($modecompta != 'CREANCES-DETTES')
|
if ($modecompta != 'CREANCES-DETTES') {
|
||||||
{
|
if ($key > 0) {
|
||||||
if ($key > 0) print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?socid='.$key.'">';
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid='.$key.'">';
|
||||||
else print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?orphelins=1">';
|
} else {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?userid=-1">';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?userid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="#">';
|
||||||
|
}
|
||||||
|
print price($amount_ht[$key]);
|
||||||
|
}
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
|
// Amount with VAT
|
||||||
|
print '<td align="right">';
|
||||||
|
if ($modecompta != 'CREANCES-DETTES') {
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?socid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/paiement/liste.php?orphelins=1">';
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if ($key > 0) {
|
||||||
|
print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?socid='.$key.'">';
|
||||||
|
} else {
|
||||||
|
print '<a href="#">';
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
if ($key > 0) print '<a href="'.DOL_URL_ROOT.'/compta/facture/list.php?socid='.$key.'">';
|
|
||||||
else print '<a href="#">';
|
|
||||||
}
|
}
|
||||||
print price($amount[$key]);
|
print price($amount[$key]);
|
||||||
print '</a>';
|
print '</a>';
|
||||||
@ -294,17 +444,30 @@ if (count($amount))
|
|||||||
|
|
||||||
// Other stats
|
// Other stats
|
||||||
print '<td align="center">';
|
print '<td align="center">';
|
||||||
if (! empty($conf->propal->enabled) && $key>0) print ' <a href="'.DOL_URL_ROOT.'/comm/propal/stats/index.php?socid='.$key.'">'.img_picto($langs->trans("ProposalStats"),"stats").'</a> ';
|
if (! empty($conf->propal->enabled) && $key>0) {
|
||||||
if (! empty($conf->commande->enabled) && $key>0) print ' <a href="'.DOL_URL_ROOT.'/commande/stats/index.php?socid='.$key.'">'.img_picto($langs->trans("OrderStats"),"stats").'</a> ';
|
print ' <a href="'.DOL_URL_ROOT.'/comm/propal/stats/index.php?socid='.$key.'">'.img_picto($langs->trans("ProposalStats"),"stats").'</a> ';
|
||||||
if (! empty($conf->facture->enabled) && $key>0) print ' <a href="'.DOL_URL_ROOT.'/compta/facture/stats/index.php?socid='.$key.'">'.img_picto($langs->trans("InvoiceStats"),"stats").'</a> ';
|
}
|
||||||
|
if (! empty($conf->commande->enabled) && $key>0) {
|
||||||
|
print ' <a href="'.DOL_URL_ROOT.'/commande/stats/index.php?socid='.$key.'">'.img_picto($langs->trans("OrderStats"),"stats").'</a> ';
|
||||||
|
}
|
||||||
|
if (! empty($conf->facture->enabled) && $key>0) {
|
||||||
|
print ' <a href="'.DOL_URL_ROOT.'/compta/facture/stats/index.php?socid='.$key.'">'.img_picto($langs->trans("InvoiceStats"),"stats").'</a> ';
|
||||||
|
}
|
||||||
print '</td>';
|
print '</td>';
|
||||||
|
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
$i++;
|
$i++;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Total
|
// Total
|
||||||
print '<tr class="liste_total"><td>'.$langs->trans("Total").'</td><td align="right">'.price($catotal).'</td><td> </td>';
|
print '<tr class="liste_total">';
|
||||||
|
print '<td>'.$langs->trans("Total").'</td>';
|
||||||
|
if ($modecompta != 'CREANCES-DETTES') {
|
||||||
|
print '<td colspan="1"></td>';
|
||||||
|
} else {
|
||||||
|
print '<td align="right">'.price($catotal_ht).'</td>';
|
||||||
|
}
|
||||||
|
print '<td align="right">'.price($catotal).'</td>';
|
||||||
|
print '<td> </td>';
|
||||||
print '<td> </td>';
|
print '<td> </td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
@ -312,8 +475,7 @@ if (count($amount))
|
|||||||
}
|
}
|
||||||
|
|
||||||
print "</table>";
|
print "</table>";
|
||||||
print '<br>';
|
print '</form>';
|
||||||
|
|
||||||
|
|
||||||
llxFooter();
|
llxFooter();
|
||||||
|
|
||||||
|
|||||||
@ -4,6 +4,7 @@
|
|||||||
* Copyright (C) 2005 Simon Tosser <simon@kornog-computing.com>
|
* Copyright (C) 2005 Simon Tosser <simon@kornog-computing.com>
|
||||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2010 Pierre Morin <pierre.morin@auguria.net>
|
* Copyright (C) 2010 Pierre Morin <pierre.morin@auguria.net>
|
||||||
|
* Copyright (C) 2013 Marcos García <marcosgdf@gmail.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -139,8 +140,7 @@ if (! dol_is_dir($upload_dir))
|
|||||||
print '<!-- TYPE='.$type.' -->'."\n";
|
print '<!-- TYPE='.$type.' -->'."\n";
|
||||||
print '<!-- Page called with mode='.(isset($mode)?$mode:'').' type='.$type.' module='.$module.' url='.$_SERVER["PHP_SELF"].'?'.$_SERVER["QUERY_STRING"].' -->'."\n";
|
print '<!-- Page called with mode='.(isset($mode)?$mode:'').' type='.$type.' module='.$module.' url='.$_SERVER["PHP_SELF"].'?'.$_SERVER["QUERY_STRING"].' -->'."\n";
|
||||||
|
|
||||||
$param='';
|
$param=($sortfield?'&sortfield='.$sortfield:'').($sortorder?'&sortorder='.$sortorder:'');
|
||||||
$param.=($sortfield?'&sortfield='.$sortfield:'').($sortorder?'&sortorder='.$sortorder:'');
|
|
||||||
$url=DOL_URL_ROOT.'/ecm/index.php';
|
$url=DOL_URL_ROOT.'/ecm/index.php';
|
||||||
|
|
||||||
// Dir scan
|
// Dir scan
|
||||||
@ -149,126 +149,73 @@ if ($type == 'directory')
|
|||||||
$formfile=new FormFile($db);
|
$formfile=new FormFile($db);
|
||||||
|
|
||||||
$maxlengthname=40;
|
$maxlengthname=40;
|
||||||
|
$excludefiles = array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^payments$','^CVS$','^thumbs$');
|
||||||
|
$sorting = (strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC);
|
||||||
|
|
||||||
// Right area. If module is defined, we are in automatic ecm.
|
// Right area. If module is defined, we are in automatic ecm.
|
||||||
if ($module == 'company') // Auto area for suppliers invoices
|
$automodules = array('company', 'invoice', 'invoice_supplier', 'propal', 'order', 'order_supplier', 'contract', 'product', 'tax', 'project');
|
||||||
{
|
|
||||||
$upload_dir = $conf->societe->dir_output; // TODO change for multicompany sharing
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^payments$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
// TODO change for multicompany sharing
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
// Auto area for suppliers invoices
|
||||||
|
if ($module == 'company') $upload_dir = $conf->societe->dir_output;
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
// Auto area for suppliers invoices
|
||||||
}
|
else if ($module == 'invoice') $upload_dir = $conf->facture->dir_output;
|
||||||
else if ($module == 'invoice') // Auto area for suppliers invoices
|
// Auto area for suppliers invoices
|
||||||
{
|
else if ($module == 'invoice_supplier')
|
||||||
$upload_dir = $conf->facture->dir_output;
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^payments$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
|
||||||
else if ($module == 'invoice_supplier') // Auto area for suppliers invoices
|
|
||||||
{
|
{
|
||||||
$relativepath='facture';
|
$relativepath='facture';
|
||||||
$upload_dir = $conf->fournisseur->dir_output.'/'.$relativepath;
|
$upload_dir = $conf->fournisseur->dir_output.'/'.$relativepath;
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
$param.='&module='.$module;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
}
|
||||||
else if ($module == 'propal') // Auto area for customers orders
|
// Auto area for customers orders
|
||||||
{
|
else if ($module == 'propal') $upload_dir = $conf->propal->dir_output;
|
||||||
$upload_dir = $conf->propal->dir_output;
|
// Auto area for customers orders
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^payments$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
else if ($module == 'order') $upload_dir = $conf->commande->dir_output;
|
||||||
|
// Auto area for suppliers orders
|
||||||
$param.='&module='.$module;
|
else if ($module == 'order_supplier')
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
|
||||||
else if ($module == 'order') // Auto area for customers orders
|
|
||||||
{
|
|
||||||
$upload_dir = $conf->commande->dir_output;
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^payments$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
|
||||||
else if ($module == 'order_supplier') // Auto area for suppliers orders
|
|
||||||
{
|
{
|
||||||
$relativepath='commande';
|
$relativepath='commande';
|
||||||
$upload_dir = $conf->fournisseur->dir_output.'/'.$relativepath;
|
$upload_dir = $conf->fournisseur->dir_output.'/'.$relativepath;
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^payments$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
}
|
||||||
else if ($module == 'contract') // Auto area for suppliers invoices
|
// Auto area for suppliers invoices
|
||||||
|
else if ($module == 'contract') $upload_dir = $conf->contrat->dir_output;
|
||||||
|
// Auto area for products
|
||||||
|
else if ($module == 'product') $upload_dir = $conf->product->dir_output;
|
||||||
|
// Auto area for suppliers invoices
|
||||||
|
else if ($module == 'tax') $upload_dir = $conf->tax->dir_output;
|
||||||
|
// Auto area for projects
|
||||||
|
else if ($module == 'project') $upload_dir = $conf->projet->dir_output;
|
||||||
|
|
||||||
|
if (in_array($module, $automodules))
|
||||||
{
|
{
|
||||||
$upload_dir = $conf->contrat->dir_output;
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
$param.='&module='.$module;
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
||||||
|
|
||||||
|
$filearray=dol_dir_list($upload_dir,"files",1,'', $excludefiles, $sortfield, $sorting,1);
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
||||||
}
|
}
|
||||||
else if ($module == 'product') // Auto area for products
|
//Manual area
|
||||||
{
|
else
|
||||||
$upload_dir = $conf->product->dir_output;
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
|
||||||
else if ($module == 'tax') // Auto area for suppliers invoices
|
|
||||||
{
|
|
||||||
$upload_dir = $conf->tax->dir_output;
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
|
||||||
else if ($module == 'project') // Auto area for projects
|
|
||||||
{
|
|
||||||
$upload_dir = $conf->projet->dir_output;
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",1,'',array('^SPECIMEN\.pdf$','^\.','\.meta$','^temp$','^CVS$','^thumbs$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
$param.='&module='.$module;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("NoFileFound")));
|
|
||||||
|
|
||||||
$formfile->list_of_autoecmfiles($upload_dir,$filearray,$module,$param,1,'',$user->rights->ecm->upload,1,$textifempty,$maxlengthname,$url);
|
|
||||||
}
|
|
||||||
else // Manual area
|
|
||||||
{
|
{
|
||||||
$relativepath=$ecmdir->getRelativePath();
|
$relativepath=$ecmdir->getRelativePath();
|
||||||
$upload_dir = $conf->ecm->dir_output.'/'.$relativepath;
|
$upload_dir = $conf->ecm->dir_output.'/'.$relativepath;
|
||||||
|
|
||||||
$filearray=dol_dir_list($upload_dir,"files",0,'',array('^\.','\.meta$','^temp$','^CVS$'),$sortfield,(strtolower($sortorder)=='desc'?SORT_DESC:SORT_ASC),1);
|
|
||||||
|
|
||||||
if ($section) $param.='§ion='.$section;
|
|
||||||
$textifempty=($section?$langs->trans("NoFileFound"):($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("ECMSelectASection")));
|
|
||||||
// If $section defined with value 0
|
// If $section defined with value 0
|
||||||
if ($section === '0')
|
if ($section === '0')
|
||||||
{
|
{
|
||||||
$filearray=array();
|
$filearray=array();
|
||||||
$textifempty='<br><div align="center"><font class="warning">'.$langs->trans("DirNotSynchronizedSyncFirst").'</font></div><br>';
|
$textifempty='<br><div align="center"><font class="warning">'.$langs->trans("DirNotSynchronizedSyncFirst").'</font></div><br>';
|
||||||
}
|
}
|
||||||
|
else $filearray=dol_dir_list($upload_dir,"files",0,'',array('^\.','\.meta$','^temp$','^CVS$'),$sortfield, $sorting,1);
|
||||||
|
|
||||||
|
if ($section)
|
||||||
|
{
|
||||||
|
$param.='§ion='.$section;
|
||||||
|
$textifempty = $langs->trans('NoFileFound');
|
||||||
|
}
|
||||||
|
else $textifempty=($showonrightsize=='featurenotyetavailable'?$langs->trans("FeatureNotYetAvailable"):$langs->trans("ECMSelectASection"));
|
||||||
|
|
||||||
$formfile->list_of_documents($filearray,'','ecm',$param,1,$relativepath,$user->rights->ecm->upload,1,$textifempty,$maxlengthname,'',$url);
|
$formfile->list_of_documents($filearray,'','ecm',$param,1,$relativepath,$user->rights->ecm->upload,1,$textifempty,$maxlengthname,'',$url);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (! empty($conf->use_javascript_ajax) && empty($conf->global->MAIN_ECM_DISABLE_JS))
|
if (! empty($conf->use_javascript_ajax) && empty($conf->global->MAIN_ECM_DISABLE_JS))
|
||||||
|
|||||||
@ -117,7 +117,7 @@ if (file_exists($fullpathselecteddir))
|
|||||||
// Loop on all database entries (sqltree) to find the one matching the subdir found into dir to scan
|
// Loop on all database entries (sqltree) to find the one matching the subdir found into dir to scan
|
||||||
foreach($sqltree as $key => $tmpval)
|
foreach($sqltree as $key => $tmpval)
|
||||||
{
|
{
|
||||||
//print "-- key=".$key." - ".$val['fullrelativename']." vs ".(($selecteddir != '/'?$selecteddir.'/':'').$file).'<br>';
|
//print "-- key=".$key." - ".$tmpval['fullrelativename']." vs ".(($selecteddir != '/'?$selecteddir.'/':'').$file)."<br>\n";
|
||||||
if ($tmpval['fullrelativename'] == (($selecteddir != '/'?$selecteddir.'/':'').$file)) // We found equivalent record into database
|
if ($tmpval['fullrelativename'] == (($selecteddir != '/'?$selecteddir.'/':'').$file)) // We found equivalent record into database
|
||||||
{
|
{
|
||||||
$val=$tmpval;
|
$val=$tmpval;
|
||||||
|
|||||||
@ -56,6 +56,8 @@ class FileUpload
|
|||||||
$filename = $regs[2];
|
$filename = $regs[2];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$parentForeignKey = '';
|
||||||
|
|
||||||
// For compatibility
|
// For compatibility
|
||||||
if ($element == 'propal') {
|
if ($element == 'propal') {
|
||||||
$pathname = 'comm/propal';
|
$pathname = 'comm/propal';
|
||||||
@ -69,6 +71,14 @@ class FileUpload
|
|||||||
$element = $pathname = 'projet';
|
$element = $pathname = 'projet';
|
||||||
$dir_output=$conf->$element->dir_output;
|
$dir_output=$conf->$element->dir_output;
|
||||||
}
|
}
|
||||||
|
elseif ($element == 'project_task') {
|
||||||
|
$pathname = 'projet'; $filename='task';
|
||||||
|
$dir_output=$conf->projet->dir_output;
|
||||||
|
$parentForeignKey = 'fk_project';
|
||||||
|
$parentClass = 'Project';
|
||||||
|
$parentElement = 'projet';
|
||||||
|
$parentObject = 'project';
|
||||||
|
}
|
||||||
elseif ($element == 'fichinter') {
|
elseif ($element == 'fichinter') {
|
||||||
$element='ficheinter';
|
$element='ficheinter';
|
||||||
$dir_output=$conf->$element->dir_output;
|
$dir_output=$conf->$element->dir_output;
|
||||||
@ -80,6 +90,17 @@ class FileUpload
|
|||||||
elseif ($element == 'invoice_supplier') {
|
elseif ($element == 'invoice_supplier') {
|
||||||
$pathname = 'fourn'; $filename='fournisseur.facture';
|
$pathname = 'fourn'; $filename='fournisseur.facture';
|
||||||
$dir_output=$conf->fournisseur->facture->dir_output;
|
$dir_output=$conf->fournisseur->facture->dir_output;
|
||||||
|
}
|
||||||
|
elseif ($element == 'product') {
|
||||||
|
$dir_output = $conf->product->multidir_output[$conf->entity];
|
||||||
|
}
|
||||||
|
elseif ($element == 'action') {
|
||||||
|
$pathname = 'comm/action'; $filename='actioncomm';
|
||||||
|
$dir_output=$conf->agenda->dir_output;
|
||||||
|
}
|
||||||
|
elseif ($element == 'chargesociales') {
|
||||||
|
$pathname = 'compta/sociales'; $filename='chargesociales';
|
||||||
|
$dir_output=$conf->tax->dir_output;
|
||||||
} else {
|
} else {
|
||||||
$dir_output=$conf->$element->dir_output;
|
$dir_output=$conf->$element->dir_output;
|
||||||
}
|
}
|
||||||
@ -97,11 +118,23 @@ class FileUpload
|
|||||||
$object = new $classname($db);
|
$object = new $classname($db);
|
||||||
|
|
||||||
$object->fetch($fk_element);
|
$object->fetch($fk_element);
|
||||||
|
if (!empty($parentForeignKey)) {
|
||||||
|
dol_include_once('/'.$parentElement.'/class/'.$parentObject.'.class.php');
|
||||||
|
$parent = new $parentClass($db);
|
||||||
|
$parent->fetch($object->$parentForeignKey);
|
||||||
|
if (!empty($parent->socid)) {
|
||||||
|
$parent->fetch_thirdparty();
|
||||||
|
}
|
||||||
|
$object->$parentObject = dol_clone($parent);
|
||||||
|
} else {
|
||||||
$object->fetch_thirdparty();
|
$object->fetch_thirdparty();
|
||||||
|
}
|
||||||
|
|
||||||
$object_ref = dol_sanitizeFileName($object->ref);
|
$object_ref = dol_sanitizeFileName($object->ref);
|
||||||
if ($element == 'invoice_supplier') {
|
if ($element == 'invoice_supplier') {
|
||||||
$object_ref = get_exdir($object->id, 2) . $object_ref;
|
$object_ref = get_exdir($object->id, 2) . $object_ref;
|
||||||
|
} else if ($element == 'project_task') {
|
||||||
|
$object_ref = $object->project->ref . '/' . $object_ref;
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->options = array(
|
$this->options = array(
|
||||||
|
|||||||
@ -144,7 +144,6 @@ class HookManager
|
|||||||
foreach($modules as $module => $actionclassinstance)
|
foreach($modules as $module => $actionclassinstance)
|
||||||
{
|
{
|
||||||
//print 'class='.get_class($actionclassinstance).' method='.$method.' action='.$action;
|
//print 'class='.get_class($actionclassinstance).' method='.$method.' action='.$action;
|
||||||
|
|
||||||
// jump to next class if method does not exists
|
// jump to next class if method does not exists
|
||||||
if (! method_exists($actionclassinstance,$method)) continue;
|
if (! method_exists($actionclassinstance,$method)) continue;
|
||||||
// test to avoid to run twice a hook, when a module implements several active contexts
|
// test to avoid to run twice a hook, when a module implements several active contexts
|
||||||
@ -178,7 +177,7 @@ class HookManager
|
|||||||
|
|
||||||
$result = $actionclassinstance->$method($parameters, $object, $action, $this); // $object and $action can be changed by method ($object->id during creation for example or $action to go back to other action for example)
|
$result = $actionclassinstance->$method($parameters, $object, $action, $this); // $object and $action can be changed by method ($object->id during creation for example or $action to go back to other action for example)
|
||||||
|
|
||||||
if (is_array($actionclassinstance->results)) $this->resArray =array_merge($this->resArray, $actionclassinstance->results);
|
if (! empty($actionclassinstance->results) && is_array($actionclassinstance->results)) $this->resArray =array_merge($this->resArray, $actionclassinstance->results);
|
||||||
if (! empty($actionclassinstance->resprints)) $this->resPrint.=$actionclassinstance->resprints;
|
if (! empty($actionclassinstance->resprints)) $this->resPrint.=$actionclassinstance->resprints;
|
||||||
|
|
||||||
// TODO. remove this. array result must be set into $actionclassinstance->results
|
// TODO. remove this. array result must be set into $actionclassinstance->results
|
||||||
|
|||||||
@ -344,7 +344,7 @@ class Form
|
|||||||
* Show a text and picto with tooltip on text or picto
|
* Show a text and picto with tooltip on text or picto
|
||||||
*
|
*
|
||||||
* @param string $text Text to show
|
* @param string $text Text to show
|
||||||
* @param string $htmltext Content html of tooltip. Must be HTML/UTF8 encoded.
|
* @param string $htmltext HTML content of tooltip. Must be HTML/UTF8 encoded.
|
||||||
* @param int $tooltipon 1=tooltip sur texte, 2=tooltip sur picto, 3=tooltip sur les 2
|
* @param int $tooltipon 1=tooltip sur texte, 2=tooltip sur picto, 3=tooltip sur les 2
|
||||||
* @param int $direction -1=Le picto est avant, 0=pas de picto, 1=le picto est apres
|
* @param int $direction -1=Le picto est avant, 0=pas de picto, 1=le picto est apres
|
||||||
* @param string $img Code img du picto (use img_xxx() function to get it)
|
* @param string $img Code img du picto (use img_xxx() function to get it)
|
||||||
@ -383,7 +383,7 @@ class Form
|
|||||||
//if ($text != '') $s.='<'.$tag.$paramfortooltiptd.'>'.(($direction < 0)?' ':'').$text.(($direction > 0)?' ':'').'</'.$tag.'>';
|
//if ($text != '') $s.='<'.$tag.$paramfortooltiptd.'>'.(($direction < 0)?' ':'').$text.(($direction > 0)?' ':'').'</'.$tag.'>';
|
||||||
$paramfortooltiptd.= (($direction < 0)?' style="padding-left: 3px !important;"':'');
|
$paramfortooltiptd.= (($direction < 0)?' style="padding-left: 3px !important;"':'');
|
||||||
$paramfortooltiptd.= (($direction > 0)?' style="padding-right: 3px !important;"':'');
|
$paramfortooltiptd.= (($direction > 0)?' style="padding-right: 3px !important;"':'');
|
||||||
if ($text != '') $s.='<'.$tag.$paramfortooltiptd.'>'.$text.'</'.$tag.'>';
|
if ((string) $text != '') $s.='<'.$tag.$paramfortooltiptd.'>'.$text.'</'.$tag.'>';
|
||||||
if ($direction > 0) $s.='<'.$tag.$paramfortooltipimg.' valign="top" width="14">'.$img.'</'.$tag.'>';
|
if ($direction > 0) $s.='<'.$tag.$paramfortooltipimg.' valign="top" width="14">'.$img.'</'.$tag.'>';
|
||||||
if (empty($notabs)) $s.='</tr></table>';
|
if (empty($notabs)) $s.='</tr></table>';
|
||||||
|
|
||||||
|
|||||||
@ -384,6 +384,11 @@ function agenda_prepare_head()
|
|||||||
$head[$h][2] = 'extsites';
|
$head[$h][2] = 'extsites';
|
||||||
$h++;
|
$h++;
|
||||||
|
|
||||||
|
$head[$h][0] = DOL_URL_ROOT."/admin/agenda_other.php";
|
||||||
|
$head[$h][1] = $langs->trans("Other");
|
||||||
|
$head[$h][2] = 'other';
|
||||||
|
$h++;
|
||||||
|
|
||||||
complete_head_from_modules($conf,$langs,$object,$head,$h,'agenda_admin');
|
complete_head_from_modules($conf,$langs,$object,$head,$h,'agenda_admin');
|
||||||
|
|
||||||
$head[$h][0] = DOL_URL_ROOT."/admin/agenda_extrafields.php";
|
$head[$h][0] = DOL_URL_ROOT."/admin/agenda_extrafields.php";
|
||||||
|
|||||||
@ -47,7 +47,7 @@ function societe_prepare_head($object)
|
|||||||
{
|
{
|
||||||
$head[$h][0] = DOL_URL_ROOT.'/comm/fiche.php?socid='.$object->id;
|
$head[$h][0] = DOL_URL_ROOT.'/comm/fiche.php?socid='.$object->id;
|
||||||
if (empty($conf->global->SOCIETE_DISABLE_PROSPECTS) && ($object->client==2 || $object->client==3)) $head[$h][1] = $langs->trans("Prospect");
|
if (empty($conf->global->SOCIETE_DISABLE_PROSPECTS) && ($object->client==2 || $object->client==3)) $head[$h][1] = $langs->trans("Prospect");
|
||||||
if ($object->client==3) $head[$h][1] .= '/';
|
if (empty($conf->global->SOCIETE_DISABLE_PROSPECTS) && empty($conf->global->SOCIETE_DISABLE_CUSTOMERS) && $object->client==3) $head[$h][1] .= '/';
|
||||||
if (empty($conf->global->SOCIETE_DISABLE_CUSTOMERS) && ($object->client==1 || $object->client==3)) $head[$h][1] .= $langs->trans("Customer");
|
if (empty($conf->global->SOCIETE_DISABLE_CUSTOMERS) && ($object->client==1 || $object->client==3)) $head[$h][1] .= $langs->trans("Customer");
|
||||||
$head[$h][2] = 'customer';
|
$head[$h][2] = 'customer';
|
||||||
$h++;
|
$h++;
|
||||||
|
|||||||
@ -814,6 +814,7 @@ function dol_print_date($time,$format='',$tzoutput='tzserver',$outputlangs='',$e
|
|||||||
}
|
}
|
||||||
if (! is_object($outputlangs)) $outputlangs=$langs;
|
if (! is_object($outputlangs)) $outputlangs=$langs;
|
||||||
if (! $format) $format='daytextshort';
|
if (! $format) $format='daytextshort';
|
||||||
|
$reduceformat=(! empty($conf->dol_optimize_smallscreen) && in_array($format,array('day','hour')))?1:0;
|
||||||
|
|
||||||
// Change predefined format into computer format. If found translation in lang file we use it, otherwise we use default.
|
// Change predefined format into computer format. If found translation in lang file we use it, otherwise we use default.
|
||||||
if ($format == 'day') $format=($outputlangs->trans("FormatDateShort")!="FormatDateShort"?$outputlangs->trans("FormatDateShort"):$conf->format_date_short);
|
if ($format == 'day') $format=($outputlangs->trans("FormatDateShort")!="FormatDateShort"?$outputlangs->trans("FormatDateShort"):$conf->format_date_short);
|
||||||
@ -834,6 +835,12 @@ function dol_print_date($time,$format='',$tzoutput='tzserver',$outputlangs='',$e
|
|||||||
else if ($format == 'dayhourrfc') $format='%Y-%m-%dT%H:%M:%SZ'; // DATETIME RFC3339
|
else if ($format == 'dayhourrfc') $format='%Y-%m-%dT%H:%M:%SZ'; // DATETIME RFC3339
|
||||||
else if ($format == 'standard') $format='%Y-%m-%d %H:%M:%S';
|
else if ($format == 'standard') $format='%Y-%m-%d %H:%M:%S';
|
||||||
|
|
||||||
|
if ($reduceformat)
|
||||||
|
{
|
||||||
|
$format=str_replace('%Y','%y',$format);
|
||||||
|
$format=str_replace('yyyy','yy',$format);
|
||||||
|
}
|
||||||
|
|
||||||
// If date undefined or "", we return ""
|
// If date undefined or "", we return ""
|
||||||
if (dol_strlen($time) == 0) return ''; // $time=0 allowed (it means 01/01/1970 00:00:00)
|
if (dol_strlen($time) == 0) return ''; // $time=0 allowed (it means 01/01/1970 00:00:00)
|
||||||
|
|
||||||
|
|||||||
@ -1283,7 +1283,7 @@ function getListOfModels($db,$type,$maxfilenamelength=0)
|
|||||||
if (! $tmpdir) { unset($listofdir[$key]); continue; }
|
if (! $tmpdir) { unset($listofdir[$key]); continue; }
|
||||||
if (is_dir($tmpdir))
|
if (is_dir($tmpdir))
|
||||||
{
|
{
|
||||||
$tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt','','name',SORT_ASC,0,true); // Disable hook for the moment
|
$tmpfiles=dol_dir_list($tmpdir,'files',0,'\.od(s|t)$','','name',SORT_ASC,0,true); // Disable hook for the moment
|
||||||
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
|
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -852,6 +852,8 @@ function print_left_eldy_menu($db,$menu_array_before,$menu_array_after,&$tabMenu
|
|||||||
*/
|
*/
|
||||||
if (empty($leftmenu) || $leftmenu=="ca") $newmenu->add("/compta/stats/casoc.php?leftmenu=ca",$langs->trans("ByCompanies"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if (empty($leftmenu) || $leftmenu=="ca") $newmenu->add("/compta/stats/casoc.php?leftmenu=ca",$langs->trans("ByCompanies"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
if (empty($leftmenu) || $leftmenu=="ca") $newmenu->add("/compta/stats/cabyuser.php?leftmenu=ca",$langs->trans("ByUsers"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
if (empty($leftmenu) || $leftmenu=="ca") $newmenu->add("/compta/stats/cabyuser.php?leftmenu=ca",$langs->trans("ByUsers"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
|
if (empty($leftmenu) || $leftmenu=="ca") $newmenu->add("/compta/stats/cabyprodserv.php?leftmenu=ca", $langs->trans("ByProductsAndServices"),2,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
|
|
||||||
|
|
||||||
// Journaux
|
// Journaux
|
||||||
//if ($leftmenu=="ca") $newmenu->add("/compta/journaux/index.php?leftmenu=ca",$langs->trans("Journaux"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
//if ($leftmenu=="ca") $newmenu->add("/compta/journaux/index.php?leftmenu=ca",$langs->trans("Journaux"),1,$user->rights->compta->resultat->lire||$user->rights->accounting->comptarapport->lire);
|
||||||
|
|||||||
@ -198,10 +198,10 @@ class modFacture extends DolibarrModules
|
|||||||
$this->export_label[$r]='CustomersInvoicesAndPayments'; // Translation key (used only if key ExportDataset_xxx_z not found)
|
$this->export_label[$r]='CustomersInvoicesAndPayments'; // Translation key (used only if key ExportDataset_xxx_z not found)
|
||||||
$this->export_icon[$r]='bill';
|
$this->export_icon[$r]='bill';
|
||||||
$this->export_permission[$r]=array(array("facture","facture","export"));
|
$this->export_permission[$r]=array(array("facture","facture","export"));
|
||||||
$this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.zip'=>'Zip','s.town'=>'Town','c.code'=>'CountryCode','s.phone'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','s.code_compta'=>'CustomerAccountancyCode','s.code_compta_fournisseur'=>'SupplierAccountancyCode','s.tva_intra'=>'VATIntra','f.rowid'=>"InvoiceId",'f.facnumber'=>"InvoiceRef",'f.datec'=>"InvoiceDateCreation",'f.datef'=>"DateInvoice",'f.date_lim_reglement'=>"DateDue",'f.total'=>"TotalHT",'f.total_ttc'=>"TotalTTC",'f.tva'=>"TotalVAT",'f.paye'=>"InvoicePaid",'f.fk_statut'=>'InvoiceStatus','f.note'=>"NotePrivate",'f.note_public'=>"NotePublic",'p.rowid'=>'PaymentId','pf.amount'=>'AmountPayment','p.datep'=>'DatePayment','p.num_paiement'=>'PaymentNumber');
|
$this->export_fields_array[$r]=array('s.rowid'=>"IdCompany",'s.nom'=>'CompanyName','s.address'=>'Address','s.zip'=>'Zip','s.town'=>'Town','c.code'=>'CountryCode','s.phone'=>'Phone','s.siren'=>'ProfId1','s.siret'=>'ProfId2','s.ape'=>'ProfId3','s.idprof4'=>'ProfId4','s.code_compta'=>'CustomerAccountancyCode','s.code_compta_fournisseur'=>'SupplierAccountancyCode','s.tva_intra'=>'VATIntra','f.rowid'=>"InvoiceId",'f.facnumber'=>"InvoiceRef",'f.datec'=>"InvoiceDateCreation",'f.datef'=>"DateInvoice",'f.date_lim_reglement'=>"DateDue",'f.total'=>"TotalHT",'f.total_ttc'=>"TotalTTC",'f.tva'=>"TotalVAT",'f.paye'=>"InvoicePaid",'f.fk_statut'=>'InvoiceStatus','f.note_private'=>"NotePrivate",'f.note_public'=>"NotePublic",'p.rowid'=>'PaymentId','pf.amount'=>'AmountPayment','p.datep'=>'DatePayment','p.num_paiement'=>'PaymentNumber');
|
||||||
//$this->export_TypeFields_array[$r]=array('s.rowid'=>"List:societe:nom",'s.nom'=>'Text','s.address'=>'Text','s.zip'=>'Text','s.town'=>'Text','c.code'=>'Text','s.phone'=>'Text','s.siren'=>'Text','s.siret'=>'Text','s.ape'=>'Text','s.idprof4'=>'Text','s.code_compta'=>'Text','s.code_compta_fournisseur'=>'Text','s.tva_intra'=>'Text','f.rowid'=>"List:facture:facnumber",'f.facnumber'=>"Text",'f.datec'=>"Date",'f.datef'=>"Date",'f.date_lim_reglement'=>"Date",'f.total'=>"Number",'f.total_ttc'=>"Number",'f.tva'=>"Number",'f.paye'=>"Boolean",'f.fk_statut'=>'Status','f.note'=>"Text",'f.note_public'=>"Text",'pf.amount'=>'Number','p.datep'=>'Date','p.num_paiement'=>'Number');
|
//$this->export_TypeFields_array[$r]=array('s.rowid'=>"List:societe:nom",'s.nom'=>'Text','s.address'=>'Text','s.zip'=>'Text','s.town'=>'Text','c.code'=>'Text','s.phone'=>'Text','s.siren'=>'Text','s.siret'=>'Text','s.ape'=>'Text','s.idprof4'=>'Text','s.code_compta'=>'Text','s.code_compta_fournisseur'=>'Text','s.tva_intra'=>'Text','f.rowid'=>"List:facture:facnumber",'f.facnumber'=>"Text",'f.datec'=>"Date",'f.datef'=>"Date",'f.date_lim_reglement'=>"Date",'f.total'=>"Number",'f.total_ttc'=>"Number",'f.tva'=>"Number",'f.paye'=>"Boolean",'f.fk_statut'=>'Status','f.note_private'=>"Text",'f.note_public'=>"Text",'pf.amount'=>'Number','p.datep'=>'Date','p.num_paiement'=>'Number');
|
||||||
$this->export_TypeFields_array[$r]=array('s.nom'=>'Text','s.address'=>'Text','s.zip'=>'Text','s.town'=>'Text','c.code'=>'Text','s.phone'=>'Text','s.siren'=>'Text','s.siret'=>'Text','s.ape'=>'Text','s.idprof4'=>'Text','s.code_compta'=>'Text','s.code_compta_fournisseur'=>'Text','s.tva_intra'=>'Text','f.rowid'=>"List:facture:facnumber",'f.facnumber'=>"Text",'f.datec'=>"Date",'f.datef'=>"Date",'f.date_lim_reglement'=>"Date",'f.total'=>"Number",'f.total_ttc'=>"Number",'f.tva'=>"Number",'f.paye'=>"Boolean",'f.fk_statut'=>'Status','f.note'=>"Text",'f.note_public'=>"Text",'pf.amount'=>'Number','p.datep'=>'Date','p.num_paiement'=>'Number');
|
$this->export_TypeFields_array[$r]=array('s.nom'=>'Text','s.address'=>'Text','s.zip'=>'Text','s.town'=>'Text','c.code'=>'Text','s.phone'=>'Text','s.siren'=>'Text','s.siret'=>'Text','s.ape'=>'Text','s.idprof4'=>'Text','s.code_compta'=>'Text','s.code_compta_fournisseur'=>'Text','s.tva_intra'=>'Text','f.rowid'=>"List:facture:facnumber",'f.facnumber'=>"Text",'f.datec'=>"Date",'f.datef'=>"Date",'f.date_lim_reglement'=>"Date",'f.total'=>"Number",'f.total_ttc'=>"Number",'f.tva'=>"Number",'f.paye'=>"Boolean",'f.fk_statut'=>'Status','f.note_private'=>"Text",'f.note_public'=>"Text",'pf.amount'=>'Number','p.datep'=>'Date','p.num_paiement'=>'Number');
|
||||||
$this->export_entities_array[$r]=array('s.rowid'=>"company",'s.nom'=>'company','s.address'=>'company','s.zip'=>'company','s.town'=>'company','c.code'=>'company','s.phone'=>'company','s.siren'=>'company','s.siret'=>'company','s.ape'=>'company','s.idprof4'=>'company','s.code_compta'=>'company','s.code_compta_fournisseur'=>'company','s.tva_intra'=>'company','f.rowid'=>"invoice",'f.facnumber'=>"invoice",'f.datec'=>"invoice",'f.datef'=>"invoice",'f.date_lim_reglement'=>"invoice",'f.total'=>"invoice",'f.total_ttc'=>"invoice",'f.tva'=>"invoice",'f.paye'=>"invoice",'f.fk_statut'=>'invoice','f.note'=>"invoice",'f.note_public'=>"invoice",'p.rowid'=>'payment','pf.amount'=>'payment','p.datep'=>'payment','p.num_paiement'=>'payment');
|
$this->export_entities_array[$r]=array('s.rowid'=>"company",'s.nom'=>'company','s.address'=>'company','s.zip'=>'company','s.town'=>'company','c.code'=>'company','s.phone'=>'company','s.siren'=>'company','s.siret'=>'company','s.ape'=>'company','s.idprof4'=>'company','s.code_compta'=>'company','s.code_compta_fournisseur'=>'company','s.tva_intra'=>'company','f.rowid'=>"invoice",'f.facnumber'=>"invoice",'f.datec'=>"invoice",'f.datef'=>"invoice",'f.date_lim_reglement'=>"invoice",'f.total'=>"invoice",'f.total_ttc'=>"invoice",'f.tva'=>"invoice",'f.paye'=>"invoice",'f.fk_statut'=>'invoice','f.note_private'=>"invoice",'f.note_public'=>"invoice",'p.rowid'=>'payment','pf.amount'=>'payment','p.datep'=>'payment','p.num_paiement'=>'payment');
|
||||||
$this->export_dependencies_array[$r]=array('payment'=>'p.rowid'); // To add unique key if we ask a field of a child to avoid the DISTINCT to discard them
|
$this->export_dependencies_array[$r]=array('payment'=>'p.rowid'); // To add unique key if we ask a field of a child to avoid the DISTINCT to discard them
|
||||||
|
|
||||||
$this->export_sql_start[$r]='SELECT DISTINCT ';
|
$this->export_sql_start[$r]='SELECT DISTINCT ';
|
||||||
|
|||||||
@ -109,7 +109,7 @@ class doc_generic_odt extends ModeleThirdPartyDoc
|
|||||||
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
|
if (! is_dir($tmpdir)) $texttitle.=img_warning($langs->trans("ErrorDirNotFound",$tmpdir),0);
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$tmpfiles=dol_dir_list($tmpdir,'files',0,'\.odt','','name',SORT_ASC,0,true); // Disable hook for the moment
|
$tmpfiles=dol_dir_list($tmpdir,'files',0,'\.od(s|t)$','','name',SORT_ASC,0,true); // Disable hook for the moment
|
||||||
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
|
if (count($tmpfiles)) $listoffiles=array_merge($listoffiles,$tmpfiles);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -210,16 +210,27 @@ class doc_generic_odt extends ModeleThirdPartyDoc
|
|||||||
{
|
{
|
||||||
//print "srctemplatepath=".$srctemplatepath; // Src filename
|
//print "srctemplatepath=".$srctemplatepath; // Src filename
|
||||||
$newfile=basename($srctemplatepath);
|
$newfile=basename($srctemplatepath);
|
||||||
$newfiletmp=preg_replace('/\.odt/i','',$newfile);
|
$newfiletmp=preg_replace('/\.od(s|t)/i','',$newfile);
|
||||||
$newfiletmp=preg_replace('/template_/i','',$newfiletmp);
|
$newfiletmp=preg_replace('/template_/i','',$newfiletmp);
|
||||||
$newfiletmp=preg_replace('/modele_/i','',$newfiletmp);
|
$newfiletmp=preg_replace('/modele_/i','',$newfiletmp);
|
||||||
$filename=$newfiletmp.'.'.dol_print_date(dol_now(),'%Y%m%d%H%M%S').'.odt';
|
// Get extension (ods or odt)
|
||||||
|
$newfileformat=substr($newfile, strrpos($newfile, '.')+1);
|
||||||
|
if ( ! empty($conf->global->MAIN_ODT_USE_TIMING))
|
||||||
|
{
|
||||||
|
$filename=$newfiletmp.'.'.dol_print_date(dol_now(),'%Y%m%d%H%M%S').'.'.$newfileformat;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$filename=$newfiletmp.'.'.$newfileformat;
|
||||||
|
}
|
||||||
$file=$dir.'/'.$filename;
|
$file=$dir.'/'.$filename;
|
||||||
$object->builddoc_filename=$filename; // For triggers
|
$object->builddoc_filename=$filename; // For triggers
|
||||||
|
//print "newfileformat=".$newfileformat;
|
||||||
//print "newdir=".$dir;
|
//print "newdir=".$dir;
|
||||||
//print "newfile=".$newfile;
|
//print "newfile=".$newfile;
|
||||||
//print "file=".$file;
|
//print "file=".$file;
|
||||||
//print "conf->societe->dir_temp=".$conf->societe->dir_temp;
|
//print "conf->societe->dir_temp=".$conf->societe->dir_temp;
|
||||||
|
//exit;
|
||||||
|
|
||||||
dol_mkdir($conf->societe->multidir_temp[$object->entity]);
|
dol_mkdir($conf->societe->multidir_temp[$object->entity]);
|
||||||
|
|
||||||
|
|||||||
@ -179,7 +179,7 @@ if ($forgetpasslink || $helpcenterlink)
|
|||||||
<?php if ($main_home)
|
<?php if ($main_home)
|
||||||
{
|
{
|
||||||
?>
|
?>
|
||||||
<center><div align="center" style="max-width: 80%">
|
<center><div align="center" class="login_main_home" style="max-width: 80%">
|
||||||
<?php echo $main_home; ?>
|
<?php echo $main_home; ?>
|
||||||
</div></center><br>
|
</div></center><br>
|
||||||
<?php
|
<?php
|
||||||
|
|||||||
@ -1,6 +1,7 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2006-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
/* Copyright (C) 2006-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2011 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2011 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
|
* Copyright (C) 2013 Marcos García <marcosgdf@gmail.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -35,7 +36,8 @@ class InterfaceNotification
|
|||||||
'PROPAL_VALIDATE',
|
'PROPAL_VALIDATE',
|
||||||
'FICHINTER_VALIDATE',
|
'FICHINTER_VALIDATE',
|
||||||
'ORDER_SUPPLIER_APPROVE',
|
'ORDER_SUPPLIER_APPROVE',
|
||||||
'ORDER_SUPPLIER_REFUSE'
|
'ORDER_SUPPLIER_REFUSE',
|
||||||
|
'SHIPPING_VALIDATE'
|
||||||
);
|
);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -196,6 +198,19 @@ class InterfaceNotification
|
|||||||
$notify = new Notify($this->db);
|
$notify = new Notify($this->db);
|
||||||
$notify->send($action, $object->socid, $mesg, 'order_supplier', $object->id, $filepdf);
|
$notify->send($action, $object->socid, $mesg, 'order_supplier', $object->id, $filepdf);
|
||||||
}
|
}
|
||||||
|
elseif ($action == 'SHIPPING_VALIDATE')
|
||||||
|
{
|
||||||
|
dol_syslog("Trigger '".$this->name."' for action '$action' launched by ".__FILE__.". id=".$object->id);
|
||||||
|
|
||||||
|
$ref = dol_sanitizeFileName($object->ref);
|
||||||
|
$filepdf = $conf->expedition->dir_output . '/sending/' . $ref . '/' . $ref . '.pdf';
|
||||||
|
if (! file_exists($filepdf)) $filepdf='';
|
||||||
|
$mesg = $langs->transnoentitiesnoconv("EMailTextExpeditionValidated",$object->ref);
|
||||||
|
|
||||||
|
|
||||||
|
$notify = new Notify($this->db);
|
||||||
|
$notify->send($action, $object->socid, $mesg, 'expedition', $object->id, $filepdf);
|
||||||
|
}
|
||||||
|
|
||||||
// If not found
|
// If not found
|
||||||
/*
|
/*
|
||||||
|
|||||||
@ -142,6 +142,7 @@ class EcmDirectory // extends CommonObject
|
|||||||
|
|
||||||
$dir=$conf->ecm->dir_output.'/'.$this->getRelativePath();
|
$dir=$conf->ecm->dir_output.'/'.$this->getRelativePath();
|
||||||
$result=dol_mkdir($dir);
|
$result=dol_mkdir($dir);
|
||||||
|
if ($result < 0) { $error++; $this->error="ErrorFailedToCreateDir"; }
|
||||||
|
|
||||||
// Appel des triggers
|
// Appel des triggers
|
||||||
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
|
||||||
|
|||||||
@ -118,6 +118,7 @@ if ($action == 'add' && $user->rights->ecm->setup)
|
|||||||
{
|
{
|
||||||
$langs->load("errors");
|
$langs->load("errors");
|
||||||
setEventMessage($langs->trans($ecmdir->error), 'errors');
|
setEventMessage($langs->trans($ecmdir->error), 'errors');
|
||||||
|
setEventMessage($ecmdir->errors, 'errors');
|
||||||
$action = 'create';
|
$action = 'create';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -5,6 +5,7 @@
|
|||||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2011-2012 Juanjo Menent <jmenent@2byte.es>
|
* Copyright (C) 2011-2012 Juanjo Menent <jmenent@2byte.es>
|
||||||
* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro>
|
* Copyright (C) 2013 Florian Henry <florian.henry@open-concept.pro>
|
||||||
|
* Copyright (C) 2013 Marcos García <marcosgdf@gmail.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -974,7 +975,18 @@ else
|
|||||||
{
|
{
|
||||||
$numref = $object->ref;
|
$numref = $object->ref;
|
||||||
}
|
}
|
||||||
$ret=$form->form_confirm($_SERVER['PHP_SELF'].'?id='.$object->id,$langs->trans('ValidateSending'),$langs->trans("ConfirmValidateSending",$numref),'confirm_valid','',0,1);
|
|
||||||
|
$text = $langs->trans("ConfirmValidateSending",$numref);
|
||||||
|
|
||||||
|
if (! empty($conf->notification->enabled))
|
||||||
|
{
|
||||||
|
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
||||||
|
$notify=new Notify($db);
|
||||||
|
$text.='<br>';
|
||||||
|
$text.=$notify->confirmMessage('SHIPPING_VALIDATE',$object->socid);
|
||||||
|
}
|
||||||
|
|
||||||
|
$ret=$form->form_confirm($_SERVER['PHP_SELF'].'?id='.$object->id,$langs->trans('ValidateSending'),$text,'confirm_valid','',0,1);
|
||||||
if ($ret == 'html') print '<br>';
|
if ($ret == 'html') print '<br>';
|
||||||
}
|
}
|
||||||
/*
|
/*
|
||||||
|
|||||||
@ -25,12 +25,12 @@
|
|||||||
|
|
||||||
require '../main.inc.php';
|
require '../main.inc.php';
|
||||||
|
|
||||||
$langs->load("externalsite@externalsite");
|
$langs->load("externalsite");
|
||||||
|
|
||||||
if (empty($conf->global->EXTERNALSITE_URL))
|
if (empty($conf->global->EXTERNALSITE_URL))
|
||||||
{
|
{
|
||||||
llxHeader();
|
llxHeader();
|
||||||
print '<div class="error">Module ExternalSite was not configured properly.</div>';
|
print '<div class="error">'.$langs->trans('ExternalSiteModuleNotComplete').'</div>';
|
||||||
llxFooter();
|
llxFooter();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
require ("../main.inc.php");
|
require ("../main.inc.php");
|
||||||
|
|
||||||
$langs->load("@externalsite");
|
$langs->load("externalsite");
|
||||||
|
|
||||||
top_htmlhead("","");
|
top_htmlhead("","");
|
||||||
top_menu("","","_top");
|
top_menu("","","_top");
|
||||||
|
|||||||
@ -1077,7 +1077,7 @@ elseif (! empty($object->id))
|
|||||||
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
||||||
$notify=new Notify($db);
|
$notify=new Notify($db);
|
||||||
$text.='<br>';
|
$text.='<br>';
|
||||||
$text.=$notify->confirmMessage(3,$object->socid);
|
$text.=$notify->confirmMessage('ORDER_SUPPLIER_APPROVE', $object->socid);
|
||||||
}
|
}
|
||||||
|
|
||||||
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ValidateOrder'), $text, 'confirm_valid', '', 0, 1);
|
$ret=$form->form_confirm($_SERVER["PHP_SELF"].'?id='.$object->id, $langs->trans('ValidateOrder'), $text, 'confirm_valid', '', 0, 1);
|
||||||
|
|||||||
@ -1347,7 +1347,7 @@ else
|
|||||||
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
require_once DOL_DOCUMENT_ROOT .'/core/class/notify.class.php';
|
||||||
$notify=new Notify($db);
|
$notify=new Notify($db);
|
||||||
$text.='<br>';
|
$text.='<br>';
|
||||||
$text.=$notify->confirmMessage('NOTIFY_VAL_FAC_SUP',$object->socid);
|
$text.=$notify->confirmMessage('BILL_SUPPLIER_VALIDATE',$object->socid);
|
||||||
}*/
|
}*/
|
||||||
$formquestion=array();
|
$formquestion=array();
|
||||||
|
|
||||||
|
|||||||
@ -85,8 +85,9 @@ if ($object->fetch($id))
|
|||||||
dol_fiche_head($head, 'supplier', $langs->trans("ThirdParty"),0,'company');
|
dol_fiche_head($head, 'supplier', $langs->trans("ThirdParty"),0,'company');
|
||||||
|
|
||||||
|
|
||||||
print '<table width="100%" class="notopnoleftnoright">';
|
print '<div class="fichecenter"><div class="fichehalfleft">';
|
||||||
print '<tr><td valign="top" width="50%" class="notopnoleft">';
|
//print '<table width="100%" class="notopnoleftnoright">';
|
||||||
|
//print '<tr><td valign="top" width="50%" class="notopnoleft">';
|
||||||
|
|
||||||
print '<table width="100%" class="border">';
|
print '<table width="100%" class="border">';
|
||||||
print '<tr><td width="20%">'.$langs->trans("ThirdPartyName").'</td><td width="80%" colspan="3">';
|
print '<tr><td width="20%">'.$langs->trans("ThirdPartyName").'</td><td width="80%" colspan="3">';
|
||||||
@ -216,7 +217,11 @@ if ($object->fetch($id))
|
|||||||
|
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
print '</td><td valign="top" width="50%" class="notopnoleftnoright">';
|
|
||||||
|
print '</div><div class="fichehalfright"><div class="ficheaddleft">';
|
||||||
|
//print '</td><td valign="top" width="50%" class="notopnoleftnoright">';
|
||||||
|
|
||||||
|
|
||||||
$var=true;
|
$var=true;
|
||||||
|
|
||||||
$MAXLIST=5;
|
$MAXLIST=5;
|
||||||
@ -367,9 +372,12 @@ if ($object->fetch($id))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
print '</td></tr>';
|
print '</div></div></div>';
|
||||||
print '</table>' . "\n";
|
print '<div style="clear:both"></div>';
|
||||||
print '</div>';
|
//print '</td></tr>';
|
||||||
|
//print '</table>' . "\n";
|
||||||
|
|
||||||
|
dol_fiche_end();
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2011 Dimitri Mouillard <dmouillard@teclib.com>
|
/* Copyright (C) 2011 Dimitri Mouillard <dmouillard@teclib.com>
|
||||||
* Copyright (C) 2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2012 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
@ -228,7 +228,6 @@ if ($id > 0)
|
|||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
print '</table><br>';
|
print '</table><br>';
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -242,7 +241,15 @@ $nbaquis=$holiday->getCPforUser($user_id);
|
|||||||
$nbdeduced=$holiday->getConfCP('nbHolidayDeducted');
|
$nbdeduced=$holiday->getConfCP('nbHolidayDeducted');
|
||||||
$nb_holiday = $nbaquis / $nbdeduced;
|
$nb_holiday = $nbaquis / $nbdeduced;
|
||||||
print $langs->trans('SoldeCPUser',round($nb_holiday,2)).($nbdeduced != 1 ? ' ('.$nbaquis.' / '.$nbdeduced.')' : '');
|
print $langs->trans('SoldeCPUser',round($nb_holiday,2)).($nbdeduced != 1 ? ' ('.$nbaquis.' / '.$nbdeduced.')' : '');
|
||||||
|
|
||||||
|
if ($id > 0)
|
||||||
|
{
|
||||||
|
dol_fiche_end();
|
||||||
|
print '</br>';
|
||||||
|
}
|
||||||
|
else {
|
||||||
print '</div>';
|
print '</div>';
|
||||||
|
}
|
||||||
|
|
||||||
print '<form method="get" action="'.$_SERVER["PHP_SELF"].'">'."\n";
|
print '<form method="get" action="'.$_SERVER["PHP_SELF"].'">'."\n";
|
||||||
print '<table class="noborder" width="100%;">';
|
print '<table class="noborder" width="100%;">';
|
||||||
|
|||||||
BIN
htdocs/install/doctemplates/thirdparties/template_thirdparty.ods
Normal file
BIN
htdocs/install/doctemplates/thirdparties/template_thirdparty.ods
Normal file
Binary file not shown.
@ -458,7 +458,7 @@ if (! $error && $db->connected && $action == "set")
|
|||||||
print '<tr><td>';
|
print '<tr><td>';
|
||||||
print $langs->trans("ConfFileReload");
|
print $langs->trans("ConfFileReload");
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td>'.$langs->trans("OK").'</td></tr>';
|
print '<td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
|
|
||||||
|
|
||||||
$userroot=isset($_POST["db_user_root"])?$_POST["db_user_root"]:"";
|
$userroot=isset($_POST["db_user_root"])?$_POST["db_user_root"]:"";
|
||||||
@ -508,7 +508,7 @@ if (! $error && $db->connected && $action == "set")
|
|||||||
print $langs->trans("UserCreation").' : ';
|
print $langs->trans("UserCreation").' : ';
|
||||||
print $dolibarr_main_db_user;
|
print $dolibarr_main_db_user;
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td>'.$langs->trans("OK").'</td></tr>';
|
print '<td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -542,7 +542,7 @@ if (! $error && $db->connected && $action == "set")
|
|||||||
print $langs->trans("UserCreation").' : ';
|
print $langs->trans("UserCreation").' : ';
|
||||||
print $dolibarr_main_db_user;
|
print $dolibarr_main_db_user;
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td>'.$langs->trans("Error").'</td>';
|
print '<td><img src="../theme/eldy/img/error.png" alt="Error"></td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
// Affiche aide diagnostique
|
// Affiche aide diagnostique
|
||||||
@ -576,7 +576,7 @@ if (! $error && $db->connected && $action == "set")
|
|||||||
print $langs->trans("DatabaseCreation")." (".$langs->trans("User")." ".$userroot.") : ";
|
print $langs->trans("DatabaseCreation")." (".$langs->trans("User")." ".$userroot.") : ";
|
||||||
print $dolibarr_main_db_name;
|
print $dolibarr_main_db_name;
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print "<td>".$langs->trans("OK")."</td></tr>";
|
print '<td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
|
|
||||||
$check1=$newdb->getDefaultCharacterSetDatabase();
|
$check1=$newdb->getDefaultCharacterSetDatabase();
|
||||||
$check2=$newdb->getDefaultCollationDatabase();
|
$check2=$newdb->getDefaultCollationDatabase();
|
||||||
@ -606,7 +606,7 @@ if (! $error && $db->connected && $action == "set")
|
|||||||
print $langs->trans("DatabaseCreation")." (".$langs->trans("User")." ".$userroot.") : ";
|
print $langs->trans("DatabaseCreation")." (".$langs->trans("User")." ".$userroot.") : ";
|
||||||
print $dolibarr_main_db_name;
|
print $dolibarr_main_db_name;
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td>'.$langs->trans("Error").'</td>';
|
print '<td><img src="../theme/eldy/img/error.png" alt="Error"></td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
// Affiche aide diagnostique
|
// Affiche aide diagnostique
|
||||||
@ -631,44 +631,36 @@ if (! $error && $db->connected && $action == "set")
|
|||||||
$db=getDoliDBInstance($conf->db->type,$conf->db->host,$conf->db->user,$conf->db->pass,$conf->db->name,$conf->db->port);
|
$db=getDoliDBInstance($conf->db->type,$conf->db->host,$conf->db->user,$conf->db->pass,$conf->db->name,$conf->db->port);
|
||||||
|
|
||||||
if ($db->connected == 1)
|
if ($db->connected == 1)
|
||||||
{
|
|
||||||
// si acces serveur ok et acces base ok, tout est ok, on ne va pas plus loin, on a meme pas utilise le compte root.
|
|
||||||
if ($db->database_selected == 1)
|
|
||||||
{
|
{
|
||||||
dolibarr_install_syslog("etape1: connexion to server by user ".$conf->db->user." is ok", LOG_DEBUG);
|
dolibarr_install_syslog("etape1: connexion to server by user ".$conf->db->user." is ok", LOG_DEBUG);
|
||||||
print "<tr><td>";
|
print "<tr><td>";
|
||||||
print $langs->trans("ServerConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
print $langs->trans("ServerConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
||||||
print $dolibarr_main_db_host;
|
print $dolibarr_main_db_host;
|
||||||
print "</td><td>";
|
print "</td><td>";
|
||||||
print $langs->trans("OK");
|
print '<img src="../theme/eldy/img/tick.png" alt="Ok">';
|
||||||
print "</td></tr>";
|
print "</td></tr>";
|
||||||
|
|
||||||
|
// si acces serveur ok et acces base ok, tout est ok, on ne va pas plus loin, on a meme pas utilise le compte root.
|
||||||
|
if ($db->database_selected == 1)
|
||||||
|
{
|
||||||
dolibarr_install_syslog("etape1: connexion to database : ".$conf->db->name.", by user : ".$conf->db->user." is ok", LOG_DEBUG);
|
dolibarr_install_syslog("etape1: connexion to database : ".$conf->db->name.", by user : ".$conf->db->user." is ok", LOG_DEBUG);
|
||||||
print "<tr><td>";
|
print "<tr><td>";
|
||||||
print $langs->trans("DatabaseConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
print $langs->trans("DatabaseConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
||||||
print $dolibarr_main_db_name;
|
print $dolibarr_main_db_name;
|
||||||
print "</td><td>";
|
print "</td><td>";
|
||||||
print $langs->trans("OK");
|
print '<img src="../theme/eldy/img/tick.png" alt="Ok">';
|
||||||
print "</td></tr>";
|
print "</td></tr>";
|
||||||
|
|
||||||
$error = 0;
|
$error = 0;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
dolibarr_install_syslog("etape1: connexion to server by user ".$conf->db->user." is ok", LOG_DEBUG);
|
|
||||||
print "<tr><td>";
|
|
||||||
print $langs->trans("ServerConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
|
||||||
print $dolibarr_main_db_host;
|
|
||||||
print "</td><td>";
|
|
||||||
print $langs->trans("OK");
|
|
||||||
print "</td></tr>";
|
|
||||||
|
|
||||||
dolibarr_install_syslog("etape1: connexion to database ".$conf->db->name.", by user : ".$conf->db->user." has failed", LOG_ERR);
|
dolibarr_install_syslog("etape1: connexion to database ".$conf->db->name.", by user : ".$conf->db->user." has failed", LOG_ERR);
|
||||||
print "<tr><td>";
|
print "<tr><td>";
|
||||||
print $langs->trans("DatabaseConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
print $langs->trans("DatabaseConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
||||||
print $dolibarr_main_db_name;
|
print $dolibarr_main_db_name;
|
||||||
print '</td><td>';
|
print '</td><td>';
|
||||||
print $langs->trans("Error");
|
print '<img src="../theme/eldy/img/error.png" alt="Error">';
|
||||||
print "</td></tr>";
|
print "</td></tr>";
|
||||||
|
|
||||||
// Affiche aide diagnostique
|
// Affiche aide diagnostique
|
||||||
@ -688,7 +680,7 @@ if (! $error && $db->connected && $action == "set")
|
|||||||
print $langs->trans("ServerConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
print $langs->trans("ServerConnection")." (".$langs->trans("User")." ".$conf->db->user.") : ";
|
||||||
print $dolibarr_main_db_host;
|
print $dolibarr_main_db_host;
|
||||||
print '</td><td>';
|
print '</td><td>';
|
||||||
print '<font class="error">'.$db->error.'</div>';
|
print '<img src="../theme/eldy/img/error.png" alt="Error">';
|
||||||
print "</td></tr>";
|
print "</td></tr>";
|
||||||
|
|
||||||
// Affiche aide diagnostique
|
// Affiche aide diagnostique
|
||||||
@ -938,7 +930,7 @@ function write_conf_file($conffile)
|
|||||||
print $langs->trans("SaveConfigurationFile");
|
print $langs->trans("SaveConfigurationFile");
|
||||||
print ' <strong>'.$conffile.'</strong>';
|
print ' <strong>'.$conffile.'</strong>';
|
||||||
print "</td><td>";
|
print "</td><td>";
|
||||||
print $langs->trans("OK");
|
print '<img src="../theme/eldy/img/tick.png" alt="Ok">';
|
||||||
print "</td></tr>";
|
print "</td></tr>";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
@ -87,12 +87,12 @@ if ($action == "set")
|
|||||||
if ($db->connected == 1)
|
if ($db->connected == 1)
|
||||||
{
|
{
|
||||||
print "<tr><td>";
|
print "<tr><td>";
|
||||||
print $langs->trans("ServerConnection")." : ".$conf->db->host."</td><td>".$langs->trans("OK")."</td></tr>";
|
print $langs->trans("ServerConnection")." : ".$conf->db->host.'</td><td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
$ok = 1 ;
|
$ok = 1 ;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print "<tr><td>Failed to connect to server : ".$conf->db->host."</td><td>".$langs->trans("Error")."</td></tr>";
|
print "<tr><td>Failed to connect to server : ".$conf->db->host.'</td><td><img src="../theme/eldy/img/error.png" alt="Error"></td></tr>';
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($ok)
|
if ($ok)
|
||||||
@ -104,7 +104,7 @@ if ($action == "set")
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
dolibarr_install_syslog("etape2: Connexion failed to database : ".$conf->db->name);
|
dolibarr_install_syslog("etape2: Connexion failed to database : ".$conf->db->name);
|
||||||
print "<tr><td>Failed to select database ".$conf->db->name."</td><td>".$langs->trans("Error")."</td></tr>";
|
print "<tr><td>Failed to select database ".$conf->db->name.'</td><td><img src="../theme/eldy/img/error.png" alt="Error"></td></tr>';
|
||||||
$ok = 0 ;
|
$ok = 0 ;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -241,13 +241,13 @@ if ($action == "set")
|
|||||||
if ($error == 0)
|
if ($error == 0)
|
||||||
{
|
{
|
||||||
print '<tr><td>';
|
print '<tr><td>';
|
||||||
print $langs->trans("TablesAndPrimaryKeysCreation").'</td><td>'.$langs->trans("OK").'</td></tr>';
|
print $langs->trans("TablesAndPrimaryKeysCreation").'</td><td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
$ok = 1;
|
$ok = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print '<tr><td>'.$langs->trans("ErrorFailedToFindSomeFiles",$dir).'</td><td><font class="error">'.$langs->trans("Error").'</font></td></tr>';
|
print '<tr><td>'.$langs->trans("ErrorFailedToFindSomeFiles",$dir).'</td><td><img src="../theme/eldy/img/error.png" alt="Error"></td></tr>';
|
||||||
dolibarr_install_syslog("Failed to find files to create database in directory ".$dir,LOG_ERR);
|
dolibarr_install_syslog("Failed to find files to create database in directory ".$dir,LOG_ERR);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -388,7 +388,7 @@ if ($action == "set")
|
|||||||
if ($tablefound && $error == 0)
|
if ($tablefound && $error == 0)
|
||||||
{
|
{
|
||||||
print '<tr><td>';
|
print '<tr><td>';
|
||||||
print $langs->trans("OtherKeysCreation").'</td><td>'.$langs->trans("OK").'</td></tr>';
|
print $langs->trans("OtherKeysCreation").'</td><td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
$okkeys = 1;
|
$okkeys = 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -466,11 +466,11 @@ if ($action == "set")
|
|||||||
print "<tr><td>".$langs->trans("FunctionsCreation")."</td>";
|
print "<tr><td>".$langs->trans("FunctionsCreation")."</td>";
|
||||||
if ($ok)
|
if ($ok)
|
||||||
{
|
{
|
||||||
print "<td>".$langs->trans("OK")."</td></tr>";
|
print '<td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print '<td><font class="error">'.$langs->trans("Error").'</font></td></tr>';
|
print '<td><img src="../theme/eldy/img/error.png" alt="Error"></td></tr>';
|
||||||
$ok = 1 ;
|
$ok = 1 ;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -588,11 +588,11 @@ if ($action == "set")
|
|||||||
print "<tr><td>".$langs->trans("ReferenceDataLoading")."</td>";
|
print "<tr><td>".$langs->trans("ReferenceDataLoading")."</td>";
|
||||||
if ($ok)
|
if ($ok)
|
||||||
{
|
{
|
||||||
print "<td>".$langs->trans("OK")."</td></tr>";
|
print '<td><img src="../theme/eldy/img/tick.png" alt="Ok"></td></tr>';
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
print '<td><font class="error">'.$langs->trans("Error").'</font></td></tr>';
|
print '<td><img src="../theme/eldy/img/error.png" alt="Error"></td></tr>';
|
||||||
$ok = 1; // Data loading are not blocking errors
|
$ok = 1; // Data loading are not blocking errors
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -46,6 +46,8 @@ ErrorModuleRequireDolibarrVersion=Error, this module requires Dolibarr version %
|
|||||||
ErrorDecimalLargerThanAreForbidden=Error, a precision higher than <b>%s</b> is not supported.
|
ErrorDecimalLargerThanAreForbidden=Error, a precision higher than <b>%s</b> is not supported.
|
||||||
DictionnarySetup=Dictionary setup
|
DictionnarySetup=Dictionary setup
|
||||||
Dictionnary=Dictionaries
|
Dictionnary=Dictionaries
|
||||||
|
ErrorReservedTypeSystemSystemAuto=Value 'system' and 'systemauto' for type is reserved. You can use 'user' as value to add your own record
|
||||||
|
ErrorCodeCantContainZero=Code can't contain value 0
|
||||||
DisableJavascript=Disable JavaScript and Ajax functions
|
DisableJavascript=Disable JavaScript and Ajax functions
|
||||||
ConfirmAjax=Use Ajax confirmation popups
|
ConfirmAjax=Use Ajax confirmation popups
|
||||||
UseSearchToSelectCompany=Use autocompletion fields to choose third parties (instead of using a list box).<br><br>Also if you have a large number of third parties (> 100 000), you can increase speed by setting constant SOCIETE_DONOTSEARCH_ANYWHERE to 1 in Setup->Other. Search will then be limited to start of string.
|
UseSearchToSelectCompany=Use autocompletion fields to choose third parties (instead of using a list box).<br><br>Also if you have a large number of third parties (> 100 000), you can increase speed by setting constant SOCIETE_DONOTSEARCH_ANYWHERE to 1 in Setup->Other. Search will then be limited to start of string.
|
||||||
@ -546,6 +548,7 @@ Permission98=Dispatch invoice accountancy lines
|
|||||||
Permission101=Read sendings
|
Permission101=Read sendings
|
||||||
Permission102=Create/modify sendings
|
Permission102=Create/modify sendings
|
||||||
Permission104=Validate sendings
|
Permission104=Validate sendings
|
||||||
|
Permission106=Export sendings
|
||||||
Permission109=Delete sendings
|
Permission109=Delete sendings
|
||||||
Permission111=Read financial accounts
|
Permission111=Read financial accounts
|
||||||
Permission112=Create/modify/delete and compare transactions
|
Permission112=Create/modify/delete and compare transactions
|
||||||
|
|||||||
@ -32,7 +32,7 @@ ViewCal=Month view
|
|||||||
ViewDay=Day view
|
ViewDay=Day view
|
||||||
ViewWeek=Week view
|
ViewWeek=Week view
|
||||||
ViewWithPredefinedFilters= View with predefined filters
|
ViewWithPredefinedFilters= View with predefined filters
|
||||||
AutoActions= Automatic filling of agenda
|
AutoActions= Automatic filling
|
||||||
AgendaAutoActionDesc= Define here events for which you want Dolibarr to create automatically an event in agenda. If nothing is checked (by default), only manual actions will be included in agenda.
|
AgendaAutoActionDesc= Define here events for which you want Dolibarr to create automatically an event in agenda. If nothing is checked (by default), only manual actions will be included in agenda.
|
||||||
AgendaSetupOtherDesc= This page provides options to allow export of your Dolibarr events into an external calendar (thunderbird, google calendar, ...)
|
AgendaSetupOtherDesc= This page provides options to allow export of your Dolibarr events into an external calendar (thunderbird, google calendar, ...)
|
||||||
AgendaExtSitesDesc=This page allows to declare external sources of calendars to see their events into Dolibarr agenda.
|
AgendaExtSitesDesc=This page allows to declare external sources of calendars to see their events into Dolibarr agenda.
|
||||||
|
|||||||
@ -81,6 +81,7 @@ ActionAC_SHIP=Send shipping by mail
|
|||||||
ActionAC_SUP_ORD=Send supplier order by mail
|
ActionAC_SUP_ORD=Send supplier order by mail
|
||||||
ActionAC_SUP_INV=Send supplier invoice by mail
|
ActionAC_SUP_INV=Send supplier invoice by mail
|
||||||
ActionAC_OTH=Other
|
ActionAC_OTH=Other
|
||||||
|
ActionAC_OTH_AUTO=Other (automatically inserted events)
|
||||||
ActionAC_MANUAL=Manually inserted events
|
ActionAC_MANUAL=Manually inserted events
|
||||||
ActionAC_AUTO=Automatically inserted events
|
ActionAC_AUTO=Automatically inserted events
|
||||||
Stats=Sales statistics
|
Stats=Sales statistics
|
||||||
|
|||||||
@ -153,3 +153,4 @@ Pcg_subtype=Pcg subtype
|
|||||||
InvoiceLinesToDispatch=Invoice lines to dispatch
|
InvoiceLinesToDispatch=Invoice lines to dispatch
|
||||||
InvoiceDispatched=Dispatched invoices
|
InvoiceDispatched=Dispatched invoices
|
||||||
AccountancyDashboard=Accountancy summary
|
AccountancyDashboard=Accountancy summary
|
||||||
|
ByProductsAndServices=By products and services
|
||||||
|
|||||||
@ -137,3 +137,4 @@ WarningUntilDirRemoved=All security warnings (visible by admin users only) will
|
|||||||
WarningCloseAlways=Warning, closing is done even if amount differs between source and target elements. Enable this feature with caution.
|
WarningCloseAlways=Warning, closing is done even if amount differs between source and target elements. Enable this feature with caution.
|
||||||
WarningUsingThisBoxSlowDown=Warning, using this box slow down seriously all pages showing the box.
|
WarningUsingThisBoxSlowDown=Warning, using this box slow down seriously all pages showing the box.
|
||||||
WarningClickToDialUserSetupNotComplete=Setup of ClickToDial information for your user are not complete (see tab ClickToDial onto your user card).
|
WarningClickToDialUserSetupNotComplete=Setup of ClickToDial information for your user are not complete (see tab ClickToDial onto your user card).
|
||||||
|
WarningNotRelevant=Irrelevant operation for this dataset
|
||||||
|
|||||||
@ -2,3 +2,4 @@
|
|||||||
CHARSET=UTF-8
|
CHARSET=UTF-8
|
||||||
ExternalSiteSetup=Setup link to external website
|
ExternalSiteSetup=Setup link to external website
|
||||||
ExternalSiteURL=External Site URL
|
ExternalSiteURL=External Site URL
|
||||||
|
ExternalSiteModuleNotComplete=Module ExternalSite was not configured properly.
|
||||||
@ -132,4 +132,9 @@ NoCPforMonth=No leave this month.
|
|||||||
Jours=days
|
Jours=days
|
||||||
nbJours=Number days
|
nbJours=Number days
|
||||||
TitleAdminCP=Configuration of Holidays
|
TitleAdminCP=Configuration of Holidays
|
||||||
Permission20001=Read / Modify all requests of holidays
|
Permission20001=Read/create/modify their holidays
|
||||||
|
Permission20002=Read/modify all requests of holidays
|
||||||
|
Permission20003=Delete their holidays requests
|
||||||
|
Permission20004=Define users holidays
|
||||||
|
Permission20005=Review log of modified holidays
|
||||||
|
Permission20006=Access holidays monthly report
|
||||||
|
|||||||
@ -152,6 +152,7 @@ EMailTextOrderApproved=The order %s has been approved.
|
|||||||
EMailTextOrderApprovedBy=The order %s has been approved by %s.
|
EMailTextOrderApprovedBy=The order %s has been approved by %s.
|
||||||
EMailTextOrderRefused=The order %s has been refused.
|
EMailTextOrderRefused=The order %s has been refused.
|
||||||
EMailTextOrderRefusedBy=The order %s has been refused by %s.
|
EMailTextOrderRefusedBy=The order %s has been refused by %s.
|
||||||
|
EMailTextExpeditionValidated=The shipping %s has been validated.
|
||||||
ImportedWithSet=Importation data set
|
ImportedWithSet=Importation data set
|
||||||
DolibarrNotification=Automatic notification
|
DolibarrNotification=Automatic notification
|
||||||
ResizeDesc=Enter new width <b>OR</b> new height. Ratio will be kept during resizing...
|
ResizeDesc=Enter new width <b>OR</b> new height. Ratio will be kept during resizing...
|
||||||
|
|||||||
@ -111,10 +111,12 @@ ServiceLimitedDuration=If product is a service with limited duration:
|
|||||||
MultiPricesAbility=Activate the multi-prices
|
MultiPricesAbility=Activate the multi-prices
|
||||||
MultiPricesNumPrices=Number of price
|
MultiPricesNumPrices=Number of price
|
||||||
MultiPriceLevelsName=Price categories
|
MultiPriceLevelsName=Price categories
|
||||||
AssociatedProductsAbility=Activate the sub-products
|
AssociatedProductsAbility=Activate the virtual products feature
|
||||||
AssociatedProducts=Sub-products
|
AssociatedProducts=Virtual product
|
||||||
AssociatedProductsNumber=Number of products composing this product
|
AssociatedProductsNumber=Number of products composing this virtual product
|
||||||
ParentProductsNumber=Number of parent product
|
ParentProductsNumber=Number of parent virtual product
|
||||||
|
IfZeroItIsNotAVirtualProduct=If 0, this product is not a virtual product
|
||||||
|
IfZeroItIsNotUsedByVirtualProduct=If 0, this product is not used by any virtual product
|
||||||
EditAssociate=Associate
|
EditAssociate=Associate
|
||||||
Translation=Translation
|
Translation=Translation
|
||||||
KeywordFilter=Keyword filter
|
KeywordFilter=Keyword filter
|
||||||
@ -124,7 +126,7 @@ AddDel=Add/Delete
|
|||||||
Quantity=Quantity
|
Quantity=Quantity
|
||||||
NoMatchFound=No match found
|
NoMatchFound=No match found
|
||||||
ProductAssociationList=List of related products/services: name of product/service (quantity affected)
|
ProductAssociationList=List of related products/services: name of product/service (quantity affected)
|
||||||
ProductParentList=List of products/services with this product as a component
|
ProductParentList=List of virtual products/services with this product as a component
|
||||||
ErrorAssociationIsFatherOfThis=One of selected product is parent with current product
|
ErrorAssociationIsFatherOfThis=One of selected product is parent with current product
|
||||||
DeleteProduct=Delete a product/service
|
DeleteProduct=Delete a product/service
|
||||||
ConfirmDeleteProduct=Are you sure you want to delete this product/service?
|
ConfirmDeleteProduct=Are you sure you want to delete this product/service?
|
||||||
@ -185,3 +187,13 @@ AlwaysUseFixedPrice=Use the fixed price
|
|||||||
PriceByQuantity=Price by quantity
|
PriceByQuantity=Price by quantity
|
||||||
PriceByQuantityRange=Quantity range
|
PriceByQuantityRange=Quantity range
|
||||||
ProductsDashboard=Products/Services summary
|
ProductsDashboard=Products/Services summary
|
||||||
|
### composition fabrication
|
||||||
|
Building=Production and items dispatchment
|
||||||
|
Build=Produce
|
||||||
|
BuildIt=Produce & Dispatch
|
||||||
|
BuildindListInfo=Available quantity for production per warehouse (set it to 0 for no further action)
|
||||||
|
QtyNeed=Qty
|
||||||
|
UnitPmp=Net unit VWAP
|
||||||
|
CostPmpHT=Net total VWAP
|
||||||
|
ProductUsedForBuild=Auto consumed by production
|
||||||
|
ProductBuilded=Production completed
|
||||||
|
|||||||
@ -45,6 +45,8 @@ ErrorModuleRequireDolibarrVersion=Error, este módulo requiere una versión %s o
|
|||||||
ErrorDecimalLargerThanAreForbidden=Error, las precisiones superiores a <b>%s</b> no están soportadas.
|
ErrorDecimalLargerThanAreForbidden=Error, las precisiones superiores a <b>%s</b> no están soportadas.
|
||||||
DictionnarySetup=Diccionarios
|
DictionnarySetup=Diccionarios
|
||||||
Dictionnary=Diccionarios
|
Dictionnary=Diccionarios
|
||||||
|
ErrorReservedTypeSystemSystemAuto=El uso del tipo 'system' y 'systemauto' está reservado. Puede utilizar 'user' como valor para añadir su propio registro
|
||||||
|
ErrorCodeCantContainZero=El código no puede contener el valor 0
|
||||||
DisableJavascript=Desactivar las funciones Javascript
|
DisableJavascript=Desactivar las funciones Javascript
|
||||||
ConfirmAjax=Utilizar los popups de confirmación Ajax
|
ConfirmAjax=Utilizar los popups de confirmación Ajax
|
||||||
UseSearchToSelectCompany=Utilizar un formulario de búsqueda para buscar terceros (en vez de lista desplegable)<br><br>Tenga en cuenta que si tiene un gran número de productos o servicios (>100 000), puede mejorar el rendimiento mediante la constante SOCIETE_DONOTSEARCH_ANYWHERE a 1 en Configuración->Varios. La búsqueda se limitará entonces al inicio de la cadena.
|
UseSearchToSelectCompany=Utilizar un formulario de búsqueda para buscar terceros (en vez de lista desplegable)<br><br>Tenga en cuenta que si tiene un gran número de productos o servicios (>100 000), puede mejorar el rendimiento mediante la constante SOCIETE_DONOTSEARCH_ANYWHERE a 1 en Configuración->Varios. La búsqueda se limitará entonces al inicio de la cadena.
|
||||||
@ -290,7 +292,7 @@ ServerNotAvailableOnIPOrPort=Servidor no disponible en la dirección <b>%s</b> e
|
|||||||
DoTestServerAvailability=Probar conectividad con el servidor
|
DoTestServerAvailability=Probar conectividad con el servidor
|
||||||
DoTestSend=Probar envío
|
DoTestSend=Probar envío
|
||||||
DoTestSendHTML=Probar envío HTML
|
DoTestSendHTML=Probar envío HTML
|
||||||
ErrorCantUseRazInStartedYearIfNoYearMonthInMask=Error, no se puede usar opción @ si la secuencia {yy}{mm} o {yyyy}{mm} no se encuentra en la máscara.
|
ErrorCantUseRazInStartedYearIfNoYearMonthInMask=Error, no se puede usar la opción @ si la secuencia {yy}{mm} o {yyyy}{mm} no se encuentra en la máscara.
|
||||||
UMask=Parámetro UMask de nuevos archivos en Unix/Linux/BSD.
|
UMask=Parámetro UMask de nuevos archivos en Unix/Linux/BSD.
|
||||||
UMaskExplanation=Este parámetro determina los derechos de los archivos creados en el servidor Dolibarr (durante la subida, por ejemplo).<br>Este debe ser el valor octal (por ejemplo, 0666 significa lectura / escritura para todos).<br>Este parámetro no tiene ningún efecto sobre un servidor Windows.
|
UMaskExplanation=Este parámetro determina los derechos de los archivos creados en el servidor Dolibarr (durante la subida, por ejemplo).<br>Este debe ser el valor octal (por ejemplo, 0666 significa lectura / escritura para todos).<br>Este parámetro no tiene ningún efecto sobre un servidor Windows.
|
||||||
SeeWikiForAllTeam=Vea el wiki para más detalles de todos los actores y de su organización
|
SeeWikiForAllTeam=Vea el wiki para más detalles de todos los actores y de su organización
|
||||||
@ -481,6 +483,8 @@ Module2900Name=GeoIPMaxmind
|
|||||||
Module2900Desc=Capacidades de conversión GeoIP Maxmind
|
Module2900Desc=Capacidades de conversión GeoIP Maxmind
|
||||||
Module5000Name=Multi-empresa
|
Module5000Name=Multi-empresa
|
||||||
Module5000Desc=Permite gestionar varias empresas
|
Module5000Desc=Permite gestionar varias empresas
|
||||||
|
Module6000Name=Workflow
|
||||||
|
Module6000Desc=Gestión de flujos de trabajo
|
||||||
Module20000Name=Días libres
|
Module20000Name=Días libres
|
||||||
Module20000Desc=Gestión de los días libres de los empleados
|
Module20000Desc=Gestión de los días libres de los empleados
|
||||||
Module50000Name=PayBox
|
Module50000Name=PayBox
|
||||||
@ -544,6 +548,7 @@ Permission98=Desglosar líneas de facturas
|
|||||||
Permission101=Consultar expediciones
|
Permission101=Consultar expediciones
|
||||||
Permission102=Crear/modificar expediciones
|
Permission102=Crear/modificar expediciones
|
||||||
Permission104=Validar expediciones
|
Permission104=Validar expediciones
|
||||||
|
Permission106=Exportar expediciones
|
||||||
Permission109=Eliminar expediciones
|
Permission109=Eliminar expediciones
|
||||||
Permission111=Consultar cuentas financieras (cuentas bancarias, cajas)
|
Permission111=Consultar cuentas financieras (cuentas bancarias, cajas)
|
||||||
Permission112=Crear/modificar cantidad/eliminar registros bancarios
|
Permission112=Crear/modificar cantidad/eliminar registros bancarios
|
||||||
@ -914,7 +919,7 @@ MAIN_ROUNDING_RULE_TOT=Tamaño rango para el redondeo (para algunos países que
|
|||||||
UnitPriceOfProduct=Precio unitario sin IVA de un producto
|
UnitPriceOfProduct=Precio unitario sin IVA de un producto
|
||||||
TotalPriceAfterRounding=Precio total después del redondeo
|
TotalPriceAfterRounding=Precio total después del redondeo
|
||||||
ParameterActiveForNextInputOnly=Parámetro efectivo solamente a partir de las próximas sesiones
|
ParameterActiveForNextInputOnly=Parámetro efectivo solamente a partir de las próximas sesiones
|
||||||
NoEventOrNoAuditSetup=No se han registrado eventos de seguridad. Esto puede ser normal si la auditoría no ha sido habilitado en la página "configuración->seguridad->auditoría".
|
NoEventOrNoAuditSetup=No se han registrado eventos de seguridad. Esto puede ser normal si la auditoría no ha sido habilitada en la página "configuración->seguridad->auditoría".
|
||||||
NoEventFoundWithCriteria=No se han encontrado eventos de seguridad para tales criterios de búsqueda.
|
NoEventFoundWithCriteria=No se han encontrado eventos de seguridad para tales criterios de búsqueda.
|
||||||
SeeLocalSendMailSetup=Ver la configuración local de sendmail
|
SeeLocalSendMailSetup=Ver la configuración local de sendmail
|
||||||
BackupDesc=Para realizar una copia de seguridad completa de Dolibarr, usted debe:
|
BackupDesc=Para realizar una copia de seguridad completa de Dolibarr, usted debe:
|
||||||
|
|||||||
@ -250,7 +250,7 @@ Deposit=Anticipo
|
|||||||
Deposits=Anticipos
|
Deposits=Anticipos
|
||||||
DiscountFromCreditNote=Descuento resultante del abono %s
|
DiscountFromCreditNote=Descuento resultante del abono %s
|
||||||
DiscountFromDeposit=Pagos de la factura de anticipo %s
|
DiscountFromDeposit=Pagos de la factura de anticipo %s
|
||||||
AbsoluteDiscountUse=Este tipo de crédito no puede ser utilizado en una factura antes de su validación
|
AbsoluteDiscountUse=Este tipo de descuento no puede ser utilizado en una factura antes de su validación
|
||||||
CreditNoteDepositUse=La factura debe de estar validada para poder utilizar este tipo de créditos
|
CreditNoteDepositUse=La factura debe de estar validada para poder utilizar este tipo de créditos
|
||||||
NewGlobalDiscount=Nuevo descuento fijo
|
NewGlobalDiscount=Nuevo descuento fijo
|
||||||
NewRelativeDiscount=Nuevo descuento
|
NewRelativeDiscount=Nuevo descuento
|
||||||
|
|||||||
@ -81,6 +81,7 @@ ActionAC_SHIP=Envío expedición por correo
|
|||||||
ActionAC_SUP_ORD=Envío pedido a proveedor por correo
|
ActionAC_SUP_ORD=Envío pedido a proveedor por correo
|
||||||
ActionAC_SUP_INV=Envío factura de proveedor por correo
|
ActionAC_SUP_INV=Envío factura de proveedor por correo
|
||||||
ActionAC_OTH=Otra
|
ActionAC_OTH=Otra
|
||||||
|
ActionAC_OTH_AUTO=Otra (eventos insertados automáticamente)
|
||||||
ActionAC_MANUAL=Eventos creados manualmente
|
ActionAC_MANUAL=Eventos creados manualmente
|
||||||
ActionAC_AUTO=Eventos creados automáticamente
|
ActionAC_AUTO=Eventos creados automáticamente
|
||||||
Stats=Estadísticas de venta
|
Stats=Estadísticas de venta
|
||||||
|
|||||||
@ -2,3 +2,4 @@
|
|||||||
CHARSET=UTF-8
|
CHARSET=UTF-8
|
||||||
ExternalSiteSetup=Configuración del enlace al sitio web externo
|
ExternalSiteSetup=Configuración del enlace al sitio web externo
|
||||||
ExternalSiteURL=URL del sitio externo
|
ExternalSiteURL=URL del sitio externo
|
||||||
|
ExternalSiteModuleNotComplete=El módulo Sitio web externo no ha sido configurado correctamente.
|
||||||
@ -132,4 +132,9 @@ NoCPforMonth=Sin vacaciones este mes.
|
|||||||
Jours=días
|
Jours=días
|
||||||
nbJours=Número de días
|
nbJours=Número de días
|
||||||
TitleAdminCP=Configuración de las vacaciones
|
TitleAdminCP=Configuración de las vacaciones
|
||||||
Permission20001=Leer / Crear / Modificar sus vacaciones
|
Permission20001=Consultar/crear/modificar sus vacaciones
|
||||||
|
Permission20002=Consultar/modificar todas las solicitudes de permisos retribuídos
|
||||||
|
Permission20003=Eliminar las solicitudes de permisos retribuídos
|
||||||
|
Permission20004=Definir los permisos retribuídos de los usuarios
|
||||||
|
Permission20005=Consultar el historial de modificaciones de permisos retribuidos
|
||||||
|
Permission20006=Acceder al informe mensual de permisos retribuidos
|
||||||
@ -151,6 +151,7 @@ EMailTextOrderApproved=Pedido %s aprobado
|
|||||||
EMailTextOrderApprovedBy=Pedido %s aprobado por %s
|
EMailTextOrderApprovedBy=Pedido %s aprobado por %s
|
||||||
EMailTextOrderRefused=Pedido %s rechazado
|
EMailTextOrderRefused=Pedido %s rechazado
|
||||||
EMailTextOrderRefusedBy=Pedido %s rechazado por %s
|
EMailTextOrderRefusedBy=Pedido %s rechazado por %s
|
||||||
|
EMailTextExpeditionValidated=El envío %s ha sido validado.
|
||||||
ImportedWithSet=Lote de importación (import key)
|
ImportedWithSet=Lote de importación (import key)
|
||||||
DolibarrNotification=Notificación automática
|
DolibarrNotification=Notificación automática
|
||||||
ResizeDesc=Introduzca el nuevo ancho <b>O</b> la nueva altura. La relación se conserva al cambiar el tamaño ...
|
ResizeDesc=Introduzca el nuevo ancho <b>O</b> la nueva altura. La relación se conserva al cambiar el tamaño ...
|
||||||
|
|||||||
@ -45,6 +45,8 @@ ErrorModuleRequireDolibarrVersion= Erreur, ce module requiert une version %s ou
|
|||||||
ErrorDecimalLargerThanAreForbidden= Erreur, les précisions supérieures à <b>%s</b> ne sont pas supportées.
|
ErrorDecimalLargerThanAreForbidden= Erreur, les précisions supérieures à <b>%s</b> ne sont pas supportées.
|
||||||
DictionnarySetup= Dictionnaires
|
DictionnarySetup= Dictionnaires
|
||||||
Dictionnary= Dictionnaires
|
Dictionnary= Dictionnaires
|
||||||
|
ErrorReservedTypeSystemSystemAuto=
|
||||||
|
ErrorCodeCantContainZero=
|
||||||
DisableJavascript= Désactiver les fonctions Javascript et Ajax
|
DisableJavascript= Désactiver les fonctions Javascript et Ajax
|
||||||
ConfirmAjax= Utiliser les popups de confirmation Ajax
|
ConfirmAjax= Utiliser les popups de confirmation Ajax
|
||||||
UseSearchToSelectCompany= Utiliser un champ avec autocomplétion pour choisir un tiers (plutôt qu'une liste déroulante).<br><br>Notez que si vous avez un nombre important de tiers (> 100 000), vous pouvez améliorer les performances en définissant la constante SOCIETE_DONOTSEARCH_ANYWHERE à 1 dans Configuration->Divers. La recherche sera alors limitée au début de la chaine.
|
UseSearchToSelectCompany= Utiliser un champ avec autocomplétion pour choisir un tiers (plutôt qu'une liste déroulante).<br><br>Notez que si vous avez un nombre important de tiers (> 100 000), vous pouvez améliorer les performances en définissant la constante SOCIETE_DONOTSEARCH_ANYWHERE à 1 dans Configuration->Divers. La recherche sera alors limitée au début de la chaine.
|
||||||
@ -545,6 +547,7 @@ Permission98= Ventiler les lignes de factures
|
|||||||
Permission101= Consulter les expéditions
|
Permission101= Consulter les expéditions
|
||||||
Permission102= Créer/modifier les expéditions
|
Permission102= Créer/modifier les expéditions
|
||||||
Permission104= Valider les expéditions
|
Permission104= Valider les expéditions
|
||||||
|
Permission106= Exporter les expéditions
|
||||||
Permission109= Supprimer les expéditions
|
Permission109= Supprimer les expéditions
|
||||||
Permission111= Consulter les comptes financiers (comptes bancaires, caisses)
|
Permission111= Consulter les comptes financiers (comptes bancaires, caisses)
|
||||||
Permission112= Créer/modifier montant/supprimer écritures bancaires
|
Permission112= Créer/modifier montant/supprimer écritures bancaires
|
||||||
|
|||||||
@ -32,7 +32,7 @@ ViewCal=Vue mois
|
|||||||
ViewDay=Vue jour
|
ViewDay=Vue jour
|
||||||
ViewWeek=Vue semaine
|
ViewWeek=Vue semaine
|
||||||
ViewWithPredefinedFilters=Vues avec filtres prédéfinis
|
ViewWithPredefinedFilters=Vues avec filtres prédéfinis
|
||||||
AutoActions=Alimentation automatique de l'agenda
|
AutoActions=Alimentation automatique
|
||||||
AgendaAutoActionDesc=Définissez dans cet onglet les événements pour lesquels dolibarr créera automatiquement une action dans l'agenda. Si aucune case n'est cochée (par défaut), seules les actions manuelles seront incluses dans l'agenda.
|
AgendaAutoActionDesc=Définissez dans cet onglet les événements pour lesquels dolibarr créera automatiquement une action dans l'agenda. Si aucune case n'est cochée (par défaut), seules les actions manuelles seront incluses dans l'agenda.
|
||||||
AgendaSetupOtherDesc=Cette page permet de configurer quelques options permettant d'exporter une vue de votre agenda Dolibarr vers un calendrier externe (thunderbird, google calendar, ...)
|
AgendaSetupOtherDesc=Cette page permet de configurer quelques options permettant d'exporter une vue de votre agenda Dolibarr vers un calendrier externe (thunderbird, google calendar, ...)
|
||||||
AgendaExtSitesDesc=Cette page permet d'ajouter des sources de calendriers externes pour les visualiser au sein de l'agenda Dolibarr.
|
AgendaExtSitesDesc=Cette page permet d'ajouter des sources de calendriers externes pour les visualiser au sein de l'agenda Dolibarr.
|
||||||
|
|||||||
@ -81,6 +81,7 @@ ActionAC_SHIP=Envoi bon d'expédition par mail
|
|||||||
ActionAC_SUP_ORD=Envoi commande fournisseur par mail
|
ActionAC_SUP_ORD=Envoi commande fournisseur par mail
|
||||||
ActionAC_SUP_INV=Envoi facture fournisseur par mail
|
ActionAC_SUP_INV=Envoi facture fournisseur par mail
|
||||||
ActionAC_OTH=Autre
|
ActionAC_OTH=Autre
|
||||||
|
ActionAC_OTH_AUTO=Autre (evênements insérés automatiquement)
|
||||||
ActionAC_MANUAL=Evênements insérés manuellement
|
ActionAC_MANUAL=Evênements insérés manuellement
|
||||||
ActionAC_AUTO=Evênements insérés automatiquement
|
ActionAC_AUTO=Evênements insérés automatiquement
|
||||||
Stats=Statistiques de vente
|
Stats=Statistiques de vente
|
||||||
|
|||||||
@ -164,3 +164,4 @@ Pcg_subtype=Sous classe de compte
|
|||||||
InvoiceLinesToDispatch=Lignes de factures à ventiler
|
InvoiceLinesToDispatch=Lignes de factures à ventiler
|
||||||
InvoiceDispatched=Factures ventilées
|
InvoiceDispatched=Factures ventilées
|
||||||
AccountancyDashboard=Synthèse compta/tréso
|
AccountancyDashboard=Synthèse compta/tréso
|
||||||
|
ByProductsAndServices=Par produits et services
|
||||||
|
|||||||
@ -138,3 +138,4 @@ WarningUntilDirRemoved=Les alertes de sécurité sont visibles par les administr
|
|||||||
WarningCloseAlways=Attention, la fermeture se fait même lorsque le montant diffère. N'activez cette fonctionnalité qu'en connaissance de cause.
|
WarningCloseAlways=Attention, la fermeture se fait même lorsque le montant diffère. N'activez cette fonctionnalité qu'en connaissance de cause.
|
||||||
WarningUsingThisBoxSlowDown=Attention, l'utilisation de cette boite provoque de sérieux ralentissement des pages affichant cette boite.
|
WarningUsingThisBoxSlowDown=Attention, l'utilisation de cette boite provoque de sérieux ralentissement des pages affichant cette boite.
|
||||||
WarningClickToDialUserSetupNotComplete=La configuration ClickToDial pour votre compte utilisateur n'est pas complète (voir l'onglet ClickToDial sur votre fiche utilisateur)
|
WarningClickToDialUserSetupNotComplete=La configuration ClickToDial pour votre compte utilisateur n'est pas complète (voir l'onglet ClickToDial sur votre fiche utilisateur)
|
||||||
|
WarningNotRelevant=Opération non pertinente pour cet ensemble de données
|
||||||
|
|||||||
@ -2,3 +2,4 @@
|
|||||||
CHARSET=UTF-8
|
CHARSET=UTF-8
|
||||||
ExternalSiteSetup=Configuration du lien vers le site externe
|
ExternalSiteSetup=Configuration du lien vers le site externe
|
||||||
ExternalSiteURL=URL du site externe
|
ExternalSiteURL=URL du site externe
|
||||||
|
ExternalSiteModuleNotComplete=
|
||||||
@ -130,4 +130,9 @@ NoCPforMonth=Aucun congé ce mois-ci.
|
|||||||
Jours=jours
|
Jours=jours
|
||||||
nbJours=Nombre jours
|
nbJours=Nombre jours
|
||||||
TitleAdminCP=Configuration des Congés
|
TitleAdminCP=Configuration des Congés
|
||||||
Permission20001=Lire / Créer / modifier ses congés
|
Permission20001=Lire / Créer / modifier ses congès
|
||||||
|
Permission20002=Lire / Modifier toutes les demandes de congés payés
|
||||||
|
Permission20003=Supprimer des demandes de congés payés
|
||||||
|
Permission20004=Définir les congés payés des utilisateurs
|
||||||
|
Permission20005=Voir les logs de modification des congés payés
|
||||||
|
Permission20006=Accéder au rapport mensuel des congés payés
|
||||||
|
|||||||
@ -3,9 +3,9 @@ CHARSET=UTF-8
|
|||||||
DIRECTION=ltr
|
DIRECTION=ltr
|
||||||
SeparatorDecimal=,
|
SeparatorDecimal=,
|
||||||
SeparatorThousand=
|
SeparatorThousand=
|
||||||
FormatDateShort=%d/%m/%y
|
FormatDateShort=%d/%m/%Y
|
||||||
FormatDateShortInput=%d/%m/%Y
|
FormatDateShortInput=%d/%m/%Y
|
||||||
FormatDateShortJava=dd/MM/yy
|
FormatDateShortJava=dd/MM/yyyy
|
||||||
FormatDateShortJavaInput=dd/MM/yyyy
|
FormatDateShortJavaInput=dd/MM/yyyy
|
||||||
FormatDateShortJQuery=dd/mm/yy
|
FormatDateShortJQuery=dd/mm/yy
|
||||||
FormatDateShortJQueryInput=dd/mm/yy
|
FormatDateShortJQueryInput=dd/mm/yy
|
||||||
|
|||||||
@ -151,6 +151,7 @@ EMailTextOrderApproved=La commande %s a été approuvée.
|
|||||||
EMailTextOrderApprovedBy=La commande %s a été approuvée par %s.
|
EMailTextOrderApprovedBy=La commande %s a été approuvée par %s.
|
||||||
EMailTextOrderRefused=La commande %s a été refusée.
|
EMailTextOrderRefused=La commande %s a été refusée.
|
||||||
EMailTextOrderRefusedBy=La commande %s a été refusée par %s.
|
EMailTextOrderRefusedBy=La commande %s a été refusée par %s.
|
||||||
|
EMailTextExpeditionValidated=
|
||||||
ImportedWithSet=Lot d'importation (Import key)
|
ImportedWithSet=Lot d'importation (Import key)
|
||||||
DolibarrNotification=Notification automatique
|
DolibarrNotification=Notification automatique
|
||||||
ResizeDesc=Entrer la nouvelle largeur <b>OU</b> la nouvelle hauteur. Le ratio est conservé lors du redimensionnement...
|
ResizeDesc=Entrer la nouvelle largeur <b>OU</b> la nouvelle hauteur. Le ratio est conservé lors du redimensionnement...
|
||||||
|
|||||||
@ -111,11 +111,13 @@ ServiceLimitedDuration=Si produit de type service à durée limitée :
|
|||||||
MultiPricesAbility=Prise en charge de prix multiples
|
MultiPricesAbility=Prise en charge de prix multiples
|
||||||
MultiPricesNumPrices=Nombre de prix
|
MultiPricesNumPrices=Nombre de prix
|
||||||
MultiPriceLevelsName=Catégorie de prix
|
MultiPriceLevelsName=Catégorie de prix
|
||||||
AssociatedProductsAbility=Prise en charge des produits composés
|
AssociatedProductsAbility=Prise en charge des produits virtuels
|
||||||
AssociatedProducts=Composition
|
AssociatedProducts=Produit virtuel
|
||||||
AssociatedProductsNumber=Nbre de sous-produits composant ce produit
|
AssociatedProductsNumber=Nbre de sous-produits constituant ce produit virtuel
|
||||||
ParentProductsNumber=Nbre de produits parent
|
ParentProductsNumber=Nbre de produits virtuels parent
|
||||||
EditAssociate=Composer
|
IfZeroItIsNotAVirtualProduct=Si 0, ce produit n'est pas un produit virtuel
|
||||||
|
IfZeroItIsNotUsedByVirtualProduct=Si 0, ce produit n'est pas utilisé par un produit virtuel
|
||||||
|
EditAssociate=Composer comme produit virtuel
|
||||||
Translation=Traduction
|
Translation=Traduction
|
||||||
KeywordFilter=Filtre par mot-clé
|
KeywordFilter=Filtre par mot-clé
|
||||||
CategoryFilter=Filtre par catégorie
|
CategoryFilter=Filtre par catégorie
|
||||||
@ -123,8 +125,8 @@ ProductToAddSearch=Recherche des produits à ajouter
|
|||||||
AddDel=Ajouter/Retirer
|
AddDel=Ajouter/Retirer
|
||||||
Quantity=Quantité
|
Quantity=Quantité
|
||||||
NoMatchFound=Aucun résultat n'a été trouvé
|
NoMatchFound=Aucun résultat n'a été trouvé
|
||||||
ProductAssociationList=Liste des produits/services composant ce produit: Le nombre entre parenthèse est la quantité affectée dans cette composition.
|
ProductAssociationList=Liste des produits/services composant ce produit virtuel: Le nombre entre parenthèse est la quantité affectée dans cette composition.
|
||||||
ProductParentList=Liste des produits/services avec ce produit comme composante
|
ProductParentList=Liste des produits/services virtuels avec ce produit comme composante
|
||||||
ErrorAssociationIsFatherOfThis=L'un des produits sélectionnés est parent du produit en cours
|
ErrorAssociationIsFatherOfThis=L'un des produits sélectionnés est parent du produit en cours
|
||||||
DeleteProduct=Supprimer un produit/service
|
DeleteProduct=Supprimer un produit/service
|
||||||
ConfirmDeleteProduct=Êtes-vous sûr de vouloir supprimer ce produit/service ?
|
ConfirmDeleteProduct=Êtes-vous sûr de vouloir supprimer ce produit/service ?
|
||||||
@ -185,3 +187,11 @@ AlwaysUseFixedPrice=Utiliser le prix fixé
|
|||||||
PriceByQuantity=Prix par quantité
|
PriceByQuantity=Prix par quantité
|
||||||
PriceByQuantityRange=Grille de quantités
|
PriceByQuantityRange=Grille de quantités
|
||||||
ProductsDashboard=Synthèse produits/services
|
ProductsDashboard=Synthèse produits/services
|
||||||
|
### composition fabrication
|
||||||
|
Building=Fabrication
|
||||||
|
Build=Fabriquer
|
||||||
|
BuildIt=Lancer la fabrication
|
||||||
|
BuildindListInfo=Nombre de produit fabricable par entrepot, si saisie à zéro on ne fabrique pas
|
||||||
|
QtyNeed=Affectée
|
||||||
|
UnitPmp=Prix Achat Unitaire
|
||||||
|
CostPmpHT=Cout à l'achat HT
|
||||||
|
|||||||
@ -1797,17 +1797,16 @@ class Product extends CommonObject
|
|||||||
*/
|
*/
|
||||||
function add_sousproduit($id_pere, $id_fils,$qty)
|
function add_sousproduit($id_pere, $id_fils,$qty)
|
||||||
{
|
{
|
||||||
$sql = 'DELETE from '.MAIN_DB_PREFIX.'product_association';
|
// Clean parameters
|
||||||
$sql .= ' WHERE fk_product_pere = "'.$id_pere.'" AND fk_product_fils = "'.$id_fils.'"';
|
if (! is_numeric($id_pere)) $id_pere=0;
|
||||||
if (! $this->db->query($sql))
|
if (! is_numeric($id_fils)) $id_fils=0;
|
||||||
{
|
|
||||||
dol_print_error($this->db);
|
$result=$this->del_sousproduit($id_pere, $id_fils);
|
||||||
return -1;
|
if ($result < 0) return $result;
|
||||||
}
|
|
||||||
else
|
// Check not already father of id_pere (to avoid father -> child -> father links)
|
||||||
{
|
|
||||||
$sql = 'SELECT fk_product_pere from '.MAIN_DB_PREFIX.'product_association';
|
$sql = 'SELECT fk_product_pere from '.MAIN_DB_PREFIX.'product_association';
|
||||||
$sql .= ' WHERE fk_product_pere = "'.$id_fils.'" AND fk_product_fils = "'.$id_pere.'"';
|
$sql .= ' WHERE fk_product_pere = '.$id_fils.' AND fk_product_fils = '.$id_pere;
|
||||||
if (! $this->db->query($sql))
|
if (! $this->db->query($sql))
|
||||||
{
|
{
|
||||||
dol_print_error($this->db);
|
dol_print_error($this->db);
|
||||||
@ -1827,7 +1826,7 @@ class Product extends CommonObject
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
$sql = 'INSERT INTO '.MAIN_DB_PREFIX.'product_association(fk_product_pere,fk_product_fils,qty)';
|
$sql = 'INSERT INTO '.MAIN_DB_PREFIX.'product_association(fk_product_pere,fk_product_fils,qty)';
|
||||||
$sql .= ' VALUES ("'.$id_pere.'","'.$id_fils.'","'.$qty.'")';
|
$sql .= ' VALUES ('.$id_pere.', '.$id_fils.', '.$qty.')';
|
||||||
if (! $this->db->query($sql))
|
if (! $this->db->query($sql))
|
||||||
{
|
{
|
||||||
dol_print_error($this->db);
|
dol_print_error($this->db);
|
||||||
@ -1841,21 +1840,24 @@ class Product extends CommonObject
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Retire le lien entre un sousproduit et un produit/service
|
* Retire le lien entre un sousproduit et un produit/service
|
||||||
*
|
*
|
||||||
* @param int $fk_parent Id du produit auquel ne sera plus lie le produit lie
|
* @param int $fk_parent Id du produit auquel ne sera plus lie le produit lie
|
||||||
* @param int $fk_child Id du produit a ne plus lie
|
* @param int $fk_child Id du produit a ne plus lie
|
||||||
* @return int < 0 si erreur, > 0 si ok
|
* @return int < 0 if KO, > 0 if OK
|
||||||
*/
|
*/
|
||||||
function del_sousproduit($fk_parent, $fk_child)
|
function del_sousproduit($fk_parent, $fk_child)
|
||||||
{
|
{
|
||||||
$sql = "DELETE FROM ".MAIN_DB_PREFIX."product_association";
|
if (! is_numeric($fk_parent)) $fk_parent=0;
|
||||||
$sql.= " WHERE fk_product_pere = '".$fk_parent."'";
|
if (! is_numeric($fk_child)) $fk_child=0;
|
||||||
$sql.= " AND fk_product_fils = '".$fk_child."'";
|
|
||||||
|
|
||||||
|
$sql = "DELETE FROM ".MAIN_DB_PREFIX."product_association";
|
||||||
|
$sql.= " WHERE fk_product_pere = ".$fk_parent;
|
||||||
|
$sql.= " AND fk_product_fils = ".$fk_child;
|
||||||
|
|
||||||
|
dol_syslog(get_class($this).'::del_sousproduit sql='.$sql);
|
||||||
if (! $this->db->query($sql))
|
if (! $this->db->query($sql))
|
||||||
{
|
{
|
||||||
dol_print_error($this->db);
|
dol_print_error($this->db);
|
||||||
@ -2120,7 +2122,7 @@ class Product extends CommonObject
|
|||||||
* Define value of this->res
|
* Define value of this->res
|
||||||
*
|
*
|
||||||
* @param array $prod Products array
|
* @param array $prod Products array
|
||||||
* @param string $compl_path Directory path
|
* @param string $compl_path Directory path of parents to add before
|
||||||
* @param int $multiply Because each sublevel must be multiplicated by parent nb
|
* @param int $multiply Because each sublevel must be multiplicated by parent nb
|
||||||
* @param int $level Init level
|
* @param int $level Init level
|
||||||
* @return void
|
* @return void
|
||||||
@ -2130,65 +2132,36 @@ class Product extends CommonObject
|
|||||||
global $conf,$langs;
|
global $conf,$langs;
|
||||||
|
|
||||||
$product = new Product($this->db);
|
$product = new Product($this->db);
|
||||||
foreach($prod as $nom_pere => $desc_pere)
|
//var_dump($prod);
|
||||||
|
foreach($prod as $id_product => $desc_pere) // nom_pere is 0 or id of sub_product
|
||||||
{
|
{
|
||||||
if (is_array($desc_pere)) // If this parent desc is an array, this is an array of childs
|
if (is_array($desc_pere)) // If this parent desc is an array, this is an array of childs
|
||||||
{
|
{
|
||||||
$id=(! empty($desc_pere[0]) ? $desc_pere[0] :'');
|
$id=(! empty($desc_pere[0]) ? $desc_pere[0] :'');
|
||||||
$nb=(! empty($desc_pere[1]) ? $desc_pere[1] :'');
|
$nb=(! empty($desc_pere[1]) ? $desc_pere[1] :'');
|
||||||
$type=(! empty($desc_pere[2]) ? $desc_pere[2] :'');
|
$type=(! empty($desc_pere[2]) ? $desc_pere[2] :'');
|
||||||
|
$label=(! empty($desc_pere[3]) ? $desc_pere[3] :'');
|
||||||
|
if ($multiply < 1) $multiply=1;
|
||||||
|
|
||||||
if ($multiply)
|
//print "XXX We add id=".$id." - label=".$label." - nb=".$nb." - multiply=".$multiply." fullpath=".$compl_path.$label."\n";
|
||||||
{
|
|
||||||
//print "XXX ".$desc_pere[1]." multiply=".$multiply;
|
|
||||||
$img="";
|
|
||||||
$this->fetch($id);
|
$this->fetch($id);
|
||||||
$this->load_stock();
|
$this->load_stock();
|
||||||
if ($this->stock_warehouse[1]->real < $this->seuil_stock_alerte)
|
|
||||||
{
|
|
||||||
$img=img_warning($langs->trans("StockTooLow"));
|
|
||||||
}
|
|
||||||
$this->res[]= array(
|
$this->res[]= array(
|
||||||
/* "<tr><td> ->
|
'id'=>$id, // Id product
|
||||||
<a href=\"".DOL_URL_ROOT."/product/fiche.php?id=".$desc_pere[0]."\">".$compl_path.stripslashes($nom_pere)."
|
|
||||||
</a> (".$desc_pere[1].")</td><td align=\"center\"> ".($desc_pere[1]*$multiply)."</td><td> </td><td> </td>
|
|
||||||
<td align=\"center\">".$this->stock_entrepot[1]." ".$img."</td></tr>",
|
|
||||||
$desc_pere[0], // Id product
|
|
||||||
*/ 'id'=>$id, // Id product
|
|
||||||
'nb'=>$nb, // Nb of units that compose parent product
|
'nb'=>$nb, // Nb of units that compose parent product
|
||||||
'nb_total'=>$nb*$multiply, // Nb of units for all nb of product
|
'nb_total'=>$nb*$multiply, // Nb of units for all nb of product
|
||||||
'stock'=>$this->stock_warehouse[1]->real, // Stock
|
'stock'=>$this->stock_warehouse[1]->real, // Stock
|
||||||
'stock_alert'=>$this->seuil_stock_alerte, // Stock alert
|
'stock_alert'=>$this->seuil_stock_alerte, // Stock alert
|
||||||
'fullpath' => $compl_path.$nom_pere, // Label
|
'fullpath' => $compl_path.$label, // Label
|
||||||
'type'=>$type // Nb of units that compose parent product
|
'type'=>$type // Nb of units that compose parent product
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
$this->fetch($desc_pere[0]);
|
|
||||||
$this->load_stock();
|
|
||||||
$this->res[]= array(
|
|
||||||
/* $compl_path.$nom_pere." (".$desc_pere[1].")",
|
|
||||||
$desc_pere[0], // Id product
|
|
||||||
*/ 'id'=>$id, // Id product
|
|
||||||
'nb'=>$nb, // Nb of units that compose parent product
|
|
||||||
'nb_total'=>$nb, // Nb of units for all nb of product
|
|
||||||
'stock'=>$this->stock_warehouse[1]->real, // Stock
|
|
||||||
'stock_alert'=>$this->seuil_stock_alerte, // Stock alert
|
|
||||||
'fullpath' => $compl_path.$nom_pere, // Label
|
|
||||||
'type'=>$type // Nb of units that compose parent product
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if($nom_pere != "0" && $nom_pere != "1")
|
|
||||||
{
|
|
||||||
$this->res[]= array($compl_path.$nom_pere,$desc_pere);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Recursive call if child is an array
|
// Recursive call if child is an array
|
||||||
if (is_array($desc_pere[0]))
|
if (is_array($desc_pere['childs']))
|
||||||
{
|
{
|
||||||
$this ->fetch_prod_arbo($desc_pere[0], $nom_pere." -> ", $desc_pere[1]*$multiply, $level+1);
|
//print 'YYY We go down for '.$desc_pere[3]." -> \n";
|
||||||
|
$this ->fetch_prod_arbo($desc_pere['childs'], $compl_path.$desc_pere[3]." -> ", $desc_pere[1]*$multiply, $level+1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2225,11 +2198,12 @@ class Product extends CommonObject
|
|||||||
$this->res = array();
|
$this->res = array();
|
||||||
if (isset($this->sousprods) && is_array($this->sousprods))
|
if (isset($this->sousprods) && is_array($this->sousprods))
|
||||||
{
|
{
|
||||||
foreach($this->sousprods as $nom_pere => $desc_pere)
|
foreach($this->sousprods as $prod_name => $desc_product)
|
||||||
{
|
{
|
||||||
if (is_array($desc_pere)) $this->fetch_prod_arbo($desc_pere,"",$multiply);
|
if (is_array($desc_product)) $this->fetch_prod_arbo($desc_product,"",$multiply);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
//var_dump($this->res);
|
||||||
return $this->res;
|
return $this->res;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2290,7 +2264,7 @@ class Product extends CommonObject
|
|||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return all parent products fo current product
|
* Return all direct parent products fo current product
|
||||||
*
|
*
|
||||||
* @return array prod
|
* @return array prod
|
||||||
*/
|
*/
|
||||||
@ -2321,19 +2295,19 @@ class Product extends CommonObject
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return childs of product with if fk_parent
|
* Return childs of product $id
|
||||||
*
|
*
|
||||||
* @param int $fk_parent Id of product to search childs of
|
* @param int $id Id of product to search childs of
|
||||||
* @return array Prod
|
* @return array Prod
|
||||||
*/
|
*/
|
||||||
function getChildsArbo($fk_parent)
|
function getChildsArbo($id)
|
||||||
{
|
{
|
||||||
$sql = "SELECT p.rowid, p.label as label, pa.qty as qty, pa.fk_product_fils as id, p.fk_product_type";
|
$sql = "SELECT p.rowid, p.label as label, pa.qty as qty, pa.fk_product_fils as id, p.fk_product_type";
|
||||||
$sql.= " FROM ".MAIN_DB_PREFIX."product as p";
|
$sql.= " FROM ".MAIN_DB_PREFIX."product as p";
|
||||||
$sql.= ", ".MAIN_DB_PREFIX."product_association as pa";
|
$sql.= ", ".MAIN_DB_PREFIX."product_association as pa";
|
||||||
$sql.= " WHERE p.rowid = pa.fk_product_fils";
|
$sql.= " WHERE p.rowid = pa.fk_product_fils";
|
||||||
$sql.= " AND pa.fk_product_pere = ".$fk_parent;
|
$sql.= " AND pa.fk_product_pere = ".$id;
|
||||||
$sql.= " AND pa.fk_product_fils != ".$fk_parent; // This should not happens, it is to avoid invinite loop if it happens
|
$sql.= " AND pa.fk_product_fils != ".$id; // This should not happens, it is to avoid infinite loop if it happens
|
||||||
|
|
||||||
dol_syslog(get_class($this).'::getChildsArbo sql='.$sql);
|
dol_syslog(get_class($this).'::getChildsArbo sql='.$sql);
|
||||||
$res = $this->db->query($sql);
|
$res = $this->db->query($sql);
|
||||||
@ -2348,7 +2322,7 @@ class Product extends CommonObject
|
|||||||
$listofchilds=$this->getChildsArbo($rec['id']);
|
$listofchilds=$this->getChildsArbo($rec['id']);
|
||||||
foreach($listofchilds as $keyChild => $valueChild)
|
foreach($listofchilds as $keyChild => $valueChild)
|
||||||
{
|
{
|
||||||
$prods[$rec['rowid']][$keyChild] = $valueChild;
|
$prods[$rec['rowid']]['childs'][$keyChild] = $valueChild;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2370,14 +2344,14 @@ class Product extends CommonObject
|
|||||||
function get_sousproduits_arbo()
|
function get_sousproduits_arbo()
|
||||||
{
|
{
|
||||||
$parent = $this->getParent();
|
$parent = $this->getParent();
|
||||||
foreach($parent as $key => $value)
|
foreach($parent as $key => $value) // key=label, value[0]=id
|
||||||
{
|
{
|
||||||
foreach($this->getChildsArbo($value[0]) as $keyChild => $valueChild)
|
foreach($this->getChildsArbo($value[0]) as $keyChild => $valueChild)
|
||||||
{
|
{
|
||||||
$parent[$key][$keyChild] = $valueChild;
|
$parent[$key][$keyChild] = $valueChild;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
foreach($parent as $key => $value)
|
foreach($parent as $key => $value) // key=label, value is array of childs
|
||||||
{
|
{
|
||||||
$this->sousprods[$key] = $value;
|
$this->sousprods[$key] = $value;
|
||||||
}
|
}
|
||||||
@ -2412,6 +2386,10 @@ class Product extends CommonObject
|
|||||||
$lien = '<a href="'.DOL_URL_ROOT.'/product/composition/fiche.php?id='.$this->id.'">';
|
$lien = '<a href="'.DOL_URL_ROOT.'/product/composition/fiche.php?id='.$this->id.'">';
|
||||||
$lienfin='</a>';
|
$lienfin='</a>';
|
||||||
}
|
}
|
||||||
|
else if ($option == 'category')
|
||||||
|
{
|
||||||
|
$lien = '<a href="'.DOL_URL_ROOT.'/categories/categorie.php?id='.$this->id.'&type=0">';
|
||||||
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
$lien = '<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$this->id.'">';
|
$lien = '<a href="'.DOL_URL_ROOT.'/product/fiche.php?id='.$this->id.'">';
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2001-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2001-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2005 Eric Seigne <eric.seigne@ryxeo.com>
|
* Copyright (C) 2005 Eric Seigne <eric.seigne@ryxeo.com>
|
||||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||||
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
|
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
|
||||||
@ -72,8 +72,8 @@ $cancel <> $langs->trans("Cancel") &&
|
|||||||
$error=0;
|
$error=0;
|
||||||
for($i=0;$i<$_POST["max_prod"];$i++)
|
for($i=0;$i<$_POST["max_prod"];$i++)
|
||||||
{
|
{
|
||||||
// print "<br> : ".$_POST["prod_id_chk".$i];
|
print "<br> : ".$_POST["prod_id_chk".$i];
|
||||||
if($_POST["prod_id_chk".$i] != "")
|
if ($_POST["prod_id_chk".$i] > 0)
|
||||||
{
|
{
|
||||||
if($product->add_sousproduit($id, $_POST["prod_id_".$i],$_POST["prod_qty_".$i]) > 0)
|
if($product->add_sousproduit($id, $_POST["prod_id_".$i],$_POST["prod_qty_".$i]) > 0)
|
||||||
{
|
{
|
||||||
@ -200,13 +200,16 @@ if ($id || $ref)
|
|||||||
// Number of subproducts
|
// Number of subproducts
|
||||||
$prodsfather = $product->getFather(); // Parent Products
|
$prodsfather = $product->getFather(); // Parent Products
|
||||||
$product->get_sousproduits_arbo();
|
$product->get_sousproduits_arbo();
|
||||||
print '<tr><td>'.$langs->trans("AssociatedProductsNumber").'</td><td>'.count($product->get_arbo_each_prod()).'</td>';
|
$prods_arbo=$product->get_arbo_each_prod();
|
||||||
|
$nbofsubproducts=count($prods_arbo);
|
||||||
|
print '<tr><td>'.$langs->trans("AssociatedProductsNumber").'</td><td>';
|
||||||
|
print $form->textwithpicto($nbofsubproducts, $langs->trans('IfZeroItIsNotAVirtualProduct'));
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
dol_fiche_end();
|
dol_fiche_end();
|
||||||
|
|
||||||
|
|
||||||
// List of subproducts
|
// List of products into this virtual product
|
||||||
$prods_arbo = $product->get_arbo_each_prod();
|
|
||||||
if (count($prods_arbo) > 0)
|
if (count($prods_arbo) > 0)
|
||||||
{
|
{
|
||||||
print '<tr><td colspan="2">';
|
print '<tr><td colspan="2">';
|
||||||
@ -223,6 +226,7 @@ if ($id || $ref)
|
|||||||
//print $productstatic->getNomUrl(1).'<br>';
|
//print $productstatic->getNomUrl(1).'<br>';
|
||||||
//print $value[0]; // This contains a tr line.
|
//print $value[0]; // This contains a tr line.
|
||||||
print '<tr>';
|
print '<tr>';
|
||||||
|
//print '<td>'.$productstatic->getNomUrl(1,'composition').' ('.$value['nb'].($value['nb_total'] > $value['nb']?'->'.$value['nb_total']:'').')    </td>';
|
||||||
print '<td>'.$productstatic->getNomUrl(1,'composition').' ('.$value['nb'].')    </td>';
|
print '<td>'.$productstatic->getNomUrl(1,'composition').' ('.$value['nb'].')    </td>';
|
||||||
if (! empty($conf->stock->enabled)) print '<td>'.$langs->trans("Stock").' : <b>'.$productstatic->stock_reel.'</b></td>';
|
if (! empty($conf->stock->enabled)) print '<td>'.$langs->trans("Stock").' : <b>'.$productstatic->stock_reel.'</b></td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
@ -231,8 +235,10 @@ if ($id || $ref)
|
|||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
}
|
}
|
||||||
|
|
||||||
// Number of parent products
|
// Number of parent virtual products
|
||||||
print '<tr><td>'.$langs->trans("ParentProductsNumber").'</td><td>'.count($prodsfather).'</td>';
|
print '<tr><td>'.$langs->trans("ParentProductsNumber").'</td><td>';
|
||||||
|
print $form->textwithpicto(count($prodsfather), $langs->trans('IfZeroItIsNotUsedByVirtualProduct'));
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
if (count($prodsfather) > 0)
|
if (count($prodsfather) > 0)
|
||||||
{
|
{
|
||||||
@ -286,12 +292,14 @@ if ($id || $ref)
|
|||||||
// Number of subproducts
|
// Number of subproducts
|
||||||
$prodsfather = $product->getFather(); //Parent Products
|
$prodsfather = $product->getFather(); //Parent Products
|
||||||
$product->get_sousproduits_arbo();
|
$product->get_sousproduits_arbo();
|
||||||
print '<tr><td>'.$langs->trans("AssociatedProductsNumber").'</td><td>'.count($product->get_arbo_each_prod()).'</td>';
|
$prods_arbo=$product->get_arbo_each_prod();
|
||||||
|
$nbofsubproducts=count($prods_arbo);
|
||||||
|
print '<tr><td>'.$langs->trans("AssociatedProductsNumber").'</td><td>';
|
||||||
|
print $form->textwithpicto($nbofsubproducts, $langs->trans('IfZeroItIsNotAVirtualProduct'));
|
||||||
|
print '</td>';
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
|
|
||||||
// List of subproducts
|
// List of subproducts
|
||||||
$prods_arbo = $product->get_arbo_each_prod();
|
|
||||||
//var_dump($prods_arbo);
|
|
||||||
if(count($prods_arbo) > 0)
|
if(count($prods_arbo) > 0)
|
||||||
{
|
{
|
||||||
print '<tr><td colspan="2">';
|
print '<tr><td colspan="2">';
|
||||||
@ -316,8 +324,10 @@ if ($id || $ref)
|
|||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
}
|
}
|
||||||
|
|
||||||
// Number of parent products
|
// Number of parent virtual products
|
||||||
print '<tr><td>'.$langs->trans("ParentProductsNumber").'</td><td>'.count($prodsfather).'</td>';
|
print '<tr><td>'.$langs->trans("ParentProductsNumber").'</td><td>';
|
||||||
|
print $form->textwithpicto(count($prodsfather), $langs->trans('IfZeroItIsNotUsedByVirtualProduct'));
|
||||||
|
print '</td>';
|
||||||
|
|
||||||
if (count($prodsfather) > 0)
|
if (count($prodsfather) > 0)
|
||||||
{
|
{
|
||||||
|
|||||||
@ -183,6 +183,7 @@ class Task extends CommonObject
|
|||||||
$sql.= " t.label,";
|
$sql.= " t.label,";
|
||||||
$sql.= " t.description,";
|
$sql.= " t.description,";
|
||||||
$sql.= " t.duration_effective,";
|
$sql.= " t.duration_effective,";
|
||||||
|
$sql.= " t.datec,";
|
||||||
$sql.= " t.dateo,";
|
$sql.= " t.dateo,";
|
||||||
$sql.= " t.datee,";
|
$sql.= " t.datee,";
|
||||||
$sql.= " t.fk_user_creat,";
|
$sql.= " t.fk_user_creat,";
|
||||||
|
|||||||
@ -93,7 +93,11 @@ if ($id > 0 || ! empty($ref))
|
|||||||
{
|
{
|
||||||
$projectstatic->fetch($object->fk_project);
|
$projectstatic->fetch($object->fk_project);
|
||||||
|
|
||||||
if (! empty($projectstatic->socid)) $projectstatic->societe->fetch($projectstatic->socid);
|
if (! empty($projectstatic->socid)) {
|
||||||
|
$projectstatic->fetch_thirdparty();
|
||||||
|
}
|
||||||
|
|
||||||
|
$object->project = dol_clone($projectstatic);
|
||||||
|
|
||||||
$upload_dir = $conf->projet->dir_output.'/'.dol_sanitizeFileName($projectstatic->ref).'/'.dol_sanitizeFileName($object->ref);
|
$upload_dir = $conf->projet->dir_output.'/'.dol_sanitizeFileName($projectstatic->ref).'/'.dol_sanitizeFileName($object->ref);
|
||||||
}
|
}
|
||||||
@ -114,7 +118,7 @@ if ($action=='delete')
|
|||||||
{
|
{
|
||||||
$langs->load("other");
|
$langs->load("other");
|
||||||
$file = $upload_dir . '/' . GETPOST('urlfile'); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
|
$file = $upload_dir . '/' . GETPOST('urlfile'); // Do not use urldecode here ($_GET and $_REQUEST are already decoded by PHP).
|
||||||
$ret=dol_delete_file($file);
|
$ret=dol_delete_file($file,0,0,0,$object);
|
||||||
if ($ret) setEventMessage($langs->trans("FileWasRemoved", GETPOST('urlfile')));
|
if ($ret) setEventMessage($langs->trans("FileWasRemoved", GETPOST('urlfile')));
|
||||||
else setEventMessage($langs->trans("ErrorFailToDeleteFile", GETPOST('urlfile')), 'errors');
|
else setEventMessage($langs->trans("ErrorFailToDeleteFile", GETPOST('urlfile')), 'errors');
|
||||||
header('Location: '.$_SERVER["PHP_SELF"].'?id='.$id);
|
header('Location: '.$_SERVER["PHP_SELF"].'?id='.$id);
|
||||||
|
|||||||
@ -1455,6 +1455,15 @@ class Societe extends CommonObject
|
|||||||
{
|
{
|
||||||
$lien = '<a href="'.DOL_URL_ROOT.'/fourn/fiche.php?socid='.$this->id;
|
$lien = '<a href="'.DOL_URL_ROOT.'/fourn/fiche.php?socid='.$this->id;
|
||||||
}
|
}
|
||||||
|
else if ($option == 'category')
|
||||||
|
{
|
||||||
|
$lien = '<a href="'.DOL_URL_ROOT.'/categories/categorie.php?id='.$this->id.'&type=2';
|
||||||
|
}
|
||||||
|
else if ($option == 'category_supplier')
|
||||||
|
{
|
||||||
|
$lien = '<a href="'.DOL_URL_ROOT.'/categories/categorie.php?id='.$this->id.'&type=1';
|
||||||
|
}
|
||||||
|
|
||||||
// By default
|
// By default
|
||||||
if (empty($lien))
|
if (empty($lien))
|
||||||
{
|
{
|
||||||
@ -1462,7 +1471,7 @@ class Societe extends CommonObject
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Add type of canvas
|
// Add type of canvas
|
||||||
$lien.=(!empty($this->canvas)?'&canvas='.$this->canvas:'').'">';
|
$lien.=(!empty($this->canvas)?'&canvas='.$this->canvas:'').'">';
|
||||||
$lienfin='</a>';
|
$lienfin='</a>';
|
||||||
|
|
||||||
if ($withpicto) $result.=($lien.img_object($langs->trans("ShowCompany").': '.$name,'company').$lienfin);
|
if ($withpicto) $result.=($lien.img_object($langs->trans("ShowCompany").': '.$name,'company').$lienfin);
|
||||||
|
|||||||
@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
global $theme_bordercolor, $theme_datacolor, $theme_bgcolor, $theme_bgcoloronglet;
|
global $theme_bordercolor, $theme_datacolor, $theme_bgcolor, $theme_bgcoloronglet;
|
||||||
$theme_bordercolor = array(235,235,224);
|
$theme_bordercolor = array(235,235,224);
|
||||||
$theme_datacolor = array(array(125,135,150), array(200,160,180), array(190,190,220), array(170,140,190), array(190,190,170));
|
$theme_datacolor = array(array(190,190,220), array(200,160,180), array(125,135,150), array(170,140,190), array(190,190,170));
|
||||||
$theme_bgcolor = array(hexdec('F4'),hexdec('F4'),hexdec('F4'));
|
$theme_bgcolor = array(hexdec('F4'),hexdec('F4'),hexdec('F4'));
|
||||||
$theme_bgcoloronglet = array(hexdec('DE'),hexdec('E7'),hexdec('EC'));
|
$theme_bgcoloronglet = array(hexdec('DE'),hexdec('E7'),hexdec('EC'));
|
||||||
|
|
||||||
|
|||||||
@ -21,25 +21,28 @@
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* \file htdocs/theme/amarok/style.css.php
|
* \file htdocs/theme/amarok/style.css.php
|
||||||
* \brief Fichier de style CSS du theme amarok
|
* \brief File for CSS style sheet Amarok
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled cause need to load personalized language
|
//if (! defined('NOREQUIREUSER')) define('NOREQUIREUSER','1'); // Not disabled because need to load personalized language
|
||||||
//if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1'); // Not disabled to increase speed. Language code is found on url.
|
//if (! defined('NOREQUIREDB')) define('NOREQUIREDB','1'); // Not disabled to increase speed. Language code is found on url.
|
||||||
if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
|
if (! defined('NOREQUIRESOC')) define('NOREQUIRESOC','1');
|
||||||
//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // Not disabled cause need to do translations
|
//if (! defined('NOREQUIRETRAN')) define('NOREQUIRETRAN','1'); // Not disabled because need to do translations
|
||||||
if (! defined('NOCSRFCHECK')) define('NOCSRFCHECK',1);
|
if (! defined('NOCSRFCHECK')) define('NOCSRFCHECK',1);
|
||||||
if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL',1);
|
if (! defined('NOTOKENRENEWAL')) define('NOTOKENRENEWAL',1);
|
||||||
if (! defined('NOLOGIN')) define('NOLOGIN',1);
|
if (! defined('NOLOGIN')) define('NOLOGIN',1); // File must be accessed by logon page so without login
|
||||||
if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU',1);
|
if (! defined('NOREQUIREMENU')) define('NOREQUIREMENU',1);
|
||||||
if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML',1);
|
if (! defined('NOREQUIREHTML')) define('NOREQUIREHTML',1);
|
||||||
if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
|
if (! defined('NOREQUIREAJAX')) define('NOREQUIREAJAX','1');
|
||||||
|
|
||||||
session_cache_limiter(FALSE);
|
session_cache_limiter(FALSE);
|
||||||
|
|
||||||
require_once("../../main.inc.php");
|
require_once '../../main.inc.php';
|
||||||
|
|
||||||
|
// Load user to have $user->conf loaded (not done into main because of NOLOGIN constant defined)
|
||||||
|
if (empty($user->id) && ! empty($_SESSION['dol_login'])) $user->fetch('',$_SESSION['dol_login']);
|
||||||
|
|
||||||
// Define css type
|
// Define css type
|
||||||
header('Content-type: text/css');
|
header('Content-type: text/css');
|
||||||
@ -69,12 +72,55 @@ $fontlist='helvetica,arial,tahoma,verdana'; //$fontlist='Verdana,Helvetica,Ar
|
|||||||
$img_liste_titre=dol_buildpath($path.'/theme/'.$theme.'/img/menus/trtitle.png',1);
|
$img_liste_titre=dol_buildpath($path.'/theme/'.$theme.'/img/menus/trtitle.png',1);
|
||||||
$img_head=dol_buildpath($path.'/theme/'.$theme.'/img/headbg2.jpg',1);
|
$img_head=dol_buildpath($path.'/theme/'.$theme.'/img/headbg2.jpg',1);
|
||||||
$img_button=dol_buildpath($path.'/theme/'.$theme.'/img/button_bg.png',1);
|
$img_button=dol_buildpath($path.'/theme/'.$theme.'/img/button_bg.png',1);
|
||||||
|
$dol_hide_topmenu=$conf->dol_hide_topmenu;
|
||||||
|
$dol_hide_leftmenu=$conf->dol_hide_leftmenu;
|
||||||
|
$dol_optimize_smallscreen=$conf->dol_optimize_smallscreen;
|
||||||
|
$dol_no_mouse_hover=$conf->dol_no_mouse_hover;
|
||||||
|
$dol_use_jmobile=$conf->dol_use_jmobile;
|
||||||
|
|
||||||
|
|
||||||
|
// Define reference colors
|
||||||
|
// Example: Light grey: $colred=235;$colgreen=235;$colblue=235;
|
||||||
|
// Example: Pink: $colred=230;$colgreen=210;$colblue=230;
|
||||||
|
// Example: Green: $colred=210;$colgreen=230;$colblue=210;
|
||||||
|
// Example: Ocean: $colred=220;$colgreen=220;$colblue=240;
|
||||||
|
//$conf->global->THEME_ELDY_ENABLE_PERSONALIZED=0;
|
||||||
|
//$user->conf->THEME_ELDY_ENABLE_PERSONALIZED=0;
|
||||||
|
//var_dump($user->conf->THEME_ELDY_RGB);
|
||||||
|
$colred =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_RGB)?235:hexdec(substr($conf->global->THEME_ELDY_RGB,0,2))):(empty($user->conf->THEME_ELDY_RGB)?235:hexdec(substr($user->conf->THEME_ELDY_RGB,0,2)));
|
||||||
|
$colgreen=empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_RGB)?235:hexdec(substr($conf->global->THEME_ELDY_RGB,2,2))):(empty($user->conf->THEME_ELDY_RGB)?235:hexdec(substr($user->conf->THEME_ELDY_RGB,2,2)));
|
||||||
|
$colblue =empty($user->conf->THEME_ELDY_ENABLE_PERSONALIZED)?(empty($conf->global->THEME_ELDY_RGB)?235:hexdec(substr($conf->global->THEME_ELDY_RGB,4,2))):(empty($user->conf->THEME_ELDY_RGB)?235:hexdec(substr($user->conf->THEME_ELDY_RGB,4,2)));
|
||||||
|
|
||||||
|
// Colors
|
||||||
|
$isred=max(0,(2*$colred-$colgreen-$colblue)/2); // 0 - 255
|
||||||
|
$isgreen=max(0,(2*$colgreen-$colred-$colblue)/2); // 0 - 255
|
||||||
|
$isblue=max(0,(2*$colblue-$colred-$colgreen)/2); // 0 - 255
|
||||||
|
$colorback1=($colred-3).','.($colgreen-3).','.($colblue-3); // topmenu
|
||||||
|
$colorback2=($colred+5).','.($colgreen+5).','.($colblue+5);
|
||||||
|
$colorbacktab1=($colred+15).','.($colgreen+16).','.($colblue+17); // vmenu
|
||||||
|
$colorbacktab1b=($colred+5).','.($colgreen+6).','.($colblue+7); // vmenu (not menu)
|
||||||
|
$colorbacktab2=($colred-15).','.($colgreen-15).','.($colblue-15);
|
||||||
|
$colorbacktitle1=($colred-5).','.($colgreen-5).','.($colblue-5); // title of array
|
||||||
|
$colorbacktitle2=($colred-15).','.($colgreen-15).','.($colblue-15);
|
||||||
|
$colorbacktabcard1=($colred+15).','.($colgreen+16).','.($colblue+17); // card
|
||||||
|
$colorbacktabcard2=($colred-15).','.($colgreen-15).','.($colblue-15);
|
||||||
|
$colorbacktabactive=($colred-15).','.($colgreen-15).','.($colblue-15);
|
||||||
|
$colorbacklineimpair1=(244+round($isred/3)).','.(244+round($isgreen/3)).','.(244+round($isblue/3)); // line impair
|
||||||
|
$colorbacklineimpair2=(250+round($isred/3)).','.(250+round($isgreen/3)).','.(250+round($isblue/3)); // line impair
|
||||||
|
$colorbacklineimpairhover=(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9)); // line impair
|
||||||
|
$colorbacklinepair1='255,255,255'; // line pair
|
||||||
|
$colorbacklinepair2='255,255,255'; // line pair
|
||||||
|
$colorbacklinepairhover=(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9)).','.(230+round(($isred+$isgreen+$isblue)/9));
|
||||||
|
$colorbackbody='#f5f5f5';
|
||||||
|
$colortext='40,40,40';
|
||||||
|
$fontsize=empty($conf->dol_optimize_smallscreen)?'12':'14';
|
||||||
|
$fontsizesmaller=empty($conf->dol_optimize_smallscreen)?'11':'14';
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
/* Styles par défaut */
|
/* Default styles */
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
|
|
||||||
*, html {
|
*, html {
|
||||||
@ -84,31 +130,17 @@ font-size:100%;
|
|||||||
}
|
}
|
||||||
|
|
||||||
body {
|
body {
|
||||||
background-color:#f5f5f5;
|
<?php if (GETPOST("optioncss") == 'print' || ! empty($conf->dol_optimize_smallscreen)) { ?>
|
||||||
<?php if ($_SESSION['dol_login'] != '') {?>
|
background-color: #FFFFFF;
|
||||||
<?php if (GETPOST("optioncss") != 'print') {?>
|
|
||||||
background-image:url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/vmenu.png',1); ?>);
|
|
||||||
background-repeat:repeat-y;
|
|
||||||
margin:0px;
|
|
||||||
<?php } ?>
|
|
||||||
<?php } else { ?>
|
<?php } else { ?>
|
||||||
background-image:url(<?php echo dol_buildpath($path.'/theme/'.$theme.'/img/background_login.png',1); ?>);
|
background-color: <?php print $colorbackbody; ?>;
|
||||||
margin:100px;
|
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
color:#232323;
|
color:#232323;
|
||||||
font-size:<?php print $fontsize ?>px;
|
font-size:<?php print $fontsize ?>px;
|
||||||
font-family:<?php print $fontlist ?>;
|
font-family:<?php print $fontlist ?>;
|
||||||
|
|
||||||
<?php print 'direction:'.$langs->trans("DIRECTION").";\n"; ?>
|
<?php print 'direction:'.$langs->trans("DIRECTION").";\n"; ?>
|
||||||
}
|
}
|
||||||
|
|
||||||
.checkVatPopup {
|
|
||||||
background-color:#f5f5f5;
|
|
||||||
background-image:none;
|
|
||||||
margin:10px;
|
|
||||||
line-height:16px;
|
|
||||||
}
|
|
||||||
|
|
||||||
a {
|
a {
|
||||||
font-family:<?php print $fontlist ?>;
|
font-family:<?php print $fontlist ?>;
|
||||||
font-weight:bold;
|
font-weight:bold;
|
||||||
@ -194,6 +226,15 @@ div.inline-block
|
|||||||
display:inline-block;
|
display:inline-block;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
th .button {
|
||||||
|
-moz-box-shadow: none !important;
|
||||||
|
-webkit-box-shadow: none !important;
|
||||||
|
box-shadow: none !important;
|
||||||
|
-moz-border-radius:0px !important;
|
||||||
|
-webkit-border-radius:0px !important;
|
||||||
|
border-radius:0px !important;
|
||||||
|
}
|
||||||
|
|
||||||
.valignmiddle {
|
.valignmiddle {
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
}
|
}
|
||||||
@ -211,11 +252,104 @@ div.inline-block
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.blockvmenubookmarks .menu_contenu {
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ! Message d'erreur lors du login : */
|
||||||
|
center .error { padding:8px !important; padding-left:26px !important; padding-right:20px; width:inherit; max-width:450px;color:#552323 !important; font-size:14px; border-radius:8px; text-align: left;}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
/* Login */
|
/* Styles to hide objects */
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
|
|
||||||
body.body center{color:white;}
|
.hideobject { display:none; }
|
||||||
|
<?php if (! empty($dol_optimize_smallscreen)) { ?>
|
||||||
|
.hideonsmartphone { display: none; }
|
||||||
|
.noenlargeonsmartphone { width : 50px !important; display: inline !important; }
|
||||||
|
<?php } ?>
|
||||||
|
.linkobject { cursor:pointer; }
|
||||||
|
|
||||||
|
|
||||||
|
/* ============================================================================== */
|
||||||
|
/* Styles for dragging lines */
|
||||||
|
/* ============================================================================== */
|
||||||
|
|
||||||
|
.dragClass {
|
||||||
|
color: #333333;
|
||||||
|
}
|
||||||
|
td.showDragHandle {
|
||||||
|
cursor: move;
|
||||||
|
}
|
||||||
|
.tdlineupdown {
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* ============================================================================== */
|
||||||
|
/* Menu top et 1ere ligne tableau */
|
||||||
|
/* ============================================================================== */
|
||||||
|
|
||||||
|
div.tmenu {
|
||||||
|
<?php if (GETPOST("optioncss") == 'print') {?>
|
||||||
|
display:none;
|
||||||
|
<?php } else {?>
|
||||||
|
position:relative;
|
||||||
|
display:block;
|
||||||
|
margin:0;
|
||||||
|
padding:0;
|
||||||
|
padding-left:1em;
|
||||||
|
top:0;
|
||||||
|
left:0;
|
||||||
|
right:0;
|
||||||
|
white-space:nowrap;
|
||||||
|
height:36px;
|
||||||
|
<?php if ($conf->browser->name != 'ie') echo "line-height:36px; /* disabled for ie9 */ \n"; ?>
|
||||||
|
background:#333333;
|
||||||
|
background-image:linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
||||||
|
background-image:-o-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
||||||
|
background-image:-moz-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
||||||
|
background-image:-webkit-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
||||||
|
background-image:-ms-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
||||||
|
background-image:-webkit-gradient(
|
||||||
|
linear,
|
||||||
|
left top,
|
||||||
|
left bottom,
|
||||||
|
color-stop(0, rgba(255,255,255,.3)),
|
||||||
|
color-stop(1, rgba(0,0,0,.3))
|
||||||
|
);
|
||||||
|
border-bottom:solid 1px rgba(0,0,0,.8);
|
||||||
|
box-shadow:0 0 6px rgba(0,0,0,.4) !important;
|
||||||
|
z-index:100;
|
||||||
|
<?php } ?>
|
||||||
|
}
|
||||||
|
|
||||||
|
div.tmenu a {
|
||||||
|
font-weight:normal;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.tmenu li {
|
||||||
|
display:inline-table;
|
||||||
|
margin-right:1em;
|
||||||
|
text-transform:uppercase;
|
||||||
|
}
|
||||||
|
|
||||||
|
div.tmenu li a {color:#cccccc;}
|
||||||
|
div.tmenu li a:hover { color:rgba(255,255,255,1);}
|
||||||
|
|
||||||
|
div.tmenu ul li a.tmenusel {/* texte du menu principal sélectionné */
|
||||||
|
color:#ffffff;
|
||||||
|
font-weight:bold;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tmenudisabled { color:#808080 !important; cursor: not-allowed; }
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* Login */
|
||||||
|
|
||||||
|
body.body center { color:white; margin-top: 100px; }
|
||||||
|
|
||||||
form#login {
|
form#login {
|
||||||
display:block;
|
display:block;
|
||||||
@ -329,96 +463,6 @@ table.login_table .vmenu {
|
|||||||
font-size:120%;
|
font-size:120%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.blockvmenubookmarks .menu_contenu {
|
|
||||||
background-color: transparent;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* ! Message d'erreur lors du login : */
|
|
||||||
center .error { padding:8px !important; padding-left:26px !important; padding-right:20px; width:inherit; max-width:450px;color:#552323 !important; font-size:14px; border-radius:8px; text-align: left;}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* ============================================================================== */
|
|
||||||
/* Styles to hide objects */
|
|
||||||
/* ============================================================================== */
|
|
||||||
|
|
||||||
.hideobject { display:none; }
|
|
||||||
<?php if (! empty($dol_optimize_smallscreen)) { ?>
|
|
||||||
.hideonsmartphone { display: none; }
|
|
||||||
.noenlargeonsmartphone { width : 50px !important; display: inline !important; }
|
|
||||||
<?php } ?>
|
|
||||||
.linkobject { cursor:pointer; }
|
|
||||||
|
|
||||||
|
|
||||||
/* For dragging lines */
|
|
||||||
|
|
||||||
.dragClass {color:#333333;}
|
|
||||||
td.showDragHandle {cursor:move;}
|
|
||||||
.tdlineupdown {white-space:nowrap;}
|
|
||||||
|
|
||||||
|
|
||||||
/* ============================================================================== */
|
|
||||||
/* Menu top et 1ère ligne tableau */
|
|
||||||
/* ============================================================================== */
|
|
||||||
|
|
||||||
div.tmenu {
|
|
||||||
<?php if (GETPOST("optioncss") == 'print') {?>
|
|
||||||
display:none;
|
|
||||||
<?php } else {?>
|
|
||||||
position:relative;
|
|
||||||
display:block;
|
|
||||||
margin:0;
|
|
||||||
padding:0;
|
|
||||||
padding-left:1em;
|
|
||||||
top:0;
|
|
||||||
left:0;
|
|
||||||
right:0;
|
|
||||||
white-space:nowrap;
|
|
||||||
height:36px;
|
|
||||||
<?php if ($conf->browser->name != 'ie') echo "line-height:36px; /* disabled for ie9 */ \n"; ?>
|
|
||||||
background:#333333;
|
|
||||||
background-image:linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
|
||||||
background-image:-o-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
|
||||||
background-image:-moz-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
|
||||||
background-image:-webkit-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
|
||||||
background-image:-ms-linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
|
||||||
background-image:-webkit-gradient(
|
|
||||||
linear,
|
|
||||||
left top,
|
|
||||||
left bottom,
|
|
||||||
color-stop(0, rgba(255,255,255,.3)),
|
|
||||||
color-stop(1, rgba(0,0,0,.3))
|
|
||||||
);
|
|
||||||
border-bottom:solid 1px rgba(0,0,0,.8);
|
|
||||||
box-shadow:0 0 6px rgba(0,0,0,.4) !important;
|
|
||||||
z-index:100;
|
|
||||||
<?php } ?>
|
|
||||||
}
|
|
||||||
|
|
||||||
div.tmenu a {
|
|
||||||
font-weight:normal;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.tmenu li {
|
|
||||||
display:inline-table;
|
|
||||||
margin-right:1em;
|
|
||||||
text-transform:uppercase;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.tmenu li a {color:#cccccc;}
|
|
||||||
div.tmenu li a:hover {color:rgba(255,255,255,.2);}
|
|
||||||
|
|
||||||
div.tmenu ul li a.tmenusel {/* texte du menu principal sélectionné */
|
|
||||||
color:#ffffff;
|
|
||||||
font-weight:bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
.tmenudisabled { color:#808080 !important; cursor: not-allowed; }
|
|
||||||
|
|
||||||
/* --- end nav --- */
|
|
||||||
|
|
||||||
/* Login */
|
|
||||||
|
|
||||||
div.login_block {
|
div.login_block {
|
||||||
position:absolute;
|
position:absolute;
|
||||||
top:5px;
|
top:5px;
|
||||||
@ -438,19 +482,23 @@ div.login_block table {
|
|||||||
|
|
||||||
div.login {
|
div.login {
|
||||||
white-space:nowrap;
|
white-space:nowrap;
|
||||||
padding:8px 0px 0px 0px;
|
padding: <?php echo ($conf->dol_optimize_smallscreen?'0':'8')?>px 0px 0px 0px;
|
||||||
margin:0px 0px 0px 8px;
|
margin:0px 0px 0px 8px;
|
||||||
font-weight:bold;
|
font-weight:bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
img.login, img.printer, img.entity {
|
img.login, img.printer, img.entity {
|
||||||
padding:8px 0px 0px 0px;
|
padding: <?php echo ($conf->dol_optimize_smallscreen?'0':'8')?>px 0px 0px 0px;
|
||||||
margin:0px 0px 0px 8px;
|
margin:0px 0px 0px 8px;
|
||||||
text-decoration:none;
|
text-decoration:none;
|
||||||
color:#ffffff;
|
color: white;
|
||||||
font-weight:bold;
|
font-weight:bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
div.login_main_home {
|
||||||
|
color: #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
/* Menu gauche */
|
/* Menu gauche */
|
||||||
@ -461,6 +509,9 @@ div.vmenu {
|
|||||||
display:none;
|
display:none;
|
||||||
<?php } else {?>
|
<?php } else {?>
|
||||||
width:170px;
|
width:170px;
|
||||||
|
-moz-box-shadow: 4px 4px 4px #CCC;
|
||||||
|
-webkit-box-shadow: 4px 4px 4px #CCC;
|
||||||
|
box-shadow: 4px 4px 4px #CCC;
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -773,8 +824,11 @@ div.tabs {
|
|||||||
div.tabBar {
|
div.tabBar {
|
||||||
background-color:#ffffff;
|
background-color:#ffffff;
|
||||||
padding:6px;
|
padding:6px;
|
||||||
margin:3px 0px 5px;
|
margin:3px 0px 14px 0px;
|
||||||
border:1px solid #bbbbbb;
|
border:1px solid #bbbbbb;
|
||||||
|
-moz-box-shadow: 4px 4px 4px #DDD;
|
||||||
|
-webkit-box-shadow: 4px 4px 4px #DDD;
|
||||||
|
box-shadow: 4px 4px 4px #DDD;
|
||||||
}
|
}
|
||||||
|
|
||||||
div.tabBar table.notopnoleftnoright {
|
div.tabBar table.notopnoleftnoright {
|
||||||
@ -1066,7 +1120,7 @@ table.liste {
|
|||||||
|
|
||||||
table.liste td {padding:1px 2px 1px 0px;}
|
table.liste td {padding:1px 2px 1px 0px;}
|
||||||
|
|
||||||
tr.liste_titre, tr.box_titre {
|
div.liste_titre, tr.liste_titre, tr.box_titre {
|
||||||
padding:4px;
|
padding:4px;
|
||||||
background-color:rgba(0,0,0,.2);
|
background-color:rgba(0,0,0,.2);
|
||||||
background-image:linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
background-image:linear-gradient(top, rgba(255,255,255,.3) 0%, rgba(0,0,0,.3) 100%);
|
||||||
@ -1116,13 +1170,13 @@ tr.impair td, tr.pair td {padding:1px 1px 1px 2px;}
|
|||||||
tr.impair table.nobordernopadding td, tr.pair table.nobordernopadding td {padding:1px 0px;}
|
tr.impair table.nobordernopadding td, tr.pair table.nobordernopadding td {padding:1px 0px;}
|
||||||
|
|
||||||
.impair {
|
.impair {
|
||||||
background:#f4f4f4;
|
background:#fdfdfd;
|
||||||
font-family:<?php print $fontlist ?>;
|
font-family:<?php print $fontlist ?>;
|
||||||
border:0px;
|
border:0px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.pair {
|
.pair {
|
||||||
background:#eaeaea;
|
background:#f4f4f4;
|
||||||
font-family:<?php print $fontlist ?>;
|
font-family:<?php print $fontlist ?>;
|
||||||
border:0px;
|
border:0px;
|
||||||
}
|
}
|
||||||
@ -1147,12 +1201,12 @@ tr.impair table.nobordernopadding td, tr.pair table.nobordernopadding td {paddin
|
|||||||
}
|
}
|
||||||
|
|
||||||
tr.box_impair {
|
tr.box_impair {
|
||||||
background:#f4f4f4;
|
background:#fdfdfd;
|
||||||
font-family:<?php print $fontlist ?>;
|
font-family:<?php print $fontlist ?>;
|
||||||
}
|
}
|
||||||
|
|
||||||
tr.box_pair {
|
tr.box_pair {
|
||||||
background:#eaeaea;
|
background:#f4f4f4;
|
||||||
font-family:<?php print $fontlist ?>;
|
font-family:<?php print $fontlist ?>;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1423,7 +1477,7 @@ td.dpHead {
|
|||||||
|
|
||||||
/* Jour courant */
|
/* Jour courant */
|
||||||
.dpSelected {
|
.dpSelected {
|
||||||
background-color:#a61111;
|
background-color:#0B63A2;
|
||||||
color:#ffffff;
|
color:#ffffff;
|
||||||
font-weight:bold;
|
font-weight:bold;
|
||||||
}
|
}
|
||||||
@ -1468,7 +1522,7 @@ td.dpHead {
|
|||||||
padding:0px 2px;
|
padding:0px 2px;
|
||||||
font-size:9px;
|
font-size:9px;
|
||||||
border-width:0px;
|
border-width:0px;
|
||||||
color:#a61111;
|
color:#0B63A2;
|
||||||
vertical-align:middle;
|
vertical-align:middle;
|
||||||
cursor:pointer;
|
cursor:pointer;
|
||||||
}
|
}
|
||||||
@ -1499,17 +1553,9 @@ table.cal_month { border-spacing: 0px; }
|
|||||||
.cal_current_month_right { border-right: solid 1px #E0E0E0; }
|
.cal_current_month_right { border-right: solid 1px #E0E0E0; }
|
||||||
.cal_other_month_right { border-right: solid 1px #C0C0C0; }
|
.cal_other_month_right { border-right: solid 1px #C0C0C0; }
|
||||||
|
|
||||||
.cal_other_month {
|
.cal_other_month { opacity: 0.6; background: #EAEAEA; padding-<?php print $left; ?>: 2px; padding-<?php print $right; ?>: 1px; padding-top: 0px; padding-bottom: 0px; }
|
||||||
background:#dddddd;
|
.cal_past_month { opacity: 0.6; background: #EEEEEE; padding-<?php print $left; ?>: 2px; padding-<?php print $right; ?>: 1px; padding-top: 0px; padding-bottom: 0px; }
|
||||||
}
|
.cal_current_month { background: #FFFFFF; border-left: solid 1px #E0E0E0; padding-<?php print $left; ?>: 2px; padding-<?php print $right; ?>: 1px; padding-top: 0px; padding-bottom: 0px; }
|
||||||
|
|
||||||
.cal_past_month {
|
|
||||||
background:#eeeeee;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cal_current_month {
|
|
||||||
background:#ffffff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cal_today {
|
.cal_today {
|
||||||
background:#ffffff;
|
background:#ffffff;
|
||||||
@ -1518,37 +1564,19 @@ table.cal_month { border-spacing: 0px; }
|
|||||||
|
|
||||||
div.dayevent table.nobordernopadding tr td {padding:1px;}
|
div.dayevent table.nobordernopadding tr td {padding:1px;}
|
||||||
|
|
||||||
table.cal_event {
|
table.cal_event { border: none; border-collapse: collapse; margin-bottom: 1px; -webkit-border-radius: 6px; border-radius: 6px;
|
||||||
border-collapse:collapse;
|
-webkit-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.25);
|
||||||
margin-bottom:1px;
|
moz-box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.25);
|
||||||
|
box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25), 0 1px 2px rgba(0, 0, 0, 0.25);
|
||||||
|
background: -webkit-gradient(linear, left top, left bottom, from(#006aac), to(#00438d));
|
||||||
}
|
}
|
||||||
|
table.cal_event td { border: none; padding-<?php print $left; ?>: 2px; padding-<?php print $right; ?>: 2px; padding-top: 0px; padding-bottom: 0px; }
|
||||||
ul.cal_event { padding-right: 2px; padding-top: 1px; border: none; list-style-type: none; margin: 0 auto; padding-left: 0px; padding-start: 0px; -khtml-padding-start: 0px; -o-padding-start: 0px; -webkit-padding-start: 0px; -webkit-padding-start: 0px; }
|
ul.cal_event { padding-right: 2px; padding-top: 1px; border: none; list-style-type: none; margin: 0 auto; padding-left: 0px; padding-start: 0px; -khtml-padding-start: 0px; -o-padding-start: 0px; -moz-padding-start: 0px; -webkit-padding-start: 0px; }
|
||||||
li.cal_event { border: none; list-style-type: none; }
|
li.cal_event { border: none; list-style-type: none; }
|
||||||
|
.cal_event a:link { color: #111111; font-size: 11px; font-weight: normal !important; }
|
||||||
.cal_event a:link {
|
.cal_event a:visited { color: #111111; font-size: 11px; font-weight: normal !important; }
|
||||||
color:#232323;
|
.cal_event a:active { color: #111111; font-size: 11px; font-weight: normal !important; }
|
||||||
font-size:11px;
|
.cal_event a:hover { color: #111111; font-size: 11px; font-weight: normal !important; color:rgba(255,255,255,.75); }
|
||||||
font-weight:normal !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cal_event a:visited {
|
|
||||||
color:#232323;
|
|
||||||
font-size:11px;
|
|
||||||
font-weight:normal !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cal_event a:active {
|
|
||||||
color:#232323;
|
|
||||||
font-size:11px;
|
|
||||||
font-weight:normal !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
.cal_event a:hover {
|
|
||||||
color:rgba(255,255,255,.75);
|
|
||||||
font-size:11px;
|
|
||||||
font-weight:normal !important;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
|
|||||||
@ -58,6 +58,8 @@ if (GETPOST('theme')) $conf->theme=GETPOST('theme'); // If theme was forced on
|
|||||||
$langs->load("main",0,1);
|
$langs->load("main",0,1);
|
||||||
$right=($langs->trans("DIRECTION")=='rtl'?'left':'right');
|
$right=($langs->trans("DIRECTION")=='rtl'?'left':'right');
|
||||||
$left=($langs->trans("DIRECTION")=='rtl'?'right':'left');
|
$left=($langs->trans("DIRECTION")=='rtl'?'right':'left');
|
||||||
|
$fontsize=empty($conf->dol_optimize_smallscreen)?'12':'12';
|
||||||
|
$fontsizesmaller=empty($conf->dol_optimize_smallscreen)?'11':'11';
|
||||||
|
|
||||||
$path=''; // This value may be used in future for external module to overwrite theme
|
$path=''; // This value may be used in future for external module to overwrite theme
|
||||||
$theme='eldy'; // Value of theme
|
$theme='eldy'; // Value of theme
|
||||||
@ -198,7 +200,7 @@ if (! empty($conf->dol_optimize_smallscreen)) $fontsize=11;
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
/* Styles par defaut */
|
/* Default styles */
|
||||||
/* ============================================================================== */
|
/* ============================================================================== */
|
||||||
|
|
||||||
body {
|
body {
|
||||||
@ -304,8 +306,8 @@ input[type=image] { background-color: transparent; border: none; box-shadow: non
|
|||||||
box-shadow: 4px 4px 4px #CCC;
|
box-shadow: 4px 4px 4px #CCC;
|
||||||
}
|
}
|
||||||
form {
|
form {
|
||||||
padding: 0em 0em 0em 0em;
|
padding:0px;
|
||||||
margin: 0em 0em 0em 0em;
|
margin:0px;
|
||||||
}
|
}
|
||||||
div.float
|
div.float
|
||||||
{
|
{
|
||||||
@ -1317,11 +1319,14 @@ div.tabsAction {
|
|||||||
|
|
||||||
|
|
||||||
a.tabTitle {
|
a.tabTitle {
|
||||||
background: #657090;
|
/* background: #657090;
|
||||||
color: white;
|
color: white;*/
|
||||||
|
color:rgba(0,0,0,.5);
|
||||||
|
margin-right:10px;
|
||||||
|
text-shadow:1px 1px 1px #ffffff;
|
||||||
font-family: <?php print $fontlist ?>;
|
font-family: <?php print $fontlist ?>;
|
||||||
font-weight: normal;
|
font-weight: normal;
|
||||||
padding: 0px 6px 2px 6px;
|
padding: 4px 6px 2px 6px;
|
||||||
margin: 0px 6px;
|
margin: 0px 6px;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@ -1329,7 +1334,7 @@ a.tabTitle {
|
|||||||
|
|
||||||
a.tab:link, a.tab:visited, a.tab:hover, a.tab#active {
|
a.tab:link, a.tab:visited, a.tab:hover, a.tab#active {
|
||||||
font-family: <?php print $fontlist ?>;
|
font-family: <?php print $fontlist ?>;
|
||||||
padding: 2px 6px 2px 6px;
|
padding: 4px 6px 2px 6px;
|
||||||
margin: 0em 0.2em;
|
margin: 0em 0.2em;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
white-space: nowrap;
|
white-space: nowrap;
|
||||||
@ -1364,6 +1369,7 @@ a.tab#active {
|
|||||||
a.tab:link, a.tab:visited, a.tab:hover, a.tab#active
|
a.tab:link, a.tab:visited, a.tab:hover, a.tab#active
|
||||||
{
|
{
|
||||||
color: #<?php echo $colortextmain; ?>;
|
color: #<?php echo $colortextmain; ?>;
|
||||||
|
font-weight: normal !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
a.tabimage {
|
a.tabimage {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user