VLKC#54124 Float default naar 2 indien data_scale niet in DB aanwezig, SUM(currency) en AVG(currency) moeten currency blijven
svn path=/Website/branches/v2018.1/; revision=38632
This commit is contained in:
@@ -427,7 +427,7 @@ function report_GET(params)
|
||||
field.sql = "SUM(" + field_expression + ")";
|
||||
if (!field.fixedlabel)
|
||||
field.label = L("lcl_usrrap_label_SUM").format(field.label);
|
||||
field.newtyp = "float";
|
||||
field.newtyp = field.typ == "currency" ? "currency" : "float";
|
||||
field.total = true;
|
||||
break;
|
||||
case "C":
|
||||
@@ -442,7 +442,7 @@ function report_GET(params)
|
||||
if (!field.fixedlabel)
|
||||
field.label = L("lcl_usrrap_label_AVG").format(field.label);
|
||||
field.total = false;
|
||||
field.newtyp = "float";
|
||||
field.newtyp = field.typ == "currency" ? "currency" : "float";
|
||||
break;
|
||||
case "H":
|
||||
if (field.typ == "date" || field.typ == "datetime")
|
||||
|
||||
@@ -431,7 +431,10 @@ function scaffolding_list(model, scf_params)
|
||||
if (field.iscurrency)
|
||||
field.decimals = 2;
|
||||
else
|
||||
field.decimals = fnfndbcol(model.table, field.dbs).decimals || 2; // Float default naar 2
|
||||
{
|
||||
field.decimals = fnfndbcol(model.table, field.dbs).decimals;
|
||||
if (field.decimals === null) field.decimals = 2; // Float default naar 2
|
||||
}
|
||||
|
||||
var coldata = { caption: field.orglabel? field.orglabel: field.label,
|
||||
content: fld,
|
||||
|
||||
Reference in New Issue
Block a user