diff --git a/Build/Build.fbl6 b/Build/Build.fbl6
index 24cad7e..8bcf121 100644
Binary files a/Build/Build.fbl6 and b/Build/Build.fbl6 differ
diff --git a/Source/Cliente/FactuGES.dproj b/Source/Cliente/FactuGES.dproj
index 6b391ad..ebc9cf9 100644
--- a/Source/Cliente/FactuGES.dproj
+++ b/Source/Cliente/FactuGES.dproj
@@ -51,7 +51,7 @@
Delphi.Personality
VCLApplication
-FalseTrueFalseC:\Archivos de programa\Borland\Delphi7\Bin\TrueFalse2650FalseFalseFalseFalseFalse30821252Rodax Software S.L.2.6.5.0FactuGESFactuGES2.6.5.0
+FalseTrueFalseC:\Archivos de programa\Borland\Delphi7\Bin\TrueFalse2660FalseFalseFalseFalseFalse30821252Rodax Software S.L.2.6.6.0FactuGESFactuGES2.6.6.0
File C:\Documents and Settings\All Users\Documentos\RAD Studio\5.0\Bpl\dxPScxScheduler2LnkD11.bpl not found
FactuGES.dprFalse
diff --git a/Source/Cliente/FactuGES.res b/Source/Cliente/FactuGES.res
index 145d538..3fef9d6 100644
Binary files a/Source/Cliente/FactuGES.res and b/Source/Cliente/FactuGES.res differ
diff --git a/Source/GUIBase/uViewTotales.dfm b/Source/GUIBase/uViewTotales.dfm
index 77404d1..70c0867 100644
--- a/Source/GUIBase/uViewTotales.dfm
+++ b/Source/GUIBase/uViewTotales.dfm
@@ -1,15 +1,15 @@
inherited frViewTotales: TfrViewTotales
- Width = 451
- Height = 404
+ Width = 1029
+ Height = 310
Align = alBottom
- ExplicitWidth = 451
- ExplicitHeight = 404
+ ExplicitWidth = 1029
+ ExplicitHeight = 310
object dxLayoutControl1: TdxLayoutControl
AlignWithMargins = True
Left = 0
Top = 0
- Width = 451
- Height = 233
+ Width = 1029
+ Height = 273
Margins.Left = 0
Margins.Top = 0
Margins.Right = 0
@@ -19,23 +19,37 @@ inherited frViewTotales: TfrViewTotales
TabOrder = 0
TabStop = False
AutoContentSizes = [acsWidth, acsHeight]
- ExplicitWidth = 860
+ ExplicitWidth = 451
object Bevel3: TBevel
- Left = 278
+ Left = 481
Top = 28
Width = 3
Height = 122
Shape = bsRightLine
end
object Bevel4: TBevel
- Left = 390
+ Left = 593
Top = 70
Width = 210
Height = 9
Shape = bsBottomLine
end
+ object Bevel2: TBevel
+ Left = 22
+ Top = 213
+ Width = 333
+ Height = 9
+ Shape = bsBottomLine
+ end
+ object Bevel1: TBevel
+ Left = 500
+ Top = 213
+ Width = 332
+ Height = 9
+ Shape = bsBottomLine
+ end
object ImporteDto: TcxDBCurrencyEdit
- Left = 175
+ Left = 202
Top = 55
AutoSize = False
DataBinding.DataField = 'IMPORTE_DESCUENTO'
@@ -66,7 +80,7 @@ inherited frViewTotales: TfrViewTotales
Width = 93
end
object ImporteIVA: TcxDBCurrencyEdit
- Left = 461
+ Left = 664
Top = 105
AutoSize = False
DataBinding.DataField = 'IMPORTE_IVA'
@@ -92,12 +106,12 @@ inherited frViewTotales: TfrViewTotales
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 9
+ TabOrder = 10
Height = 21
Width = 137
end
object ImporteTotal: TcxDBCurrencyEdit
- Left = 391
+ Left = 594
Top = 186
AutoSize = False
DataBinding.DataField = 'IMPORTE_TOTAL'
@@ -124,12 +138,12 @@ inherited frViewTotales: TfrViewTotales
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 14
+ TabOrder = 15
Height = 21
Width = 137
end
object edtDescuento: TcxDBSpinEdit
- Left = 104
+ Left = 131
Top = 55
AutoSize = False
DataBinding.DataField = 'DESCUENTO'
@@ -159,7 +173,7 @@ inherited frViewTotales: TfrViewTotales
Width = 65
end
object edtIVA: TcxDBSpinEdit
- Left = 390
+ Left = 593
Top = 105
AutoSize = False
DataBinding.DataField = 'IVA'
@@ -191,12 +205,12 @@ inherited frViewTotales: TfrViewTotales
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 8
+ TabOrder = 9
Height = 21
Width = 65
end
object ImporteBase: TcxDBCurrencyEdit
- Left = 390
+ Left = 593
Top = 28
AutoSize = False
DataBinding.DataField = 'BASE_IMPONIBLE'
@@ -221,12 +235,12 @@ inherited frViewTotales: TfrViewTotales
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 7
+ TabOrder = 8
Height = 21
Width = 92
end
object edtRE: TcxDBSpinEdit
- Left = 390
+ Left = 593
Top = 159
AutoSize = False
DataBinding.DataField = 'RE'
@@ -258,12 +272,12 @@ inherited frViewTotales: TfrViewTotales
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 12
+ TabOrder = 13
Height = 21
Width = 65
end
object edtIRPF: TcxDBSpinEdit
- Left = 390
+ Left = 593
Top = 132
AutoSize = False
DataBinding.DataSource = DADataSource
@@ -294,12 +308,12 @@ inherited frViewTotales: TfrViewTotales
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 10
+ TabOrder = 11
Height = 21
Width = 65
end
object ImporteRE: TcxDBCurrencyEdit
- Left = 461
+ Left = 664
Top = 159
AutoSize = False
DataBinding.DataField = 'IMPORTE_RE'
@@ -325,12 +339,12 @@ inherited frViewTotales: TfrViewTotales
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 13
+ TabOrder = 14
Height = 21
Width = 56
end
object ImporteIRPF: TcxDBCurrencyEdit
- Left = 461
+ Left = 664
Top = 132
AutoSize = False
DataBinding.DataSource = DADataSource
@@ -355,12 +369,12 @@ inherited frViewTotales: TfrViewTotales
StyleDisabled.TextColor = clWindowText
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 11
+ TabOrder = 12
Height = 21
Width = 56
end
object eImporteNeto: TcxDBCurrencyEdit
- Left = 104
+ Left = 131
Top = 28
AutoSize = False
DataBinding.DataField = 'IMPORTE_NETO'
@@ -391,7 +405,7 @@ inherited frViewTotales: TfrViewTotales
Width = 147
end
object ePorte: TcxDBCurrencyEdit
- Left = 104
+ Left = 131
Top = 82
AutoSize = False
DataBinding.DataField = 'IMPORTE_PORTE'
@@ -421,7 +435,7 @@ inherited frViewTotales: TfrViewTotales
Width = 147
end
object eIVA: TcxDBLookupComboBox
- Left = 104
+ Left = 131
Top = 109
DataBinding.DataField = 'ID_TIPO_IVA'
DataBinding.DataSource = DADataSource
@@ -453,7 +467,7 @@ inherited frViewTotales: TfrViewTotales
Width = 81
end
object bTiposIVA: TButton
- Left = 130
+ Left = 333
Top = 109
Width = 132
Height = 21
@@ -461,7 +475,7 @@ inherited frViewTotales: TfrViewTotales
TabOrder = 5
end
object cbRecargoEquivalencia: TcxDBCheckBox
- Left = 104
+ Left = 131
Top = 136
Caption = 'Aplicar recargo de equivalencia'
DataBinding.DataField = 'RECARGO_EQUIVALENCIA'
@@ -486,6 +500,95 @@ inherited frViewTotales: TfrViewTotales
TabOrder = 6
Width = 219
end
+ object edtRetencion: TcxDBSpinEdit
+ Left = 593
+ Top = 228
+ AutoSize = False
+ DataBinding.DataSource = DADataSource
+ ParentFont = False
+ Properties.Alignment.Horz = taRightJustify
+ Properties.AssignedValues.EditFormat = True
+ Properties.DisplayFormat = ',0.00 %;-,0.00 %'
+ Properties.ImmediatePost = True
+ Properties.MaxValue = 100.000000000000000000
+ Style.BorderColor = clWindowFrame
+ Style.BorderStyle = ebs3D
+ Style.Font.Charset = DEFAULT_CHARSET
+ Style.Font.Color = clWindowText
+ Style.Font.Height = -11
+ Style.Font.Name = 'Tahoma'
+ Style.Font.Style = []
+ Style.HotTrack = False
+ Style.LookAndFeel.Kind = lfStandard
+ Style.LookAndFeel.NativeStyle = True
+ Style.TextColor = clWindowText
+ Style.ButtonStyle = bts3D
+ Style.IsFontAssigned = True
+ StyleDisabled.LookAndFeel.Kind = lfStandard
+ StyleDisabled.LookAndFeel.NativeStyle = True
+ StyleDisabled.TextColor = clWindowText
+ StyleFocused.LookAndFeel.Kind = lfStandard
+ StyleFocused.LookAndFeel.NativeStyle = True
+ StyleHot.LookAndFeel.Kind = lfStandard
+ StyleHot.LookAndFeel.NativeStyle = True
+ TabOrder = 16
+ Height = 21
+ Width = 65
+ end
+ object edtImporteRetencion: TcxDBCurrencyEdit
+ Left = 664
+ Top = 228
+ AutoSize = False
+ DataBinding.DataSource = DADataSource
+ Enabled = False
+ ParentFont = False
+ Properties.Alignment.Horz = taRightJustify
+ Properties.ReadOnly = True
+ Properties.UseLeftAlignmentOnEditing = False
+ Properties.UseThousandSeparator = True
+ Style.BorderColor = clWindowFrame
+ Style.BorderStyle = ebs3D
+ Style.Font.Charset = DEFAULT_CHARSET
+ Style.Font.Color = clWindowText
+ Style.Font.Height = -11
+ Style.Font.Name = 'Tahoma'
+ Style.Font.Style = []
+ Style.HotTrack = False
+ Style.LookAndFeel.NativeStyle = True
+ Style.TextColor = clWindowText
+ Style.IsFontAssigned = True
+ StyleDisabled.LookAndFeel.NativeStyle = True
+ StyleDisabled.TextColor = clWindowText
+ StyleFocused.LookAndFeel.NativeStyle = True
+ StyleHot.LookAndFeel.NativeStyle = True
+ TabOrder = 17
+ Height = 21
+ Width = 342
+ end
+ object edtFechaRetencion: TcxDBDateEdit
+ Left = 131
+ Top = 228
+ DataBinding.DataSource = DADataSource
+ Style.BorderColor = clWindowFrame
+ Style.BorderStyle = ebs3D
+ Style.HotTrack = False
+ Style.LookAndFeel.Kind = lfStandard
+ Style.LookAndFeel.NativeStyle = True
+ Style.LookAndFeel.SkinName = ''
+ Style.ButtonStyle = bts3D
+ Style.PopupBorderStyle = epbsFrame3D
+ StyleDisabled.LookAndFeel.Kind = lfStandard
+ StyleDisabled.LookAndFeel.NativeStyle = True
+ StyleDisabled.LookAndFeel.SkinName = ''
+ StyleFocused.LookAndFeel.Kind = lfStandard
+ StyleFocused.LookAndFeel.NativeStyle = True
+ StyleFocused.LookAndFeel.SkinName = ''
+ StyleHot.LookAndFeel.Kind = lfStandard
+ StyleHot.LookAndFeel.NativeStyle = True
+ StyleHot.LookAndFeel.SkinName = ''
+ TabOrder = 7
+ Width = 333
+ end
object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False
Hidden = True
@@ -563,6 +666,21 @@ inherited frViewTotales: TfrViewTotales
Control = cbRecargoEquivalencia
ControlOptions.ShowBorder = False
end
+ object dxLayoutControl1Item19: TdxLayoutItem
+ AutoAligns = [aaHorizontal]
+ AlignVert = avBottom
+ Visible = False
+ Control = Bevel2
+ ControlOptions.ShowBorder = False
+ end
+ object dxLayoutControl1Item18: TdxLayoutItem
+ AutoAligns = [aaHorizontal]
+ AlignVert = avBottom
+ Caption = 'Fecha vto. retenci'#243'n:'
+ Visible = False
+ Control = edtFechaRetencion
+ ControlOptions.ShowBorder = False
+ end
end
object dxLayoutControl1Group5: TdxLayoutGroup
AutoAligns = [aaVertical]
@@ -680,6 +798,30 @@ inherited frViewTotales: TfrViewTotales
Control = ImporteTotal
ControlOptions.ShowBorder = False
end
+ object dxLayoutControl1Item20: TdxLayoutItem
+ Visible = False
+ Control = Bevel1
+ ControlOptions.ShowBorder = False
+ end
+ object dxLayoutControl1Group12: TdxLayoutGroup
+ ShowCaption = False
+ Visible = False
+ Hidden = True
+ LayoutDirection = ldHorizontal
+ ShowBorder = False
+ object dxLayoutControl1Item10: TdxLayoutItem
+ Caption = 'Retenci'#243'n (%):'
+ CaptionOptions.AlignHorz = taRightJustify
+ Control = edtRetencion
+ ControlOptions.ShowBorder = False
+ end
+ object dxLayoutControl1Item17: TdxLayoutItem
+ AutoAligns = [aaVertical]
+ AlignHorz = ahClient
+ Control = edtImporteRetencion
+ ControlOptions.ShowBorder = False
+ end
+ end
end
end
end
diff --git a/Source/GUIBase/uViewTotales.pas b/Source/GUIBase/uViewTotales.pas
index e38b9b3..4954f69 100644
--- a/Source/GUIBase/uViewTotales.pas
+++ b/Source/GUIBase/uViewTotales.pas
@@ -8,7 +8,7 @@ uses
cxTextEdit, cxMaskEdit, cxDropDownEdit, cxDBEdit, cxControls,
cxContainer, cxEdit, cxLabel, cxDBLabel, cxCurrencyEdit, cxSpinEdit,
ComCtrls, dxLayoutControl, dxLayoutLookAndFeels, cxLookupEdit, cxDBLookupEdit,
- cxDBLookupComboBox, cxCheckBox, uDAInterfaces;
+ cxDBLookupComboBox, cxCheckBox, uDAInterfaces, cxCalendar;
type
TfrViewTotales = class(TfrViewBase)
@@ -64,6 +64,17 @@ type
dxLayoutControl1Group10: TdxLayoutGroup;
dxLayoutControl1Group11: TdxLayoutGroup;
dxLayoutControl1Group1191: TdxLayoutGroup;
+ dxLayoutControl1Item10: TdxLayoutItem;
+ edtRetencion: TcxDBSpinEdit;
+ dxLayoutControl1Item17: TdxLayoutItem;
+ edtImporteRetencion: TcxDBCurrencyEdit;
+ dxLayoutControl1Group12: TdxLayoutGroup;
+ dxLayoutControl1Item18: TdxLayoutItem;
+ edtFechaRetencion: TcxDBDateEdit;
+ dxLayoutControl1Item19: TdxLayoutItem;
+ Bevel2: TBevel;
+ dxLayoutControl1Item20: TdxLayoutItem;
+ Bevel1: TBevel;
public
{ Public declarations }
end;
diff --git a/Source/Informes/1/InfFacturaCliente.fr3 b/Source/Informes/1/InfFacturaCliente.fr3
index f27b754..1b42fe0 100644
--- a/Source/Informes/1/InfFacturaCliente.fr3
+++ b/Source/Informes/1/InfFacturaCliente.fr3
@@ -1,5 +1,5 @@
-
+
@@ -24,36 +24,40 @@
-
-
+
+
-
+
-
+
-
+
-
+
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -62,7 +66,7 @@
-
+
diff --git a/Source/Informes/2/InfFacturaCliente.fr3 b/Source/Informes/2/InfFacturaCliente.fr3
index 43891f6..86546a5 100644
--- a/Source/Informes/2/InfFacturaCliente.fr3
+++ b/Source/Informes/2/InfFacturaCliente.fr3
@@ -1,5 +1,5 @@
-
+
@@ -22,39 +22,43 @@
-
+
-
+
-
+
-
+
-
+
-
-
+
+
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -63,7 +67,7 @@
-
+
diff --git a/Source/Informes/3/InfFacturaCliente.fr3 b/Source/Informes/3/InfFacturaCliente.fr3
index 9c93417..9414df6 100644
--- a/Source/Informes/3/InfFacturaCliente.fr3
+++ b/Source/Informes/3/InfFacturaCliente.fr3
@@ -1,5 +1,5 @@
-
+
@@ -25,39 +25,43 @@
-
+
-
+
-
+
-
+
-
-
+
+
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -66,7 +70,7 @@
-
+
diff --git a/Source/Informes/4/InfFacturaCliente.fr3 b/Source/Informes/4/InfFacturaCliente.fr3
index 7ac2ea6..c13d4e1 100644
--- a/Source/Informes/4/InfFacturaCliente.fr3
+++ b/Source/Informes/4/InfFacturaCliente.fr3
@@ -1,5 +1,5 @@
-
+
@@ -21,39 +21,43 @@
-
+
-
+
-
+
-
+
-
-
+
+
-
+
-
+
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -62,7 +66,7 @@
-
+
diff --git a/Source/Informes/InformeListadoFacturasClientePendientes.fr3 b/Source/Informes/InformeListadoFacturasClientePendientes.fr3
index 10f95ba..55becb6 100644
--- a/Source/Informes/InformeListadoFacturasClientePendientes.fr3
+++ b/Source/Informes/InformeListadoFacturasClientePendientes.fr3
@@ -1,5 +1,5 @@
-
+
@@ -15,17 +15,19 @@
-
+
-
+
+
-
-
-
-
-
-
+
+
+
+
+
+
+
diff --git a/Source/Informes/InformeListadoFacturasClientePendientesDesglosado.fr3 b/Source/Informes/InformeListadoFacturasClientePendientesDesglosado.fr3
index f01667d..eb82be6 100644
--- a/Source/Informes/InformeListadoFacturasClientePendientesDesglosado.fr3
+++ b/Source/Informes/InformeListadoFacturasClientePendientesDesglosado.fr3
@@ -1,5 +1,5 @@
-
+
@@ -15,17 +15,19 @@
-
+
-
+
+
-
-
-
-
-
+
+
+
+
+
+
diff --git a/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas b/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas
index d7481d9..66913d9 100644
--- a/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas
+++ b/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas
@@ -694,6 +694,12 @@ begin
if (EsFechaVacia(AFactura.FECHA_FACTURA)) then
raise Exception.Create('Debe indicar la fecha de esta factura');
+ //En el caso de asignar una retención a la factura será obligatorio meter la fecha de retención.
+ if (AFactura.IMPORTE_RETENCION > 0) then
+ if (EsFechaVacia(AFactura.FECHA_RETENCION)) then
+ raise Exception.Create('Debe indicar la fecha de vencimiento de la retención, para poder asociarla al recibo que contendrá el importe de la retención.');
+
+
if (AFactura.Detalles.DataTable.RecordCount = 0) then
raise Exception.Create('La factura debe tener al menos un concepto en su contenido');
@@ -1285,6 +1291,7 @@ var
ADiasMas: Integer;
BSemaforo: Boolean;
AImporteAcumulado : Double;
+ AImporteTotal: Double;
begin
if not Assigned(AFactura) then
@@ -1301,6 +1308,11 @@ begin
ARecibos := ARecibosClienteController.BuscarRecibosFactura(AFactura.ID);
ARecibosClienteController.EliminarTodo(ARecibos);
+ //Si hay retención, se generará un recibo por ese importe, y el resto se generarán recibos
+ //según forma de pago
+ AImporteTotal := AFactura.IMPORTE_TOTAL - AFactura.IMPORTE_RETENCION;
+
+
//Se cambia la lógica a peticion de acana, en el caso de meter una fecha de vencimiento,
//los plazos de la forma de pago no tendrán efecto, se generará un recibo con el 100% y fecha de vencimiento
//de la factura. (Se permitirá para acana poder dar de alta facturas sin recibos asociados)
@@ -1332,7 +1344,7 @@ begin
if AFormaPago.Plazos.RecordCount < 1 then
begin
ARecibos.FECHA_VENCIMIENTO := AFactura.FECHA_VENCIMIENTO;
- ARecibos.IMPORTE := AFactura.IMPORTE_TOTAL;
+ ARecibos.IMPORTE := AImporteTotal;
AImporteAcumulado := AImporteAcumulado + ARecibos.IMPORTE;
end
else
@@ -1375,15 +1387,15 @@ begin
ARecibos.FECHA_VENCIMIENTO := AFechaVencimiento;
- ARecibos.IMPORTE := RoundCurrency(RoundCurrency(AFactura.IMPORTE_TOTAL) * (AFormaPago.Plazos.PORCENTAJE / 100));
+ ARecibos.IMPORTE := RoundCurrency(RoundCurrency(AImporteTotal) * (AFormaPago.Plazos.PORCENTAJE / 100));
AImporteAcumulado := AImporteAcumulado + ARecibos.IMPORTE;
if (i = AFormaPago.Plazos.RecordCount) then
begin
- if (AImporteAcumulado < RoundCurrency(AFactura.IMPORTE_TOTAL)) then
- ARecibos.IMPORTE := ARecibos.IMPORTE + (RoundCurrency(AFactura.IMPORTE_TOTAL) - AImporteAcumulado)
- else if (AImporteAcumulado > RoundCurrency(AFactura.IMPORTE_TOTAL)) then
- ARecibos.IMPORTE := ARecibos.IMPORTE - (AImporteAcumulado - RoundCurrency(AFactura.IMPORTE_TOTAL));
+ if (AImporteAcumulado < RoundCurrency(AImporteTotal)) then
+ ARecibos.IMPORTE := ARecibos.IMPORTE + (RoundCurrency(AImporteTotal) - AImporteAcumulado)
+ else if (AImporteAcumulado > RoundCurrency(AImporteTotal)) then
+ ARecibos.IMPORTE := ARecibos.IMPORTE - (AImporteAcumulado - RoundCurrency(AImporteTotal));
end;
end;
@@ -1397,6 +1409,20 @@ begin
until (eof);
end;
+ //Si hay retención generaremos un recibo para dicha retención
+ if AFactura.IMPORTE_RETENCION > 0 then
+ begin
+ ARecibos := ARecibosClienteController.Nuevo;
+ ARecibos.Edit;
+ ARecibos.ID_FACTURA := AFactura.ID;
+ ARecibos.REFERENCIA := AFactura.REFERENCIA + ' - ' + IntToStr(i);
+ ARecibos.FECHA_EMISION := AFactura.FECHA_FACTURA;
+ ARecibos.FECHA_VENCIMIENTO := AFactura.FECHA_RETENCION;
+ ARecibos.IMPORTE := AFactura.IMPORTE_RETENCION;
+ ARecibos.DESCRIPCION := 'Pago de factura de retención ' + AFactura.REFERENCIA + ': son ' + CifraToLetras(ARecibos.IMPORTE);
+ ARecibosClienteController.Guardar(ARecibos);
+ end;
+
//Liberamos
AFormasPagoController := Nil;
AFormaPago := Nil;
diff --git a/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm b/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm
index 52bcbc4..3adf71d 100644
--- a/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm
+++ b/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm
@@ -346,6 +346,18 @@ inherited DataModuleFacturasCliente: TDataModuleFacturasCliente
DataType = datSmallInt
DisplayLabel = 'FacturasCliente_SIN_COMISION'
DictionaryEntry = 'FacturasCliente_SIN_COMISION'
+ end
+ item
+ Name = 'RETENCION'
+ DataType = datFloat
+ end
+ item
+ Name = 'IMPORTE_RETENCION'
+ DataType = datCurrency
+ end
+ item
+ Name = 'FECHA_RETENCION'
+ DataType = datDateTime
end>
Params = <>
StreamingOptions = [soDisableEventsWhileStreaming]
diff --git a/Source/Modulos/Facturas de cliente/FacturasCliente_Group.groupproj b/Source/Modulos/Facturas de cliente/FacturasCliente_Group.groupproj
index 06da0cc..983c9de 100644
--- a/Source/Modulos/Facturas de cliente/FacturasCliente_Group.groupproj
+++ b/Source/Modulos/Facturas de cliente/FacturasCliente_Group.groupproj
@@ -201,6 +201,15 @@
+
+
+
+
+
+
+
+
+
@@ -255,15 +264,6 @@
-
-
-
-
-
-
-
-
-
@@ -292,13 +292,13 @@
-
+
-
+
-
+
\ No newline at end of file
diff --git a/Source/Modulos/Facturas de cliente/Model/schFacturasClienteClient_Intf.pas b/Source/Modulos/Facturas de cliente/Model/schFacturasClienteClient_Intf.pas
index 4e7d23a..1b39e66 100644
--- a/Source/Modulos/Facturas de cliente/Model/schFacturasClienteClient_Intf.pas
+++ b/Source/Modulos/Facturas de cliente/Model/schFacturasClienteClient_Intf.pas
@@ -9,9 +9,9 @@ const
{ Data table rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
- RID_ListaAnosFacturas = '{C9E93D4F-3A5E-4C8E-8305-B2AAB8E41C83}';
- RID_FacturasCliente = '{240D687B-A424-48A6-87C4-B55E1910A62F}';
- RID_FacturasCliente_Detalles = '{103A3F35-8D1F-4517-AFFF-023722C59B2A}';
+ RID_ListaAnosFacturas = '{7D65E46A-1501-412C-A702-00A1827BA01E}';
+ RID_FacturasCliente = '{7CBEA816-E87B-47DF-AF37-8A26F50A8F89}';
+ RID_FacturasCliente_Detalles = '{01274CC5-0F80-420B-9D15-D762FD8FAACA}';
{ Data table names }
nme_ListaAnosFacturas = 'ListaAnosFacturas';
@@ -75,6 +75,9 @@ const
fld_FacturasClienteREF_CONTRATO = 'REF_CONTRATO';
fld_FacturasClienteREF_CLI_CONTRATO = 'REF_CLI_CONTRATO';
fld_FacturasClienteSIN_COMISION = 'SIN_COMISION';
+ fld_FacturasClienteRETENCION = 'RETENCION';
+ fld_FacturasClienteIMPORTE_RETENCION = 'IMPORTE_RETENCION';
+ fld_FacturasClienteFECHA_RETENCION = 'FECHA_RETENCION';
{ FacturasCliente field indexes }
idx_FacturasClienteID = 0;
@@ -127,6 +130,9 @@ const
idx_FacturasClienteREF_CONTRATO = 47;
idx_FacturasClienteREF_CLI_CONTRATO = 48;
idx_FacturasClienteSIN_COMISION = 49;
+ idx_FacturasClienteRETENCION = 50;
+ idx_FacturasClienteIMPORTE_RETENCION = 51;
+ idx_FacturasClienteFECHA_RETENCION = 52;
{ FacturasCliente_Detalles fields }
fld_FacturasCliente_DetallesID = 'ID';
@@ -165,7 +171,7 @@ const
type
{ IListaAnosFacturas }
IListaAnosFacturas = interface(IDAStronglyTypedDataTable)
- ['{05716F30-A380-4511-8D1C-1CB66CE89B74}']
+ ['{C550D0F5-A742-4987-B656-2D1B8536B137}']
{ Property getters and setters }
function GetANOValue: String;
procedure SetANOValue(const aValue: String);
@@ -200,7 +206,7 @@ type
{ IFacturasCliente }
IFacturasCliente = interface(IDAStronglyTypedDataTable)
- ['{FFCE2216-A516-4FFC-B701-559E5CA69879}']
+ ['{5952F24E-C317-4659-B13F-23500E1555FF}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -401,6 +407,18 @@ type
procedure SetSIN_COMISIONValue(const aValue: SmallInt);
function GetSIN_COMISIONIsNull: Boolean;
procedure SetSIN_COMISIONIsNull(const aValue: Boolean);
+ function GetRETENCIONValue: Float;
+ procedure SetRETENCIONValue(const aValue: Float);
+ function GetRETENCIONIsNull: Boolean;
+ procedure SetRETENCIONIsNull(const aValue: Boolean);
+ function GetIMPORTE_RETENCIONValue: Currency;
+ procedure SetIMPORTE_RETENCIONValue(const aValue: Currency);
+ function GetIMPORTE_RETENCIONIsNull: Boolean;
+ procedure SetIMPORTE_RETENCIONIsNull(const aValue: Boolean);
+ function GetFECHA_RETENCIONValue: DateTime;
+ procedure SetFECHA_RETENCIONValue(const aValue: DateTime);
+ function GetFECHA_RETENCIONIsNull: Boolean;
+ procedure SetFECHA_RETENCIONIsNull(const aValue: Boolean);
{ Properties }
@@ -504,6 +522,12 @@ type
property REF_CLI_CONTRATOIsNull: Boolean read GetREF_CLI_CONTRATOIsNull write SetREF_CLI_CONTRATOIsNull;
property SIN_COMISION: SmallInt read GetSIN_COMISIONValue write SetSIN_COMISIONValue;
property SIN_COMISIONIsNull: Boolean read GetSIN_COMISIONIsNull write SetSIN_COMISIONIsNull;
+ property RETENCION: Float read GetRETENCIONValue write SetRETENCIONValue;
+ property RETENCIONIsNull: Boolean read GetRETENCIONIsNull write SetRETENCIONIsNull;
+ property IMPORTE_RETENCION: Currency read GetIMPORTE_RETENCIONValue write SetIMPORTE_RETENCIONValue;
+ property IMPORTE_RETENCIONIsNull: Boolean read GetIMPORTE_RETENCIONIsNull write SetIMPORTE_RETENCIONIsNull;
+ property FECHA_RETENCION: DateTime read GetFECHA_RETENCIONValue write SetFECHA_RETENCIONValue;
+ property FECHA_RETENCIONIsNull: Boolean read GetFECHA_RETENCIONIsNull write SetFECHA_RETENCIONIsNull;
end;
{ TFacturasClienteDataTableRules }
@@ -712,6 +736,18 @@ type
procedure SetSIN_COMISIONValue(const aValue: SmallInt); virtual;
function GetSIN_COMISIONIsNull: Boolean; virtual;
procedure SetSIN_COMISIONIsNull(const aValue: Boolean); virtual;
+ function GetRETENCIONValue: Float; virtual;
+ procedure SetRETENCIONValue(const aValue: Float); virtual;
+ function GetRETENCIONIsNull: Boolean; virtual;
+ procedure SetRETENCIONIsNull(const aValue: Boolean); virtual;
+ function GetIMPORTE_RETENCIONValue: Currency; virtual;
+ procedure SetIMPORTE_RETENCIONValue(const aValue: Currency); virtual;
+ function GetIMPORTE_RETENCIONIsNull: Boolean; virtual;
+ procedure SetIMPORTE_RETENCIONIsNull(const aValue: Boolean); virtual;
+ function GetFECHA_RETENCIONValue: DateTime; virtual;
+ procedure SetFECHA_RETENCIONValue(const aValue: DateTime); virtual;
+ function GetFECHA_RETENCIONIsNull: Boolean; virtual;
+ procedure SetFECHA_RETENCIONIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
@@ -814,6 +850,12 @@ type
property REF_CLI_CONTRATOIsNull: Boolean read GetREF_CLI_CONTRATOIsNull write SetREF_CLI_CONTRATOIsNull;
property SIN_COMISION: SmallInt read GetSIN_COMISIONValue write SetSIN_COMISIONValue;
property SIN_COMISIONIsNull: Boolean read GetSIN_COMISIONIsNull write SetSIN_COMISIONIsNull;
+ property RETENCION: Float read GetRETENCIONValue write SetRETENCIONValue;
+ property RETENCIONIsNull: Boolean read GetRETENCIONIsNull write SetRETENCIONIsNull;
+ property IMPORTE_RETENCION: Currency read GetIMPORTE_RETENCIONValue write SetIMPORTE_RETENCIONValue;
+ property IMPORTE_RETENCIONIsNull: Boolean read GetIMPORTE_RETENCIONIsNull write SetIMPORTE_RETENCIONIsNull;
+ property FECHA_RETENCION: DateTime read GetFECHA_RETENCIONValue write SetFECHA_RETENCIONValue;
+ property FECHA_RETENCIONIsNull: Boolean read GetFECHA_RETENCIONIsNull write SetFECHA_RETENCIONIsNull;
public
constructor Create(aDataTable: TDADataTable); override;
@@ -823,7 +865,7 @@ type
{ IFacturasCliente_Detalles }
IFacturasCliente_Detalles = interface(IDAStronglyTypedDataTable)
- ['{2B6FCA91-CF89-45F3-B606-258098698EBE}']
+ ['{75045275-7B22-4D9A-A1BF-D5169B86855C}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -2129,6 +2171,69 @@ begin
DataTable.Fields[idx_FacturasClienteSIN_COMISION].AsVariant := Null;
end;
+function TFacturasClienteDataTableRules.GetRETENCIONValue: Float;
+begin
+ result := DataTable.Fields[idx_FacturasClienteRETENCION].AsFloat;
+end;
+
+procedure TFacturasClienteDataTableRules.SetRETENCIONValue(const aValue: Float);
+begin
+ DataTable.Fields[idx_FacturasClienteRETENCION].AsFloat := aValue;
+end;
+
+function TFacturasClienteDataTableRules.GetRETENCIONIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_FacturasClienteRETENCION].IsNull;
+end;
+
+procedure TFacturasClienteDataTableRules.SetRETENCIONIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_FacturasClienteRETENCION].AsVariant := Null;
+end;
+
+function TFacturasClienteDataTableRules.GetIMPORTE_RETENCIONValue: Currency;
+begin
+ result := DataTable.Fields[idx_FacturasClienteIMPORTE_RETENCION].AsCurrency;
+end;
+
+procedure TFacturasClienteDataTableRules.SetIMPORTE_RETENCIONValue(const aValue: Currency);
+begin
+ DataTable.Fields[idx_FacturasClienteIMPORTE_RETENCION].AsCurrency := aValue;
+end;
+
+function TFacturasClienteDataTableRules.GetIMPORTE_RETENCIONIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_FacturasClienteIMPORTE_RETENCION].IsNull;
+end;
+
+procedure TFacturasClienteDataTableRules.SetIMPORTE_RETENCIONIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_FacturasClienteIMPORTE_RETENCION].AsVariant := Null;
+end;
+
+function TFacturasClienteDataTableRules.GetFECHA_RETENCIONValue: DateTime;
+begin
+ result := DataTable.Fields[idx_FacturasClienteFECHA_RETENCION].AsDateTime;
+end;
+
+procedure TFacturasClienteDataTableRules.SetFECHA_RETENCIONValue(const aValue: DateTime);
+begin
+ DataTable.Fields[idx_FacturasClienteFECHA_RETENCION].AsDateTime := aValue;
+end;
+
+function TFacturasClienteDataTableRules.GetFECHA_RETENCIONIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_FacturasClienteFECHA_RETENCION].IsNull;
+end;
+
+procedure TFacturasClienteDataTableRules.SetFECHA_RETENCIONIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_FacturasClienteFECHA_RETENCION].AsVariant := Null;
+end;
+
{ TFacturasCliente_DetallesDataTableRules }
constructor TFacturasCliente_DetallesDataTableRules.Create(aDataTable: TDADataTable);
diff --git a/Source/Modulos/Facturas de cliente/Model/schFacturasClienteServer_Intf.pas b/Source/Modulos/Facturas de cliente/Model/schFacturasClienteServer_Intf.pas
index 24d1d93..b14e0e9 100644
--- a/Source/Modulos/Facturas de cliente/Model/schFacturasClienteServer_Intf.pas
+++ b/Source/Modulos/Facturas de cliente/Model/schFacturasClienteServer_Intf.pas
@@ -9,14 +9,14 @@ const
{ Delta rules ids
Feel free to change them to something more human readable
but make sure they are unique in the context of your application }
- RID_ListaAnosFacturasDelta = '{42E63B9E-C30F-4EC7-94CA-5E04DD371267}';
- RID_FacturasClienteDelta = '{5001B597-C42F-43E3-8F12-76971C88F8E8}';
- RID_FacturasCliente_DetallesDelta = '{E16AF380-A076-4EDB-9CB4-5446DBF8C9AE}';
+ RID_ListaAnosFacturasDelta = '{491A2F25-2666-44F0-9840-E59A6F5FE91C}';
+ RID_FacturasClienteDelta = '{E71F6BB9-24D4-45DC-872F-63B1B6081CEA}';
+ RID_FacturasCliente_DetallesDelta = '{1AA87512-9077-40A2-80E2-62DEBD690640}';
type
{ IListaAnosFacturasDelta }
IListaAnosFacturasDelta = interface(IListaAnosFacturas)
- ['{42E63B9E-C30F-4EC7-94CA-5E04DD371267}']
+ ['{491A2F25-2666-44F0-9840-E59A6F5FE91C}']
{ Property getters and setters }
function GetOldANOValue : String;
@@ -50,7 +50,7 @@ type
{ IFacturasClienteDelta }
IFacturasClienteDelta = interface(IFacturasCliente)
- ['{5001B597-C42F-43E3-8F12-76971C88F8E8}']
+ ['{E71F6BB9-24D4-45DC-872F-63B1B6081CEA}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;
@@ -102,6 +102,9 @@ type
function GetOldREF_CONTRATOValue : String;
function GetOldREF_CLI_CONTRATOValue : String;
function GetOldSIN_COMISIONValue : SmallInt;
+ function GetOldRETENCIONValue : Float;
+ function GetOldIMPORTE_RETENCIONValue : Currency;
+ function GetOldFECHA_RETENCIONValue : DateTime;
{ Properties }
property OldID : Integer read GetOldIDValue;
@@ -154,6 +157,9 @@ type
property OldREF_CONTRATO : String read GetOldREF_CONTRATOValue;
property OldREF_CLI_CONTRATO : String read GetOldREF_CLI_CONTRATOValue;
property OldSIN_COMISION : SmallInt read GetOldSIN_COMISIONValue;
+ property OldRETENCION : Float read GetOldRETENCIONValue;
+ property OldIMPORTE_RETENCION : Currency read GetOldIMPORTE_RETENCIONValue;
+ property OldFECHA_RETENCION : DateTime read GetOldFECHA_RETENCIONValue;
end;
{ TFacturasClienteBusinessProcessorRules }
@@ -462,6 +468,24 @@ type
function GetOldSIN_COMISIONIsNull: Boolean; virtual;
procedure SetSIN_COMISIONValue(const aValue: SmallInt); virtual;
procedure SetSIN_COMISIONIsNull(const aValue: Boolean); virtual;
+ function GetRETENCIONValue: Float; virtual;
+ function GetRETENCIONIsNull: Boolean; virtual;
+ function GetOldRETENCIONValue: Float; virtual;
+ function GetOldRETENCIONIsNull: Boolean; virtual;
+ procedure SetRETENCIONValue(const aValue: Float); virtual;
+ procedure SetRETENCIONIsNull(const aValue: Boolean); virtual;
+ function GetIMPORTE_RETENCIONValue: Currency; virtual;
+ function GetIMPORTE_RETENCIONIsNull: Boolean; virtual;
+ function GetOldIMPORTE_RETENCIONValue: Currency; virtual;
+ function GetOldIMPORTE_RETENCIONIsNull: Boolean; virtual;
+ procedure SetIMPORTE_RETENCIONValue(const aValue: Currency); virtual;
+ procedure SetIMPORTE_RETENCIONIsNull(const aValue: Boolean); virtual;
+ function GetFECHA_RETENCIONValue: DateTime; virtual;
+ function GetFECHA_RETENCIONIsNull: Boolean; virtual;
+ function GetOldFECHA_RETENCIONValue: DateTime; virtual;
+ function GetOldFECHA_RETENCIONIsNull: Boolean; virtual;
+ procedure SetFECHA_RETENCIONValue(const aValue: DateTime); virtual;
+ procedure SetFECHA_RETENCIONIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID : Integer read GetIDValue write SetIDValue;
@@ -664,6 +688,18 @@ type
property SIN_COMISIONIsNull : Boolean read GetSIN_COMISIONIsNull write SetSIN_COMISIONIsNull;
property OldSIN_COMISION : SmallInt read GetOldSIN_COMISIONValue;
property OldSIN_COMISIONIsNull : Boolean read GetOldSIN_COMISIONIsNull;
+ property RETENCION : Float read GetRETENCIONValue write SetRETENCIONValue;
+ property RETENCIONIsNull : Boolean read GetRETENCIONIsNull write SetRETENCIONIsNull;
+ property OldRETENCION : Float read GetOldRETENCIONValue;
+ property OldRETENCIONIsNull : Boolean read GetOldRETENCIONIsNull;
+ property IMPORTE_RETENCION : Currency read GetIMPORTE_RETENCIONValue write SetIMPORTE_RETENCIONValue;
+ property IMPORTE_RETENCIONIsNull : Boolean read GetIMPORTE_RETENCIONIsNull write SetIMPORTE_RETENCIONIsNull;
+ property OldIMPORTE_RETENCION : Currency read GetOldIMPORTE_RETENCIONValue;
+ property OldIMPORTE_RETENCIONIsNull : Boolean read GetOldIMPORTE_RETENCIONIsNull;
+ property FECHA_RETENCION : DateTime read GetFECHA_RETENCIONValue write SetFECHA_RETENCIONValue;
+ property FECHA_RETENCIONIsNull : Boolean read GetFECHA_RETENCIONIsNull write SetFECHA_RETENCIONIsNull;
+ property OldFECHA_RETENCION : DateTime read GetOldFECHA_RETENCIONValue;
+ property OldFECHA_RETENCIONIsNull : Boolean read GetOldFECHA_RETENCIONIsNull;
public
constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
@@ -673,7 +709,7 @@ type
{ IFacturasCliente_DetallesDelta }
IFacturasCliente_DetallesDelta = interface(IFacturasCliente_Detalles)
- ['{E16AF380-A076-4EDB-9CB4-5446DBF8C9AE}']
+ ['{1AA87512-9077-40A2-80E2-62DEBD690640}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_FACTURAValue : Integer;
@@ -2490,6 +2526,99 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteSIN_COMISION] := Null;
end;
+function TFacturasClienteBusinessProcessorRules.GetRETENCIONValue: Float;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteRETENCION];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetRETENCIONIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteRETENCION]);
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldRETENCIONValue: Float;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteRETENCION];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldRETENCIONIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteRETENCION]);
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetRETENCIONValue(const aValue: Float);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteRETENCION] := aValue;
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetRETENCIONIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteRETENCION] := Null;
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetIMPORTE_RETENCIONValue: Currency;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteIMPORTE_RETENCION];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetIMPORTE_RETENCIONIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteIMPORTE_RETENCION]);
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldIMPORTE_RETENCIONValue: Currency;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteIMPORTE_RETENCION];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldIMPORTE_RETENCIONIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteIMPORTE_RETENCION]);
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetIMPORTE_RETENCIONValue(const aValue: Currency);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteIMPORTE_RETENCION] := aValue;
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetIMPORTE_RETENCIONIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteIMPORTE_RETENCION] := Null;
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetFECHA_RETENCIONValue: DateTime;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_RETENCION];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetFECHA_RETENCIONIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_RETENCION]);
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldFECHA_RETENCIONValue: DateTime;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteFECHA_RETENCION];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldFECHA_RETENCIONIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteFECHA_RETENCION]);
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetFECHA_RETENCIONValue(const aValue: DateTime);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_RETENCION] := aValue;
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetFECHA_RETENCIONIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteFECHA_RETENCION] := Null;
+end;
+
{ TFacturasCliente_DetallesBusinessProcessorRules }
constructor TFacturasCliente_DetallesBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
diff --git a/Source/Modulos/Facturas de cliente/Model/uBizFacturasCliente.pas b/Source/Modulos/Facturas de cliente/Model/uBizFacturasCliente.pas
index 4a672a0..07e91f1 100644
--- a/Source/Modulos/Facturas de cliente/Model/uBizFacturasCliente.pas
+++ b/Source/Modulos/Facturas de cliente/Model/uBizFacturasCliente.pas
@@ -44,6 +44,7 @@ type
procedure CalcularDescuento;
procedure CalcularIVA;
procedure CalcularRE;
+ procedure CalcularRetencion;
procedure CalcularBaseImponible;
procedure AsignarTipoIVA (IDTipoIVA : Integer);
@@ -69,6 +70,7 @@ type
procedure DESCUENTOOnChange(Sender: TDACustomField);
procedure IVAOnChange(Sender: TDACustomField);
procedure REOnChange(Sender: TDACustomField);
+ procedure RetencionOnChange(Sender: TDACustomField);
procedure SetID_TIENDAValue(const aValue: Integer);
procedure SetID_SUBCUENTAValue(const aValue: Integer);
@@ -157,7 +159,8 @@ begin
CalcularBaseImponible;
CalcularIVA;
CalcularRE;
-
+ CalcularRetencion;
+
if not Self.DataTable.Editing then
Edit;
IMPORTE_TOTAL := BASE_IMPONIBLE + IMPORTE_IVA + IMPORTE_RE;
@@ -181,6 +184,13 @@ begin
IMPORTE_RE := (RE / 100) * BASE_IMPONIBLE;
end;
+procedure TBizFacturaCliente.CalcularRetencion;
+begin
+ if not Self.DataTable.Editing then
+ Edit;
+ IMPORTE_RETENCION := (RETENCION / 100) * BASE_IMPONIBLE;
+end;
+
constructor TBizFacturaCliente.Create(aDataTable: TDADataTable);
begin
inherited;
@@ -196,6 +206,7 @@ begin
FieldByName(fld_FacturasClienteDESCUENTO).OnChange := DESCUENTOOnChange;
FieldByName(fld_FacturasClienteIVA).OnChange := IVAOnChange;
FieldByName(fld_FacturasClienteRE).OnChange := REOnChange;
+ FieldByName(fld_FacturasClienteRetencion).OnChange := RetencionOnChange;
end;
FDetallesLink := TDADataSource.Create(NIL);
@@ -316,6 +327,11 @@ begin
CalcularImporteTotal;
end;
+procedure TBizFacturaCliente.RetencionOnChange(Sender: TDACustomField);
+begin
+ CalcularImporteTotal;
+end;
+
procedure TBizFacturaCliente.SetCliente(AValue: IBizCliente);
var
bEnEdicion : Boolean;
diff --git a/Source/Modulos/Facturas de cliente/Reports/uRptFacturasCliente_Server.dfm b/Source/Modulos/Facturas de cliente/Reports/uRptFacturasCliente_Server.dfm
index fde399f..9e2cc9c 100644
--- a/Source/Modulos/Facturas de cliente/Reports/uRptFacturasCliente_Server.dfm
+++ b/Source/Modulos/Facturas de cliente/Reports/uRptFacturasCliente_Server.dfm
@@ -149,6 +149,18 @@ object RptFacturasCliente: TRptFacturasCliente
DataType = datString
Size = 255
end
+ item
+ Name = 'RETENCION'
+ DataType = datFloat
+ end
+ item
+ Name = 'IMPORTE_RETENCION'
+ DataType = datCurrency
+ end
+ item
+ Name = 'FECHA_RETENCION'
+ DataType = datDateTime
+ end
item
Name = 'TITULAR'
DataType = datString
@@ -488,9 +500,10 @@ object RptFacturasCliente: TRptFacturasCliente
#39' || extract (year from fecha_factura)'#10'when extract (month from ' +
'fecha_factura) = 12 then '#39'DICIEMBRE - '#39' || extract (year from fe' +
'cha_factura)'#10'end as TITULO,'#10'REFERENCIA, ID_CLIENTE, NOMBRE, SIT' +
- 'UACION, NIF_CIF, REFERENCIA_CLIENTE, FECHA_FACTURA, BASE_IMPONIB' +
- 'LE, IVA, IMPORTE_IVA, IMPORTE_TOTAL'#10#10'from V_facturas_cliente'#10'whe' +
- 're {where}'#10'order by ANO, MES, FECHA_FACTURA, NOMBRE'#10#10
+ 'UACION, NIF_CIF, REFERENCIA_CLIENTE, FECHA_FACTURA, FECHA_VENCIM' +
+ 'IENTO, BASE_IMPONIBLE, IVA, IMPORTE_IVA, IMPORTE_TOTAL'#10#10'from V_f' +
+ 'acturas_cliente'#10'where {where}'#10'order by ANO, MES, FECHA_FACTURA, ' +
+ 'NOMBRE'#10#10
StatementType = stSQL
ColumnMappings = <
item
@@ -552,6 +565,10 @@ object RptFacturasCliente: TRptFacturasCliente
item
DatasetField = 'IVA'
TableField = 'IVA'
+ end
+ item
+ DatasetField = 'FECHA_VENCIMIENTO'
+ TableField = 'FECHA_VENCIMIENTO'
end>
end>
Name = 'ListadoFacturas'
@@ -606,6 +623,10 @@ object RptFacturasCliente: TRptFacturasCliente
Name = 'FECHA_FACTURA'
DataType = datDateTime
end
+ item
+ Name = 'FECHA_VENCIMIENTO'
+ DataType = datDateTime
+ end
item
Name = 'BASE_IMPONIBLE'
DataType = datCurrency
@@ -648,21 +669,22 @@ object RptFacturasCliente: TRptFacturasCliente
'CTURAS_CLIENTE.REFERENCIA_CLIENTE, V_FACTURAS_CLIENTE.NIF_CIF, V' +
'_FACTURAS_CLIENTE.NOMBRE, V_FACTURAS_CLIENTE.CALLE,'#10' V_FACTUR' +
'AS_CLIENTE.PROVINCIA, V_FACTURAS_CLIENTE.CODIGO_POSTAL, V_FACTUR' +
- 'AS_CLIENTE.POBLACION,'#10' V_FACTURAS_CLIENTE.REF_CLI_CONTRATO,'#10' ' +
- ' CONTACTOS_DATOS_BANCO.TITULAR,'#10' CONTACTOS_DATOS_BANCO.ENTI' +
- 'DAD,'#10' CONTACTOS_DATOS_BANCO.SUCURSAL,'#10' CONTACTOS_DATOS_BAN' +
- 'CO.DC,'#10' CONTACTOS_DATOS_BANCO.CUENTA,'#10' ID_EMPRESA, EMPRESA' +
- 'S.NIF_CIF as NIF_CIF_EMPRESA, EMPRESAS.RAZON_SOCIAL,'#10' EMPRESA' +
- 'S.CALLE as CALLE_EMPRESA, EMPRESAS.POBLACION as POBLACION_EMPRES' +
- 'A,'#10' EMPRESAS.PROVINCIA as PROVINCIA_EMPRESA, EMPRESAS.CODIGO_' +
- 'POSTAL as CODIGO_POSTAL_EMPRESA,'#10' EMPRESAS.TELEFONO_1, EMPRES' +
- 'AS.FAX, EMPRESAS.MOVIL_1, EMPRESAS.EMAIL_1,'#10' EMPRESAS.PAGINA_' +
- 'WEB, EMPRESAS.REGISTRO_MERCANTIL, EMPRESAS.LOGOTIPO'#10'FROM V_FACTU' +
- 'RAS_CLIENTE'#10'LEFT JOIN EMPRESAS ON EMPRESAS.ID = ID_EMPRESA'#10'LEFT ' +
- 'JOIN FORMAS_PAGO ON (FORMAS_PAGO.ID = V_FACTURAS_CLIENTE.ID_FORM' +
- 'A_PAGO)'#10'LEFT JOIN CONTACTOS_DATOS_BANCO ON (CONTACTOS_DATOS_BANC' +
- 'O.ID_CONTACTO = V_FACTURAS_CLIENTE.ID_CLIENTE)'#10'WHERE V_FACTURAS_' +
- 'CLIENTE.ID = :ID'#10
+ 'AS_CLIENTE.POBLACION,'#10' V_FACTURAS_CLIENTE.REF_CLI_CONTRATO, V' +
+ '_FACTURAS_CLIENTE.RETENCION, V_FACTURAS_CLIENTE.IMPORTE_RETENCIO' +
+ 'N, V_FACTURAS_CLIENTE.FECHA_RETENCION,'#10' CONTACTOS_DATOS_BANCO' +
+ '.TITULAR,'#10' CONTACTOS_DATOS_BANCO.ENTIDAD,'#10' CONTACTOS_DATOS' +
+ '_BANCO.SUCURSAL,'#10' CONTACTOS_DATOS_BANCO.DC,'#10' CONTACTOS_DAT' +
+ 'OS_BANCO.CUENTA,'#10' ID_EMPRESA, EMPRESAS.NIF_CIF as NIF_CIF_EMP' +
+ 'RESA, EMPRESAS.RAZON_SOCIAL,'#10' EMPRESAS.CALLE as CALLE_EMPRESA' +
+ ', EMPRESAS.POBLACION as POBLACION_EMPRESA,'#10' EMPRESAS.PROVINCI' +
+ 'A as PROVINCIA_EMPRESA, EMPRESAS.CODIGO_POSTAL as CODIGO_POSTAL_' +
+ 'EMPRESA,'#10' EMPRESAS.TELEFONO_1, EMPRESAS.FAX, EMPRESAS.MOVIL_1' +
+ ', EMPRESAS.EMAIL_1,'#10' EMPRESAS.PAGINA_WEB, EMPRESAS.REGISTRO_M' +
+ 'ERCANTIL, EMPRESAS.LOGOTIPO'#10'FROM V_FACTURAS_CLIENTE'#10'LEFT JOIN EM' +
+ 'PRESAS ON EMPRESAS.ID = ID_EMPRESA'#10'LEFT JOIN FORMAS_PAGO ON (FOR' +
+ 'MAS_PAGO.ID = V_FACTURAS_CLIENTE.ID_FORMA_PAGO)'#10'LEFT JOIN CONTAC' +
+ 'TOS_DATOS_BANCO ON (CONTACTOS_DATOS_BANCO.ID_CONTACTO = V_FACTUR' +
+ 'AS_CLIENTE.ID_CLIENTE)'#10'WHERE V_FACTURAS_CLIENTE.ID = :ID'#10
StatementType = stSQL
ColumnMappings = <
item
@@ -862,6 +884,18 @@ object RptFacturasCliente: TRptFacturasCliente
DatasetField = 'REF_CLI_CONTRATO'
TableField = ''
SQLOrigin = 'REF_CLI_CONTRATO'
+ end
+ item
+ DatasetField = 'RETENCION'
+ TableField = 'RETENCION'
+ end
+ item
+ DatasetField = 'IMPORTE_RETENCION'
+ TableField = 'IMPORTE_RETENCION'
+ end
+ item
+ DatasetField = 'FECHA_RETENCION'
+ TableField = 'FECHA_RETENCION'
end>
end>
Name = 'InformeFacturasCliente'
@@ -996,6 +1030,18 @@ object RptFacturasCliente: TRptFacturasCliente
DataType = datString
Size = 255
end
+ item
+ Name = 'RETENCION'
+ DataType = datFloat
+ end
+ item
+ Name = 'IMPORTE_RETENCION'
+ DataType = datCurrency
+ end
+ item
+ Name = 'FECHA_RETENCION'
+ DataType = datDateTime
+ end
item
Name = 'TITULAR'
DataType = datString
@@ -1565,7 +1611,7 @@ object RptFacturasCliente: TRptFacturasCliente
PrintOptions.Printer = 'Por defecto'
PrintOptions.PrintOnSheet = 0
ReportOptions.CreateDate = 37800.807714351900000000
- ReportOptions.LastChange = 40959.582460520830000000
+ ReportOptions.LastChange = 42380.750037025460000000
ScriptLanguage = 'PascalScript'
ShowProgress = False
StoreInDFM = False
diff --git a/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm b/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm
index 50cf8ca..33c9d01 100644
--- a/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm
+++ b/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm
@@ -247,6 +247,18 @@ object srvFacturasCliente: TsrvFacturasCliente
item
DatasetField = 'REF_CLI_CONTRATO'
TableField = 'REF_CLI_CONTRATO'
+ end
+ item
+ DatasetField = 'RETENCION'
+ TableField = 'RETENCION'
+ end
+ item
+ DatasetField = 'IMPORTE_RETENCION'
+ TableField = 'IMPORTE_RETENCION'
+ end
+ item
+ DatasetField = 'FECHA_RETENCION'
+ TableField = 'FECHA_RETENCION'
end>
end>
Name = 'FacturasCliente'
@@ -524,6 +536,18 @@ object srvFacturasCliente: TsrvFacturasCliente
Name = 'SIN_COMISION'
DataType = datSmallInt
DictionaryEntry = 'FacturasCliente_SIN_COMISION'
+ end
+ item
+ Name = 'RETENCION'
+ DataType = datFloat
+ end
+ item
+ Name = 'IMPORTE_RETENCION'
+ DataType = datCurrency
+ end
+ item
+ Name = 'FECHA_RETENCION'
+ DataType = datDateTime
end>
end
item
@@ -1126,6 +1150,21 @@ object srvFacturasCliente: TsrvFacturasCliente
DataType = datString
Size = 255
Value = ''
+ end
+ item
+ Name = 'RETENCION'
+ DataType = datFloat
+ Value = ''
+ end
+ item
+ Name = 'IMPORTE_RETENCION'
+ DataType = datCurrency
+ Value = ''
+ end
+ item
+ Name = 'FECHA_RETENCION'
+ DataType = datDateTime
+ Value = ''
end>
Statements = <
item
@@ -1142,16 +1181,18 @@ object srvFacturasCliente: TsrvFacturasCliente
'RIO,'#10' ID_FORMA_PAGO,'#10' RECARGO_EQUIVALENCIA,'#10' ID_TIPO_IV' +
'A,'#10' IMPORTE_NETO,'#10' IMPORTE_PORTE,'#10' IGNORAR_CONTABILIDAD' +
','#10' ID_TIENDA,'#10' ID_CONTRATO,'#10' SIN_COMISION,'#10' SITUACIO' +
- 'N)'#10' VALUES ('#10' :ID,'#10' :ID_EMPRESA,'#10' :REFERENCIA,'#10' :FE' +
- 'CHA_FACTURA,'#10' :FECHA_VENCIMIENTO,'#10' :BASE_IMPONIBLE,'#10' :D' +
- 'ESCUENTO,'#10' :IMPORTE_DESCUENTO,'#10' :IVA,'#10' :IMPORTE_IVA,'#10' ' +
- ' :RE,'#10' :IMPORTE_RE,'#10' :IMPORTE_TOTAL,'#10' :OBSERVACIONES,'#10 +
- ' :ID_CLIENTE,'#10' :NIF_CIF,'#10' :NOMBRE,'#10' :CALLE,'#10' :POB' +
- 'LACION,'#10' :PROVINCIA,'#10' :CODIGO_POSTAL,'#10' CURRENT_TIMESTAM' +
- 'P,'#10' :USUARIO,'#10' :ID_FORMA_PAGO,'#10' :RECARGO_EQUIVALENCIA,'#10 +
- ' :ID_TIPO_IVA,'#10' :IMPORTE_NETO,'#10' :IMPORTE_PORTE,'#10' :IG' +
- 'NORAR_CONTABILIDAD,'#10' :ID_TIENDA,'#10' :ID_CONTRATO,'#10' :SIN_C' +
- 'OMISION,'#10' :SITUACION);'#10
+ 'N,'#10' RETENCION,'#10' IMPORTE_RETENCION,'#10' FECHA_RETENCION)'#10' ' +
+ 'VALUES ('#10' :ID,'#10' :ID_EMPRESA,'#10' :REFERENCIA,'#10' :FECHA_F' +
+ 'ACTURA,'#10' :FECHA_VENCIMIENTO,'#10' :BASE_IMPONIBLE,'#10' :DESCUE' +
+ 'NTO,'#10' :IMPORTE_DESCUENTO,'#10' :IVA,'#10' :IMPORTE_IVA,'#10' :RE' +
+ ','#10' :IMPORTE_RE,'#10' :IMPORTE_TOTAL,'#10' :OBSERVACIONES,'#10' :' +
+ 'ID_CLIENTE,'#10' :NIF_CIF,'#10' :NOMBRE,'#10' :CALLE,'#10' :POBLACIO' +
+ 'N,'#10' :PROVINCIA,'#10' :CODIGO_POSTAL,'#10' CURRENT_TIMESTAMP,'#10' ' +
+ ' :USUARIO,'#10' :ID_FORMA_PAGO,'#10' :RECARGO_EQUIVALENCIA,'#10' :' +
+ 'ID_TIPO_IVA,'#10' :IMPORTE_NETO,'#10' :IMPORTE_PORTE,'#10' :IGNORAR' +
+ '_CONTABILIDAD,'#10' :ID_TIENDA,'#10' :ID_CONTRATO,'#10' :SIN_COMISI' +
+ 'ON,'#10' :SITUACION,'#10' :RETENCION,'#10' :IMPORTE_RETENCION,'#10' ' +
+ ':FECHA_RETENCION);'#10
StatementType = stSQL
ColumnMappings = <>
end>
@@ -1323,6 +1364,21 @@ object srvFacturasCliente: TsrvFacturasCliente
Size = 255
Value = ''
end
+ item
+ Name = 'RETENCION'
+ DataType = datFloat
+ Value = ''
+ end
+ item
+ Name = 'IMPORTE_RETENCION'
+ DataType = datCurrency
+ Value = ''
+ end
+ item
+ Name = 'FECHA_RETENCION'
+ DataType = datDateTime
+ Value = ''
+ end
item
Name = 'OLD_ID'
Value = ''
@@ -1348,7 +1404,9 @@ object srvFacturasCliente: TsrvFacturasCliente
'TO = :IMPORTE_NETO,'#10' IMPORTE_PORTE = :IMPORTE_PORTE,'#10' IGNO' +
'RAR_CONTABILIDAD = :IGNORAR_CONTABILIDAD,'#10' ID_TIENDA = :ID_TI' +
'ENDA,'#10' ID_CONTRATO = :ID_CONTRATO,'#10' SIN_COMISION = :SIN_CO' +
- 'MISION,'#10' SITUACION = :SITUACION'#10' WHERE'#10' (ID = :OLD_ID);'#10
+ 'MISION,'#10' SITUACION = :SITUACION,'#10' RETENCION = :RETENCION,'#10 +
+ ' IMPORTE_RETENCION = :IMPORTE_RETENCION,'#10' FECHA_RETENCION ' +
+ '= :FECHA_RETENCION'#10' WHERE'#10' (ID = :OLD_ID);'#10
StatementType = stSQL
ColumnMappings = <>
end>
diff --git a/Source/Modulos/Facturas de cliente/Views/FacturasCliente_view.dproj b/Source/Modulos/Facturas de cliente/Views/FacturasCliente_view.dproj
index 07a1721..f3614ed 100644
--- a/Source/Modulos/Facturas de cliente/Views/FacturasCliente_view.dproj
+++ b/Source/Modulos/Facturas de cliente/Views/FacturasCliente_view.dproj
@@ -49,48 +49,48 @@
MainSource
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
TForm
diff --git a/Source/Modulos/Facturas de cliente/Views/uEditorFacturaCliente.dfm b/Source/Modulos/Facturas de cliente/Views/uEditorFacturaCliente.dfm
index 01c63d2..531fcaa 100644
--- a/Source/Modulos/Facturas de cliente/Views/uEditorFacturaCliente.dfm
+++ b/Source/Modulos/Facturas de cliente/Views/uEditorFacturaCliente.dfm
@@ -70,32 +70,32 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
end
end
inherited StatusBar: TJvStatusBar
- Top = 643
+ Top = 423
Width = 860
Panels = <
item
Width = 200
end>
- ExplicitTop = 643
+ ExplicitTop = 423
ExplicitWidth = 860
end
inherited pgPaginas: TPageControl
Width = 854
- Height = 365
+ Height = 308
OnChanging = pgPaginasChanging
ExplicitTop = 112
ExplicitWidth = 854
- ExplicitHeight = 365
+ ExplicitHeight = 308
inherited pagGeneral: TTabSheet
ExplicitLeft = 4
ExplicitTop = 24
ExplicitWidth = 846
- ExplicitHeight = 337
+ ExplicitHeight = 280
inline frViewFacturaCliente1: TfrViewFacturaCliente
Left = 0
Top = 0
Width = 846
- Height = 337
+ Height = 280
Align = alClient
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
@@ -106,12 +106,12 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
TabOrder = 0
ReadOnly = False
ExplicitWidth = 846
- ExplicitHeight = 337
+ ExplicitHeight = 280
inherited dxLayoutControl1: TdxLayoutControl
Width = 846
- Height = 337
+ Height = 280
ExplicitWidth = 846
- ExplicitHeight = 337
+ ExplicitHeight = 280
inherited eReferencia: TcxDBTextEdit
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
@@ -270,7 +270,7 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
Left = 0
Top = 0
Width = 846
- Height = 337
+ Height = 280
Align = alClient
BiDiMode = bdLeftToRight
Font.Charset = DEFAULT_CHARSET
@@ -283,7 +283,7 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
TabOrder = 0
ReadOnly = False
ExplicitWidth = 846
- ExplicitHeight = 337
+ ExplicitHeight = 280
inherited ToolBar1: TToolBar
Width = 846
Height = 24
@@ -313,67 +313,67 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
ExplicitWidth = 57
end
inherited UpDown1: TUpDown
- Left = 570
+ Left = 588
Top = 0
- ExplicitLeft = 570
+ ExplicitLeft = 588
ExplicitTop = 0
end
inherited ToolButton13: TToolButton
- Left = 587
+ Left = 605
Top = 0
- ExplicitLeft = 587
+ ExplicitLeft = 605
ExplicitTop = 0
end
inherited ToolButton6: TToolButton
- Left = 595
+ Left = 613
Top = 0
- ExplicitLeft = 595
+ ExplicitLeft = 613
ExplicitTop = 0
end
inherited ToolButton7: TToolButton
- Left = 629
+ Left = 647
Top = 0
- ExplicitLeft = 629
+ ExplicitLeft = 647
ExplicitTop = 0
end
inherited ToolButton8: TToolButton
- Left = 663
+ Left = 681
Top = 0
- ExplicitLeft = 663
+ ExplicitLeft = 681
ExplicitTop = 0
end
inherited ToolButton12: TToolButton
- Left = 697
+ Left = 715
Top = 0
- ExplicitLeft = 697
+ ExplicitLeft = 715
ExplicitTop = 0
end
inherited ToolButton9: TToolButton
- Left = 705
+ Left = 723
Top = 0
- ExplicitLeft = 705
+ ExplicitLeft = 723
ExplicitTop = 0
end
inherited ToolButton10: TToolButton
- Left = 739
+ Left = 757
Top = 0
- ExplicitLeft = 739
+ ExplicitLeft = 757
ExplicitTop = 0
end
inherited ToolButton11: TToolButton
- Left = 773
+ Left = 791
Top = 0
- ExplicitLeft = 773
+ ExplicitLeft = 791
ExplicitTop = 0
end
end
inherited cxGrid: TcxGrid
Top = 50
Width = 846
- Height = 287
+ Height = 230
ExplicitTop = 50
ExplicitWidth = 846
- ExplicitHeight = 287
+ ExplicitHeight = 230
end
inherited TBXDock1: TTBXDock
Top = 24
@@ -453,9 +453,9 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
end
inline frViewTotales1: TfrViewTotales [5]
Left = 0
- Top = 480
+ Top = 442
Width = 860
- Height = 163
+ Height = 220
Align = alBottom
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
@@ -465,29 +465,43 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
ParentFont = False
TabOrder = 4
ReadOnly = False
- ExplicitTop = 480
+ ExplicitTop = 442
ExplicitWidth = 860
- ExplicitHeight = 163
+ ExplicitHeight = 220
inherited dxLayoutControl1: TdxLayoutControl
Width = 860
LookAndFeel = frViewFacturaCliente1.dxLayoutOfficeLookAndFeel1
ExplicitWidth = 860
inherited Bevel3: TBevel
- Left = 457
+ Left = 404
Top = 30
Height = 122
- ExplicitLeft = 457
+ ExplicitLeft = 404
ExplicitTop = 30
ExplicitHeight = 122
end
inherited Bevel4: TBevel
- Left = 569
+ Left = 516
Top = 57
Width = 186
- ExplicitLeft = 569
+ ExplicitLeft = 516
ExplicitTop = 57
ExplicitWidth = 186
end
+ inherited Bevel2: TBevel
+ Top = 185
+ Width = 333
+ ExplicitTop = 185
+ ExplicitWidth = 333
+ end
+ inherited Bevel1: TBevel
+ Left = 423
+ Top = 185
+ Width = 332
+ ExplicitLeft = 423
+ ExplicitTop = 185
+ ExplicitWidth = 332
+ end
inherited ImporteDto: TcxDBCurrencyEdit
Top = 57
Style.LookAndFeel.SkinName = ''
@@ -500,27 +514,27 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
Width = 220
end
inherited ImporteIVA: TcxDBCurrencyEdit
- Left = 640
+ Left = 587
Top = 77
Style.LookAndFeel.SkinName = ''
Style.IsFontAssigned = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
- ExplicitLeft = 640
+ ExplicitLeft = 587
ExplicitTop = 77
ExplicitWidth = 155
Width = 155
end
inherited ImporteTotal: TcxDBCurrencyEdit
- Left = 570
+ Left = 517
Top = 158
Style.LookAndFeel.SkinName = ''
Style.IsFontAssigned = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
- ExplicitLeft = 570
+ ExplicitLeft = 517
ExplicitTop = 158
ExplicitWidth = 225
Width = 225
@@ -536,31 +550,31 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
ExplicitTop = 57
end
inherited edtIVA: TcxDBSpinEdit
- Left = 569
+ Left = 516
Top = 77
Style.LookAndFeel.SkinName = ''
Style.IsFontAssigned = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
- ExplicitLeft = 569
+ ExplicitLeft = 516
ExplicitTop = 77
end
inherited ImporteBase: TcxDBCurrencyEdit
- Left = 569
+ Left = 516
Top = 30
Style.LookAndFeel.SkinName = ''
Style.IsFontAssigned = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
- ExplicitLeft = 569
+ ExplicitLeft = 516
ExplicitTop = 30
ExplicitWidth = 226
Width = 226
end
inherited edtRE: TcxDBSpinEdit
- Left = 569
+ Left = 516
Top = 131
Properties.AssignedValues.MinValue = True
Style.LookAndFeel.SkinName = ''
@@ -568,34 +582,34 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
- ExplicitLeft = 569
+ ExplicitLeft = 516
ExplicitTop = 131
end
inherited edtIRPF: TcxDBSpinEdit
- Left = 569
+ Left = 516
Top = 104
Style.IsFontAssigned = True
- ExplicitLeft = 569
+ ExplicitLeft = 516
ExplicitTop = 104
end
inherited ImporteRE: TcxDBCurrencyEdit
- Left = 640
+ Left = 587
Top = 131
Style.LookAndFeel.SkinName = ''
Style.IsFontAssigned = True
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
- ExplicitLeft = 640
+ ExplicitLeft = 587
ExplicitTop = 131
ExplicitWidth = 155
Width = 155
end
inherited ImporteIRPF: TcxDBCurrencyEdit
- Left = 640
+ Left = 587
Top = 104
Style.IsFontAssigned = True
- ExplicitLeft = 640
+ ExplicitLeft = 587
ExplicitTop = 104
ExplicitWidth = 56
Width = 56
@@ -638,10 +652,10 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
Width = 153
end
inherited bTiposIVA: TButton
- Left = 309
+ Left = 256
Top = 111
OnClick = frViewTotales1bTiposIVAClick
- ExplicitLeft = 309
+ ExplicitLeft = 256
ExplicitTop = 111
end
inherited cbRecargoEquivalencia: TcxDBCheckBox
@@ -654,6 +668,35 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
ExplicitWidth = 291
Width = 291
end
+ inherited edtRetencion: TcxDBSpinEdit
+ Left = 516
+ Top = 200
+ DataBinding.DataField = 'RETENCION'
+ Style.IsFontAssigned = True
+ ExplicitLeft = 516
+ ExplicitTop = 200
+ end
+ inherited edtImporteRetencion: TcxDBCurrencyEdit
+ Left = 587
+ Top = 200
+ DataBinding.DataField = 'IMPORTE_RETENCION'
+ Style.IsFontAssigned = True
+ ExplicitLeft = 587
+ ExplicitTop = 200
+ ExplicitWidth = 342
+ Width = 342
+ end
+ inherited edtFechaRetencion: TcxDBDateEdit
+ Top = 200
+ DataBinding.DataField = 'FECHA_RETENCION'
+ Style.LookAndFeel.SkinName = ''
+ StyleDisabled.LookAndFeel.SkinName = ''
+ StyleFocused.LookAndFeel.SkinName = ''
+ StyleHot.LookAndFeel.SkinName = ''
+ ExplicitTop = 200
+ ExplicitWidth = 333
+ Width = 333
+ end
inherited dxLayoutControl1Group_Root: TdxLayoutGroup
inherited dxLayoutControl1Group1: TdxLayoutGroup
inherited dxLayoutControl1Group2: TdxLayoutGroup
@@ -662,6 +705,12 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
Visible = False
end
end
+ inherited dxLayoutControl1Item19: TdxLayoutItem
+ Visible = True
+ end
+ inherited dxLayoutControl1Item18: TdxLayoutItem
+ Visible = True
+ end
end
inherited dxLayoutControl1Group5: TdxLayoutGroup
inherited dxLayoutControl1Group3: TdxLayoutGroup
@@ -672,6 +721,12 @@ inherited fEditorFacturaCliente: TfEditorFacturaCliente
Visible = False
end
end
+ inherited dxLayoutControl1Item20: TdxLayoutItem
+ Visible = True
+ end
+ inherited dxLayoutControl1Group12: TdxLayoutGroup
+ Visible = True
+ end
end
end
end
diff --git a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm
index 649ec27..e78eddd 100644
--- a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm
+++ b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm
@@ -162,8 +162,18 @@ inherited frViewFacturasCliente: TfrViewFacturasCliente
DataBinding.FieldName = 'REF_CLI_CONTRATO'
end
object cxGridViewFECHA_VENCIMIENTO: TcxGridDBColumn
+ Caption = 'Fecha vencimiento'
DataBinding.FieldName = 'FECHA_VENCIMIENTO'
end
+ object cxGridViewIMPORTE_RETENIDO: TcxGridDBColumn
+ Caption = 'Imp. Retenci'#243'n'
+ DataBinding.FieldName = 'IMPORTE_RETENCION'
+ PropertiesClassName = 'TcxCurrencyEditProperties'
+ Properties.Alignment.Horz = taRightJustify
+ FooterAlignmentHorz = taRightJustify
+ GroupSummaryAlignment = taRightJustify
+ HeaderAlignmentHorz = taRightJustify
+ end
end
inherited cxGridLevel: TcxGridLevel
Caption = 'Todas'
diff --git a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas
index cdaa845..dc98867 100644
--- a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas
+++ b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas
@@ -63,6 +63,7 @@ type
cxGridViewREF_CONTRATO: TcxGridDBColumn;
cxGridViewFECHA_VENCIMIENTO: TcxGridDBColumn;
cxGridViewREF_CLI_CONTRATO: TcxGridDBColumn;
+ cxGridViewIMPORTE_RETENIDO: TcxGridDBColumn;
procedure cxGridViewStylesGetContentStyle(Sender: TcxCustomGridTableView;
ARecord: TcxCustomGridRecord; AItem: TcxCustomGridTableItem;
out AStyle: TcxStyle);
diff --git a/Source/Servidor/FactuGES_Server.dpr b/Source/Servidor/FactuGES_Server.dpr
index 188592e..3b771d2 100644
--- a/Source/Servidor/FactuGES_Server.dpr
+++ b/Source/Servidor/FactuGES_Server.dpr
@@ -134,15 +134,15 @@ uses
schFormasPagoServer_Intf in '..\Modulos\Formas de pago\Model\schFormasPagoServer_Intf.pas',
schEmpresasClient_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasClient_Intf.pas',
schEmpresasServer_Intf in '..\ApplicationBase\Empresas\Model\schEmpresasServer_Intf.pas',
- schFacturasClienteClient_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteClient_Intf.pas',
- schFacturasClienteServer_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteServer_Intf.pas',
schAlbaranesClienteClient_Intf in '..\Modulos\Albaranes de cliente\Model\schAlbaranesClienteClient_Intf.pas',
schAlbaranesClienteServer_Intf in '..\Modulos\Albaranes de cliente\Model\schAlbaranesClienteServer_Intf.pas',
schPresupuestosClienteClient_Intf in '..\Modulos\Presupuestos de cliente\Model\schPresupuestosClienteClient_Intf.pas',
schPresupuestosClienteServer_Intf in '..\Modulos\Presupuestos de cliente\Model\schPresupuestosClienteServer_Intf.pas',
schContratosClienteClient_Intf in '..\Modulos\Contratos de cliente\Model\schContratosClienteClient_Intf.pas',
schContratosClienteServer_Intf in '..\Modulos\Contratos de cliente\Model\schContratosClienteServer_Intf.pas',
- uNumUtils in '..\Base\Utiles\uNumUtils.pas';
+ uNumUtils in '..\Base\Utiles\uNumUtils.pas',
+ schFacturasClienteClient_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteClient_Intf.pas',
+ schFacturasClienteServer_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteServer_Intf.pas';
{$R *.res}
{$R ..\Servicios\RODLFile.res}
diff --git a/Source/Servidor/FactuGES_Server.dproj b/Source/Servidor/FactuGES_Server.dproj
index 90d7ebb..9f0ab64 100644
--- a/Source/Servidor/FactuGES_Server.dproj
+++ b/Source/Servidor/FactuGES_Server.dproj
@@ -28,7 +28,7 @@
Delphi.Personality
- FalseTrueFalseTrueFalse2650FalseFalseFalseFalseFalse30821252Rodax Software S.L.2.6.5.0FactuGES (Servidor)2.6.5.0miércoles, 07 de mayo de 2014 12:33
+ FalseTrueFalseTrueFalse2660FalseFalseFalseFalseFalse30821252Rodax Software S.L.2.6.6.0FactuGES (Servidor)2.6.6.0lunes, 11 de enero de 2016 13:39
File C:\Documents and Settings\All Users\Documentos\RAD Studio\5.0\Bpl\dxPScxScheduler2LnkD11.bpl not found
FactuGES_Server.dpr
diff --git a/Source/Servidor/FactuGES_Server.res b/Source/Servidor/FactuGES_Server.res
index baa7aa8..bfa81ca 100644
Binary files a/Source/Servidor/FactuGES_Server.res and b/Source/Servidor/FactuGES_Server.res differ