Merge remote-tracking branch 'upstream/develop' into dolibarr-3509

Conflicts:
	htdocs/install/mysql/migration/3.8.0-3.9.0.sql
This commit is contained in:
Juanjo Menent 2015-10-03 14:59:56 +02:00
commit 67d28d6991
1233 changed files with 405 additions and 12166 deletions

View File

@ -10,13 +10,12 @@ beta version of Dolibarr, step by step.
- Check all files are commited.
- Update version/info in ChangeLog. To generate a changelog, you can do "git log `git merge-base 3.7.0 origin/develop`.. --no-merges --pretty=short --oneline | sed -e "s/^[0-9a-z]* //" | grep -e '^FIX\|NEW' | sort -u | sed 's/FIXED:/FIX:/g' | sed 's/FIXED :/FIX:/g' | sed 's/FIX :/FIX:/g' | sed 's/FIX /FIX: /g' | sed 's/NEW :/NEW:/g' | sed 's/NEW /NEW: /g' > /tmp/aaa"
- Update version number with x.y.z-w in htdocs/filefunc.inc.php
- Update version number with x.y.z-w in build/debian/changelog
- Commit all changes.
- Add a Tag (x.y.z-beta) and push it: git push --tags
- Create a branch (x.y).
- Run makepack-dolibarr.pl to generate all packages.
- Create a branch (x.y), if version seems stable enough.
- Move build files into www.dolibarr.org web site
(/home/dolibarr/wwwroot/files/lastbuild).
@ -31,7 +30,6 @@ complete release of Dolibarr, step by step.
- Check all files are commited.
- Update version/info in ChangeLog. To generate a changelog, you can do "git log `git merge-base 3.7.0 origin/develop`.. --no-merges --pretty=short --oneline | sed -e "s/^[0-9a-z]* //" | grep -e '^FIX\|NEW' | sort -u | sed 's/FIXED:/FIX:/g' | sed 's/FIXED :/FIX:/g' | sed 's/FIX :/FIX:/g' | sed 's/FIX /FIX: /g' | sed 's/NEW :/NEW:/g' | sed 's/NEW /NEW: /g' > /tmp/aaa"
- Update version number with x.y.z in htdocs/filefunc.inc.php
- Update version number with x.y.z in build/debian/changelog
- Commit all changes.
- Run makepack-dolibarr.pl to generate all packages.

View File

