Informes base -> en la generación de los sumarios se aplica el formato que tenga la columna de ese sumario (en vez de comprobar los tipos)
git-svn-id: https://192.168.0.254/svn/Proyectos.LuisLeon_FactuGES/trunk@304 c93665c3-c93d-084d-9b98-7d5f4a9c3376
This commit is contained in:
parent
d1cc146bae
commit
ab106540f3
@ -88,6 +88,7 @@ inherited frViewSumarios: TfrViewSumarios
|
|||||||
object cxStyleRepository1: TcxStyleRepository
|
object cxStyleRepository1: TcxStyleRepository
|
||||||
Left = 216
|
Left = 216
|
||||||
Top = 104
|
Top = 104
|
||||||
|
PixelsPerInch = 96
|
||||||
object cxStyleNombreColumna: TcxStyle
|
object cxStyleNombreColumna: TcxStyle
|
||||||
AssignedValues = [svColor, svTextColor]
|
AssignedValues = [svColor, svTextColor]
|
||||||
Color = clWindow
|
Color = clWindow
|
||||||
|
|||||||
@ -104,27 +104,25 @@ end;
|
|||||||
procedure TfrViewSumarios.AplicarSumarioVista (
|
procedure TfrViewSumarios.AplicarSumarioVista (
|
||||||
const APosition: TcxSummaryPosition; const AColumnCaption: String;
|
const APosition: TcxSummaryPosition; const AColumnCaption: String;
|
||||||
const AKind: TcxSummaryKind);
|
const AKind: TcxSummaryKind);
|
||||||
const
|
|
||||||
MASK_MONEDA = ',0.## €;-,0.## €';
|
|
||||||
MASK_NUMERO = '#,##0';
|
|
||||||
var
|
var
|
||||||
AColumn : TcxGridDBColumn;
|
AColumn : TcxGridDBColumn;
|
||||||
|
ADisplayFormat : string;
|
||||||
begin
|
begin
|
||||||
AColumn := ViewInformeBaseGrid.GetColumnByCaption(AColumnCaption);
|
AColumn := ViewInformeBaseGrid.GetColumnByCaption(AColumnCaption);
|
||||||
|
|
||||||
|
if (AColumn.Properties is TcxCustomTextEditProperties) then
|
||||||
|
ADisplayFormat := TcxCustomTextEditProperties(AColumn.Properties).DisplayFormat
|
||||||
|
else
|
||||||
|
ADisplayFormat := '';
|
||||||
|
|
||||||
if APosition = spFooter then
|
if APosition = spFooter then
|
||||||
begin
|
begin
|
||||||
AColumn.Summary.FooterKind := AKind;
|
AColumn.Summary.FooterKind := AKind;
|
||||||
if (AKind in [skSum, skAverage]) and (AColumn.PropertiesClassName = 'TcxCurrencyEditProperties') then
|
//AColumn.Summary.FooterFormat := ADisplayFormat;
|
||||||
AColumn.Summary.FooterFormat := MASK_MONEDA
|
|
||||||
else
|
|
||||||
AColumn.Summary.FooterFormat := MASK_NUMERO;
|
|
||||||
end
|
end
|
||||||
else begin
|
else begin
|
||||||
AColumn.Summary.GroupFooterKind := AKind;
|
AColumn.Summary.GroupFooterKind := AKind;
|
||||||
if (AKind in [skSum, skAverage]) and (AColumn.PropertiesClassName = 'TcxCurrencyEditProperties') then
|
// AColumn.Summary.GroupFooterFormat := ADisplayFormat;
|
||||||
AColumn.Summary.GroupFooterFormat := MASK_MONEDA
|
|
||||||
else
|
|
||||||
AColumn.Summary.GroupFooterFormat := MASK_NUMERO;
|
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user