Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into develop
This commit is contained in:
commit
4d4512fadd
13
ChangeLog
13
ChangeLog
@ -6,17 +6,18 @@ English Dolibarr ChangeLog
|
||||
For users:
|
||||
- New: Update ckeditor to version 4.
|
||||
- New: Add form "search customer order" on commercial main page.
|
||||
- New: Can input barcode during product creation step.
|
||||
- New: Add autonumbering of barcode value for products.
|
||||
- New: Can create contract from an order.
|
||||
- New: Add list of orders products in tab "consumption" on thirdparties.
|
||||
- New: Add graph stats for suppliers orders in tab "stats" on products.
|
||||
- New: Add option MAIN_HIDE_INACTIVETAB_ON_PRINT to hide inactive tabs when you
|
||||
use the "print" view on screen.
|
||||
- New: Add a page/tool for mass barcode generation.
|
||||
- New: Add option MAIN_AUTO_TIMESTAMP_IN_PUBLIC_NOTES and MAIN_AUTO_TIMESTAMP_IN_PRIVATE_NOTES
|
||||
to automatically add timestamp and user line into edition field when editing a note.
|
||||
- New: Add button cancel into edition of notes.
|
||||
- New: Improved Barcode module:
|
||||
Can input barcode during product creation step.
|
||||
Add autonumbering of barcode value for products.
|
||||
Add a page/tool for mass barcode generation.
|
||||
- New: Improved Opensurvey module:
|
||||
Added options to disable comments and disable public votes.
|
||||
Limit dates use calendar popup.
|
||||
@ -39,9 +40,9 @@ For users:
|
||||
- New: Add manager name (ceo, director, president...) into main company information page.
|
||||
- New: Add field url as product properties.
|
||||
- New: More options to create a credit note (can be filled autatically according to remain to pay).
|
||||
- New: Can define custom fields for catagories.
|
||||
- New: Can define custom fields for categories.
|
||||
- Fix: Project Task numbering customs rule works.
|
||||
- Fix: Add actions events not implemented
|
||||
- Fix: Add actions events not implemented.
|
||||
|
||||
TODO
|
||||
- New: Predefined product and free product use same form.
|
||||
@ -113,6 +114,8 @@ Fix: [ bug #1240 ] traduction.
|
||||
Fix: [ bug #1238 ] When creating accompte with a %, free product are used for calculation.
|
||||
Fix: [ bug #1280 ] service with not end of date was tagged as expired.
|
||||
Fix: [ bug #1295 ] Error when creating an agenda extrafield with a number as reference
|
||||
Fix: [ bug #1306 ] Fatal error when adding an external calendar
|
||||
New: Added es_CL language
|
||||
|
||||
***** ChangeLog for 3.5 compared to 3.4.* *****
|
||||
For users:
|
||||
|
||||
13
build/debian/README.Debian
Normal file
13
build/debian/README.Debian
Normal file
@ -0,0 +1,13 @@
|
||||
Information about Dolibarr in Debian
|
||||
------------------------------------
|
||||
|
||||
The Debian package provides integration with apache2 and lighttpd.
|
||||
If you have one of those servers installed, then Dolibarr is immediately
|
||||
accessible at http://localhost/dolibarr/
|
||||
|
||||
But it won't be usable until you configure it via
|
||||
http://localhost/dolibarr/install/
|
||||
|
||||
To complete the setup process you will need the MySQL root credentials
|
||||
because the Dolibarr installer will create the database and the dedicated user
|
||||
for you.
|
||||
@ -1,12 +0,0 @@
|
||||
==================================================================
|
||||
Dolibarr - Web based software to manage a small company or foundation
|
||||
==================================================================
|
||||
|
||||
|
||||
Note for package maintainers
|
||||
----------------------------
|
||||
This file explains how to modify official sources (from http://www.dolibarr.org)
|
||||
to have ready to use source files to build a debian package.
|
||||
|
||||
All changes are included into patch file
|
||||
build/debian/patches
|
||||
@ -5,6 +5,13 @@ dolibarr (3.6.0-1) unstable; urgency=low
|
||||
|
||||
-- Laurent Destailleur (eldy) <eldy@users.sourceforge.net> Sat, 8 Feb 2014 12:00:00 +0100
|
||||
|
||||
dolibarr (3.5.2-3) unstable; urgency=low
|
||||
|
||||
[ Laurent Destailleur (eldy) ]
|
||||
* New upstream release.
|
||||
|
||||
-- Laurent Destailleur (eldy) <eldy@users.sourceforge.net> Fri, 14 March 2014 12:00:00 +0100
|
||||
|
||||
dolibarr (3.5.1-3) unstable; urgency=low
|
||||
|
||||
[ Laurent Destailleur (eldy) ]
|
||||
|
||||
@ -1,10 +0,0 @@
|
||||
Document: dolibarr
|
||||
Title: Dolibarr ERP & CRM documentation
|
||||
Author: Dolibarr team
|
||||
Abstract: This documentation covers the install, use and administration of
|
||||
Dolibarr ERP & CRM software.
|
||||
Section: Office
|
||||
|
||||
Format: HTML
|
||||
Index: /usr/share/doc/dolibarr/index.html
|
||||
Files: /usr/share/doc/dolibarr/*.html
|
||||
2
build/debian/dolibarr.docs
Normal file
2
build/debian/dolibarr.docs
Normal file
@ -0,0 +1,2 @@
|
||||
README.md
|
||||
README-FR.md
|
||||
@ -6,8 +6,6 @@ debian/lighttpd/50-dolibarr.conf etc/lighttpd/conf-available/
|
||||
debian/install.forced.php.install etc/dolibarr/
|
||||
htdocs usr/share/dolibarr/
|
||||
scripts usr/share/dolibarr/
|
||||
changelog usr/share/doc/dolibarr/
|
||||
README usr/share/doc/dolibarr/
|
||||
doc/install usr/share/doc/dolibarr/
|
||||
doc/user usr/share/doc/dolibarr/
|
||||
doc/index.html usr/share/doc/dolibarr/
|
||||
@ -9,6 +9,12 @@ export DH_OPTIONS=-v
|
||||
|
||||
%:
|
||||
dh $@
|
||||
|
||||
override_dh_auto_clean:
|
||||
# Do nothing. Added to disable launchpad to use bugged dh_auto_clean search for ant
|
||||
|
||||
override_dh_auto_build:
|
||||
# Do nothing. Added to disable launchpad to use bugged dh_auto_build search for ant
|
||||
|
||||
override_dh_install:
|
||||
dh_install
|
||||
|
||||
@ -81,7 +81,7 @@ If you want to build/test package locally:
|
||||
bzr init
|
||||
bzr add
|
||||
bzr commit -m "Init control files"
|
||||
bzr push lp:~yourlogin/+junk/debian-[dev|beta|stable] (put here any branch name)
|
||||
bzr push lp:~yourlogin/+junk/debian-[dev|beta|stable] (put here any branch name or just bzr push if into a known branch)
|
||||
- or download it from launchpad bazaar:
|
||||
cd bzr
|
||||
bzr branch lp:~yourlogin/+junk/debian-[dev|beta|stable]
|
||||
|
||||
@ -365,7 +365,6 @@ if ($nboftargetok) {
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build.xml`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/quickbuild.xml`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/pom.xml`;
|
||||
$ret=`mv $BUILDROOT/$PROJECT/README.md $BUILDROOT/$PROJECT/README`;
|
||||
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT/build/html`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT/build/Doli*-*`;
|
||||
@ -708,7 +707,7 @@ if ($nboftargetok) {
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/copyright`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.config`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.desktop`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.doc-base`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.docs`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.install`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.lintian-overrides`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.postrm`;
|
||||
@ -716,6 +715,7 @@ if ($nboftargetok) {
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.templates`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/dolibarr.templates.futur`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/rules`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/README.Debian`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/README.howto`;
|
||||
$ret=`rm -f $BUILDROOT/$PROJECT.tmp/build/debian/watch`;
|
||||
$ret=`rm -fr $BUILDROOT/$PROJECT.tmp/build/doap`;
|
||||
@ -744,11 +744,10 @@ if ($nboftargetok) {
|
||||
$ret=`cp -f "$SOURCE/build/debian/control" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/copyright" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/dolibarr.desktop" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/dolibarr.doc-base" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/dolibarr.docs" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/dolibarr.install" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/dolibarr.lintian-overrides" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/dolibarr.xpm" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/README.source" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/rules" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -f "$SOURCE/build/debian/watch" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
$ret=`cp -fr "$SOURCE/build/debian/patches" "$BUILDROOT/$PROJECT.tmp/debian"`;
|
||||
|
||||
@ -30,7 +30,7 @@ return "Regis Houssin";
|
||||
# script_dolibarr_versions()
|
||||
sub script_dolibarr_versions
|
||||
{
|
||||
return ( "3.6.0", "3.5.1", "3.5.0", "3.4.1", "3.4.0", "3.3.3", "3.3.2", "3.3.1", "3.3.0", "3.2.1", "3.1.1" );
|
||||
return ( "3.6.0", "3.5.2", "3.5.1", "3.5.0", "3.4.1", "3.4.0", "3.3.3", "3.3.2", "3.3.1", "3.3.0", "3.2.1", "3.1.1" );
|
||||
}
|
||||
|
||||
sub script_dolibarr_category
|
||||
|
||||
@ -334,5 +334,11 @@ fi
|
||||
* Fri Feb 7 2014 Laurent Destailleur 3.6.0-0.2.b
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 14 2014 Laurent Destailleur 3.5.2-0.3
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 7 2014 Laurent Destailleur 3.5.1-0.3
|
||||
- Upstream release
|
||||
|
||||
* Mon Dec 30 2013 Laurent Destailleur 3.5.0-0.3
|
||||
- Initial version (#723326)
|
||||
|
||||
@ -562,5 +562,11 @@ fi
|
||||
* Mon Feb 7 2014 Laurent Destailleur 3.6.0-0.2.b
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 14 2014 Laurent Destailleur 3.5.2-0.3
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 7 2014 Laurent Destailleur 3.5.1-0.3
|
||||
- Upstream release
|
||||
|
||||
* Mon Dec 30 2013 Laurent Destailleur 3.5.0-0.3
|
||||
- Initial version (#723326)
|
||||
|
||||
@ -339,5 +339,11 @@ fi
|
||||
* Mon Feb 7 2014 Laurent Destailleur 3.6.0-0.2.b
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 14 2014 Laurent Destailleur 3.5.2-0.3
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 7 2014 Laurent Destailleur 3.5.1-0.3
|
||||
- Upstream release
|
||||
|
||||
* Mon Dec 30 2013 Laurent Destailleur 3.5.0-0.3
|
||||
- Initial version (#723326)
|
||||
|
||||
@ -349,5 +349,11 @@ fi
|
||||
* Mon Feb 7 2014 Laurent Destailleur 3.6.0-0.2.b
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 14 2014 Laurent Destailleur 3.5.2-0.3
|
||||
- Upstream release
|
||||
|
||||
* Fri Feb 7 2014 Laurent Destailleur 3.5.1-0.3
|
||||
- Upstream release
|
||||
|
||||
* Mon Dec 30 2013 Laurent Destailleur 3.5.0-0.3
|
||||
- Initial version (#723326)
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2008-2011 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2011-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2011-2014 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
|
||||
@ -28,6 +28,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formadmin.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/agenda.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||
|
||||
if (!$user->admin)
|
||||
accessforbidden();
|
||||
@ -228,4 +229,4 @@ dol_fiche_end();
|
||||
llxFooter();
|
||||
|
||||
$db->close();
|
||||
?>
|
||||
?>
|
||||
|
||||
@ -155,7 +155,8 @@ print '<tr '.$bc[$var].'><td width="300"> => price(1234.56)</td><td>'.pric
|
||||
// Timezone
|
||||
$txt =$langs->trans("OSTZ").' (variable system TZ): '.(! empty($_ENV["TZ"])?$_ENV["TZ"]:$langs->trans("NotDefined")).'<br>'."\n";
|
||||
$txt.=$langs->trans("PHPTZ").' (php.ini date.timezone): '.(ini_get("date.timezone")?ini_get("date.timezone"):$langs->trans("NotDefined")).''."<br>\n"; // date.timezone must be in valued defined in http://fr3.php.net/manual/en/timezones.europe.php
|
||||
$txt.=$langs->trans("YouCanEditPHPTZ");
|
||||
$txt.=$langs->trans("Dolibarr constant MAIN_SERVER_TZ").': '.(empty($conf->global->MAIN_SERVER_TZ)?$langs->trans("NotDefined"):$conf->global->MAIN_SERVER_TZ);
|
||||
//$txt.=$langs->trans("YouCanEditPHPTZ"); // deprecated
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td width="300">'.$langs->trans("CurrentTimeZone").'</td><td>'; // Timezone server PHP
|
||||
$a=getServerTimeZoneInt('now');
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -1472,7 +1472,8 @@ class Facture extends CommonInvoice
|
||||
}
|
||||
|
||||
/**
|
||||
* Tag la facture comme paye completement (close_code non renseigne) ou partiellement (close_code renseigne) + appel trigger BILL_PAYED
|
||||
* Tag la facture comme paye completement (si close_code non renseigne) => this->fk_statut=2, this->paye=1
|
||||
* ou partiellement (si close_code renseigne) + appel trigger BILL_PAYED => this->fk_statut=2, this->paye stay 0
|
||||
*
|
||||
* @param User $user Objet utilisateur qui modifie
|
||||
* @param string $close_code Code renseigne si on classe a payee completement alors que paiement incomplet (cas escompte par exemple)
|
||||
@ -1496,6 +1497,7 @@ class Facture extends CommonInvoice
|
||||
if ($close_note) $sql.= ", close_note='".$this->db->escape($close_note)."'";
|
||||
$sql.= ' WHERE rowid = '.$this->id;
|
||||
|
||||
dol_syslog(get_class($this)."::set_paid sql=".$sql, LOG_DEBUG);
|
||||
$resql = $this->db->query($sql);
|
||||
if ($resql)
|
||||
{
|
||||
@ -1511,8 +1513,7 @@ class Facture extends CommonInvoice
|
||||
else
|
||||
{
|
||||
$error++;
|
||||
$this->error=$this->db->error();
|
||||
dol_print_error($this->db);
|
||||
$this->error=$this->db->lasterror();
|
||||
}
|
||||
|
||||
if (! $error)
|
||||
@ -2075,7 +2076,7 @@ class Facture extends CommonInvoice
|
||||
$product=new Product($this->db);
|
||||
$result=$product->fetch($fk_product);
|
||||
$product_type=$product->type;
|
||||
|
||||
|
||||
if($conf->global->STOCK_MUST_BE_ENOUGH_FOR_INVOICE && $product_type == 0 && $product->stock_reel < $qty) {
|
||||
$this->error=$langs->trans('ErrorStockIsNotEnough');
|
||||
$this->db->rollback();
|
||||
|
||||
@ -200,7 +200,12 @@ class Conf
|
||||
}
|
||||
//var_dump($this->modules);
|
||||
//var_dump($this->modules_parts['theme']);
|
||||
|
||||
|
||||
// If you can't set timezone of your PHP, set this constant. Better is to set it to UTC.
|
||||
// In future, this constant will be forced to 'UTC' so PHP server timezone will not have effect anymore.
|
||||
//$this->global->MAIN_SERVER_TZ='Europe/Paris';
|
||||
if (! empty($this->global->MAIN_SERVER_TZ) && $this->global->MAIN_SERVER_TZ != 'auto') date_default_timezone_set($this->global->MAIN_SERVER_TZ);
|
||||
|
||||
// Object $mc
|
||||
if (! defined('NOREQUIREMC') && ! empty($this->multicompany->enabled))
|
||||
{
|
||||
|
||||
@ -764,8 +764,9 @@ class FormFile
|
||||
if (empty($relativepath))
|
||||
{
|
||||
$relativepath=(! empty($object->ref)?dol_sanitizeFileName($object->ref):'').'/';
|
||||
if ($object->element == 'invoice_supplier') $relativepath=get_exdir($object->id,2).$relativepath;
|
||||
if ($object->element == 'member') $relativepath=get_exdir($object->id,2).$relativepath;
|
||||
if ($object->element == 'invoice_supplier') $relativepath=get_exdir($object->id,2).$relativepath; // TODO Call using a defined value for $relativepath
|
||||
if ($object->element == 'member') $relativepath=get_exdir($object->id,2).$relativepath; // TODO Call using a defined value for $relativepath
|
||||
if ($object->element == 'project_task') $relativepath='Call_not_supported_._Call_function_using_a_defined_relative_path_.';
|
||||
}
|
||||
|
||||
$var=!$var;
|
||||
@ -1052,9 +1053,10 @@ class FormFile
|
||||
* @param int $permtodelete Deletion is allowed
|
||||
* @param string $action Action
|
||||
* @param string $selected ???
|
||||
* @param string $param More param to add into URL
|
||||
* @return int Number of links
|
||||
*/
|
||||
public function listOfLinks($object, $permtodelete=1, $action=null, $selected=null)
|
||||
public function listOfLinks($object, $permtodelete=1, $action=null, $selected=null, $param='')
|
||||
{
|
||||
global $user, $conf, $langs, $user;
|
||||
global $bc;
|
||||
@ -1071,17 +1073,17 @@ class FormFile
|
||||
$sortfield = null;
|
||||
}
|
||||
$res = $link->fetchAll($links, $object->element, $object->id, $sortfield, $sortorder);
|
||||
$param = (isset($object->id)?'&id=' . $object->id : '');
|
||||
$param .= (isset($object->id)?'&id=' . $object->id : '');
|
||||
|
||||
// Show list of associated links
|
||||
print_titre($langs->trans("LinkedFiles"));
|
||||
|
||||
print '<form action="' . $_SERVER['PHP_SELF'] . '" method="POST">';
|
||||
print '<form action="' . $_SERVER['PHP_SELF'] . ($param?'?'.$param:'') . '" method="POST">';
|
||||
|
||||
print '<table width="100%" class="liste">';
|
||||
print '<tr class="liste_titre">';
|
||||
print_liste_field_titre(
|
||||
$langs->trans("Documents2"),
|
||||
$langs->trans("Links"),
|
||||
$_SERVER['PHP_SELF'],
|
||||
"name",
|
||||
"",
|
||||
@ -1135,34 +1137,34 @@ class FormFile
|
||||
print '<input type="hidden" name="action" value="confirm_updateline">';
|
||||
print $langs->trans('Link') . ': <input type="text" name="link" size="50" value="' . $link->url . '">';
|
||||
print '</td>';
|
||||
print '<td align="right">';
|
||||
print '<td>';
|
||||
print $langs->trans('Label') . ': <input type="text" name="label" value="' . $link->label . '">';
|
||||
print '</td>';
|
||||
print '<td align="center">' . dol_print_date(dol_now(), "dayhour", "tzuser") . '</td>';
|
||||
print '<td align="right"></td>';
|
||||
print '<td align="right" colspan="2"><input type="submit" name="save" class="button" value="' . $langs->trans('Save') . '">';
|
||||
print '<input type="submit" name="cancel" class="button" value="' . $langs->trans('Cancel') . '">';
|
||||
print '<td align="right" colspan="2">';
|
||||
print '<input type="submit" name="save" class="button" value="' . dol_escape_htmltag($langs->trans('Save')) . '">';
|
||||
print '<input type="submit" name="cancel" class="button" value="' . dol_escape_htmltag($langs->trans('Cancel')) . '">';
|
||||
print '</td>';
|
||||
}
|
||||
else {
|
||||
else
|
||||
{
|
||||
print '<td>';
|
||||
print '<a data-ajax="false" href="'. $link->url . '" target="_blank">';
|
||||
print '<a data-ajax="false" href="' . $link->url . '" target="_blank">';
|
||||
print $link->label;
|
||||
print '</a>';
|
||||
print "</td>\n";
|
||||
print '</td>'."\n";
|
||||
print '<td align="right"></td>';
|
||||
print '<td align="center">' . dol_print_date($link->datea, "dayhour", "tzuser") . '</td>';
|
||||
print '<td align="center"></td>';
|
||||
print '<td align="right" colspan="2">';
|
||||
print '<a href="' . $_SERVER['PHP_SELF'] . '?action=update&linkid=' . $link->id
|
||||
. '&id=' . $object->id . '" class="editfilelink" >' . img_edit().'</a>';
|
||||
print '<a href="' . $_SERVER['PHP_SELF'] . '?action=update&linkid=' . $link->id . $param . '" class="editfilelink" >' . img_edit() . '</a>'; // id= is included into $param
|
||||
if ($permtodelete) {
|
||||
print ' <a href="'. $_SERVER['PHP_SELF'] .'?action=delete&linkid=' . $link->id
|
||||
. '&id=' . $object->id . '" class="deletefilelink" >' . img_delete() . '</a>';
|
||||
print ' <a href="'. $_SERVER['PHP_SELF'] .'?action=delete&linkid=' . $link->id . $param . '" class="deletefilelink">' . img_delete() . '</a>'; // id= is included into $param
|
||||
} else {
|
||||
print ' ';
|
||||
}
|
||||
print "</td>";
|
||||
print '</td>';
|
||||
}
|
||||
print "</tr>\n";
|
||||
}
|
||||
|
||||
@ -69,13 +69,11 @@ function get_tz_array()
|
||||
*/
|
||||
function getServerTimeZoneString()
|
||||
{
|
||||
if (function_exists('date_default_timezone_get')) return date_default_timezone_get();
|
||||
else return '';
|
||||
return @date_default_timezone_get();
|
||||
}
|
||||
|
||||
/**
|
||||
* Return server timezone int.
|
||||
* If $conf->global->MAIN_OLD_DATE is set or PHP too old, we use old behaviour: All convertions does not take care of dayling saving time.
|
||||
*
|
||||
* @param string $refgmtdate Reference period for timezone (timezone differs on winter and summer. May be 'now', 'winter' or 'summer')
|
||||
* @return int An offset in hour (+1 for Europe/Paris on winter and +2 for Europe/Paris on summer)
|
||||
@ -83,7 +81,7 @@ function getServerTimeZoneString()
|
||||
function getServerTimeZoneInt($refgmtdate='now')
|
||||
{
|
||||
global $conf;
|
||||
if (method_exists('DateTimeZone','getOffset') && empty($conf->global->MAIN_OLD_DATE))
|
||||
if (method_exists('DateTimeZone','getOffset'))
|
||||
{
|
||||
// Method 1 (include daylight)
|
||||
$gmtnow=dol_now('gmt'); $yearref=dol_print_date($gmtnow,'%Y'); $monthref=dol_print_date($gmtnow,'%m'); $dayref=dol_print_date($gmtnow,'%d');
|
||||
@ -97,11 +95,13 @@ function getServerTimeZoneInt($refgmtdate='now')
|
||||
}
|
||||
else
|
||||
{
|
||||
dol_print_error('','PHP version must be 5.3+');
|
||||
/*
|
||||
// Method 2 (does not include daylight, not supported by adodb)
|
||||
if ($refgmtdate == 'now')
|
||||
{
|
||||
if (ini_get("date.timezone")=='UTC') return 0;
|
||||
// We don't know server timezone string, so we don't know location, so we can't guess daylight. We assume we use same than client. Fix is to use new PHP with not MAIN_OLD_DATE.
|
||||
// We don't know server timezone string, so we don't know location, so we can't guess daylight. We assume we use same than client but this may be a bug.
|
||||
$gmtnow=dol_now('gmt'); $yearref=dol_print_date($gmtnow,'%Y'); $monthref=dol_print_date($gmtnow,'%m'); $dayref=dol_print_date($gmtnow,'%d');
|
||||
if (dol_stringtotime($_SESSION['dol_dst_first']) <= $gmtnow && $gmtnow < dol_stringtotime($_SESSION['dol_dst_second'])) $daylight=1;
|
||||
else $daylight=0;
|
||||
@ -111,7 +111,7 @@ function getServerTimeZoneInt($refgmtdate='now')
|
||||
elseif ($refgmtdate == 'summer')
|
||||
{
|
||||
if (ini_get("date.timezone")=='UTC') return 0;
|
||||
// We don't know server timezone string, so we don't know location, so we can't guess daylight. We assume we use same than client. Fix is to use new PHP with not MAIN_OLD_DATE.
|
||||
// We don't know server timezone string, so we don't know location, so we can't guess daylight. We assume we use same than client but this may be a bug.
|
||||
$gmtnow=dol_now('gmt'); $yearref=dol_print_date($gmtnow,'%Y'); $monthref='08'; $dayref='01';
|
||||
if (dol_stringtotime($_SESSION['dol_dst_first']) <= dol_stringtotime($yearref.'-'.$monthref.'-'.$dayref) && dol_stringtotime($yearref.'-'.$monthref.'-'.$dayref) < dol_stringtotime($_SESSION['dol_dst_second'])) $daylight=1;
|
||||
else $daylight=0;
|
||||
@ -119,49 +119,12 @@ function getServerTimeZoneInt($refgmtdate='now')
|
||||
return 'unknown'; // For true result
|
||||
}
|
||||
else $tmp=dol_mktime(0,0,0,1,1,1970);
|
||||
*/
|
||||
}
|
||||
$tz=round(($tmp<0?1:-1)*abs($tmp/3600));
|
||||
return $tz;
|
||||
}
|
||||
|
||||
/**
|
||||
* Return server timezone string
|
||||
*
|
||||
* @return string Parent company timezone string ('Europe/Paris')
|
||||
*
|
||||
function getParentCompanyTimeZoneString()
|
||||
{
|
||||
if (function_exists('date_default_timezone_get')) return date_default_timezone_get();
|
||||
else return '';
|
||||
}
|
||||
*/
|
||||
|
||||
/**
|
||||
* Return parent company timezone int.
|
||||
* If $conf->global->MAIN_NEW_DATE is set, we use new behaviour: All convertions take care of dayling saving time.
|
||||
*
|
||||
* @param string $refgmtdate Reference date for timezone (timezone differs on winter and summer)
|
||||
* @return int An offset in hour (+1 for Europe/Paris on winter and +2 for Europe/Paris on summer)
|
||||
*
|
||||
function getParentCompanyTimeZoneInt($refgmtdate='now')
|
||||
{
|
||||
global $conf;
|
||||
if (class_exists('DateTime') && empty($conf->global->MAIN_OLD_DATE))
|
||||
{
|
||||
// Method 1 (include daylight)
|
||||
$localtz = new DateTimeZone(getParentCompanyTimeZoneString());
|
||||
$localdt = new DateTime($refgmtdate, $localtz);
|
||||
$tmp=-1*$localtz->getOffset($localdt);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Method 2 (does not include daylight)
|
||||
$tmp=dol_mktime(0,0,0,1,1,1970);
|
||||
}
|
||||
$tz=($tmp<0?1:-1)*abs($tmp/3600);
|
||||
return $tz;
|
||||
}*/
|
||||
|
||||
|
||||
/**
|
||||
* Add a delay to a date
|
||||
@ -476,7 +439,7 @@ function dol_get_next_week($day, $week, $month, $year)
|
||||
*
|
||||
* @param int $year Year
|
||||
* @param int $month Month
|
||||
* @param boolean $gm False = Return date to compare with server TZ, True to compare with GM date.
|
||||
* @param mixed $gm False or 0 or 'server' = Return date to compare with server TZ, True or 1 to compare with GM date.
|
||||
* Exemple: dol_get_first_day(1970,1,false) will return -3600 with TZ+1, after a dol_print_date will return 1970-01-01 00:00:00
|
||||
* Exemple: dol_get_first_day(1970,1,true) will return 0 whatever is TZ, after a dol_print_date will return 1970-01-01 00:00:00
|
||||
* @return timestamp Date for first day
|
||||
@ -491,7 +454,7 @@ function dol_get_first_day($year,$month=1,$gm=false)
|
||||
*
|
||||
* @param int $year Year
|
||||
* @param int $month Month
|
||||
* @param boolean $gm False = Return date to compare with server TZ, True to compare with GM date.
|
||||
* @param boolean $gm False or 0 or 'server' = Return date to compare with server TZ, True or 1 to compare with GM date.
|
||||
* @return timestamp Date for first day
|
||||
*/
|
||||
function dol_get_last_day($year,$month=12,$gm=false)
|
||||
@ -518,7 +481,7 @@ function dol_get_last_day($year,$month=12,$gm=false)
|
||||
* @param int $day Day
|
||||
* @param int $month Month
|
||||
* @param int $year Year
|
||||
* @param int $gm False = Return date to compare with server TZ, True to compare with GM date.
|
||||
* @param int $gm False or 0 or 'server' = Return date to compare with server TZ, True or 1 to compare with GM date.
|
||||
* @return array year,month, week,first_day,prev_year,prev_month,prev_day
|
||||
*/
|
||||
function dol_get_first_day_week($day,$month,$year,$gm=false)
|
||||
|
||||
@ -997,7 +997,7 @@ function dol_getdate($timestamp,$fast=false)
|
||||
* @param int $month Month (1 to 12)
|
||||
* @param int $day Day (1 to 31)
|
||||
* @param int $year Year
|
||||
* @param int $gm 1=Input informations are GMT values, otherwise local to server TZ
|
||||
* @param mixed $gm True or 1 or 'gmt'=Input informations are GMT values, False or 0 or 'server' = local to server TZ, 'user' = local to user TZ
|
||||
* @param int $check 0=No check on parameters (Can use day 32, etc...)
|
||||
* @return int Date as a timestamp, '' if error
|
||||
* @see dol_print_date, dol_stringtotime, dol_getdate
|
||||
@ -1023,17 +1023,28 @@ function dol_mktime($hour,$minute,$second,$month,$day,$year,$gm=false,$check=1)
|
||||
if ($second< 0 || $second > 60) return '';
|
||||
}
|
||||
|
||||
if (method_exists('DateTime','getTimestamp') && empty($conf->global->MAIN_OLD_DATE))
|
||||
if (method_exists('DateTime','getTimestamp'))
|
||||
{
|
||||
if (empty($gm)) $localtz = new DateTimeZone(date_default_timezone_get());
|
||||
if (empty($gm) || $gm === 'server')
|
||||
{
|
||||
$default_timezone=@date_default_timezone_get();
|
||||
$localtz = new DateTimeZone($default_timezone);
|
||||
}
|
||||
else if ($gm === 'user')
|
||||
{
|
||||
$default_timezone=(empty($_SESSION["dol_tz_string"])?'UTC':$_SESSION["dol_tz_string"]);
|
||||
$localtz = new DateTimeZone($default_timezone);
|
||||
}
|
||||
else $localtz = new DateTimeZone('UTC');
|
||||
$dt = new DateTime(null,$localtz);
|
||||
$dt->setDate($year,$month,$day);
|
||||
$dt->setTime((int) $hour, (int) $minute, (int) $second);
|
||||
$date=$dt->getTimestamp();
|
||||
$date=$dt->getTimestamp(); // should include daylight saving time
|
||||
}
|
||||
else
|
||||
{
|
||||
dol_print_error('','PHP version must be 5.3+');
|
||||
/*
|
||||
$usealternatemethod=false;
|
||||
if ($year <= 1970) $usealternatemethod=true; // <= 1970
|
||||
if ($year >= 2038) $usealternatemethod=true; // >= 2038
|
||||
@ -1045,7 +1056,7 @@ function dol_mktime($hour,$minute,$second,$month,$day,$year,$gm=false,$check=1)
|
||||
else
|
||||
{
|
||||
$date=mktime($hour,$minute,$second,$month,$day,$year);
|
||||
}
|
||||
}*/
|
||||
}
|
||||
return $date;
|
||||
}
|
||||
@ -2223,10 +2234,10 @@ function info_admin($text, $infoonimgalt = 0, $nodiv=0)
|
||||
|
||||
if ($infoonimgalt)
|
||||
{
|
||||
return img_picto($text, 'star', 'class="hideonsmartphone"');
|
||||
return img_picto($text, 'info', 'class="hideonsmartphone"');
|
||||
}
|
||||
|
||||
return ($nodiv?'':'<div class="info hideonsmartphone">').img_picto($langs->trans('InfoAdmin'), 'star', 'class="hideonsmartphone"').' '.$text.($nodiv?'':'</div>');
|
||||
return ($nodiv?'':'<div class="info hideonsmartphone">').img_picto($langs->trans('InfoAdmin'), 'info', 'class="hideonsmartphone"').' '.$text.($nodiv?'':'</div>');
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2008 Raphael Bertrand <raphael.bertrand@resultic.fr>
|
||||
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
@ -109,7 +109,7 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
$this->posxdiscount=162;
|
||||
$this->postotalht=174;
|
||||
if (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT)) $this->posxtva=$this->posxup;
|
||||
$this->posxpicture=$this->posxtva - 16; // width of images
|
||||
$this->posxpicture=$this->posxtva - (empty($conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH)?16:$conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH); // width of images
|
||||
if ($this->page_largeur < 210) // To work with US executive format
|
||||
{
|
||||
$this->posxpicture-=20;
|
||||
@ -153,7 +153,7 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
$outputlangs->load("products");
|
||||
$outputlangs->load("orders");
|
||||
$outputlangs->load("deliveries");
|
||||
|
||||
|
||||
if ($conf->commande->dir_output)
|
||||
{
|
||||
$object->fetch_thirdparty();
|
||||
@ -228,6 +228,15 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
if (empty($this->atleastonediscount))
|
||||
{
|
||||
$this->posxpicture+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxtva+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxup+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxqty+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxdiscount+=($this->postotalht - $this->posxdiscount);
|
||||
//$this->postotalht;
|
||||
}
|
||||
|
||||
// New page
|
||||
$pdf->AddPage();
|
||||
@ -316,7 +325,7 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pagenb+1);
|
||||
$pdf->setPage($pageposafter+1);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -412,6 +421,7 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
@ -601,7 +611,7 @@ class pdf_einstein extends ModelePDFCommandes
|
||||
$pdf->SetFont('','B', $default_font_size - 2);
|
||||
$text=$outputlangs->transnoentities("DeliveryDate").':';
|
||||
$pdf->MultiCell(80, 3, $text, 0, 'L', 0);
|
||||
|
||||
|
||||
$pdf->SetFont('','', $default_font_size - 2);
|
||||
$pdf->SetXY($posxval, $posy);
|
||||
$text=dol_print_date($object->date_livraison,'day','',$outputlangs);
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2008 Raphael Bertrand <raphael.bertrand@resultic.fr>
|
||||
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
@ -109,7 +109,7 @@ class pdf_proforma extends ModelePDFCommandes
|
||||
$this->posxdiscount=162;
|
||||
$this->postotalht=174;
|
||||
if (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT)) $this->posxtva=$this->posxup;
|
||||
$this->posxpicture=$this->posxtva - 16; // width of images
|
||||
$this->posxpicture=$this->posxtva - (empty($conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH)?16:$conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH); // width of images
|
||||
if ($this->page_largeur < 210) // To work with US executive format
|
||||
{
|
||||
$this->posxpicture-=20;
|
||||
@ -227,6 +227,15 @@ class pdf_proforma extends ModelePDFCommandes
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
if (empty($this->atleastonediscount))
|
||||
{
|
||||
$this->posxpicture+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxtva+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxup+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxqty+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxdiscount+=($this->postotalht - $this->posxdiscount);
|
||||
//$this->postotalht;
|
||||
}
|
||||
|
||||
// New page
|
||||
$pdf->AddPage();
|
||||
@ -315,7 +324,7 @@ class pdf_proforma extends ModelePDFCommandes
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pagenb+1);
|
||||
$pdf->setPage($pageposafter+1);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -411,6 +420,7 @@ class pdf_proforma extends ModelePDFCommandes
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
|
||||
@ -116,15 +116,24 @@ class pdf_strato extends ModelePDFContract
|
||||
$outputlangs->load("dict");
|
||||
$outputlangs->load("companies");
|
||||
$outputlangs->load("contracts");
|
||||
$outputlangs->load("interventions");
|
||||
|
||||
if ($conf->contrat->dir_output)
|
||||
{
|
||||
$object->fetch_thirdparty();
|
||||
|
||||
$objectref = dol_sanitizeFileName($object->ref);
|
||||
$dir = $conf->contrat->dir_output;
|
||||
if (! preg_match('/specimen/i',$objectref)) $dir.= "/" . $objectref;
|
||||
$file = $dir . "/" . $objectref . ".pdf";
|
||||
// Definition of $dir and $file
|
||||
if ($object->specimen)
|
||||
{
|
||||
$dir = $conf->contrat->dir_output;
|
||||
$file = $dir . "/SPECIMEN.pdf";
|
||||
}
|
||||
else
|
||||
{
|
||||
$objectref = dol_sanitizeFileName($object->ref);
|
||||
$dir = $conf->contrat->dir_output . "/" . $objectref;
|
||||
$file = $dir . "/" . $objectref . ".pdf";
|
||||
}
|
||||
|
||||
if (! file_exists($dir))
|
||||
{
|
||||
|
||||
@ -267,6 +267,7 @@ class pdf_merou extends ModelePdfExpedition
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
@ -474,7 +475,7 @@ class pdf_merou extends ModelePdfExpedition
|
||||
else
|
||||
{
|
||||
$text=$this->emetteur->name;
|
||||
$pdf->MultiCell(100, 3, $outputlangs->convToOutputCharset($text), 0, 'L');
|
||||
$pdf->MultiCell(70, 3, $outputlangs->convToOutputCharset($text), 0, 'L');
|
||||
}
|
||||
|
||||
//*********************Entete****************************
|
||||
|
||||
@ -240,7 +240,7 @@ class pdf_rouget extends ModelePdfExpedition
|
||||
$pageposbefore=$pdf->getPage();
|
||||
|
||||
// Description de la ligne produit
|
||||
pdf_writelinedesc($pdf,$object,$i,$outputlangs,150,3,$this->posxdesc,$curY,0,1);
|
||||
pdf_writelinedesc($pdf,$object,$i,$outputlangs,$this->posxqtyordered-10,3,$this->posxdesc,$curY,0,1);
|
||||
|
||||
$nexY = $pdf->GetY();
|
||||
$pageposafter=$pdf->getPage();
|
||||
@ -264,6 +264,7 @@ class pdf_rouget extends ModelePdfExpedition
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2008 Raphael Bertrand <raphael.bertrand@resultic.fr>
|
||||
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
@ -109,7 +109,7 @@ class pdf_crabe extends ModelePDFFactures
|
||||
$this->posxdiscount=162;
|
||||
$this->postotalht=174;
|
||||
if (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT)) $this->posxtva=$this->posxup;
|
||||
$this->posxpicture=$this->posxtva - 16; // width of images
|
||||
$this->posxpicture=$this->posxtva - (empty($conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH)?16:$conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH); // width of images
|
||||
if ($this->page_largeur < 210) // To work with US executive format
|
||||
{
|
||||
$this->posxpicture-=20;
|
||||
@ -228,6 +228,15 @@ class pdf_crabe extends ModelePDFFactures
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
if (empty($this->atleastonediscount))
|
||||
{
|
||||
$this->posxpicture+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxtva+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxup+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxqty+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxdiscount+=($this->postotalht - $this->posxdiscount);
|
||||
//$this->postotalht;
|
||||
}
|
||||
|
||||
// New page
|
||||
$pdf->AddPage();
|
||||
@ -318,7 +327,7 @@ class pdf_crabe extends ModelePDFFactures
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pagenb+1);
|
||||
$pdf->setPage($pageposafter+1);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -413,6 +422,7 @@ class pdf_crabe extends ModelePDFFactures
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
|
||||
@ -250,7 +250,7 @@ class ImportCsv extends ModeleImports
|
||||
/**
|
||||
* Return array of next record in input file.
|
||||
*
|
||||
* @return Array Array of field values. Data are UTF8 encoded. [fieldpos] => (['val']=>val, ['type']=>-1=null,0=blank,1=string)
|
||||
* @return Array Array of field values. Data are UTF8 encoded. [fieldpos] => (['val']=>val, ['type']=>-1=null,0=blank,1=not empty string)
|
||||
*/
|
||||
function import_read_record()
|
||||
{
|
||||
@ -335,7 +335,8 @@ class ImportCsv extends ModeleImports
|
||||
function import_insert($arrayrecord,$array_match_file_to_database,$objimport,$maxfields,$importid)
|
||||
{
|
||||
global $langs,$conf,$user;
|
||||
global $thirdparty_static; // Specifi to thirdparty import
|
||||
global $thirdparty_static; // Specific to thirdparty import
|
||||
global $tablewithentity_cache; // Cache to avoid to call desc at each rows on tables
|
||||
|
||||
$error=0;
|
||||
$warning=0;
|
||||
@ -371,6 +372,25 @@ class ImportCsv extends ModeleImports
|
||||
$i=0;
|
||||
$errorforthistable=0;
|
||||
|
||||
// Define $tablewithentity_cache[$tablename] if not already defined
|
||||
if (! isset($tablewithentity_cache[$tablename])) // keep this test with "isset"
|
||||
{
|
||||
dol_syslog("Check if table ".$tablename." has an entity field");
|
||||
$resql=$this->db->DDLDescTable($tablename,'entity');
|
||||
if ($resql)
|
||||
{
|
||||
$obj=$this->db->fetch_object($resql);
|
||||
if ($obj) $tablewithentity_cache[$tablename]=1; // table contains entity field
|
||||
else $tablewithentity_cache[$tablename]=0; // table does not contains entity field
|
||||
}
|
||||
else dol_print_error($this->db);;
|
||||
}
|
||||
else
|
||||
{
|
||||
//dol_syslog("Table ".$tablename." check for entity into cache is ".$tablewithentity_cache[$tablename]);
|
||||
}
|
||||
|
||||
|
||||
// Loop on each fields in the match array: $key = 1..n, $val=alias of field (s.nom)
|
||||
foreach($sort_array_match_file_to_database as $key => $val)
|
||||
{
|
||||
@ -383,7 +403,7 @@ class ImportCsv extends ModeleImports
|
||||
{
|
||||
// Set $newval with value to insert and set $listvalues with sql request part for insert
|
||||
$newval='';
|
||||
if ($arrayrecord[($key-1)]['type'] > 0) $newval=$arrayrecord[($key-1)]['val']; // If type of field is not null or '' but string
|
||||
if ($arrayrecord[($key-1)]['type'] > 0) $newval=$arrayrecord[($key-1)]['val']; // If type of field into input file is not empty string (so defined into input file), we get value
|
||||
|
||||
// Make some tests on $newval
|
||||
|
||||
@ -441,41 +461,46 @@ class ImportCsv extends ModeleImports
|
||||
{
|
||||
if (empty($newval)) $newval='0';
|
||||
}
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getcustomercodeifnull')
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getcustomercodeifauto')
|
||||
{
|
||||
if (empty($newval) || $newval=='auto')
|
||||
if (strtolower($newval) == 'auto')
|
||||
{
|
||||
$this->thirpartyobject->get_codeclient(0,0);
|
||||
$newval=$this->thirpartyobject->code_client;
|
||||
//print 'code_client='.$newval;
|
||||
}
|
||||
if (empty($newval)) $arrayrecord[($key-1)]['type']=-1; // If we get empty value, we will use "null"
|
||||
}
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getsuppliercodeifnull')
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getsuppliercodeifauto')
|
||||
{
|
||||
if (empty($newval) || $newval=='auto')
|
||||
if (strtolower($newval) == 'auto')
|
||||
{
|
||||
$newval=$this->thirpartyobject->get_codefournisseur(0,1);
|
||||
$newval=$this->thirpartyobject->code_fournisseur;
|
||||
//print 'code_fournisseur='.$newval;
|
||||
}
|
||||
if (empty($newval)) $arrayrecord[($key-1)]['type']=-1; // If we get empty value, we will use "null"
|
||||
}
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getcustomeraccountancycodeifnull')
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getcustomeraccountancycodeifauto')
|
||||
{
|
||||
if (empty($newval) || $newval=='auto')
|
||||
if (strtolower($newval) == 'auto')
|
||||
{
|
||||
$this->thirpartyobject->get_codecompta('customer');
|
||||
$newval=$this->thirpartyobject->code_compta;
|
||||
//print 'code_compta='.$newval;
|
||||
}
|
||||
if (empty($newval)) $arrayrecord[($key-1)]['type']=-1; // If we get empty value, we will use "null"
|
||||
}
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getsupplieraccountancycodeifnull')
|
||||
elseif ($objimport->array_import_convertvalue[0][$val]['rule']=='getsupplieraccountancycodeifauto')
|
||||
{
|
||||
if (empty($newval) || $newval=='auto')
|
||||
if (strtolower($newval) == 'auto')
|
||||
{
|
||||
$this->thirpartyobject->get_codecompta('supplier');
|
||||
$newval=$this->thirpartyobject->code_compta_fournisseur;
|
||||
if (empty($newval)) $arrayrecord[($key-1)]['type']=-1; // If we get empty value, we will use "null"
|
||||
//print 'code_compta_fournisseur='.$newval;
|
||||
}
|
||||
if (empty($newval)) $arrayrecord[($key-1)]['type']=-1; // If we get empty value, we will use "null"
|
||||
}
|
||||
|
||||
//print 'Val to use as insert is '.$newval.'<br>';
|
||||
@ -540,6 +565,7 @@ class ImportCsv extends ModeleImports
|
||||
if ($listfields) { $listfields.=', '; $listvalues.=', '; }
|
||||
$listfields.=$fieldname;
|
||||
|
||||
// Note: arrayrecord (and 'type') is filled with ->import_read_record called by import.php page before calling import_insert
|
||||
if (empty($newval) && $arrayrecord[($key-1)]['type'] < 0) $listvalues.=($newval=='0'?$newval:"null");
|
||||
elseif (empty($newval) && $arrayrecord[($key-1)]['type'] == 0) $listvalues.="''";
|
||||
else $listvalues.="'".$this->db->escape($newval)."'";
|
||||
@ -581,7 +607,7 @@ class ImportCsv extends ModeleImports
|
||||
//var_dump($objimport->array_import_convertvalue); exit;
|
||||
|
||||
// Build SQL request
|
||||
if (! tablewithentity($tablename))
|
||||
if (empty($tablewithentity[$tablename]))
|
||||
{
|
||||
$sql ='INSERT INTO '.$tablename.'('.$listfields.', import_key';
|
||||
if (! empty($objimport->array_import_tables_creator[0][$alias])) $sql.=', '.$objimport->array_import_tables_creator[0][$alias];
|
||||
@ -644,25 +670,5 @@ function cleansep($value)
|
||||
return str_replace(array(',',';'),'/',$value);
|
||||
};
|
||||
|
||||
/**
|
||||
* Returns if a table contains entity column
|
||||
*
|
||||
* @param string $table Table name
|
||||
* @return int 1 if table contains entity, 0 if not and -1 if error
|
||||
*/
|
||||
function tablewithentity($table)
|
||||
{
|
||||
global $db;
|
||||
|
||||
$resql=$db->DDLDescTable($table,'entity');
|
||||
if ($resql)
|
||||
{
|
||||
$i=0;
|
||||
$obj=$db->fetch_object($resql);
|
||||
if ($obj) return 1;
|
||||
else return 0;
|
||||
}
|
||||
else return -1;
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2004-2008 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
||||
* Copyright (C) 2008 Chiptronik
|
||||
@ -223,15 +223,24 @@ class pdf_typhon extends ModelePDFDeliveryOrder
|
||||
$pdf->SetMargins($this->marge_gauche, $this->marge_haute, $this->marge_droite); // Left, Top, Right
|
||||
|
||||
/*
|
||||
// Positionne $this->atleastonediscount si on a au moins une remise
|
||||
for ($i = 0 ; $i < $nblines ; $i++)
|
||||
{
|
||||
if ($object->lines[$i]->remise_percent)
|
||||
{
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
*/
|
||||
// Positionne $this->atleastonediscount si on a au moins une remise
|
||||
for ($i = 0 ; $i < $nblines ; $i++)
|
||||
{
|
||||
if ($object->lines[$i]->remise_percent)
|
||||
{
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
if (empty($this->atleastonediscount))
|
||||
{
|
||||
$this->posxpicture+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxtva+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxup+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxqty+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxdiscount+=($this->postotalht - $this->posxdiscount);
|
||||
//$this->postotalht;
|
||||
}
|
||||
*/
|
||||
|
||||
// New page
|
||||
$pdf->AddPage();
|
||||
@ -307,7 +316,7 @@ class pdf_typhon extends ModelePDFDeliveryOrder
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pagenb+1);
|
||||
$pdf->setPage($pageposafter+1);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -370,6 +379,7 @@ class pdf_typhon extends ModelePDFDeliveryOrder
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblines - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
|
||||
@ -401,14 +401,14 @@ class modSociete extends DolibarrModules
|
||||
's.fk_typent'=>array('rule'=>'fetchidfromcodeid','classfile'=>'/core/class/ctypent.class.php','class'=>'Ctypent','method'=>'fetch','dict'=>'DictionaryCompanyType'),
|
||||
's.fk_pays'=>array('rule'=>'fetchidfromcodeid','classfile'=>'/core/class/cpays.class.php','class'=>'Cpays','method'=>'fetch','dict'=>'DictionaryCountry'),
|
||||
's.fk_stcomm'=>array('rule'=>'zeroifnull'),
|
||||
's.code_client'=>array('rule'=>'getcustomercodeifnull'),
|
||||
's.code_fournisseur'=>array('rule'=>'getsuppliercodeifnull'),
|
||||
's.code_compta'=>array('rule'=>'getcustomeraccountancycodeifnull'),
|
||||
's.code_compta_fournisseur'=>array('rule'=>'getsupplieraccountancycodeifnull')
|
||||
's.code_client'=>array('rule'=>'getcustomercodeifauto'),
|
||||
's.code_fournisseur'=>array('rule'=>'getsuppliercodeifauto'),
|
||||
's.code_compta'=>array('rule'=>'getcustomeraccountancycodeifauto'),
|
||||
's.code_compta_fournisseur'=>array('rule'=>'getsupplieraccountancycodeifauto')
|
||||
);
|
||||
//$this->import_convertvalue_array[$r]=array('s.fk_soc'=>array('rule'=>'lastrowid',table='t');
|
||||
$this->import_regex_array[$r]=array('s.status'=>'^[0|1]','s.client'=>'^[0|1|2|3]','s.fournisseur'=>'^[0|1]','s.fk_typent'=>'id@'.MAIN_DB_PREFIX.'c_typent','s.datec'=>'^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$');
|
||||
$this->import_examplevalues_array[$r]=array('s.nom'=>"MyBigCompany",'s.status'=>"0 (closed) or 1 (active)",'s.client'=>'0 (no customer no prospect)/1 (customer)/2 (prospect)/3 (customer and prospect)','s.fournisseur'=>'0 or 1','s.datec'=>dol_print_date(dol_now(),'%Y-%m-%d'),'s.code_client'=>"CU01-0001 or auto",'s.code_fournisseur'=>"SU01-0001 or auto",'s.address'=>"61 jump street",'s.zip'=>"123456",'s.town'=>"Big town",'s.fk_pays'=>'US, FR, DE...','s.phone'=>"0101010101",'s.fax'=>"0101010102",'s.url'=>"http://mycompany.com",'s.email'=>"test@mycompany.com",'s.siret'=>"",'s.siren'=>"",'s.ape'=>"",'s.idprof4'=>"",'s.tva_intra'=>"FR0123456789",'s.capital'=>"10000",'s.note_private'=>"This is an example of private note for record",'s.note_public'=>"This is an example of public note for record",'s.fk_typent'=>"2",'s.fk_effectif'=>"3","s.fk_forme_juridique"=>"1",'s.fk_prospectlevel'=>'PL_MEDIUM','s.fk_stcomm'=>'0','s.default_lang'=>'en_US','s.barcode'=>'123456789');
|
||||
$this->import_examplevalues_array[$r]=array('s.nom'=>"MyBigCompany",'s.status'=>"0 (closed) or 1 (active)",'s.client'=>'0 (no customer no prospect)/1 (customer)/2 (prospect)/3 (customer and prospect)','s.fournisseur'=>'0 or 1','s.datec'=>dol_print_date(dol_now(),'%Y-%m-%d'),'s.code_client'=>"CU01-0001 or empty or 'auto'",'s.code_fournisseur'=>"SU01-0001 or empty or 'auto'",'s.address'=>"61 jump street",'s.zip'=>"123456",'s.town'=>"Big town",'s.fk_pays'=>'US, FR, DE...','s.phone'=>"0101010101",'s.fax'=>"0101010102",'s.url'=>"http://mycompany.com",'s.email'=>"test@mycompany.com",'s.siret'=>"",'s.siren'=>"",'s.ape'=>"",'s.idprof4'=>"",'s.tva_intra'=>"FR0123456789",'s.capital'=>"10000",'s.note_private'=>"This is an example of private note for record",'s.note_public'=>"This is an example of public note for record",'s.fk_typent'=>"2",'s.fk_effectif'=>"3","s.fk_forme_juridique"=>"1",'s.fk_prospectlevel'=>'PL_MEDIUM','s.fk_stcomm'=>'0','s.default_lang'=>'en_US','s.barcode'=>'123456789');
|
||||
|
||||
// Import list of contact and attributes
|
||||
$r++;
|
||||
|
||||
@ -222,12 +222,15 @@ class pdf_baleine extends ModelePDFProjects
|
||||
$pdf->MultiCell(20, 3, $dateend, 0, 'L');
|
||||
|
||||
|
||||
$pageposafter=$pdf->getPage();
|
||||
|
||||
$pdf->SetFont('','', $default_font_size - 1); // On repositionne la police par defaut
|
||||
$nexY = $pdf->GetY();
|
||||
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
|
||||
@ -254,6 +254,15 @@ class pdf_azur extends ModelePDFPropales
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
if (empty($this->atleastonediscount))
|
||||
{
|
||||
$this->posxpicture+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxtva+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxup+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxqty+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxdiscount+=($this->postotalht - $this->posxdiscount);
|
||||
//$this->postotalht;
|
||||
}
|
||||
|
||||
// New page
|
||||
$pdf->AddPage();
|
||||
@ -332,7 +341,7 @@ class pdf_azur extends ModelePDFPropales
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pagenb+1);
|
||||
$pdf->setPage($pageposbefore+1);
|
||||
|
||||
$curY = $tab_top_newpage;
|
||||
$showpricebeforepagebreak=0;
|
||||
@ -370,7 +379,7 @@ class pdf_azur extends ModelePDFPropales
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pagenb+1);
|
||||
$pdf->setPage($pageposafter+1);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -387,6 +396,7 @@ class pdf_azur extends ModelePDFPropales
|
||||
|
||||
$nexY = $pdf->GetY();
|
||||
$pageposafter=$pdf->getPage();
|
||||
|
||||
$pdf->setPage($pageposbefore);
|
||||
$pdf->setTopMargin($this->marge_haute);
|
||||
$pdf->setPageOrientation('', 1, 0); // The only function to edit the bottom margin of current page to set it.
|
||||
@ -468,6 +478,7 @@ class pdf_azur extends ModelePDFPropales
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2010-2011 Juanjo Menent <jmenent@2byte.es>
|
||||
* Copyright (C) 2010-2012 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2010-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
*
|
||||
* 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
|
||||
@ -58,7 +58,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
* Constructor
|
||||
*
|
||||
* @param DoliDB $db Database handler
|
||||
* @param Societe $object Supplier invoice
|
||||
* @param Object $object Supplier invoice
|
||||
*/
|
||||
function __construct($db,$object)
|
||||
{
|
||||
@ -105,7 +105,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
$this->posxdiscount=162;
|
||||
$this->postotalht=174;
|
||||
//if (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT)) $this->posxtva=$this->posxup;
|
||||
$this->posxpicture=$this->posxtva - 16; // width of images
|
||||
$this->posxpicture=$this->posxtva - (empty($conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH)?16:$conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH); // width of images
|
||||
if ($this->page_largeur < 210) // To work with US executive format
|
||||
{
|
||||
$this->posxpicture-=20;
|
||||
@ -227,6 +227,15 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
if (empty($this->atleastonediscount))
|
||||
{
|
||||
$this->posxpicture+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxtva+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxup+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxqty+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxdiscount+=($this->postotalht - $this->posxdiscount);
|
||||
//$this->postotalht;
|
||||
}
|
||||
|
||||
// New page
|
||||
$pdf->AddPage();
|
||||
@ -281,7 +290,39 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
|
||||
// Description of product line
|
||||
$curX = $this->posxdesc-1;
|
||||
pdf_writelinedesc($pdf,$object,$i,$outputlangs,$this->posxtva-$curX,3,$curX,$curY,$hideref,$hidedesc,1);
|
||||
$showpricebeforepagebreak=1;
|
||||
|
||||
$pdf->startTransaction();
|
||||
pdf_writelinedesc($pdf,$object,$i,$outputlangs,$this->posxtva-$curX,3,$curX,$curY,$hideref,$hidedesc,1);
|
||||
$pageposafter=$pdf->getPage();
|
||||
if ($pageposafter > $pageposbefore) // There is a pagebreak
|
||||
{
|
||||
$pdf->rollbackTransaction(true);
|
||||
$pageposafter=$pageposbefore;
|
||||
//print $pageposafter.'-'.$pageposbefore;exit;
|
||||
$pdf->setPageOrientation('', 1, $heightforfooter); // The only function to edit the bottom margin of current page to set it.
|
||||
pdf_writelinedesc($pdf,$object,$i,$outputlangs,$this->posxtva-$curX,4,$curX,$curY,$hideref,$hidedesc);
|
||||
$posyafter=$pdf->GetY();
|
||||
if ($posyafter > ($this->page_hauteur - ($heightforfooter+$heightforfreetext+$heightforinfotot))) // There is no space left for total+free text
|
||||
{
|
||||
if ($i == ($nblignes-1)) // No more lines, and no space left to show total, so we create a new page
|
||||
{
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pageposafter+1);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// We found a page break
|
||||
$showpricebeforepagebreak=0;
|
||||
}
|
||||
}
|
||||
else // No pagebreak
|
||||
{
|
||||
$pdf->commitTransaction();
|
||||
}
|
||||
|
||||
$nexY = $pdf->GetY();
|
||||
$pageposafter=$pdf->getPage();
|
||||
@ -290,7 +331,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
$pdf->setPageOrientation('', 1, 0); // The only function to edit the bottom margin of current page to set it.
|
||||
|
||||
// We suppose that a too long description is moved completely on next page
|
||||
if ($pageposafter > $pageposbefore) {
|
||||
if ($pageposafter > $pageposbefore && empty($showpricebeforepagebreak)) {
|
||||
$pdf->setPage($pageposafter); $curY = $tab_top_newpage;
|
||||
}
|
||||
|
||||
@ -301,7 +342,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
{
|
||||
$vat_rate = pdf_getlinevatrate($object, $i, $outputlangs, $hidedetails);
|
||||
$pdf->SetXY($this->posxtva, $curY);
|
||||
$pdf->MultiCell($this->posxup-$this->posxtva-0.8, 3, $vat_rate, 0, 'R');
|
||||
$pdf->MultiCell($this->posxup-$this->posxtva-1, 3, $vat_rate, 0, 'R');
|
||||
}
|
||||
|
||||
// Unit price before discount
|
||||
@ -322,7 +363,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
// Total HT line
|
||||
$total_excl_tax = pdf_getlinetotalexcltax($object, $i, $outputlangs);
|
||||
$pdf->SetXY($this->postotalht, $curY);
|
||||
$pdf->MultiCell(26, 3, $total_excl_tax, 0, 'R', 0);
|
||||
$pdf->MultiCell($this->page_largeur-$this->marge_droite-$this->postotalht, 3, $total_excl_tax, 0, 'R', 0);
|
||||
|
||||
// Collecte des totaux par valeur de tva dans $this->tva["taux"]=total_tva
|
||||
$tvaligne=$object->lines[$i]->total_tva;
|
||||
@ -344,6 +385,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
@ -368,6 +410,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
$pagenb++;
|
||||
$pdf->setPage($pagenb);
|
||||
$pdf->setPageOrientation('', 1, 0); // The only function to edit the bottom margin of current page to set it.
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
}
|
||||
if (isset($object->lines[$i+1]->pagebreak) && $object->lines[$i+1]->pagebreak)
|
||||
{
|
||||
@ -384,6 +427,7 @@ class pdf_canelle extends ModelePDFSuppliersInvoices
|
||||
$pdf->AddPage();
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
$pagenb++;
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
/* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2005-2011 Regis Houssin <regis.houssin@capnetworks.com>
|
||||
* Copyright (C) 2007 Franky Van Liedekerke <franky.van.liedekerke@telenet.be>
|
||||
* Copyright (C) 2010-2013 Juanjo Menent <jmenent@2byte.es>
|
||||
@ -110,7 +110,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
||||
$this->posxdiscount=162;
|
||||
$this->postotalht=174;
|
||||
//if (! empty($conf->global->MAIN_GENERATE_DOCUMENTS_WITHOUT_VAT)) $this->posxtva=$this->posxup;
|
||||
$this->posxpicture=$this->posxtva - 16; // width of images
|
||||
$this->posxpicture=$this->posxtva - (empty($conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH)?16:$conf->global->MAIN_DOCUMENTS_WITH_PICTURE_WIDTH); // width of images
|
||||
if ($this->page_largeur < 210) // To work with US executive format
|
||||
{
|
||||
$this->posxpicture-=20;
|
||||
@ -235,6 +235,15 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
||||
$this->atleastonediscount++;
|
||||
}
|
||||
}
|
||||
if (empty($this->atleastonediscount))
|
||||
{
|
||||
$this->posxpicture+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxtva+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxup+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxqty+=($this->postotalht - $this->posxdiscount);
|
||||
$this->posxdiscount+=($this->postotalht - $this->posxdiscount);
|
||||
//$this->postotalht;
|
||||
}
|
||||
|
||||
// New page
|
||||
$pdf->AddPage();
|
||||
@ -309,7 +318,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
||||
$pdf->AddPage('','',true);
|
||||
if (! empty($tplidx)) $pdf->useTemplate($tplidx);
|
||||
if (empty($conf->global->MAIN_PDF_DONOTREPEAT_HEAD)) $this->_pagehead($pdf, $object, 0, $outputlangs);
|
||||
$pdf->setPage($pagenb+1);
|
||||
$pdf->setPage($pageposafter+1);
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -403,6 +412,7 @@ class pdf_muscadet extends ModelePDFSuppliersOrders
|
||||
// Add line
|
||||
if (! empty($conf->global->MAIN_PDF_DASH_BETWEEN_LINES) && $i < ($nblignes - 1))
|
||||
{
|
||||
$pdf->setPage($pageposafter);
|
||||
$pdf->SetLineStyle(array('dash'=>'1,1','color'=>array(210,210,210)));
|
||||
//$pdf->SetDrawColor(190,190,200);
|
||||
$pdf->line($this->marge_gauche, $nexY+1, $this->page_largeur - $this->marge_droite, $nexY+1);
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/* Copyright (C) 2013 Cédric Salvador <csalvador@gpcsolutions.fr>
|
||||
* Copyright (C) 2013 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
/* Copyright (C) 2013 Cédric Salvador <csalvador@gpcsolutions.fr>
|
||||
* Copyright (C) 2013-2014 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
*
|
||||
* 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
|
||||
@ -18,16 +18,17 @@
|
||||
*/
|
||||
|
||||
$langs->load("link");
|
||||
if (empty($relativepathwithnofile)) $relativepathwithnofile='';
|
||||
|
||||
/*
|
||||
* Confirm suppression
|
||||
* Confirm form to delete
|
||||
*/
|
||||
|
||||
if ($action == 'delete')
|
||||
{
|
||||
$langs->load("companies"); // Need for string DeleteFile+ConfirmDeleteFiles
|
||||
$ret = $form->form_confirm(
|
||||
$_SERVER["PHP_SELF"] . '?id=' . $object->id . '&urlfile=' . urlencode(GETPOST("urlfile")) . '&linkid=' . GETPOST('linkid', 'int'),
|
||||
$_SERVER["PHP_SELF"] . '?id=' . $object->id . '&urlfile=' . urlencode(GETPOST("urlfile")) . '&linkid=' . GETPOST('linkid', 'int') . (empty($param)?'':$param),
|
||||
$langs->trans('DeleteFile'),
|
||||
$langs->trans('ConfirmDeleteFile'),
|
||||
'confirm_deletefile',
|
||||
@ -58,11 +59,11 @@ $formfile->list_of_documents(
|
||||
$modulepart,
|
||||
$param,
|
||||
0,
|
||||
'',
|
||||
$relativepathwithnofile, // relative path with no file. For example "moduledir/0/1"
|
||||
$permission
|
||||
);
|
||||
|
||||
print "<br>";
|
||||
//List of links
|
||||
$formfile->listOfLinks($object, $permission, $action, GETPOST('linkid', 'int'));
|
||||
$formfile->listOfLinks($object, $permission, $action, GETPOST('linkid', 'int'), $param);
|
||||
print "<br>";
|
||||
|
||||
@ -74,7 +74,7 @@ if ($action == 'confirm_deletefile' && $confirm == 'yes')
|
||||
setEventMessage($langs->trans("ErrorFailedToDeleteLink", $link->label), 'errors');
|
||||
}
|
||||
}
|
||||
header('Location: ' . $_SERVER["PHP_SELF"] . '?id=' . $object->id);
|
||||
header('Location: ' . $_SERVER["PHP_SELF"] . '?id=' . $object->id.($withproject?'&withproject=1':''));
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
@ -24,10 +24,6 @@
|
||||
* \brief Note card expedition
|
||||
*/
|
||||
|
||||
error_reporting(E_ALL);
|
||||
ini_set('display_errors', true);
|
||||
ini_set('html_errors', false);
|
||||
|
||||
require '../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/expedition/class/expedition.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/lib/sendings.lib.php';
|
||||
|
||||
@ -212,8 +212,9 @@ else if ($action == 'addline' && $user->rights->fournisseur->commande->creer)
|
||||
setEventMessage($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('Type')), 'errors');
|
||||
$error++;
|
||||
}
|
||||
if (! GETPOST('addline_predefined') && (! GETPOST('pu') || GETPOST('pu')=='')) // Unit price can be 0 but not ''
|
||||
if (! GETPOST('addline_predefined') && ( GETPOST('pu')==='')) // Unit price can be 0 but not ''
|
||||
{
|
||||
|
||||
setEventMessage($langs->trans($langs->trans('ErrorFieldRequired', $langs->transnoentitiesnoconv('UnitPrice'))), 'errors');
|
||||
$error++;
|
||||
}
|
||||
@ -232,7 +233,7 @@ else if ($action == 'addline' && $user->rights->fournisseur->commande->creer)
|
||||
// Ecrase $pu par celui du produit
|
||||
// Ecrase $desc par celui du produit
|
||||
// Ecrase $txtva par celui du produit
|
||||
if (GETPOST('addline_predefined') || GETPOST('idprodfournprice')) // With combolist idprodfournprice is > 0 or -1. With autocomplete, idprodfournprice is > 0 or ''
|
||||
if ((GETPOST('addline_predefined') || GETPOST('idprodfournprice')) && ( GETPOST('pu')!=='')) // With combolist idprodfournprice is > 0 or -1. With autocomplete, idprodfournprice is > 0 or ''
|
||||
{
|
||||
$idprod=0;
|
||||
$productsupplier = new ProductFournisseur($db);
|
||||
@ -292,7 +293,7 @@ else if ($action == 'addline' && $user->rights->fournisseur->commande->creer)
|
||||
setEventMessage($langs->trans("ErrorQtyTooLowForThisSupplier"), 'errors');
|
||||
}
|
||||
}
|
||||
else
|
||||
else if( GETPOST('pu')!=='' || GETPOST('amountttc')!=='' )
|
||||
{
|
||||
$type=$_POST["type"];
|
||||
$desc=$_POST['dp_desc'];
|
||||
@ -319,7 +320,7 @@ else if ($action == 'addline' && $user->rights->fournisseur->commande->creer)
|
||||
$ttc = price2num($_POST['amountttc']);
|
||||
$ht = $ttc / (1 + ($tauxtva / 100));
|
||||
$price_base_type = 'HT';
|
||||
$result=$object->addline($desc, $ht, $qty, $tva_tx, $localtax1_tx, $localtax2_tx, 0, 0, '', $remise_percent, $price_base_type, $ttc, $type);
|
||||
$result=$object->addline($desc, $ht, $qty, $tva_tx, $localtax1_tx, $localtax2_tx, 0, 0, '', $remise_percent, $price_base_type, $ttc, $type);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -32,11 +32,9 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
|
||||
|
||||
$langs->load("orders");
|
||||
|
||||
$sref=GETPOST('search_ref');
|
||||
$snom=GETPOST('search_nom');
|
||||
$suser=GETPOST('search_user');
|
||||
$sttc=GETPOST('search_ttc');
|
||||
|
||||
$search_ref=GETPOST('search_ref');
|
||||
$search_refsupp=GETPOST('search_refsupp');
|
||||
$search_nom=GETPOST('search_nom');
|
||||
$search_user=GETPOST('search_user');
|
||||
$search_ttc=GETPOST('search_ttc');
|
||||
@ -81,7 +79,7 @@ $offset = $conf->liste_limit * $page ;
|
||||
*/
|
||||
|
||||
$sql = "SELECT s.rowid as socid, s.nom, cf.date_commande as dc,";
|
||||
$sql.= " cf.rowid,cf.ref, cf.fk_statut, cf.total_ttc, cf.fk_user_author,";
|
||||
$sql.= " cf.rowid,cf.ref, cf.ref_supplier, cf.fk_statut, cf.total_ttc, cf.fk_user_author,";
|
||||
$sql.= " u.login";
|
||||
$sql.= " FROM (".MAIN_DB_PREFIX."societe as s,";
|
||||
$sql.= " ".MAIN_DB_PREFIX."commande_fournisseur as cf";
|
||||
@ -91,21 +89,21 @@ $sql.= " LEFT JOIN ".MAIN_DB_PREFIX."user as u ON cf.fk_user_author = u.rowid";
|
||||
$sql.= " WHERE cf.fk_soc = s.rowid ";
|
||||
$sql.= " AND cf.entity = ".$conf->entity;
|
||||
if (!$user->rights->societe->client->voir && !$socid) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
|
||||
if ($sref)
|
||||
if ($search_ref)
|
||||
{
|
||||
$sql .= natural_search('cf.ref', $sref);
|
||||
$sql .= natural_search('cf.ref', $search_ref);
|
||||
}
|
||||
if ($snom)
|
||||
if ($search_nom)
|
||||
{
|
||||
$sql .= natural_search('s.nom', $snom);
|
||||
$sql .= natural_search('s.nom', $search_nom);
|
||||
}
|
||||
if ($suser)
|
||||
if ($search_user)
|
||||
{
|
||||
$sql.= " AND u.login LIKE '%".$db->escape($suser)."%'";
|
||||
$sql.= " AND u.login LIKE '%".$db->escape($search_user)."%'";
|
||||
}
|
||||
if ($sttc)
|
||||
if ($search_ttc)
|
||||
{
|
||||
$sql .= " AND total_ttc = ".price2num($sttc);
|
||||
$sql .= " AND total_ttc = ".price2num($search_ttc);
|
||||
}
|
||||
if ($sall)
|
||||
{
|
||||
@ -117,6 +115,10 @@ if (GETPOST('statut'))
|
||||
{
|
||||
$sql .= " AND fk_statut =".GETPOST('statut','int');
|
||||
}
|
||||
if ($search_refsupp)
|
||||
{
|
||||
$sql.= " AND (cf.ref_supplier LIKE '%".$db->escape($search_refsupp)."%')";
|
||||
}
|
||||
|
||||
$sql.= " ORDER BY $sortfield $sortorder ";
|
||||
$sql.= $db->plimit($conf->liste_limit+1, $offset);
|
||||
@ -133,11 +135,13 @@ if ($resql)
|
||||
if ($search_nom) $param.="&search_nom=".$search_nom;
|
||||
if ($search_user) $param.="&search_user=".$search_user;
|
||||
if ($search_ttc) $param.="&search_ttc=".$search_ttc;
|
||||
if ($search_refsupp) $param.="&search_refsupp=".$search_refsupp;
|
||||
print_barre_liste($title, $page, $_SERVER["PHP_SELF"], $param, $sortfield, $sortorder, '', $num);
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print_liste_field_titre($langs->trans("Ref"),$_SERVER["PHP_SELF"],"cf.ref","",$param,'',$sortfield,$sortorder);
|
||||
print_liste_field_titre($langs->trans("RefSupplier"),$_SERVER["PHP_SELF"],"cf.ref_supplier","",$param,'',$sortfield,$sortorder);
|
||||
print_liste_field_titre($langs->trans("Company"),$_SERVER["PHP_SELF"],"s.nom","",$param,'',$sortfield,$sortorder);
|
||||
print_liste_field_titre($langs->trans("Author"),$_SERVER["PHP_SELF"],"u.login","",$param,'',$sortfield,$sortorder);
|
||||
print_liste_field_titre($langs->trans("AmountTTC"),$_SERVER["PHP_SELF"],"total_ttc","",$param,$sortfield,$sortorder);
|
||||
@ -147,10 +151,11 @@ if ($resql)
|
||||
|
||||
print '<tr class="liste_titre">';
|
||||
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_ref" value="'.$sref.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_nom" value="'.$snom.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_user" value="'.$suser.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_ttc" value="'.$sttc.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_ref" value="'.$search_ref.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_refsupp" value="'.$search_refsupp.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_nom" value="'.$search_nom.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_user" value="'.$search_user.'"></td>';
|
||||
print '<td class="liste_titre"><input type="text" class="flat" name="search_ttc" value="'.$search_ttc.'"></td>';
|
||||
print '<td colspan="2" class="liste_titre" align="right">';
|
||||
print '<input type="image" class="liste_titre" name="button_search" src="'.img_picto($langs->trans("Search"),'search.png','','',1).'" value="'.dol_escape_htmltag($langs->trans("Search")).'" title="'.dol_escape_htmltag($langs->trans("Search")).'">';
|
||||
print '</td>';
|
||||
@ -174,6 +179,10 @@ if ($resql)
|
||||
$filedir=$conf->fournisseur->dir_output.'/commande' . '/' . dol_sanitizeFileName($obj->ref);
|
||||
print $formfile->getDocumentsLink($objectstatic->element, $filename, $filedir);
|
||||
print '</td>'."\n";
|
||||
|
||||
// Ref Supplier
|
||||
print '<td>'.$obj->ref_supplier.'</td>'."\n";
|
||||
|
||||
|
||||
// Company
|
||||
print '<td><a href="'.DOL_URL_ROOT.'/fourn/fiche.php?socid='.$obj->socid.'">'.img_object($langs->trans("ShowCompany"),"company").' ';
|
||||
|
||||
@ -28,10 +28,6 @@
|
||||
* \brief Page for supplier invoice card (view, edit, validate)
|
||||
*/
|
||||
|
||||
error_reporting(E_ALL);
|
||||
ini_set('display_errors', true);
|
||||
ini_set('html_errors', false);
|
||||
|
||||
require '../../main.inc.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.class.php';
|
||||
|
||||
@ -1043,7 +1043,7 @@ else
|
||||
$idGroupValid = $cp->getConfCP('userGroup');
|
||||
|
||||
$validator = new UserGroup($db,$idGroupValid);
|
||||
$valideur = $validator->listUsersForGroup();
|
||||
$valideur = $validator->listUsersForGroup('',1);
|
||||
|
||||
print '<td>';
|
||||
$form->select_users($cp->fk_validator,"valideur",1,"",0,$valideur,'');
|
||||
|
||||
@ -482,7 +482,7 @@ if ($step == 3 && $datatoimport)
|
||||
if ($action == 'delete')
|
||||
{
|
||||
print $form->formconfirm($_SERVER["PHP_SELF"].'?urlfile='.urlencode(GETPOST('urlfile')).'&step=3'.$param, $langs->trans('DeleteFile'), $langs->trans('ConfirmDeleteFile'), 'confirm_deletefile', '', 0, 1);
|
||||
|
||||
|
||||
}
|
||||
|
||||
print '<table width="100%" class="border">';
|
||||
@ -1307,7 +1307,10 @@ if ($step == 5 && $datatoimport)
|
||||
$result=$obj->import_open_file($pathfile,$langs);
|
||||
if ($result > 0)
|
||||
{
|
||||
$sourcelinenb=0; $endoffile=0;
|
||||
global $tablewithentity_cache;
|
||||
$tablewithentity_cache=array();
|
||||
$sourcelinenb=0; $endoffile=0;
|
||||
|
||||
// Loop on each input file record
|
||||
while ($sourcelinenb < $nboflines && ! $endoffile)
|
||||
{
|
||||
@ -1621,7 +1624,10 @@ if ($step == 6 && $datatoimport)
|
||||
$result=$obj->import_open_file($pathfile,$langs);
|
||||
if ($result > 0)
|
||||
{
|
||||
global $tablewithentity_cache;
|
||||
$tablewithentity_cache=array();
|
||||
$sourcelinenb=0; $endoffile=0;
|
||||
|
||||
while ($sourcelinenb < $nboflines && ! $endoffile)
|
||||
{
|
||||
$sourcelinenb++;
|
||||
|
||||
@ -73,12 +73,12 @@ if (! empty($useragent))
|
||||
if (versioncompare(versionphparray(),array(4,3,10)) < 0) // Minimum to use (error if lower)
|
||||
{
|
||||
print '<img src="../theme/eldy/img/error.png" alt="Error"> '.$langs->trans("ErrorPHPVersionTooLow",'4.3.10');
|
||||
$checksok=0;
|
||||
$checksok=0; // 0=error, 1=warning
|
||||
}
|
||||
else if (versioncompare(versionphparray(),array(5,2,0)) < 0) // Minimum supported (warning if lower)
|
||||
else if (versioncompare(versionphparray(),array(5,3,0)) < 0) // Minimum supported (error if lower)
|
||||
{
|
||||
print '<img src="../theme/eldy/img/warning.png" alt="Error"> '.$langs->trans("WarningPHPVersionTooLow",'5.2.0');
|
||||
$checksok=1;
|
||||
print '<img src="../theme/eldy/img/warning.png" alt="Error"> '.$langs->trans("ErrorPHPVersionTooLow",'5.3.0');
|
||||
$checksok=0; // 0=error, 1=warning
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@ -428,10 +428,6 @@ INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'XEU'
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'ARP', NULL, 0, 'Pesos argentins');
|
||||
INSERT INTO llx_c_currencies ( code_iso, unicode, active, label ) VALUES ( 'MXP', NULL, 0, 'Pesos Mexicans');
|
||||
|
||||
ALTER TABLE llx_propal ADD CONSTRAINT fk_propal_fk_currency FOREIGN KEY (fk_currency) REFERENCES llx_c_currencies (code_iso);
|
||||
ALTER TABLE llx_commande ADD CONSTRAINT fk_commande_fk_currency FOREIGN KEY (fk_currency) REFERENCES llx_c_currencies (code_iso);
|
||||
ALTER TABLE llx_facture ADD CONSTRAINT fk_facture_fk_currency FOREIGN KEY (fk_currency) REFERENCES llx_c_currencies (code_iso);
|
||||
|
||||
ALTER TABLE llx_expedition DROP COLUMN billed;
|
||||
|
||||
ALTER TABLE llx_product_fournisseur_price DROP FOREIGN KEY fk_product_fournisseur_price_fk_product_fournisseur;
|
||||
|
||||
@ -17,6 +17,18 @@
|
||||
-- -- VPGSQL8.2 DELETE FROM llx_usergroup_user WHERE fk_user NOT IN (SELECT rowid from llx_user);
|
||||
-- -- VMYSQL4.1 DELETE FROM llx_usergroup_user WHERE fk_usergroup NOT IN (SELECT rowid from llx_usergroup);
|
||||
|
||||
|
||||
-- delete foreign key that should never exists
|
||||
ALTER TABLE llx_propal DROP FOREIGN KEY fk_propal_fk_currency;
|
||||
ALTER TABLE llx_commande DROP FOREIGN KEY fk_commande_fk_currency;
|
||||
ALTER TABLE llx_facture DROP FOREIGN KEY fk_facture_fk_currency;
|
||||
ALTER TABLE llx_facture DROP FOREIGN KEY fk_societe_fk_currency;
|
||||
|
||||
ALTER TABLE llx_propal MODIFY COLUMN fk_currency varchar(3) NULL;
|
||||
ALTER TABLE llx_commande MODIFY COLUMN fk_currency varchar(3) NULL;
|
||||
ALTER TABLE llx_facture MODIFY COLUMN fk_currency varchar(3) NULL;
|
||||
ALTER TABLE llx_societe MODIFY COLUMN fk_currency varchar(3) NULL;
|
||||
|
||||
ALTER TABLE llx_bookmark ADD COLUMN entity integer DEFAULT 1 NOT NULL;
|
||||
ALTER TABLE llx_bookmark MODIFY COLUMN url varchar(255) NOT NULL;
|
||||
|
||||
|
||||
@ -6,6 +6,11 @@
|
||||
|
||||
-- Requests to clean corrupted database
|
||||
|
||||
-- delete foreign key that should never exists
|
||||
ALTER TABLE llx_propal DROP FOREIGN KEY fk_propal_fk_currency;
|
||||
ALTER TABLE llx_commande DROP FOREIGN KEY fk_commande_fk_currency;
|
||||
ALTER TABLE llx_facture DROP FOREIGN KEY fk_facture_fk_currency;
|
||||
|
||||
delete from llx_facturedet where fk_facture in (select rowid from llx_facture where facnumber in ('(PROV)','ErrorBadMask'));
|
||||
delete from llx_facture where facnumber in ('(PROV)','ErrorBadMask');
|
||||
delete from llx_commandedet where fk_commande in (select rowid from llx_commande where ref in ('(PROV)','ErrorBadMask'));
|
||||
|
||||
@ -56,7 +56,7 @@ create table llx_commande
|
||||
|
||||
facture tinyint default 0,
|
||||
fk_account integer, -- bank account
|
||||
fk_currency varchar(2), -- currency code
|
||||
fk_currency varchar(3), -- currency code
|
||||
fk_cond_reglement integer, -- condition de reglement
|
||||
fk_mode_reglement integer, -- mode de reglement
|
||||
|
||||
|
||||
@ -63,7 +63,7 @@ create table llx_facture
|
||||
fk_projet integer DEFAULT NULL, -- projet auquel est associee la facture
|
||||
|
||||
fk_account integer, -- bank account
|
||||
fk_currency varchar(2), -- currency code
|
||||
fk_currency varchar(3), -- currency code
|
||||
fk_cond_reglement integer DEFAULT 1 NOT NULL, -- condition de reglement (30 jours, fin de mois ...)
|
||||
fk_mode_reglement integer, -- mode de reglement (Virement, Prelevement)
|
||||
date_lim_reglement date, -- date limite de reglement
|
||||
|
||||
@ -53,7 +53,7 @@ create table llx_propal
|
||||
total double(24,8) DEFAULT 0, -- montant total ttc apres remise globale
|
||||
|
||||
fk_account integer, -- bank account
|
||||
fk_currency varchar(2), -- currency code
|
||||
fk_currency varchar(3), -- currency code
|
||||
fk_cond_reglement integer, -- condition de reglement (30 jours, fin de mois ...)
|
||||
fk_mode_reglement integer, -- mode de reglement (Virement, Prelevement)
|
||||
|
||||
|
||||
@ -53,7 +53,7 @@ create table llx_societe
|
||||
fk_effectif integer DEFAULT 0, --
|
||||
fk_typent integer DEFAULT 0, --
|
||||
fk_forme_juridique integer DEFAULT 0, -- juridical status
|
||||
fk_currency integer DEFAULT 0, -- currency
|
||||
fk_currency varchar(3), -- default currency
|
||||
siren varchar(128), -- IDProf1: siren or RCS for france
|
||||
siret varchar(128), -- IDProf2: siret for france
|
||||
ape varchar(128), -- IDProf3: code ape for france
|
||||
|
||||
@ -8,7 +8,6 @@ BillsCustomersUnpaid=Unpaid customer's invoices
|
||||
BillsCustomersUnpaidForCompany=Unpaid customer's invoices for %s
|
||||
BillsSuppliersUnpaid=Unpaid supplier's invoices
|
||||
BillsSuppliersUnpaidForCompany=Unpaid supplier's invoices for %s
|
||||
BillsUnpaid=Unpaid
|
||||
BillsLate=Late payments
|
||||
BillsStatistics=Customer's invoices statistics
|
||||
BillsStatisticsSuppliers=Supplier's invoices statistics
|
||||
@ -24,7 +23,7 @@ InvoiceProFormaAsk=Proforma invoice
|
||||
InvoiceProFormaDesc=<b>Proforma invoice</b> is an image of a true invoice but has no accountancy value.
|
||||
InvoiceReplacement=Replacement invoice
|
||||
InvoiceReplacementAsk=Replacement invoice for invoice
|
||||
InvoiceReplacementDesc=<b>Replacement invoice</b> is used to cancel and replace completely an invoice with no payment already received.<br><br>Note: Only invoice with no payment on it can be replaced. If not closed, it will be automatically closed to 'abandoned'.
|
||||
InvoiceReplacementDesc=<b>Replacement invoice</b> is used to cancel and replace completely an invoice with no payment already received.<br><br>Note: Only invoices with no payment on it can be replaced. If the invoice you replace is not yet closed, it will be automatically closed to 'abandoned'.
|
||||
InvoiceAvoir=Credit note
|
||||
InvoiceAvoirAsk=Credit note to correct invoice
|
||||
InvoiceAvoirDesc=The <b>credit note</b> is a negative invoice used to solve fact that an invoice has an amount that differs than amount really paid (because customer paid too much by error, or will not paid completely since he returned some products for example).
|
||||
@ -217,7 +216,6 @@ DateEcheance=Due date limit
|
||||
DateInvoice=Invoice date
|
||||
NoInvoice=No invoice
|
||||
ClassifyBill=Classify invoice
|
||||
NoSupplierBillsUnpaid=No suppliers invoices unpaid
|
||||
SupplierBillsToPay=Suppliers invoices to pay
|
||||
CustomerBillsUnpaid=Unpaid customers invoices
|
||||
DispenseMontantLettres=The bill drafted by mechanographical are exempt from the order in letters
|
||||
@ -399,6 +397,11 @@ ToMakePaymentBack=Pay back
|
||||
ListOfYourUnpaidInvoices=List of unpaid invoices
|
||||
NoteListOfYourUnpaidInvoices=Note: This list contains only invoices for third parties you are linked to as a sale representative.
|
||||
RevenueStamp=Revenue stamp
|
||||
YouMustCreateInvoiceFromThird=This option is only available when creating invoice from tab "customer" of thirdparty
|
||||
PDFCrabeDescription=Invoice PDF template Crabe. A complete invoice template (recommended Template)
|
||||
TerreNumRefModelDesc1=Return number with format %syymm-nnnn for standard invoices and %syymm-nnnn for credit notes where yy is year, mm is month and nnnn is a sequence with no break and no return to 0
|
||||
MarsNumRefModelDesc1=Return number with format %syymm-nnnn for standard invoices, %syymm-nnnn for replacement invoices, %syymm-nnnn for credit notes and %syymm-nnnn for credit notes where yy is year, mm is month and nnnn is a sequence with no break and no return to 0
|
||||
TerreNumRefModelError=A bill starting with $syymm already exists and is not compatible with this model of sequence. Remove it or rename it to activate this module.
|
||||
##### Types de contacts #####
|
||||
TypeContact_facture_internal_SALESREPFOLL=Representative following-up customer invoice
|
||||
TypeContact_facture_external_BILLING=Customer invoice contact
|
||||
@ -408,11 +411,3 @@ TypeContact_invoice_supplier_internal_SALESREPFOLL=Representative following-up s
|
||||
TypeContact_invoice_supplier_external_BILLING=Supplier invoice contact
|
||||
TypeContact_invoice_supplier_external_SHIPPING=Supplier shipping contact
|
||||
TypeContact_invoice_supplier_external_SERVICE=Supplier service contact
|
||||
# crabe PDF Model
|
||||
PDFCrabeDescription=Invoice PDF template Crabe. A complete invoice template (recommended Template)
|
||||
# oursin PDF Model
|
||||
PDFOursinDescription=Invoice PDF template Oursin. A complete invoice template (alternative Template)
|
||||
# NumRef Modules
|
||||
TerreNumRefModelDesc1=Return number with format %syymm-nnnn for standard invoices and %syymm-nnnn for credit notes where yy is year, mm is month and nnnn is a sequence with no break and no return to 0
|
||||
MarsNumRefModelDesc1=Return number with format %syymm-nnnn for standard invoices, %syymm-nnnn for replacement invoices, %syymm-nnnn for credit notes and %syymm-nnnn for credit notes where yy is year, mm is month and nnnn is a sequence with no break and no return to 0
|
||||
TerreNumRefModelError=A bill starting with $syymm already exists and is not compatible with this model of sequence. Remove it or rename it to activate this module.
|
||||
|
||||
@ -20,6 +20,7 @@ Language_en_US=English (United States)
|
||||
Language_en_ZA=English (South Africa)
|
||||
Language_es_ES=Spanish
|
||||
Language_es_AR=Spanish (Argentina)
|
||||
Language_es_CL=Spanish (Chile)
|
||||
Language_es_HN=Spanish (Honduras)
|
||||
Language_es_MX=Spanish (Mexico)
|
||||
Language_es_PY=Spanish (Paraguay)
|
||||
|
||||
@ -18,12 +18,11 @@ MarginDetails=Margin details
|
||||
|
||||
ProductMargins=Product margins
|
||||
CustomerMargins=Customer margins
|
||||
AgentMargins=Agent margins
|
||||
SalesRepresentativeMargins=Sales representative margins
|
||||
|
||||
ProductService=Product or Service
|
||||
AllProducts=All products and services
|
||||
ChooseProduct/Service=Choose product or service
|
||||
CommercialAgent=Commercial agent
|
||||
|
||||
StartDate=Start date
|
||||
EndDate=End date
|
||||
|
||||
23
htdocs/langs/es_CL/admin.lang
Normal file
23
htdocs/langs/es_CL/admin.lang
Normal file
@ -0,0 +1,23 @@
|
||||
Module20Name=Cotizaciones
|
||||
Module20Desc=Gestión de cotizaciones/propuestas comerciales
|
||||
Permission21=Consultar cotizaciones
|
||||
Permission22=Crear/modificar cotizaciones
|
||||
Permission24=Validar cotizaciones
|
||||
Permission25=Enviar las cotizaciones
|
||||
Permission26=Cerrar cotizaciones
|
||||
Permission27=Eliminar cotizaciones
|
||||
Permission28=Exportar las cotizaciones
|
||||
DictionnarySource=Orígenes de cotizaciones/pedidos
|
||||
VATIsUsedDesc=El tipo de IVA propuesto por defecto en las creaciones de cotizaciones, facturas, pedidos, etc. Responde a la siguiente regla:<br>Si el vendedor no está sujeto a IVA, IVA por defecto=0. Final de regla.<br>Si el país del vendedor= país del comprador entonces IVA por defecto=IVA del producto vendido. Final de regla.<br>Si vendedor y comprador residen en la Comunidad Europea y el bien vendido= nuevo medio de transportes (auto, barco, avión), IVA por defecto=0 (el IVA debe ser pagado por comprador a la hacienda pública de su país y no al vendedor). Final de regla<br>Si vendedor y comprador residen en la Comunidad Europea y comprador= particular o empresa sin NIF intracomunitario entonces IVA por defecto=IVA del producto vendido. Final de regla.<br>Si vendedor y comprador residen en la Comunidad Europea y comprador= empresa con NIF intracomunitario entonces IVA por defecto=0. Final de regla.<br>Si no, IVA propuesto por defecto=0. Final de regla.<br>
|
||||
VATIsNotUsedDesc=El tipo de IVA propuesto por defecto es 0. Este es el caso de asociaciones, particulares o algunas pequeñas sociedades.
|
||||
VATIsUsedExampleFR=En Francia, se trata de las sociedades u organismos que eligen un régimen fiscal general (General simplificado o General normal), régimen en el cual se declara el IVA.
|
||||
Delays_MAIN_DELAY_PROPALS_TO_CLOSE=Tolerancia de retraso antes de la alerta (en días) sobre cotizaciones a cerrar
|
||||
Delays_MAIN_DELAY_PROPALS_TO_BILL=Tolerancia de retraso antes de la alerta (en días) sobre cotizaciones no facturadas
|
||||
WebCalAddEventOnStatusPropal=Añadir evento en el calendario en el cambio de estado de las cotizaciones
|
||||
PropalSetup=Configuración del módulo Cotizaciones
|
||||
ProposalsNumberingModules=Módulos de numeración de cotizaciones
|
||||
ProposalsPDFModules=Modelos de documentos de cotizaciones
|
||||
HideTreadedPropal=Ocultar las cotizaciones procesados del listado
|
||||
FreeLegalTextOnProposal=Texto libre en cotizaciones
|
||||
WatermarkOnDraftProposal=Marca de agua en cotizaciones borrador (en caso de estar vacío)
|
||||
FCKeditorForProductDetails=Creación/edición WYSIWIG de las líneas de detalle de los productos (en pedidos, cotizaciones, facturas, etc.)
|
||||
2
htdocs/langs/es_CL/agenda.lang
Normal file
2
htdocs/langs/es_CL/agenda.lang
Normal file
@ -0,0 +1,2 @@
|
||||
PropalValidatedInDolibarr=Cotización %s validada
|
||||
ProposalSentByEMail=Cotización %s enviada por e-mail
|
||||
1
htdocs/langs/es_CL/bills.lang
Normal file
1
htdocs/langs/es_CL/bills.lang
Normal file
@ -0,0 +1 @@
|
||||
RelatedCommercialProposals=Cotizaciones asociadas
|
||||
5
htdocs/langs/es_CL/boxes.lang
Normal file
5
htdocs/langs/es_CL/boxes.lang
Normal file
@ -0,0 +1,5 @@
|
||||
BoxLastProposals=Últimas cotizaciones
|
||||
BoxTitleLastPropals=Las %s últimas cotizaciones registradas
|
||||
NoRecordedProposals=Sin cotizaciones registradas
|
||||
BoxProposalsPerMonth=Cotizaciones por mes
|
||||
ForProposals=Cotizaciones
|
||||
4
htdocs/langs/es_CL/commercial.lang
Normal file
4
htdocs/langs/es_CL/commercial.lang
Normal file
@ -0,0 +1,4 @@
|
||||
SendPropalRef=Envío de la cotización %s
|
||||
ActionAC_PROP=Envío cotización por correo
|
||||
DraftPropals=Cotizaciones borrador
|
||||
SearchPropal=Buscar una cotización
|
||||
2
htdocs/langs/es_CL/companies.lang
Normal file
2
htdocs/langs/es_CL/companies.lang
Normal file
@ -0,0 +1,2 @@
|
||||
ContactForProposals=Contacto de cotizaciones
|
||||
NoContactForAnyProposal=Este contacto no es contacto de ninguna cotización
|
||||
1
htdocs/langs/es_CL/compta.lang
Normal file
1
htdocs/langs/es_CL/compta.lang
Normal file
@ -0,0 +1 @@
|
||||
ProposalStats=Estadísticas de cotizaciones
|
||||
2
htdocs/langs/es_CL/ecm.lang
Normal file
2
htdocs/langs/es_CL/ecm.lang
Normal file
@ -0,0 +1,2 @@
|
||||
DocsProposals=Documentos cotizaciones
|
||||
ECMDocsByProposals=Documentos asociados a cotizaciones
|
||||
1
htdocs/langs/es_CL/install.lang
Normal file
1
htdocs/langs/es_CL/install.lang
Normal file
@ -0,0 +1 @@
|
||||
MigrationProposal=Migración de datos de cotizaciones
|
||||
1
htdocs/langs/es_CL/main.lang
Normal file
1
htdocs/langs/es_CL/main.lang
Normal file
@ -0,0 +1 @@
|
||||
CommercialProposalsShort=Cotizaciones
|
||||
1
htdocs/langs/es_CL/members.lang
Normal file
1
htdocs/langs/es_CL/members.lang
Normal file
@ -0,0 +1 @@
|
||||
TurnoverOrBudget=Volumen de ventas (empresa) o Cotización (asociación o colectivo)
|
||||
1
htdocs/langs/es_CL/orders.lang
Normal file
1
htdocs/langs/es_CL/orders.lang
Normal file
@ -0,0 +1 @@
|
||||
OrderSource0=Cotización
|
||||
9
htdocs/langs/es_CL/other.lang
Normal file
9
htdocs/langs/es_CL/other.lang
Normal file
@ -0,0 +1,9 @@
|
||||
Notify_PROPAL_VALIDATE=Validación cotización cliente
|
||||
Notify_PROPAL_SENTBYMAIL=Envío cotización por e-mail
|
||||
PredefinedMailContentSendProposal=Buenos días, __CONTACTCIVNAME__ \n\n Nos ponemos en contacto con usted para facilitarle la cotización __PROPREF__\n\n Ante cualquier duda, consúltenos y será atendido a la mayor brevedad posible.\n\n __PERSONALIZED__Cordialmente\n\n__SIGNATURE__
|
||||
NumberOfProposals=Número de cotizaciones en los últimos 12 meses
|
||||
NumberOfUnitsProposals=Número de unidades en las cotizaciones en los últimos 12 meses
|
||||
EMailTextProposalValidated=La cotización %s que le concierne ha sido validado.
|
||||
PropalClosedSignedInDolibarr=Cotización %s firmada en Dolibarr
|
||||
PropalClosedRefusedInDolibarr=Cotización %s rechazada en Dolibarr
|
||||
PropalValidatedInDolibarr=Cotización %s validada en Dolibarr
|
||||
3
htdocs/langs/es_CL/products.lang
Normal file
3
htdocs/langs/es_CL/products.lang
Normal file
@ -0,0 +1,3 @@
|
||||
AddToMyProposals=Añadir a mis cotizaciones
|
||||
AddToOtherProposals=Añadir a otras cotizaciones
|
||||
NoteNotVisibleOnBill=Nota (no visible en las facturas, cotizaciones, etc.)
|
||||
1
htdocs/langs/es_CL/projects.lang
Normal file
1
htdocs/langs/es_CL/projects.lang
Normal file
@ -0,0 +1 @@
|
||||
ListProposalsAssociatedProject=Listado de cotizaciones asociadas al proyecto
|
||||
62
htdocs/langs/es_CL/propal.lang
Normal file
62
htdocs/langs/es_CL/propal.lang
Normal file
@ -0,0 +1,62 @@
|
||||
Proposals=Cotizaciones
|
||||
Proposal=Cotización
|
||||
ProposalShort=Cotización
|
||||
ProposalsDraft=Cotizaciones borrador
|
||||
ProposalDraft=Cotización borrador
|
||||
ProposalsOpened=Cotizaciones abiertas
|
||||
Prop=Cotizaciones
|
||||
CommercialProposal=Cotización
|
||||
CommercialProposals=Cotizaciones
|
||||
ProposalCard=Ficha cotización
|
||||
NewProp=Nueva cotización
|
||||
NewProposal=Nueva cotización
|
||||
NewPropal=Nueva cotización
|
||||
DeletePop=Eliminar cotización
|
||||
ValidateProp=Validar cotización
|
||||
AddProp=Crear cotización
|
||||
ConfirmDeleteProp=¿Está seguro de querer eliminar esta cotización?
|
||||
ConfirmValidateProp=¿Está seguro de querer validar esta cotización bajo la referencia <b>%s</b> ?
|
||||
LastClosedProposals=Las %s últimas cotizaciones cerradas
|
||||
LastModifiedProposals=Las %s últimas cotizaciones modificadas
|
||||
AllPropals=Todas las cotizacioness
|
||||
LastProposals=Últimas cotizaciones
|
||||
SearchAProposal=Buscar una cotización
|
||||
ProposalsStatistics=Estadísticas de cotizaciones
|
||||
NumberOfUnitsProposals=Número de unidades en las cotizaciones en los últimos 12 meses
|
||||
NbOfProposals=Número cotizaciones
|
||||
ShowPropal=Ver cotización
|
||||
PropalStatusValidated=Validado (cotización abierta)
|
||||
PropalStatusOpened=Validado (cotización abierta)
|
||||
PropalsToClose=Cotizaciones a cerrar
|
||||
PropalsToBill=Cotizaciones firmadas a facturar
|
||||
ListOfProposals=Listado de cotizaciones
|
||||
ActionsOnPropal=Eventos sobre la cotización
|
||||
NoOpenedPropals=Sin cotizaciones abiertos
|
||||
NoOtherOpenedPropals=Ninguna otra cotización abierta
|
||||
RefProposal=Ref. cotización
|
||||
SendPropalByMail=Enviar cotización por e-mail
|
||||
AssociatedDocuments=Documentos asociados a la cotizacion
|
||||
DatePropal=Fecha cotización
|
||||
ErrorPropalNotFound=Presupuesto %s inexistente
|
||||
Estimate=Cotización:
|
||||
EstimateShort=Cotización
|
||||
OtherPropals=Otras cotizaciones
|
||||
AddToDraftProposals=Añadir a cotización borrador
|
||||
NoDraftProposals=Sin cotizaciones borrador
|
||||
CopyPropalFrom=Crear cotización por copia de una existente
|
||||
CreateEmptyPropal=Crear cotización vacía
|
||||
UseCustomerContactAsPropalRecipientIfExist=Utilizar dirección contacto de seguimiento de cliente definido en vez de la dirección del tercero como destinatario de las cotizaciones
|
||||
ClonePropal=Clonar cotización
|
||||
ConfirmClonePropal=¿Está seguro de querer clonar la cotización <b>%s</b>?
|
||||
ConfirmReOpenProp=¿Está seguro de querer reabrir la cotización <b>%s</b> ?
|
||||
ProposalsAndProposalsLines=Cotizaciones a clientes y líneas de cotizaciones
|
||||
ProposalLine=Línea de cotización
|
||||
##### Types de contacts #####
|
||||
TypeContact_propal_internal_SALESREPFOLL=Comercial seguimiento cotización
|
||||
TypeContact_propal_external_BILLING=Contacto cliente de facturación cotización
|
||||
TypeContact_propal_external_CUSTOMER=Contacto cliente seguimiento cotización
|
||||
# Document models
|
||||
DocModelAzurDescription=Modelo de cotización completa (logo...)
|
||||
DocModelJauneDescription=Modelo de cotización Jaune
|
||||
DefaultModelPropalToBill=Modelo por defecto al cerrar una cotización (a facturar)
|
||||
DefaultModelPropalClosed=Modelo por defecto al cerrar una cotización (no facturado)
|
||||
3
htdocs/langs/es_CL/workflow.lang
Normal file
3
htdocs/langs/es_CL/workflow.lang
Normal file
@ -0,0 +1,3 @@
|
||||
descWORKFLOW_PROPAL_AUTOCREATE_ORDER=Crear un pedido de cliente automáticamente a la firma de una cotización
|
||||
descWORKFLOW_PROPAL_AUTOCREATE_INVOICE=Crear una factura a cliente automáticamente a la firma de una cotización
|
||||
descWORKFLOW_ORDER_CLASSIFY_BILLED_PROPAL=Clasificar como facturada la cotización cuando el pedido de cliente relacionado se clasifique como pagado
|
||||
@ -109,8 +109,8 @@ ParameterInDolibarr=Variable %s
|
||||
LanguageParameter=Variable idioma %s
|
||||
LanguageBrowserParameter=Variable %s
|
||||
LocalisationDolibarrParameters=Parámetros de localización
|
||||
# ClientTZ=Client Time Zone (user)
|
||||
# ClientHour=Client time (user)
|
||||
ClientTZ=Zona horaria cliente (usuario)
|
||||
ClientHour=Hora cliente (usuario)
|
||||
OSTZ=Zona horaria Servidor SO
|
||||
PHPTZ=Zona horaria Servidor PHP
|
||||
PHPServerOffsetWithGreenwich=Offset servidor con Greenwich (segundos)
|
||||
@ -512,8 +512,8 @@ Module50200Name= Paypal
|
||||
Module50200Desc= Módulo para proporcionar un pago en línea con tarjeta de crédito mediante Paypal
|
||||
Module54000Name=PrintIPP
|
||||
Module54000Desc=Imprimir vía impresora Cups IPP.
|
||||
# Module55000Name=Open Poll
|
||||
# Module55000Desc=Module to make online polls (like Doodle, Studs, Rdvz, ...)
|
||||
Module55000Name=OpenSurvey
|
||||
Module55000Desc=Módulo para realizar encuestas online (Como Doodle, Studs, Rdvz, etc.)
|
||||
Module59000Name=Márgenes
|
||||
Module59000Desc=Módulo para gestionar los márgenes de beneficio
|
||||
Module60000Name=Comisiones
|
||||
@ -732,8 +732,8 @@ Permission50101=Usar TPV
|
||||
Permission50201=Consultar las transacciones
|
||||
Permission50202=Importar las transacciones
|
||||
Permission54001=Imprimir
|
||||
# Permission55001=Read polls
|
||||
# Permission55002=Create/modify polls
|
||||
Permission55001=Leer encuestas
|
||||
Permission55002=Crear/modificar encuestas
|
||||
Permission59001=Leer márgenes comerciales
|
||||
Permission59002=Definir márgenes comerciales
|
||||
DictionaryCompanyType=Tipos de terceros
|
||||
|
||||
@ -28,9 +28,9 @@ InvoiceReplacementDesc=La <b>factura rectificativa</b> sirve para cancelar y par
|
||||
InvoiceAvoir=Abono
|
||||
InvoiceAvoirAsk=Abono para corregir la factura
|
||||
InvoiceAvoirDesc=El <b>abono</b> es una factura negativa destinada a compensar un importe de factura que difiere del importe realmente pagado (por haber pagado de más o por devolución de productos, por ejemplo).
|
||||
# invoiceAvoirWithLines=Create Credit Note with lines from the origin invoice
|
||||
# invoiceAvoirWithPaymentRestAmount=Create Credit Note with the amount of origin invoice payment's lake
|
||||
# invoiceAvoirLineWithPaymentRestAmount=Credit Note amount of invoice payment's lake
|
||||
invoiceAvoirWithLines=Crear abono con las líneas de la factura original
|
||||
invoiceAvoirWithPaymentRestAmount=Crear abono con el importe pendiente de la factura origen
|
||||
invoiceAvoirLineWithPaymentRestAmount=Abono del importe pendiente de la factura
|
||||
ReplaceInvoice=Rectificar la factura %s
|
||||
ReplacementInvoice=Rectificación factura
|
||||
ReplacedByInvoice=Rectificada por la factura %s
|
||||
|
||||
@ -66,7 +66,7 @@ ReturnInCompany=Volver a la ficha cliente/cliente potencial
|
||||
ContentsVisibleByAll=El contenido será visible por todos
|
||||
ContentsVisibleByAllShort=Contenido visible por todos
|
||||
ContentsNotVisibleByAllShort=Contenido no visible por todos
|
||||
# CategoriesTree=Categories tree
|
||||
CategoriesTree=Árbol de categorías
|
||||
DeleteCategory=Eliminar categoría
|
||||
ConfirmDeleteCategory=¿Está seguro de querer eliminar esta categoría?
|
||||
RemoveFromCategory=Eliminar vínculo con categoría
|
||||
@ -105,9 +105,9 @@ CatProdLinks=Productos
|
||||
CatCusLinks=Clientes/Clientes potenciales
|
||||
CatSupLinks=Proveedores
|
||||
DeleteFromCat=Eliminar de la categoría
|
||||
# DeletePicture=Picture delete
|
||||
# ConfirmDeletePicture=Confirm picture deletion?
|
||||
# ExtraFieldsCategories=Complementary attributes
|
||||
# CategoriesSetup=Categories setup
|
||||
# CategorieRecursiv=Link with parent category automatically
|
||||
# CategorieRecursivHelp=If activated, product will also linked to parent category when adding into a subcategory
|
||||
DeletePicture=Eliminar imagen
|
||||
ConfirmDeletePicture=¿Confirma la eliminación de la imagen?
|
||||
ExtraFieldsCategories=Atributos complementarios
|
||||
CategoriesSetup=Configuración de categorías
|
||||
CategorieRecursiv=Enlazar con la categoría padre automáticamente
|
||||
CategorieRecursivHelp=Si está activado, el producto se enlazará a la categoría padre si lo añadimos a una subcategoría
|
||||
|
||||
@ -405,4 +405,4 @@ OutstandingBill=Importe máximo para facturas pendientes
|
||||
OutstandingBillReached=Importe máximo alcanzado
|
||||
MonkeyNumRefModelDesc=Devuelve un número bajo el formato %syymm-nnnn para los códigos de clientes y %syymm-nnnn para los códigos de los proveedores, donde yy es el año, mm el mes y nnnn un contador secuencial sin ruptura y sin volver a 0.
|
||||
LeopardNumRefModelDesc=Código de cliente/proveedor libre sin verificación. Puede ser modificado en cualquier momento.
|
||||
# ManagingDirectors=Manager(s) name (CEO, director, president...)
|
||||
ManagingDirectors=Administrador(es) (CEO, director, presidente, etc.)
|
||||
|
||||
@ -41,20 +41,20 @@ VATToCollect=IVA compras
|
||||
VATSummary=Balance de IVA
|
||||
LT2SummaryES=Balance de IRPF
|
||||
VATPaid=IVA Pagado
|
||||
# SalaryPaid=Salary paid
|
||||
SalaryPaid=Pago salario
|
||||
LT2PaidES=IRPF Pagado
|
||||
LT2CustomerES=IRPF ventas
|
||||
LT2SupplierES=IRPF compras
|
||||
VATCollected=IVA recuperado
|
||||
ToPay=A pagar
|
||||
ToGet=A devolver
|
||||
# SpecialExpensesArea=Area for all special paiements
|
||||
SpecialExpensesArea=Área de pagos especiales
|
||||
TaxAndDividendsArea=Área impuestos, cargas sociales y dividendos
|
||||
SocialContribution=Carga social
|
||||
SocialContributions=Cargas sociales
|
||||
# MenuSpecialExpenses=Special expenses
|
||||
MenuSpecialExpenses=Pagos especiales
|
||||
MenuTaxAndDividends=Impuestos y cargas
|
||||
# MenuSalaries=Salaries
|
||||
MenuSalaries=Salarios
|
||||
MenuSocialContributions=Cargas sociales
|
||||
MenuNewSocialContribution=Nueva carga
|
||||
NewSocialContribution=Nueva carga social
|
||||
@ -67,14 +67,14 @@ PaymentCustomerInvoice=Cobro factura a cliente
|
||||
PaymentSupplierInvoice=Pago factura de proveedor
|
||||
PaymentSocialContribution=Pago carga social
|
||||
PaymentVat=Pago IVA
|
||||
# PaymentSalary=Salary payment
|
||||
PaymentSalary=Pago salario
|
||||
ListPayment=Listado de pagos
|
||||
ListOfPayments=Listado de pagos
|
||||
ListOfCustomerPayments=Listado de pagos de clientes
|
||||
ListOfSupplierPayments=Listado de pagos a proveedores
|
||||
DatePayment=Fecha de pago
|
||||
# DateStartPeriod=Date start period
|
||||
# DateEndPeriod=Date end period
|
||||
DateStartPeriod=Fecha inicio periodo
|
||||
DateEndPeriod=Fecha final periodo
|
||||
NewVATPayment=Nuevo pago de IVA
|
||||
newLT2PaymentES=Nuevo pago de IRPF
|
||||
LT2PaymentES=Pago IRPF
|
||||
|
||||
@ -23,4 +23,4 @@ GoodStatusDeclaration=He recibido la mercancía en buen estado,
|
||||
Deliverer=Destinatario :
|
||||
Sender=Origen
|
||||
Recipient=Destinatario
|
||||
# ErrorStockIsNotEnough=There's not enough stock
|
||||
ErrorStockIsNotEnough=No hay suficiente stock
|
||||
|
||||
@ -125,7 +125,7 @@ BankAccountNumber=Número cuenta
|
||||
BankAccountNumberKey=Dígito Control
|
||||
SpecialCode=Código especial
|
||||
ExportStringFilter=%% permite reemplazar uno o más carácteres en el texto
|
||||
# ExportDateFilter='YYYY' 'YYYYMM' 'YYYYMMDD': filters by one year/month/day<br>'YYYY+YYYY' 'YYYYMM+YYYYMM' 'YYYYMMDD+YYYYMMDD': filters over a range of years/months/days<br>'>YYYY' '>YYYYMM' '>YYYYMMDD': filters on the following years/months/days<br>'<YYYY' '<YYYYMM' '<YYYYMMDD': filters on the previous years/months/days
|
||||
ExportDateFilter='YYYY' 'YYYYMM' 'YYYYMMDD': filtro por un año/mes/día<br>'YYYY+YYYY' 'YYYYMM+YYYYMM' 'YYYYMMDD+YYYYMMDD': filtro en un rango de años/meses/días<br>'>YYYY' '>YYYYMM' '>YYYYMMDD': filtro en los siguentes años/meses/días<br>'<YYYY' '<YYYYMM' '<YYYYMMDD': filtro en los años/meses/días anteriores
|
||||
ExportNumericFilter='NNNNN' filtros para un valor<br>'NNNNN+NNNNN' filtros sobre un rango de valores<br>'>NNNNN' filtros para valores menores<br>'>NNNNN' filtros para valores mayores
|
||||
## filters
|
||||
SelectFilterFields=Si quiere aplicar un filtro sobre algunos valores, introdúzcalos aquí.
|
||||
|
||||
@ -80,12 +80,12 @@ ActivateCheckRead=Activar confirmación de lectura y opción de desuscripción
|
||||
ActivateCheckReadKey=Clave usada para encriptar la URL de la confirmación de lectura y la función de desuscripción
|
||||
EMailSentToNRecipients=E-Mail enviado a %s destinatarios.
|
||||
EachInvoiceWillBeAttachedToEmail=Se creará y adjuntará a cada e-mail un documento usando el modelo de factura por defecto.
|
||||
# MailTopicSendRemindUnpaidInvoices=Reminder of invoice %s (%s)
|
||||
# SendRemind=Send reminder by EMails
|
||||
# RemindSent=%s reminder(s) sent
|
||||
MailTopicSendRemindUnpaidInvoices=Recordatorio de la factura %s (%s)
|
||||
SendRemind=Enviar recordatorios por e-mail
|
||||
RemindSent=%s recordatorio(s) enviados
|
||||
AllRecipientSelectedForRemind=Todos los terceros seleccionados y si hay e-mail definido (se enviará un e-mail por factura)
|
||||
# NoRemindSent=No EMail reminder sent
|
||||
# ResultOfMassSending=Result of mass EMail reminders sending
|
||||
NoRemindSent=No se han enviado recordatorios por e-mail
|
||||
ResultOfMassSending=Resultado del envío de recordatorios
|
||||
|
||||
# Libelle des modules de liste de destinataires mailing
|
||||
MailingModuleDescContactCompanies=Contactos de terceros (clientes potenciales, clientes, proveedores...)
|
||||
|
||||
@ -34,7 +34,7 @@ ErrorFailedToOpenFile=Imposible abrir el archivo %s
|
||||
ErrorCanNotCreateDir=Imposible crear el directorio %s
|
||||
ErrorCanNotReadDir=Imposible leer el directorio %s
|
||||
ErrorConstantNotDefined=Parámetro %s no definido
|
||||
# ErrorUnknown=Unknown error
|
||||
ErrorUnknown=Error desconocido
|
||||
ErrorSQL=Error de SQL
|
||||
ErrorLogoFileNotFound=El archivo logo '%s' no se encuentra
|
||||
ErrorGoToGlobalSetup=Vaya a la Configuración ' Empresa/Institución ' para corregir
|
||||
@ -60,8 +60,8 @@ ErrorNoSocialContributionForSellerCountry=Error, ningún tipo de carga social de
|
||||
ErrorFailedToSaveFile=Error, el registro del archivo falló.
|
||||
ErrorOnlyPngJpgSupported=Error, solamente se soportan los formatos de imagen jpg y png.
|
||||
ErrorImageFormatNotSupported=Su PHP no soporta las funciones de conversión de este formato de imagen.
|
||||
# SetDate=Set date
|
||||
# SelectDate=Select a date
|
||||
SetDate=Fijar fecha
|
||||
SelectDate=Seleccione una fecha
|
||||
SeeAlso=Ver también %s
|
||||
BackgroundColorByDefault=Color de fondo
|
||||
FileWasNotUploaded=Un archivo ha sido seleccionado para adjuntarlo, pero aún no se ha subido. Haga clic en "Adjuntar este archivo" para ello.
|
||||
@ -669,7 +669,7 @@ OriginFileName=Nombre del archivo origen
|
||||
SetDemandReason=Definir origen
|
||||
ViewPrivateNote=Ver notas
|
||||
XMoreLines=%s línea(s) ocultas
|
||||
# PublicUrl=Public URL
|
||||
PublicUrl=URL pública
|
||||
|
||||
# Week day
|
||||
Monday=Lunes
|
||||
|
||||
@ -1,18 +1,18 @@
|
||||
# Dolibarr language file - Source file is en_US - opensurvey
|
||||
# Survey=Poll
|
||||
# Surveys=Polls
|
||||
# OrganizeYourMeetingEasily=Organize your meetings and polls easily. First select type of poll...
|
||||
# NewSurvey=New poll
|
||||
# NoSurveysInDatabase=%s poll(s) into database.
|
||||
# OpenSurveyArea=Polls area
|
||||
# AddACommentForPoll=You can add a comment into poll...
|
||||
Survey=Encuesta
|
||||
Surveys=Encuestas
|
||||
OrganizeYourMeetingEasily=Organice sus reuniones y encuestas fácilmente. Primero seleccione el tipo de encuesta...
|
||||
NewSurvey=Nueva encuesta
|
||||
NoSurveysInDatabase=$s encuesta(s) en la base de datos.
|
||||
OpenSurveyArea=Área encuestas
|
||||
AddACommentForPoll=Puede añadir un comentario en la encuesta...
|
||||
AddComment=Añadir comentario
|
||||
CreatePoll=Crear encuesta
|
||||
PollTitle=Título de la encuesta
|
||||
# ToReceiveEMailForEachVote=Receive an email for each vote
|
||||
ToReceiveEMailForEachVote=Recibir un e-mail por cada voto
|
||||
TypeDate=Tipo fecha
|
||||
TypeClassic=Tipo estándar
|
||||
# OpenSurveyStep2=Select your dates amoung the free days (grey). The selected days are green. You can unselect a day previously selected by clicking again on it
|
||||
OpenSurveyStep2=Seleccione sus fechas entre los días libres (en gris). Los días seleccionados son de color verde. Puede cancelar la selección de un día previamente seleccionado haciendo clic de nuevo sobre el mismo
|
||||
RemoveAllDays=Eliminar todos los días
|
||||
CopyHoursOfFirstDay=Copiar horas del primer día
|
||||
RemoveAllHours=Eliminar todas las horas
|
||||
@ -24,10 +24,10 @@ OpenSurveyHowTo=Si está de acuerdo para votar en esta encuesta, tiene que dar s
|
||||
CommentsOfVoters=Comentarios de los votantes
|
||||
ConfirmRemovalOfPoll=¿Está seguro de que desea eliminar esta encuesta (y todos los votos)?
|
||||
RemovePoll=Eliminar encuesta
|
||||
# UrlForSurvey=URL to communicate to get a direct access to poll
|
||||
UrlForSurvey=URL para indicar el acceso directo a la encuesta
|
||||
PollOnChoice=Está creando una encuesta con multi-opciones. Primero introduzca todas las opciones posibles para esta encuesta:
|
||||
# CreateSurveyDate=Create a date poll
|
||||
# CreateSurveyStandard=Create a standard poll
|
||||
CreateSurveyDate=Crear una encuesta de fecha
|
||||
CreateSurveyStandard=Crear una encuesta estandard
|
||||
CheckBox=Checkbox simple
|
||||
YesNoList=Lista (vacío/sí/no)
|
||||
PourContreList=Lista (vacío/a favor/en contra)
|
||||
@ -35,7 +35,7 @@ AddNewColumn=Añadir nueva columna
|
||||
TitleChoice=Título de la opción
|
||||
ExportSpreadsheet=Exportar resultados a una hoja de cálculo
|
||||
ExpireDate=Fecha límite
|
||||
# NbOfSurveys=Number of polls
|
||||
NbOfSurveys=Número de encuestas
|
||||
NbOfVoters=Núm. de votantes
|
||||
SurveyResults=Resultados
|
||||
PollAdminDesc=Está autorizado para cambiar todas las líneas de la encuesta con el botón "Editar". Puede, también, eliminar una columna o una línea con %s. También puede añadir una nueva columna con %s.
|
||||
|
||||
@ -22,7 +22,7 @@ Notify_WITHDRAW_CREDIT=Abono domiciliación
|
||||
Notify_WITHDRAW_EMIT=Emisión domiciliación
|
||||
Notify_ORDER_SENTBYMAIL=Envío pedido de cliente por e-mail
|
||||
Notify_COMPANY_CREATE=Creación tercero
|
||||
# Notify_COMPANY_COMPANY_SENTBYMAIL=Mails sent from third party card
|
||||
Notify_COMPANY_COMPANY_SENTBYMAIL=E-mail enviado desde la ficha del tercero
|
||||
Notify_PROPAL_SENTBYMAIL=Envío presupuesto por e-mail
|
||||
Notify_ORDER_SENTBYMAIL=Envío pedido de cliente por e-mail
|
||||
Notify_BILL_PAYED=Cobro factura a cliente
|
||||
@ -41,7 +41,7 @@ Notify_MEMBER_VALIDATE=Validación miembro
|
||||
Notify_MEMBER_SUBSCRIPTION=Afiliación miembro
|
||||
Notify_MEMBER_RESILIATE=Baja miembro
|
||||
Notify_MEMBER_DELETE=Eliminación miembro
|
||||
# Notify_PROJECT_CREATE=Project creation
|
||||
Notify_PROJECT_CREATE=Creación de proyecto
|
||||
NbOfAttachedFiles=Número archivos/documentos adjuntos
|
||||
TotalSizeOfAttachedFiles=Tamaño total de los archivos/documentos adjuntos
|
||||
MaxSize=Tamaño máximo
|
||||
|
||||
@ -168,7 +168,7 @@ CloneProduct=Clonar producto/servicio
|
||||
ConfirmCloneProduct=¿Está seguro de querer clonar el producto o servicio <b>%s</b>?
|
||||
CloneContentProduct=Clonar solamente la información general del producto/servicio
|
||||
ClonePricesProduct=Clonar la información general y los precios
|
||||
# CloneCompositionProduct=Clone virtual product/services
|
||||
CloneCompositionProduct=Clonar producto/servicio virtual
|
||||
ProductIsUsed=Este producto es utilizado
|
||||
NewRefForClone=Ref. del nuevo producto/servicio
|
||||
CustomerPrices=Precios clientes
|
||||
|
||||
@ -33,9 +33,9 @@ TimesSpent=Tiempos dedicados
|
||||
RefTask=Ref. tarea
|
||||
LabelTask=Etiqueta tarea
|
||||
TaskTimeSpent=Tiempo dedicado en tareas
|
||||
# TaskTimeUser=User
|
||||
# TaskTimeNote=Note
|
||||
# TaskTimeDate=Date
|
||||
TaskTimeUser=Usuario
|
||||
TaskTimeNote=Nota
|
||||
TaskTimeDate=Fecha
|
||||
NewTimeSpent=Nuevo tiempo dedicado
|
||||
MyTimeSpent=Mi tiempo dedicado
|
||||
MyTasks=Mis tareas
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
# Dolibarr language file - Source file is en_US - users
|
||||
# Employee=Employee
|
||||
# NewSalaryPayment=New salary payment
|
||||
# SalaryPayment=Salary payment
|
||||
# SalariesPayments=Salaries payments
|
||||
# ShowSalaryPayment=Show salary payment
|
||||
Employee=Empleado
|
||||
NewSalaryPayment=Nuevo pago
|
||||
SalaryPayment=Pago de salario
|
||||
SalariesPayments=Pagos de salarios
|
||||
ShowSalaryPayment=Ver pago
|
||||
|
||||
@ -84,7 +84,7 @@ dol_fiche_head($head, 'agentMargins', $titre, 0, $picto);
|
||||
print '<form method="post" name="sel" action="'.$_SERVER['PHP_SELF'].'">';
|
||||
print '<table class="border" width="100%">';
|
||||
|
||||
print '<tr><td width="20%">'.$langs->trans('CommercialAgent').'</td>';
|
||||
print '<tr><td width="20%">'.$langs->trans('SalesRepresentative').'</td>';
|
||||
print '<td colspan="4">';
|
||||
print $form->select_dolusers($agentid,'agentid',1);
|
||||
print '</td></tr>';
|
||||
@ -155,7 +155,7 @@ if ($result)
|
||||
if ($agentid > 0)
|
||||
print_liste_field_titre($langs->trans("Customer"),$_SERVER["PHP_SELF"],"s.nom","","&agentid=".$agentid,'',$sortfield,$sortorder);
|
||||
else
|
||||
print_liste_field_titre($langs->trans("CommercialAgent"),$_SERVER["PHP_SELF"],"u.lastname","","&agentid=".$agentid,'',$sortfield,$sortorder);
|
||||
print_liste_field_titre($langs->trans("SalesRepresentative"),$_SERVER["PHP_SELF"],"u.lastname","","&agentid=".$agentid,'',$sortfield,$sortorder);
|
||||
|
||||
print_liste_field_titre($langs->trans("SellingPrice"),$_SERVER["PHP_SELF"],"selling_price","","&agentid=".$agentid,'align="right"',$sortfield,$sortorder);
|
||||
print_liste_field_titre($langs->trans("BuyingPrice"),$_SERVER["PHP_SELF"],"buying_price","","&agentid=".$agentid,'align="right"',$sortfield,$sortorder);
|
||||
|
||||
@ -73,7 +73,7 @@ function marges_prepare_head()
|
||||
$h++;
|
||||
|
||||
$head[$h][0] = DOL_URL_ROOT."/margin/agentMargins.php";
|
||||
$head[$h][1] = $langs->trans("AgentMargins");
|
||||
$head[$h][1] = $langs->trans("SalesRepresentativeMargins");
|
||||
$head[$h][2] = 'agentMargins';
|
||||
$h++;
|
||||
|
||||
@ -102,7 +102,7 @@ function getMarginInfos($pvht, $remise_percent, $tva_tx, $localtax1_tx, $localta
|
||||
if ($fk_pa > 0) {
|
||||
require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.product.class.php';
|
||||
$product = new ProductFournisseur($db);
|
||||
if ($product->fetch_product_fournisseur_price($fk_pa))
|
||||
if ($product->fetch_product_fournisseur_price($fk_pa))
|
||||
{
|
||||
$paht_ret = $product->fourn_unitprice * (1 - $product->fourn_remise_percent / 100);
|
||||
if ($conf->global->MARGIN_TYPE == "2" && $product->fourn_unitcharges > 0)
|
||||
@ -113,11 +113,11 @@ function getMarginInfos($pvht, $remise_percent, $tva_tx, $localtax1_tx, $localta
|
||||
$paht_ret = $paht;
|
||||
}
|
||||
}
|
||||
else
|
||||
else
|
||||
{
|
||||
$paht_ret = $paht;
|
||||
}
|
||||
|
||||
|
||||
// Calculate selling unit price including line discount
|
||||
// We don't use calculate_price, because this function is dedicated to calculation of total with accuracy of total. We need an accuracy of a unit price.
|
||||
// Also we must not apply rounding on non decimal rule defined by option MAIN_ROUNDING_RULE_TOT
|
||||
|
||||
@ -144,9 +144,8 @@ if ($object->id > 0)
|
||||
print "</table>\n";
|
||||
print "</div>\n";
|
||||
|
||||
$modulepart = 'projet';
|
||||
$modulepart = 'project';
|
||||
$permission = ($userWrite > 0);
|
||||
$param = '&id=' . $object->id;
|
||||
include_once DOL_DOCUMENT_ROOT . '/core/tpl/document_actions_post_headers.tpl.php';
|
||||
|
||||
}
|
||||
|
||||
@ -110,6 +110,7 @@ if ($id > 0 || ! empty($ref))
|
||||
|
||||
include_once DOL_DOCUMENT_ROOT . '/core/tpl/document_actions_pre_headers.tpl.php';
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
@ -229,9 +230,11 @@ if ($object->id > 0)
|
||||
|
||||
print '<br>';
|
||||
|
||||
$modulepart = 'projet';
|
||||
$param='';
|
||||
if ($withproject) $param .= '&withproject=1';
|
||||
$modulepart = 'project_task';
|
||||
$permission = $user->rights->projet->creer;
|
||||
$param = '&id=' . $object->id;
|
||||
$relativepathwithnofile=dol_sanitizeFileName($projectstatic->ref).'/'.dol_sanitizeFileName($object->ref).'/';
|
||||
include_once DOL_DOCUMENT_ROOT . '/core/tpl/document_actions_post_headers.tpl.php';
|
||||
}
|
||||
else
|
||||
|
||||
@ -23,10 +23,6 @@
|
||||
* \brief Page of a project task
|
||||
*/
|
||||
|
||||
error_reporting(E_ALL);
|
||||
ini_set('display_errors', true);
|
||||
ini_set('html_errors', false);
|
||||
|
||||
require ("../../main.inc.php");
|
||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/project.class.php';
|
||||
require_once DOL_DOCUMENT_ROOT.'/projet/class/task.class.php';
|
||||
|
||||
@ -313,15 +313,6 @@ class DateLibTest extends PHPUnit_Framework_TestCase
|
||||
$langs=$this->savlangs;
|
||||
$db=$this->savdb;
|
||||
|
||||
$conf->global->MAIN_OLD_DATE=1;
|
||||
|
||||
$stime='19700102';
|
||||
$result=dol_stringtotime($stime);
|
||||
print __METHOD__." result=".$result."\n";
|
||||
$this->assertEquals(86400,$result);
|
||||
|
||||
$conf->global->MAIN_OLD_DATE=0;
|
||||
|
||||
$stime='19700102';
|
||||
$result=dol_stringtotime($stime);
|
||||
print __METHOD__." result=".$result."\n";
|
||||
|
||||
@ -1,2 +1,3 @@
|
||||
"Name* (s.nom)";"Status (s.status)";"Customer* (s.client)";"Supplier* (s.fournisseur)";"DateCreation (s.datec)";"CustomerCode (s.code_client)";"SupplierCode (s.code_fournisseur)";"Address (s.address)";"Zip (s.cp)";"Town (s.ville)";"Phone (s.tel)";"Fax (s.fax)";"Url (s.url)";"Email (s.email)";"IdProf1 (s.siret)";"IdProf2 (s.siren)";"IdProf3 (s.ape)";"IdProf4 (s.idprof4)";"VATIntraShort (s.tva_intra)";"Capital (s.capital)";"Note (s.note)";"ThirdPartyType (s.fk_typent)";"Effectif (s.fk_effectif)";"JuridicalStatus (s.fk_forme_juridique)";"ProspectLevel (s.fk_prospectlevel)";"ProspectStatus (s.fk_stcomm)";"DefaultLanguage (s.default_lang)";"BarCode (s.barcode)"
|
||||
"MyBigCompanyImport1";1;3;1;01/01/00;"CU01-0001";"SU01-0001";"61 jump street";123456;"Big town";101010101;101010102;"http://mycompany.com";"test@mycompany.com";;;;;"FR0123456789";10000;"This is an example of note for record";2;3;1;"PL_MEDIUM";1;"en_US";123456789
|
||||
"MyBigCompanyImport1";1;3;1;01/01/00;"CU01-0001";"SU01-0001";"61 jump street";123456;"Big town";101010101;101010111;"http://mycompany.com";"test@mycompany.com";;;;;"FR0123456781";10000;"This is an example of note for record 1";2;3;1;"PL_MEDIUM";1;"en_US";123456781
|
||||
"MyBigCompanyImport2";1;3;1;01/01/00;"auto";;"62 jump street";123456;"Big town";101010102;101010112;"http://mycompany2.com";"test@mycompany2.com";;;;;"FR0123456782";10000;"This is an example of note for record 2";2;3;1;"PL_MEDIUM";1;"en_US";auto
|
||||
|
||||
|
@ -162,7 +162,7 @@ class FilesLibTest extends PHPUnit_Framework_TestCase
|
||||
$file=dirname(__FILE__).'/Example_import_company_1.csv';
|
||||
$result=dol_count_nb_of_line($file);
|
||||
print __METHOD__." result=".$result."\n";
|
||||
$this->assertEquals(2,$result);
|
||||
$this->assertEquals(3,$result);
|
||||
|
||||
return $result;
|
||||
}
|
||||
|
||||
@ -367,6 +367,14 @@ class FunctionsLibTest extends PHPUnit_Framework_TestCase
|
||||
*/
|
||||
public function testDolMkTime()
|
||||
{
|
||||
global $conf;
|
||||
|
||||
$savtz=date_default_timezone_get();
|
||||
|
||||
// Some test for UTC TZ
|
||||
date_default_timezone_set('UTC');
|
||||
|
||||
// Check bad hours
|
||||
$result=dol_mktime(25,0,0,1,1,1970,1,1); // Error (25 hours)
|
||||
print __METHOD__." result=".$result."\n";
|
||||
$this->assertEquals('',$result);
|
||||
@ -390,7 +398,22 @@ class FunctionsLibTest extends PHPUnit_Framework_TestCase
|
||||
$result=dol_mktime(2,0,0,1,1,1970,0); // 1970-01-01 02:00:00 = 7200 in local area Europe/Paris = 3600 GMT
|
||||
print __METHOD__." result=".$result."\n";
|
||||
$tz=getServerTimeZoneInt('winter'); // +1 in Europe/Paris at this time (this time is winter)
|
||||
$this->assertEquals(7200-($tz*3600),$result); // Should be 7200 if we are at greenwich winter
|
||||
$this->assertEquals(7200-($tz*3600),$result); // 7200 if we are at greenwich winter, 7200-($tz*3600) at local winter
|
||||
|
||||
// Some test for local TZ Europe/Paris
|
||||
date_default_timezone_set('Europe/Paris');
|
||||
|
||||
// Check that tz for paris in winter is used
|
||||
$result=dol_mktime(2,0,0,1,1,1970,'server'); // 1970-01-01 02:00:00 = 7200 in local area Europe/Paris = 3600 GMT
|
||||
print __METHOD__." result=".$result."\n";
|
||||
$this->assertEquals(3600,$result); // 7200 if we are at greenwich winter, 3600 at Europe/Paris
|
||||
|
||||
// Check that daylight saving time is used
|
||||
$result=dol_mktime(2,0,0,6,1,2014,0); // 2014-06-01 02:00:00 = 1401588000-3600(location)-3600(daylight) in local area Europe/Paris = 1401588000 GMT
|
||||
print __METHOD__." result=".$result."\n";
|
||||
$this->assertEquals(1401588000-3600-3600,$result); // 1401588000 are at greenwich summer, 1401588000-3600(location)-3600(daylight) at Europe/Paris summer
|
||||
|
||||
date_default_timezone_set($savtz);
|
||||
}
|
||||
|
||||
|
||||
@ -574,11 +597,11 @@ class FunctionsLibTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
// Test RULE 2 (FR-FR)
|
||||
$vat=get_default_tva($companyfr,$companyfr,0);
|
||||
$this->assertEquals(19.6,$vat);
|
||||
$this->assertEquals(20,$vat);
|
||||
|
||||
// Test RULE 2 (FR-MC)
|
||||
$vat=get_default_tva($companyfr,$companymc,0);
|
||||
$this->assertEquals(19.6,$vat);
|
||||
$this->assertEquals(20,$vat);
|
||||
|
||||
// Test RULE 3 (FR-IT)
|
||||
$vat=get_default_tva($companyfr,$companyit,0);
|
||||
@ -586,7 +609,7 @@ class FunctionsLibTest extends PHPUnit_Framework_TestCase
|
||||
|
||||
// Test RULE 4 (FR-IT)
|
||||
$vat=get_default_tva($companyfr,$notcompanyit,0);
|
||||
$this->assertEquals(19.6,$vat);
|
||||
$this->assertEquals(20,$vat);
|
||||
|
||||
// Test RULE 5 (FR-US)
|
||||
$vat=get_default_tva($companyfr,$companyus,0);
|
||||
|
||||
@ -125,7 +125,10 @@ class ImportTest extends PHPUnit_Framework_TestCase
|
||||
{
|
||||
$file=dirname(__FILE__).'/Example_import_company_1.csv';
|
||||
|
||||
//if (! preg_match('/^[0-9][0-9][0-9][0-9]-[0-9][0-9]-[0-9][0-9]$/i','2012-03-23')) print 'eeeeeeeeeeee';
|
||||
// TODO
|
||||
// Run import on file and check the record with field "auto" are filled
|
||||
// according to option
|
||||
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user