@ -35,19 +35,10 @@ require_once DOL_DOCUMENT_ROOT . '/core/class/commonobject.class.php';
* Class Skeleton_Class
*
* Put here description of your class
* @see CommonObject
*/
class Skeleton_Class extends CommonObject
{
/**
* @var string Error code (or message)
* @deprecated
* @see Skeleton_Class::errors
*/
public $error;
/**
* @var string[] Error codes (or messages)
*/
public $errors = array();
/**
* @var string Id to identify managed objects
*/
@ -62,10 +53,6 @@ class Skeleton_Class extends CommonObject
*/
public $lines = array();
/**
* @var int ID
*/
public $id;
/**
* @var mixed Sample property 1
*/

View File

@ -30,11 +30,6 @@
*/
class AccountingAccount extends CommonObject
{
var $db;
var $error;
var $errors;
var $id;
var $rowid;
var $datec; // Creation date

View File

@ -29,11 +29,6 @@
*/
class BookKeeping extends CommonObject
{
var $db;
var $error;
var $errors;
var $id;
var $doc_date;
var $doc_type;
var $doc_ref;

View File

@ -30,12 +30,6 @@ include_once DOL_DOCUMENT_ROOT.'/adherents/canvas/actions_adherentcard_common.cl
*/
class ActionsAdherentCardDefault extends ActionsAdherentCardCommon
{
var $db;
var $dirmodule;
var $targetmodule;
var $canvas;
var $card;
/**
* Constructor
*

View File

@ -44,18 +44,8 @@ class Adherent extends CommonObject
public $table_element='adherent';
protected $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
var $error;
var $errors;
var $mesgs;
var $id;
var $ref;
public $ref_ext;
var $civility_id;
var $firstname;
var $lastname;
var $login;
var $pass;
var $societe;
@ -68,10 +58,6 @@ class Adherent extends CommonObject
var $state_code; // Code of department
var $state; // Label of department
var $country_id;
var $country_code;
var $country;
var $email;
var $skype;
var $phone;
@ -80,8 +66,6 @@ class Adherent extends CommonObject
var $morphy;
var $public;
var $note_private; // Private note
var $note_public; // Public note
var $statut; // -1:brouillon, 0:resilie, >=1:valide,paye
var $photo;
@ -99,7 +83,6 @@ class Adherent extends CommonObject
var $user_login;
var $fk_soc;
var $thirdparty; // Loaded by ->fetch_thirdparty()
// Fields loaded by fetch_subscriptions()
var $first_subscription_date;
@ -110,9 +93,6 @@ class Adherent extends CommonObject
var $last_subscription_amount;
var $subscriptions=array();
// var $public;
var $array_options;
var $oldcopy; // To contains a clone of this when we need to save old properties of object
public $entity;

View File

@ -35,18 +35,9 @@ class AdherentType extends CommonObject
public $table_element = 'adherent_type';
public $element = 'adherent_type';
var $id;
/**
* @var int
*/
public $ref;
var $libelle;
var $statut;
var $cotisation; // Soumis a la cotisation
var $vote; // droit de vote
var $note; // commentaire
var $mail_valid; //mail envoye lors de la validation

View File

@ -33,16 +33,12 @@ class Cotisation extends CommonObject
public $element='subscription';
public $table_element='cotisation';
var $id;
var $ref;
var $datec; // Date creation
var $datem; // Date modification
var $dateh; // Subscription start date (date subscription)
var $datef; // Subscription end date
var $fk_adherent;
var $amount;
var $note;
var $fk_bank;

View File

@ -74,8 +74,9 @@ if (preg_match('/del_(.*)/',$action,$reg))
if ($action == 'set')
{
dolibarr_set_const($db, 'AGENDA_DEFAULT_FILTER_TYPE', GETPOST('AGENDA_DEFAULT_FILTER_TYPE'), 'chaine', 0, '', $conf->entity);
dolibarr_set_const($db, 'AGENDA_DEFAULT_FILTER_STATUS', GETPOST('AGENDA_DEFAULT_FILTER_STATUS'), 'chaine', 0, '', $conf->entity);
dolibarr_set_const($db, 'AGENDA_USE_EVENT_TYPE_DEFAULT', GETPOST('AGENDA_USE_EVENT_TYPE_DEFAULT'), 'chaine', 0, '', $conf->entity);
dolibarr_set_const($db, 'AGENDA_DEFAULT_FILTER_TYPE', GETPOST('AGENDA_DEFAULT_FILTER_TYPE'), 'chaine', 0, '', $conf->entity);
dolibarr_set_const($db, 'AGENDA_DEFAULT_FILTER_STATUS', GETPOST('AGENDA_DEFAULT_FILTER_STATUS'), 'chaine', 0, '', $conf->entity);
dolibarr_set_const($db, 'AGENDA_DEFAULT_VIEW', GETPOST('AGENDA_DEFAULT_VIEW'), 'chaine', 0, '', $conf->entity);
}
@ -127,6 +128,17 @@ else
}
print '</td></tr>'."\n";
if (! empty($conf->global->AGENDA_USE_EVENT_TYPE))
{
$var=!$var;
print '<tr '.$bc[$var].'>'."\n";
print '<td>'.$langs->trans("AGENDA_USE_EVENT_TYPE_DEFAULT").'</td>'."\n";
print '<td align="center">&nbsp;</td>'."\n";
print '<td align="right" class="nowrap">'."\n";
$formactions->select_type_actions($conf->global->AGENDA_USE_EVENT_TYPE_DEFAULT, "AGENDA_USE_EVENT_TYPE_DEFAULT", '', 0, 1);
print '</td></tr>'."\n";
}
// AGENDA_DEFAULT_FILTER_TYPE
$var=!$var;
print '<tr '.$bc[$var].'>'."\n";

View File

@ -414,9 +414,9 @@ if ($action == 'edit' || $action == 'updateedit')
// Forme juridique
$var=!$var;
print '<tr '.$bc[$var].'><td><label for="legal_form">'.$langs->trans("JuridicalStatus").'</label></td><td>';
print '<tr '.$bc[$var].'><td><label for="forme_juridique_code">'.$langs->trans("JuridicalStatus").'</label></td><td>';
if ($mysoc->country_code) {
print $formcompany->select_juridicalstatus($conf->global->MAIN_INFO_SOCIETE_FORME_JURIDIQUE, $mysoc->country_code, '', 'legal_form');
print $formcompany->select_juridicalstatus($conf->global->MAIN_INFO_SOCIETE_FORME_JURIDIQUE, $mysoc->country_code, '', 'forme_juridique_code');
} else {
print $countrynotdefined;
}

View File

@ -151,7 +151,7 @@ $tabsql[8] = "SELECT t.id as rowid, t.code as code, t.libelle, t.fk_country a
$tabsql[9] = "SELECT c.code_iso as code, c.label, c.unicode, c.active FROM ".MAIN_DB_PREFIX."c_currencies AS c";
$tabsql[10]= "SELECT t.rowid, t.taux, t.localtax1_type, t.localtax1, t.localtax2_type, t.localtax2, c.label as country, c.code as country_code, t.fk_pays as country_id, t.recuperableonly, t.note, t.active, t.accountancy_code_sell, t.accountancy_code_buy FROM ".MAIN_DB_PREFIX."c_tva as t, ".MAIN_DB_PREFIX."c_country as c WHERE t.fk_pays=c.rowid";
$tabsql[11]= "SELECT t.rowid as rowid, element, source, code, libelle, active FROM ".MAIN_DB_PREFIX."c_type_contact AS t";
$tabsql[12]= "SELECT c.rowid as rowid, c.code, c.sortorder, c.libelle, c.libelle_facture, nbjour, fdm, decalage, active FROM ".MAIN_DB_PREFIX.'c_payment_term AS c';
$tabsql[12]= "SELECT c.rowid as rowid, c.code, c.libelle, c.libelle_facture, c.nbjour, c.fdm, c.decalage, c.active, c.sortorder FROM ".MAIN_DB_PREFIX.'c_payment_term AS c';
$tabsql[13]= "SELECT c.id as rowid, c.code, c.libelle, c.type, c.active, c.accountancy_code FROM ".MAIN_DB_PREFIX."c_paiement AS c";
$tabsql[14]= "SELECT e.rowid as rowid, e.code as code, e.libelle, e.price, e.organization, e.fk_pays as country_id, c.code as country_code, c.label as country, e.active FROM ".MAIN_DB_PREFIX."c_ecotaxe AS e, ".MAIN_DB_PREFIX."c_country as c WHERE e.fk_pays=c.rowid and c.active=1";
$tabsql[15]= "SELECT rowid as rowid, code, label as libelle, width, height, unit, active FROM ".MAIN_DB_PREFIX."c_paper_format";
@ -215,7 +215,7 @@ $tabfield[8] = "code,libelle,country_id,country";
$tabfield[9] = "code,label,unicode";
$tabfield[10]= "country_id,country,taux,recuperableonly,localtax1_type,localtax1,localtax2_type,localtax2,accountancy_code_sell,accountancy_code_buy,note";
$tabfield[11]= "element,source,code,libelle";
$tabfield[12]= "code,libelle,libelle_facture,nbjour,fdm,decalage";
$tabfield[12]= "code,libelle,libelle_facture,nbjour,fdm,decalage,sortorder";
$tabfield[13]= "code,libelle,type,accountancy_code";
$tabfield[14]= "code,libelle,price,organization,country_id,country";
$tabfield[15]= "code,libelle,width,height,unit";
@ -247,7 +247,7 @@ $tabfieldvalue[8] = "code,libelle,country";
$tabfieldvalue[9] = "code,label,unicode";
$tabfieldvalue[10]= "country,taux,recuperableonly,localtax1_type,localtax1,localtax2_type,localtax2,accountancy_code_sell,accountancy_code_buy,note";
$tabfieldvalue[11]= "element,source,code,libelle";
$tabfieldvalue[12]= "code,libelle,libelle_facture,nbjour,fdm,decalage";
$tabfieldvalue[12]= "code,libelle,libelle_facture,nbjour,fdm,decalage,sortorder";
$tabfieldvalue[13]= "code,libelle,type,accountancy_code";
$tabfieldvalue[14]= "code,libelle,price,organization,country";
$tabfieldvalue[15]= "code,libelle,width,height,unit";
@ -279,7 +279,7 @@ $tabfieldinsert[8] = "code,libelle,fk_country";
$tabfieldinsert[9] = "code_iso,label,unicode";
$tabfieldinsert[10]= "fk_pays,taux,recuperableonly,localtax1_type,localtax1,localtax2_type,localtax2,accountancy_code_sell,accountancy_code_buy,note";
$tabfieldinsert[11]= "element,source,code,libelle";
$tabfieldinsert[12]= "code,libelle,libelle_facture,nbjour,fdm,decalage";
$tabfieldinsert[12]= "code,libelle,libelle_facture,nbjour,fdm,decalage,sortorder";
$tabfieldinsert[13]= "code,libelle,type,accountancy_code";
$tabfieldinsert[14]= "code,libelle,price,organization,fk_pays";
$tabfieldinsert[15]= "code,label,width,height,unit";
@ -1595,6 +1595,7 @@ function fieldList($fieldlist, $obj='', $tabname='', $context='')
if ($fieldlist[$field]=='accountancy_code') $size='size="10" ';
if ($fieldlist[$field]=='accountancy_code_sell') $size='size="10" ';
if ($fieldlist[$field]=='accountancy_code_buy') $size='size="10" ';
if ($fieldlist[$field]=='sortorder') $size='size="2" ';
print '<input type="text" '.$size.' class="flat" value="'.(isset($obj->$fieldlist[$field])?$obj->$fieldlist[$field]:'').'" name="'.$fieldlist[$field].'">';
print '</td>';
}

View File

@ -63,8 +63,7 @@ if ($action == 'update')
dolibarr_set_const($db, "MAIN_DEFAULT_WORKING_DAYS", $_POST["MAIN_DEFAULT_WORKING_DAYS"],'chaine',0,'',$conf->entity);
dolibarr_set_const($db, "MAIN_DEFAULT_WORKING_HOURS", $_POST["MAIN_DEFAULT_WORKING_HOURS"],'chaine',0,'',$conf->entity);
dolibarr_set_const($db, "MAIN_SHOW_LOGO", $_POST["MAIN_SHOW_LOGO"],'chaine',0,'',$conf->entity);
dolibarr_set_const($db, "MAIN_ACTIVATE_HTML5", $_POST["MAIN_ACTIVATE_HTML5"],'chaine',0,'',$conf->entity);
dolibarr_set_const($db, "MAIN_ACTIVATE_FILECACHE", $_POST["MAIN_ACTIVATE_FILECACHE"],'chaine',0,'',$conf->entity);
dolibarr_set_const($db, "MAIN_ACTIVATE_FILECACHE", $_POST["MAIN_ACTIVATE_FILECACHE"],'chaine',0,'',$conf->entity);
dolibarr_set_const($db, "MAIN_FIRSTNAME_NAME_POSITION", $_POST["MAIN_FIRSTNAME_NAME_POSITION"],'chaine',0,'',$conf->entity);
dolibarr_set_const($db, "MAIN_THEME", $_POST["main_theme"],'chaine',0,'',$conf->entity);
@ -90,8 +89,8 @@ if ($action == 'update')
dolibarr_set_const($db, "MAIN_HELP_DISABLELINK", $_POST["MAIN_HELP_DISABLELINK"],'chaine',0,'',0); // Param for all entities
dolibarr_set_const($db, "MAIN_BUGTRACK_ENABLELINK", $_POST["MAIN_BUGTRACK_ENABLELINK"],'chaine',0,'',$conf->entity);
if (GETPOST('check_THEME_ELDY_USE_HOVER') == 'on') dolibarr_set_const($db,"THEME_ELDY_USE_HOVER", 1,'chaine',0,'',$conf->entity);
else dolibarr_set_const($db,"THEME_ELDY_USE_HOVER",0,'chaine',0,'',$conf->entity);
if (GETPOST('THEME_ELDY_USE_HOVER') == '') dolibarr_del_const($db, "THEME_ELDY_USE_HOVER", $conf->entity);
else dolibarr_set_const($db, "THEME_ELDY_USE_HOVER", $_POST["THEME_ELDY_USE_HOVER"], 'chaine', 0, '', $conf->entity);
// This one is not always defined
if (isset($_POST["MAIN_USE_PREVIEW_TABS"])) dolibarr_set_const($db, "MAIN_USE_PREVIEW_TABS", $_POST["MAIN_USE_PREVIEW_TABS"],'chaine',0,'',$conf->entity);
@ -189,17 +188,6 @@ if ($action == 'edit') // Edit
print '<td width="20">&nbsp;</td>';
print '</tr>';
// Activate Html5 - Developement - Only available on Eldy template
if ($conf->global->MAIN_FEATURES_LEVEL == 2 || ! empty($conf->global->MAIN_ACTIVATE_HTML5))
{
$var=!$var;
print '<tr '.$bc[$var].'><td width="35%">'.$langs->trans("EnableHtml5").'</td><td>';
print $form->selectyesno('MAIN_ACTIVATE_HTML5',$conf->global->MAIN_ACTIVATE_HTML5,1);
print '</td>';
print '<td width="20">&nbsp;</td>';
print '</tr>';
}
// Activate FileCache - Developement
if ($conf->global->MAIN_FEATURES_LEVEL == 2 || ! empty($conf->global->MAIN_ACTIVATE_FILECACHE)) {
$var=!$var;
@ -385,15 +373,6 @@ else // Show
print '<td width="20">&nbsp;</td>';
print "</tr>";
// Activate Html5 - Developement - Only available on Eldy template
if ($conf->global->MAIN_FEATURES_LEVEL == 2 || ! empty($conf->global->MAIN_ACTIVATE_HTML5))
{
$var=!$var;
print '<tr '.$bc[$var].'><td>'.$langs->trans("EnableHtml5").'</td><td>' . yn($conf->global->MAIN_ACTIVATE_HTML5) . '</td>';
print '<td width="20">&nbsp;</td>';
print "</tr>";
}
// Activate FileCache - Developement
if ($conf->global->MAIN_FEATURES_LEVEL == 2 || ! empty($conf->global->MAIN_ACTIVATE_FILECACHE)) {
$var=!$var;

View File

@ -419,7 +419,7 @@ else if ($id || $ref)
// Ref
print '<tr><td width="20%">'.$langs->trans("Ref").'</td>';
print '<td class="valeur">';
print $form->showrefnav($member,'id','','1','rowid','ref','','&type=3');
print $form->showrefnav($member,'id','','1','rowid','ref','','&type='.$type);
print '</td></tr>';
// Login

View File

@ -112,7 +112,6 @@ class Categorie extends CommonObject
public $element='category';
public $table_element='categories';
var $id;
var $fk_parent;
var $label;
var $description;
@ -134,7 +133,6 @@ class Categorie extends CommonObject
* @see Categorie::TYPE_CONTACT
*/
var $type;
var $import_key;
var $cats=array(); // Tableau en memoire des categories
var $motherof=array();
@ -230,6 +228,8 @@ class Categorie extends CommonObject
$error=0;
dol_syslog(get_class($this).'::create', LOG_DEBUG);
// Clean parameters
$this->label = trim($this->label);
$this->description = trim($this->description);
@ -248,7 +248,6 @@ class Categorie extends CommonObject
$this->db->begin();
dol_syslog(get_class($this).'::create', LOG_DEBUG);
$sql = "INSERT INTO ".MAIN_DB_PREFIX."categorie (";
$sql.= "fk_parent,";
$sql.= " label,";
@ -277,7 +276,6 @@ class Categorie extends CommonObject
$sql.= $conf->entity;
$sql.= ")";
dol_syslog(get_class($this).'::create', LOG_DEBUG);
$res = $this->db->query($sql);
if ($res)
{

View File

@ -647,7 +647,8 @@ if ($action == 'create')
if (! empty($conf->global->AGENDA_USE_EVENT_TYPE))
{
print '<tr><td width="30%"><span class="fieldrequired">'.$langs->trans("Type").'</span></b></td><td>';
$formactions->select_type_actions(GETPOST("actioncode")?GETPOST("actioncode"):$object->type_code, "actioncode","systemauto");
$default=(empty($conf->global->AGENDA_USE_EVENT_TYPE_DEFAULT)?'':$conf->global->AGENDA_USE_EVENT_TYPE_DEFAULT);
$formactions->select_type_actions(GETPOST("actioncode")?GETPOST("actioncode"):($object->type_code?$object->type_code:$default), "actioncode","systemauto");
print '</td></tr>';
}

View File

@ -107,7 +107,6 @@ class ActionComm extends CommonObject
var $transparency; // Transparency (ical standard). Used to say if people assigned to event are busy or not by event. 0=available, 1=busy, 2=busy (refused events)
var $priority; // Small int (0 By default)
var $note; // Description
var $userassigned = array(); // Array of user ids
var $userownerid; // Id of user owner = fk_user_action into table
@ -148,12 +147,6 @@ class ActionComm extends CommonObject
*/
var $contact;
/**
* Id of project (optional)
* @var int
*/
var $fk_project;
// Properties for links to other objects
var $fk_element; // Id of record
var $elementtype; // Type of record. This if property ->element of object linked to.

View File

@ -1210,7 +1210,7 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa
// We decide to choose color of owner of event (event->userownerid is user id of owner, event->userassigned contains all users assigned to event)
if (! empty($cacheusers[$event->userownerid]->color)) $color=$cacheusers[$event->userownerid]->color;
}
else if ($event->type_code == 'ICALEVENT')
else if ($event->type_code == 'ICALEVENT') // Event come from external ical file
{
$numical++;
if (! empty($event->icalname)) {
@ -1220,7 +1220,7 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa
$numicals[dol_string_nospecial($event->icalname)]++;
}
$color=$event->icalcolor;
$cssclass=(! empty($event->icalname)?'family_ext'.md5($event->icalname):'family_other unmovable');
$cssclass=(! empty($event->icalname)?'family_ext'.md5($event->icalname):'family_other');
}
else if ($event->type_code == 'BIRTHDAY')
{
@ -1266,6 +1266,10 @@ function show_day_events($db, $day, $month, $year, $monthshown, $style, &$eventa
{
$cssclass.= " unmovable";
}
else if ($event->type_code == 'ICALEVENT')
{
$cssclass.= " unmovable";
}
else if ($event->date_end_in_calendar && date('Ymd',$event->date_start_in_calendar) != date('Ymd',$event->date_end_in_calendar))
{
$tmpyearend = date('Y',$event->date_end_in_calendar);

View File

@ -53,18 +53,13 @@ class AskPriceSupplier extends CommonObject
*/
protected $table_ref_field = 'ref';
var $id;
var $socid; // Id client
var $client; // Objet societe client (a charger par fetch_client)
var $fk_project;
/**
* @deprecated
* @see user_author_id
*/
var $author;
var $ref;
var $ref_fourn; //Reference saisie lors de l'ajout d'une ligne à la demande
var $statut; // 0 (draft), 1 (validated), 2 (signed), 3 (not signed), 4 (billed)
var $date; // Date of proposal
@ -99,12 +94,6 @@ class AskPriceSupplier extends CommonObject
var $user_valid_id;
var $user_close_id;
var $total_ht; // Total net of tax
var $total_tva; // Total VAT
var $total_localtax1; // Total Local Taxes 1
var $total_localtax2; // Total Local Taxes 2
var $total_ttc; // Total with tax
/**
* @deprecated
* @see price_ht
@ -121,22 +110,11 @@ class AskPriceSupplier extends CommonObject
*/
var $total;
var $cond_reglement_id;
var $cond_reglement_code;
var $fk_account; // Id of bank account
var $mode_reglement_id;
var $mode_reglement_code;
var $remise;
var $remise_percent;
var $remise_absolue;
/**
* @deprecated
* @see note_public, note_private
*/
var $note;
var $note_private;
var $note_public;
var $shipping_method_id;
var $products=array();
var $extraparams=array();
@ -144,9 +122,6 @@ class AskPriceSupplier extends CommonObject
var $lines = array();
var $line;
var $origin;
var $origin_id;
var $labelstatut=array();
var $labelstatut_short=array();

View File

@ -34,8 +34,6 @@ class Mailing extends CommonObject
public $element='mailing';
public $table_element='mailing';
var $id;
var $statut;
var $titre;
var $sujet;
var $body;

View File

@ -2121,18 +2121,20 @@ if ($action == 'create')
if ($action != 'statut' && $action != 'editline')
{
// Validate
if ($object->statut == Propal::STATUS_DRAFT && $object->total_ttc >= 0 && count($object->lines) > 0 &&
((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->propal->creer))
if ($object->statut == Propal::STATUS_DRAFT && $object->total_ttc >= 0 && count($object->lines) > 0)
{
if ((empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->propal->creer))
|| (! empty($conf->global->MAIN_USE_ADVANCED_PERMS) && ! empty($user->rights->propal->propal_advance->validate)))
) {
if (count($object->lines) > 0)
{
print '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . '?id=' . $object->id . '&amp;action=validate">' . $langs->trans('Validate') . '</a></div>';
// else print '<a class="butActionRefused" href="#">'.$langs->trans('Validate').'</a>';
}
else
print '<div class="inline-block divButAction"><a class="butActionRefused" href="#">' . $langs->trans('Validate') . '</a></div>';
}
// Create event
if ($conf->agenda->enabled && ! empty($conf->global->MAIN_ADD_EVENT_ON_ELEMENT_CARD)) // Add hidden condition because this is not a "workflow" action so should appears somewhere else on page.
{
print '<a class="butAction" href="' . DOL_URL_ROOT . '/comm/action/card.php?action=create&amp;origin=' . $object->element . '&amp;originid=' . $object->id . '&amp;socid=' . $object->socid . '">' . $langs->trans("AddAction") . '</a>';
print '<div class="inline-block divButAction"><a class="butAction" href="' . DOL_URL_ROOT . '/comm/action/card.php?action=create&amp;origin=' . $object->element . '&amp;originid=' . $object->id . '&amp;socid=' . $object->socid . '">' . $langs->trans("AddAction") . '</a></div>';
}
// Edit
if ($object->statut == Propal::STATUS_VALIDATED && $user->rights->propal->creer) {

View File

@ -54,23 +54,14 @@ class Propal extends CommonObject
*/
protected $table_ref_field = 'ref';
var $id;
/**
* ID of the client
* @var int
*/
var $socid;
/**
* Client (loaded by fetch_client)
* @var Societe
*/
var $client;
var $contactid;
var $fk_project;
var $author;
var $ref;
var $ref_client;
/**
@ -122,12 +113,6 @@ class Propal extends CommonObject
var $user_valid_id;
var $user_close_id;
var $total_ht; // Total net of tax
var $total_tva; // Total VAT
var $total_localtax1; // Total Local Taxes 1
var $total_localtax2; // Total Local Taxes 2
var $total_ttc; // Total with tax
/**
* @deprecated
* @see total_ht
@ -144,29 +129,14 @@ class Propal extends CommonObject
*/
var $total;
var $cond_reglement_id;
var $cond_reglement_code;
var $fk_account; // Id of bank account
var $mode_reglement_id;
var $mode_reglement_code;
var $remise;
var $remise_percent;
var $remise_absolue;
/**
* @deprecated
* @see note_private, note_public
*/
var $note;
var $note_private;
var $note_public;
/**
* @deprecated
*/
var $fk_delivery_address;
var $fk_address;
var $address_type;
var $address;
var $shipping_method_id;
var $availability_id;
var $availability_code;
var $demand_reason_id;
@ -181,19 +151,11 @@ class Propal extends CommonObject
var $lines = array();
var $line;
var $origin;
var $origin_id;
var $labelstatut=array();
var $labelstatut_short=array();
var $specimen;
//Incorterms
var $fk_incoterms;
var $location_incoterms;
var $libelle_incoterms; //Used into tooltip
/**
* Draft status
*/

View File

@ -51,26 +51,15 @@ class Commande extends CommonOrder
*/
protected $table_ref_field = 'ref';
var $id;
/**
* Client ID
* @var int
*/
var $socid;
/**
* Client (loaded by fetch_client)
* @var Societe
*/
var $client;
var $ref;
var $ref_client;
var $ref_ext;
var $ref_int;
var $contactid;
var $fk_project;
/**
* Status of the order. Check the following constants:
@ -86,16 +75,12 @@ class Commande extends CommonOrder
var $billed; // billed or not
var $brouillon;
var $cond_reglement_id;
var $cond_reglement_code;
var $fk_account;
var $mode_reglement_id;
var $mode_reglement_code;
var $availability_id;
var $availability_code;
var $demand_reason_id;
var $demand_reason_code;
var $fk_delivery_address;
var $address;
var $date; // Date commande
/**
@ -104,31 +89,15 @@ class Commande extends CommonOrder
*/
var $date_commande;
var $date_livraison; // Date livraison souhaitee
var $shipping_method_id;
var $fk_remise_except;
var $remise_percent;
var $total_ht; // Total net of tax
var $total_ttc; // Total with tax
var $total_tva; // Total VAT
var $total_localtax1; // Total Local tax 1
var $total_localtax2; // Total Local tax 2
var $remise_absolue;
var $modelpdf;
var $info_bits;
var $rang;
var $special_code;
var $source; // Origin of order
/**
* @deprecated
* @see note_private, note_public
*/
var $note;
var $note_private;
var $note_public;
var $extraparams=array();
var $origin;
var $origin_id;
var $linked_objects=array();
var $user_author_id;
@ -138,11 +107,6 @@ class Commande extends CommonOrder
*/
var $lines = array();
//Incorterms
var $fk_incoterms;
var $location_incoterms;
var $libelle_incoterms; //Used into tooltip
// Pour board
var $nbtodo;
var $nbtodolate;

View File

@ -338,7 +338,7 @@ if ($resql)
print '</td>';
print '<td align="right">';
$liststatus=array('0'=>$langs->trans("StatusOrderDraftShort"), '1'=>$langs->trans("StatusOrderValidated"), '2'=>$langs->trans("StatusOrderSentShort"), '3'=>$langs->trans("StatusOrderToBill"), '4'=>$langs->trans("StatusOrderProcessed"), '-1'=>$langs->trans("StatusOrderCanceledShort"));
print $form->selectarray('viewstatut', $liststatus, $viewstatut, 1);
print $form->selectarray('viewstatut', $liststatus, $viewstatut, -4);
print '</td>';
print '<td class="liste_titre" align="right"><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 '<input type="image" class="liste_titre" name="button_removefilter" src="'.img_picto($langs->trans("Search"),'searchclear.png','','',1).'" value="'.dol_escape_htmltag($langs->trans("RemoveFilter")).'" title="'.dol_escape_htmltag($langs->trans("RemoveFilter")).'">';

View File

@ -44,9 +44,7 @@ class Account extends CommonObject
* @see id
*/
var $rowid;
var $id;
var $ref;
var $label;
//! 1=Compte courant/check/carte, 2=Compte liquide, 0=Compte épargne
var $courant;
@ -75,10 +73,6 @@ class Account extends CommonObject
var $state_code;
var $state;
var $country_id;
var $country_code;
var $country;
var $type_lib=array();
var $account_number;

View File

@ -37,23 +37,13 @@ class Deplacement extends CommonObject
public $fk_element = '';
protected $ismultientitymanaged = 0; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
var $id;
var $datec; // Creation date
var $dated;
var $fk_user_author;
var $fk_user;
var $km;
/**
* @deprecated
* @see note_private, note_public
*/
var $note; // TODO deprecated
var $note_private;
var $note_public;
var $socid;
var $statut; // 0=draft, 1=validated
var $fk_project;
var $extraparams=array();
var $statuts=array();

View File

@ -42,35 +42,20 @@ class FactureRec extends Facture
public $table_element_line='facturedet_rec';
public $fk_element='fk_facture';
var $id;
//! Id customer
var $socid;
//! Customer object (charging by fetch_client)
var $client;
var $number;
var $author;
var $date;
var $ref;
var $amount;
var $remise;
var $tva;
var $total;
var $note_private;
var $note_public;
var $db_table;
var $propalid;
var $fk_project;
var $rang;
var $special_code;
var $usenewprice=0;
var $lines=array();
/**
* Constructor
*

View File

@ -58,27 +58,15 @@ class Facture extends CommonInvoice
*/
protected $table_ref_field = 'facnumber';
var $id;
//! Id client
var $socid;
//! Objet societe client (to load with fetch_client method)
/**
* Customer
* @var Societe
*/
var $client;
var $author;
var $fk_user_author;
var $fk_user_valid;
//! Invoice date
var $date; // Invoice date
var $date_creation; // Creation date
var $date_validation; // Validation date
var $datem;
var $ref;
var $ref_client;
var $ref_ext;
var $ref_int;
//Check constants for types
var $type = self::TYPE_STANDARD;
@ -90,20 +78,7 @@ class Facture extends CommonInvoice
var $total_tva=0;
var $total_ttc=0;
var $revenuestamp;
/**
* @deprecated
* @see note_private, note_public
*/
var $note;
var $note_private;
var $note_public;
/**
* Invoice status
* @var int
* @see Facture::STATUS_DRAFT, Facture::STATUS_VALIDATED, Facture::STATUS_PAID, Facture::STATUS_ABANDONED
*/
var $statut;
//! Fermeture apres paiement partiel: discount_vat, badcustomer, abandon
//! Fermeture alors que aucun paiement: replaced (si remplace), abandon
var $close_code;
@ -113,18 +88,11 @@ class Facture extends CommonInvoice
var $paye;
//! id of source invoice if replacement invoice or credit note
var $fk_facture_source;
var $origin;
var $origin_id;
var $linked_objects=array();
var $fk_project;
var $date_lim_reglement;
var $cond_reglement_id; // Id in llx_c_paiement
var $cond_reglement_code; // Code in llx_c_paiement
var $mode_reglement_id; // Id in llx_c_paiement
var $mode_reglement_code; // Code in llx_c_paiement
var $fk_account; // Id of bank account
var $fk_bank; // Field to store bank id to use when payment mode is withdraw
var $modelpdf;
/**
* @deprecated
*/
@ -139,11 +107,6 @@ class Facture extends CommonInvoice
var $fac_rec;
//Incoterms
var $fk_incoterms;
var $location_incoterms;
var $libelle_incoterms; //Used into tooltip
/**
* @var int Situation cycle reference number
*/
@ -159,64 +122,6 @@ class Facture extends CommonInvoice
*/
public $situation_final;
/**
* Standard invoice
*/
const TYPE_STANDARD = 0;
/**
* Replacement invoice
*/
const TYPE_REPLACEMENT = 1;
/**
* Credit note invoice
*/
const TYPE_CREDIT_NOTE = 2;
/**
* Deposit invoice
*/
const TYPE_DEPOSIT = 3;
/**
* Proforma invoice
*/
const TYPE_PROFORMA = 4;
/**
* Situation invoice
*/
const TYPE_SITUATION = 5;
/**
* Draft
*/
const STATUS_DRAFT = 0;
/**
* Validated (need to be paid)
*/
const STATUS_VALIDATED = 1;
/**
* Classified paid.
* If paid partially, $this->close_code can be:
* - CLOSECODE_DISCOUNTVAT
* - CLOSECODE_BADDEBT
* If paid completelly, this->close_code will be null
*/
const STATUS_CLOSED = 2;
/**
* Classified abandoned and no payment done.
* $this->close_code can be:
* - CLOSECODE_BADDEBT
* - CLOSECODE_ABANDONED
* - CLOSECODE_REPLACED
*/
const STATUS_ABANDONED = 3;
const CLOSECODE_DISCOUNTVAT = 'discount_vat';
const CLOSECODE_BADDEBT = 'badcustomer';
const CLOSECODE_ABANDONED = 'abandon';

View File

@ -3,7 +3,7 @@
* Copyright (C) 2004 Eric Seigne <eric.seigne@ryxeo.com>
* Copyright (C) 2004-2012 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005 Marc Barilley / Ocebo <marc@ocebo.com>
* Copyright (C) 2005-2013 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2005-2015 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2006 Andre Cianfarani <acianfa@free.fr>
* Copyright (C) 2010-2012 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2012 Christophe Battarel <christophe.battarel@altairis.fr>
@ -69,7 +69,7 @@ $search_refcustomer=GETPOST('search_refcustomer','alpha');
$search_societe=GETPOST('search_societe','alpha');
$search_montant_ht=GETPOST('search_montant_ht','alpha');
$search_montant_ttc=GETPOST('search_montant_ttc','alpha');
$search_status=GETPOST('search_status','alpha');
$search_status=GETPOST('search_status','int');
$sortfield = GETPOST("sortfield",'alpha');
$sortorder = GETPOST("sortorder",'alpha');
@ -191,7 +191,7 @@ if ($search_refcustomer) $sql .= natural_search('f.ref_client', $search_refcusto
if ($search_societe) $sql .= natural_search('s.nom', $search_societe);
if ($search_montant_ht != '') $sql.= natural_search('f.total', $search_montant_ht, 1);
if ($search_montant_ttc != '') $sql.= natural_search('f.total_ttc', $search_montant_ttc, 1);
if ($search_status >= 0 ) $sql.= " AND f.fk_statut = ".$db->escape($search_status);
if ($search_status != '') $sql.= " AND f.fk_statut = ".$db->escape($search_status);
if ($month > 0)
{
if ($year > 0 && empty($day))

View File

@ -1,7 +1,7 @@
<?php
/* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2005-2015 Regis Houssin <regis.houssin@capnetworks.com>
* Copyright (C) 2015 Juanjo Menent <jmenent@2byte.es>
* Copyright (C) 2015 Jean-François Ferry <jfefe@aternatik.fr>
* Copyright (C) 2015 Raphaël Doursenaud <rdoursenaud@gpcsolutions.fr>
@ -781,6 +781,7 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire)
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("BillsCustomersUnpaid",$num).' <a href="'.DOL_URL_ROOT.'/compta/facture/list.php?search_status=1"><span class="badge">'.$num.'</span></a></td>';
print '<td align="right">'.$langs->trans("DateDue").'</td>';
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print '<td align="right">'.$langs->trans("AmountHT").'</td>';
print '<td align="right">'.$langs->trans("AmountTTC").'</td>';
print '<td align="right">'.$langs->trans("Received").'</td>';
@ -830,6 +831,7 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire)
$societestatic->code_fournisseur = $obj->code_fournisseur;
print $societestatic->getNomUrl(1,'customer',44);
print '</td>';
print '<td align="right">'.dol_print_date($db->jdate($obj->datelimite),'day').'</td>';
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print '<td align="right">'.price($obj->total_ht).'</td>';
print '<td align="right">'.price($obj->total_ttc).'</td>';
print '<td align="right">'.price($obj->am).'</td>';
@ -844,6 +846,7 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire)
}
print '<tr class="liste_total"><td colspan="2">'.$langs->trans("Total").' &nbsp; <font style="font-weight: normal">('.$langs->trans("RemainderToTake").': '.price($total_ttc-$totalam).')</font> </td>';
print '<td>&nbsp;</td>';
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print '<td align="right">'.price($total).'</td>';
print '<td align="right">'.price($total_ttc).'</td>';
print '<td align="right">'.price($totalam).'</td>';
@ -852,7 +855,7 @@ if (! empty($conf->facture->enabled) && $user->rights->facture->lire)
}
else
{
$colspan=5;
$colspan=6;
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) $colspan++;
print '<tr '.$bc[$var].'><td colspan="'.$colspan.'">'.$langs->trans("NoInvoice").'</td></tr>';
}
@ -873,6 +876,7 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture-
$facstatic=new FactureFournisseur($db);
$sql = "SELECT ff.rowid, ff.ref, ff.fk_statut, ff.libelle, ff.total_ht, ff.total_tva, ff.total_ttc, ff.paye";
$sql.= ", ff.date_lim_reglement";
$sql.= ", s.nom as name";
$sql.= ", s.rowid as socid";
$sql.= ", s.code_client";
@ -889,6 +893,7 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture-
if ($socid) $sql.= " AND ff.fk_soc = ".$socid;
$sql.= " GROUP BY ff.rowid, ff.ref, ff.fk_statut, ff.libelle, ff.total_ht, ff.tva, ff.total_tva, ff.total_ttc, ff.paye,";
$sql.= " s.nom, s.rowid, s.code_client, s.code_fournisseur";
$sql.= " ORDER BY ff.date_lim_reglement ASC";
$resql=$db->query($sql);
if ($resql)
@ -898,6 +903,7 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture-
print '<table class="noborder" width="100%">';
print '<tr class="liste_titre"><td colspan="2">'.$langs->trans("BillsSuppliersUnpaid",$num).' <a href="'.DOL_URL_ROOT.'/fourn/facture/impayees.php"><span class="badge">'.$num.'</span></a></td>';
print '<td align="right">'.$langs->trans("DateDue").'</td>';
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print '<td align="right">'.$langs->trans("AmountHT").'</td>';
print '<td align="right">'.$langs->trans("AmountTTC").'</td>';
print '<td align="right">'.$langs->trans("Paid").'</td>';
@ -926,6 +932,7 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture-
$societestatic->code_client = $obj->code_client;
$societestatic->code_fournisseur = $obj->code_fournisseur;
print '<td>'.$societestatic->getNomUrl(1, 'supplier', 44).'</td>';
print '<td align="right">'.dol_print_date($db->jdate($obj->date_lim_reglement),'day').'</td>';
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print '<td align="right">'.price($obj->total_ht).'</td>';
print '<td align="right">'.price($obj->total_ttc).'</td>';
print '<td align="right">'.price($obj->am).'</td>';
@ -939,6 +946,7 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture-
}
print '<tr class="liste_total"><td colspan="2">'.$langs->trans("Total").' &nbsp; <font style="font-weight: normal">('.$langs->trans("RemainderToPay").': '.price($total_ttc-$totalam).')</font> </td>';
print '<td>&nbsp;</td>';
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) print '<td align="right">'.price($total).'</td>';
print '<td align="right">'.price($total_ttc).'</td>';
print '<td align="right">'.price($totalam).'</td>';
@ -947,7 +955,7 @@ if (! empty($conf->fournisseur->enabled) && $user->rights->fournisseur->facture-
}
else
{
$colspan=5;
$colspan=6;
if (! empty($conf->global->MAIN_SHOW_HT_ON_SUMMARY)) $colspan++;
print '<tr '.$bc[$var].'><td colspan="'.$colspan.'">'.$langs->trans("NoInvoice").'</td></tr>';
}

View File

@ -29,15 +29,12 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php';
*/
class Localtax extends CommonObject
{
var $id;
var $ref;
var $ltt;
var $tms;
var $datep;
var $datev;
var $amount;
var $label;
var $note;
var $fk_bank;
var $fk_user_creat;
var $fk_user_modif;

View File

@ -36,14 +36,11 @@ class RemiseCheque extends CommonObject
public $element='chequereceipt';
public $table_element='bordereau_cheque';
var $id;
var $num;
var $intitule;
var $ref_ext;
//! Numero d'erreur Plage 1024-1279
var $errno;
public $statut;
public $amount;
public $date_bordereau;
public $account_id;

View File

@ -37,8 +37,6 @@ class Paiement extends CommonObject
public $element='payment';
public $table_element='paiement';
var $id;
var $ref;
var $facid;
var $datepaye;
/**
@ -60,8 +58,6 @@ class Paiement extends CommonObject
var $num_paiement; // Numero du CHQ, VIR, etc...
var $bank_account; // Id compte bancaire du paiement
var $bank_line; // Id de la ligne d'ecriture bancaire
var $fk_account; // Id of bank account
var $note;
// fk_paiement dans llx_paiement est l'id du type de paiement (7 pour CHQ, ...)
// fk_paiement dans llx_paiement_facture est le rowid du paiement

View File

@ -37,8 +37,6 @@ require_once DOL_DOCUMENT_ROOT.'/compta/paiement/class/paiement.class.php';
*/
class BonPrelevement extends CommonObject
{
var $db;
var $date_echeance;
var $raison_sociale;
var $reference_remise;

View File

@ -34,9 +34,6 @@ class PaymentSalary extends CommonObject
//public $element='payment_salary'; //!< Id that identify managed objects
//public $table_element='payment_salary'; //!< Name of table without prefix where object is stored
var $id;
var $ref;
var $tms;
var $fk_user;
var $datep;
@ -47,7 +44,6 @@ class PaymentSalary extends CommonObject
var $label;
var $datesp;
var $dateep;
var $note;
var $fk_bank;
var $fk_user_author;
var $fk_user_modif;

View File

@ -39,8 +39,6 @@ class ChargeSociales extends CommonObject
*/
protected $table_ref_field = 'ref';
var $id;
var $ref;
var $date_ech;
var $lib;
var $type;

View File

@ -33,9 +33,6 @@ class PaymentSocialContribution extends CommonObject
public $element='paiementcharge'; //!< Id that identify managed objects
public $table_element='paiementcharge'; //!< Name of table without prefix where object is stored
var $id;
var $ref;
var $fk_charge;
var $datec='';
var $tms='';
@ -49,7 +46,6 @@ class PaymentSocialContribution extends CommonObject
var $amounts=array(); // Array of amounts
var $fk_typepaiement;
var $num_paiement;
var $note;
var $fk_bank;
var $fk_user_creat;
var $fk_user_modif;

View File

@ -35,9 +35,6 @@ class Tva extends CommonObject
//public $element='tva'; //!< Id that identify managed objects
//public $table_element='tva'; //!< Name of table without prefix where object is stored
var $id;
var $ref;
var $tms;
var $datep;
var $datev;
@ -45,7 +42,6 @@ class Tva extends CommonObject
var $type_payment;
var $num_payment;
var $label;
var $note;
var $fk_bank;
var $fk_user_creat;
var $fk_user_modif;

View File

@ -100,6 +100,10 @@ if ($user->societe_id) {
}
$result = restrictedArea($user, 'tax', '', '', 'charges');
// Define modecompta ('CREANCES-DETTES' or 'RECETTES-DEPENSES')
$modecompta = $conf->global->ACCOUNTING_MODE;
if (GETPOST("modecompta")) $modecompta=GETPOST("modecompta");
/*
@ -292,7 +296,14 @@ if (is_array($coll_list)) {
} else {
$langs->load("errors");
if ($coll_list == -1) {
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
if ($modecompta == 'CREANCES-DETTES')
{
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
}
else
{
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';
}
} else if ($coll_list == -2) {
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';
} else {
@ -377,7 +388,14 @@ if (is_array($coll_list)) {
} else {
$langs->load("errors");
if ($coll_list == -1) {
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
if ($modecompta == 'CREANCES-DETTES')
{
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
}
else
{
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';
}
} else if ($coll_list == -2) {
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';
} else {
@ -457,7 +475,14 @@ if ($special_report) {
} else {
$langs->load("errors");
if ($coll_list == -1) {
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
if ($modecompta == 'CREANCES-DETTES')
{
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
}
else
{
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';
}
} else {
if ($coll_list == -2) {
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';
@ -530,7 +555,14 @@ if ($special_report) {
} else {
$langs->load("errors");
if ($coll_list == -1) {
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
if ($modecompta == 'CREANCES-DETTES')
{
print '<tr><td colspan="5">' . $langs->trans("ErrorNoAccountancyModuleLoaded") . '</td></tr>';
}
else
{
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';
}
} else {
if ($coll_list == -2) {
print '<tr><td colspan="5">' . $langs->trans("FeatureNotYetAvailable") . '</td></tr>';

View File

@ -29,12 +29,6 @@ include_once DOL_DOCUMENT_ROOT.'/contact/canvas/actions_contactcard_common.class
*/
class ActionsContactCardDefault extends ActionsContactCardCommon
{
var $db;
var $dirmodule;
var $targetmodule;
var $canvas;
var $card;
/**
* Constructor
*

View File

@ -41,11 +41,7 @@ class Contact extends CommonObject
public $table_element='socpeople';
protected $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
var $id;
var $ref_ext;
var $civility_id; // In fact we store civility_code
var $lastname;
var $firstname;
var $address;
var $zip;
var $town;
@ -69,10 +65,6 @@ class Contact extends CommonObject
var $state_code; // Code of department
var $state; // Label of department
var $country_id; // Id of country
var $country_code; // Code of country
var $country; // Label of country
var $poste; // Position
var $socid; // fk_soc
@ -91,13 +83,6 @@ class Contact extends CommonObject
var $birthday;
var $default_lang;
var $note_public; // Public note
/**
* @deprecated
* @see note_public, note_private
*/
var $note;
var $note_private; // Private note
var $no_email; // 1=Don't send e-mail to this contact, 0=do
var $ref_facturation; // Nb de reference facture pour lequel il est contact
@ -107,7 +92,6 @@ class Contact extends CommonObject
var $user_id;
var $user_login;
var $import_key;
var $oldcopy; // To contains a clone of this when we need to save old properties of object

View File

@ -50,25 +50,6 @@ class Contrat extends CommonObject
*/
protected $table_ref_field = 'ref';
/**
* Id of the contract
* @var int
*/
var $id;
/**
* Reference of the contract
* @var string
*/
var $ref;
/**
* External reference of the contract.
* Used by 3rd party services
* @var string
*/
var $ref_ext;
/**
* Supplier reference of the contract
* @var string
@ -140,26 +121,12 @@ class Contrat extends CommonObject
var $commercial_signature_id;
var $commercial_suivi_id;
/**
* @var string Private note
*/
var $note_private;
/**
* @var string Public note
*/
var $note_public;
var $modelpdf;
/**
* @deprecated Use fk_project instead
* @see fk_project
*/
var $fk_projet;
public $fk_project;
var $extraparams=array();
/**

View File

@ -131,6 +131,7 @@ abstract class CommonObject
public $thirdparty;
/**
* @deprecated
* @var Societe A related customer
* @see thirdparty
*/
public $client;
@ -283,27 +284,27 @@ abstract class CommonObject
public $note;
/**
* @var float
* @var float Total amount before taxes
* @see update_price()
*/
public $total_ht;
/**
* @var float
* @var float Total VAT amount
* @see update_price()
*/
public $total_tva;
/**
* @var float
* @var float Total local tax 1 amount
* @see update_price()
*/
public $total_localtax1;
/**
* @var float
* @var float Total local tax 2 amount
* @see update_price()
*/
public $total_localtax2;
/**
* @var float
* @var float Total amount with taxes
* @see update_price()
*/
public $total_ttc;
@ -1083,18 +1084,18 @@ abstract class CommonObject
function getValueFrom($table, $id, $field)
{
$result=false;
$sql = "SELECT ".$field." FROM ".MAIN_DB_PREFIX.$table;
$sql.= " WHERE rowid = ".$id;
dol_syslog(get_class($this).'::getValueFrom', LOG_DEBUG);
$resql = $this->db->query($sql);
if ($resql)
{
$row = $this->db->fetch_row($resql);
$result = $row[0];
}
if (!empty($id) && !empty($field) && !empty($table)) {
$sql = "SELECT ".$field." FROM ".MAIN_DB_PREFIX.$table;
$sql.= " WHERE rowid = ".$id;
dol_syslog(get_class($this).'::getValueFrom', LOG_DEBUG);
$resql = $this->db->query($sql);
if ($resql)
{
$row = $this->db->fetch_row($resql);
$result = $row[0];
}
}
return $result;
}

View File

@ -43,9 +43,6 @@ abstract class CommonObjectLine extends CommonObject
*/
public $rowid;
//! Database handler
public $db;
/**
* Product/service unit code ('km', 'm', 'p', ...)
* @var string

View File

@ -137,36 +137,6 @@ abstract class CommonOrderLine extends CommonObjectLine
public $localtax1_type;
public $localtax2_type;
/**
* Total amount before taxes
* @var float
*/
public $total_ht;
/**
* Total VAT amount
* @var float
*/
public $total_tva;
/**
* Total local tax 1 amount
* @var float
*/
public $total_localtax1;
/**
* Total local tax 2 amount
* @var float
*/
public $total_localtax2;
/**
* Total amount with taxes
* @var float
*/
public $total_ttc;
/**
* Liste d'options cumulables:
* Bit 0: 0 si TVA normal - 1 si TVA NPR

View File

@ -390,8 +390,8 @@ class Conf
// conf->global->ACCOUNTING_MODE = Option des modules Comptabilites (simple ou expert). Defini le mode de calcul des etats comptables (CA,...)
if (empty($this->global->ACCOUNTING_MODE)) $this->global->ACCOUNTING_MODE='RECETTES-DEPENSES'; // By default. Can be 'RECETTES-DEPENSES' ou 'CREANCES-DETTES'
// By default, suppliers ojbects can be linked to all projects
$conf->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS = 1;
// By default, suppliers objects can be linked to all projects
$this->global->PROJECT_CAN_ALWAYS_LINK_TO_ALL_SUPPLIERS = 1;
// conf->liste_limit = constante de taille maximale des listes
if (empty($this->global->MAIN_SIZE_LISTE_LIMIT)) $this->global->MAIN_SIZE_LISTE_LIMIT=25;

View File

@ -34,7 +34,6 @@ class Fiscalyear extends CommonObject
public $fk_element = '';
protected $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
var $id;
var $rowid;
var $label;
@ -324,4 +323,4 @@ class Fiscalyear extends CommonObject
}
}
}
}

View File

@ -30,8 +30,6 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php';
class GenericObject extends CommonObject
{
var $db;
/**
* Constructor
*

View File

@ -31,7 +31,6 @@ class Link extends CommonObject
public $element = 'link';
public $table_element = 'links';
public $id;
public $entity;
public $datea;
public $url;

View File

@ -94,7 +94,7 @@ function societe_prepare_head(Societe $object)
}*/
// Tab to link resources
if ($conf->resource->enabled && ! empty($conf->global->RESOURCE_ON_THIRDPARTIES))
if (! empty($conf->resource->enabled) && ! empty($conf->global->RESOURCE_ON_THIRDPARTIES))
{
$head[$h][0] = DOL_URL_ROOT.'/resource/element_resource.php?element=societe&element_id='.$object->id;
$head[$h][1] = $langs->trans("Resources");

View File

@ -1341,7 +1341,10 @@ function pdf_getlinevatrate($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlinevatrate',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlinevatrate',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1371,7 +1374,10 @@ function pdf_getlineupexcltax($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlineupexcltax',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlineupexcltax',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1428,7 +1434,11 @@ function pdf_getlineqty($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlineqty',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlineqty',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1458,7 +1468,10 @@ function pdf_getlineqty_asked($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlineqty_asked',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlineqty_asked',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1488,7 +1501,10 @@ function pdf_getlineqty_shipped($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlineqty_shipped',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlineqty_shipped',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1518,7 +1534,10 @@ function pdf_getlineqty_keeptoship($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlineqty_keeptoship',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlineqty_keeptoship',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1553,8 +1572,12 @@ function pdf_getlineunit($object, $i, $outputlangs, $hidedetails = 0, $hookmanag
'special_code' => $special_code
);
$action = '';
return $hookmanager->executeHooks('pdf_getlineunit', $parameters, $object,
$reshook = $hookmanager->executeHooks('pdf_getlineunit', $parameters, $object,
$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
} else {
if (empty($hidedetails) || $hidedetails > 1) {
return $langs->transnoentitiesnoconv($object->lines[$i]->getLabelOfUnit('short'));
@ -1587,7 +1610,10 @@ function pdf_getlineremisepercent($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlineremisepercent',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlineremisepercent',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1614,7 +1640,10 @@ function pdf_getlineprogress($object, $i, $outputlangs, $hidedetails = 0, $hookm
if (!empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i' => $i, 'outputlangs' => $outputlangs, 'hidedetails' => $hidedetails, 'special_code' => $special_code);
$action = '';
return $hookmanager->executeHooks('pdf_getlineprogress', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlineprogress', $parameters, $object, $action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
} else {
if (empty($hidedetails) || $hidedetails > 1) return $object->lines[$i]->situation_percent . '%';
}
@ -1649,7 +1678,10 @@ function pdf_getlinetotalexcltax($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlinetotalexcltax',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlinetotalexcltax',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1684,7 +1716,10 @@ function pdf_getlinetotalwithtax($object,$i,$outputlangs,$hidedetails=0)
if (! empty($object->lines[$i]->fk_parent_line)) $special_code = $object->getSpecialCode($object->lines[$i]->fk_parent_line);
$parameters = array('i'=>$i,'outputlangs'=>$outputlangs,'hidedetails'=>$hidedetails,'special_code'=>$special_code);
$action='';
return $hookmanager->executeHooks('pdf_getlinetotalwithtax',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
$reshook = $hookmanager->executeHooks('pdf_getlinetotalwithtax',$parameters,$object,$action); // Note that $action and $object may have been modified by some hooks
if(!empty($hookmanager->resPrint)) return $hookmanager->resPrint;
else return $reshook;
}
else
{
@ -1808,7 +1843,7 @@ function pdf_getLinkedObjects($object,$outputlangs)
else // We show both info of order and shipment
{
$linkedobjects[$objecttype]['ref_title'] = $outputlangs->transnoentities("RefOrder") . ' / ' . $outputlangs->transnoentities("RefSending");
$linkedobjects[$objecttype]['ref_value'] = $outputlangs->transnoentities($order->ref) . ($order->ref_client ? ' ('.$order->ref_client.')' : '');
$linkedobjects[$objecttype]['ref_value'] = $outputlangs->convToOutputCharset($order->ref) . ($order->ref_client ? ' ('.$order->ref_client.')' : '');
$linkedobjects[$objecttype]['ref_value'].= ' / ' . $outputlangs->transnoentities($elementobject->ref);
$linkedobjects[$objecttype]['date_title'] = $outputlangs->transnoentities("OrderDate") . ' / ' . $outputlangs->transnoentities("DateSending");
$linkedobjects[$objecttype]['date_value'] = dol_print_date($order->date,'day','',$outputlangs);

View File

@ -79,7 +79,7 @@ function tax_prepare_head(ChargeSociales $object)
* @param int $y Year
* @param string $date_start Start date
* @param string $date_end End date
* @param int $modetax 0 or 1 (option vat on debit)
* @param int $modetax 0 or 1 (option vat on debit, 1 => $modecompta = 'CREANCES-DETTES')
* @param string $direction 'sell' or 'buy'
* @param int $m Month
* @return array List of customers third parties with vat, -1 if no accountancy module, -2 if not yet developped, -3 if error

View File

@ -400,9 +400,24 @@ function show_theme($fuser,$edit=0,$foruserprofile=false)
else
{
print '<tr '.$bc[$var].'>';
print '<td>'.$langs->trans("HighlightLinesOnMouseHover").'</td>';
print '<td colspan="'.($colspan-1).'"><input '.$bc[$var].' name="check_THEME_ELDY_USE_HOVER"'.($edit?'':' disabled').' type="checkbox" '.($hoverdisabled?"":" checked").'>';
print ' &nbsp; ('.$langs->trans("NotSupportedByAllThemes").', '.$langs->trans("PressF5AfterChangingThis").')';
print '<td>'.$langs->trans("HighlightLinesColor").'</td>';
print '<td colspan="'.($colspan-1).'">';
//print '<input '.$bc[$var].' name="check_THEME_ELDY_USE_HOVER"'.($edit?'':' disabled').' type="checkbox" '.($hoverdisabled?"":" checked").'>';
//print ' &nbsp; ('.$langs->trans("NotSupportedByAllThemes").', '.$langs->trans("PressF5AfterChangingThis").')';
if ($edit)
{
if ($conf->global->THEME_ELDY_USE_HOVER == '1') $color='edf4fb';
else $color = colorArrayToHex(colorStringToArray($conf->global->THEME_ELDY_USE_HOVER,array()),'');
print $formother->selectColor($color,'THEME_ELDY_USE_HOVER','formcolor',1).' ';
}
else
{
if ($conf->global->THEME_ELDY_USE_HOVER == '1') $color='edf4fb';
else $color = colorArrayToHex(colorStringToArray($conf->global->THEME_ELDY_USE_HOVER,array()),'');
if ($color) print '<input type="text" class="colorthumb" disabled="disabled" style="padding: 1px; margin-top: 0; margin-bottom: 0; width: 36px; background-color: #'.$color.'" value="'.$color.'">';
else print $langs->trans("None");
}
print ' &nbsp; ('.$langs->trans("Default").': <strong>edf4fb</strong>, '.$langs->trans("NotSupportedByAllThemes").', '.$langs->trans("PressF5AfterChangingThis").')';
print '</td>';
print '</tr>';
}

View File

@ -33,8 +33,6 @@ require_once DOL_DOCUMENT_ROOT.'/core/modules/cheque/pdf/modules_chequereceipts.
*/
class BordereauChequeBlochet extends ModeleChequeReceipts
{
var $error='';
var $emetteur; // Objet societe qui emet
/**

View File

@ -771,9 +771,10 @@ class pdf_einstein extends ModelePDFCommandes
// If payment mode not forced or forced to VIR, show payment with BAN
if (empty($object->mode_reglement_code) || $object->mode_reglement_code == 'VIR')
{
if (! empty($object->fk_bank) || ! empty($conf->global->FACTURE_RIB_NUMBER))
if (! empty($object->fk_account) || ! empty($object->fk_bank) || ! empty($conf->global->FACTURE_RIB_NUMBER))
{
$bankid=(empty($object->fk_bank)?$conf->global->FACTURE_RIB_NUMBER:$object->fk_bank);
$bankid=(empty($object->fk_account)?$conf->global->FACTURE_RIB_NUMBER:$object->fk_account);
if (! empty($object->fk_bank)) $bankid=$object->fk_bank; // For backward compatibility when object->fk_account is forced with object->fk_bank
$account = new Account($this->db);
$account->fetch($bankid);

View File

@ -958,9 +958,10 @@ class pdf_crabe extends ModelePDFFactures
// If payment mode not forced or forced to VIR, show payment with BAN
if (empty($object->mode_reglement_code) || $object->mode_reglement_code == 'VIR')
{
if (! empty($object->fk_account) || ! empty($conf->global->FACTURE_RIB_NUMBER))
if (! empty($object->fk_account) || ! empty($object->fk_bank) || ! empty($conf->global->FACTURE_RIB_NUMBER))
{
$bankid=(empty($object->fk_account)?$conf->global->FACTURE_RIB_NUMBER:$object->fk_account);
if (! empty($object->fk_bank)) $bankid=$object->fk_bank; // For backward compatibility when object->fk_account is forced with object->fk_bank
$account = new Account($this->db);
$account->fetch($bankid);

View File

@ -114,7 +114,23 @@ class modProjet extends DolibarrModules
$this->const[$r][2] = "DOL_DATA_ROOT/doctemplates/tasks";
$this->const[$r][3] = "";
$this->const[$r][4] = 0;
$r++;
$this->const[$r][0] = "PROJECT_USE_OPPORTUNIES";
$this->const[$r][1] = "chaine";
$this->const[$r][2] = "1";
$this->const[$r][3] = "";
$this->const[$r][4] = 0;
$r++;
/* not required (0 = not present)
$this->const[$r][0] = "PROJECT_HIDE_TASKS";
$this->const[$r][1] = "chaine";
$this->const[$r][2] = "0";
$this->const[$r][3] = "";
$this->const[$r][4] = 0;
*/
// Boxes
$this->boxes = array();
$r=0;

View File

@ -917,9 +917,10 @@ class pdf_azur extends ModelePDFPropales
// If payment mode not forced or forced to VIR, show payment with BAN
if (empty($object->mode_reglement_code) || $object->mode_reglement_code == 'VIR')
{
if (! empty($object->fk_bank) || ! empty($conf->global->FACTURE_RIB_NUMBER))
if (! empty($object->fk_account) || ! empty($object->fk_bank) || ! empty($conf->global->FACTURE_RIB_NUMBER))
{
$bankid=(empty($object->fk_bank)?$conf->global->FACTURE_RIB_NUMBER:$object->fk_bank);
$bankid=(empty($object->fk_account)?$conf->global->FACTURE_RIB_NUMBER:$object->fk_account);
if (! empty($object->fk_bank)) $bankid=$object->fk_bank; // For backward compatibility when object->fk_account is forced with object->fk_bank
$account = new Account($this->db);
$account->fetch($bankid);

View File

@ -30,15 +30,9 @@ require_once(DOL_DOCUMENT_ROOT."/core/class/commonobject.class.php");
*/
class Cronjob extends CommonObject
{
var $db; //!< To store db handler
var $error; //!< To return error code (or message)
var $errors=array(); //!< To return several error codes (or messages)
var $element='cronjob'; //!< Id that identify managed objects
var $table_element='cronjob'; //!< Name of table without prefix where object is stored
var $id;
var $ref; //Use for prevnext_ref
var $jobtype;
var $tms='';
var $datec='';
@ -63,12 +57,8 @@ class Cronjob extends CommonObject
var $status;
var $fk_user_author;
var $fk_user_mod;
var $note;
var $nbrun;
var $libname;
var $lines;
/**

View File

@ -39,29 +39,17 @@ class Don extends CommonObject
public $fk_element = 'fk_donation';
protected $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
var $id;
var $ref;
var $date;
var $amount;
var $firstname;
var $lastname;
var $societe;
var $address;
var $zip;
var $town;
var $country_id;
var $country_code;
var $country;
var $email;
var $public;
var $fk_projet;
var $fk_typepayment;
var $num_payment;
var $note_private;
var $note_public;
var $statut;
var $modelpdf;
var $projet;
/**
* @deprecated

View File

@ -32,9 +32,7 @@ class PaymentDonation extends CommonObject
public $element='payment_donation'; //!< Id that identify managed objects
public $table_element='payment_donation'; //!< Name of table without prefix where object is stored
var $id;
var $rowid;
var $ref;
var $fk_donation;
var $datec='';
@ -44,7 +42,6 @@ class PaymentDonation extends CommonObject
var $amounts=array(); // Array of amounts
var $typepayment;
var $num_payment;
var $note;
var $fk_bank;
var $fk_user_creat;
var $fk_user_modif;

View File

@ -45,24 +45,15 @@ class Expedition extends CommonObject
public $table_element="expedition";
protected $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe
var $id;
var $socid;
var $ref_customer;
var $ref_ext;
var $ref_int;
var $brouillon;
var $entrepot_id;
var $modelpdf;
var $origin;
var $origin_id;
var $lines=array();
var $shipping_method_id;
var $tracking_number;
var $tracking_url;
var $statut;
var $billed;
var $note_public;
var $note_private;
var $model_pdf;
var $trueWeight;
@ -95,20 +86,8 @@ class Expedition extends CommonObject
var $date_creation;
var $date_valid;
// For Invoicing
var $total_ht; // Total net of tax
var $total_ttc; // Total with tax
var $total_tva; // Total VAT
var $total_localtax1; // Total Local tax 1
var $total_localtax2; // Total Local tax 2
var $listmeths; // List of carriers
//Incorterms
var $fk_incoterms;
var $location_incoterms;
var $libelle_incoterms; //Used into tooltip
/**
* Constructor
*

View File

@ -31,7 +31,6 @@ class ExpeditionLineBatch extends CommonObject
var $element='expeditionlignebatch'; //!< Id that identify managed objects
private static $_table_element='expeditiondet_batch'; //!< Name of table without prefix where object is stored
var $id;
var $sellby;
var $eatby;
var $batch;

View File

@ -29,21 +29,12 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php';
*/
class ExpenseReport extends CommonObject
{
var $db;
var $error;
var $element='expensereport';
var $table_element='expensereport';
var $table_element_line = 'expensereport_det';
var $fk_element = 'fk_expensereport';
var $id;
var $ref;
var $lignes=array();
var $total_ht;
var $total_tva;
var $total_ttc;
var $note_public;
var $note_private;
var $date_debut;
var $date_fin;

View File

@ -32,9 +32,7 @@ class PaymentExpenseReport extends CommonObject
public $element='payment_expensereport'; //!< Id that identify managed objects
public $table_element='payment_expensereport'; //!< Name of table without prefix where object is stored
var $id;
var $rowid;
var $ref;
var $fk_expensereport;
var $datec='';
@ -44,7 +42,6 @@ class PaymentExpenseReport extends CommonObject
var $amounts=array(); // Array of amounts
var $fk_typepayment;
var $num_payment;
var $note;
var $fk_bank;
var $fk_user_creat;
var $fk_user_modif;

View File

@ -43,24 +43,16 @@ class Fichinter extends CommonObject
*/
protected $table_ref_field = 'ref';
var $id;
var $socid; // Id client
var $client; // Objet societe client (a charger par fetch_client)
var $author;
var $ref;
var $datec;
var $datev;
var $datem;
var $duration;
var $statut; // 0=draft, 1=validated, 2=invoiced
var $description;
var $note_private;
var $note_public;
var $fk_project;
var $fk_contrat;
var $modelpdf;
var $extraparams=array();
var $lines = array();

View File

@ -33,8 +33,6 @@ require_once DOL_DOCUMENT_ROOT.'/fourn/class/fournisseur.product.class.php';
*/
class Fournisseur extends Societe
{
var $db;
var $next_prev_filter="te.fournisseur = 1"; // Used to add a filter in Form::showrefnav method

View File

@ -36,21 +36,6 @@ class PaiementFourn extends Paiement
public $element='payment_supplier';
public $table_element='paiementfourn';
var $id;
var $ref;
var $facid;
var $datepaye;
var $total;
var $amount; // Total amount of payment
var $amounts=array(); // Array of amounts
var $author;
var $paiementid; // Type de paiement. Stocke dans fk_paiement
// de llx_paiement qui est lie aux types de
//paiement de llx_c_paiement
var $num_paiement; // Numero du CHQ, VIR, etc...
var $bank_account; // Id compte bancaire du paiement
var $bank_line; // Id de la ligne d'ecriture bancaire
var $note;
var $statut; //Status of payment. 0 = unvalidated; 1 = validated
// fk_paiement dans llx_paiement est l'id du type de paiement (7 pour CHQ, ...)
// fk_paiement dans llx_paiement_facture est le rowid du paiement

View File

@ -34,16 +34,11 @@ class Holiday extends CommonObject
public $element='holiday';
public $table_element='holiday';
var $db;
var $error;
var $errors=array();
/**
* @deprecated
* @see id
*/
var $rowid;
var $ref;
var $fk_user;
var $date_create='';

View File

@ -83,6 +83,7 @@ if (! defined('DONOTLOADCONF') && file_exists($conffile))
if ($result)
{
if (empty($dolibarr_main_db_type)) $dolibarr_main_db_type='mysqli'; // For backward compatibility
if (empty($dolibarr_main_db_port) && ($dolibarr_main_db_type=='mysqli' || $dolibarr_main_db_type=='mysql')) $dolibarr_main_db_port='3306'; // For backward compatibility
// Clean parameters
$dolibarr_main_data_root =isset($dolibarr_main_data_root)?trim($dolibarr_main_data_root):'';

View File

@ -19,13 +19,18 @@
-- -- VMYSQL4.1 DELETE FROM llx_usergroup_user WHERE fk_usergroup NOT IN (SELECT rowid from llx_usergroup);
INSERT INTO llx_const (name, value, type, note, visible) values ('MAIN_DELAY_EXPENSEREPORTS_TO_PAY','31','chaine','Tolérance de retard avant alerte (en jours) sur les notes de frais impayées',0);
INSERT INTO llx_const (name, value, type, note, visible) values (__ENCRYPT('MAIN_DELAY_EXPENSEREPORTS_TO_PAY')__,__ENCRYPT('31')__,'chaine','Tolérance de retard avant alerte (en jours) sur les notes de frais impayées',0);
ALTER TABLE llx_accounting_system MODIFY COLUMN pcg_version varchar(32);
ALTER TABLE llx_accountingaccount MODIFY COLUMN fk_pcg_version varchar(32);
UPDATE llx_const SET name = __ENCRYPT('ACCOUNTING_EXPORT_PREFIX_SPEC')__ WHERE __DECRYPT('name')__ = 'EXPORT_PREFIX_SPEC';
UPDATE llx_const set value = __ENCRYPT('eldy')__ WHERE __DECRYPT('value')__ = 'auguria';
UPDATE llx_const set value = __ENCRYPT('eldy')__ WHERE __DECRYPT('value')__ = 'bureau2crea';
UPDATE llx_const set value = __ENCRYPT('eldy')__ WHERE __DECRYPT('value')__ = 'amarok';
UPDATE llx_const set value = __ENCRYPT('eldy')__ WHERE __DECRYPT('value')__ = 'cameleo';
ALTER TABLE llx_accountingaccount RENAME TO llx_accounting_account;
ALTER TABLE llx_societe ADD COLUMN model_pdf varchar(255);
@ -45,4 +50,7 @@ create table llx_overwrite_trans
ALTER TABLE llx_payment_salary ADD COLUMN datec datetime after tms;
ALTER TABLE llx_payment_salary CHANGE COLUMN fk_user_creat fk_user_author integer;
ALTER TABLE llx_adherent ADD COLUMN pass_crypted varchar(128) after pass;
ALTER TABLE llx_paiement ADD COLUMN ref varchar(30) NOT NULL AFTER rowid;

View File

@ -35,6 +35,7 @@ create table llx_adherent
firstname varchar(50),
login varchar(50), -- login
pass varchar(50), -- password
pass_crypted varchar(128),
fk_adherent_type integer NOT NULL,
morphy varchar(3) NOT NULL, -- personne morale / personne physique
societe varchar(128), -- company name (should be same lenght than societe.name)

View File

@ -938,7 +938,6 @@ PermanentLeftSearchForm=Permanent search form on left menu
DefaultLanguage=Default language to use (language code)
EnableMultilangInterface=Enable multilingual interface
EnableShowLogo=Show logo on left menu
EnableHtml5=Enable Html5 (Developement - Only available on Eldy template)
SystemSuccessfulyUpdated=Your system has been updated successfully
CompanyInfo=Company/foundation information
CompanyIds=Company/foundation identities
@ -1547,6 +1546,7 @@ AgendaSetup=Events and agenda module setup
PasswordTogetVCalExport=Key to authorize export link
PastDelayVCalExport=Do not export event older than
AGENDA_USE_EVENT_TYPE=Use events types (managed into menu Setup -> Dictionary -> Type of agenda events)
AGENDA_USE_EVENT_TYPE_DEFAULT=Set automatically this default value for type of event into event create form
AGENDA_DEFAULT_FILTER_TYPE=Set automatically this type of event into search filter of agenda view
AGENDA_DEFAULT_FILTER_STATUS=Set automatically this status for events into search filter of agenda view
AGENDA_DEFAULT_VIEW=Which tab do you want to open by default when selecting menu Agenda
@ -1654,12 +1654,13 @@ SomethingMakeInstallFromWebNotPossible2=For this reason, process to upgrade desc
InstallModuleFromWebHasBeenDisabledByFile=Install of external module from application has been disabled by your administrator. You must ask him to remove the file <strong>%s</strong> to allow this feature.
ConfFileMuseContainCustom=Installing an external module from application save the module files into directory <strong>%s</strong>. To have this directory processed by Dolibarr, you must setup your <strong>conf/conf.php</strong> to have option<br>- <strong>$dolibarr_main_url_root_alt</strong> enabled to value <strong>$dolibarr_main_url_root_alt="/custom"</strong><br>- <strong>$dolibarr_main_document_root_alt</strong> enabled to value <strong>"%s/custom"</strong>
HighlightLinesOnMouseHover=Highlight table lines when mouse move passes over
HighlightLinesColor=Color of highlight line when mouse move passes over (keep empty for no highlight)
PressF5AfterChangingThis=Press F5 on keyboard after changing this value to have it effective
NotSupportedByAllThemes=Will works with eldy theme but is not supported by all themes
BackgroundColor=Background color
TopMenuBackgroundColor=Background color for Top menu
LeftMenuBackgroundColor=Background color for Left menu
BackgroundTableTitleColor=Background color for table title line
BackgroundTableTitleColor=Background color for Table title line
BackgroundTableLineOddColor=Background color for odd table lines
BackgroundTableLineEvenColor=Background color for even table lines
MinimumNoticePeriod=Minimum notice period (Your leave request must be done before this delay)

View File

@ -43,32 +43,15 @@ class Livraison extends CommonObject
public $fk_element="fk_livraison";
public $table_element="livraison";
var $id;
var $brouillon;
var $origin;
var $origin_id;
var $socid;
var $ref_customer;
var $statut;
/**
* @deprecated
* @see note_public, note_private
*/
var $note;
var $note_public;
var $note_private;
var $date_delivery; // Date really received
var $date_creation;
var $date_valid;
var $model_pdf;
//Incorterms
var $fk_incoterms;
var $location_incoterms;
var $libelle_incoterms; //Used into tooltip
/**
* Constructor
*

View File

@ -33,17 +33,13 @@ class Loan extends CommonObject
public $table='loan';
public $table_element='loan';
var $id;
var $rowid;
var $ref;
var $datestart;
var $dateend;
var $label;
var $capital;
var $nbterm;
var $rate;
var $note_private;
var $note_public;
var $paid;
var $account_capital;
var $account_insurance;

View File

@ -33,9 +33,6 @@ class PaymentLoan extends CommonObject
public $element='payment_loan'; //!< Id that identify managed objects
public $table_element='payment_loan'; //!< Name of table without prefix where object is stored
var $id;
var $ref;
var $fk_loan;
var $datec='';
var $tms='';
@ -46,8 +43,6 @@ class PaymentLoan extends CommonObject
var $amount_interest;
var $fk_typepayment;
var $num_payment;
var $note_private;
var $note_public;
var $fk_bank;
var $fk_user_creat;
var $fk_user_modif;

View File

@ -973,10 +973,9 @@ function top_htmlhead($head, $title='', $disablejs=0, $disablehead=0, $arrayofjs
if (GETPOST('dol_basehref')) print '<base href="'.dol_escape_htmltag(GETPOST('dol_basehref')).'">'."\n";
// Displays meta
print '<meta name="robots" content="noindex,nofollow">'."\n"; // Do not index
print '<meta name="viewport" content="width=device-width, initial-scale=1">'; // Scale for mobile device
print '<meta name="viewport" content="width=device-width, initial-scale=1.0">'; // Scale for mobile device
print '<meta name="author" content="Dolibarr Development Team">'."\n";
if (! empty($conf->global->MAIN_ACTIVATE_HTML5)) print '<meta name="viewport" content="width=device-width, initial-scale=1.0">'."\n"; // Needed for Responsive Web Design
$favicon=dol_buildpath('/theme/'.$conf->theme.'/img/favicon.ico',1);
$favicon=dol_buildpath('/theme/'.$conf->theme.'/img/favicon.ico',1);
if (! empty($conf->global->MAIN_FAVICON_URL)) $favicon=$conf->global->MAIN_FAVICON_URL;
print '<link rel="shortcut icon" type="image/x-icon" href="'.$favicon.'"/>'."\n";
if (empty($conf->global->MAIN_OPTIMIZEFORTEXTBROWSER)) print '<link rel="top" title="'.$langs->trans("Home").'" href="'.(DOL_URL_ROOT?DOL_URL_ROOT:'/').'">'."\n";

View File

@ -34,14 +34,9 @@ require_once(DOL_DOCUMENT_ROOT."/core/class/commonobject.class.php");
*/
class Opensurveysondage extends CommonObject
{
var $db; //!< To store db handler
var $error; //!< To return error code (or message)
var $errors=array(); //!< To return several error codes (or messages)
var $element='opensurvey_sondage'; //!< Id that identify managed objects
var $table_element='opensurvey_sondage'; //!< Name of table without prefix where object is stored
var $id;
var $id_sondage;
/**
* @deprecated

View File

@ -55,10 +55,6 @@ class Product extends CommonObject
var $regeximgext='\.jpg|\.jpeg|\.bmp|\.gif|\.png|\.tiff';
//! Identifiant unique
var $id ;
//! Ref
var $ref;
/*
* @deprecated
* @see label
@ -128,8 +124,6 @@ class Product extends CommonObject
var $status_batch;
var $customcode; // Customs code
var $country_id; // Country origin id
var $country_code; // Country origin code (US, FR, ...)
//! Unites de mesure
var $weight;
@ -146,10 +140,6 @@ class Product extends CommonObject
//! barcode
var $barcode; // value
var $barcode_type; // id
var $barcode_type_code; // code (loaded by fetch_barcode). Example 'ean', 'isbn', ...
var $barcode_type_label; // label (loaded by fetch_barcode)
var $barcode_type_coder; // coder (loaded by fetch_barcode). Engine.
var $stats_propale=array();
var $stats_commande=array();
@ -163,10 +153,6 @@ class Product extends CommonObject
var $imgWidth;
var $imgHeight;
//! Canevas a utiliser si le produit n'est pas un produit generique
var $canvas;
var $import_key;
var $date_creation;
var $date_modification;
@ -183,9 +169,6 @@ class Product extends CommonObject
var $oldcopy;
//note not visible on orders and invoices
var $note;
var $fk_price_expression;
/**

View File

@ -33,15 +33,12 @@ class Productbatch extends CommonObject
var $element='productbatch'; //!< Id that identify managed objects
private static $_table_element='product_batch'; //!< Name of table without prefix where object is stored
var $id;
var $tms='';
var $fk_product_stock;
var $sellby='';
var $eatby='';
var $batch='';
var $qty;
var $import_key;
public $warehouseid;

View File

@ -28,12 +28,8 @@ require_once DOL_DOCUMENT_ROOT . '/core/class/commonobject.class.php';
*/
class Productcustomerprice extends CommonObject
{
var $db; // !< To store db handler
var $error; // !< To return error code (or message)
var $errors = array (); // !< To return several error codes (or messages)
var $element = 'product_customer_price'; // !< Id that identify managed objects
var $table_element = 'product_customer_price'; // !< Name of table without prefix where object is stored
var $id;
var $entity;
var $datec = '';
var $tms = '';
@ -49,7 +45,6 @@ class Productcustomerprice extends CommonObject
var $localtax1_tx;
var $localtax2_tx;
var $fk_user;
var $import_key;
var $lines = array ();
/**
@ -307,8 +302,8 @@ class Productcustomerprice extends CommonObject
{
global $langs;
if (! empty($sortfield)) $sortfield = "t.rowid";
if (! empty($sortorder)) $sortorder = "DESC";
if ( empty($sortfield)) $sortfield = "t.rowid";
if ( empty($sortorder)) $sortorder = "DESC";
$sql = "SELECT";
$sql .= " t.rowid,";
@ -351,8 +346,9 @@ class Productcustomerprice extends CommonObject
}
}
}
$sql.= $this->db->order($sortfield, $sortorder);
if (!empty($sortfield)) {
$sql.= $this->db->order($sortfield, $sortorder);
}
if (! empty($limit)) $sql .= ' ' . $this->db->plimit($limit + 1, $offset);
dol_syslog(get_class($this) . "::fetch_all", LOG_DEBUG);

View File

@ -31,13 +31,8 @@ require_once(DOL_DOCUMENT_ROOT."/core/class/commonobject.class.php");
*/
class Propalmergepdfproduct extends CommonObject
{
var $db; //!< To store db handler
var $error; //!< To return error code (or message)
var $errors=array(); //!< To return several error codes (or messages)
var $element='propal_merge_pdf_product'; //!< Id that identify managed objects
var $table_element='propal_merge_pdf_product'; //!< Name of table without prefix where object is stored
var $id;
var $fk_product;
var $file_name;
@ -45,7 +40,6 @@ class Propalmergepdfproduct extends CommonObject
var $fk_user_mod;
var $datec='';
var $tms='';
var $import_key;
var $lang;
var $lines=array();

View File

@ -29,9 +29,6 @@ require_once DOL_DOCUMENT_ROOT .'/core/class/commonobject.class.php';
*/
class Service extends CommonObject
{
var $db;
var $id;
var $libelle;
var $price;
var $tms;

View File

@ -35,7 +35,6 @@ class Entrepot extends CommonObject
public $element='stock';
public $table_element='entrepot';
var $id;
var $libelle;
var $description;
//! Statut 1 pour ouvert, 0 pour ferme
@ -46,10 +45,6 @@ class Entrepot extends CommonObject
var $zip;
var $town;
var $country;
var $country_id;
var $country_code;
/**
* Constructor

View File

@ -30,9 +30,6 @@
*/
class MouvementStock extends CommonObject
{
var $error;
var $db;
var $product_id;
var $entrepot_id;
var $qty;

View File

@ -466,6 +466,7 @@ if ($action == 'create' && $user->rights->projet->creer)
print $form->textwithtooltip($text.' '.img_help(),$texthelp,1);
}
else print $text;
print ' <a href="'.DOL_URL_ROOT.'/societe/soc.php?action=create&backtopage='.urlencode($_SERVER["PHP_SELF"].'?action=create').'">'.$langs->trans("AddThirdParty").'</a>';
print '</td></tr>';
// Status

View File

@ -43,8 +43,6 @@ class Project extends CommonObject
*/
protected $table_ref_field = 'ref';
var $id;
var $ref;
var $description;
/**
* @var string
@ -60,8 +58,6 @@ class Project extends CommonObject
var $user_author_id; //!< Id of project creator. Not defined if shared project.
var $user_close_id;
var $public; //!< Tell if this is a public or private project
var $note_private;
var $note_public;
var $budget_amount;
var $statuts_short;

View File

@ -24,7 +24,6 @@ include_once DOL_DOCUMENT_ROOT . '/core/lib/date.lib.php';
*/
class ProjectStats extends Stats
{
protected $db;
private $project;
public $userid;
public $socid;

View File

@ -34,11 +34,6 @@ class Task extends CommonObject
public $element='project_task'; //!< Id that identify managed objects
public $table_element='projet_task'; //!< Name of table without prefix where object is stored
var $id;
var $ref;
var $fk_project;
var $fk_task_parent;
var $label;
var $description;
@ -51,9 +46,6 @@ class Task extends CommonObject
var $priority;
var $fk_user_creat;
var $fk_user_valid;
var $statut;
var $note_private;
var $note_public;
var $rang;
var $timespent_id;

View File

@ -31,15 +31,9 @@ require_once DOL_DOCUMENT_ROOT."/core/lib/functions2.lib.php";
*/
class Resource extends CommonObject
{
var $db; //!< To store db handler
var $error; //!< To return error code (or message)
var $errors=array(); //!< To return several error codes (or messages)
var $element='resource'; //!< Id that identify managed objects
var $table_element='resource'; //!< Name of table without prefix where object is stored
var $id;
var $resource_id;
var $resource_type;
var $element_id;
@ -50,7 +44,6 @@ class Resource extends CommonObject
var $type_label;
var $tms='';
/**
* Constructor
*

View File

@ -29,11 +29,6 @@ include_once DOL_DOCUMENT_ROOT.'/societe/canvas/actions_card_common.class.php';
*/
class ActionsCardCompany extends ActionsCardCommon
{
var $dirmodule;
var $targetmodule;
var $canvas;
var $card;
/**
* Constructor
*

View File

@ -28,11 +28,6 @@ include_once DOL_DOCUMENT_ROOT.'/societe/canvas/actions_card_common.class.php';
*/
class ActionsCardIndividual extends ActionsCardCommon
{
var $dirmodule;
var $targetmodule;
var $canvas;
var $card;
/**
* Constructor
*

View File

@ -29,8 +29,6 @@ include_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php';
*/
class Client extends Societe
{
var $db;
var $next_prev_filter="te.client in (1,2,3)"; // Used to add a filter in Form::showrefnav method
var $cacheprospectstatus=array();

View File

@ -32,21 +32,8 @@ require_once DOL_DOCUMENT_ROOT .'/compta/bank/class/account.class.php';
*/
class CompanyBankAccount extends Account
{
var $rowid;
var $socid;
var $label;
var $bank;
var $courant;
var $clos;
var $code_banque;
var $code_guichet;
var $number;
var $cle_rib;
var $bic;
var $iban;
var $proprio;
var $owner_address;
var $default_rib;
var $frstrecur;

View File

@ -51,8 +51,6 @@ class Societe extends CommonObject
*/
protected $ismultientitymanaged = 1;
public $id;
public $name;
public $entity;
/**
@ -63,9 +61,6 @@ class Societe extends CommonObject
*/
public $nom;
var $firstname;
var $lastname;
/**
* Alias names (commercial, trademark or alias names)
* @var string
@ -73,7 +68,6 @@ class Societe extends CommonObject
public $name_alias;
public $particulier;
public $civility_id;
public $address;
public $zip;
public $town;
@ -113,9 +107,6 @@ class Societe extends CommonObject
* @see country
*/
var $pays;
var $country_id;
var $country_code;
var $country;
/**
* Phone number
@ -149,26 +140,6 @@ class Societe extends CommonObject
* @var string
*/
var $barcode;
/**
* ID of bardode type
* @var int
*/
var $barcode_type;
/**
* code (loaded by fetch_barcode)
* @var string
*/
var $barcode_type_code;
/**
* label (loaded by fetch_barcode)
* @var string
*/
var $barcode_type_label;
/**
* coder (loaded by fetch_barcode)
* @var string
*/
var $barcode_type_coder;
// 6 professional id (usage depends on country)
@ -233,8 +204,6 @@ class Societe extends CommonObject
var $forme_juridique;
var $remise_percent;
var $mode_reglement_id;
var $cond_reglement_id;
var $mode_reglement_supplier_id;
var $cond_reglement_supplier_id;
var $fk_prospectlevel;

View File

@ -56,6 +56,7 @@ if (! empty($conf->notification->enabled)) $langs->load("mails");
$mesg=''; $error=0; $errors=array();
$action = (GETPOST('action') ? GETPOST('action') : 'view');
$cancel = GETPOST('cancel');
$backtopage = GETPOST('backtopage','alpha');
$confirm = GETPOST('confirm');
$socid = GETPOST('socid','int');
@ -98,6 +99,16 @@ if ($reshook < 0) setEventMessages($hookmanager->error, $hookmanager->errors, 'e
if (empty($reshook))
{
if ($cancel)
{
$action='';
if (! empty($backtopage))
{
header("Location: ".$backtopage);
exit;
}
}
if ($action == 'confirm_merge' && $confirm == 'yes')
{
$object->fetch($socid);
@ -1158,11 +1169,11 @@ else
print '</td></tr>';
// Legal Form
print '<tr><td>'.fieldLabel('JuridicalStatus','legal_form').'</td>';
print '<tr><td>'.fieldLabel('JuridicalStatus','forme_juridique_code').'</td>';
print '<td colspan="3" class="maxwidthonsmartphone">';
if ($object->country_id)
{
print $formcompany->select_juridicalstatus($object->forme_juridique_code, $object->country_code, '', 'legal_form');
print $formcompany->select_juridicalstatus($object->forme_juridique_code, $object->country_code, '', 'forme_juridique_code');
}
else
{
@ -1273,7 +1284,12 @@ else
dol_fiche_end();
print '<div class="center">';
print '<input type="submit" class="button" value="'.$langs->trans('AddThirdParty').'">';
print '<input type="submit" class="button" name="submit" value="'.$langs->trans('AddThirdParty').'">';
if ($backtopage)
{
print ' &nbsp; ';
print '<input type="submit" class="button" name="cancel" value="'.$langs->trans('Cancel').'">';
}
print '</div>'."\n";
print '</form>'."\n";
@ -1741,8 +1757,8 @@ else
print '</td></tr>';
// Juridical type
print '<tr><td>'.fieldLabel('JuridicalStatus','legal_form').'</td><td colspan="3">';
print $formcompany->select_juridicalstatus($object->forme_juridique_code, $object->country_code, '', 'legal_form');
print '<tr><td>'.fieldLabel('JuridicalStatus','forme_juridique_code').'</td><td colspan="3">';
print $formcompany->select_juridicalstatus($object->forme_juridique_code, $object->country_code, '', 'forme_juridique_code');
print '</td></tr>';
// Capital

View File

@ -1,2 +0,0 @@
2012 Nicolas Péré <nicolas@amarok2.net>
2012 Xavier Peyronnet <xavier.peyronnet@free.fr>

View File

@ -1,92 +0,0 @@
/*
Copyright (c) 2003-2010, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.html or http://ckeditor.com/license
*/
CKEDITOR.editorConfig = function( config )
{
// Define changes to default configuration here.
// http://docs.cksource.com/CKEditor_3.x/Developers_Guide
// http://docs.cksource.com/ckeditor_api/symbols/CKEDITOR.config.html
config.enterMode = CKEDITOR.ENTER_BR;
config.resize_enabled = false;
//config.resize_maxHeight = 3000;
//config.resize_maxWidth = 3000;
//config.height = '300px';
//config.resize_dir = 'vertical'; // horizontal, vertical, both
config.removePlugins = 'elementspath,save'; // config.removePlugins = 'elementspath,save,font';
config.removeDialogTabs = 'flash:advanced'; // config.removeDialogTabs = 'flash:advanced;image:Link';
config.protectedSource.push( /<\?[\s\S]*?\?>/g ); // Prevent PHP Code to be formatted
//config.menu_groups = 'clipboard,table,anchor,link,image'; // for context menu 'clipboard,form,tablecell,tablecellproperties,tablerow,tablecolumn,table,anchor,link,image,flash,checkbox,radio,textfield,hiddenfield,imagebutton,button,select,textarea'
//config.language = 'de';
//config.defaultLanguage = 'en';
//config.contentsLanguage = 'fr';
config.fullPage = false; // Not a full html page string, just part of it
config.dialog_backgroundCoverColor = 'rgb(255, 254, 253)';
//config.contentsCss = '/css/mysitestyles.css';
config.image_previewText=' '; // Must no be empty
config.toolbar_Full =
[
['Source','-','Save','NewPage','Preview','-','Templates'],
['Cut','Copy','Paste','PasteText','PasteFromWord','-','Print', 'SpellChecker', 'Scayt'],
['Undo','Redo','-','Find','Replace','-','SelectAll','RemoveFormat'],
['Form', 'Checkbox', 'Radio', 'TextField', 'Textarea', 'Select', 'Button', 'ImageButton', 'HiddenField'],
'/',
['Bold','Italic','Underline','Strike','-','Subscript','Superscript'],
['NumberedList','BulletedList','-','Outdent','Indent','Blockquote','CreateDiv'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['BidiLtr', 'BidiRtl'],
['Link','Unlink','Anchor'],
['Image','Flash','Table','HorizontalRule','Smiley','SpecialChar','PageBreak','Iframe'],
'/',
['Styles','Format','Font','FontSize'],
['TextColor','BGColor'],
['Maximize', 'ShowBlocks','-','About']
];
// Used for mailing fields
config.toolbar_dolibarr_mailings =
[
['Source','Maximize'],
['Cut','Copy','Paste','-','SpellChecker'],
['Undo','Redo','-','Find','Replace'],
['Format','Font','FontSize'],
['Bold','Italic','Underline','Strike','Subscript','Superscript','-','TextColor','RemoveFormat'],
['NumberedList','BulletedList','Outdent','Indent','CreateDiv'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['Link','Unlink','Anchor','Image','Table','HorizontalRule','SpecialChar']
];
// Used for notes fields
config.toolbar_dolibarr_notes =
[
['Source','Maximize'],
['Cut','Copy','Paste','-','SpellChecker'],
['Undo','Redo','-','Find','Replace'],
['Format','Font','FontSize'],
['Bold','Italic','Underline','Strike','Subscript','Superscript','-','TextColor','RemoveFormat'],
['NumberedList','BulletedList','Outdent','Indent'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['Link','Unlink','Image','Table','HorizontalRule','SpecialChar']
];
// Used for details lines
config.toolbar_dolibarr_details =
[
['Source','Maximize'],
['Cut','Copy','Paste','-','SpellChecker'],
['Font','FontSize'],
['Bold','Italic','Underline','Strike','Subscript','Superscript','-','TextColor','RemoveFormat'],
['NumberedList','BulletedList','Outdent','Indent'],
['JustifyLeft','JustifyCenter','JustifyRight','JustifyBlock'],
['Link','Unlink','SpecialChar']
];
// Used for mailing fields
config.toolbar_dolibarr_readonly =
[
['Source','Maximize'],
['Find']
];
};

View File

@ -1,30 +0,0 @@
<?PHP
/* Copyright (C) 2004 Rodolphe Quiedeville <rodolphe@quiedeville.org>
* Copyright (C) 2004-2007 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
* the Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
/**
* \file htdocs/theme/amarok/graph-color.php
* \brief File to declare colors to use to build graphics with theme Amarok
* \ingroup core
*/
global $theme_bordercolor, $theme_datacolor, $theme_bgcolor, $theme_bgcoloronglet;
$theme_bordercolor = array(235,235,224);
$theme_datacolor = array(array(190,190,220), array(200,160,180), array(125,135,150), array(170,140,190), array(190,190,170));
$theme_bgcolor = array(hexdec('F4'),hexdec('F4'),hexdec('F4'));
$theme_bgcoloronglet = array(hexdec('DE'),hexdec('E7'),hexdec('EC'));

Binary file not shown.

Before

Width:  |  Height:  |  Size: 117 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 117 B

Some files were not shown because too many files have changed in this diff Show More