Skip to content
Snippets Groups Projects
Commit 24d0568e authored by aspangaro's avatar aspangaro
Browse files

Merge remote-tracking branch 'Upstream/develop' into develop-patch

parents e43de8b8 9c51effe
No related branches found
No related tags found
No related merge requests found
......@@ -61,13 +61,17 @@ If you want to build/test package locally:
- List of series are visible here: https://launchpad.net/dolibarr/+series
# To update Dolibarr into launchpad (when repository for sources already exists)
# To update Dolibarr into launchpad (when remote repository for sources already exists)
#----------------------------------
# create local repository
cd bzr
bzr branch lp:~yourlogin/dolibarr/[dev|beta|stable]
bzr branch lp:~yourlogin/dolibarr/[develop|beta|stable] dolibarr-[dev|beta|stable]
cd dolibarr-[dev|beta|stable]
# Update
bzr update
-- Update files here. Remove all and overwrite --
bzr status
-- Update files here --
bzr add *
bzr commit -m "Description of change"
bzr push
......
<?php
/* Copyright (C) 2004-2013 Laurent Destailleur <eldy@users.sourceforge.net>
/* Copyright (C) 2004-2014 Laurent Destailleur <eldy@users.sourceforge.net>
* Copyright (C) 2005-2012 Regis Houssin <regis.houssin@capnetworks.com>
*
* This program is free software; you can redistribute it and/or modify
......@@ -229,10 +229,11 @@ if ($result)
// Description
print '<td>';
$text=$langs->trans($obj->description);
if (preg_match('/\((.*)\)/i',$obj->description,$reg))
if (preg_match('/\((.*)\)(.*)/i',$obj->description,$reg))
{
$val=explode(',',$reg[1]);
$text=$langs->trans($val[0], isset($val[1])?$val[1]:'', isset($val[2])?$val[2]:'', isset($val[3])?$val[3]:'', isset($val[4])?$val[4]:'');
if (! empty($reg[2])) $text.=$reg[2];
}
print $text;
print '</td>';
......
......@@ -111,7 +111,7 @@ class Events // extends CommonObject
$this->description=trim($this->description);
// Check parameters
if (! $this->description) { $this->error='ErrorBadValueForParameter'; return -1; }
if (empty($this->description)) { $this->error='ErrorBadValueForParameter'; return -1; }
// Insert request
$sql = "INSERT INTO ".MAIN_DB_PREFIX."events(";
......@@ -129,7 +129,7 @@ class Events // extends CommonObject
$sql.= " ".($_SERVER['HTTP_USER_AGENT']?"'".dol_trunc($_SERVER['HTTP_USER_AGENT'],250)."'":'NULL').",";
$sql.= " '".$this->db->idate($this->dateevent)."',";
$sql.= " ".($user->id?"'".$user->id."'":'NULL').",";
$sql.= " '".$this->db->escape($this->description)."'";
$sql.= " '".$this->db->escape(dol_trunc($this->description,250))."'";
$sql.= ")";
dol_syslog(get_class($this)."::create", LOG_DEBUG);
......
......@@ -66,7 +66,9 @@ class InterfaceLogevents extends DolibarrTriggers
// Initialisation donnees (date,duree,texte,desc)
$text="(UserLogged,".$object->login.")";
$text.=(empty($object->trigger_mesg)?'':' - '.$object->trigger_mesg);
$desc="(UserLogged,".$object->login.")";
$desc.=(empty($object->trigger_mesg)?'':' - '.$object->trigger_mesg);
}
if ($action == 'USER_LOGIN_FAILED')
{
......
......@@ -1064,8 +1064,8 @@ ALTER TABLE llx_adherent CHANGE COLUMN civilite civility VARCHAR(6);
ALTER TABLE llx_socpeople CHANGE COLUMN civilite civility VARCHAR(6);
ALTER TABLE llx_user CHANGE COLUMN civilite civility VARCHAR(6);
ALTER TABLE llx_societe CHANGE COLUMN nom varchar(128);
ALTER TABLE llx_adherent CHANGE COLUMN societe varchar(128);
ALTER TABLE llx_societe MODIFY COLUMN nom varchar(128);
ALTER TABLE llx_adherent MODIFY COLUMN societe varchar(128);
ALTER TABLE llx_c_type_fees CHANGE COLUMN libelle label VARCHAR(30);
ALTER TABLE llx_c_type_fees ADD COLUMN accountancy_code varchar(32) DEFAULT NULL AFTER label;
......
......@@ -460,7 +460,7 @@ if (! defined('NOLOGIN'))
$datesecond=dol_stringtotime($_POST["dst_second"]);
if ($datenow >= $datefirst && $datenow < $datesecond) $dol_dst=1;
}
//print $datefirst.'-'.$datesecond.'-'.$datenow; exit;
//print $datefirst.'-'.$datesecond.'-'.$datenow.'-'.$dol_tz.'-'.$dol_tzstring.'-'.$dol_dst; exit;
}
if (! $login)
......@@ -621,6 +621,8 @@ if (! defined('NOLOGIN'))
$user->update_last_login_date();
$user->trigger_mesg = 'TZ='.$_SESSION["dol_tz"].';TZString='.$_SESSION["dol_tz_string"].';Screen='.$_SESSION["dol_screenwidth"].'x'.$_SESSION["dol_screenheight"];
// TODO We should use a hook here, not a trigger
// Call triggers
include_once DOL_DOCUMENT_ROOT . '/core/class/interfaces.class.php';
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment