FIX #16431
This commit is contained in:
commit
e7da1d7fe4
@ -553,7 +553,7 @@ class AccountancyExport
|
|||||||
}*/
|
}*/
|
||||||
$Tab['sens'] = $data->sens; // C or D
|
$Tab['sens'] = $data->sens; // C or D
|
||||||
$Tab['signe_montant'] = '+';
|
$Tab['signe_montant'] = '+';
|
||||||
|
|
||||||
// The amount must be in centimes without decimal points.
|
// The amount must be in centimes without decimal points.
|
||||||
$Tab['montant'] = str_pad(abs(($data->debit - $abs->credit) * 100), 12, '0', STR_PAD_LEFT);
|
$Tab['montant'] = str_pad(abs(($data->debit - $abs->credit) * 100), 12, '0', STR_PAD_LEFT);
|
||||||
$Tab['contrepartie'] = str_repeat(' ', 8);
|
$Tab['contrepartie'] = str_repeat(' ', 8);
|
||||||
@ -646,7 +646,7 @@ class AccountancyExport
|
|||||||
} else {
|
} else {
|
||||||
$Tab['montant_debit'] = str_pad(number_format(0, 2, ',', ''), 13, ' ', STR_PAD_LEFT);
|
$Tab['montant_debit'] = str_pad(number_format(0, 2, ',', ''), 13, ' ', STR_PAD_LEFT);
|
||||||
|
|
||||||
$Tab['montant_crebit'] = str_pad(number_format($data->credit), 2, ',', ''), 13, ' ', STR_PAD_LEFT);
|
$Tab['montant_crebit'] = str_pad(number_format($data->credit, 2, ',', ''), 13, ' ', STR_PAD_LEFT);
|
||||||
}
|
}
|
||||||
|
|
||||||
$Tab['libelle_ecriture'] = str_pad(self::trunc(dol_string_unaccent($data->doc_ref).' '.dol_string_unaccent($data->label_operation), 30), 30);
|
$Tab['libelle_ecriture'] = str_pad(self::trunc(dol_string_unaccent($data->doc_ref).' '.dol_string_unaccent($data->label_operation), 30), 30);
|
||||||
|
|||||||
@ -530,6 +530,7 @@ function hideMessage(fieldId,message) {
|
|||||||
* @param string token Token
|
* @param string token Token
|
||||||
*/
|
*/
|
||||||
function setConstant(url, code, input, entity, strict, forcereload, userid, token) {
|
function setConstant(url, code, input, entity, strict, forcereload, userid, token) {
|
||||||
|
var saved_url = url; /* avoid undefined url */
|
||||||
$.post( url, {
|
$.post( url, {
|
||||||
action: "set",
|
action: "set",
|
||||||
name: code,
|
name: code,
|
||||||
@ -574,7 +575,7 @@ function setConstant(url, code, input, entity, strict, forcereload, userid, toke
|
|||||||
$.each(data, function(key, value) {
|
$.each(data, function(key, value) {
|
||||||
$("#set_" + key).hide();
|
$("#set_" + key).hide();
|
||||||
$("#del_" + key).show();
|
$("#del_" + key).show();
|
||||||
$.post( url, {
|
$.post( saved_url, {
|
||||||
action: "set",
|
action: "set",
|
||||||
name: key,
|
name: key,
|
||||||
value: value,
|
value: value,
|
||||||
@ -604,6 +605,7 @@ function setConstant(url, code, input, entity, strict, forcereload, userid, toke
|
|||||||
* @param string token Token
|
* @param string token Token
|
||||||
*/
|
*/
|
||||||
function delConstant(url, code, input, entity, strict, forcereload, userid, token) {
|
function delConstant(url, code, input, entity, strict, forcereload, userid, token) {
|
||||||
|
var saved_url = url; /* avoid undefined url */
|
||||||
$.post( url, {
|
$.post( url, {
|
||||||
action: "del",
|
action: "del",
|
||||||
name: code,
|
name: code,
|
||||||
@ -645,7 +647,7 @@ function delConstant(url, code, input, entity, strict, forcereload, userid, toke
|
|||||||
$.each(data, function(key, value) {
|
$.each(data, function(key, value) {
|
||||||
$("#del_" + value).hide();
|
$("#del_" + value).hide();
|
||||||
$("#set_" + value).show();
|
$("#set_" + value).show();
|
||||||
$.post( url, {
|
$.post( saved_url, {
|
||||||
action: "del",
|
action: "del",
|
||||||
name: value,
|
name: value,
|
||||||
entity: entity,
|
entity: entity,
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user