Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/develop' into camelCaps
Browse files Browse the repository at this point in the history
  • Loading branch information
frederic34 committed Aug 29, 2018
2 parents fe4260a + 86d8513 commit cbdc669
Show file tree
Hide file tree
Showing 40 changed files with 271 additions and 225 deletions.
14 changes: 7 additions & 7 deletions htdocs/accountancy/class/accountancycategory.class.php
Expand Up @@ -30,31 +30,31 @@
*/
class AccountancyCategory // extends CommonObject
{
/**
/**
* @var DoliDB Database handler.
*/
public $db;

/**
* @var string Error string
* @see errors
*/
public $error;

/**
* @var string[] Error codes (or messages)
*/
public $errors = array();

/**
* @var string ID to identify managed object
*/
public $element='c_accounting_category';
public $element='c_accounting_category';

/**
* @var string Name of table without prefix where object is stored
*/
public $table_element='c_accounting_category';
public $table_element='c_accounting_category';

public $id;
public $code;
Expand Down
26 changes: 17 additions & 9 deletions htdocs/accountancy/class/accountingaccount.class.php
Expand Up @@ -80,15 +80,23 @@ class AccountingAccount extends CommonObject
var $account_parent;
var $account_category;

/**
* @var string proper name for given parameter
*/
public $label;
/**
* @var string Label of account
*/
public $label;

/**
* @var int ID
*/
public $fk_user_author;

/**
* @var int ID
*/
public $fk_user_modif;

var $fk_user_author;
var $fk_user_modif;
var $active; // duplicate with status
var $status;
public $active; // duplicate with status
public $status;


/**
Expand Down Expand Up @@ -422,7 +430,7 @@ function delete($user, $notrigger = 0)
* @param string $moretitle Add more text to title tooltip
* @param int $notooltip 1=Disable tooltip
* @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking
* @return string String with URL
* @return string String with URL
*/
function getNomUrl($withpicto = 0, $withlabel = 0, $nourl = 0, $moretitle='',$notooltip=0, $save_lastsearch_value=-1)
{
Expand Down
6 changes: 3 additions & 3 deletions htdocs/adherents/canvas/actions_adherentcard_common.class.php
Expand Up @@ -31,7 +31,7 @@ abstract class ActionsAdherentCardCommon
* @var DoliDB Database handler.
*/
public $db;

var $dirmodule;
var $targetmodule;
var $canvas;
Expand All @@ -41,11 +41,11 @@ abstract class ActionsAdherentCardCommon
var $tpl = array();
//! Object container
var $object;

/**
* @var string Error code (or message)
*/
public $error='';
public $error='';

/**
* @var string[] Error codes (or messages)
Expand Down
10 changes: 5 additions & 5 deletions htdocs/adherents/class/adherent.class.php
Expand Up @@ -45,12 +45,12 @@ class Adherent extends CommonObject
* @var string ID to identify managed object
*/
public $element='member';

/**
* @var string Name of table without prefix where object is stored
*/
public $table_element='adherent';

public $ismultientitymanaged = 1; // 0=No test on entity, 1=Test with field entity, 2=Test with link by societe

var $mesgs;
Expand Down Expand Up @@ -543,10 +543,10 @@ function update($user,$notrigger=0,$nosyncuser=0,$nosyncuserpass=0,$nosyncthirdp
$luser->birth=$this->birth;
$luser->address=$this->address;
$luser->zip=$this->zip;
$luser->town=$this->town;
$luser->country_id=$this->country_id;
$luser->town=$this->town;
$luser->country_id=$this->country_id;
$luser->state_id=$this->state_id;

$luser->email=$this->email;
$luser->skype=$this->skype;
$luser->office_phone=$this->phone;
Expand Down
14 changes: 10 additions & 4 deletions htdocs/comm/mailing/cibles.php
Expand Up @@ -303,9 +303,11 @@
// Sort $modulenames
sort($modulenames);

$var = true;

// Loop on each submodule
foreach($modulenames as $modulename)
{
foreach($modulenames as $modulename)
{
// Loading Class
$file = $dir.$modulename.".modules.php";
$classname = "mailing_".$modulename;
Expand All @@ -326,14 +328,18 @@
}

// Si le module mailing est qualifie
if ($qualified)
{
$var = ! $var;

if ($allowaddtarget)
{
print '<form class="oddeven tagtr" name="'.$modulename.'" action="'.$_SERVER['PHP_SELF'].'?action=add&id='.$object->id.'&module='.$modulename.'" method="POST" enctype="multipart/form-data">';
print '<form '.$bctag[$var].' name="'.$modulename.'" action="'.$_SERVER['PHP_SELF'].'?action=add&id='.$object->id.'&module='.$modulename.'" method="POST" enctype="multipart/form-data">';
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
}
else
{
print '<div class="oddeven tagtr">';
print '<div '.$bctag[$var].'>';
}

print '<div class="tagtd">';
Expand Down
12 changes: 6 additions & 6 deletions htdocs/comm/mailing/class/advtargetemailing.class.php
Expand Up @@ -28,10 +28,10 @@
*/
class AdvanceTargetingMailing extends CommonObject
{
/**
* @var DoliDB Database handler.
*/
public $db;
/**
* @var DoliDB Database handler.
*/
public $db;

/**
* @var string Error code (or message)
Expand Down Expand Up @@ -75,9 +75,9 @@ class AdvanceTargetingMailing extends CommonObject


/**
* Constructor
* Constructor
*
* @param DoliDb $db Database handler
* @param DoliDb $db Database handler
*/
function __construct($db)
{
Expand Down
10 changes: 5 additions & 5 deletions htdocs/comm/mailing/class/html.formadvtargetemailing.class.php
Expand Up @@ -30,7 +30,7 @@ class FormAdvTargetEmailing extends Form
* @var DoliDB Database handler.
*/
public $db;

/**
* @var string Error code (or message)
*/
Expand Down Expand Up @@ -378,10 +378,10 @@ function multiselectContactCategories($htmlname='contact_cat',$selected_array =
/**
* Return combo list of categories
*
* @param string $htmlname Name of categorie
* @param array $selected_array value selected
* @param int $type type
* @return string HTML combo
* @param string $htmlname Name of categorie
* @param array $selected_array Value selected
* @param int $type Type
* @return string HTML combo
*/
public function multiselectCategories($htmlname='',$selected_array = array(), $type=0)
{
Expand Down
2 changes: 1 addition & 1 deletion htdocs/compta/facture/card.php
Expand Up @@ -3705,7 +3705,7 @@
$discount = new DiscountAbsolute($db);
$result = $discount->fetch(0, $object->id);
if ($result > 0){
print '. '.$langs->trans("CreditNoteConvertedIntoDiscount", $object->getLibType(), $discount->getNomUrl(1, 'discount')).'<br>';
print '. '.$langs->trans("CreditNoteConvertedIntoDiscount", $object->getLibType(1), $discount->getNomUrl(1, 'discount')).'<br>';
}
}
print '</td></tr>';
Expand Down
10 changes: 5 additions & 5 deletions htdocs/compta/localtax/class/localtax.class.php
Expand Up @@ -32,26 +32,26 @@ class Localtax extends CommonObject
/**
* @var string ID to identify managed object
*/
public $element='localtax';
public $element='localtax';

/**
* @var string Name of table without prefix where object is stored
*/
public $table_element='localtax';

public $picto='payment';

var $ltt;
var $tms;
var $datep;
var $datev;
var $amount;

/**
* @var string proper name for given parameter
*/
public $label;

var $fk_bank;
var $fk_user_creat;
var $fk_user_modif;
Expand Down
6 changes: 3 additions & 3 deletions htdocs/compta/salaries/class/paymentsalary.class.php
Expand Up @@ -35,12 +35,12 @@ class PaymentSalary extends CommonObject
* @var string ID to identify managed object
*/
public $element='payment_salary';

/**
* @var string Name of table without prefix where object is stored
*/
public $table_element='payment_salary';
public $table_element='payment_salary';

public $picto='payment';

public $tms;
Expand Down
Expand Up @@ -35,12 +35,12 @@ class PaymentSocialContribution extends CommonObject
* @var string ID to identify managed object
*/
public $element='paiementcharge';

/**
* @var string Name of table without prefix where object is stored
*/
public $table_element='paiementcharge';
public $table_element='paiementcharge';

public $picto = 'payment';

var $fk_charge;
Expand Down
8 changes: 4 additions & 4 deletions htdocs/core/ajax/ajaxdirpreview.php
Expand Up @@ -158,8 +158,8 @@
//print '<!-- Page called with mode='.dol_escape_htmltag(isset($mode)?$mode:'').' type='.dol_escape_htmltag($type).' module='.dol_escape_htmltag($module).' url='.dol_escape_htmltag($url).' '.dol_escape_htmltag($_SERVER["PHP_SELF"]).'?'.dol_escape_htmltag($_SERVER["QUERY_STRING"]).' -->'."\n";

$param=($sortfield?'&sortfield='.$sortfield:'').($sortorder?'&sortorder='.$sortorder:'');
if (! empty($website)) $param.='&website='.$website;
if (! empty($pageid)) $param.='&pageid='.$pageid;
if (! empty($websitekey)) $param.='&website='.$websitekey;
if (! empty($pageid)) $param.='&pageid='.$pageid;


// Dir scan
Expand Down Expand Up @@ -234,7 +234,7 @@
$param.='&file_manager=1';
if (!preg_match('/website=/',$param)) $param.='&website='.urlencode(GETPOST('website','alpha'));
if (!preg_match('/pageid=/',$param)) $param.='&pageid='.urlencode(GETPOST('pageid','int'));
//if (!preg_match('/backtopage=/',$param)) $param.='&backtopage='.urlencode($_SERVER["PHP_SELF"].'?file_manager=1&website='.$website.'&pageid='.$pageid);
//if (!preg_match('/backtopage=/',$param)) $param.='&backtopage='.urlencode($_SERVER["PHP_SELF"].'?file_manager=1&website='.$websitekey.'&pageid='.$pageid);
}
}
else
Expand Down Expand Up @@ -315,7 +315,7 @@
$formquestion['section_id']=array('type'=>'hidden','value'=>$section_id,'name'=>'section_id'); // We must always put field, even if empty because it is fille by javascript later
$formquestion['section_dir']=array('type'=>'hidden','value'=>$section_dir,'name'=>'section_dir'); // We must always put field, even if empty because it is fille by javascript later
if (! empty($action) && $action == 'file_manager') $formquestion['file_manager']=array('type'=>'hidden','value'=>1,'name'=>'file_manager');
if (! empty($website)) $formquestion['website']=array('type'=>'hidden','value'=>$website,'name'=>'website');
if (! empty($websitekey)) $formquestion['website']=array('type'=>'hidden','value'=>$websitekey,'name'=>'website');
if (! empty($pageid) && $pageid > 0) $formquestion['pageid']=array('type'=>'hidden','value'=>$pageid,'name'=>'pageid');

print $form->formconfirm($url,$langs->trans("DeleteFile"),$langs->trans("ConfirmDeleteFile"),'confirm_deletefile',$formquestion,"no",($useajax?'deletefile':0));
Expand Down
2 changes: 1 addition & 1 deletion htdocs/core/ajax/ajaxdirtree.php
Expand Up @@ -201,7 +201,7 @@
// Edit link
print '<td align="right" width="18"><a href="';
print DOL_URL_ROOT.'/ecm/dir_card.php?module='.urlencode($modulepart).'&section='.$val['id'].'&relativedir='.urlencode($val['fullrelativename']);
print '&backtopage='.urlencode($_SERVER["PHP_SELF"].'?file_manager=1&website='.$website.'&pageid='.$pageid);
print '&backtopage='.urlencode($_SERVER["PHP_SELF"].'?file_manager=1&website='.$websitekey.'&pageid='.$pageid);
print '">'.img_edit($langs->trans("Edit").' - '.$langs->trans("View"), 0, 'class="valignmiddle opacitymedium"').'</a></td>';

// Add link
Expand Down
21 changes: 19 additions & 2 deletions htdocs/core/class/comment.class.php
@@ -1,4 +1,21 @@
<?php
/*
*
* 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/>.
* or see http://www.gnu.org/
*/

/**
* Class to manage comment
*/
Expand All @@ -8,11 +25,11 @@ class Comment extends CommonObject
* @var string ID to identify managed object
*/
public $element='comment';

/**
* @var string Name of table without prefix where object is stored
*/
public $table_element='comment';
public $table_element='comment';

public $fk_element;
public $element_type;
Expand Down

0 comments on commit cbdc669

Please sign in to comment.