Skip to content

Commit

Permalink
Merge branch 'Upstream/develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
aspangaro committed May 29, 2014
2 parents 22bb789 + 82a2a72 commit aa4e9d5
Show file tree
Hide file tree
Showing 202 changed files with 1,002 additions and 563 deletions.
3 changes: 2 additions & 1 deletion .scrutinizer.yml
Expand Up @@ -100,8 +100,9 @@ tools:
comparison_of_bit_result: true
basic_semantic_checks:
enabled: true
# Disabled unused code. In most cases, we want to keep it.
unused_code:
enabled: true
enabled: false
deprecation_checks:
enabled: true
useless_function_calls:
Expand Down
7 changes: 7 additions & 0 deletions ChangeLog
Expand Up @@ -133,6 +133,12 @@ Fix: [ bug #1393 ] PHP Warning when creating a supplier invoice.
Fix: [ bug #1399 ] [pgsql] Silent warning when setting a propal as "facturée" in propal.php
Fix: When number reach 9999 with default numbering module, next number
will be 10000 instead of 0000 and error.
Fix: element page on project give wrong href link.
Fix: [ bug #1397 ] Filter by supplier orders with status Draft does not filter.
Fix: [ bug #1388 ] Wrong date when invoicing several orders.
Fix: [ bug #1411 ] Unable to set an expedition note if invoices module is not enabled.
Fix: [ bug #1407 ] Rouget pdf overlapped when using tracking number and public notes.
Fix: [ bug #1405 ] Rouget PDF expedition incorrect when two expeditions under the same commande

***** ChangeLog for 3.5.2 compared to 3.5.1 *****
Fix: Can't add user for a task.
Expand Down Expand Up @@ -220,6 +226,7 @@ Fix: [ bug #1306 ] Fatal error when adding an external calendar.
New: Added es_CL language
Fix: Margin tabs bad data show
Fix: [ bug #1318 ] Problem with enter key when adding an existing product to a customer invoice.
Fix: [ bug #1410 ] Add customer order line asks for required Unit Price but doesn't interrupt the creation of the line

***** ChangeLog for 3.5 compared to 3.4.* *****
For users:
Expand Down
4 changes: 3 additions & 1 deletion build/debian/README.howto
Expand Up @@ -229,7 +229,9 @@ from origin/upstream and origin/pristine.
* If new upstream is available onto sourceforge, launch:
> debian/get-orig-source.sh

* Edit tgz file to remove ckeditor and phpexcel and renama file into dolibarr-x.y.z+dsfgw.tgz
* Edit tgz file to remove ckeditor and phpexcel and rename file into
dolibarr-x.y.z+dsfgw.tgz
(x.y.z = version, w start from 1 and is increased for each new import)

* Staying into git root directory, run
> git-import-orig -vv ../dolibarr-x.y.z+dsfgw.tgz
Expand Down
1 change: 0 additions & 1 deletion build/dmg/dolimamp/install.forced.php
Expand Up @@ -14,4 +14,3 @@
$force_install_dolibarrlogin='admin';
$force_install_nophpinfo='1';
$force_install_lockinstall='444';
?>
1 change: 1 addition & 0 deletions build/makepack-dolibarr.pl
Expand Up @@ -452,6 +452,7 @@
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/adapters`; # Keep this removal in case we embed libraries
#$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/ckeditor/_source`; # _source must be kept into tarball

$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/datatables/extras/TableTools/swf`; # Source of this flash is not available
$ret=`rm -f $BUILDROOT/$PROJECT/htdocs/includes/jquery/plugins/multiselect/MIT-LICENSE.txt`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nusoap/lib/Mail`;
$ret=`rm -fr $BUILDROOT/$PROJECT/htdocs/includes/nusoap/samples`;
Expand Down
1 change: 0 additions & 1 deletion dev/examples/create_invoice.php
Expand Up @@ -115,4 +115,3 @@
$db->close();

return $error;
?>
23 changes: 23 additions & 0 deletions dev/rmphpclosingtag.sh
@@ -0,0 +1,23 @@
#!/bin/bash
# vim:ft=sh:ts=3:sts=3:sw=3:et:

###
# Strips the closing php tag `?>` and any following blank lines from the
# end of any PHP file in the current working directory and sub-directories. Files
# with non-whitespace characters following the closing tag will not be affected.
#
# Author: Bryan C. Geraghty <bryan@ravensight.org>
# Date: 2009-10-28
# Source: http://bryan.ravensight.org/2010/07/remove-php-closing-tag/
##

FILES=$(pcregrep -rnM --include='^.*\.php$' '^\?\>(?=([\s\n]+)?$(?!\n))' .);

for MATCH in $FILES;
do
FILE=`echo $MATCH | awk -F ':' '{print $1}'`;
TARGET=`echo $MATCH | awk -F ':' '{print $2}'`;
LINE_COUNT=`wc -l $FILE | awk -F " " '{print $1}'`;
echo "Removing lines ${TARGET} through ${LINE_COUNT} from file $FILE...";
sed -i "${TARGET},${LINE_COUNT}d" $FILE;
done;
1 change: 0 additions & 1 deletion dev/skeletons/skeleton_class.class.php
Expand Up @@ -371,4 +371,3 @@ function initAsSpecimen()
}

}
?>
1 change: 0 additions & 1 deletion dev/skeletons/skeleton_webservice_server.php
Expand Up @@ -271,4 +271,3 @@ function createSkeleton($authentication,$skeleton)
// Return the results.
$server->service($HTTP_RAW_POST_DATA);

?>
1 change: 0 additions & 1 deletion dev/translation/autotranslator.class.php
Expand Up @@ -338,4 +338,3 @@ private function translateTexts($src_texts, $src_lang, $dest_lang)
}

}
?>
1 change: 0 additions & 1 deletion dev/translation/strip_language_file.php
Expand Up @@ -264,4 +264,3 @@


return 0;
?>
1 change: 0 additions & 1 deletion htdocs/accountancy/class/accountancyaccount.class.php
Expand Up @@ -93,4 +93,3 @@ function create($user)
}

}
?>
Expand Up @@ -62,7 +62,7 @@ function __construct($db, $dirmodule, $targetmodule, $canvas, $card)
*/
private function getTitle($action)
{
global $langs;
global $langs,$conf;

$out='';

Expand Down
5 changes: 2 additions & 3 deletions htdocs/adherents/card_subscriptions.php
Expand Up @@ -138,7 +138,7 @@
if ($_POST["userid"] != $object->user_id) // If link differs from currently in database
{
$result=$object->setUserId($_POST["userid"]);
if ($result < 0) dol_print_error($object->db,$object->error);
if ($result < 0) dol_print_error('',$object->error);
$_POST['action']='';
$action='';
}
Expand Down Expand Up @@ -172,7 +172,7 @@
if (! $error)
{
$result=$object->setThirdPartyId(GETPOST('socid','int'));
if ($result < 0) dol_print_error($object->db,$object->error);
if ($result < 0) dol_print_error('',$object->error);
$_POST['action']='';
$action='';
}
Expand Down Expand Up @@ -1101,4 +1101,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/adherents/cartes/carte.php
Expand Up @@ -280,4 +280,3 @@
llxFooter();

$db->close();
?>
2 changes: 2 additions & 0 deletions htdocs/adherents/class/adherent.class.php
Expand Up @@ -95,6 +95,8 @@ class Adherent extends CommonObject
var $first_subscription_date;
var $first_subscription_amount;
var $last_subscription_date;
var $last_subscription_date_start;
var $last_subscription_date_end;
var $last_subscription_amount;
var $subscriptions=array();

Expand Down
12 changes: 8 additions & 4 deletions htdocs/adherents/class/adherent_type.class.php
Expand Up @@ -99,8 +99,10 @@ function create($user)
*/
function update($user)
{
global $hookmanager;

global $hookmanager,$conf;

$error=0;

$this->libelle=trim($this->libelle);

$sql = "UPDATE ".MAIN_DB_PREFIX."adherent_type ";
Expand All @@ -116,6 +118,8 @@ function update($user)
$result = $this->db->query($sql);
if ($result)
{
$action='update';

// Actions on extra fields (by external module or standard code)
$hookmanager->initHooks(array('membertypedao'));
$parameters=array('membertype'=>$this->id);
Expand All @@ -132,8 +136,8 @@ function update($user)
}
}
else if ($reshook < 0) $error++;


return 1;
}
else
Expand Down
10 changes: 4 additions & 6 deletions htdocs/admin/agenda_extsites.php
Expand Up @@ -30,8 +30,7 @@
require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';

if (!$user->admin)
accessforbidden();
if (!$user->admin) accessforbidden();

$langs->load("agenda");
$langs->load("admin");
Expand Down Expand Up @@ -63,7 +62,7 @@
// Save agendas
while ($i <= $MAXAGENDA)
{
$name=trim(GETPOST('agenda_ext_name'.$i),'alpha');
$name=trim(GETPOST('agenda_ext_name'.$i,'alpha'));
$src=trim(GETPOST('agenda_ext_src'.$i,'alpha'));
$color=trim(GETPOST('agenda_ext_color'.$i,'alpha'));
if ($color=='-1') $color='';
Expand All @@ -76,7 +75,7 @@
break;
}

//print 'color='.$color;
//print '-name='.$name.'-color='.$color;
$res=dolibarr_set_const($db,'AGENDA_EXT_NAME'.$i,$name,'chaine',0,'',$conf->entity);
if (! $res > 0) $error++;
$res=dolibarr_set_const($db,'AGENDA_EXT_SRC'.$i,$src,'chaine',0,'',$conf->entity);
Expand Down Expand Up @@ -218,8 +217,7 @@
print '<br>';

print '<center>';

print "<input type=\"submit\" name=\"save\" class=\"button\" value=\"".$langs->trans("Save")."\">";
print "<input type=\"submit\" id=\"save\" name=\"save\" class=\"button hideifnotset\" value=\"".$langs->trans("Save")."\">";
print "</center>";

print "</form>\n";
Expand Down
2 changes: 1 addition & 1 deletion htdocs/admin/barcode.php
Expand Up @@ -64,7 +64,7 @@
{
if (GETPOST('submit_GENBARCODE_LOCATION'))
{
$location = GETPOST('genbarcodelocation','alpha');
$location = GETPOST('GENBARCODE_LOCATION','alpha');
$res = dolibarr_set_const($db, "GENBARCODE_LOCATION",$location,'chaine',0,'',$conf->entity);
}
if (GETPOST('submit_PRODUIT_DEFAULT_BARCODE_TYPE'))
Expand Down
1 change: 0 additions & 1 deletion htdocs/admin/boxes.php
Expand Up @@ -468,4 +468,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/compta.php
Expand Up @@ -170,4 +170,3 @@
$db->close();

llxFooter();
?>
1 change: 0 additions & 1 deletion htdocs/admin/fichinter.php
Expand Up @@ -511,4 +511,3 @@
$db->close();

llxFooter();
?>
1 change: 0 additions & 1 deletion htdocs/admin/index.php
Expand Up @@ -116,4 +116,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/mailing.php
Expand Up @@ -143,4 +143,3 @@ function(token) {
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/mails.php
Expand Up @@ -703,4 +703,3 @@ function initfields()
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/modules.php
Expand Up @@ -540,4 +540,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/orderdet_extrafields.php
Expand Up @@ -157,4 +157,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/osc-languages.php
Expand Up @@ -88,4 +88,3 @@
$db->close();

llxFooter();
?>
1 change: 0 additions & 1 deletion htdocs/admin/supplierorder_extrafields.php
Expand Up @@ -156,4 +156,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/syslog.php
Expand Up @@ -253,4 +253,3 @@
llxFooter();

$db->close();
?>
23 changes: 9 additions & 14 deletions htdocs/admin/system/about.php
Expand Up @@ -113,28 +113,23 @@
print '</ul>';


print $langs->trans("OfficialWebHostingService").':';
$url='http://wiki.dolibarr.org/index.php/Cloud_Solutions'; $title=$langs->trans('List');
print $langs->trans("OtherResources").':';
print '<ul>';

$url='http://saas.dolibarr.org'; $title=$langs->trans("OfficialWebHostingService");
if (preg_match('/^fr_/i',$langs->getDefaultLang())) $url='http://wiki.dolibarr.org/index.php/Solutions_de_Cloud';
if (preg_match('/^es_/i',$langs->getDefaultLang())) $url='http://wiki.dolibarr.org/index.php/Soluciones_en_la_Nube';
print '<ul>';
print '<li>';
print '<a target="_blank" href="'.$url.'">'.$title.'</a>';
print '</li>';
$url='http://partners.dolibarr.org'; $title=$langs->trans("ReferencedPreferredPartners");
print '<li>';
print '<a target="_blank" href="'.$url.'">'.$title.'</a>';
print '</li>';

print '</ul>';


llxFooter();

$db->close();
?>










1 change: 0 additions & 1 deletion htdocs/admin/system/os.php
Expand Up @@ -51,4 +51,3 @@


llxFooter();
?>
29 changes: 23 additions & 6 deletions htdocs/admin/system/perf.php
Expand Up @@ -86,18 +86,35 @@
// OPCode cache
print '<br>';
print '<strong>'.$langs->trans("OPCodeCache").'</strong>: ';
$test1=function_exists('xcache_info');
if ($test1)
$foundcache=0;
$test=function_exists('xcache_info');
if (! $foundcache && $test)
{
$foundcache++;
print img_picto('','tick.png').' '.$langs->trans("XCacheInstalled");
print ' '.$langs->trans("MoreInformation").' <a href="'.DOL_URL_ROOT.'/admin/system/xcache.php'.'">Xcache admin page</a>';
}
else
$test=function_exists('eaccelerator_info');
if (! $foundcache && $test)
{
$foundcache++;
print img_picto('','tick.png').' '.$langs->trans("EAcceleratorInstalled");
}
$test=function_exists('apc_cache_info');
if (! $foundcache && $test)
{
$test2=function_exists('eaccelerator_info');
if ($test2) print img_picto('','tick.png').' '.$langs->trans("EAcceleratorInstalled");
else print $langs->trans("NoOPCodeCacheFound");
//var_dump(apc_cache_info());
if (ini_get('apc.enabled'))
{
$foundcache++;
print img_picto('','tick.png').' '.$langs->trans("APCInstalled");
}
else
{
print img_picto('','warning').' '.$langs->trans("APCCacheInstalledButDisabled");
}
}
if (! $foundcache) print $langs->trans("NoOPCodeCacheFound");
print '<br>';

// HTTPCacheStaticResources
Expand Down
1 change: 0 additions & 1 deletion htdocs/admin/system/phpinfo.php
Expand Up @@ -120,4 +120,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/system/web.php
Expand Up @@ -64,4 +64,3 @@
llxFooter();

$db->close();
?>
1 change: 0 additions & 1 deletion htdocs/admin/tools/listsessions.php
Expand Up @@ -214,4 +214,3 @@

llxFooter();
$db->close();
?>

0 comments on commit aa4e9d5

Please sign in to comment.