Skip to content

Commit

Permalink
Merge branch 'develop' of git@github.com:Dolibarr/dolibarr.git into d…
Browse files Browse the repository at this point in the history
…evelop
  • Loading branch information
eldy committed Mar 24, 2017
2 parents 720a820 + 278bbf1 commit 292bcae
Show file tree
Hide file tree
Showing 32 changed files with 1,657 additions and 1,036 deletions.
47 changes: 23 additions & 24 deletions htdocs/accountancy/admin/index.php
Expand Up @@ -142,18 +142,17 @@
}

if ($action == 'setdisabledirectinput') {
$setdisabledirectinput = GETPOST('value', 'int');
$res = dolibarr_set_const($db, "BANK_DISABLE_DIRECT_INPUT", $setdisabledirectinput, 'yesno', 0, '', $conf->entity);
if (! $res > 0)
$error ++;
if (! $error) {
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
} else {
setEventMessages($langs->trans("Error"), null, 'mesgs');
}
$setdisabledirectinput = GETPOST('value', 'int');
$res = dolibarr_set_const($db, "BANK_DISABLE_DIRECT_INPUT", $setdisabledirectinput, 'yesno', 0, '', $conf->entity);
if (! $res > 0)
$error ++;
if (! $error) {
setEventMessages($langs->trans("SetupSaved"), null, 'mesgs');
} else {
setEventMessages($langs->trans("Error"), null, 'mesgs');
}
}


/*
* View
*/
Expand Down Expand Up @@ -243,20 +242,20 @@
}
print '</tr>';

$var = ! $var;
print "<tr " . $bc[$var] . ">";
print '<td>' . $langs->trans("BANK_DISABLE_DIRECT_INPUT") . '</td>';
if (! empty($conf->global->BANK_DISABLE_DIRECT_INPUT)) {
print '<td align="right"><a href="' . $_SERVER['PHP_SELF'] . '?action=setdisabledirectinput&value=0">';
print img_picto($langs->trans("Activated"), 'switch_on');
print '</a></td>';
} else {
print '<td align="right"><a href="' . $_SERVER['PHP_SELF'] . '?action=setdisabledirectinput&value=1">';
print img_picto($langs->trans("Disabled"), 'switch_off');
print '</a></td>';
}
print '</tr>';
$var = ! $var;
print "<tr " . $bc[$var] . ">";
print '<td>' . $langs->trans("BANK_DISABLE_DIRECT_INPUT") . '</td>';
if (! empty($conf->global->BANK_DISABLE_DIRECT_INPUT)) {
print '<td align="right"><a href="' . $_SERVER['PHP_SELF'] . '?action=setdisabledirectinput&value=0">';
print img_picto($langs->trans("Activated"), 'switch_on');
print '</a></td>';
} else {
print '<td align="right"><a href="' . $_SERVER['PHP_SELF'] . '?action=setdisabledirectinput&value=1">';
print img_picto($langs->trans("Disabled"), 'switch_off');
print '</a></td>';
}
print '</tr>';

$var = ! $var;
print "<tr " . $bc[$var] . ">";
print '<td>' . $langs->trans("ACCOUNTING_MANAGE_ZERO") . '</td>';
Expand Down
13 changes: 7 additions & 6 deletions htdocs/accountancy/class/accountingaccount.class.php
Expand Up @@ -369,22 +369,23 @@ function delete($user, $notrigger = 0) {
*/
function getNomUrl($withpicto = 0) {
global $langs;

$result = '';

$link = '<a href="' . DOL_URL_ROOT . '/accountancy/admin/card.php?id=' . $this->id . '">';
$linkend = '</a>';

$picto = 'billr';

$label = $langs->trans("Show") . ': ' . $this->account_number . ' - ' . $this->label;

if ($withpicto)
$result .= ($link . img_object($label, $picto) . $linkend);
if ($withpicto && $withpicto != 2)
$result .= ' ';
if ($withpicto != 2)
$result .= $link . $this->account_number . $linkend;
require_once DOL_DOCUMENT_ROOT.'/core/lib/accounting.lib.php';
$result .= $link . length_accountg($this->account_number) . ' - ' . $this->label . $linkend;
return $result;
}

Expand Down
224 changes: 0 additions & 224 deletions htdocs/comm/propal/apercu.php

This file was deleted.

37 changes: 1 addition & 36 deletions htdocs/comm/propal/card.php
Expand Up @@ -1804,42 +1804,7 @@

print '<table class="border" width="100%">';

// Ref
/*
print '<tr><td>' . $langs->trans('Ref') . '</td><td colspan="5">';
print $form->showrefnav($object, 'ref', $linkback, 1, 'ref', 'ref', '');
print '</td></tr>';
*/

// Ref customer
/*
print '<tr><td>';
print '<table class="nobordernopadding" width="100%"><tr><td class="nowrap">';
print $langs->trans('RefCustomer') . '</td>';
if ($action != 'refclient' && ! empty($object->brouillon))
print '<td align="right"><a href="' . $_SERVER['PHP_SELF'] . '?action=refclient&amp;id=' . $object->id . '">' . img_edit($langs->trans('Modify')) . '</a></td>';
print '</td></tr></table>';
print '</td><td colspan="5">';
if ($user->rights->propal->creer && $action == 'refclient') {
print '<form action="'.$_SERVER["PHP_SELF"].'?id=' . $object->id . '" method="post">';
print '<input type="hidden" name="token" value="' . $_SESSION ['newtoken'] . '">';
print '<input type="hidden" name="action" value="set_ref_client">';
print '<input type="text" class="flat" size="20" name="ref_client" value="' . $object->ref_client . '">';
print ' <input type="submit" class="button" value="' . $langs->trans('Modify') . '">';
print '</form>';
} else {
print $object->ref_client;
}
print '</td>';
print '</tr>';
*/

// Company
/*
print '<tr><td>' . $langs->trans('Company') . '</td><td colspan="5">' . $soc->getNomUrl(1) . '</td>';
print '</tr>';*/

// Lin for thirdparty discounts
// Link for thirdparty discounts
print '<tr><td class="titlefield">' . $langs->trans('Discounts') . '</td><td>';
if ($soc->remise_percent)
print $langs->trans("CompanyHasRelativeDiscount", $soc->remise_percent);
Expand Down

0 comments on commit 292bcae

Please sign in to comment.