diff --git a/Source/Base/Base.dproj b/Source/Base/Base.dproj
index 59a3917a..88e218eb 100644
--- a/Source/Base/Base.dproj
+++ b/Source/Base/Base.dproj
@@ -44,6 +44,13 @@
Package
FalseTrueFalseLibreria base de FactuGESFalseFalseFalseTrueFalse1000FalseFalseFalseFalseFalse308212521.0.0.01.0.0.0
+
+
+
+
+
+
+
VCL for the Web Design Package for CodeGear RAD Studio
CodeGear WebSnap Components
CodeGear SOAP Components
@@ -58,56 +65,56 @@
MainSource
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
TForm
diff --git a/Source/Base/Controladores/uControllerDetallesBase.pas b/Source/Base/Controladores/uControllerDetallesBase.pas
index 6bef0a55..8f98ad21 100644
--- a/Source/Base/Controladores/uControllerDetallesBase.pas
+++ b/Source/Base/Controladores/uControllerDetallesBase.pas
@@ -14,6 +14,8 @@ const
CTE_DESC_SALTO = 'SALTO DE PAGINA >>';
+ DESGLOSE_IVA = 1.21;
+
type
TIntegerArray = array of Integer;
@@ -32,7 +34,7 @@ type
// procedure Paste;
procedure ActualizarTotales(ADataTable: IDAStronglyTypedDataTable);
- function DarTotalImporteTotal(ADataTable: IDAStronglyTypedDataTable): Double;
+ function DarTotalImporteTotal(ADataTable: IDAStronglyTypedDataTable; const DesglosarIVA: Boolean = False): Double;
function LocalizarPosicion(ADataTable: IDAStronglyTypedDataTable; const APosicion: Integer): Boolean;
function DarListaTiposDetalle: TStringList;
@@ -44,7 +46,7 @@ type
fUpdateCount: Integer;
FImporteSubtotal: Double;
- function CalcularTotales(Modificar: boolean; DataTable: TDADataTable): Double;
+ function CalcularTotales(Modificar: boolean; DataTable: TDADataTable; const DesglosarIVA: Boolean = False): Double;
protected
procedure Renumerar(DataTable: TDADataTable; LocalizaPosicion: Integer);
@@ -56,7 +58,7 @@ type
//Si sobreescribimos este método podremos tener en cuenta otras columnas para el calculo del importe total de un concepto
function CalcularImporteTotalConcepto(DataTable: TDADataTable): Double; virtual;
- procedure TratamientoDetalleConcepto(DataTable: TDADataTable); virtual;
+ procedure TratamientoDetalleConcepto(DataTable: TDADataTable; const DesglosarIVA: Boolean = False); virtual;
procedure CalculoDetalleConcepto(DataTable: TDADataTable; var ImporteAcumulado : Double; var ImporteTotal : Double; const Opcional: Boolean); virtual;
procedure TratamientoDetalleSalto(DataTable: TDADataTable); virtual;
procedure CalculoDetalleSalto(DataTable: TDADataTable; var ImporteAcumulado : Double; var ImporteTotal : Double); virtual;
@@ -88,7 +90,7 @@ type
// procedure Paste;
procedure ActualizarTotales(ADataTable: IDAStronglyTypedDataTable);
- function DarTotalImporteTotal(ADataTable: IDAStronglyTypedDataTable): Double;
+ function DarTotalImporteTotal(ADataTable: IDAStronglyTypedDataTable; const DesglosarIVA: Boolean = False): Double;
function DarListaTiposDetalle: TStringList; virtual;
function LocalizarPosicion(ADataTable: IDAStronglyTypedDataTable; const APosicion: Integer): Boolean;
@@ -153,7 +155,7 @@ begin
Result := FieldByName(CAMPO_CANTIDAD).asFloat * FieldByName(CAMPO_IMPORTE_UNIDAD).AsFloat;
end;
-function TControllerDetallesBase.CalcularTotales(Modificar: boolean; DataTable: TDADataTable): Double;
+function TControllerDetallesBase.CalcularTotales(Modificar: boolean; DataTable: TDADataTable; const DesglosarIVA: Boolean = False): Double;
{
funcion que recalcula todos los detalles de la tabla pasada por parametro y devuelve
la cantidad total de los mismos
@@ -226,7 +228,7 @@ begin
else if (DataTable.FieldByName(CAMPO_TIPO).AsString = TIPO_DETALLE_CONCEPTO) then
begin
if Modificar then
- TratamientoDetalleConcepto(DataTable); //Se podrá sobreescribir para que se tengan en cuenta nuevos campos
+ TratamientoDetalleConcepto(DataTable, DesglosarIVA); //Se podrá sobreescribir para que se tengan en cuenta nuevos campos
if DataTable.FieldByName(CAMPO_VISIBLE).AsBoolean then //Se usa para saber si el concepto se sumará o no como un concepto más del presupuesto
CalculoDetalleConcepto(DataTable, AuxImporteAcumulado, AuxImporteTotal, SemaforoOpcional); //Se podrá sobreescribir para posibles nuevos calculos de los hijos
end
@@ -256,7 +258,6 @@ procedure TControllerDetallesBase.CalculoDetalleConcepto(DataTable: TDADataTable
begin
with DataTable do
begin
-
ImporteAcumulado := ImporteAcumulado + RoundCurrency(FieldByName(CAMPO_IMPORTE_TOTAL).AsCurrency);
// ImporteAcumulado := ImporteAcumulado + FieldByName(CAMPO_IMPORTE_TOTAL).AsFloat;
if not Opcional then
@@ -338,9 +339,12 @@ begin
Result.Values[TIPO_DETALLE_SALTO] := TIPO_DETALLE_SALTO;
end;
-function TControllerDetallesBase.DarTotalImporteTotal(ADataTable: IDAStronglyTypedDataTable): Double;
+function TControllerDetallesBase.DarTotalImporteTotal(ADataTable: IDAStronglyTypedDataTable; const DesglosarIVA: Boolean = False): Double;
begin
- Result := CalcularTotales(False, ADataTable.DataTable);
+ if DesglosarIVA then
+ Result := CalcularTotales(True, ADataTable.DataTable, DesglosarIVA)
+ else
+ Result := CalcularTotales(False, ADataTable.DataTable, DesglosarIVA);
end;
procedure TControllerDetallesBase.Delete(ADataTable: IDAStronglyTypedDataTable; Posicion: TIntegerArray);
@@ -601,11 +605,16 @@ begin
end;
end;
-procedure TControllerDetallesBase.TratamientoDetalleConcepto(DataTable: TDADataTable);
+procedure TControllerDetallesBase.TratamientoDetalleConcepto(DataTable: TDADataTable; const DesglosarIVA: Boolean = False);
begin
with DataTable do
begin
if not Editing then Edit;
+
+ //Si se desglosa IVA hay que quitar el IVA de los Importes Unidad antes de tratar el concepto
+ if DesglosarIVA then
+ DataTable.FieldByName(CAMPO_IMPORTE_UNIDAD).AsCurrency := RoundCurrency(DataTable.FieldByName(CAMPO_IMPORTE_UNIDAD).AsCurrency / DESGLOSE_IVA);
+
//Si alguno de los campos de calculo de total es nulo el total tambien será nulo
if (VarIsNull(FieldByName(CAMPO_CANTIDAD).AsVariant)
or VarIsNull(FieldByName(CAMPO_IMPORTE_UNIDAD).AsVariant))
diff --git a/Source/Cliente/FactuGES.dproj b/Source/Cliente/FactuGES.dproj
index 632369c7..ffdc963e 100644
--- a/Source/Cliente/FactuGES.dproj
+++ b/Source/Cliente/FactuGES.dproj
@@ -52,7 +52,8 @@
Delphi.Personality
VCLApplication
-FalseTrueFalseC:\Archivos de programa\Borland\Delphi7\Bin\TrueFalse5000FalseFalseFalseFalseFalse30821252Rodax Software S.L.5.0.0.0FactuGESFactuGES5.0.0.0
+FalseTrueFalseC:\Archivos de programa\Borland\Delphi7\Bin\TrueFalse5220FalseFalseFalseFalseFalse30821252Rodax Software S.L.5.2.2.0FactuGESFactuGES5.2.2.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.rc b/Source/Cliente/FactuGES.rc
index 0b6de9c2..354d35f8 100644
--- a/Source/Cliente/FactuGES.rc
+++ b/Source/Cliente/FactuGES.rc
@@ -1,7 +1,7 @@
MAINICON ICON "C:\Codigo Acana\Resources\Iconos\Factuges.ico"
1 VERSIONINFO
-FILEVERSION 5,0,0,0
-PRODUCTVERSION 5,0,0,0
+FILEVERSION 5,2,2,0
+PRODUCTVERSION 5,2,2,0
FILEFLAGSMASK 0x3FL
FILEFLAGS 0x00L
FILEOS 0x40004L
@@ -13,10 +13,10 @@ BEGIN
BLOCK "0C0A04E4"
BEGIN
VALUE "CompanyName", "Rodax Software S.L.\0"
- VALUE "FileVersion", "5.0.0.0\0"
+ VALUE "FileVersion", "5.2.2.0\0"
VALUE "InternalName", "FactuGES\0"
VALUE "ProductName", "FactuGES\0"
- VALUE "ProductVersion", "5.0.0.0\0"
+ VALUE "ProductVersion", "5.2.2.0\0"
END
END
BLOCK "VarFileInfo"
diff --git a/Source/Cliente/FactuGES.res b/Source/Cliente/FactuGES.res
index d6960213..7cd60e24 100644
Binary files a/Source/Cliente/FactuGES.res and b/Source/Cliente/FactuGES.res differ
diff --git a/Source/Informes/5/3/InfAlbaranCliente.fr3 b/Source/Informes/5/3/InfAlbaranCliente.fr3
index 8d9b6030..d1a5a9b6 100644
--- a/Source/Informes/5/3/InfAlbaranCliente.fr3
+++ b/Source/Informes/5/3/InfAlbaranCliente.fr3
@@ -1,12 +1,12 @@
-
+
-
+
diff --git a/Source/Informes/5/3/InfFacturaCliente.fr3 b/Source/Informes/5/3/InfFacturaCliente.fr3
index d3654b00..38f9c772 100644
--- a/Source/Informes/5/3/InfFacturaCliente.fr3
+++ b/Source/Informes/5/3/InfFacturaCliente.fr3
@@ -1,5 +1,5 @@
-
+
@@ -9,7 +9,7 @@
-
+
diff --git a/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteController.pas b/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteController.pas
index 6e5adf06..fb8bb5e3 100644
--- a/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteController.pas
+++ b/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteController.pas
@@ -42,8 +42,8 @@ type
function ExtraerSeleccionados(AAlbaran: IBizAlbaranCliente) : IBizAlbaranCliente;
function ElegirAlbaranes(AAlbaran: IBizAlbaranCliente; AMensaje: String; AMultiSelect: Boolean): IBizAlbaranCliente;
- procedure Preview(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
- procedure Print(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+ procedure Preview(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
+ procedure Print(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
procedure EtiquetasPreview(AAlbaran : IBizAlbaranCliente; Const withRefCliente: Boolean);
procedure EtiquetasPrint(AAlbaran : IBizAlbaranCliente; Const withRefCliente: Boolean);
@@ -136,8 +136,8 @@ type
DoPost: Boolean = True) : Boolean;
procedure EnviarAlbaranPorEMail(AAlbaran : IBizAlbaranCliente);
- procedure Preview(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
- procedure Print(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+ procedure Preview(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
+ procedure Print(AAlbaran : IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
procedure EtiquetasPreview(AAlbaran : IBizAlbaranCliente; Const withRefCliente: Boolean);
procedure EtiquetasPrint(AAlbaran : IBizAlbaranCliente; Const withRefCliente: Boolean);
@@ -1003,7 +1003,7 @@ begin
end;
end;
-procedure TAlbaranesClienteController.Preview(AAlbaran: IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+procedure TAlbaranesClienteController.Preview(AAlbaran: IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
var
AReportController : IAlbaranesClienteReportController;
ID_Albaranes: TIntegerList;
@@ -1031,7 +1031,7 @@ begin
else
ID_Albaranes.Add(AAlbaran.ID);
- AReportController.Preview(ID_Albaranes, VerPrecios, VerTrabajos, VerIncidencias);
+ AReportController.Preview(ID_Albaranes, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
finally
AReportController := NIL;
@@ -1039,7 +1039,7 @@ begin
end;
end;
-procedure TAlbaranesClienteController.Print(AAlbaran: IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+procedure TAlbaranesClienteController.Print(AAlbaran: IBizAlbaranCliente; AllItems: Boolean = false; const VerPrecios: Boolean = True; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
var
AReportController : IAlbaranesClienteReportController;
ID_Albaranes: TIntegerList;
@@ -1065,7 +1065,7 @@ begin
else
ID_Albaranes.Add(AAlbaran.ID);
- AReportController.Print(ID_Albaranes, VerPrecios, VerTrabajos, VerIncidencias);
+ AReportController.Print(ID_Albaranes, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
finally
AReportController := NIL;
diff --git a/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteReportController.pas b/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteReportController.pas
index 5a0d579e..9c526330 100644
--- a/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteReportController.pas
+++ b/Source/Modulos/Albaranes de cliente/Controller/uAlbaranesClienteReportController.pas
@@ -10,8 +10,8 @@ uses
type
IAlbaranesClienteReportController = interface(IControllerBase)
['{4BCC7A93-3322-494C-A3FA-118F4B62CB15}']
- procedure Preview(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
- procedure Print(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+ procedure Preview(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
+ procedure Print(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
procedure EtiquetasPreview(const AID : integer; Const withRefCliente: Boolean);
procedure EtiquetasPrint(const AID : integer; Const withRefCliente: Boolean);
function ExportToPDF(const AID: Integer; const AFileName : String = ''; const VerPrecios: Boolean = True): Boolean;
@@ -26,8 +26,8 @@ type
constructor Create; override;
destructor Destroy; override;
- procedure Preview(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
- procedure Print(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+ procedure Preview(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
+ procedure Print(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
procedure EtiquetasPreview(const AID : integer; Const withRefCliente: Boolean);
procedure EtiquetasPrint(const AID : integer; Const withRefCliente: Boolean);
function ExportToPDF(const AID: Integer; const AFileName : String = ''; const VerPrecios: Boolean = True): Boolean;
@@ -135,14 +135,14 @@ begin
end;
end;
-procedure TAlbaranesClienteReportController.Preview(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+procedure TAlbaranesClienteReportController.Preview(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
var
AStream: Binary;
AEditor : IEditorAlbaranesClientePreview;
begin
AEditor := NIL;
- AStream := FDataModule.GetRptAlbaranes(AListaID, VerPrecios, VerTrabajos, VerIncidencias);
+ AStream := FDataModule.GetRptAlbaranes(AListaID, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
try
CreateEditor('EditorAlbaranesClientePreview', IEditorAlbaranesClientePreview, AEditor);
if Assigned(AEditor) then
@@ -163,7 +163,7 @@ begin
end;
end;
-procedure TAlbaranesClienteReportController.Print(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True);
+procedure TAlbaranesClienteReportController.Print(const AListaID : TIntegerList; const VerPrecios: Boolean; const VerTrabajos: Boolean = True; const VerIncidencias: Boolean = True; const VerSoloTotales: Boolean = False);
var
AStream: Binary;
AEditor : IEditorAlbaranesClientePreview;
@@ -172,7 +172,7 @@ begin
ShowHourglassCursor;
try
- AStream := FDataModule.GetRptAlbaranes(AListaID, VerPrecios, VerTrabajos, VerIncidencias);
+ AStream := FDataModule.GetRptAlbaranes(AListaID, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
try
CreateEditor('EditorAlbaranesClientePreview', IEditorAlbaranesClientePreview, AEditor);
if Assigned(AEditor) then
diff --git a/Source/Modulos/Albaranes de cliente/Data/uDataModuleAlbaranesCliente.pas b/Source/Modulos/Albaranes de cliente/Data/uDataModuleAlbaranesCliente.pas
index 555330f7..7032c118 100644
--- a/Source/Modulos/Albaranes de cliente/Data/uDataModuleAlbaranesCliente.pas
+++ b/Source/Modulos/Albaranes de cliente/Data/uDataModuleAlbaranesCliente.pas
@@ -37,9 +37,9 @@ type
function NewItem : IBizAlbaranCliente;
// Report
- function GetRptAlbaranes(const ListaID: TIntegerList; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False): Binary;
+ function GetRptAlbaranes(const ListaID: TIntegerList; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False; const VerSoloTotales: Boolean = False): Binary;
function GetEtiquetas(const AID: Integer; withRefCliente: Boolean): Binary;
- function GetRptPDFAlbaran(const AID: Integer; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False): Binary;
+ function GetRptPDFAlbaran(const AID: Integer; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False; const VerSoloTotales: Boolean = False): Binary;
end;
implementation
@@ -63,26 +63,26 @@ begin
RORemoteService.Message := dmConexion.Message;
end;
-function TDataModuleAlbaranesCliente.GetRptAlbaranes(const ListaID: TIntegerList; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False): Binary;
+function TDataModuleAlbaranesCliente.GetRptAlbaranes(const ListaID: TIntegerList; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False; const VerSoloTotales: Boolean = False): Binary;
var
AParam : TIntegerArray;
begin
AParam := ListaID.ToIntegerArray;
try
- Result := (RORemoteService as IsrvAlbaranesCliente).GenerarInforme(AParam, VerPrecios, VerTrabajos, VerIncidencias);
+ Result := (RORemoteService as IsrvAlbaranesCliente).GenerarInforme(AParam, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
finally
FreeAndNil(AParam);
end;
end;
-function TDataModuleAlbaranesCliente.GetRptPDFAlbaran(const AID: Integer; const VerPrecios, VerTrabajos, VerIncidencias: Boolean): Binary;
+function TDataModuleAlbaranesCliente.GetRptPDFAlbaran(const AID: Integer; const VerPrecios, VerTrabajos, VerIncidencias: Boolean; const VerSoloTotales: Boolean): Binary;
var
AParam : TIntegerArray;
begin
AParam := TIntegerArray.Create;
try
AParam.Add(AID);
- Result := (RORemoteService as IsrvAlbaranesCliente).GenerarInforme(AParam, VerPrecios, VerTrabajos, VerIncidencias);
+ Result := (RORemoteService as IsrvAlbaranesCliente).GenerarInforme(AParam, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
finally
FreeAndNil(AParam);
end;
diff --git a/Source/Modulos/Albaranes de cliente/Model/Data/uIDataModuleAlbaranesClienteReport.pas b/Source/Modulos/Albaranes de cliente/Model/Data/uIDataModuleAlbaranesClienteReport.pas
index 9daafbc9..33e8f3be 100644
--- a/Source/Modulos/Albaranes de cliente/Model/Data/uIDataModuleAlbaranesClienteReport.pas
+++ b/Source/Modulos/Albaranes de cliente/Model/Data/uIDataModuleAlbaranesClienteReport.pas
@@ -8,9 +8,9 @@ uses
type
IDataModuleAlbaranesClienteReport = interface
['{32A52EC9-90F6-4934-9001-015A2579746D}']
- function GetRptAlbaranes(const ListaID: TIntegerList; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False): Binary;
+ function GetRptAlbaranes(const ListaID: TIntegerList; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False; const VerSoloTotales: Boolean = False): Binary;
function GetEtiquetas(const AID: Integer; withRefCliente: Boolean): Binary;
- function GetRptPDFAlbaran(const AID: Integer; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False): Binary;
+ function GetRptPDFAlbaran(const AID: Integer; const VerPrecios: Boolean = False; const VerTrabajos: Boolean = False; const VerIncidencias: Boolean = False; const VerSoloTotales: Boolean = False): Binary;
end;
implementation
diff --git a/Source/Modulos/Albaranes de cliente/Reports/uRptAlbaranesCliente_Server.pas b/Source/Modulos/Albaranes de cliente/Reports/uRptAlbaranesCliente_Server.pas
index 3c4ee351..9f6c301f 100644
--- a/Source/Modulos/Albaranes de cliente/Reports/uRptAlbaranesCliente_Server.pas
+++ b/Source/Modulos/Albaranes de cliente/Reports/uRptAlbaranesCliente_Server.pas
@@ -38,12 +38,13 @@ type
FConnection: IDAConnection;
FVerPrecios: Boolean;
FVerTrabajos: Boolean;
- FVerIncidencias: Boolean;
+ FVerIncidencias: Boolean;
+ FVerSoloTotales: Boolean;
//Genera cada uno de los albaranes a imprimir
procedure _GenerarAlbaran(const ID: Integer);
public
- function GenerarAlbaran(const ListaID : TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
- function GenerarAlbaranEnPDF(const ListaID : TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+ function GenerarAlbaran(const ListaID : TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean; const VerSoloTotales: Boolean): Binary;
+ function GenerarAlbaranEnPDF(const ListaID : TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean; const VerSoloTotales: Boolean): Binary;
function GenerarEtiquetas(const AID : Integer; withRefCliente: Boolean): Binary;
end;
@@ -75,7 +76,7 @@ begin
end;
-function TRptAlbaranesCliente.GenerarAlbaran(const ListaID : TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+function TRptAlbaranesCliente.GenerarAlbaran(const ListaID : TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean; const VerSoloTotales: Boolean): Binary;
var
i: Integer;
begin
@@ -84,6 +85,7 @@ begin
FVerPrecios := VerPrecios;
FVerTrabajos := VerTrabajos;
FVerIncidencias := VerIncidencias;
+ FVerSoloTotales := VerSoloTotales;
//Vamos generando todos y cada uno de los presupuestos recibidos
for i := 0 to ListaID.Count - 1 do
@@ -92,7 +94,7 @@ begin
frxReport.PreviewPages.SaveToStream(Result);
end;
-function TRptAlbaranesCliente.GenerarAlbaranEnPDF(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+function TRptAlbaranesCliente.GenerarAlbaranEnPDF(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean; const VerSoloTotales: Boolean): Binary;
var
i: Integer;
begin
@@ -101,6 +103,7 @@ begin
FVerPrecios := VerPrecios;
FVerTrabajos := VerTrabajos;
FVerIncidencias := VerIncidencias;
+ FVerSoloTotales := VerSoloTotales;
//Vamos generando todos y cada uno de los presupuestos recibidos
for i := 0 to ListaID.Count - 1 do
@@ -133,7 +136,8 @@ begin
frxReport.LoadFromFile(AInforme, True);
frxReport.Variables.Variables['VerPrecios'] := FVerPrecios;
frxReport.Variables.Variables['VerTrabajos'] := FVerTrabajos;
- frxReport.Variables.Variables['VerIncidencias'] := FVerIncidencias;
+ frxReport.Variables.Variables['VerIncidencias'] := FVerIncidencias;
+ frxReport.Variables.Variables['VerSoloTotales'] := FVerSoloTotales;
frxReport.ReportOptions.Name := 'Albarán de cliente ' + tbl_Cabecera.FieldByName('REFERENCIA').AsString;
frxReport.PrepareReport(False);
finally
diff --git a/Source/Modulos/Albaranes de cliente/Servidor/srvAlbaranesCliente_Impl.pas b/Source/Modulos/Albaranes de cliente/Servidor/srvAlbaranesCliente_Impl.pas
index 448d5e7c..242b161a 100644
--- a/Source/Modulos/Albaranes de cliente/Servidor/srvAlbaranesCliente_Impl.pas
+++ b/Source/Modulos/Albaranes de cliente/Servidor/srvAlbaranesCliente_Impl.pas
@@ -32,7 +32,7 @@ type
procedure DARemoteServiceCreate(Sender: TObject);
protected
{ IsrvAlbaranesCliente methods }
- function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+ function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean; const VerSoloTotales: Boolean): Binary;
function GenerarInformeEtiquetas(const ID: Integer; const withRefCliente: Boolean): Binary;
end;
@@ -81,13 +81,13 @@ begin
ConnectionName := dmServer.ConnectionName;
end;
-function TsrvAlbaranesCliente.GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+function TsrvAlbaranesCliente.GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean; const VerSoloTotales: Boolean): Binary;
var
AReportGenerator : TRptAlbaranesCliente;
begin
AReportGenerator := TRptAlbaranesCliente.Create(nil);
try
- Result := AReportGenerator.GenerarAlbaran(ListaID, VerPrecios, VerTrabajos, VerIncidencias);
+ Result := AReportGenerator.GenerarAlbaran(ListaID, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
finally
FreeAndNIL(AReportGenerator);
end;
diff --git a/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.dfm b/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.dfm
index 2a66321e..3dd25b0a 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.dfm
+++ b/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.dfm
@@ -3,7 +3,7 @@ inherited fDialogOpcionesImpresionAlbaranesCliente: TfDialogOpcionesImpresionAlb
ClientHeight = 237
ClientWidth = 393
ExplicitWidth = 399
- ExplicitHeight = 269
+ ExplicitHeight = 265
PixelsPerInch = 96
TextHeight = 13
inherited Bevel2: TBevel
@@ -47,12 +47,13 @@ inherited fDialogOpcionesImpresionAlbaranesCliente: TfDialogOpcionesImpresionAlb
inherited pnlCuerpo: TPanel
Width = 393
Height = 127
+ ExplicitTop = 70
ExplicitWidth = 393
ExplicitHeight = 127
object cbVerPrecios: TCheckBox
AlignWithMargins = True
Left = 50
- Top = 29
+ Top = 6
Width = 415
Height = 17
Caption = 'Mostrar los precios'
@@ -82,6 +83,15 @@ inherited fDialogOpcionesImpresionAlbaranesCliente: TfDialogOpcionesImpresionAlb
State = cbChecked
TabOrder = 2
end
+ object cbVerSoloTotales: TCheckBox
+ AlignWithMargins = True
+ Left = 50
+ Top = 29
+ Width = 415
+ Height = 17
+ Caption = 'Mostrar solo precios totales'
+ TabOrder = 3
+ end
end
inherited ActionListDialog: TActionList
inherited actAceptar: TAction
diff --git a/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.pas b/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.pas
index 70963d07..ad5422f0 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.pas
+++ b/Source/Modulos/Albaranes de cliente/Views/uDialogOpcionesImpresionAlbaranesCliente.pas
@@ -11,17 +11,18 @@ type
cbVerPrecios: TCheckBox;
cbVerIncidencias: TCheckBox;
cbVerTrabajos: TCheckBox;
+ cbVerSoloTotales: TCheckBox;
procedure actAceptarExecute(Sender: TObject);
procedure actCancelarExecute(Sender: TObject);
end;
- function ElegirOpcionesImpresionAlbaranCliente(var AVerPrecios : Boolean; var AVerTrabajos : Boolean; var AVerIncidencias : Boolean): Boolean;
+ function ElegirOpcionesImpresionAlbaranCliente(var AVerPrecios : Boolean; var AVerTrabajos : Boolean; var AVerIncidencias : Boolean; var AVerSoloTotales: Boolean): Boolean;
implementation
{$R *.dfm}
-function ElegirOpcionesImpresionAlbaranCliente(var AVerPrecios : Boolean; var AVerTrabajos : Boolean; var AVerIncidencias : Boolean): Boolean;
+function ElegirOpcionesImpresionAlbaranCliente(var AVerPrecios : Boolean; var AVerTrabajos : Boolean; var AVerIncidencias : Boolean; var AVerSoloTotales: Boolean): Boolean;
var
AEditor : TfDialogOpcionesImpresionAlbaranesCliente;
begin
@@ -30,6 +31,7 @@ begin
AEditor.cbVerPrecios.Checked := AVerPrecios;
AEditor.cbVerTrabajos.Checked := AVerTrabajos;
AEditor.cbVerIncidencias.Checked := AVerIncidencias;
+ AEditor.cbVerSoloTotales.Checked := AVerSoloTotales;
Result := (AEditor.ShowModal = mrOk);
@@ -38,6 +40,7 @@ begin
AVerPrecios := AEditor.cbVerPrecios.Checked;
AVerTrabajos := AEditor.cbVerTrabajos.Checked;
AVerIncidencias := AEditor.cbVerIncidencias.Checked;
+ AVerSoloTotales := AEditor.cbVerSoloTotales.Checked;
end;
finally
AEditor.Release;
diff --git a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.dfm b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.dfm
index f22a9b1b..aa885573 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.dfm
+++ b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.dfm
@@ -5,14 +5,13 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
ClientHeight = 585
ClientWidth = 765
OnClose = CustomEditorClose
- ExplicitWidth = 773
- ExplicitHeight = 619
+ ExplicitWidth = 781
+ ExplicitHeight = 623
PixelsPerInch = 96
TextHeight = 13
inherited JvNavPanelHeader: TJvNavPanelHeader
Width = 765
Caption = 'Nuevo albar'#225'n de cliente'
- ExplicitTop = 49
ExplicitWidth = 765
inherited Image1: TImage
Left = 738
@@ -125,12 +124,18 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
0000000049454E44AE426082}
ExplicitLeft = 735
end
+ inherited lblDesbloquear: TcxLabel
+ Left = 640
+ ExplicitLeft = 640
+ AnchorX = 685
+ AnchorY = 14
+ end
end
inherited TBXDock: TTBXDock
Width = 765
ExplicitWidth = 765
inherited tbxMain: TTBXToolbar
- ExplicitWidth = 488
+ ExplicitWidth = 518
inherited TBXItem2: TTBXItem
Visible = False
end
@@ -157,29 +162,32 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
end
inherited pgPaginas: TPageControl
Width = 759
- Height = 376
+ Height = 374
TabOrder = 1
OnChanging = pgPaginasChanging
+ ExplicitTop = 111
ExplicitWidth = 759
- ExplicitHeight = 376
+ ExplicitHeight = 374
inherited pagGeneral: TTabSheet
ExplicitLeft = 4
ExplicitTop = 24
ExplicitWidth = 751
- ExplicitHeight = 348
+ ExplicitHeight = 346
inline frViewAlbaranCliente1: TfrViewAlbaranCliente
Left = 0
Top = 0
Width = 751
- Height = 348
+ Height = 346
Align = alClient
TabOrder = 0
ReadOnly = False
- ExplicitLeft = -196
- ExplicitTop = -296
+ ExplicitWidth = 751
+ ExplicitHeight = 346
inherited dxLayoutControl1: TdxLayoutControl
Width = 751
- Height = 348
+ Height = 346
+ ExplicitWidth = 751
+ ExplicitHeight = 346
inherited Label1: TLabel
Width = 299
ExplicitWidth = 299
@@ -197,14 +205,14 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
ExplicitWidth = 442
inherited dxLayoutControl1: TdxLayoutControl
Width = 442
+ inherited Bevel1: TBevel
+ Width = 266
+ ExplicitWidth = 266
+ end
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 224
Width = 224
end
- inherited edtNIFCIF: TcxDBTextEdit
- ExplicitWidth = 103
- Width = 103
- end
inherited bVerFichaCliente: TBitBtn
Left = 82
ExplicitLeft = 82
@@ -221,12 +229,6 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
ExplicitWidth = 193
Width = 193
end
- inherited edtReferencia: TcxDBTextEdit
- Left = 204
- ExplicitLeft = 204
- ExplicitWidth = 103
- Width = 103
- end
end
end
inherited eCalle: TcxDBTextEdit
@@ -321,7 +323,7 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
Left = 0
Top = 0
Width = 751
- Height = 348
+ Height = 346
Align = alClient
BiDiMode = bdLeftToRight
Font.Charset = DEFAULT_CHARSET
@@ -334,22 +336,24 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
TabOrder = 0
ReadOnly = False
ExplicitWidth = 751
- ExplicitHeight = 348
+ ExplicitHeight = 346
inherited ToolBar1: TToolBar
Width = 751
ExplicitWidth = 751
end
inherited cxGrid: TcxGrid
Width = 751
- Height = 276
+ Height = 274
+ ExplicitTop = 72
ExplicitWidth = 751
- ExplicitHeight = 276
+ ExplicitHeight = 274
end
inherited TBXDock1: TTBXDock
Width = 751
+ ExplicitTop = 46
ExplicitWidth = 751
inherited TBXToolbar1: TTBXToolbar
- ExplicitWidth = 548
+ ExplicitWidth = 597
end
end
end
@@ -373,7 +377,7 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 0
- Height = 348
+ Height = 346
Width = 751
end
end
@@ -384,7 +388,7 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
Left = 0
Top = 0
Width = 751
- Height = 348
+ Height = 346
Align = alClient
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
@@ -395,7 +399,7 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
TabOrder = 0
ReadOnly = False
ExplicitWidth = 751
- ExplicitHeight = 348
+ ExplicitHeight = 346
inherited pnlSup: TPanel
Width = 751
ExplicitWidth = 751
@@ -405,13 +409,13 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
end
inherited GroupBox1: TGroupBox
Width = 751
- Height = 320
+ Height = 318
ExplicitWidth = 751
- ExplicitHeight = 320
+ ExplicitHeight = 318
inherited eIncidencias: TcxDBMemo
ExplicitWidth = 747
- ExplicitHeight = 303
- Height = 303
+ ExplicitHeight = 301
+ Height = 301
Width = 747
end
end
@@ -614,6 +618,7 @@ inherited fEditorAlbaranCliente: TfEditorAlbaranCliente
end
inherited PnlComentario: TPanel [5]
Width = 765
+ ExplicitTop = 78
ExplicitWidth = 765
inherited lbComentario: TLabel
Width = 755
diff --git a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.pas b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.pas
index 8a560497..dfc79215 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.pas
+++ b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranCliente.pas
@@ -13,7 +13,7 @@ uses
uViewIncidencias, uAlbaranesClienteController, uViewDetallesBase, uViewDetallesAlbaranCliente,
dxLayoutLookAndFeels, JvExComCtrls, JvStatusBar, uViewTotales,
uIEditorAlbaranCliente, uBizAlbaranesCliente, uViewAlbaranCliente,
- uViewDetallesDTO, uViewDetallesArticulos, uDAInterfaces;
+ uViewDetallesDTO, uViewDetallesArticulos, uDAInterfaces, cxLabel;
type
TfEditorAlbaranCliente = class(TfEditorDBItem, IEditorAlbaranCliente)
@@ -231,15 +231,17 @@ var
VerPrecios: Boolean;
VerTrabajos: Boolean;
VerIncidencias: Boolean;
+ VerSoloTotales: Boolean;
begin
inherited;
VerPrecios := True;
VerTrabajos := True;
VerIncidencias := True;
+ VerSoloTotales := False;
- if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias) then
- FController.Print(FAlbaran, False, VerPrecios, VerTrabajos, VerIncidencias);
+ if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales) then
+ FController.Print(FAlbaran, False, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
end;
procedure TfEditorAlbaranCliente.OnClienteChanged(Sender: TObject);
@@ -325,15 +327,17 @@ var
VerPrecios: Boolean;
VerTrabajos: Boolean;
VerIncidencias: Boolean;
+ VerSoloTotales: Boolean;
begin
inherited;
VerPrecios := True;
VerTrabajos := True;
VerIncidencias := True;
+ VerSoloTotales := False;
- if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias) then
- FController.Preview(FAlbaran, False, VerPrecios, VerTrabajos, VerIncidencias);
+ if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales) then
+ FController.Preview(FAlbaran, False, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
end;
procedure TfEditorAlbaranCliente.RecalcularPortePorUnidad;
diff --git a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.dfm b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.dfm
index 8d428f76..b51b3ecd 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.dfm
+++ b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.dfm
@@ -2,6 +2,7 @@ inherited fEditorAlbaranesCliente: TfEditorAlbaranesCliente
Caption = 'Lista de albaranes de cliente'
ClientWidth = 583
ExplicitWidth = 591
+ ExplicitHeight = 240
PixelsPerInch = 96
TextHeight = 13
inherited JvNavPanelHeader: TJvNavPanelHeader
@@ -129,7 +130,7 @@ inherited fEditorAlbaranesCliente: TfEditorAlbaranesCliente
end
end
inherited tbxFiltro: TTBXToolbar
- ExplicitWidth = 356
+ ExplicitWidth = 362
inherited lblAno: TTBXLabelItem
Visible = True
end
@@ -144,10 +145,10 @@ inherited fEditorAlbaranesCliente: TfEditorAlbaranesCliente
ExplicitWidth = 583
end
inherited TBXTMain2: TTBXToolbar
- Left = 356
+ Left = 362
Visible = True
- ExplicitLeft = 356
- ExplicitWidth = 129
+ ExplicitLeft = 362
+ ExplicitWidth = 130
object TBXItem42: TTBXItem
Action = actEnviar
DisplayMode = nbdmImageAndText
diff --git a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.pas b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.pas
index 44e24a4d..508cfbf2 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.pas
+++ b/Source/Modulos/Albaranes de cliente/Views/uEditorAlbaranesCliente.pas
@@ -384,6 +384,7 @@ var
VerPrecios: Boolean;
VerTrabajos: Boolean;
VerIncidencias: Boolean;
+ VersoloTotales: Boolean;
begin
AAlbaranes := Nil;
@@ -391,6 +392,7 @@ begin
VerPrecios := True;
VerTrabajos := True;
VerIncidencias := True;
+ VerSoloTotales := False;
if MultiSelect and Assigned(ViewGrid) then
AllItems := (ViewGrid.NumSeleccionados > 1);
@@ -417,8 +419,8 @@ begin
AAlbaranes := Albaranes;
if Assigned(AAlbaranes) then
- if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias) then
- FController.Print(AAlbaranes, AllItems, VerPrecios, VerTrabajos, VerIncidencias);
+ if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales) then
+ FController.Print(AAlbaranes, AllItems, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
end;
end;
end;
@@ -487,6 +489,7 @@ var
VerPrecios: Boolean;
VerTrabajos: Boolean;
VerIncidencias: Boolean;
+ VerSoloTotales: Boolean;
begin
AAlbaranes := Nil;
@@ -494,6 +497,7 @@ begin
VerPrecios := True;
VerTrabajos := True;
VerIncidencias := True;
+ VerSoloTotales := False;
if MultiSelect and Assigned(ViewGrid) then
AllItems := (ViewGrid.NumSeleccionados > 1);
@@ -520,8 +524,8 @@ begin
AAlbaranes := Albaranes;
if Assigned(AAlbaranes) then
- if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias) then
- FController.Preview(AAlbaranes, AllItems, VerPrecios, VerTrabajos, VerIncidencias);
+ if ElegirOpcionesImpresionAlbaranCliente(VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales) then
+ FController.Preview(AAlbaranes, AllItems, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
end;
end;
end;
diff --git a/Source/Modulos/Albaranes de cliente/Views/uViewAlbaranCliente.dfm b/Source/Modulos/Albaranes de cliente/Views/uViewAlbaranCliente.dfm
index d53b0135..d53fdf99 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uViewAlbaranCliente.dfm
+++ b/Source/Modulos/Albaranes de cliente/Views/uViewAlbaranCliente.dfm
@@ -102,14 +102,14 @@ inherited frViewAlbaranCliente: TfrViewAlbaranCliente
Height = 221
ExplicitWidth = 442
ExplicitHeight = 221
+ inherited Bevel1: TBevel
+ Width = 266
+ ExplicitWidth = 266
+ end
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 224
Width = 224
end
- inherited edtNIFCIF: TcxDBTextEdit
- ExplicitWidth = 103
- Width = 103
- end
inherited bVerFichaCliente: TBitBtn
Left = 160
ExplicitLeft = 160
@@ -126,12 +126,6 @@ inherited frViewAlbaranCliente: TfrViewAlbaranCliente
ExplicitWidth = 193
Width = 193
end
- inherited edtReferencia: TcxDBTextEdit
- Left = 242
- ExplicitLeft = 242
- ExplicitWidth = 103
- Width = 103
- end
end
inherited ActionList1: TActionList
Left = 306
diff --git a/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.dfm b/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.dfm
index 84fbc349..f2e95f11 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.dfm
+++ b/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.dfm
@@ -20,8 +20,15 @@ inherited frViewDatosYSeleccionClienteAlbaran: TfrViewDatosYSeleccionClienteAlba
DesignSize = (
579
220)
+ object Bevel1: TBevel
+ Left = 114
+ Top = 68
+ Width = 266
+ Height = 13
+ Shape = bsBottomLine
+ end
object edtlNombre: TcxDBTextEdit
- Left = 66
+ Left = 114
Top = 41
Anchors = [akLeft, akTop, akRight]
AutoSize = False
@@ -42,28 +49,6 @@ inherited frViewDatosYSeleccionClienteAlbaran: TfrViewDatosYSeleccionClienteAlba
Height = 21
Width = 224
end
- object edtNIFCIF: TcxDBTextEdit
- Left = 66
- Top = 68
- Anchors = [akLeft, akTop, akRight]
- AutoSize = False
- DataBinding.DataField = 'NIF_CIF'
- DataBinding.DataSource = dsCliente
- ParentFont = False
- Properties.ReadOnly = True
- Properties.UseLeftAlignmentOnEditing = False
- Style.BorderColor = clWindowFrame
- Style.BorderStyle = ebs3D
- Style.HotTrack = False
- Style.LookAndFeel.NativeStyle = True
- StyleDisabled.LookAndFeel.NativeStyle = True
- StyleDisabled.TextColor = clWindowText
- StyleFocused.LookAndFeel.NativeStyle = True
- StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 3
- Height = 21
- Width = 103
- end
object bElegirCliente: TBitBtn
Left = 10
Top = 10
@@ -154,12 +139,12 @@ inherited frViewDatosYSeleccionClienteAlbaran: TfrViewDatosYSeleccionClienteAlba
end
object bVerFichaCliente: TBitBtn
Left = 377
- Top = 181
+ Top = 174
Width = 192
Height = 25
Action = actVerContacto
Caption = 'Ver ficha completa del cliente...'
- TabOrder = 8
+ TabOrder = 6
Glyph.Data = {
36040000424D3604000000000000360000002800000010000000100000000100
2000000000000004000000000000000000000000000000000000FF00FF00FF00
@@ -197,8 +182,35 @@ inherited frViewDatosYSeleccionClienteAlbaran: TfrViewDatosYSeleccionClienteAlba
FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00FF00}
end
object edtDireccion: TcxMemo
- Left = 66
- Top = 95
+ Left = 114
+ Top = 88
+ Style.BorderColor = clWindowFrame
+ Style.BorderStyle = ebs3D
+ Style.HotTrack = False
+ Style.LookAndFeel.Kind = lfStandard
+ Style.LookAndFeel.NativeStyle = 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 = 3
+ Height = 53
+ Width = 437
+ end
+ object bElegirDireccion: TButton
+ Left = 546
+ Top = 88
+ Width = 23
+ Height = 25
+ Action = actElegirDireccion
+ TabOrder = 4
+ end
+ object edtTelefonos: TcxTextEdit
+ Left = 114
+ Top = 147
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
@@ -212,57 +224,8 @@ inherited frViewDatosYSeleccionClienteAlbaran: TfrViewDatosYSeleccionClienteAlba
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 5
- Height = 53
- Width = 437
- end
- object bElegirDireccion: TButton
- Left = 546
- Top = 95
- Width = 23
- Height = 25
- Action = actElegirDireccion
- TabOrder = 6
- end
- object edtTelefonos: TcxTextEdit
- Left = 66
- Top = 154
- Style.BorderColor = clWindowFrame
- Style.BorderStyle = ebs3D
- Style.HotTrack = False
- Style.LookAndFeel.Kind = lfStandard
- Style.LookAndFeel.NativeStyle = 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 = 7
Width = 302
end
- object edtReferencia: TcxDBTextEdit
- Left = 349
- Top = 68
- Anchors = [akLeft, akTop, akRight]
- AutoSize = False
- DataBinding.DataField = 'REFERENCIA'
- DataBinding.DataSource = dsCliente
- ParentFont = False
- Properties.ReadOnly = True
- Properties.UseLeftAlignmentOnEditing = False
- Style.BorderColor = clWindowFrame
- Style.BorderStyle = ebs3D
- Style.HotTrack = False
- Style.LookAndFeel.NativeStyle = True
- StyleDisabled.LookAndFeel.NativeStyle = True
- StyleDisabled.TextColor = clWindowText
- StyleFocused.LookAndFeel.NativeStyle = True
- StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 4
- Height = 21
- Width = 103
- end
object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False
Hidden = True
@@ -296,25 +259,10 @@ inherited frViewDatosYSeleccionClienteAlbaran: TfrViewDatosYSeleccionClienteAlba
Control = edtlNombre
ControlOptions.ShowBorder = False
end
- object dxLayoutControl1Group3: TdxLayoutGroup
- ShowCaption = False
- Hidden = True
- LayoutDirection = ldHorizontal
- ShowBorder = False
- object dxLayoutControl1Item2: TdxLayoutItem
- AutoAligns = [aaVertical]
- AlignHorz = ahClient
- Caption = 'NIF/CIF:'
- Control = edtNIFCIF
- ControlOptions.ShowBorder = False
- end
- object dxLayoutControl1Item11: TdxLayoutItem
- AutoAligns = [aaVertical]
- AlignHorz = ahClient
- Caption = 'Referencia:'
- Control = edtReferencia
- ControlOptions.ShowBorder = False
- end
+ object dxLayoutControl1Item2: TdxLayoutItem
+ Caption = 'Direcci'#243'n de entrega'
+ Control = Bevel1
+ ControlOptions.ShowBorder = False
end
object dxLayoutControl1Group2: TdxLayoutGroup
ShowCaption = False
diff --git a/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.pas b/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.pas
index c4692da4..c39bfbb3 100644
--- a/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.pas
+++ b/Source/Modulos/Albaranes de cliente/Views/uViewDatosYSeleccionClienteAlbaran.pas
@@ -51,8 +51,6 @@ type
dxLayoutControl1: TdxLayoutControl;
dxLayoutControl1Item1: TdxLayoutItem;
edtlNombre: TcxDBTextEdit;
- dxLayoutControl1Item2: TdxLayoutItem;
- edtNIFCIF: TcxDBTextEdit;
bElegirCliente: TBitBtn;
dxLayoutControl1Item7: TdxLayoutItem;
bNuevoCliente: TBitBtn;
@@ -69,10 +67,9 @@ type
dxLayoutControl1Item5: TdxLayoutItem;
dxLayoutControl1Item10: TdxLayoutItem;
edtTelefonos: TcxTextEdit;
- dxLayoutControl1Item11: TdxLayoutItem;
- edtReferencia: TcxDBTextEdit;
dxLayoutControl1Group6: TdxLayoutGroup;
- dxLayoutControl1Group3: TdxLayoutGroup;
+ dxLayoutControl1Item2: TdxLayoutItem;
+ Bevel1: TBevel;
procedure actElegirContactoExecute(Sender: TObject);
procedure actAnadirContactoExecute(Sender: TObject);
procedure actVerContactoUpdate(Sender: TObject);
@@ -182,9 +179,9 @@ begin
FDireccionesController := TDireccionesContactoController.Create;
edtlNombre.Enabled := False;
- edtNIFCIF.Enabled := False;
+// edtNIFCIF.Enabled := False;
edtDireccion.Enabled := False;
- edtReferencia.Enabled := False;
+// edtReferencia.Enabled := False;
edtTelefonos.Enabled := False;
end;
@@ -242,7 +239,7 @@ begin
with FAlbaran do
begin
- CALLE := ADireccion.CALLE;
+ CALLE := ADireccion.NOMBRE + #13 + ADireccion.CALLE;
POBLACION := ADireccion.POBLACION;
CODIGO_POSTAL := ADireccion.CODIGO_POSTAL;
PROVINCIA := ADireccion.PROVINCIA;
diff --git a/Source/Modulos/Articulos/Views/uViewDetallesArticulos.dfm b/Source/Modulos/Articulos/Views/uViewDetallesArticulos.dfm
index dbc6a354..06bc6a98 100644
--- a/Source/Modulos/Articulos/Views/uViewDetallesArticulos.dfm
+++ b/Source/Modulos/Articulos/Views/uViewDetallesArticulos.dfm
@@ -1,67 +1,94 @@
inherited frViewDetallesArticulos: TfrViewDetallesArticulos
+ Width = 943
+ Height = 463
ParentBiDiMode = False
OnShow = CustomViewShow
inherited ToolBar1: TToolBar
+ Width = 943
+ Height = 24
inherited ToolButton4: TToolButton
- Wrap = True
+ ExplicitWidth = 57
end
inherited ToolButton14: TToolButton
- Left = 0
- Top = 22
+ Left = 335
Wrap = False
- ExplicitLeft = 0
- ExplicitTop = 22
+ ExplicitLeft = 335
end
inherited FontName: TJvFontComboBox
- Left = 34
- ExplicitLeft = 34
+ Left = 369
+ Top = 0
+ ExplicitLeft = 369
+ ExplicitTop = 0
end
inherited FontSize: TEdit
- Left = 179
+ Left = 514
+ Top = 0
Width = 42
- ExplicitLeft = 179
+ ExplicitLeft = 514
+ ExplicitTop = 0
ExplicitWidth = 42
end
inherited UpDown1: TUpDown
- Left = 221
+ Left = 556
+ Top = 0
Width = 17
- ExplicitLeft = 221
+ ExplicitLeft = 556
+ ExplicitTop = 0
ExplicitWidth = 17
end
inherited ToolButton13: TToolButton
- Left = 238
- ExplicitLeft = 238
+ Left = 573
+ Top = 0
+ ExplicitLeft = 573
+ ExplicitTop = 0
end
inherited ToolButton6: TToolButton
- Left = 246
- ExplicitLeft = 246
+ Left = 581
+ Top = 0
+ ExplicitLeft = 581
+ ExplicitTop = 0
end
inherited ToolButton7: TToolButton
- Left = 280
- ExplicitLeft = 280
+ Left = 615
+ Top = 0
+ ExplicitLeft = 615
+ ExplicitTop = 0
end
inherited ToolButton8: TToolButton
- Left = 314
- ExplicitLeft = 314
+ Left = 649
+ Top = 0
+ ExplicitLeft = 649
+ ExplicitTop = 0
end
inherited ToolButton12: TToolButton
- Left = 348
- ExplicitLeft = 348
+ Left = 683
+ Top = 0
+ ExplicitLeft = 683
+ ExplicitTop = 0
end
inherited ToolButton9: TToolButton
- Left = 356
- ExplicitLeft = 356
+ Left = 691
+ Top = 0
+ ExplicitLeft = 691
+ ExplicitTop = 0
end
inherited ToolButton10: TToolButton
- Left = 390
- ExplicitLeft = 390
+ Left = 725
+ Top = 0
+ ExplicitLeft = 725
+ ExplicitTop = 0
end
inherited ToolButton11: TToolButton
- Left = 424
- ExplicitLeft = 424
+ Left = 759
+ Top = 0
+ ExplicitLeft = 759
+ ExplicitTop = 0
end
end
inherited cxGrid: TcxGrid
+ Top = 50
+ Width = 943
+ Height = 413
inherited cxGridView: TcxGridDBTableView
inherited cxGridViewTIPO: TcxGridDBColumn
Visible = False
@@ -118,12 +145,19 @@ inherited frViewDetallesArticulos: TfrViewDetallesArticulos
end
end
inherited TBXDock1: TTBXDock
+ Top = 24
+ Width = 943
inherited TBXToolbar1: TTBXToolbar
- ExplicitWidth = 451
+ ExplicitWidth = 597
object TBXItem12: TTBXItem [0]
Action = actAnadirArticulos
DisplayMode = nbdmImageAndText
end
+ object TBXSeparatorItem12: TTBXSeparatorItem
+ end
+ object TBXItem23: TTBXItem
+ Action = actDesglosarIVA
+ end
end
end
inherited ActionListContenido: TActionList
@@ -134,6 +168,13 @@ inherited frViewDetallesArticulos: TfrViewDetallesArticulos
OnExecute = actAnadirArticulosExecute
OnUpdate = actAnadirArticulosUpdate
end
+ object actDesglosarIVA: TAction
+ Caption = 'Desglosar IVA'
+ Enabled = False
+ Visible = False
+ OnExecute = actDesglosarIVAExecute
+ OnUpdate = actDesglosarIVAUpdate
+ end
end
inherited ContenidoImageList: TPngImageList
PngImages = <
diff --git a/Source/Modulos/Articulos/Views/uViewDetallesArticulos.pas b/Source/Modulos/Articulos/Views/uViewDetallesArticulos.pas
index 0a1ae677..4bb18d37 100644
--- a/Source/Modulos/Articulos/Views/uViewDetallesArticulos.pas
+++ b/Source/Modulos/Articulos/Views/uViewDetallesArticulos.pas
@@ -24,6 +24,9 @@ type
cxGridViewREFERENCIA_PROVEEDOR: TcxGridDBColumn;
actAnadirArticulos: TAction;
TBXItem12: TTBXItem;
+ actDesglosarIVA: TAction;
+ TBXItem23: TTBXItem;
+ TBXSeparatorItem12: TTBXSeparatorItem;
procedure CustomViewCreate(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject);
procedure actAnadirArticulosExecute(Sender: TObject);
@@ -31,6 +34,8 @@ type
procedure OnValidateReferencia(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
procedure OnValidateReferenciaProveedor(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
procedure CustomViewShow(Sender: TObject);
+ procedure actDesglosarIVAExecute(Sender: TObject);
+ procedure actDesglosarIVAUpdate(Sender: TObject);
protected
procedure AnadirArticulosInterno; virtual;
@@ -133,6 +138,18 @@ begin
(Sender as TAction).Enabled := actAnadir.Enabled;
end;
+procedure TfrViewDetallesArticulos.actDesglosarIVAExecute(Sender: TObject);
+begin
+ inherited;
+//
+end;
+
+procedure TfrViewDetallesArticulos.actDesglosarIVAUpdate(Sender: TObject);
+begin
+ inherited;
+//
+end;
+
function TfrViewDetallesArticulos.AnadirArticulo(pReferencia: String; TipoReferencia: TEnumReferencia): Boolean;
begin
Result := (Controller as IControllerDetallesArticulos).AnadirArticulo(Detalles, pReferencia, TipoReferencia);
diff --git a/Source/Modulos/Contratos de cliente/Controller/uContratosClienteController.pas b/Source/Modulos/Contratos de cliente/Controller/uContratosClienteController.pas
index f9b53ac9..49a5015b 100644
--- a/Source/Modulos/Contratos de cliente/Controller/uContratosClienteController.pas
+++ b/Source/Modulos/Contratos de cliente/Controller/uContratosClienteController.pas
@@ -465,7 +465,7 @@ begin
ID_INSTALADORIsNull := True;
NOMBRE_INSTALADORIsNull := True;
end;
- Result.AsignarVendedor;
+ Result.AsignarPresupuestador;
Result.Post;
finally
HideHourglassCursor;
@@ -616,10 +616,23 @@ procedure TContratosClienteController.VerListadoBeneficios;
var
AContratosClienteBeneficios: IBizContratosClienteBeneficios;
AEditor : IEditorContratosClienteBeneficios;
+ Condicion: TDAWhereExpression;
begin
AEditor := NIL;
AContratosClienteBeneficios := FDataModule.GetContratosClienteBeneficios;
+ // Filtrar los contratos actuales por empresa
+ with AContratosClienteBeneficios.DataTable.DynamicWhere do
+ begin
+ // (ID_EMPRESA >= ID)
+ Condicion := NewBinaryExpression(NewField('', fld_ContratosClienteID_EMPRESA), NewConstant(AppFactuGES.EmpresaActiva.ID, datInteger), dboEqual);
+
+ if IsEmpty then
+ Expression := Condicion
+ else
+ Expression := NewBinaryExpression(Expression, Condicion, dboAnd);
+ end;
+
CreateEditor('EditorContratosClienteBeneficios', IEditorContratosClienteBeneficios, AEditor);
if Assigned(AEditor) then
diff --git a/Source/Modulos/Contratos de cliente/Data/uDataModuleContratosCliente.dfm b/Source/Modulos/Contratos de cliente/Data/uDataModuleContratosCliente.dfm
index 8ae6e96a..71f09809 100644
--- a/Source/Modulos/Contratos de cliente/Data/uDataModuleContratosCliente.dfm
+++ b/Source/Modulos/Contratos de cliente/Data/uDataModuleContratosCliente.dfm
@@ -359,6 +359,27 @@ inherited DataModuleContratosCliente: TDataModuleContratosCliente
Name = 'NOMBRE_INSTALADOR'
DataType = datString
Size = 255
+ ServerAutoRefresh = True
+ end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ end
+ item
+ Name = 'PRESUPUESTADOR'
+ DataType = datString
+ Size = 255
+ ServerAutoRefresh = True
+ end
+ item
+ Name = 'ID_SEGUIDOR'
+ DataType = datInteger
+ end
+ item
+ Name = 'SEGUIDOR'
+ DataType = datString
+ Size = 255
+ ServerAutoRefresh = True
end>
Params = <>
StreamingOptions = [soDisableEventsWhileStreaming]
@@ -560,6 +581,10 @@ inherited DataModuleContratosCliente: TDataModuleContratosCliente
Name = 'ID'
DataType = datInteger
end
+ item
+ Name = 'ID_EMPRESA'
+ DataType = datInteger
+ end
item
Name = 'REFERENCIA'
DataType = datString
diff --git a/Source/Modulos/Contratos de cliente/Model/schContratosClienteClient_Intf.pas b/Source/Modulos/Contratos de cliente/Model/schContratosClienteClient_Intf.pas
index acb755ce..e0df7dd0 100644
--- a/Source/Modulos/Contratos de cliente/Model/schContratosClienteClient_Intf.pas
+++ b/Source/Modulos/Contratos de cliente/Model/schContratosClienteClient_Intf.pas
@@ -9,14 +9,14 @@ 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_Valores = '{20F4DF5F-38DB-4AA6-B17F-5192ED36BC0D}';
- RID_Propiedades = '{10A019F3-E795-413B-AE1A-8075665936C4}';
- RID_ListaAnosContratos = '{B706B31A-572A-44D7-815A-11028E17F3F0}';
- RID_ContratosClienteBeneficios = '{F9036DB4-7264-4B53-B7B7-A33F1FA4F72C}';
- RID_ContratosCliente = '{210D5B45-17D3-4EA9-82CC-FD40936C848C}';
- RID_TiposCapitulos = '{6781118D-1743-4A35-AD55-9C426656C662}';
- RID_ContratosCliente_Detalles = '{DC6E8B1B-AEEE-4CBC-A18D-5B7AB6B693FC}';
- RID_ContratoClienteFacturasProv = '{9F92B050-F8CB-4D0B-8C98-53D93B2F93D3}';
+ RID_Valores = '{B959D29A-4D0E-4C85-8253-14F1A7A94852}';
+ RID_Propiedades = '{598A590B-E236-4C4E-AD40-DFF0477B435F}';
+ RID_ListaAnosContratos = '{0C28F1E9-E2B3-425A-AFB8-02AA6C05B03E}';
+ RID_ContratosClienteBeneficios = '{6F2C3C2B-114F-4E37-B1EC-52BC64FC0AF2}';
+ RID_ContratosCliente = '{FE3220CF-C79A-4746-9F30-9F0736188F7C}';
+ RID_TiposCapitulos = '{C06DCF4D-5ABF-46D4-8633-FD07FE8528B2}';
+ RID_ContratosCliente_Detalles = '{958C1B7F-44FD-4E70-B5AB-C3839B9AB84F}';
+ RID_ContratoClienteFacturasProv = '{789FBA41-F5CF-4585-835C-A2E69B81AACC}';
{ Data table names }
nme_Valores = 'Valores';
@@ -56,6 +56,7 @@ const
{ ContratosClienteBeneficios fields }
fld_ContratosClienteBeneficiosID = 'ID';
+ fld_ContratosClienteBeneficiosID_EMPRESA = 'ID_EMPRESA';
fld_ContratosClienteBeneficiosREFERENCIA = 'REFERENCIA';
fld_ContratosClienteBeneficiosREFERENCIA_CLIENTE = 'REFERENCIA_CLIENTE';
fld_ContratosClienteBeneficiosTIPO_CONTRATO = 'TIPO_CONTRATO';
@@ -74,21 +75,22 @@ const
{ ContratosClienteBeneficios field indexes }
idx_ContratosClienteBeneficiosID = 0;
- idx_ContratosClienteBeneficiosREFERENCIA = 1;
- idx_ContratosClienteBeneficiosREFERENCIA_CLIENTE = 2;
- idx_ContratosClienteBeneficiosTIPO_CONTRATO = 3;
- idx_ContratosClienteBeneficiosFECHA_CONTRATO = 4;
- idx_ContratosClienteBeneficiosNOMBRE = 5;
- idx_ContratosClienteBeneficiosNIF_CIF = 6;
- idx_ContratosClienteBeneficiosIMPORTE_NETO = 7;
- idx_ContratosClienteBeneficiosIMPORTE_DESCUENTO = 8;
- idx_ContratosClienteBeneficiosBASE_IMPONIBLE = 9;
- idx_ContratosClienteBeneficiosIMPORTE_FACTURAS_PROVEEDOR = 10;
- idx_ContratosClienteBeneficiosIMPORTE_BENEFICIO = 11;
- idx_ContratosClienteBeneficiosPORCENTAJE_BENEFICIO = 12;
- idx_ContratosClienteBeneficiosSITUACION = 13;
- idx_ContratosClienteBeneficiosID_VENDEDOR = 14;
- idx_ContratosClienteBeneficiosVENDEDOR = 15;
+ idx_ContratosClienteBeneficiosID_EMPRESA = 1;
+ idx_ContratosClienteBeneficiosREFERENCIA = 2;
+ idx_ContratosClienteBeneficiosREFERENCIA_CLIENTE = 3;
+ idx_ContratosClienteBeneficiosTIPO_CONTRATO = 4;
+ idx_ContratosClienteBeneficiosFECHA_CONTRATO = 5;
+ idx_ContratosClienteBeneficiosNOMBRE = 6;
+ idx_ContratosClienteBeneficiosNIF_CIF = 7;
+ idx_ContratosClienteBeneficiosIMPORTE_NETO = 8;
+ idx_ContratosClienteBeneficiosIMPORTE_DESCUENTO = 9;
+ idx_ContratosClienteBeneficiosBASE_IMPONIBLE = 10;
+ idx_ContratosClienteBeneficiosIMPORTE_FACTURAS_PROVEEDOR = 11;
+ idx_ContratosClienteBeneficiosIMPORTE_BENEFICIO = 12;
+ idx_ContratosClienteBeneficiosPORCENTAJE_BENEFICIO = 13;
+ idx_ContratosClienteBeneficiosSITUACION = 14;
+ idx_ContratosClienteBeneficiosID_VENDEDOR = 15;
+ idx_ContratosClienteBeneficiosVENDEDOR = 16;
{ ContratosCliente fields }
fld_ContratosClienteID = 'ID';
@@ -143,6 +145,10 @@ const
fld_ContratosClienteFECHA_ULT_PRESENTACION_CLIENTE = 'FECHA_ULT_PRESENTACION_CLIENTE';
fld_ContratosClienteID_INSTALADOR = 'ID_INSTALADOR';
fld_ContratosClienteNOMBRE_INSTALADOR = 'NOMBRE_INSTALADOR';
+ fld_ContratosClienteID_PRESUPUESTADOR = 'ID_PRESUPUESTADOR';
+ fld_ContratosClientePRESUPUESTADOR = 'PRESUPUESTADOR';
+ fld_ContratosClienteID_SEGUIDOR = 'ID_SEGUIDOR';
+ fld_ContratosClienteSEGUIDOR = 'SEGUIDOR';
{ ContratosCliente field indexes }
idx_ContratosClienteID = 0;
@@ -197,6 +203,10 @@ const
idx_ContratosClienteFECHA_ULT_PRESENTACION_CLIENTE = 49;
idx_ContratosClienteID_INSTALADOR = 50;
idx_ContratosClienteNOMBRE_INSTALADOR = 51;
+ idx_ContratosClienteID_PRESUPUESTADOR = 52;
+ idx_ContratosClientePRESUPUESTADOR = 53;
+ idx_ContratosClienteID_SEGUIDOR = 54;
+ idx_ContratosClienteSEGUIDOR = 55;
{ TiposCapitulos fields }
fld_TiposCapitulosID = 'ID';
@@ -273,7 +283,7 @@ const
type
{ IValores }
IValores = interface(IDAStronglyTypedDataTable)
- ['{90B6AEAB-CA86-415A-9867-AE6DDF147292}']
+ ['{1FA49D4B-6562-4B1A-B190-D0AF6129353D}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -332,7 +342,7 @@ type
{ IPropiedades }
IPropiedades = interface(IDAStronglyTypedDataTable)
- ['{D75A4B85-BBF5-495B-81BD-D8423BEB8878}']
+ ['{2FB922C0-59ED-4844-861F-84BF71E0442C}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -391,7 +401,7 @@ type
{ IListaAnosContratos }
IListaAnosContratos = interface(IDAStronglyTypedDataTable)
- ['{A58F3174-AAB8-42A5-9F76-CD538099B39D}']
+ ['{B84B9D7F-2E8C-4073-89CA-52D6F0F1D5B6}']
{ Property getters and setters }
function GetANOValue: String;
procedure SetANOValue(const aValue: String);
@@ -426,12 +436,16 @@ type
{ IContratosClienteBeneficios }
IContratosClienteBeneficios = interface(IDAStronglyTypedDataTable)
- ['{443426BE-76C1-459F-B040-945933103153}']
+ ['{7675C9FB-656E-4E2A-9137-FFA4B2069210}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
function GetIDIsNull: Boolean;
procedure SetIDIsNull(const aValue: Boolean);
+ function GetID_EMPRESAValue: Integer;
+ procedure SetID_EMPRESAValue(const aValue: Integer);
+ function GetID_EMPRESAIsNull: Boolean;
+ procedure SetID_EMPRESAIsNull(const aValue: Boolean);
function GetREFERENCIAValue: String;
procedure SetREFERENCIAValue(const aValue: String);
function GetREFERENCIAIsNull: Boolean;
@@ -497,6 +511,8 @@ type
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull;
+ property ID_EMPRESA: Integer read GetID_EMPRESAValue write SetID_EMPRESAValue;
+ property ID_EMPRESAIsNull: Boolean read GetID_EMPRESAIsNull write SetID_EMPRESAIsNull;
property REFERENCIA: String read GetREFERENCIAValue write SetREFERENCIAValue;
property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull;
property REFERENCIA_CLIENTE: String read GetREFERENCIA_CLIENTEValue write SetREFERENCIA_CLIENTEValue;
@@ -538,6 +554,10 @@ type
procedure SetIDValue(const aValue: Integer); virtual;
function GetIDIsNull: Boolean; virtual;
procedure SetIDIsNull(const aValue: Boolean); virtual;
+ function GetID_EMPRESAValue: Integer; virtual;
+ procedure SetID_EMPRESAValue(const aValue: Integer); virtual;
+ function GetID_EMPRESAIsNull: Boolean; virtual;
+ procedure SetID_EMPRESAIsNull(const aValue: Boolean); virtual;
function GetREFERENCIAValue: String; virtual;
procedure SetREFERENCIAValue(const aValue: String); virtual;
function GetREFERENCIAIsNull: Boolean; virtual;
@@ -602,6 +622,8 @@ type
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull;
+ property ID_EMPRESA: Integer read GetID_EMPRESAValue write SetID_EMPRESAValue;
+ property ID_EMPRESAIsNull: Boolean read GetID_EMPRESAIsNull write SetID_EMPRESAIsNull;
property REFERENCIA: String read GetREFERENCIAValue write SetREFERENCIAValue;
property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull;
property REFERENCIA_CLIENTE: String read GetREFERENCIA_CLIENTEValue write SetREFERENCIA_CLIENTEValue;
@@ -641,7 +663,7 @@ type
{ IContratosCliente }
IContratosCliente = interface(IDAStronglyTypedDataTable)
- ['{E5FEBD8B-4FA0-4E95-B596-969808CA3467}']
+ ['{E63C592B-6E5F-4B12-A8DF-98AEB887A49F}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -845,6 +867,22 @@ type
procedure SetNOMBRE_INSTALADORValue(const aValue: String);
function GetNOMBRE_INSTALADORIsNull: Boolean;
procedure SetNOMBRE_INSTALADORIsNull(const aValue: Boolean);
+ function GetID_PRESUPUESTADORValue: Integer;
+ procedure SetID_PRESUPUESTADORValue(const aValue: Integer);
+ function GetID_PRESUPUESTADORIsNull: Boolean;
+ procedure SetID_PRESUPUESTADORIsNull(const aValue: Boolean);
+ function GetPRESUPUESTADORValue: String;
+ procedure SetPRESUPUESTADORValue(const aValue: String);
+ function GetPRESUPUESTADORIsNull: Boolean;
+ procedure SetPRESUPUESTADORIsNull(const aValue: Boolean);
+ function GetID_SEGUIDORValue: Integer;
+ procedure SetID_SEGUIDORValue(const aValue: Integer);
+ function GetID_SEGUIDORIsNull: Boolean;
+ procedure SetID_SEGUIDORIsNull(const aValue: Boolean);
+ function GetSEGUIDORValue: String;
+ procedure SetSEGUIDORValue(const aValue: String);
+ function GetSEGUIDORIsNull: Boolean;
+ procedure SetSEGUIDORIsNull(const aValue: Boolean);
{ Properties }
@@ -952,6 +990,14 @@ type
property ID_INSTALADORIsNull: Boolean read GetID_INSTALADORIsNull write SetID_INSTALADORIsNull;
property NOMBRE_INSTALADOR: String read GetNOMBRE_INSTALADORValue write SetNOMBRE_INSTALADORValue;
property NOMBRE_INSTALADORIsNull: Boolean read GetNOMBRE_INSTALADORIsNull write SetNOMBRE_INSTALADORIsNull;
+ property ID_PRESUPUESTADOR: Integer read GetID_PRESUPUESTADORValue write SetID_PRESUPUESTADORValue;
+ property ID_PRESUPUESTADORIsNull: Boolean read GetID_PRESUPUESTADORIsNull write SetID_PRESUPUESTADORIsNull;
+ property PRESUPUESTADOR: String read GetPRESUPUESTADORValue write SetPRESUPUESTADORValue;
+ property PRESUPUESTADORIsNull: Boolean read GetPRESUPUESTADORIsNull write SetPRESUPUESTADORIsNull;
+ property ID_SEGUIDOR: Integer read GetID_SEGUIDORValue write SetID_SEGUIDORValue;
+ property ID_SEGUIDORIsNull: Boolean read GetID_SEGUIDORIsNull write SetID_SEGUIDORIsNull;
+ property SEGUIDOR: String read GetSEGUIDORValue write SetSEGUIDORValue;
+ property SEGUIDORIsNull: Boolean read GetSEGUIDORIsNull write SetSEGUIDORIsNull;
end;
{ TContratosClienteDataTableRules }
@@ -1173,6 +1219,22 @@ type
procedure SetNOMBRE_INSTALADORValue(const aValue: String); virtual;
function GetNOMBRE_INSTALADORIsNull: Boolean; virtual;
procedure SetNOMBRE_INSTALADORIsNull(const aValue: Boolean); virtual;
+ function GetID_PRESUPUESTADORValue: Integer; virtual;
+ procedure SetID_PRESUPUESTADORValue(const aValue: Integer); virtual;
+ function GetID_PRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetID_PRESUPUESTADORIsNull(const aValue: Boolean); virtual;
+ function GetPRESUPUESTADORValue: String; virtual;
+ procedure SetPRESUPUESTADORValue(const aValue: String); virtual;
+ function GetPRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetPRESUPUESTADORIsNull(const aValue: Boolean); virtual;
+ function GetID_SEGUIDORValue: Integer; virtual;
+ procedure SetID_SEGUIDORValue(const aValue: Integer); virtual;
+ function GetID_SEGUIDORIsNull: Boolean; virtual;
+ procedure SetID_SEGUIDORIsNull(const aValue: Boolean); virtual;
+ function GetSEGUIDORValue: String; virtual;
+ procedure SetSEGUIDORValue(const aValue: String); virtual;
+ function GetSEGUIDORIsNull: Boolean; virtual;
+ procedure SetSEGUIDORIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
@@ -1279,6 +1341,14 @@ type
property ID_INSTALADORIsNull: Boolean read GetID_INSTALADORIsNull write SetID_INSTALADORIsNull;
property NOMBRE_INSTALADOR: String read GetNOMBRE_INSTALADORValue write SetNOMBRE_INSTALADORValue;
property NOMBRE_INSTALADORIsNull: Boolean read GetNOMBRE_INSTALADORIsNull write SetNOMBRE_INSTALADORIsNull;
+ property ID_PRESUPUESTADOR: Integer read GetID_PRESUPUESTADORValue write SetID_PRESUPUESTADORValue;
+ property ID_PRESUPUESTADORIsNull: Boolean read GetID_PRESUPUESTADORIsNull write SetID_PRESUPUESTADORIsNull;
+ property PRESUPUESTADOR: String read GetPRESUPUESTADORValue write SetPRESUPUESTADORValue;
+ property PRESUPUESTADORIsNull: Boolean read GetPRESUPUESTADORIsNull write SetPRESUPUESTADORIsNull;
+ property ID_SEGUIDOR: Integer read GetID_SEGUIDORValue write SetID_SEGUIDORValue;
+ property ID_SEGUIDORIsNull: Boolean read GetID_SEGUIDORIsNull write SetID_SEGUIDORIsNull;
+ property SEGUIDOR: String read GetSEGUIDORValue write SetSEGUIDORValue;
+ property SEGUIDORIsNull: Boolean read GetSEGUIDORIsNull write SetSEGUIDORIsNull;
public
constructor Create(aDataTable: TDADataTable); override;
@@ -1291,7 +1361,7 @@ type
}
{ ITiposCapitulos }
ITiposCapitulos = interface(IDAStronglyTypedDataTable)
- ['{42253827-AA15-492F-AFAC-257EB0C0F6D7}']
+ ['{073AA046-A990-4F4C-9511-1FCECCAB82F5}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -1386,7 +1456,7 @@ type
{ IContratosCliente_Detalles }
IContratosCliente_Detalles = interface(IDAStronglyTypedDataTable)
- ['{4654E368-8185-40CF-AAD9-9233379440E5}']
+ ['{DC068DE8-7645-4606-A495-EA61858FA573}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -1637,7 +1707,7 @@ type
{ IContratoClienteFacturasProv }
IContratoClienteFacturasProv = interface(IDAStronglyTypedDataTable)
- ['{B6845872-92DB-4F81-8768-8FD56B3FD473}']
+ ['{0FA7F5D0-2691-460F-9169-53D618623C2A}']
{ Property getters and setters }
function GetID_CONTRATOValue: Integer;
procedure SetID_CONTRATOValue(const aValue: Integer);
@@ -1937,6 +2007,27 @@ begin
DataTable.Fields[idx_ContratosClienteBeneficiosID].AsVariant := Null;
end;
+function TContratosClienteBeneficiosDataTableRules.GetID_EMPRESAValue: Integer;
+begin
+ result := DataTable.Fields[idx_ContratosClienteBeneficiosID_EMPRESA].AsInteger;
+end;
+
+procedure TContratosClienteBeneficiosDataTableRules.SetID_EMPRESAValue(const aValue: Integer);
+begin
+ DataTable.Fields[idx_ContratosClienteBeneficiosID_EMPRESA].AsInteger := aValue;
+end;
+
+function TContratosClienteBeneficiosDataTableRules.GetID_EMPRESAIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_ContratosClienteBeneficiosID_EMPRESA].IsNull;
+end;
+
+procedure TContratosClienteBeneficiosDataTableRules.SetID_EMPRESAIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_ContratosClienteBeneficiosID_EMPRESA].AsVariant := Null;
+end;
+
function TContratosClienteBeneficiosDataTableRules.GetREFERENCIAValue: String;
begin
result := DataTable.Fields[idx_ContratosClienteBeneficiosREFERENCIA].AsString;
@@ -3388,6 +3479,90 @@ begin
DataTable.Fields[idx_ContratosClienteNOMBRE_INSTALADOR].AsVariant := Null;
end;
+function TContratosClienteDataTableRules.GetID_PRESUPUESTADORValue: Integer;
+begin
+ result := DataTable.Fields[idx_ContratosClienteID_PRESUPUESTADOR].AsInteger;
+end;
+
+procedure TContratosClienteDataTableRules.SetID_PRESUPUESTADORValue(const aValue: Integer);
+begin
+ DataTable.Fields[idx_ContratosClienteID_PRESUPUESTADOR].AsInteger := aValue;
+end;
+
+function TContratosClienteDataTableRules.GetID_PRESUPUESTADORIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_ContratosClienteID_PRESUPUESTADOR].IsNull;
+end;
+
+procedure TContratosClienteDataTableRules.SetID_PRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_ContratosClienteID_PRESUPUESTADOR].AsVariant := Null;
+end;
+
+function TContratosClienteDataTableRules.GetPRESUPUESTADORValue: String;
+begin
+ result := DataTable.Fields[idx_ContratosClientePRESUPUESTADOR].AsString;
+end;
+
+procedure TContratosClienteDataTableRules.SetPRESUPUESTADORValue(const aValue: String);
+begin
+ DataTable.Fields[idx_ContratosClientePRESUPUESTADOR].AsString := aValue;
+end;
+
+function TContratosClienteDataTableRules.GetPRESUPUESTADORIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_ContratosClientePRESUPUESTADOR].IsNull;
+end;
+
+procedure TContratosClienteDataTableRules.SetPRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_ContratosClientePRESUPUESTADOR].AsVariant := Null;
+end;
+
+function TContratosClienteDataTableRules.GetID_SEGUIDORValue: Integer;
+begin
+ result := DataTable.Fields[idx_ContratosClienteID_SEGUIDOR].AsInteger;
+end;
+
+procedure TContratosClienteDataTableRules.SetID_SEGUIDORValue(const aValue: Integer);
+begin
+ DataTable.Fields[idx_ContratosClienteID_SEGUIDOR].AsInteger := aValue;
+end;
+
+function TContratosClienteDataTableRules.GetID_SEGUIDORIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_ContratosClienteID_SEGUIDOR].IsNull;
+end;
+
+procedure TContratosClienteDataTableRules.SetID_SEGUIDORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_ContratosClienteID_SEGUIDOR].AsVariant := Null;
+end;
+
+function TContratosClienteDataTableRules.GetSEGUIDORValue: String;
+begin
+ result := DataTable.Fields[idx_ContratosClienteSEGUIDOR].AsString;
+end;
+
+procedure TContratosClienteDataTableRules.SetSEGUIDORValue(const aValue: String);
+begin
+ DataTable.Fields[idx_ContratosClienteSEGUIDOR].AsString := aValue;
+end;
+
+function TContratosClienteDataTableRules.GetSEGUIDORIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_ContratosClienteSEGUIDOR].IsNull;
+end;
+
+procedure TContratosClienteDataTableRules.SetSEGUIDORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_ContratosClienteSEGUIDOR].AsVariant := Null;
+end;
+
{ TTiposCapitulosDataTableRules }
constructor TTiposCapitulosDataTableRules.Create(aDataTable: TDADataTable);
diff --git a/Source/Modulos/Contratos de cliente/Model/schContratosClienteServer_Intf.pas b/Source/Modulos/Contratos de cliente/Model/schContratosClienteServer_Intf.pas
index fd752b7d..1ff7e340 100644
--- a/Source/Modulos/Contratos de cliente/Model/schContratosClienteServer_Intf.pas
+++ b/Source/Modulos/Contratos de cliente/Model/schContratosClienteServer_Intf.pas
@@ -9,19 +9,19 @@ 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_ValoresDelta = '{3B7D377E-AB81-4975-8494-9821E0FC6AA4}';
- RID_PropiedadesDelta = '{7ECA25E4-73C2-49A4-AD97-52951A70F8BB}';
- RID_ListaAnosContratosDelta = '{AD1A22B8-9535-49EE-AB3D-9CCAFA231A5E}';
- RID_ContratosClienteBeneficiosDelta = '{703EB6BB-27C5-4E04-AB28-7253E5724A2F}';
- RID_ContratosClienteDelta = '{9DE64986-EE28-44BE-BE23-11127CD3AFB0}';
- RID_TiposCapitulosDelta = '{7D66353C-5A18-40C0-8523-6DEB3A54899C}';
- RID_ContratosCliente_DetallesDelta = '{3451CA78-2E5A-4DA1-A8D2-50CA06D86BDD}';
- RID_ContratoClienteFacturasProvDelta = '{95667A5A-0FA5-4E92-A851-F3D3E7C98260}';
+ RID_ValoresDelta = '{BEF7E846-68E6-4642-A963-8239662BC18F}';
+ RID_PropiedadesDelta = '{965C52FF-51FE-49E2-AB0F-CC133550B5F0}';
+ RID_ListaAnosContratosDelta = '{100E85ED-6E4C-483A-A598-B561F0EEE3AA}';
+ RID_ContratosClienteBeneficiosDelta = '{0EA5FDD2-43CA-49C1-BA07-FF120B4344FF}';
+ RID_ContratosClienteDelta = '{FBB297BE-9076-4A45-B9FB-7296823BA42C}';
+ RID_TiposCapitulosDelta = '{92BA6A50-5D11-4716-A080-9CB5DCEFCAA8}';
+ RID_ContratosCliente_DetallesDelta = '{225035B8-7694-4159-AB92-AA97C02FB36B}';
+ RID_ContratoClienteFacturasProvDelta = '{17B96B7F-8DF6-4136-B8C3-4E32068BE42E}';
type
{ IValoresDelta }
IValoresDelta = interface(IValores)
- ['{3B7D377E-AB81-4975-8494-9821E0FC6AA4}']
+ ['{BEF7E846-68E6-4642-A963-8239662BC18F}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_PROPIEDADValue : Integer;
@@ -79,7 +79,7 @@ type
{ IPropiedadesDelta }
IPropiedadesDelta = interface(IPropiedades)
- ['{7ECA25E4-73C2-49A4-AD97-52951A70F8BB}']
+ ['{965C52FF-51FE-49E2-AB0F-CC133550B5F0}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldDESCRIPCIONValue : String;
@@ -137,7 +137,7 @@ type
{ IListaAnosContratosDelta }
IListaAnosContratosDelta = interface(IListaAnosContratos)
- ['{AD1A22B8-9535-49EE-AB3D-9CCAFA231A5E}']
+ ['{100E85ED-6E4C-483A-A598-B561F0EEE3AA}']
{ Property getters and setters }
function GetOldANOValue : String;
@@ -171,9 +171,10 @@ type
{ IContratosClienteBeneficiosDelta }
IContratosClienteBeneficiosDelta = interface(IContratosClienteBeneficios)
- ['{703EB6BB-27C5-4E04-AB28-7253E5724A2F}']
+ ['{0EA5FDD2-43CA-49C1-BA07-FF120B4344FF}']
{ Property getters and setters }
function GetOldIDValue : Integer;
+ function GetOldID_EMPRESAValue : Integer;
function GetOldREFERENCIAValue : String;
function GetOldREFERENCIA_CLIENTEValue : String;
function GetOldTIPO_CONTRATOValue : String;
@@ -192,6 +193,7 @@ type
{ Properties }
property OldID : Integer read GetOldIDValue;
+ property OldID_EMPRESA : Integer read GetOldID_EMPRESAValue;
property OldREFERENCIA : String read GetOldREFERENCIAValue;
property OldREFERENCIA_CLIENTE : String read GetOldREFERENCIA_CLIENTEValue;
property OldTIPO_CONTRATO : String read GetOldTIPO_CONTRATOValue;
@@ -220,6 +222,12 @@ type
function GetOldIDIsNull: Boolean; virtual;
procedure SetIDValue(const aValue: Integer); virtual;
procedure SetIDIsNull(const aValue: Boolean); virtual;
+ function GetID_EMPRESAValue: Integer; virtual;
+ function GetID_EMPRESAIsNull: Boolean; virtual;
+ function GetOldID_EMPRESAValue: Integer; virtual;
+ function GetOldID_EMPRESAIsNull: Boolean; virtual;
+ procedure SetID_EMPRESAValue(const aValue: Integer); virtual;
+ procedure SetID_EMPRESAIsNull(const aValue: Boolean); virtual;
function GetREFERENCIAValue: String; virtual;
function GetREFERENCIAIsNull: Boolean; virtual;
function GetOldREFERENCIAValue: String; virtual;
@@ -316,6 +324,10 @@ type
property IDIsNull : Boolean read GetIDIsNull write SetIDIsNull;
property OldID : Integer read GetOldIDValue;
property OldIDIsNull : Boolean read GetOldIDIsNull;
+ property ID_EMPRESA : Integer read GetID_EMPRESAValue write SetID_EMPRESAValue;
+ property ID_EMPRESAIsNull : Boolean read GetID_EMPRESAIsNull write SetID_EMPRESAIsNull;
+ property OldID_EMPRESA : Integer read GetOldID_EMPRESAValue;
+ property OldID_EMPRESAIsNull : Boolean read GetOldID_EMPRESAIsNull;
property REFERENCIA : String read GetREFERENCIAValue write SetREFERENCIAValue;
property REFERENCIAIsNull : Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull;
property OldREFERENCIA : String read GetOldREFERENCIAValue;
@@ -385,7 +397,7 @@ type
{ IContratosClienteDelta }
IContratosClienteDelta = interface(IContratosCliente)
- ['{9DE64986-EE28-44BE-BE23-11127CD3AFB0}']
+ ['{FBB297BE-9076-4A45-B9FB-7296823BA42C}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;
@@ -439,6 +451,10 @@ type
function GetOldFECHA_ULT_PRESENTACION_CLIENTEValue : DateTime;
function GetOldID_INSTALADORValue : Integer;
function GetOldNOMBRE_INSTALADORValue : String;
+ function GetOldID_PRESUPUESTADORValue : Integer;
+ function GetOldPRESUPUESTADORValue : String;
+ function GetOldID_SEGUIDORValue : Integer;
+ function GetOldSEGUIDORValue : String;
{ Properties }
property OldID : Integer read GetOldIDValue;
@@ -493,6 +509,10 @@ type
property OldFECHA_ULT_PRESENTACION_CLIENTE : DateTime read GetOldFECHA_ULT_PRESENTACION_CLIENTEValue;
property OldID_INSTALADOR : Integer read GetOldID_INSTALADORValue;
property OldNOMBRE_INSTALADOR : String read GetOldNOMBRE_INSTALADORValue;
+ property OldID_PRESUPUESTADOR : Integer read GetOldID_PRESUPUESTADORValue;
+ property OldPRESUPUESTADOR : String read GetOldPRESUPUESTADORValue;
+ property OldID_SEGUIDOR : Integer read GetOldID_SEGUIDORValue;
+ property OldSEGUIDOR : String read GetOldSEGUIDORValue;
end;
{ TContratosClienteBusinessProcessorRules }
@@ -818,6 +838,30 @@ type
function GetOldNOMBRE_INSTALADORIsNull: Boolean; virtual;
procedure SetNOMBRE_INSTALADORValue(const aValue: String); virtual;
procedure SetNOMBRE_INSTALADORIsNull(const aValue: Boolean); virtual;
+ function GetID_PRESUPUESTADORValue: Integer; virtual;
+ function GetID_PRESUPUESTADORIsNull: Boolean; virtual;
+ function GetOldID_PRESUPUESTADORValue: Integer; virtual;
+ function GetOldID_PRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetID_PRESUPUESTADORValue(const aValue: Integer); virtual;
+ procedure SetID_PRESUPUESTADORIsNull(const aValue: Boolean); virtual;
+ function GetPRESUPUESTADORValue: String; virtual;
+ function GetPRESUPUESTADORIsNull: Boolean; virtual;
+ function GetOldPRESUPUESTADORValue: String; virtual;
+ function GetOldPRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetPRESUPUESTADORValue(const aValue: String); virtual;
+ procedure SetPRESUPUESTADORIsNull(const aValue: Boolean); virtual;
+ function GetID_SEGUIDORValue: Integer; virtual;
+ function GetID_SEGUIDORIsNull: Boolean; virtual;
+ function GetOldID_SEGUIDORValue: Integer; virtual;
+ function GetOldID_SEGUIDORIsNull: Boolean; virtual;
+ procedure SetID_SEGUIDORValue(const aValue: Integer); virtual;
+ procedure SetID_SEGUIDORIsNull(const aValue: Boolean); virtual;
+ function GetSEGUIDORValue: String; virtual;
+ function GetSEGUIDORIsNull: Boolean; virtual;
+ function GetOldSEGUIDORValue: String; virtual;
+ function GetOldSEGUIDORIsNull: Boolean; virtual;
+ procedure SetSEGUIDORValue(const aValue: String); virtual;
+ procedure SetSEGUIDORIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID : Integer read GetIDValue write SetIDValue;
@@ -1028,6 +1072,22 @@ type
property NOMBRE_INSTALADORIsNull : Boolean read GetNOMBRE_INSTALADORIsNull write SetNOMBRE_INSTALADORIsNull;
property OldNOMBRE_INSTALADOR : String read GetOldNOMBRE_INSTALADORValue;
property OldNOMBRE_INSTALADORIsNull : Boolean read GetOldNOMBRE_INSTALADORIsNull;
+ property ID_PRESUPUESTADOR : Integer read GetID_PRESUPUESTADORValue write SetID_PRESUPUESTADORValue;
+ property ID_PRESUPUESTADORIsNull : Boolean read GetID_PRESUPUESTADORIsNull write SetID_PRESUPUESTADORIsNull;
+ property OldID_PRESUPUESTADOR : Integer read GetOldID_PRESUPUESTADORValue;
+ property OldID_PRESUPUESTADORIsNull : Boolean read GetOldID_PRESUPUESTADORIsNull;
+ property PRESUPUESTADOR : String read GetPRESUPUESTADORValue write SetPRESUPUESTADORValue;
+ property PRESUPUESTADORIsNull : Boolean read GetPRESUPUESTADORIsNull write SetPRESUPUESTADORIsNull;
+ property OldPRESUPUESTADOR : String read GetOldPRESUPUESTADORValue;
+ property OldPRESUPUESTADORIsNull : Boolean read GetOldPRESUPUESTADORIsNull;
+ property ID_SEGUIDOR : Integer read GetID_SEGUIDORValue write SetID_SEGUIDORValue;
+ property ID_SEGUIDORIsNull : Boolean read GetID_SEGUIDORIsNull write SetID_SEGUIDORIsNull;
+ property OldID_SEGUIDOR : Integer read GetOldID_SEGUIDORValue;
+ property OldID_SEGUIDORIsNull : Boolean read GetOldID_SEGUIDORIsNull;
+ property SEGUIDOR : String read GetSEGUIDORValue write SetSEGUIDORValue;
+ property SEGUIDORIsNull : Boolean read GetSEGUIDORIsNull write SetSEGUIDORIsNull;
+ property OldSEGUIDOR : String read GetOldSEGUIDORValue;
+ property OldSEGUIDORIsNull : Boolean read GetOldSEGUIDORIsNull;
public
constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
@@ -1037,7 +1097,7 @@ type
{ ITiposCapitulosDelta }
ITiposCapitulosDelta = interface(ITiposCapitulos)
- ['{7D66353C-5A18-40C0-8523-6DEB3A54899C}']
+ ['{92BA6A50-5D11-4716-A080-9CB5DCEFCAA8}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldPOSICIONValue : Integer;
@@ -1131,7 +1191,7 @@ type
{ IContratosCliente_DetallesDelta }
IContratosCliente_DetallesDelta = interface(IContratosCliente_Detalles)
- ['{3451CA78-2E5A-4DA1-A8D2-50CA06D86BDD}']
+ ['{225035B8-7694-4159-AB92-AA97C02FB36B}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_CONTRATOValue : Integer;
@@ -1381,7 +1441,7 @@ type
{ IContratoClienteFacturasProvDelta }
IContratoClienteFacturasProvDelta = interface(IContratoClienteFacturasProv)
- ['{95667A5A-0FA5-4E92-A851-F3D3E7C98260}']
+ ['{17B96B7F-8DF6-4136-B8C3-4E32068BE42E}']
{ Property getters and setters }
function GetOldID_CONTRATOValue : Integer;
function GetOldREFERENCIAValue : String;
@@ -1761,6 +1821,37 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteBeneficiosID] := Null;
end;
+function TContratosClienteBeneficiosBusinessProcessorRules.GetID_EMPRESAValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteBeneficiosID_EMPRESA];
+end;
+
+function TContratosClienteBeneficiosBusinessProcessorRules.GetID_EMPRESAIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteBeneficiosID_EMPRESA]);
+end;
+
+function TContratosClienteBeneficiosBusinessProcessorRules.GetOldID_EMPRESAValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteBeneficiosID_EMPRESA];
+end;
+
+function TContratosClienteBeneficiosBusinessProcessorRules.GetOldID_EMPRESAIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteBeneficiosID_EMPRESA]);
+end;
+
+procedure TContratosClienteBeneficiosBusinessProcessorRules.SetID_EMPRESAValue(const aValue: Integer);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteBeneficiosID_EMPRESA] := aValue;
+end;
+
+procedure TContratosClienteBeneficiosBusinessProcessorRules.SetID_EMPRESAIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteBeneficiosID_EMPRESA] := Null;
+end;
+
function TContratosClienteBeneficiosBusinessProcessorRules.GetREFERENCIAValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteBeneficiosREFERENCIA];
@@ -3888,6 +3979,130 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteNOMBRE_INSTALADOR] := Null;
end;
+function TContratosClienteBusinessProcessorRules.GetID_PRESUPUESTADORValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_PRESUPUESTADOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetID_PRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_PRESUPUESTADOR]);
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldID_PRESUPUESTADORValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteID_PRESUPUESTADOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldID_PRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteID_PRESUPUESTADOR]);
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetID_PRESUPUESTADORValue(const aValue: Integer);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_PRESUPUESTADOR] := aValue;
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetID_PRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_PRESUPUESTADOR] := Null;
+end;
+
+function TContratosClienteBusinessProcessorRules.GetPRESUPUESTADORValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClientePRESUPUESTADOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetPRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClientePRESUPUESTADOR]);
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldPRESUPUESTADORValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClientePRESUPUESTADOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldPRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClientePRESUPUESTADOR]);
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetPRESUPUESTADORValue(const aValue: String);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClientePRESUPUESTADOR] := aValue;
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetPRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClientePRESUPUESTADOR] := Null;
+end;
+
+function TContratosClienteBusinessProcessorRules.GetID_SEGUIDORValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_SEGUIDOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetID_SEGUIDORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_SEGUIDOR]);
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldID_SEGUIDORValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteID_SEGUIDOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldID_SEGUIDORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteID_SEGUIDOR]);
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetID_SEGUIDORValue(const aValue: Integer);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_SEGUIDOR] := aValue;
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetID_SEGUIDORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteID_SEGUIDOR] := Null;
+end;
+
+function TContratosClienteBusinessProcessorRules.GetSEGUIDORValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteSEGUIDOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetSEGUIDORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteSEGUIDOR]);
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldSEGUIDORValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteSEGUIDOR];
+end;
+
+function TContratosClienteBusinessProcessorRules.GetOldSEGUIDORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_ContratosClienteSEGUIDOR]);
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetSEGUIDORValue(const aValue: String);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteSEGUIDOR] := aValue;
+end;
+
+procedure TContratosClienteBusinessProcessorRules.SetSEGUIDORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_ContratosClienteSEGUIDOR] := Null;
+end;
+
{ TTiposCapitulosBusinessProcessorRules }
constructor TTiposCapitulosBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
diff --git a/Source/Modulos/Contratos de cliente/Model/uBizContratosCliente.pas b/Source/Modulos/Contratos de cliente/Model/uBizContratosCliente.pas
index e36ea710..73a61ef2 100644
--- a/Source/Modulos/Contratos de cliente/Model/uBizContratosCliente.pas
+++ b/Source/Modulos/Contratos de cliente/Model/uBizContratosCliente.pas
@@ -35,7 +35,7 @@ type
property Detalles: IBizDetallesContratoCliente read GetDetalles write SetDetalles;
procedure CalcularImporteTotal;
- procedure AsignarVendedor;
+ procedure AsignarPresupuestador;
function EsNuevo : Boolean;
function DarListaSituaciones: TStringList;
@@ -92,7 +92,7 @@ type
function DarListaSituaciones: TStringList;
function EsNuevo : Boolean;
procedure CalcularImporteTotal;
- procedure AsignarVendedor;
+ procedure AsignarPresupuestador;
property Cliente : IBizCliente read GetCliente write SetCliente;
property _Cliente : IBizCliente read _GetCliente write _SetCliente;
@@ -279,16 +279,16 @@ begin
Self.DataTable.FieldByName(fld_ContratosClienteOBSERVACIONES).AsString := AppFactuGES.ObservacionesDocumentos;
Self.DataTable.FieldByName(fld_ContratosClienteCONDICIONES).AsString := AppFactuGES.CondicionesDocumentos;
- AsignarVendedor;
+ AsignarPresupuestador;
end;
-procedure TBizContratoCliente.AsignarVendedor;
+procedure TBizContratoCliente.AsignarPresupuestador;
var
AVendedoresController: IVendedoresController;
begin
AVendedoresController := TVendedoresController.Create;
try
- ID_VENDEDOR := AVendedoresController.DarIDVendedorDeUsuario(AppFactuGES.UsuarioActivo.ID);
+ ID_PRESUPUESTADOR := AVendedoresController.DarIDVendedorDeUsuario(AppFactuGES.UsuarioActivo.ID);
finally
AVendedoresController := nil;
end;
diff --git a/Source/Modulos/Contratos de cliente/Servidor/srvContratosCliente_Impl.dfm b/Source/Modulos/Contratos de cliente/Servidor/srvContratosCliente_Impl.dfm
index 44e5161a..68540bc3 100644
--- a/Source/Modulos/Contratos de cliente/Servidor/srvContratosCliente_Impl.dfm
+++ b/Source/Modulos/Contratos de cliente/Servidor/srvContratosCliente_Impl.dfm
@@ -137,11 +137,11 @@ object srvContratosCliente: TsrvContratosCliente
TargetTable = 'V_CONTRATOS_BENEFICIOS'
Name = 'IBX'
SQL =
- 'SELECT '#10' ID, REFERENCIA, REFERENCIA_CLIENTE, TIPO_CONTRATO, F' +
- 'ECHA_CONTRATO, NOMBRE, NIF_CIF, IMPORTE_NETO,'#10' IMPORTE_DESCUE' +
- 'NTO, BASE_IMPONIBLE, IMPORTE_FACTURAS_PROVEEDOR, '#10' IMPORTE_BE' +
- 'NEFICIO, PORCENTAJE_BENEFICIO, SITUACION, ID_VENDEDOR, VENDEDOR'#10 +
- ' FROM'#10' V_CONTRATOS_BENEFICIOS'#10' WHERE {Where}'#10
+ 'SELECT '#10' ID, ID_EMPRESA, REFERENCIA, REFERENCIA_CLIENTE, TIPO' +
+ '_CONTRATO, FECHA_CONTRATO, NOMBRE, NIF_CIF, IMPORTE_NETO,'#10' IM' +
+ 'PORTE_DESCUENTO, BASE_IMPONIBLE, IMPORTE_FACTURAS_PROVEEDOR, '#10' ' +
+ ' IMPORTE_BENEFICIO, PORCENTAJE_BENEFICIO, SITUACION, ID_VENDEDO' +
+ 'R, VENDEDOR'#10' FROM'#10' V_CONTRATOS_BENEFICIOS'#10' WHERE {Where}'#10
StatementType = stSQL
ColumnMappings = <
item
@@ -207,6 +207,10 @@ object srvContratosCliente: TsrvContratosCliente
item
DatasetField = 'TIPO_CONTRATO'
TableField = 'TIPO_CONTRATO'
+ end
+ item
+ DatasetField = 'ID_EMPRESA'
+ TableField = 'ID_EMPRESA'
end>
end>
Name = 'ContratosClienteBeneficios'
@@ -215,6 +219,10 @@ object srvContratosCliente: TsrvContratosCliente
Name = 'ID'
DataType = datInteger
end
+ item
+ Name = 'ID_EMPRESA'
+ DataType = datInteger
+ end
item
Name = 'REFERENCIA'
DataType = datString
@@ -499,6 +507,22 @@ object srvContratosCliente: TsrvContratosCliente
item
DatasetField = 'NOMBRE_INSTALADOR'
TableField = 'NOMBRE_INSTALADOR'
+ end
+ item
+ DatasetField = 'PRESUPUESTADOR'
+ TableField = 'PRESUPUESTADOR'
+ end
+ item
+ DatasetField = 'ID_PRESUPUESTADOR'
+ TableField = 'ID_PRESUPUESTADOR'
+ end
+ item
+ DatasetField = 'ID_SEGUIDOR'
+ TableField = 'ID_SEGUIDOR'
+ end
+ item
+ DatasetField = 'SEGUIDOR'
+ TableField = 'SEGUIDOR'
end>
end>
Name = 'ContratosCliente'
@@ -786,6 +810,27 @@ object srvContratosCliente: TsrvContratosCliente
Name = 'NOMBRE_INSTALADOR'
DataType = datString
Size = 255
+ ServerAutoRefresh = True
+ end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ end
+ item
+ Name = 'PRESUPUESTADOR'
+ DataType = datString
+ Size = 255
+ ServerAutoRefresh = True
+ end
+ item
+ Name = 'ID_SEGUIDOR'
+ DataType = datInteger
+ end
+ item
+ Name = 'SEGUIDOR'
+ DataType = datString
+ Size = 255
+ ServerAutoRefresh = True
end>
end
item
@@ -1349,6 +1394,16 @@ object srvContratosCliente: TsrvContratosCliente
DataType = datString
Size = 255
Value = ''
+ end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ Value = ''
+ end
+ item
+ Name = 'ID_SEGUIDOR'
+ DataType = datInteger
+ Value = ''
end>
Statements = <
item
@@ -1366,18 +1421,19 @@ object srvContratosCliente: TsrvContratosCliente
' PERSONA_CONTACTO,'#10' RE, IMPORTE_RE, RECARGO_EQUIVALENCIA, TE' +
'LEFONO, MOVIL, TIPO_CONTRATO, CONDICIONES,'#10' CALIDADES, REFER' +
'ENCIA_CLIENTE, ID_EMPRESA, FECHA_ULT_PRESENTACION_CLIENTE,'#10' ' +
- 'ID_INSTALADOR, NOMBRE_INSTALADOR)'#10' VALUES'#10' (:ID, :ID_CLIENTE' +
- ', :NIF_CIF, :NOMBRE, :ID_DIRECCION, :CALLE, :POBLACION, :PROVINC' +
- 'IA,'#10' :CODIGO_POSTAL, :REFERENCIA, :FECHA_CONTRATO, :SITUACIO' +
- 'N, :FORMA_PAGO,'#10' :PLAZO_ENTREGA, :OBSERVACIONES, :INCIDENCIA' +
- 'S, :INCIDENCIAS_ACTIVAS, CURRENT_TIMESTAMP,'#10' :USUARIO, :IMPO' +
- 'RTE_NETO, :IMPORTE_PORTE, :DESCUENTO, :IMPORTE_DESCUENTO,'#10' :' +
- 'BASE_IMPONIBLE, :ID_TIPO_IVA, :IVA, :IMPORTE_IVA, :IMPORTE_TOTAL' +
- ', :ID_FORMA_PAGO,'#10' :ID_TIENDA, :ID_VENDEDOR, :PERSONA_CONTAC' +
- 'TO, :RE, :IMPORTE_RE, :RECARGO_EQUIVALENCIA,'#10' :TELEFONO, :MO' +
- 'VIL, :TIPO_CONTRATO, :CONDICIONES, :CALIDADES, :REFERENCIA_CLIEN' +
- 'TE, :ID_EMPRESA, :FECHA_ULT_PRESENTACION_CLIENTE,'#10' :ID_INSTA' +
- 'LADOR, :NOMBRE_INSTALADOR)'#10#10
+ 'ID_INSTALADOR, NOMBRE_INSTALADOR, ID_PRESUPUESTADOR, ID_SEGUIDOR' +
+ ')'#10' VALUES'#10' (:ID, :ID_CLIENTE, :NIF_CIF, :NOMBRE, :ID_DIRECCI' +
+ 'ON, :CALLE, :POBLACION, :PROVINCIA,'#10' :CODIGO_POSTAL, :REFERE' +
+ 'NCIA, :FECHA_CONTRATO, :SITUACION, :FORMA_PAGO,'#10' :PLAZO_ENTR' +
+ 'EGA, :OBSERVACIONES, :INCIDENCIAS, :INCIDENCIAS_ACTIVAS, CURRENT' +
+ '_TIMESTAMP,'#10' :USUARIO, :IMPORTE_NETO, :IMPORTE_PORTE, :DESCU' +
+ 'ENTO, :IMPORTE_DESCUENTO,'#10' :BASE_IMPONIBLE, :ID_TIPO_IVA, :I' +
+ 'VA, :IMPORTE_IVA, :IMPORTE_TOTAL, :ID_FORMA_PAGO,'#10' :ID_TIEND' +
+ 'A, :ID_VENDEDOR, :PERSONA_CONTACTO, :RE, :IMPORTE_RE, :RECARGO_E' +
+ 'QUIVALENCIA,'#10' :TELEFONO, :MOVIL, :TIPO_CONTRATO, :CONDICIONE' +
+ 'S, :CALIDADES, :REFERENCIA_CLIENTE, :ID_EMPRESA, :FECHA_ULT_PRES' +
+ 'ENTACION_CLIENTE,'#10' :ID_INSTALADOR, :NOMBRE_INSTALADOR, :ID_P' +
+ 'RESUPUESTADOR, :ID_SEGUIDOR)'#10#10
StatementType = stSQL
ColumnMappings = <>
end>
@@ -1638,6 +1694,16 @@ object srvContratosCliente: TsrvContratosCliente
Size = 255
Value = ''
end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ Value = ''
+ end
+ item
+ Name = 'ID_SEGUIDOR'
+ DataType = datInteger
+ Value = ''
+ end
item
Name = 'OLD_ID'
Value = ''
@@ -1670,8 +1736,9 @@ object srvContratosCliente: TsrvContratosCliente
'ES,'#10' REFERENCIA_CLIENTE = :REFERENCIA_CLIENTE,'#10' ID_EMPRESA' +
' = :ID_EMPRESA,'#10' FECHA_ULT_PRESENTACION_CLIENTE = :FECHA_ULT_' +
'PRESENTACION_CLIENTE,'#10' ID_INSTALADOR = :ID_INSTALADOR,'#10' NO' +
- 'MBRE_INSTALADOR = :NOMBRE_INSTALADOR'#10' WHERE'#10' (ID = :OLD_ID)'#10 +
- #10
+ 'MBRE_INSTALADOR = :NOMBRE_INSTALADOR,'#10' ID_PRESUPUESTADOR = :I' +
+ 'D_PRESUPUESTADOR,'#10' ID_SEGUIDOR = :ID_SEGUIDOR'#10' WHERE'#10' (ID' +
+ ' = :OLD_ID)'#10#10
StatementType = stSQL
ColumnMappings = <>
end>
diff --git a/Source/Modulos/Contratos de cliente/Views/uEditorContratosClienteBeneficios.pas b/Source/Modulos/Contratos de cliente/Views/uEditorContratosClienteBeneficios.pas
index 67c40c47..65183a8f 100644
--- a/Source/Modulos/Contratos de cliente/Views/uEditorContratosClienteBeneficios.pas
+++ b/Source/Modulos/Contratos de cliente/Views/uEditorContratosClienteBeneficios.pas
@@ -134,9 +134,6 @@ begin
ViewGrid.RestoreGridStatus;
HideHourglassCursor;
end;
-
-
-
end;
procedure TfEditorContratosClienteBeneficios.SetContratos(const Value: IBizContratosClienteBeneficios);
diff --git a/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.dfm b/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.dfm
index 9af1d6dc..d8e56aea 100644
--- a/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.dfm
+++ b/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.dfm
@@ -59,7 +59,7 @@ inherited frViewContratoCliente: TfrViewContratoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 14
+ TabOrder = 16
Height = 139
Width = 404
end
@@ -159,7 +159,7 @@ inherited frViewContratoCliente: TfrViewContratoCliente
end
object memFormaPago: TcxDBMemo
Left = 22
- Top = 459
+ Top = 513
Anchors = [akLeft, akTop, akRight, akBottom]
DataBinding.DataField = 'FORMA_PAGO'
DataBinding.DataSource = DADataSource
@@ -175,13 +175,13 @@ inherited frViewContratoCliente: TfrViewContratoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 11
+ TabOrder = 13
Height = 100
Width = 396
end
object memPlazoEntrega: TcxDBMemo
Left = 22
- Top = 637
+ Top = 664
Anchors = [akLeft, akTop, akRight, akBottom]
DataBinding.DataField = 'PLAZO_ENTREGA'
DataBinding.DataSource = DADataSource
@@ -197,7 +197,7 @@ inherited frViewContratoCliente: TfrViewContratoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 12
+ TabOrder = 14
Height = 100
Width = 396
end
@@ -284,7 +284,7 @@ inherited frViewContratoCliente: TfrViewContratoCliente
Top = 28
Width = 476
Height = 280
- TabOrder = 13
+ TabOrder = 15
ReadOnly = False
ExplicitLeft = 529
ExplicitTop = 28
@@ -293,7 +293,7 @@ inherited frViewContratoCliente: TfrViewContratoCliente
inherited dxLayoutControl1: TdxLayoutControl
Width = 476
Height = 280
- ExplicitWidth = 478
+ ExplicitWidth = 476
ExplicitHeight = 280
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 707
@@ -316,12 +316,12 @@ inherited frViewContratoCliente: TfrViewContratoCliente
Width = 707
end
inherited edtCodigoPostal: TcxDBTextEdit
- Left = 385
- ExplicitLeft = 385
+ Left = 384
+ ExplicitLeft = 384
end
inherited Button3: TBitBtn
- Left = 275
- ExplicitLeft = 275
+ Left = 274
+ ExplicitLeft = 274
end
inherited cxDBTextEdit1: TcxDBTextEdit
ExplicitWidth = 283
@@ -331,19 +331,19 @@ inherited frViewContratoCliente: TfrViewContratoCliente
end
inline frViewTienda1: TfrViewTienda
Left = 22
- Top = 363
+ Top = 417
Width = 476
Height = 60
Align = alClient
- TabOrder = 10
+ TabOrder = 12
ReadOnly = False
ExplicitLeft = 22
- ExplicitTop = 363
+ ExplicitTop = 417
ExplicitWidth = 476
ExplicitHeight = 60
inherited dxLayoutControl1: TdxLayoutControl
Width = 476
- ExplicitWidth = 475
+ ExplicitWidth = 476
end
end
object edtFechaUltRevision: TcxDBDateEdit
@@ -371,20 +371,20 @@ inherited frViewContratoCliente: TfrViewContratoCliente
end
inline frViewDatosYSeleccionInstalador1: TfrViewDatosYSeleccionInstalador
Left = 10
- Top = 229
+ Top = 283
Width = 488
Height = 110
Align = alClient
- TabOrder = 9
+ TabOrder = 11
ReadOnly = False
ExplicitLeft = 10
- ExplicitTop = 229
+ ExplicitTop = 283
ExplicitWidth = 488
ExplicitHeight = 110
inherited dxLayoutControl1: TdxLayoutControl
Width = 488
Height = 110
- ExplicitWidth = 499
+ ExplicitWidth = 488
ExplicitHeight = 110
inherited edtlNombreInstalador: TcxDBTextEdit
Left = 109
@@ -400,10 +400,10 @@ inherited frViewContratoCliente: TfrViewContratoCliente
end
inherited Button2: TBitBtn
Left = 191
- Width = 190
+ Width = 200
Caption = 'Dar de alta un alba'#241'il / instalador'
ExplicitLeft = 191
- ExplicitWidth = 190
+ ExplicitWidth = 200
end
inherited Button3: TBitBtn
Left = 231
@@ -428,6 +428,66 @@ inherited frViewContratoCliente: TfrViewContratoCliente
Left = 488
end
end
+ object cbPresupuestador: TcxDBLookupComboBox
+ Left = 131
+ Top = 217
+ DataBinding.DataField = 'ID_PRESUPUESTADOR'
+ DataBinding.DataSource = DADataSource
+ Properties.KeyFieldNames = 'ID'
+ Properties.ListColumns = <
+ item
+ FieldName = 'NOMBRE'
+ end>
+ Properties.ListOptions.GridLines = glNone
+ Properties.ListOptions.ShowHeader = False
+ Properties.ListOptions.SyncMode = True
+ Properties.ListSource = dsVendedor
+ Style.BorderColor = clWindowFrame
+ Style.BorderStyle = ebs3D
+ Style.HotTrack = False
+ Style.LookAndFeel.Kind = lfStandard
+ Style.LookAndFeel.NativeStyle = True
+ Style.ButtonStyle = bts3D
+ Style.PopupBorderStyle = epbsFrame3D
+ StyleDisabled.LookAndFeel.Kind = lfStandard
+ StyleDisabled.LookAndFeel.NativeStyle = True
+ StyleFocused.LookAndFeel.Kind = lfStandard
+ StyleFocused.LookAndFeel.NativeStyle = True
+ StyleHot.LookAndFeel.Kind = lfStandard
+ StyleHot.LookAndFeel.NativeStyle = True
+ TabOrder = 9
+ Width = 368
+ end
+ object cbSeguidor: TcxDBLookupComboBox
+ Left = 131
+ Top = 244
+ DataBinding.DataField = 'ID_SEGUIDOR'
+ DataBinding.DataSource = DADataSource
+ Properties.KeyFieldNames = 'ID'
+ Properties.ListColumns = <
+ item
+ FieldName = 'NOMBRE'
+ end>
+ Properties.ListOptions.GridLines = glNone
+ Properties.ListOptions.ShowHeader = False
+ Properties.ListOptions.SyncMode = True
+ Properties.ListSource = dsSeguidor
+ Style.BorderColor = clWindowFrame
+ Style.BorderStyle = ebs3D
+ Style.HotTrack = False
+ Style.LookAndFeel.Kind = lfStandard
+ Style.LookAndFeel.NativeStyle = True
+ Style.ButtonStyle = bts3D
+ Style.PopupBorderStyle = epbsFrame3D
+ StyleDisabled.LookAndFeel.Kind = lfStandard
+ StyleDisabled.LookAndFeel.NativeStyle = True
+ StyleFocused.LookAndFeel.Kind = lfStandard
+ StyleFocused.LookAndFeel.NativeStyle = True
+ StyleHot.LookAndFeel.Kind = lfStandard
+ StyleHot.LookAndFeel.NativeStyle = True
+ TabOrder = 10
+ Width = 368
+ end
object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False
Hidden = True
@@ -517,6 +577,16 @@ inherited frViewContratoCliente: TfrViewContratoCliente
Control = cbVendedor
ControlOptions.ShowBorder = False
end
+ object dxLayoutControl1Item16: TdxLayoutItem
+ Caption = 'Presupuestador:'
+ Control = cbPresupuestador
+ ControlOptions.ShowBorder = False
+ end
+ object dxLayoutControl1Item17: TdxLayoutItem
+ Caption = 'Seg. Instalaci'#243'n:'
+ Control = cbSeguidor
+ ControlOptions.ShowBorder = False
+ end
end
end
object dxLayoutControl1Item15: TdxLayoutItem
@@ -605,4 +675,12 @@ inherited frViewContratoCliente: TfrViewContratoCliente
Left = 40
Top = 40
end
+ object dsPresupuestador: TDADataSource
+ Left = 32
+ Top = 88
+ end
+ object dsSeguidor: TDADataSource
+ Left = 32
+ Top = 128
+ end
end
diff --git a/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.pas b/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.pas
index 0b40256e..16f97e39 100644
--- a/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.pas
+++ b/Source/Modulos/Contratos de cliente/Views/uViewContratoCliente.pas
@@ -75,6 +75,12 @@ type
edtFechaUltRevision: TcxDBDateEdit;
dxLayoutControl1Item15: TdxLayoutItem;
frViewDatosYSeleccionInstalador1: TfrViewDatosYSeleccionInstalador;
+ dxLayoutControl1Item16: TdxLayoutItem;
+ cbPresupuestador: TcxDBLookupComboBox;
+ dsPresupuestador: TDADataSource;
+ dxLayoutControl1Item17: TdxLayoutItem;
+ cbSeguidor: TcxDBLookupComboBox;
+ dsSeguidor: TDADataSource;
procedure CustomViewCreate(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject);
procedure bFormasPagoClick(Sender: TObject);
@@ -84,6 +90,8 @@ type
FContrato : IBizContratoCliente;
FFormasPago : IBizFormaPago;
FVendedor : IBizVendedor;
+ FPresupuestador : IBizVendedor;
+ FSeguidor : IBizVendedor;
FFormasPagoController : IFormasPagoController;
FVendedoresController : IVendedoresController;
FController : IContratosClienteController;
@@ -123,6 +131,8 @@ begin
inherited;
FFormasPago := Nil;
FVendedor := Nil;
+ FPresupuestador := Nil;
+ FSeguidor := Nil;
FFormasPagoController := TFormasPagoController.Create;
FVendedoresController := TVendedoresController.Create;
@@ -167,6 +177,8 @@ begin
FFormasPagoController := NIL;
FVendedor := Nil;
FVendedoresController := NIL;
+ FPresupuestador := Nil;
+ FSeguidor := Nil;
inherited;
end;
@@ -227,6 +239,14 @@ begin
dsVendedor.DataTable := FVendedor.DataTable;
dsVendedor.DataTable.Active := True;
+ FPresupuestador := (FVendedoresController.BuscarTodos as IBizVendedor);
+ dsPresupuestador.DataTable := FPresupuestador.DataTable;
+ dsPresupuestador.DataTable.Active := True;
+
+ FSeguidor := (FVendedoresController.BuscarTodos as IBizVendedor);
+ dsSeguidor.DataTable := FSeguidor.DataTable;
+ dsSeguidor.DataTable.Active := True;
+
frViewDatosYSeleccionInstalador1.ID_Instalador := FContrato.ID_INSTALADOR;
frViewDatosYSeleccionInstalador1.OnInstaladorChanged := OnInstaladorChanged;
@@ -236,6 +256,8 @@ begin
DADataSource.DataTable := NIL;
dsFormaPago.DataTable := NIL;
dsVendedor.DataTable := NIL;
+ dsPresupuestador.DataTable := NIL;
+ dsSeguidor.DataTable := NIL;
frViewClienteContrato1.Cliente := Nil;
end;
end;
diff --git a/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.dfm b/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.dfm
index 68afc1e6..04a6cd49 100644
--- a/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.dfm
+++ b/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.dfm
@@ -193,6 +193,20 @@ inherited frViewContratosCliente: TfrViewContratosCliente
object cxGridViewInstalador: TcxGridDBColumn
Caption = 'Alba'#241'il / Instalador'
DataBinding.FieldName = 'NOMBRE_INSTALADOR'
+ PropertiesClassName = 'TcxTextEditProperties'
+ Properties.Alignment.Horz = taLeftJustify
+ end
+ object cxGridViewPresupuestador: TcxGridDBColumn
+ Caption = 'Presupuestador'
+ DataBinding.FieldName = 'PRESUPUESTADOR'
+ PropertiesClassName = 'TcxTextEditProperties'
+ Properties.Alignment.Horz = taLeftJustify
+ end
+ object cxGridViewSeguidor: TcxGridDBColumn
+ Caption = 'Seg. Instalaci'#243'n'
+ DataBinding.FieldName = 'SEGUIDOR'
+ PropertiesClassName = 'TcxTextEditProperties'
+ Properties.Alignment.Horz = taLeftJustify
end
end
inherited cxGridLevel: TcxGridLevel
diff --git a/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.pas b/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.pas
index 507c1b33..346aa669 100644
--- a/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.pas
+++ b/Source/Modulos/Contratos de cliente/Views/uViewContratosCliente.pas
@@ -58,6 +58,8 @@ type
TBXSeparatorItem3: TTBXSeparatorItem;
TBXItem4: TTBXItem;
cxGridViewInstalador: TcxGridDBColumn;
+ cxGridViewPresupuestador: TcxGridDBColumn;
+ cxGridViewSeguidor: TcxGridDBColumn;
procedure cxGridActiveTabChanged(Sender: TcxCustomGrid; ALevel:
TcxGridLevel);
procedure cxGridViewStylesGetContentStyle(Sender: TcxCustomGridTableView;
diff --git a/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas b/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas
index b6cf9592..32ecb6bb 100644
--- a/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas
+++ b/Source/Modulos/Facturas de cliente/Controller/uFacturasClienteController.pas
@@ -55,6 +55,7 @@ type
function DarListaAnosFacturas: TStringList;
procedure FiltrarAno(AFactura: IBizFacturaCliente; ADynWhereDataTable: WideString; const Ano: String);
function CambiarSituacion(AFactura : IBizFacturaCliente; AllItems: Boolean = false; ASituacion: String = CTE_PENDIENTE; AListaCausas: TStringList = nil): Boolean;
+ function enviarVerifactu(AFactura: IBizFacturaCliente; AllItems: Boolean = false; AListaCausas: TStringList = nil): Boolean;
end;
TFacturasClienteController = class(TControllerBase, IFacturasClienteController)
@@ -127,6 +128,7 @@ type
procedure FiltrarAno(AFactura: IBizFacturaCliente; ADynWhereDataTable: WideString; const Ano: String);
function CambiarSituacion(AFactura : IBizFacturaCliente; AllItems: Boolean = false; ASituacion: String = CTE_PENDIENTE; AListaCausas: TStringList = nil): Boolean;
+ function enviarVerifactu(AFactura: IBizFacturaCliente; AllItems: Boolean = false; AListaCausas: TStringList = nil): Boolean;
end;
implementation
@@ -1019,6 +1021,72 @@ begin
end;
end;
+function TFacturasClienteController.enviarVerifactu(AFactura: IBizFacturaCliente; AllItems: Boolean; AListaCausas: TStringList): Boolean;
+//Solo devolverá true en el caso de eliminar todos y cada uno de los elementos a eliminar
+var
+ bModificado: Boolean;
+ ACausa: Variant;
+
+begin
+ bModificado := True;
+
+ if not Assigned(AFactura) then
+ raise Exception.Create ('Factura no asignada');
+
+ ShowHourglassCursor;
+ try
+ if not AFactura.DataTable.Active then
+ AFactura.DataTable.Active := True;
+
+ if (AFactura.State in dsEditModes) then
+ AFactura.Cancel;
+
+ //Siempre modificaremos el seleccionado tanto si es una lista de facturas a eliminar como si es la propia lista del editor.
+ if AFactura.VERIFACTU = 0 then
+ begin
+ if not AFactura.DataTable.Editing then
+ AFactura.DataTable.Edit;
+
+ AFactura.VERIFACTU := 1;
+ AFactura.DataTable.Post;
+ end;
+ //En el caso de querer modificar todos los items del objeto AFactura
+ if AllItems then
+ begin
+ with AFactura.DataTable do
+ begin
+ First;
+ while not EOF do
+ begin
+ if AFactura.VERIFACTU = 1 then
+ begin
+ bModificado := False;
+ Next;
+ end
+ else
+ begin
+ if not AFactura.DataTable.Editing then
+ AFactura.DataTable.Edit;
+
+ AFactura.VERIFACTU := 1;
+ AFactura.DataTable.Post;
+ end;
+ end;
+ end;
+ end;
+
+ try
+ AFactura.DataTable.ApplyUpdates;
+ Result := bModificado;
+ except
+ Result := False;
+ end;
+
+ finally
+ HideHourglassCursor;
+ end;
+end;
+
function TFacturasClienteController.EsEliminable(AFactura: IBizFacturaCliente; var AComentario: Variant): Boolean;
begin
Result := True;
@@ -1026,7 +1094,12 @@ begin
if not Assigned(AFactura) then
raise Exception.Create ('Factura no asignado: EsEliminable');
- if (AFactura.SITUACION <> CTE_PENDIENTE) then
+ if (AFactura.VERIFACTU = 1) then
+ begin
+ Result := False;
+ AComentario := 'La factura se ha mandado a VERIFACTU, por lo que no puede ser eliminada';
+ end
+ else if (AFactura.SITUACION <> CTE_PENDIENTE) then
begin
Result := False;
AComentario := 'La factura esta parcial o totalmente pagada, por lo que no puede ser eliminada';
@@ -1051,7 +1124,12 @@ begin
if not Assigned(AFactura) then
raise Exception.Create ('Factura no asignado: EsModificable');
- if (AFactura.SITUACION <> CTE_PENDIENTE) then
+ if (AFactura.VERIFACTU = 1) then
+ begin
+ Result := False;
+ AComentario := 'La factura se ha mandado a VERIFACTU, por lo que no puede ser modificada';
+ end
+ else if (AFactura.SITUACION <> CTE_PENDIENTE) then
begin
if FacturaTieneRecibos(AFactura) > 0 then
begin
diff --git a/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm b/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm
index a2b6dec0..4224e90d 100644
--- a/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm
+++ b/Source/Modulos/Facturas de cliente/Data/uDataModuleFacturasCliente.dfm
@@ -330,6 +330,10 @@ inherited DataModuleFacturasCliente: TDataModuleFacturasCliente
Size = 255
DisplayLabel = 'Otros nombres'
DictionaryEntry = 'FacturasCliente_LISTA_NOMBRES'
+ end
+ item
+ Name = 'VERIFACTU'
+ DataType = datSmallInt
end>
Params = <>
StreamingOptions = [soDisableEventsWhileStreaming]
diff --git a/Source/Modulos/Facturas de cliente/Model/schFacturasClienteClient_Intf.pas b/Source/Modulos/Facturas de cliente/Model/schFacturasClienteClient_Intf.pas
index 879a82c1..76a19201 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 = '{AA9E9DF8-6E40-4A04-9F56-47B64CB31051}';
- RID_FacturasCliente = '{35ABCCE5-A88B-4859-859C-7D64631B8A39}';
- RID_FacturasCliente_Detalles = '{A1647325-0E90-4395-B301-CA5855F4360C}';
+ RID_ListaAnosFacturas = '{B69B55BD-5E55-4B54-A51B-42A78E3A7CE9}';
+ RID_FacturasCliente = '{138DC6B2-AE65-442B-A817-DAF8B232F651}';
+ RID_FacturasCliente_Detalles = '{D46B6B5D-729B-483E-BE25-99E1C9A4479B}';
{ Data table names }
nme_ListaAnosFacturas = 'ListaAnosFacturas';
@@ -77,6 +77,7 @@ const
fld_FacturasClienteSIN_COMISION = 'SIN_COMISION';
fld_FacturasClienteTIPO_FACTURA = 'TIPO_FACTURA';
fld_FacturasClienteLISTA_NOMBRES = 'LISTA_NOMBRES';
+ fld_FacturasClienteVERIFACTU = 'VERIFACTU';
{ FacturasCliente field indexes }
idx_FacturasClienteID = 0;
@@ -131,6 +132,7 @@ const
idx_FacturasClienteSIN_COMISION = 49;
idx_FacturasClienteTIPO_FACTURA = 50;
idx_FacturasClienteLISTA_NOMBRES = 51;
+ idx_FacturasClienteVERIFACTU = 52;
{ FacturasCliente_Detalles fields }
fld_FacturasCliente_DetallesID = 'ID';
@@ -167,7 +169,7 @@ const
type
{ IListaAnosFacturas }
IListaAnosFacturas = interface(IDAStronglyTypedDataTable)
- ['{6F39FFB6-319E-466C-A13F-451029BC363F}']
+ ['{0A78F7B9-733E-4E29-A0AD-C80889316AF8}']
{ Property getters and setters }
function GetANOValue: String;
procedure SetANOValue(const aValue: String);
@@ -202,7 +204,7 @@ type
{ IFacturasCliente }
IFacturasCliente = interface(IDAStronglyTypedDataTable)
- ['{7C87FE37-C098-4355-990B-2693BC995665}']
+ ['{6D58B4D9-9AA3-4552-99A9-27A1BB728D85}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -411,6 +413,10 @@ type
procedure SetLISTA_NOMBRESValue(const aValue: String);
function GetLISTA_NOMBRESIsNull: Boolean;
procedure SetLISTA_NOMBRESIsNull(const aValue: Boolean);
+ function GetVERIFACTUValue: SmallInt;
+ procedure SetVERIFACTUValue(const aValue: SmallInt);
+ function GetVERIFACTUIsNull: Boolean;
+ procedure SetVERIFACTUIsNull(const aValue: Boolean);
{ Properties }
@@ -518,6 +524,8 @@ type
property TIPO_FACTURAIsNull: Boolean read GetTIPO_FACTURAIsNull write SetTIPO_FACTURAIsNull;
property LISTA_NOMBRES: String read GetLISTA_NOMBRESValue write SetLISTA_NOMBRESValue;
property LISTA_NOMBRESIsNull: Boolean read GetLISTA_NOMBRESIsNull write SetLISTA_NOMBRESIsNull;
+ property VERIFACTU: SmallInt read GetVERIFACTUValue write SetVERIFACTUValue;
+ property VERIFACTUIsNull: Boolean read GetVERIFACTUIsNull write SetVERIFACTUIsNull;
end;
{ TFacturasClienteDataTableRules }
@@ -734,6 +742,10 @@ type
procedure SetLISTA_NOMBRESValue(const aValue: String); virtual;
function GetLISTA_NOMBRESIsNull: Boolean; virtual;
procedure SetLISTA_NOMBRESIsNull(const aValue: Boolean); virtual;
+ function GetVERIFACTUValue: SmallInt; virtual;
+ procedure SetVERIFACTUValue(const aValue: SmallInt); virtual;
+ function GetVERIFACTUIsNull: Boolean; virtual;
+ procedure SetVERIFACTUIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
@@ -840,6 +852,8 @@ type
property TIPO_FACTURAIsNull: Boolean read GetTIPO_FACTURAIsNull write SetTIPO_FACTURAIsNull;
property LISTA_NOMBRES: String read GetLISTA_NOMBRESValue write SetLISTA_NOMBRESValue;
property LISTA_NOMBRESIsNull: Boolean read GetLISTA_NOMBRESIsNull write SetLISTA_NOMBRESIsNull;
+ property VERIFACTU: SmallInt read GetVERIFACTUValue write SetVERIFACTUValue;
+ property VERIFACTUIsNull: Boolean read GetVERIFACTUIsNull write SetVERIFACTUIsNull;
public
constructor Create(aDataTable: TDADataTable); override;
@@ -849,7 +863,7 @@ type
{ IFacturasCliente_Detalles }
IFacturasCliente_Detalles = interface(IDAStronglyTypedDataTable)
- ['{8FE5D0B5-031E-4B7C-9CEB-B2ED7A7201D5}']
+ ['{C9F165D5-5856-41F6-A5BF-9139520624DC}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -2185,6 +2199,27 @@ begin
DataTable.Fields[idx_FacturasClienteLISTA_NOMBRES].AsVariant := Null;
end;
+function TFacturasClienteDataTableRules.GetVERIFACTUValue: SmallInt;
+begin
+ result := DataTable.Fields[idx_FacturasClienteVERIFACTU].AsSmallInt;
+end;
+
+procedure TFacturasClienteDataTableRules.SetVERIFACTUValue(const aValue: SmallInt);
+begin
+ DataTable.Fields[idx_FacturasClienteVERIFACTU].AsSmallInt := aValue;
+end;
+
+function TFacturasClienteDataTableRules.GetVERIFACTUIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_FacturasClienteVERIFACTU].IsNull;
+end;
+
+procedure TFacturasClienteDataTableRules.SetVERIFACTUIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_FacturasClienteVERIFACTU].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 53460a17..0d2a8eef 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 = '{625CABDC-50D6-4944-B22B-D3348700AFA2}';
- RID_FacturasClienteDelta = '{1B6A177E-8B9C-415E-94B1-5CBD0CF0FF05}';
- RID_FacturasCliente_DetallesDelta = '{A116A70B-8E0A-4216-9D6E-97820C5EB891}';
+ RID_ListaAnosFacturasDelta = '{8684B20C-9A58-4343-ACBF-6E788A6D9342}';
+ RID_FacturasClienteDelta = '{F6D07436-A868-46A4-AF86-357F3FB7A074}';
+ RID_FacturasCliente_DetallesDelta = '{904B050A-78E2-4159-AD88-28EB0F6F6F69}';
type
{ IListaAnosFacturasDelta }
IListaAnosFacturasDelta = interface(IListaAnosFacturas)
- ['{625CABDC-50D6-4944-B22B-D3348700AFA2}']
+ ['{8684B20C-9A58-4343-ACBF-6E788A6D9342}']
{ Property getters and setters }
function GetOldANOValue : String;
@@ -50,7 +50,7 @@ type
{ IFacturasClienteDelta }
IFacturasClienteDelta = interface(IFacturasCliente)
- ['{1B6A177E-8B9C-415E-94B1-5CBD0CF0FF05}']
+ ['{F6D07436-A868-46A4-AF86-357F3FB7A074}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;
@@ -104,6 +104,7 @@ type
function GetOldSIN_COMISIONValue : SmallInt;
function GetOldTIPO_FACTURAValue : String;
function GetOldLISTA_NOMBRESValue : String;
+ function GetOldVERIFACTUValue : SmallInt;
{ Properties }
property OldID : Integer read GetOldIDValue;
@@ -158,6 +159,7 @@ type
property OldSIN_COMISION : SmallInt read GetOldSIN_COMISIONValue;
property OldTIPO_FACTURA : String read GetOldTIPO_FACTURAValue;
property OldLISTA_NOMBRES : String read GetOldLISTA_NOMBRESValue;
+ property OldVERIFACTU : SmallInt read GetOldVERIFACTUValue;
end;
{ TFacturasClienteBusinessProcessorRules }
@@ -478,6 +480,12 @@ type
function GetOldLISTA_NOMBRESIsNull: Boolean; virtual;
procedure SetLISTA_NOMBRESValue(const aValue: String); virtual;
procedure SetLISTA_NOMBRESIsNull(const aValue: Boolean); virtual;
+ function GetVERIFACTUValue: SmallInt; virtual;
+ function GetVERIFACTUIsNull: Boolean; virtual;
+ function GetOldVERIFACTUValue: SmallInt; virtual;
+ function GetOldVERIFACTUIsNull: Boolean; virtual;
+ procedure SetVERIFACTUValue(const aValue: SmallInt); virtual;
+ procedure SetVERIFACTUIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID : Integer read GetIDValue write SetIDValue;
@@ -688,6 +696,10 @@ type
property LISTA_NOMBRESIsNull : Boolean read GetLISTA_NOMBRESIsNull write SetLISTA_NOMBRESIsNull;
property OldLISTA_NOMBRES : String read GetOldLISTA_NOMBRESValue;
property OldLISTA_NOMBRESIsNull : Boolean read GetOldLISTA_NOMBRESIsNull;
+ property VERIFACTU : SmallInt read GetVERIFACTUValue write SetVERIFACTUValue;
+ property VERIFACTUIsNull : Boolean read GetVERIFACTUIsNull write SetVERIFACTUIsNull;
+ property OldVERIFACTU : SmallInt read GetOldVERIFACTUValue;
+ property OldVERIFACTUIsNull : Boolean read GetOldVERIFACTUIsNull;
public
constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
@@ -697,7 +709,7 @@ type
{ IFacturasCliente_DetallesDelta }
IFacturasCliente_DetallesDelta = interface(IFacturasCliente_Detalles)
- ['{A116A70B-8E0A-4216-9D6E-97820C5EB891}']
+ ['{904B050A-78E2-4159-AD88-28EB0F6F6F69}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_FACTURAValue : Integer;
@@ -2564,6 +2576,37 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteLISTA_NOMBRES] := Null;
end;
+function TFacturasClienteBusinessProcessorRules.GetVERIFACTUValue: SmallInt;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteVERIFACTU];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetVERIFACTUIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteVERIFACTU]);
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldVERIFACTUValue: SmallInt;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteVERIFACTU];
+end;
+
+function TFacturasClienteBusinessProcessorRules.GetOldVERIFACTUIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_FacturasClienteVERIFACTU]);
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetVERIFACTUValue(const aValue: SmallInt);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteVERIFACTU] := aValue;
+end;
+
+procedure TFacturasClienteBusinessProcessorRules.SetVERIFACTUIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_FacturasClienteVERIFACTU] := 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 5b509c3d..c02d942a 100644
--- a/Source/Modulos/Facturas de cliente/Model/uBizFacturasCliente.pas
+++ b/Source/Modulos/Facturas de cliente/Model/uBizFacturasCliente.pas
@@ -258,7 +258,8 @@ begin
SITUACION := CTE_PENDIENTE;
ID_CLIENTE := ID_NULO;
SIN_COMISION := 0;
-
+ VERIFACTU := 0;
+
ID_FORMA_PAGO := AppFactuGES.EmpresaActiva.ID_FORMA_PAGO;
ID_TIPO_IVA := AppFactuGES.EmpresaActiva.ID_TIPO_IVA;
diff --git a/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm b/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm
index a0d4484b..7decb043 100644
--- a/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm
+++ b/Source/Modulos/Facturas de cliente/Servidor/srvFacturasCliente_Impl.dfm
@@ -251,6 +251,14 @@ object srvFacturasCliente: TsrvFacturasCliente
item
DatasetField = 'VENDEDOR'
TableField = 'VENDEDOR'
+ end
+ item
+ DatasetField = 'LISTA_NOMBRES'
+ TableField = 'LISTA_NOMBRES'
+ end
+ item
+ DatasetField = 'VERIFACTU'
+ TableField = 'VERIFACTU'
end>
end>
Name = 'FacturasCliente'
@@ -525,6 +533,10 @@ object srvFacturasCliente: TsrvFacturasCliente
DataType = datString
Size = 255
DictionaryEntry = 'FacturasCliente_LISTA_NOMBRES'
+ end
+ item
+ Name = 'VERIFACTU'
+ DataType = datSmallInt
end>
end
item
@@ -1320,6 +1332,11 @@ object srvFacturasCliente: TsrvFacturasCliente
Size = 255
Value = ''
end
+ item
+ Name = 'VERIFACTU'
+ DataType = datSmallInt
+ Value = ''
+ end
item
Name = 'OLD_ID'
Value = ''
@@ -1346,7 +1363,7 @@ object srvFacturasCliente: TsrvFacturasCliente
'RAR_CONTABILIDAD = :IGNORAR_CONTABILIDAD,'#10' ID_TIENDA = :ID_TI' +
'ENDA,'#10' ID_CONTRATO = :ID_CONTRATO,'#10' SIN_COMISION = :SIN_CO' +
'MISION,'#10' TIPO_FACTURA = :TIPO_FACTURA,'#10' SITUACION = :SITUA' +
- 'CION'#10' WHERE'#10' (ID = :OLD_ID);'#10
+ 'CION,'#10' VERIFACTU = :VERIFACTU'#10' WHERE'#10' (ID = :OLD_ID);'#10
StatementType = stSQL
ColumnMappings = <>
end>
diff --git a/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.dfm b/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.dfm
index 8a7b2e94..98ea0fee 100644
--- a/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.dfm
+++ b/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.dfm
@@ -2,8 +2,8 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
Caption = 'Lista de facturas de cliente'
ClientHeight = 666
ClientWidth = 640
- ExplicitWidth = 648
- ExplicitHeight = 700
+ ExplicitWidth = 656
+ ExplicitHeight = 704
PixelsPerInch = 96
TextHeight = 13
inherited JvNavPanelHeader: TJvNavPanelHeader
@@ -69,7 +69,7 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
end
end
inherited tbxFiltro: TTBXToolbar
- ExplicitWidth = 356
+ ExplicitWidth = 362
inherited lblAno: TTBXLabelItem
Visible = True
end
@@ -84,10 +84,10 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
ExplicitWidth = 640
end
inherited TBXTMain2: TTBXToolbar
- Left = 356
+ Left = 362
Visible = True
- ExplicitLeft = 356
- ExplicitWidth = 211
+ ExplicitLeft = 362
+ ExplicitWidth = 278
object TBXItem42: TTBXItem
Action = actCambiarSituacion
DisplayMode = nbdmImageAndText
@@ -98,6 +98,10 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
Action = actInformes
DisplayMode = nbdmImageAndText
end
+ object TBXItem45: TTBXItem
+ Action = actMandarVerifactu
+ DisplayMode = nbdmImageAndText
+ end
end
end
inherited StatusBar: TJvStatusBar
@@ -108,9 +112,9 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
end
inline frViewFacturasCliente1: TfrViewFacturasCliente [3]
Left = 0
- Top = 102
+ Top = 105
Width = 640
- Height = 545
+ Height = 542
Align = alClient
Font.Charset = DEFAULT_CHARSET
Font.Color = clWindowText
@@ -120,14 +124,14 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
ParentFont = False
TabOrder = 3
ReadOnly = False
- ExplicitTop = 102
+ ExplicitTop = 105
ExplicitWidth = 640
- ExplicitHeight = 545
+ ExplicitHeight = 542
inherited cxGrid: TcxGrid
Width = 640
- Height = 417
+ Height = 414
ExplicitWidth = 640
- ExplicitHeight = 417
+ ExplicitHeight = 414
inherited cxGridView: TcxGridDBTableView
DataController.Summary.DefaultGroupSummaryItems = <
item
@@ -252,8 +256,8 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
end
end
inherited pnlAgrupaciones: TTBXDockablePanel
- Top = 519
- ExplicitTop = 519
+ Top = 516
+ ExplicitTop = 516
ExplicitWidth = 640
inherited TBXAlignmentPanel1: TTBXAlignmentPanel
Width = 640
@@ -344,6 +348,12 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
OnExecute = actGenerarPDFExecute
OnUpdate = actGenerarPDFUpdate
end
+ object actMandarVerifactu: TAction
+ Caption = 'Mandar Verifactu'
+ ImageIndex = 16
+ OnExecute = actMandarVerifactuExecute
+ OnUpdate = actMandarVerifactuUpdate
+ end
end
inherited SmallImages: TPngImageList [5]
PngImages = <
@@ -3554,39 +3564,40 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
000000180806000000E0773DF8000000017352474200AECE1CE9000000046741
4D410000B18F0BFC6105000000206348524D00007A26000080840000FA000000
80E8000075300000EA6000003A98000017709CBA513C00000009704859730000
- 0AE900000AE901FD75CED3000003F049444154484BBD557B6C53651C3D7DAD7B
- B0ADADC0363ADDA0834D2DDA6E5904A24C17E64864BAF8484C348E104940FD47
- 128D31121213134DD4C4F8644F794C6413188E81A003B3A15B8AC87C4CA39D9A
- 685013515B36D8B3F7E7F9AEDCDAB9760F62BCC94D9ADEEF3BE7FCCE777EBFCF
- 2422F8DF9ED781A56D0EFB730D56945D0EA9BE3F2F676F3D70DF36C01C15FF0A
- 30AF333BB9E9E74ADF68E4A12A19A8F0851BADB869B6242F00292DD9AE6DBD2B
- BD43273D4E79371D5A1DB05527B807B0BCE7C0FEC1EB20A3373A447B60B5688F
- 544BF0567FA8113393D45970F3C9E265FD7D371448E77C93746442DB6945B322
- D5099ACCD8F8DBD5D0467C90E1EB21178A6D3276979F247748B0A2385C6FC5EA
- 789550A1EBD02247DD57AB964DF4E4A7C9072E487B06B426139E55A2D51E9DE0
- 656051201B030A7C885584BC9073D740C2E55789B6799D0C54964CB1EB0D6065
- 4F81EBC76FFDD9F2E17CE8E0B465BCC18C4763C544CF603B5074C68D5FFFBC16
- C26AE49742C84F4B21677D193252532EC1B5A521E34C76D9CD0FF67B175CFCCC
- 931A056F4BC3700370FFBF2B9D94D02660455F2E060DF01F3C90E062C8371E8B
- FC5EE593606569B8353D69F7803F2B12C8B546C10F109CA9B92D9E8D535A6087
- 05EBFADC1835C0BFCE837C7125E44C2EC94A72E4F4E264F928CB2427AE80BCEF
- 841C9C8771567F6FA2B4C5EDB15D366CF8D48D8928B81B722A07D29305E95E80
- 28383D8FD0F387A78B72C2266E4EC29304D5782E71C10F5D4ACB4C7D92904075
- E1DE64040254FE319577C5283F9209A1EF5A1DE34802D39C2BA0A7B6B7D3936A
- BFBC65B966801FA7E7C7E8F96182D31AD99F06D9930CAD16786A4E04044F6D77
- BB0E9CDB52239F143A75E5F1C05B52206FD9216F5A75922DB33A6482671E5B92
- 73E2E2E335F25DA57F0A382DFB638F1DE70DF09D3648A305B2DD840936DEA669
- 634ACFAD47721D1D639BAA24B47EAD742D344D52DE9A82610A287B0D286C34A3
- 7B87F56FF05A1384E0C2293AC66F35091BAD25DDF6F460758936B1A1424E79D2
- A593AD7FD401E9C880EC4B458436AC3736B770CE10F431FE7741811BEF25128E
- A17F1E3D4554527E7655FEB8DCE993EF4BDD93C0555AEA4D783E5EF954EC2568
- 2F5F2D8668E455A0CA58AF139C2E5AD82FD5CBE5FC9A0239CE716B2867970A3B
- BB4BA52AD121D2DA24126D25C9704C2543DCB3263A4DBBF39DAD91DBBD12C84B
- 9904DE6CC7A0BAA1666A26F59D80C524E88BA924AC26AE5E418305777F5EE414
- 5E3AC20E95362A6752D48DB47936E0C69A97003B053DA3CE82E0115A55A613A8
- 32391A7ADBD9400AFC9D5426C48CA3AA9BE74260ACA5652BF8BE18B548FDE0F5
- E662F40E2BE5CC77880B965C0EF8B4F7818A1F6D7982F1DBF85F801B15FC059E
- 6028BEE22B69170000000049454E44AE426082}
+ 0AE900000AE901FD75CED30000040449444154484BB5957B6C53551CC7BF7DAD
+ 7BD0AD2D8F6D74BA413736B060BB65911165BA304702D3C54762A271844002EA
+ 3F90608C9190989868A226C6277B0A38918DC7700CE431301BBAA5080C6510EC
+ D444C32301B465833D7B7FFECEEDE96537ED3209F19B9CA4F79EDFEFF33DE7D7
+ DF391744F4BF0E9D3E07F25AEDD6F7EACD2895AFEE496A7E76E6AE3AE0C52D80
+ 5133F80498D69191D878A5C23B127EA592FACBBDA106331E8BCC4EAD0F80A4E6
+ 0CE7969E12CFE049B783BEB541A90536AB06CF03A6EFECD83BB00834F2A89D94
+ 979792F25A15059EF4051B30B549AD098F9F2C9CD7D7FB482E75CC30507B1A94
+ ED66340953D5A0D188B5D7E74319F682861E06DD2EB4D0E8B33E36799A02E585
+ A13A33964A964EBC42E781D9F6DA0B4BE68D77E7A4D03127A82D154AA301EF8A
+ 458B18D5E06360B63F03FD023EC8BB087A4037168042650F92B27E25F55714C5
+ 94EB0BA0A43BD7F9E7AFBE0CFA7E0654389765ACDE880D324495F61F6C050ACE
+ BA70ED9F8740BC1BBA9A0FFA2B0F74D99B4AC3D56514585E1C8C9AECB01AD7F4
+ 7966DE39E74ED6E0AD2918AA075E526113A4190835028B7BB3301085FFE10605
+ E6802EB94D74B3D24B818AE2508B2DE1AB7E5F7AD89F65D6E0FB18CE5DB34262
+ 74D219086D336165AF0B2351F8C56CD02F0F80CE66F17351269D9E93483FA41B
+ E8C474D0510768FF348CF1EE5F90E9318A3110DA61C1EA332E8C6B7017E85426
+ A83B1DD435131A9C6B1EE69ABF2AD3E22AAE81505302DE64A83219FC80EC1619
+ 3EA9263510A7705722FC7E86FFC8F0CE09F043696ADD95DA88812192115F710D
+ B8A6966F6C0935E79F58A844E1C7197E84E10719CEA5A1BD29A09D89506A80B7
+ 645A5CC518303CB9CDE5DC77636335FD94EF9814DE9C04FADA0AFAD2AC9A6C94
+ E931D219303CEDC8DCCC13775EAFA6DF2A7C31702ED9DF3BADB815856FB7801A
+ 4CA0AD068CF3C15B27313A69065C73F3A12C7BFBE8BA4A0AAE5A4E9DB30C3A78
+ 4B12867801A59F01F90D46746D3347E0350610C3896FD1519EAB8ED0EE4A3368
+ B659DE1EA82A52C65797D329B78D3AF8001DB683DA53417B9211E632AC8A4472
+ 2CDF330CDDC4EF6E0B78744813BE86EE4A35E095945D5E923346CF78E9F76297
+ 0E2EBAA5CE80F765BC4E0CF330B4878732C168F853A05286440C4E17CCEAA3AA
+ 85746B592E1DE7EB360AE7534A7CB23B4557C9F818716913D868339B0C4DD8C9
+ 20E72C13F3AA41578EA325FC9487FCD9493A789315031C9CA792A610030B19DE
+ 1B35E111E251A21AD49BF0DCCF050EE28F8E38A1D4CA70EE14F1455A2FF3FF93
+ 3E02ACBCA077788C323CCCA52A550DC436F96AE869E31E17F0DDC9DC21461C16
+ A759E6DE93B8648B797C287EAB0642FC797372EB1D142BE7FE0E72C0DCC8CCFD
+ 49331012EDC7657983DB6FAD7C75DF2222FC0B51266D78E692E7220000000049
+ 454E44AE426082}
Instruction.Text = 'Las siguientes facturas no han podido ser eliminadas:'
Instruction.Glyph.Data = {
0A54504E474F626A65637489504E470D0A1A0A0000000D494844520000001C00
@@ -4182,39 +4193,40 @@ inherited fEditorFacturasCliente: TfEditorFacturasCliente
000000180806000000E0773DF8000000017352474200AECE1CE9000000046741
4D410000B18F0BFC6105000000206348524D00007A26000080840000FA000000
80E8000075300000EA6000003A98000017709CBA513C00000009704859730000
- 0AE900000AE901FD75CED3000003F049444154484BBD557B6C53651C3D7DAD7B
- B0ADADC0363ADDA0834D2DDA6E5904A24C17E64864BAF8484C348E104940FD47
- 128D31121213134DD4C4F8644F794C6413188E81A003B3A15B8AC87C4CA39D9A
- 685013515B36D8B3F7E7F9AEDCDAB9760F62BCC94D9ADEEF3BE7FCCE777EBFCF
- 2422F8DF9ED781A56D0EFB730D56945D0EA9BE3F2F676F3D70DF36C01C15FF0A
- 30AF333BB9E9E74ADF68E4A12A19A8F0851BADB869B6242F00292DD9AE6DBD2B
- BD43273D4E79371D5A1DB05527B807B0BCE7C0FEC1EB20A3373A447B60B5688F
- 544BF0567FA8113393D45970F3C9E265FD7D371448E77C93746442DB6945B322
- D5099ACCD8F8DBD5D0467C90E1EB21178A6D3276979F247748B0A2385C6FC5EA
- 789550A1EBD02247DD57AB964DF4E4A7C9072E487B06B426139E55A2D51E9DE0
- 656051201B030A7C885584BC9073D740C2E55789B6799D0C54964CB1EB0D6065
- 4F81EBC76FFDD9F2E17CE8E0B465BCC18C4763C544CF603B5074C68D5FFFBC16
- C26AE49742C84F4B21677D193252532EC1B5A521E34C76D9CD0FF67B175CFCCC
- 931A056F4BC3700370FFBF2B9D94D02660455F2E060DF01F3C90E062C8371E8B
- FC5EE593606569B8353D69F7803F2B12C8B546C10F109CA9B92D9E8D535A6087
- 05EBFADC1835C0BFCE837C7125E44C2EC94A72E4F4E264F928CB2427AE80BCEF
- 841C9C8771567F6FA2B4C5EDB15D366CF8D48D8928B81B722A07D29305E95E80
- 28383D8FD0F387A78B72C2266E4EC29304D5782E71C10F5D4ACB4C7D92904075
- E1DE64040254FE319577C5283F9209A1EF5A1DE34802D39C2BA0A7B6B7D3936A
- BFBC65B966801FA7E7C7E8F96182D31AD99F06D9930CAD16786A4E04044F6D77
- BB0E9CDB52239F143A75E5F1C05B52206FD9216F5A75922DB33A6482671E5B92
- 73E2E2E335F25DA57F0A382DFB638F1DE70DF09D3648A305B2DD840936DEA669
- 634ACFAD47721D1D639BAA24B47EAD742D344D52DE9A82610A287B0D286C34A3
- 7B87F56FF05A1384E0C2293AC66F35091BAD25DDF6F460758936B1A1424E79D2
- A593AD7FD401E9C880EC4B458436AC3736B770CE10F431FE7741811BEF25128E
- A17F1E3D4554527E7655FEB8DCE993EF4BDD93C0555AEA4D783E5EF954EC2568
- 2F5F2D8668E455A0CA58AF139C2E5AD82FD5CBE5FC9A0239CE716B2867970A3B
- BB4BA52AD121D2DA24126D25C9704C2543DCB3263A4DBBF39DAD91DBBD12C84B
- 9904DE6CC7A0BAA1666A26F59D80C524E88BA924AC26AE5E418305777F5EE414
- 5E3AC20E95362A6752D48DB47936E0C69A97003B053DA3CE82E0115A55A613A8
- 32391A7ADBD9400AFC9D5426C48CA3AA9BE74260ACA5652BF8BE18B548FDE0F5
- E662F40E2BE5CC77880B965C0EF8B4F7818A1F6D7982F1DBF85F801B15FC059E
- 6028BEE22B69170000000049454E44AE426082}
+ 0AE900000AE901FD75CED30000040449444154484BB5957B6C53551CC7BF7DAD
+ 7BD0AD2D8F6D74BA413736B060BB65911165BA304702D3C54762A271844002EA
+ 3F90608C9190989868A226C6277B0A38918DC7700CE431301BBAA5080C6510EC
+ D444C32301B465833D7B7FFECEEDE96537ED3209F19B9CA4F79EDFEFF33DE7D7
+ DF391744F4BF0E9D3E07F25AEDD6F7EACD2895AFEE496A7E76E6AE3AE0C52D80
+ 5133F80498D69191D878A5C23B127EA592FACBBDA106331E8BCC4EAD0F80A4E6
+ 0CE7969E12CFE049B783BEB541A90536AB06CF03A6EFECD83BB00834F2A89D94
+ 979792F25A15059EF4051B30B549AD098F9F2C9CD7D7FB482E75CC30507B1A94
+ ED66340953D5A0D188B5D7E74319F682861E06DD2EB4D0E8B33E36799A02E585
+ A13A33964A964EBC42E781D9F6DA0B4BE68D77E7A4D03127A82D154AA301EF8A
+ 458B18D5E06360B63F03FD023EC8BB087A4037168042650F92B27E25F55714C5
+ 94EB0BA0A43BD7F9E7AFBE0CFA7E0654389765ACDE880D324495F61F6C050ACE
+ BA70ED9F8740BC1BBA9A0FFA2B0F74D99B4AC3D56514585E1C8C9AECB01AD7F4
+ 7966DE39E74ED6E0AD2918AA075E526113A4190835028B7BB3301085FFE10605
+ E6802EB94D74B3D24B818AE2508B2DE1AB7E5F7AD89F65D6E0FB18CE5DB34262
+ 74D219086D336165AF0B2351F8C56CD02F0F80CE66F17351269D9E93483FA41B
+ E8C474D0510768FF348CF1EE5F90E9318A3110DA61C1EA332E8C6B7017E85426
+ A83B1DD435131A9C6B1EE69ABF2AD3E22AAE81505302DE64A83219FC80EC1619
+ 3EA9263510A7705722FC7E86FFC8F0CE09F043696ADD95DA88812192115F710D
+ B8A6966F6C0935E79F58A844E1C7197E84E10719CEA5A1BD29A09D89506A80B7
+ 645A5CC518303CB9CDE5DC77636335FD94EF9814DE9C04FADA0AFAD2AC9A6C94
+ E931D219303CEDC8DCCC13775EAFA6DF2A7C31702ED9DF3BADB815856FB7801A
+ 4CA0AD068CF3C15B27313A69065C73F3A12C7BFBE8BA4A0AAE5A4E9DB30C3A78
+ 4B12867801A59F01F90D46746D3347E0350610C3896FD1519EAB8ED0EE4A3368
+ B659DE1EA82A52C65797D329B78D3AF8001DB683DA53417B9211E632AC8A4472
+ 2CDF330CDDC4EF6E0B78744813BE86EE4A35E095945D5E923346CF78E9F76297
+ 0E2EBAA5CE80F765BC4E0CF330B4878732C168F853A05286440C4E17CCEAA3AA
+ 85746B592E1DE7EB360AE7534A7CB23B4557C9F818716913D868339B0C4DD8C9
+ 20E72C13F3AA41578EA325FC9487FCD9493A789315031C9CA792A610030B19DE
+ 1B35E111E251A21AD49BF0DCCF050EE28F8E38A1D4CA70EE14F1455A2FF3FF93
+ 3E02ACBCA077788C323CCCA52A550DC436F96AE869E31E17F0DDC9DC21461C16
+ A759E6DE93B8648B797C287EAB0642FC797372EB1D142BE7FE0E72C0DCC8CCFD
+ 49331012EDC7657983DB6FAD7C75DF2222FC0B51266D78E692E7220000000049
+ 454E44AE426082}
Instruction.Text = 'Las siguientes facturas no han podido ser modificadas:'
Instruction.Glyph.Data = {
0A54504E474F626A65637489504E470D0A1A0A0000000D494844520000001C00
diff --git a/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.pas b/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.pas
index 0a588eb0..ddf4907d 100644
--- a/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.pas
+++ b/Source/Modulos/Facturas de cliente/Views/uEditorFacturasCliente.pas
@@ -48,6 +48,8 @@ type
JSDialog1: TJSDialog;
actGenerarPDF: TAction;
TBXItem44: TTBXItem;
+ actMandarVerifactu: TAction;
+ TBXItem45: TTBXItem;
procedure FormShow(Sender: TObject);
procedure actEliminarUpdate(Sender: TObject);
procedure actNuevaFacturaExecute(Sender: TObject);
@@ -62,6 +64,8 @@ type
procedure actConvertirEnFacturaUpdate(Sender: TObject);
procedure actGenerarPDFExecute(Sender: TObject);
procedure actGenerarPDFUpdate(Sender: TObject);
+ procedure actMandarVerifactuExecute(Sender: TObject);
+ procedure actMandarVerifactuUpdate(Sender: TObject);
private
FFacturas: IBizFacturaCliente;
@@ -287,6 +291,83 @@ begin
end;
+procedure TfEditorFacturasCliente.actMandarVerifactuExecute(Sender: TObject);
+var
+ AFacturas: IBizFacturaCliente;
+ AllItems: Boolean;
+ AListaCausas: TStringList;
+
+begin
+ AFacturas := Nil;
+ AllItems := False;
+ AListaCausas := TStringList.Create;
+
+ if MultiSelect and Assigned(ViewGrid) then
+ AllItems := (ViewGrid.NumSeleccionados > 1);
+
+ if AllItems then
+ begin
+ if (Application.MessageBox('¿Desea mandar a verifactu los borradores seleccionados?, ya no podrá modificarlos', 'Atención', MB_YESNO) = IDYES) then
+ begin
+ SeleccionarFilasDesdeGrid(ViewGrid._FocusedView, (Facturas as ISeleccionable).SelectedRecords);
+ AFacturas := (Controller as IFacturasClienteController).ExtraerSeleccionados(Facturas) as IBizFacturaCliente;
+ end
+ end
+ else begin
+ if (Application.MessageBox('¿Desea mandar a verifactu el borrador seleccionado?, ya no podrá modificarlo', 'Atención', MB_YESNO) = IDYES) then
+ AFacturas := Facturas;
+ end;
+
+ if Assigned(AFacturas) then
+ begin
+ FController.enviarVerifactu(AFacturas, AllItems, AListaCausas);
+
+ if AllItems then
+ begin
+{ if (AFacturas.DataTable.RecordCount > 0) then
+ begin
+ with AFacturas.DataTable do
+ begin
+ JsListaFacturasNoEliminadas.Content.Clear;
+ First;
+ while not EOF do
+ begin
+ JsListaFacturasNoEliminadas.Content.Add('Ref. factura: ' + AFacturas.REFERENCIA + ' ' + AFacturas.NOMBRE);
+ if Length(AListaCausas.Values[IntToStr(AFacturas.ID)]) > 0 then
+ JsListaFacturasNoEliminadas.Content.Add(VarToStr(AListaCausas.Values[IntToStr(AFacturas.ID)]))
+ else
+ JsListaFacturasNoEliminadas.Content.Add('La factura puede tener algún recibo devuelto y no puede ser eliminada');
+ JsListaFacturasNoEliminadas.Content.Add('');
+ Next;
+ end;
+ end;
+ JsListaFacturasNoEliminadas.Execute;
+ end;
+}
+ actRefrescar.Execute;
+ end
+ end;
+
+ AListaCausas.Free;
+ ViewGrid.GotoFirst;
+end;
+
+procedure TfEditorFacturasCliente.actMandarVerifactuUpdate(Sender: TObject);
+begin
+ inherited;
+
+ (Sender as TAction).Enabled := False;
+
+{Quitar al activar verifactu
+ if HayDatos and Assigned(ViewGrid) then
+ (Sender as TAction).Enabled := ViewGrid.EsSeleccionCeldaDatos
+ and (ViewGrid.NumSeleccionados > 0)
+ and (FFacturas.VERIFACTU < 1)
+ else
+ (Sender as TAction).Enabled := False;
+}
+end;
+
procedure TfEditorFacturasCliente.actNuevaFacturaExecute(Sender: TObject);
begin
actNuevo.Execute;
diff --git a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm
index 9785cb9e..daf577e1 100644
--- a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm
+++ b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.dfm
@@ -171,6 +171,24 @@ inherited frViewFacturasCliente: TfrViewFacturasCliente
Caption = 'Otros nombres'
DataBinding.FieldName = 'LISTA_NOMBRES'
end
+ object cxGridViewVERIFACTU: TcxGridDBColumn
+ DataBinding.FieldName = 'VERIFACTU'
+ PropertiesClassName = 'TcxImageComboBoxProperties'
+ Properties.Images = PngImageList
+ Properties.Items = <
+ item
+ Description = 'Verifactu'
+ ImageIndex = 0
+ Value = 1
+ end
+ item
+ Value = 0
+ end>
+ FooterAlignmentHorz = taCenter
+ GroupSummaryAlignment = taCenter
+ HeaderAlignmentHorz = taCenter
+ HeaderGlyphAlignmentHorz = taCenter
+ end
end
inherited cxGridLevel: TcxGridLevel
Caption = 'Todas'
@@ -223,14 +241,12 @@ inherited frViewFacturasCliente: TfrViewFacturasCliente
Width = 273
end
inherited txtFiltroTodo2: TcxTextEdit
- Left = 541
+ Left = 559
Style.LookAndFeel.SkinName = ''
StyleDisabled.LookAndFeel.SkinName = ''
StyleFocused.LookAndFeel.SkinName = ''
StyleHot.LookAndFeel.SkinName = ''
- ExplicitLeft = 541
- ExplicitWidth = 250
- Width = 250
+ ExplicitLeft = 559
end
end
inherited TBXAlignmentPanel1: TTBXAlignmentPanel
diff --git a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas
index 808a53eb..96163f1c 100644
--- a/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas
+++ b/Source/Modulos/Facturas de cliente/Views/uViewFacturasCliente.pas
@@ -71,6 +71,7 @@ type
TBXSeparatorItem3: TTBXSeparatorItem;
TBXItem4: TTBXItem;
cxGridProforma: TcxGridLevel;
+ cxGridViewVERIFACTU: TcxGridDBColumn;
procedure cxGridViewStylesGetContentStyle(Sender: TcxCustomGridTableView;
ARecord: TcxCustomGridRecord; AItem: TcxCustomGridTableItem;
out AStyle: TcxStyle);
diff --git a/Source/Modulos/Pedidos a proveedor/Views/uViewPedidoProveedor.dfm b/Source/Modulos/Pedidos a proveedor/Views/uViewPedidoProveedor.dfm
index fc36f96a..39a34aba 100644
--- a/Source/Modulos/Pedidos a proveedor/Views/uViewPedidoProveedor.dfm
+++ b/Source/Modulos/Pedidos a proveedor/Views/uViewPedidoProveedor.dfm
@@ -15,8 +15,6 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
TabOrder = 0
TabStop = False
AutoContentSizes = [acsWidth, acsHeight]
- ExplicitWidth = 934
- ExplicitHeight = 594
DesignSize = (
1042
619)
@@ -39,8 +37,7 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
inherited dxLayoutControl1: TdxLayoutControl
Height = 225
Align = alClient
- ExplicitWidth = 357
- ExplicitHeight = 215
+ ExplicitHeight = 225
inherited edtlNombre: TcxDBTextEdit
ExplicitWidth = 283
Width = 283
@@ -554,7 +551,7 @@ inherited frViewPedidoProveedor: TfrViewPedidoProveedor
end
end
object dxLayoutControl1Item16: TdxLayoutItem
- Caption = 'Vendedor:'
+ Caption = 'Realizado por:'
Control = cbVendedor
ControlOptions.ShowBorder = False
end
diff --git a/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.dfm b/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.dfm
index e17c3d86..c2423c1f 100644
--- a/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.dfm
+++ b/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.dfm
@@ -175,6 +175,10 @@ inherited frViewPedidosProveedor: TfrViewPedidosProveedor
VisibleForCustomization = False
Width = 57
end
+ object cxGridViewVENDEDOR: TcxGridDBColumn
+ Caption = 'Realizado por'
+ DataBinding.FieldName = 'VENDEDOR'
+ end
end
object cxGridDBTableView1: TcxGridDBTableView [1]
NavigatorButtons.ConfirmDelete = False
diff --git a/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.pas b/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.pas
index 076cff16..221a14b6 100644
--- a/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.pas
+++ b/Source/Modulos/Pedidos a proveedor/Views/uViewPedidosProveedor.pas
@@ -66,6 +66,7 @@ type
actTienda: TAction;
TBXItem4: TTBXItem;
TBXSeparatorItem3: TTBXSeparatorItem;
+ cxGridViewVENDEDOR: TcxGridDBColumn;
procedure cxGridActiveTabChanged(Sender: TcxCustomGrid; ALevel:
TcxGridLevel);
procedure cxGridViewCODIGOCustomDrawCell(Sender: TcxCustomGridTableView;
diff --git a/Source/Modulos/Presupuestos de cliente/Controller/uDetallesPresupuestoClienteController.pas b/Source/Modulos/Presupuestos de cliente/Controller/uDetallesPresupuestoClienteController.pas
index e68844d7..94e430d1 100644
--- a/Source/Modulos/Presupuestos de cliente/Controller/uDetallesPresupuestoClienteController.pas
+++ b/Source/Modulos/Presupuestos de cliente/Controller/uDetallesPresupuestoClienteController.pas
@@ -20,11 +20,12 @@ type
function BuscarCapitulo (const Tipo: String): IBizCapitulo;
procedure SetTipoArticulo(ADetalles: IDAStronglyTypedDataTable; ATipo: String);
procedure SetVisible(ADetalles: IDAStronglyTypedDataTable;const AVisible: Integer;const Orden: Integer); //1Ascendente/0Descendente
- procedure SetVisible2(ADetalles: IDAStronglyTypedDataTable;const AVisible: Integer;const Orden: Integer);
+ procedure SetVisible2(ADetalles: IDAStronglyTypedDataTable;const AVisible: Integer;const Orden: Integer);
end;
TDetallesPresupuestoClienteController = class(TControllerDetallesArticulos, IDetallesPresupuestoClienteController)
private
+ FTipoPresupuesto: Variant;
FDataModule : IDataModulePresupuestosCliente;
function CreateEditor(const AName : String; const IID: TGUID; out Intf): Boolean;
diff --git a/Source/Modulos/Presupuestos de cliente/Controller/uPresupuestosClienteController.pas b/Source/Modulos/Presupuestos de cliente/Controller/uPresupuestosClienteController.pas
index bbc4f369..e9cddd0e 100644
--- a/Source/Modulos/Presupuestos de cliente/Controller/uPresupuestosClienteController.pas
+++ b/Source/Modulos/Presupuestos de cliente/Controller/uPresupuestosClienteController.pas
@@ -110,7 +110,7 @@ type
procedure QuitarDireccionEnvio(APresupuesto: IBizPresupuestoCliente);
- procedure RecalcularImportes(APresupuesto : IBizPresupuestoCliente);
+ procedure RecalcularImportes(APresupuesto : IBizPresupuestoCliente; const DesglosarIVA: Boolean = False);
function EsModificable(APresupuesto : IBizPresupuestoCliente): Boolean;
function EsEliminable(APresupuesto : IBizPresupuestoCliente): Boolean;
@@ -187,7 +187,7 @@ type
function ExtraerSeleccionados(APresupuesto: IBizPresupuestoCliente) : IBizPresupuestoCliente;
function ElegirPresupuestos(APresupuesto: IBizPresupuestoCliente; AMensaje: String; AMultiSelect: Boolean): IBizPresupuestoCliente;
- procedure RecalcularImportes(APresupuesto : IBizPresupuestoCliente);
+ procedure RecalcularImportes(APresupuesto : IBizPresupuestoCliente; const DesglosarIVA: Boolean = False);
function EsModificable(APresupuesto : IBizPresupuestoCliente): Boolean;
function EsEliminable(APresupuesto : IBizPresupuestoCliente): Boolean;
@@ -493,7 +493,7 @@ begin
REFERENCIA := '';
SITUACION := SITUACION_PRESUPUESTO_PENDIENTE;
end;
- Result.AsignarVendedor;
+ Result.AsignarPresupuestador;
Result.Post;
finally
HideHourglassCursor;
@@ -569,8 +569,7 @@ begin
SetDataTableReadOnly(APresupuesto.DataTable, True);
//En el caso de las plantilla dejamos mover el cursor del grid pero sin poder modificar nada
//activamos el grid para que puedan consultar contenido.
- if not (APresupuesto.SITUACION = SITUACION_PRESUPUESTO_PLANTILLA) then
- AEditor.ReadOnly := True;
+ //AEditor.ReadOnly := True;
end;
AEditor.ShowModal;
@@ -790,7 +789,10 @@ begin
if not Assigned(APresupuesto) then
raise Exception.Create ('Presupuesto no asignado: EsEliminable');
- Result := (APresupuesto.SITUACION = SITUACION_PRESUPUESTO_PENDIENTE);
+ Result := (APresupuesto.SITUACION = SITUACION_PRESUPUESTO_PENDIENTE)
+ or ((AppFactuGES.UsuarioActivo.ID_PERFIL = CTE_PREFIL_GERENCIA_COMUN)
+ or (AppFactuGES.UsuarioActivo.ID_PERFIL = CTE_PERFIL_ADMINISTRADOR))
+
end;
function TPresupuestosClienteController.EsModificable(APresupuesto: IBizPresupuestoCliente): Boolean;
@@ -801,8 +803,7 @@ begin
Result := (APresupuesto.SITUACION <> SITUACION_PRESUPUESTO_PLANTILLA);
end;
-procedure TPresupuestosClienteController.RecalcularImportes(
- APresupuesto: IBizPresupuestoCliente);
+procedure TPresupuestosClienteController.RecalcularImportes(APresupuesto: IBizPresupuestoCliente; const DesglosarIVA: Boolean = False);
var
bEnEdicion : Boolean;
ADetallePosAct : Integer;
@@ -826,7 +827,7 @@ begin
ShowHourglassCursor;
try
- APresupuesto.IMPORTE_NETO := FDetallesController.DarTotalImporteTotal(APresupuesto.Detalles);
+ APresupuesto.IMPORTE_NETO := FDetallesController.DarTotalImporteTotal(APresupuesto.Detalles, DesglosarIVA);
APresupuesto.IMPORTE_PORTE := FDetallesController.DarTotalPorteTotal(APresupuesto.Detalles);
if not bEnEdicion then
diff --git a/Source/Modulos/Presupuestos de cliente/Data/uDataModulePresupuestosCliente.dfm b/Source/Modulos/Presupuestos de cliente/Data/uDataModulePresupuestosCliente.dfm
index 2a5e0192..bc9fb958 100644
--- a/Source/Modulos/Presupuestos de cliente/Data/uDataModulePresupuestosCliente.dfm
+++ b/Source/Modulos/Presupuestos de cliente/Data/uDataModulePresupuestosCliente.dfm
@@ -312,6 +312,16 @@ inherited DataModulePresupuestosCliente: TDataModulePresupuestosCliente
item
Name = 'FECHA_ULT_PRESENTACION_CLIENTE'
DataType = datDateTime
+ end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ end
+ item
+ Name = 'PRESUPUESTADOR'
+ DataType = datString
+ Size = 255
+ ServerAutoRefresh = True
end>
Params = <>
StreamingOptions = [soDisableEventsWhileStreaming]
diff --git a/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteClient_Intf.pas b/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteClient_Intf.pas
index d5a1c757..ba349bad 100644
--- a/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteClient_Intf.pas
+++ b/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteClient_Intf.pas
@@ -9,12 +9,12 @@ 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_Valores = '{1C137EA2-79F9-4B4C-905B-31E2F3118006}';
- RID_Propiedades = '{A64DFA30-E2C1-4317-B535-D2FEC9DD5FDC}';
- RID_ListaAnosPresupuestos = '{AFF490F1-4DC0-4717-B4A1-1C66A8BE0B61}';
- RID_PresupuestosCliente = '{CC490968-9BAD-41E4-81CB-A6EEBFE5F382}';
- RID_CapitulosPresupuesto = '{2F44DC36-32F6-45B9-85D6-3D793A9F4AE2}';
- RID_PresupuestosCliente_Detalles = '{C95D5B67-4EC8-4B81-A498-2104C61C977C}';
+ RID_Valores = '{A50539DF-0F94-4F50-B306-92F2530E0DF5}';
+ RID_Propiedades = '{FC2876CF-73B5-4DBD-A896-9B5580E1182C}';
+ RID_ListaAnosPresupuestos = '{3480D852-9D3D-450B-8857-745532FCAF51}';
+ RID_PresupuestosCliente = '{2C9BBE6F-490F-45DE-942A-9A01CEE80892}';
+ RID_CapitulosPresupuesto = '{45D87B74-D253-409A-860C-40D216298F14}';
+ RID_PresupuestosCliente_Detalles = '{D5FCA165-32A0-46FB-B9D0-3B1A4A76E5C8}';
{ Data table names }
nme_Valores = 'Valores';
@@ -102,6 +102,8 @@ const
fld_PresupuestosClienteREFERENCIA_CLIENTE = 'REFERENCIA_CLIENTE';
fld_PresupuestosClienteLISTA_NOMBRES = 'LISTA_NOMBRES';
fld_PresupuestosClienteFECHA_ULT_PRESENTACION_CLIENTE = 'FECHA_ULT_PRESENTACION_CLIENTE';
+ fld_PresupuestosClienteID_PRESUPUESTADOR = 'ID_PRESUPUESTADOR';
+ fld_PresupuestosClientePRESUPUESTADOR = 'PRESUPUESTADOR';
{ PresupuestosCliente field indexes }
idx_PresupuestosClienteID = 0;
@@ -149,6 +151,8 @@ const
idx_PresupuestosClienteREFERENCIA_CLIENTE = 42;
idx_PresupuestosClienteLISTA_NOMBRES = 43;
idx_PresupuestosClienteFECHA_ULT_PRESENTACION_CLIENTE = 44;
+ idx_PresupuestosClienteID_PRESUPUESTADOR = 45;
+ idx_PresupuestosClientePRESUPUESTADOR = 46;
{ CapitulosPresupuesto fields }
fld_CapitulosPresupuestoID = 'ID';
@@ -221,7 +225,7 @@ const
type
{ IValores }
IValores = interface(IDAStronglyTypedDataTable)
- ['{D66A0BC2-1BB9-4699-8E7A-786E0205A42D}']
+ ['{6BA9F35E-B31F-42DD-B267-3A6068D97775}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -328,7 +332,7 @@ type
{ IPropiedades }
IPropiedades = interface(IDAStronglyTypedDataTable)
- ['{5CA94698-11F6-4DAB-82E2-7BC712E7E4D8}']
+ ['{BD401EFD-6694-4728-9B85-36D9ED3B72F8}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -375,7 +379,7 @@ type
{ IListaAnosPresupuestos }
IListaAnosPresupuestos = interface(IDAStronglyTypedDataTable)
- ['{B695311B-59BC-4222-B586-5CE4E46426D5}']
+ ['{187A3EC4-6046-4860-AC38-B25237C36E2D}']
{ Property getters and setters }
function GetANOValue: String;
procedure SetANOValue(const aValue: String);
@@ -410,7 +414,7 @@ type
{ IPresupuestosCliente }
IPresupuestosCliente = interface(IDAStronglyTypedDataTable)
- ['{B2C60249-0034-42C6-ACB9-E6AF356420DD}']
+ ['{9F13C2C0-4480-4495-A41E-0ED3CD8509F4}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -587,6 +591,14 @@ type
procedure SetFECHA_ULT_PRESENTACION_CLIENTEValue(const aValue: DateTime);
function GetFECHA_ULT_PRESENTACION_CLIENTEIsNull: Boolean;
procedure SetFECHA_ULT_PRESENTACION_CLIENTEIsNull(const aValue: Boolean);
+ function GetID_PRESUPUESTADORValue: Integer;
+ procedure SetID_PRESUPUESTADORValue(const aValue: Integer);
+ function GetID_PRESUPUESTADORIsNull: Boolean;
+ procedure SetID_PRESUPUESTADORIsNull(const aValue: Boolean);
+ function GetPRESUPUESTADORValue: String;
+ procedure SetPRESUPUESTADORValue(const aValue: String);
+ function GetPRESUPUESTADORIsNull: Boolean;
+ procedure SetPRESUPUESTADORIsNull(const aValue: Boolean);
{ Properties }
@@ -680,6 +692,10 @@ type
property LISTA_NOMBRESIsNull: Boolean read GetLISTA_NOMBRESIsNull write SetLISTA_NOMBRESIsNull;
property FECHA_ULT_PRESENTACION_CLIENTE: DateTime read GetFECHA_ULT_PRESENTACION_CLIENTEValue write SetFECHA_ULT_PRESENTACION_CLIENTEValue;
property FECHA_ULT_PRESENTACION_CLIENTEIsNull: Boolean read GetFECHA_ULT_PRESENTACION_CLIENTEIsNull write SetFECHA_ULT_PRESENTACION_CLIENTEIsNull;
+ property ID_PRESUPUESTADOR: Integer read GetID_PRESUPUESTADORValue write SetID_PRESUPUESTADORValue;
+ property ID_PRESUPUESTADORIsNull: Boolean read GetID_PRESUPUESTADORIsNull write SetID_PRESUPUESTADORIsNull;
+ property PRESUPUESTADOR: String read GetPRESUPUESTADORValue write SetPRESUPUESTADORValue;
+ property PRESUPUESTADORIsNull: Boolean read GetPRESUPUESTADORIsNull write SetPRESUPUESTADORIsNull;
end;
{ TPresupuestosClienteDataTableRules }
@@ -872,6 +888,14 @@ type
procedure SetFECHA_ULT_PRESENTACION_CLIENTEValue(const aValue: DateTime); virtual;
function GetFECHA_ULT_PRESENTACION_CLIENTEIsNull: Boolean; virtual;
procedure SetFECHA_ULT_PRESENTACION_CLIENTEIsNull(const aValue: Boolean); virtual;
+ function GetID_PRESUPUESTADORValue: Integer; virtual;
+ procedure SetID_PRESUPUESTADORValue(const aValue: Integer); virtual;
+ function GetID_PRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetID_PRESUPUESTADORIsNull(const aValue: Boolean); virtual;
+ function GetPRESUPUESTADORValue: String; virtual;
+ procedure SetPRESUPUESTADORValue(const aValue: String); virtual;
+ function GetPRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetPRESUPUESTADORIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID: Integer read GetIDValue write SetIDValue;
@@ -964,6 +988,10 @@ type
property LISTA_NOMBRESIsNull: Boolean read GetLISTA_NOMBRESIsNull write SetLISTA_NOMBRESIsNull;
property FECHA_ULT_PRESENTACION_CLIENTE: DateTime read GetFECHA_ULT_PRESENTACION_CLIENTEValue write SetFECHA_ULT_PRESENTACION_CLIENTEValue;
property FECHA_ULT_PRESENTACION_CLIENTEIsNull: Boolean read GetFECHA_ULT_PRESENTACION_CLIENTEIsNull write SetFECHA_ULT_PRESENTACION_CLIENTEIsNull;
+ property ID_PRESUPUESTADOR: Integer read GetID_PRESUPUESTADORValue write SetID_PRESUPUESTADORValue;
+ property ID_PRESUPUESTADORIsNull: Boolean read GetID_PRESUPUESTADORIsNull write SetID_PRESUPUESTADORIsNull;
+ property PRESUPUESTADOR: String read GetPRESUPUESTADORValue write SetPRESUPUESTADORValue;
+ property PRESUPUESTADORIsNull: Boolean read GetPRESUPUESTADORIsNull write SetPRESUPUESTADORIsNull;
public
constructor Create(aDataTable: TDADataTable); override;
@@ -973,7 +1001,7 @@ type
{ ICapitulosPresupuesto }
ICapitulosPresupuesto = interface(IDAStronglyTypedDataTable)
- ['{8DDBB981-6B18-428A-9F4E-FF4BE6283AD4}']
+ ['{254BD61D-0CAA-4514-8E0E-AB64926E6DA5}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -1128,7 +1156,7 @@ type
{ IPresupuestosCliente_Detalles }
IPresupuestosCliente_Detalles = interface(IDAStronglyTypedDataTable)
- ['{D156932E-C94A-4BD6-A3CF-B3EF3166E76E}']
+ ['{B99888D1-1407-4023-A400-F1B41ACF9A84}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -2610,6 +2638,48 @@ begin
DataTable.Fields[idx_PresupuestosClienteFECHA_ULT_PRESENTACION_CLIENTE].AsVariant := Null;
end;
+function TPresupuestosClienteDataTableRules.GetID_PRESUPUESTADORValue: Integer;
+begin
+ result := DataTable.Fields[idx_PresupuestosClienteID_PRESUPUESTADOR].AsInteger;
+end;
+
+procedure TPresupuestosClienteDataTableRules.SetID_PRESUPUESTADORValue(const aValue: Integer);
+begin
+ DataTable.Fields[idx_PresupuestosClienteID_PRESUPUESTADOR].AsInteger := aValue;
+end;
+
+function TPresupuestosClienteDataTableRules.GetID_PRESUPUESTADORIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_PresupuestosClienteID_PRESUPUESTADOR].IsNull;
+end;
+
+procedure TPresupuestosClienteDataTableRules.SetID_PRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_PresupuestosClienteID_PRESUPUESTADOR].AsVariant := Null;
+end;
+
+function TPresupuestosClienteDataTableRules.GetPRESUPUESTADORValue: String;
+begin
+ result := DataTable.Fields[idx_PresupuestosClientePRESUPUESTADOR].AsString;
+end;
+
+procedure TPresupuestosClienteDataTableRules.SetPRESUPUESTADORValue(const aValue: String);
+begin
+ DataTable.Fields[idx_PresupuestosClientePRESUPUESTADOR].AsString := aValue;
+end;
+
+function TPresupuestosClienteDataTableRules.GetPRESUPUESTADORIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_PresupuestosClientePRESUPUESTADOR].IsNull;
+end;
+
+procedure TPresupuestosClienteDataTableRules.SetPRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_PresupuestosClientePRESUPUESTADOR].AsVariant := Null;
+end;
+
{ TCapitulosPresupuestoDataTableRules }
constructor TCapitulosPresupuestoDataTableRules.Create(aDataTable: TDADataTable);
diff --git a/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteServer_Intf.pas b/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteServer_Intf.pas
index 23921c51..577c4053 100644
--- a/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteServer_Intf.pas
+++ b/Source/Modulos/Presupuestos de cliente/Model/schPresupuestosClienteServer_Intf.pas
@@ -9,17 +9,17 @@ 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_ValoresDelta = '{F1287920-FCBE-4504-9B47-E59123D3BDA3}';
- RID_PropiedadesDelta = '{EC69B037-7162-4B60-B280-DC0BE4C2C763}';
- RID_ListaAnosPresupuestosDelta = '{1F8FFF3A-9750-4D9F-944E-3B5A4696FD1C}';
- RID_PresupuestosClienteDelta = '{F7B626AE-70AA-4FEB-8E94-9B5D049DBF5B}';
- RID_CapitulosPresupuestoDelta = '{CDA86224-B80C-4EE6-BA08-1FBE48C27FE6}';
- RID_PresupuestosCliente_DetallesDelta = '{F7A55A7B-967E-410C-AA6D-C1D14E2D57DD}';
+ RID_ValoresDelta = '{7948E371-CD64-4D0C-9E9C-401A8DC37243}';
+ RID_PropiedadesDelta = '{F3EE64C0-99BF-49EC-BA9B-38B7607C525F}';
+ RID_ListaAnosPresupuestosDelta = '{F67788DA-A062-498E-9176-93D02C9684CA}';
+ RID_PresupuestosClienteDelta = '{ED33D82E-0CB2-44D7-8204-9B22F70C9ABC}';
+ RID_CapitulosPresupuestoDelta = '{E97D0DFC-1517-475A-AADC-4CE3C091C7A3}';
+ RID_PresupuestosCliente_DetallesDelta = '{3BA09AF3-28D1-4918-9F7F-B6324CE29BEF}';
type
{ IValoresDelta }
IValoresDelta = interface(IValores)
- ['{F1287920-FCBE-4504-9B47-E59123D3BDA3}']
+ ['{7948E371-CD64-4D0C-9E9C-401A8DC37243}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;
@@ -125,7 +125,7 @@ type
{ IPropiedadesDelta }
IPropiedadesDelta = interface(IPropiedades)
- ['{EC69B037-7162-4B60-B280-DC0BE4C2C763}']
+ ['{F3EE64C0-99BF-49EC-BA9B-38B7607C525F}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldDESCRIPCIONValue : String;
@@ -171,7 +171,7 @@ type
{ IListaAnosPresupuestosDelta }
IListaAnosPresupuestosDelta = interface(IListaAnosPresupuestos)
- ['{1F8FFF3A-9750-4D9F-944E-3B5A4696FD1C}']
+ ['{F67788DA-A062-498E-9176-93D02C9684CA}']
{ Property getters and setters }
function GetOldANOValue : String;
@@ -205,7 +205,7 @@ type
{ IPresupuestosClienteDelta }
IPresupuestosClienteDelta = interface(IPresupuestosCliente)
- ['{F7B626AE-70AA-4FEB-8E94-9B5D049DBF5B}']
+ ['{ED33D82E-0CB2-44D7-8204-9B22F70C9ABC}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_EMPRESAValue : Integer;
@@ -252,6 +252,8 @@ type
function GetOldREFERENCIA_CLIENTEValue : String;
function GetOldLISTA_NOMBRESValue : String;
function GetOldFECHA_ULT_PRESENTACION_CLIENTEValue : DateTime;
+ function GetOldID_PRESUPUESTADORValue : Integer;
+ function GetOldPRESUPUESTADORValue : String;
{ Properties }
property OldID : Integer read GetOldIDValue;
@@ -299,6 +301,8 @@ type
property OldREFERENCIA_CLIENTE : String read GetOldREFERENCIA_CLIENTEValue;
property OldLISTA_NOMBRES : String read GetOldLISTA_NOMBRESValue;
property OldFECHA_ULT_PRESENTACION_CLIENTE : DateTime read GetOldFECHA_ULT_PRESENTACION_CLIENTEValue;
+ property OldID_PRESUPUESTADOR : Integer read GetOldID_PRESUPUESTADORValue;
+ property OldPRESUPUESTADOR : String read GetOldPRESUPUESTADORValue;
end;
{ TPresupuestosClienteBusinessProcessorRules }
@@ -581,6 +585,18 @@ type
function GetOldFECHA_ULT_PRESENTACION_CLIENTEIsNull: Boolean; virtual;
procedure SetFECHA_ULT_PRESENTACION_CLIENTEValue(const aValue: DateTime); virtual;
procedure SetFECHA_ULT_PRESENTACION_CLIENTEIsNull(const aValue: Boolean); virtual;
+ function GetID_PRESUPUESTADORValue: Integer; virtual;
+ function GetID_PRESUPUESTADORIsNull: Boolean; virtual;
+ function GetOldID_PRESUPUESTADORValue: Integer; virtual;
+ function GetOldID_PRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetID_PRESUPUESTADORValue(const aValue: Integer); virtual;
+ procedure SetID_PRESUPUESTADORIsNull(const aValue: Boolean); virtual;
+ function GetPRESUPUESTADORValue: String; virtual;
+ function GetPRESUPUESTADORIsNull: Boolean; virtual;
+ function GetOldPRESUPUESTADORValue: String; virtual;
+ function GetOldPRESUPUESTADORIsNull: Boolean; virtual;
+ procedure SetPRESUPUESTADORValue(const aValue: String); virtual;
+ procedure SetPRESUPUESTADORIsNull(const aValue: Boolean); virtual;
{ Properties }
property ID : Integer read GetIDValue write SetIDValue;
@@ -763,6 +779,14 @@ type
property FECHA_ULT_PRESENTACION_CLIENTEIsNull : Boolean read GetFECHA_ULT_PRESENTACION_CLIENTEIsNull write SetFECHA_ULT_PRESENTACION_CLIENTEIsNull;
property OldFECHA_ULT_PRESENTACION_CLIENTE : DateTime read GetOldFECHA_ULT_PRESENTACION_CLIENTEValue;
property OldFECHA_ULT_PRESENTACION_CLIENTEIsNull : Boolean read GetOldFECHA_ULT_PRESENTACION_CLIENTEIsNull;
+ property ID_PRESUPUESTADOR : Integer read GetID_PRESUPUESTADORValue write SetID_PRESUPUESTADORValue;
+ property ID_PRESUPUESTADORIsNull : Boolean read GetID_PRESUPUESTADORIsNull write SetID_PRESUPUESTADORIsNull;
+ property OldID_PRESUPUESTADOR : Integer read GetOldID_PRESUPUESTADORValue;
+ property OldID_PRESUPUESTADORIsNull : Boolean read GetOldID_PRESUPUESTADORIsNull;
+ property PRESUPUESTADOR : String read GetPRESUPUESTADORValue write SetPRESUPUESTADORValue;
+ property PRESUPUESTADORIsNull : Boolean read GetPRESUPUESTADORIsNull write SetPRESUPUESTADORIsNull;
+ property OldPRESUPUESTADOR : String read GetOldPRESUPUESTADORValue;
+ property OldPRESUPUESTADORIsNull : Boolean read GetOldPRESUPUESTADORIsNull;
public
constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
@@ -772,7 +796,7 @@ type
{ ICapitulosPresupuestoDelta }
ICapitulosPresupuestoDelta = interface(ICapitulosPresupuesto)
- ['{CDA86224-B80C-4EE6-BA08-1FBE48C27FE6}']
+ ['{E97D0DFC-1517-475A-AADC-4CE3C091C7A3}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldPOSICIONValue : Integer;
@@ -926,7 +950,7 @@ type
{ IPresupuestosCliente_DetallesDelta }
IPresupuestosCliente_DetallesDelta = interface(IPresupuestosCliente_Detalles)
- ['{F7A55A7B-967E-410C-AA6D-C1D14E2D57DD}']
+ ['{3BA09AF3-28D1-4918-9F7F-B6324CE29BEF}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldID_PRESUPUESTOValue : Integer;
@@ -2963,6 +2987,68 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClienteFECHA_ULT_PRESENTACION_CLIENTE] := Null;
end;
+function TPresupuestosClienteBusinessProcessorRules.GetID_PRESUPUESTADORValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClienteID_PRESUPUESTADOR];
+end;
+
+function TPresupuestosClienteBusinessProcessorRules.GetID_PRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClienteID_PRESUPUESTADOR]);
+end;
+
+function TPresupuestosClienteBusinessProcessorRules.GetOldID_PRESUPUESTADORValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_PresupuestosClienteID_PRESUPUESTADOR];
+end;
+
+function TPresupuestosClienteBusinessProcessorRules.GetOldID_PRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PresupuestosClienteID_PRESUPUESTADOR]);
+end;
+
+procedure TPresupuestosClienteBusinessProcessorRules.SetID_PRESUPUESTADORValue(const aValue: Integer);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClienteID_PRESUPUESTADOR] := aValue;
+end;
+
+procedure TPresupuestosClienteBusinessProcessorRules.SetID_PRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClienteID_PRESUPUESTADOR] := Null;
+end;
+
+function TPresupuestosClienteBusinessProcessorRules.GetPRESUPUESTADORValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClientePRESUPUESTADOR];
+end;
+
+function TPresupuestosClienteBusinessProcessorRules.GetPRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClientePRESUPUESTADOR]);
+end;
+
+function TPresupuestosClienteBusinessProcessorRules.GetOldPRESUPUESTADORValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_PresupuestosClientePRESUPUESTADOR];
+end;
+
+function TPresupuestosClienteBusinessProcessorRules.GetOldPRESUPUESTADORIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_PresupuestosClientePRESUPUESTADOR]);
+end;
+
+procedure TPresupuestosClienteBusinessProcessorRules.SetPRESUPUESTADORValue(const aValue: String);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClientePRESUPUESTADOR] := aValue;
+end;
+
+procedure TPresupuestosClienteBusinessProcessorRules.SetPRESUPUESTADORIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_PresupuestosClientePRESUPUESTADOR] := Null;
+end;
+
{ TCapitulosPresupuestoBusinessProcessorRules }
constructor TCapitulosPresupuestoBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
diff --git a/Source/Modulos/Presupuestos de cliente/Model/uBizPresupuestosCliente.pas b/Source/Modulos/Presupuestos de cliente/Model/uBizPresupuestosCliente.pas
index 75896f4d..10b41191 100644
--- a/Source/Modulos/Presupuestos de cliente/Model/uBizPresupuestosCliente.pas
+++ b/Source/Modulos/Presupuestos de cliente/Model/uBizPresupuestosCliente.pas
@@ -35,7 +35,7 @@ type
property Detalles: IBizDetallesPresupuestoCliente read GetDetalles write SetDetalles;
procedure CalcularImporteTotal;
- procedure AsignarVendedor;
+ procedure AsignarPresupuestador;
function EsNuevo : Boolean;
function DarListaSituaciones: TStringList;
@@ -84,7 +84,7 @@ type
function DarListaSituaciones: TStringList;
function EsNuevo : Boolean;
- procedure AsignarVendedor;
+ procedure AsignarPresupuestador;
procedure CalcularImporteTotal;
property Cliente : IBizCliente read GetCliente write SetCliente;
property _Cliente : IBizCliente read _GetCliente write _SetCliente;
@@ -222,13 +222,13 @@ begin
inherited;
end;
-procedure TBizPresupuestoCliente.AsignarVendedor;
+procedure TBizPresupuestoCliente.AsignarPresupuestador;
var
AVendedoresController: IVendedoresController;
begin
AVendedoresController := TVendedoresController.Create;
try
- ID_VENDEDOR := AVendedoresController.DarIDVendedorDeUsuario(AppFactuGES.UsuarioActivo.ID);
+ ID_PRESUPUESTADOR := AVendedoresController.DarIDVendedorDeUsuario(AppFactuGES.UsuarioActivo.ID);
finally
AVendedoresController := nil;
end;
@@ -284,7 +284,7 @@ begin
// Self.DataTable.FieldByName(fld_PresupuestosClienteCALIDADES).AsString := AppFactuGES.CalidadesDocumentos;
- AsignarVendedor;
+ AsignarPresupuestador;
end;
procedure TBizPresupuestoCliente.IVAOnChange(Sender: TDACustomField);
diff --git a/Source/Modulos/Presupuestos de cliente/Servidor/srvPresupuestosCliente_Impl.dfm b/Source/Modulos/Presupuestos de cliente/Servidor/srvPresupuestosCliente_Impl.dfm
index e30a94be..ed10e335 100644
--- a/Source/Modulos/Presupuestos de cliente/Servidor/srvPresupuestosCliente_Impl.dfm
+++ b/Source/Modulos/Presupuestos de cliente/Servidor/srvPresupuestosCliente_Impl.dfm
@@ -346,6 +346,14 @@ object srvPresupuestosCliente: TsrvPresupuestosCliente
item
DatasetField = 'FECHA_ULT_PRESENTACION_CLIENTE'
TableField = 'FECHA_ULT_PRESENTACION_CLIENTE'
+ end
+ item
+ DatasetField = 'PRESUPUESTADOR'
+ TableField = 'PRESUPUESTADOR'
+ end
+ item
+ DatasetField = 'ID_PRESUPUESTADOR'
+ TableField = 'ID_PRESUPUESTADOR'
end>
end>
Name = 'PresupuestosCliente'
@@ -591,6 +599,16 @@ object srvPresupuestosCliente: TsrvPresupuestosCliente
item
Name = 'FECHA_ULT_PRESENTACION_CLIENTE'
DataType = datDateTime
+ end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ end
+ item
+ Name = 'PRESUPUESTADOR'
+ DataType = datString
+ Size = 255
+ ServerAutoRefresh = True
end>
end
item
@@ -1114,6 +1132,11 @@ object srvPresupuestosCliente: TsrvPresupuestosCliente
Name = 'FECHA_ULT_PRESENTACION_CLIENTE'
DataType = datDateTime
Value = ''
+ end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ Value = ''
end>
Statements = <
item
@@ -1130,17 +1153,18 @@ object srvPresupuestosCliente: TsrvPresupuestosCliente
'_IVA,'#10' RE, IMPORTE_RE, RECARGO_EQUIVALENCIA, IMPORTE_TOTAL, ' +
'ID_FORMA_PAGO, ID_TIENDA, ID_VENDEDOR,'#10' ID_CONTRATO, NO_VALO' +
'RADO, TIPO_PRESUPUESTO, CALIDADES, REFERENCIA_CLIENTE,'#10' ID_E' +
- 'MPRESA, FECHA_ULT_PRESENTACION_CLIENTE)'#10' VALUES'#10' (:ID,'#10' ' +
- ':FECHA_PRESUPUESTO, :FECHA_VIGENCIA, :FECHA_DECISION, :REFERENCI' +
- 'A,'#10' :SITUACION, :ID_CLIENTE, :ID_DIRECCION, :PERSONA_CONTACT' +
- 'O,'#10' :FORMA_PAGO, :PLAZO_ENTREGA, :OBSERVACIONES, :INCIDENCIA' +
- 'S,'#10' :INCIDENCIAS_ACTIVAS, CURRENT_TIMESTAMP, :USUARIO, :IMPO' +
- 'RTE_NETO, :IMPORTE_PORTE,'#10' :DESCUENTO, :IMPORTE_DESCUENTO, :' +
- 'BASE_IMPONIBLE, :ID_TIPO_IVA, :IVA, :IMPORTE_IVA,'#10' :RE, :IMP' +
- 'ORTE_RE, :RECARGO_EQUIVALENCIA, :IMPORTE_TOTAL, :ID_FORMA_PAGO, ' +
- ':ID_TIENDA, :ID_VENDEDOR,'#10' :ID_CONTRATO, :NO_VALORADO, :TIPO' +
- '_PRESUPUESTO, :CALIDADES, :REFERENCIA_CLIENTE,'#10' :ID_EMPRESA,' +
- ' :FECHA_ULT_PRESENTACION_CLIENTE)'#10' '#10#10#10#10#10
+ 'MPRESA, FECHA_ULT_PRESENTACION_CLIENTE, ID_PRESUPUESTADOR)'#10' VAL' +
+ 'UES'#10' (:ID,'#10' :FECHA_PRESUPUESTO, :FECHA_VIGENCIA, :FECHA_D' +
+ 'ECISION, :REFERENCIA,'#10' :SITUACION, :ID_CLIENTE, :ID_DIRECCIO' +
+ 'N, :PERSONA_CONTACTO,'#10' :FORMA_PAGO, :PLAZO_ENTREGA, :OBSERVA' +
+ 'CIONES, :INCIDENCIAS,'#10' :INCIDENCIAS_ACTIVAS, CURRENT_TIMESTA' +
+ 'MP, :USUARIO, :IMPORTE_NETO, :IMPORTE_PORTE,'#10' :DESCUENTO, :I' +
+ 'MPORTE_DESCUENTO, :BASE_IMPONIBLE, :ID_TIPO_IVA, :IVA, :IMPORTE_' +
+ 'IVA,'#10' :RE, :IMPORTE_RE, :RECARGO_EQUIVALENCIA, :IMPORTE_TOTA' +
+ 'L, :ID_FORMA_PAGO, :ID_TIENDA, :ID_VENDEDOR,'#10' :ID_CONTRATO, ' +
+ ':NO_VALORADO, :TIPO_PRESUPUESTO, :CALIDADES, :REFERENCIA_CLIENTE' +
+ ','#10' :ID_EMPRESA, :FECHA_ULT_PRESENTACION_CLIENTE, :ID_PRESUPU' +
+ 'ESTADOR)'#10' '#10#10#10#10#10
StatementType = stSQL
ColumnMappings = <>
end>
@@ -1359,6 +1383,11 @@ object srvPresupuestosCliente: TsrvPresupuestosCliente
DataType = datDateTime
Value = ''
end
+ item
+ Name = 'ID_PRESUPUESTADOR'
+ DataType = datInteger
+ Value = ''
+ end
item
Name = 'OLD_ID'
Value = ''
@@ -1390,7 +1419,8 @@ object srvPresupuestosCliente: TsrvPresupuestosCliente
'TIPO_PRESUPUESTO = :TIPO_PRESUPUESTO,'#10' CALIDADES = :CALIDADES' +
','#10' REFERENCIA_CLIENTE = :REFERENCIA_CLIENTE,'#10' ID_EMPRESA =' +
' :ID_EMPRESA,'#10' FECHA_ULT_PRESENTACION_CLIENTE = :FECHA_ULT_PR' +
- 'ESENTACION_CLIENTE'#10' WHERE'#10' (ID = :OLD_ID)'#10#10
+ 'ESENTACION_CLIENTE,'#10' ID_PRESUPUESTADOR = :ID_PRESUPUESTADOR'#10' ' +
+ ' WHERE'#10' (ID = :OLD_ID)'#10#10
StatementType = stSQL
ColumnMappings = <>
end>
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.dfm b/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.dfm
index f4f3cf6e..9d2fdac4 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.dfm
+++ b/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.dfm
@@ -185,11 +185,15 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
inherited pgPaginas: TPageControl
Width = 842
Height = 440
+ ActivePage = pagContenido
TabOrder = 1
OnChanging = pgPaginasChanging
+ ExplicitTop = 111
ExplicitWidth = 842
ExplicitHeight = 440
inherited pagGeneral: TTabSheet
+ ExplicitLeft = 4
+ ExplicitTop = 24
ExplicitWidth = 834
ExplicitHeight = 412
inline frViewPresupuestoCliente1: TfrViewPresupuestoCliente
@@ -291,8 +295,8 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
Width = 475
end
inherited memPlazoEntrega: TcxDBMemo
- Top = 407
- ExplicitTop = 407
+ Top = 434
+ ExplicitTop = 434
ExplicitWidth = 396
ExplicitHeight = 100
Height = 100
@@ -353,89 +357,106 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
ExplicitHeight = 412
inherited ToolBar1: TToolBar
Width = 834
+ Height = 46
ExplicitWidth = 834
- inherited FontName: TJvFontComboBox
- ExplicitLeft = 368
+ ExplicitHeight = 46
+ inherited ToolButton3: TToolButton
+ Wrap = False
+ end
+ inherited ToolButton4: TToolButton
+ Left = 278
+ Top = 0
+ Wrap = True
+ ExplicitLeft = 278
ExplicitTop = 0
end
+ inherited ToolButton14: TToolButton
+ Left = 0
+ Wrap = False
+ ExplicitLeft = 0
+ end
+ inherited FontName: TJvFontComboBox
+ Left = 34
+ Top = 22
+ ExplicitLeft = 34
+ ExplicitTop = 22
+ end
inherited FontSize: TEdit
- Left = 513
- Top = 0
- Width = 58
- ExplicitLeft = 513
- ExplicitTop = 0
- ExplicitWidth = 58
+ Left = 179
+ Top = 22
+ ExplicitLeft = 179
+ ExplicitTop = 22
end
inherited UpDown1: TUpDown
- Left = 571
- Top = 0
- ExplicitLeft = 571
- ExplicitTop = 0
+ Left = 301
+ Top = 22
+ ExplicitLeft = 301
+ ExplicitTop = 22
end
inherited ToolButton13: TToolButton
- Left = 588
- Top = 0
- ExplicitLeft = 588
- ExplicitTop = 0
+ Left = 318
+ Top = 22
+ ExplicitLeft = 318
+ ExplicitTop = 22
end
inherited ToolButton6: TToolButton
- Left = 596
- Top = 0
- ExplicitLeft = 596
- ExplicitTop = 0
+ Left = 326
+ Top = 22
+ ExplicitLeft = 326
+ ExplicitTop = 22
end
inherited ToolButton7: TToolButton
- Left = 630
- Top = 0
- ExplicitLeft = 630
- ExplicitTop = 0
+ Left = 360
+ Top = 22
+ ExplicitLeft = 360
+ ExplicitTop = 22
end
inherited ToolButton8: TToolButton
- Left = 664
- Top = 0
- ExplicitLeft = 664
- ExplicitTop = 0
+ Left = 394
+ Top = 22
+ ExplicitLeft = 394
+ ExplicitTop = 22
end
inherited ToolButton12: TToolButton
- Left = 698
- Top = 0
- ExplicitLeft = 698
- ExplicitTop = 0
+ Left = 428
+ Top = 22
+ ExplicitLeft = 428
+ ExplicitTop = 22
end
inherited ToolButton9: TToolButton
- Left = 706
- Top = 0
- ExplicitLeft = 706
- ExplicitTop = 0
+ Left = 436
+ Top = 22
+ ExplicitLeft = 436
+ ExplicitTop = 22
end
inherited ToolButton10: TToolButton
- Left = 740
- Top = 0
- ExplicitLeft = 740
- ExplicitTop = 0
+ Left = 470
+ Top = 22
+ ExplicitLeft = 470
+ ExplicitTop = 22
end
inherited ToolButton11: TToolButton
- Left = 774
- Top = 0
- ExplicitLeft = 774
- ExplicitTop = 0
+ Left = 504
+ Top = 22
+ ExplicitLeft = 504
+ ExplicitTop = 22
end
end
inherited cxGrid: TcxGrid
- Top = 50
+ Top = 72
Width = 834
- Height = 362
- ExplicitTop = 50
+ Height = 340
+ ExplicitTop = 72
ExplicitWidth = 834
- ExplicitHeight = 364
+ ExplicitHeight = 340
end
inherited TBXDock1: TTBXDock
- Top = 24
+ Top = 46
Width = 834
- ExplicitTop = 24
+ ExplicitTop = 46
ExplicitWidth = 834
inherited TBXToolbar1: TTBXToolbar
- ExplicitWidth = 718
+ ExplicitWidth = 806
end
end
inherited cxLookupComboBox1: TcxLookupComboBox
@@ -447,6 +468,13 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
inherited cxLookupComboBox2: TcxLookupComboBox
Style.IsFontAssigned = True
end
+ inherited ActionListContenido: TActionList
+ inherited actDesglosarIVA: TAction
+ Enabled = True
+ Visible = True
+ OnExecute = frViewDetallesPresupuestoCliente1actDesglosarIVAExecute
+ end
+ end
end
end
object pagCalidades: TTabSheet
@@ -526,7 +554,7 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
Width = 834
Height = 384
ExplicitWidth = 834
- ExplicitHeight = 386
+ ExplicitHeight = 384
inherited eIncidencias: TcxDBMemo
ExplicitWidth = 830
ExplicitHeight = 367
@@ -563,8 +591,9 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
inherited ListView1: TListView
Width = 834
Height = 387
+ ExplicitTop = 25
ExplicitWidth = 834
- ExplicitHeight = 391
+ ExplicitHeight = 387
end
inherited EditorActionList: TActionList
Left = 8
@@ -575,6 +604,7 @@ inherited fEditorPresupuestoCliente: TfEditorPresupuestoCliente
end
inherited PnlComentario: TPanel
Width = 848
+ ExplicitTop = 78
ExplicitWidth = 848
inherited lbComentario: TLabel
Width = 838
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.pas b/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.pas
index 254d73af..b0eed7da 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.pas
+++ b/Source/Modulos/Presupuestos de cliente/Views/uEditorPresupuestoCliente.pas
@@ -55,11 +55,12 @@ type
procedure actEnviarPorEMailUpdate(Sender: TObject);
procedure actEliminarUpdate(Sender: TObject);
procedure frViewTotales1bTiposIVAClick(Sender: TObject);
- procedure frViewTotales1eIVAPropertiesValidate(Sender: TObject;
- var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
- procedure OnRecargoEquivalenciaPropertiesValidate(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption;
- var Error: Boolean);
- procedure pagDocumentosShow(Sender: TObject); //Importante en este punto se deben de quitar los eventos que puedan afectar a la tabla una vez se cierre el editor.
+ procedure frViewTotales1eIVAPropertiesValidate(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
+ procedure OnRecargoEquivalenciaPropertiesValidate(Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption; var Error: Boolean);
+ procedure pagDocumentosShow(Sender: TObject);
+ procedure frViewDetallesPresupuestoCliente1actDesglosarIVAExecute(Sender: TObject);
+
+ //Importante en este punto se deben de quitar los eventos que puedan afectar a la tabla una vez se cierre el editor.
private
procedure RecalcularPortePorUnidad;
@@ -109,7 +110,7 @@ type
implementation
uses
- uViewDatosYSeleccionCliente, uDataModuleUsuarios, uClientesController,
+ Dialogs, cxDataUtils, uViewDatosYSeleccionCliente, uDataModuleUsuarios, uClientesController,
uBizDireccionesContacto, uDialogUtils, uFactuGES_App, uDataTableUtils;
{$R *.dfm}
@@ -122,9 +123,22 @@ uses
procedure TfEditorPresupuestoCliente.actEliminarUpdate(Sender: TObject);
begin
inherited;
-// if (Sender as TAction).Enabled then
-// (Sender as TAction).Enabled := (FPresupuesto.SITUACION = SITUACION_PRESUPUESTO_PENDIENTE);
- (Sender as TAction).Enabled := False;
+ if (FPresupuesto.SITUACION = SITUACION_PRESUPUESTO_ACEPTADO) then
+ begin
+ (Sender as TAction).Enabled := false;
+ exit;
+ end;
+
+ if ((AppFactuGES.UsuarioActivo.ID_PERFIL = CTE_PREFIL_GERENCIA_COMUN)
+ or (AppFactuGES.UsuarioActivo.ID_PERFIL = CTE_PERFIL_ADMINISTRADOR))
+ and (lblDesbloquear.Visible = false) then
+ begin
+ (Sender as TAction).Enabled := True;
+ exit;
+ end;
+
+ if not Controller.EsModificable(Presupuesto) then
+ (Sender as TAction).Enabled := False;
end;
procedure TfEditorPresupuestoCliente.actEnviarPorEMailExecute(Sender: TObject);
@@ -165,8 +179,7 @@ begin
FTiposIVAController := TTiposIVAController.Create;
end;
-procedure TfEditorPresupuestoCliente.CustomEditorClose(Sender: TObject;
- var Action: TCloseAction);
+procedure TfEditorPresupuestoCliente.CustomEditorClose(Sender: TObject; var Action: TCloseAction);
begin
inherited;
frViewDetallesPresupuestoCliente1.SaveGridStatus;
@@ -184,6 +197,7 @@ end;
destructor TfEditorPresupuestoCliente.Destroy;
begin
// Utilizar mejor OnClose;
+ frViewDetallesPresupuestoCliente1.cxGridViewIMPORTEUNIDAD.Properties.OnEditValueChanged := Nil;
inherited;
end;
@@ -206,6 +220,18 @@ begin
if not Assigned(Presupuesto) then
raise Exception.Create('No hay ningún presupuesto asignado');
+ //El usuario GERENCIA)
+ if (AppFactuGES.UsuarioActivo.ID_PERFIL = CTE_PREFIL_GERENCIA_COMUN)
+ or (AppFactuGES.UsuarioActivo.ID_PERFIL = CTE_PERFIL_ADMINISTRADOR) then
+ begin
+ lblDesbloquear.Visible := True;
+
+ if not Controller.EsModificable(Presupuesto) then
+ lblDesbloquear.Enabled := True
+ else
+ lblDesbloquear.Enabled := False;
+ end;
+
frViewTotales1.cbRecargoEquivalencia.Properties.OnValidate := OnRecargoEquivalenciaPropertiesValidate;
pgPaginas.ActivePage := pagGeneral;
@@ -213,6 +239,17 @@ begin
frViewDetallesPresupuestoCliente1.RestoreGridStatus;
end;
+procedure TfEditorPresupuestoCliente.frViewDetallesPresupuestoCliente1actDesglosarIVAExecute(Sender: TObject);
+begin
+ inherited;
+ try
+ ShowHourglassCursor;
+ Controller.RecalcularImportes(Presupuesto, True);
+ finally
+ HideHourglassCursor;
+ end;
+end;
+
procedure TfEditorPresupuestoCliente.frViewTotales1bTiposIVAClick(
Sender: TObject);
begin
@@ -327,7 +364,6 @@ procedure TfEditorPresupuestoCliente.OnRecargoEquivalenciaPropertiesValidate(
Sender: TObject; var DisplayValue: Variant; var ErrorText: TCaption;
var Error: Boolean);
begin
-
if frViewTotales1.cbRecargoEquivalencia.Checked then
Presupuesto.RECARGO_EQUIVALENCIA := 1
else
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.dfm b/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.dfm
index 3c996489..bdbab3fc 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.dfm
+++ b/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.dfm
@@ -1,5 +1,89 @@
inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
+ Width = 872
+ Height = 481
+ inherited ToolBar1: TToolBar
+ Width = 872
+ ButtonWidth = 123
+ ExplicitHeight = 73
+ inherited ToolButton1: TToolButton
+ ExplicitWidth = 119
+ end
+ inherited ToolButton2: TToolButton
+ Left = 119
+ ExplicitLeft = 119
+ ExplicitWidth = 127
+ end
+ inherited ToolButton3: TToolButton
+ Left = 246
+ ExplicitLeft = 246
+ ExplicitWidth = 58
+ end
+ inherited ToolButton4: TToolButton
+ Left = 304
+ Wrap = False
+ ExplicitLeft = 304
+ ExplicitWidth = 57
+ end
+ inherited ToolButton14: TToolButton
+ Left = 361
+ Top = 0
+ Wrap = True
+ ExplicitLeft = 361
+ ExplicitTop = 0
+ end
+ inherited FontName: TJvFontComboBox
+ Left = 0
+ ExplicitLeft = 0
+ end
+ inherited ToolButton13: TToolButton [6]
+ Left = 145
+ ExplicitLeft = 145
+ end
+ inherited ToolButton6: TToolButton [7]
+ Left = 153
+ ExplicitLeft = 153
+ end
+ inherited ToolButton7: TToolButton [8]
+ Left = 187
+ ExplicitLeft = 187
+ end
+ inherited ToolButton8: TToolButton [9]
+ Left = 221
+ ExplicitLeft = 221
+ end
+ inherited ToolButton12: TToolButton [10]
+ Left = 255
+ ExplicitLeft = 255
+ end
+ inherited ToolButton9: TToolButton [11]
+ Left = 263
+ ExplicitLeft = 263
+ end
+ inherited ToolButton10: TToolButton [12]
+ Left = 297
+ ExplicitLeft = 297
+ end
+ inherited ToolButton11: TToolButton [13]
+ Left = 331
+ ExplicitLeft = 331
+ end
+ inherited FontSize: TEdit [14]
+ Left = 365
+ Width = 122
+ ExplicitLeft = 365
+ ExplicitWidth = 122
+ end
+ inherited UpDown1: TUpDown [15]
+ Left = 487
+ ExplicitLeft = 487
+ end
+ end
inherited cxGrid: TcxGrid
+ Width = 872
+ Height = 409
+ ExplicitTop = 99
+ ExplicitWidth = 451
+ ExplicitHeight = 205
inherited cxGridView: TcxGridDBTableView
inherited cxGridViewTIPO: TcxGridDBColumn
VisibleForCustomization = False
@@ -72,8 +156,12 @@ inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
end
end
inherited TBXDock1: TTBXDock
+ Width = 872
+ ExplicitTop = 73
+ ExplicitWidth = 451
inherited TBXToolbar1: TTBXToolbar
DockPos = 0
+ ExplicitWidth = 806
object TBXSubmenuItem1: TTBXSubmenuItem [0]
Caption = 'A'#241'adir cap'#237'tulo'
DisplayMode = nbdmImageAndText
@@ -115,11 +203,15 @@ inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
end
object TBXSeparatorItem6: TTBXSeparatorItem [3]
end
- object TBXSeparatorItem9: TTBXSeparatorItem
+ object TBXSeparatorItem9: TTBXSeparatorItem [20]
end
- object TBXItem18: TTBXItem
+ object TBXItem18: TTBXItem [21]
Action = actAsignarDescuento
end
+ inherited TBXItem23: TTBXItem
+ Action = actDesglosarIVA
+ DisplayMode = nbdmImageAndText
+ end
end
end
object cxLookupComboBox1: TcxLookupComboBox [3]
@@ -190,7 +282,7 @@ inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
Width = 145
end
inherited ActionListContenido: TActionList
- object actAsignarDescuento: TAction
+ object actAsignarDescuento: TAction [14]
Category = 'Operaciones'
Caption = 'Asignar descuento'
Enabled = False
@@ -198,46 +290,50 @@ inherited frViewDetallesPresupuestoCliente: TfrViewDetallesPresupuestoCliente
OnExecute = actAsignarDescuentoExecute
OnUpdate = actAsignarDescuentoUpdate
end
- object actCapituloArmarioF: TAction
+ object actCapituloArmarioF: TAction [15]
Category = 'Operaciones'
Caption = 'Capitulo frente de armario'
OnExecute = actCapituloArmarioFExecute
end
- object actCapituloArmarioI: TAction
+ object actCapituloArmarioI: TAction [16]
Category = 'Operaciones'
Caption = 'Capitulo interior de armario'
OnExecute = actCapituloArmarioIExecute
end
- object actCapituloBano: TAction
+ object actCapituloBano: TAction [17]
Category = 'Operaciones'
Caption = 'Capitulo de ba'#241'o'
OnExecute = actCapituloBanoExecute
end
- object actCapituloCocina: TAction
+ object actCapituloCocina: TAction [18]
Category = 'Operaciones'
Caption = 'Cap'#237'tulo de cocina'
OnExecute = actCapituloCocinaExecute
end
- object actCapituloElectrodomesticos: TAction
+ object actCapituloElectrodomesticos: TAction [19]
Category = 'Operaciones'
Caption = 'Cap'#237'tulo de Electrodom'#233'sticos'
OnExecute = actCapituloElectrodomesticosExecute
end
- object actCapituloVarios: TAction
+ object actCapituloVarios: TAction [20]
Category = 'Operaciones'
Caption = 'Cap'#237'tulo de varios'
OnExecute = actCapituloVariosExecute
end
- object actCapituloImportes: TAction
+ object actCapituloImportes: TAction [21]
Category = 'Operaciones'
Caption = 'Capitulo de importes'
OnExecute = actCapituloImportesExecute
end
- object actCapituloObra: TAction
+ object actCapituloObra: TAction [22]
Category = 'Operaciones'
Caption = 'Cap'#237'tulo de obra'
OnExecute = actCapituloObraExecute
end
+ inherited actDesglosarIVA: TAction
+ OnExecute = nil
+ OnUpdate = nil
+ end
end
inherited cxStyleRepository: TcxStyleRepository
inherited cxStyle_IMPORTETOTAL: TcxStyle
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.pas b/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.pas
index 9812e3b3..30331abe 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.pas
+++ b/Source/Modulos/Presupuestos de cliente/Views/uViewDetallesPresupuestoCliente.pas
@@ -74,7 +74,7 @@ type
procedure actAnadirExecute(Sender: TObject);
procedure actCapituloImportesExecute(Sender: TObject);
procedure OnVISIBLEPropertiesEditValueChanged(Sender: TObject);
- procedure OnVISIBLE2PropertiesEditValueChanged(Sender: TObject);
+ procedure OnVISIBLE2PropertiesEditValueChanged(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject);
procedure actCapituloObraExecute(Sender: TObject);
procedure cxLookupComboBox1PropertiesEditValueChanged(Sender: TObject);
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.dfm b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.dfm
index bbbd74ea..b23446d9 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.dfm
+++ b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.dfm
@@ -59,7 +59,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 15
+ TabOrder = 16
Height = 245
Width = 793
end
@@ -221,7 +221,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
Font.Name = 'Tahoma'
Font.Style = []
ParentFont = False
- TabOrder = 14
+ TabOrder = 15
ReadOnly = False
ExplicitLeft = 440
ExplicitTop = 28
@@ -268,7 +268,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
end
object memFormaPago: TcxDBMemo
Left = 22
- Top = 351
+ Top = 378
Anchors = [akLeft, akTop, akRight, akBottom]
DataBinding.DataField = 'FORMA_PAGO'
DataBinding.DataSource = DADataSource
@@ -284,13 +284,13 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 12
+ TabOrder = 13
Height = 44
Width = 475
end
object memPlazoEntrega: TcxDBMemo
Left = 22
- Top = 432
+ Top = 449
Anchors = [akLeft, akTop, akRight, akBottom]
DataBinding.DataField = 'PLAZO_ENTREGA'
DataBinding.DataSource = DADataSource
@@ -306,7 +306,7 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True
- TabOrder = 13
+ TabOrder = 14
Height = 100
Width = 396
end
@@ -384,13 +384,13 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
end
inline frViewTienda1: TfrViewTienda
Left = 22
- Top = 274
+ Top = 301
Width = 451
Height = 41
- TabOrder = 11
+ TabOrder = 12
ReadOnly = False
ExplicitLeft = 22
- ExplicitTop = 274
+ ExplicitTop = 301
end
object edtFechaUltRevision: TcxDBDateEdit
Left = 131
@@ -415,6 +415,36 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
TabOrder = 4
Width = 111
end
+ object cbPresupuestador: TcxDBLookupComboBox
+ Left = 131
+ Top = 244
+ DataBinding.DataField = 'ID_PRESUPUESTADOR'
+ DataBinding.DataSource = DADataSource
+ Properties.KeyFieldNames = 'ID'
+ Properties.ListColumns = <
+ item
+ FieldName = 'NOMBRE'
+ end>
+ Properties.ListOptions.GridLines = glNone
+ Properties.ListOptions.ShowHeader = False
+ Properties.ListOptions.SyncMode = True
+ Properties.ListSource = dsPresupuestador
+ Style.BorderColor = clWindowFrame
+ Style.BorderStyle = ebs3D
+ Style.HotTrack = False
+ Style.LookAndFeel.Kind = lfStandard
+ Style.LookAndFeel.NativeStyle = True
+ Style.ButtonStyle = bts3D
+ Style.PopupBorderStyle = epbsFrame3D
+ StyleDisabled.LookAndFeel.Kind = lfStandard
+ StyleDisabled.LookAndFeel.NativeStyle = True
+ StyleFocused.LookAndFeel.Kind = lfStandard
+ StyleFocused.LookAndFeel.NativeStyle = True
+ StyleHot.LookAndFeel.Kind = lfStandard
+ StyleHot.LookAndFeel.NativeStyle = True
+ TabOrder = 11
+ Width = 279
+ end
object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False
Hidden = True
@@ -532,6 +562,11 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
Control = cbVendedor
ControlOptions.ShowBorder = False
end
+ object dxLayoutControl1Item17: TdxLayoutItem
+ Caption = 'Presupuestador:'
+ Control = cbPresupuestador
+ ControlOptions.ShowBorder = False
+ end
end
end
object dxLayoutControl1Group13: TdxLayoutGroup
@@ -615,4 +650,8 @@ inherited frViewPresupuestoCliente: TfrViewPresupuestoCliente
Left = 80
Top = 16
end
+ object dsPresupuestador: TDADataSource
+ Left = 80
+ Top = 64
+ end
end
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.pas b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.pas
index 337b268b..ea2615ce 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.pas
+++ b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestoCliente.pas
@@ -78,6 +78,9 @@ type
dxLayoutControl1Item16: TdxLayoutItem;
edtFechaUltRevision: TcxDBDateEdit;
dxLayoutControl1Group14: TdxLayoutGroup;
+ dxLayoutControl1Item17: TdxLayoutItem;
+ cbPresupuestador: TcxDBLookupComboBox;
+ dsPresupuestador: TDADataSource;
procedure CustomViewCreate(Sender: TObject);
procedure CustomViewDestroy(Sender: TObject);
procedure bFormasPagoClick(Sender: TObject);
@@ -87,6 +90,7 @@ type
FPresupuesto : IBizPresupuestoCliente;
FFormasPago : IBizFormaPago;
FVendedor : IBizVendedor;
+ FPresupuestador : IBizVendedor;
FFormasPagoController : IFormasPagoController;
FVendedoresController : IVendedoresController;
FViewClientePresupuesto : IViewDatosYSeleccionClientePresupuesto;
@@ -121,6 +125,7 @@ begin
inherited;
FFormasPago := Nil;
FVendedor := Nil;
+ FPresupuestador := Nil;
FFormasPagoController := TFormasPagoController.Create;
FVendedoresController := TVendedoresController.Create;
FViewClientePresupuesto := frViewDatosYSeleccionClientePresupuesto1;
@@ -167,6 +172,7 @@ begin
FFormasPago := Nil;
FFormasPagoController := NIL;
FVendedor := Nil;
+ FPresupuestador := Nil;
FVendedoresController := NIL;
FViewClientePresupuesto := NIL;
end;
@@ -219,12 +225,17 @@ begin
dsVendedor.DataTable := FVendedor.DataTable;
dsVendedor.DataTable.Active := True;
+ FPresupuestador := (FVendedoresController.BuscarTodos as IBizVendedor);
+ dsPresupuestador.DataTable := FPresupuestador.DataTable;
+ dsPresupuestador.DataTable.Active := True;
+
FViewClientePresupuesto.Presupuesto := FPresupuesto;
end
else begin
DADataSource.DataTable := NIL;
dsFormaPago.DataTable := NIL;
- dsVendedor.DataTable := NIL;
+ dsVendedor.DataTable := NIL;
+ dsPresupuestador.DataTable := NIL;
FViewClientePresupuesto.Presupuesto := Nil;
end;
end;
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.dfm b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.dfm
index 950f78b6..92324acb 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.dfm
+++ b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.dfm
@@ -182,6 +182,12 @@ inherited frViewPresupuestosCliente: TfrViewPresupuestosCliente
Caption = 'Fecha '#250'lt. actualizaci'#243'n'
DataBinding.FieldName = 'FECHA_ULT_PRESENTACION_CLIENTE'
end
+ object cxGridViewPRESUPUESTADOR: TcxGridDBColumn
+ Caption = 'Presupuestador'
+ DataBinding.FieldName = 'PRESUPUESTADOR'
+ PropertiesClassName = 'TcxTextEditProperties'
+ Properties.Alignment.Horz = taLeftJustify
+ end
end
inherited cxGridLevel: TcxGridLevel
Caption = 'Todos'
@@ -593,7 +599,7 @@ inherited frViewPresupuestosCliente: TfrViewPresupuestosCliente
end
object cxStylePLANTILLA: TcxStyle
AssignedValues = [svTextColor]
- TextColor = 33023
+ TextColor = 121
end
end
end
diff --git a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.pas b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.pas
index 72b50148..6c3bc1b2 100644
--- a/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.pas
+++ b/Source/Modulos/Presupuestos de cliente/Views/uViewPresupuestosCliente.pas
@@ -58,6 +58,7 @@ type
cxGridViewFECHA_ULT_PRESENTACION_CLIENTE: TcxGridDBColumn;
cxGridPlantillas: TcxGridLevel;
cxStylePLANTILLA: TcxStyle;
+ cxGridViewPRESUPUESTADOR: TcxGridDBColumn;
procedure cxGridActiveTabChanged(Sender: TcxCustomGrid; ALevel:
TcxGridLevel);
procedure cxGridViewStylesGetContentStyle(Sender: TcxCustomGridTableView;
diff --git a/Source/Modulos/Relaciones/Presupuestos de cliente - Contratos de cliente/uGenerarContratosCliUtils.pas b/Source/Modulos/Relaciones/Presupuestos de cliente - Contratos de cliente/uGenerarContratosCliUtils.pas
index c700a393..4103241d 100644
--- a/Source/Modulos/Relaciones/Presupuestos de cliente - Contratos de cliente/uGenerarContratosCliUtils.pas
+++ b/Source/Modulos/Relaciones/Presupuestos de cliente - Contratos de cliente/uGenerarContratosCliUtils.pas
@@ -151,7 +151,8 @@ begin
AContrato.IMPORTE_IVA := APresupuesto.IMPORTE_IVA;
AContrato.IMPORTE_TOTAL := APresupuesto.IMPORTE_TOTAL;
AContrato.ID_TIENDA := APresupuesto.ID_TIENDA;
- AContrato.TIENDA := APresupuesto.TIENDA;
+ AContrato.TIENDA := APresupuesto.TIENDA;
+ AContrato.ID_PRESUPUESTADOR := APresupuesto.ID_PRESUPUESTADOR;
// AContrato.ID_VENDEDOR := APresupuesto.ID_VENDEDOR;
AContrato.RECARGO_EQUIVALENCIA := APresupuesto.RECARGO_EQUIVALENCIA;
AContrato.RE := APresupuesto.RE;
diff --git a/Source/Servicios/FactuGES.RODL b/Source/Servicios/FactuGES.RODL
index c4e11e21..1cba00a4 100644
--- a/Source/Servicios/FactuGES.RODL
+++ b/Source/Servicios/FactuGES.RODL
@@ -400,6 +400,8 @@
+
+
@@ -997,7 +999,7 @@
-
diff --git a/Source/Servicios/FactuGES_Intf.pas b/Source/Servicios/FactuGES_Intf.pas
index 394175f7..4b91aa00 100644
--- a/Source/Servicios/FactuGES_Intf.pas
+++ b/Source/Servicios/FactuGES_Intf.pas
@@ -598,7 +598,8 @@ type
{ IsrvAlbaranesCliente }
IsrvAlbaranesCliente = interface(IDataAbstractService)
['{6E910718-9AB0-47BB-9875-B0DE66A68D7A}']
- function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+ function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean;
+ const VerSoloTotales: Boolean): Binary;
function GenerarInformeEtiquetas(const ID: Integer; const withRefCliente: Boolean): Binary;
end;
@@ -612,7 +613,8 @@ type
protected
function __GetInterfaceName:string; override;
- function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+ function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean;
+ const VerSoloTotales: Boolean): Binary;
function GenerarInformeEtiquetas(const ID: Integer; const withRefCliente: Boolean): Binary;
end;
@@ -2000,7 +2002,8 @@ begin
result := 'srvAlbaranesCliente';
end;
-function TsrvAlbaranesCliente_Proxy.GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary;
+function TsrvAlbaranesCliente_Proxy.GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean;
+ const VerSoloTotales: Boolean): Binary;
begin
try
result := nil;
@@ -2009,6 +2012,7 @@ begin
__Message.Write('VerPrecios', TypeInfo(Boolean), VerPrecios, []);
__Message.Write('VerTrabajos', TypeInfo(Boolean), VerTrabajos, []);
__Message.Write('VerIncidencias', TypeInfo(Boolean), VerIncidencias, []);
+ __Message.Write('VerSoloTotales', TypeInfo(Boolean), VerSoloTotales, []);
__Message.Finalize;
__TransportChannel.Dispatch(__Message);
diff --git a/Source/Servicios/FactuGES_Invk.pas b/Source/Servicios/FactuGES_Invk.pas
index c3326b17..67e88d38 100644
--- a/Source/Servicios/FactuGES_Invk.pas
+++ b/Source/Servicios/FactuGES_Invk.pas
@@ -1177,12 +1177,14 @@ begin
end;
procedure TsrvAlbaranesCliente_Invoker.Invoke_GenerarInforme(const __Instance:IInterface; const __Message:IROMessage; const __Transport:IROTransport; out __oResponseOptions:TROResponseOptions);
-{ function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean): Binary; }
+{ function GenerarInforme(const ListaID: TIntegerArray; const VerPrecios: Boolean; const VerTrabajos: Boolean; const VerIncidencias: Boolean;
+ const VerSoloTotales: Boolean): Binary; }
var
ListaID: FactuGES_Intf.TIntegerArray;
VerPrecios: Boolean;
VerTrabajos: Boolean;
VerIncidencias: Boolean;
+ VerSoloTotales: Boolean;
lResult: Binary;
__lObjectDisposer: TROObjectDisposer;
begin
@@ -1193,8 +1195,9 @@ begin
__Message.Read('VerPrecios', TypeInfo(Boolean), VerPrecios, []);
__Message.Read('VerTrabajos', TypeInfo(Boolean), VerTrabajos, []);
__Message.Read('VerIncidencias', TypeInfo(Boolean), VerIncidencias, []);
+ __Message.Read('VerSoloTotales', TypeInfo(Boolean), VerSoloTotales, []);
- lResult := (__Instance as IsrvAlbaranesCliente).GenerarInforme(ListaID, VerPrecios, VerTrabajos, VerIncidencias);
+ lResult := (__Instance as IsrvAlbaranesCliente).GenerarInforme(ListaID, VerPrecios, VerTrabajos, VerIncidencias, VerSoloTotales);
__Message.InitializeResponseMessage(__Transport, 'FactuGES', 'srvAlbaranesCliente', 'GenerarInformeResponse');
__Message.Write('Result', TypeInfo(Binary), lResult, []);
diff --git a/Source/Servicios/RODLFile.res b/Source/Servicios/RODLFile.res
index a5a471ba..722b420d 100644
Binary files a/Source/Servicios/RODLFile.res and b/Source/Servicios/RODLFile.res differ
diff --git a/Source/Servidor/FactuGES_Server.dpr b/Source/Servidor/FactuGES_Server.dpr
index 85bf600a..77441b3d 100644
--- a/Source/Servidor/FactuGES_Server.dpr
+++ b/Source/Servidor/FactuGES_Server.dpr
@@ -131,15 +131,15 @@ uses
schAlbaranesClienteServer_Intf in '..\Modulos\Albaranes de cliente\Model\schAlbaranesClienteServer_Intf.pas',
schFacturasProveedorClient_Intf in '..\Modulos\Facturas de proveedor\Model\schFacturasProveedorClient_Intf.pas',
schFacturasProveedorServer_Intf in '..\Modulos\Facturas de proveedor\Model\schFacturasProveedorServer_Intf.pas',
- schPresupuestosClienteClient_Intf in '..\Modulos\Presupuestos de cliente\Model\schPresupuestosClienteClient_Intf.pas',
- schPresupuestosClienteServer_Intf in '..\Modulos\Presupuestos de cliente\Model\schPresupuestosClienteServer_Intf.pas',
- schFacturasClienteClient_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteClient_Intf.pas',
- schFacturasClienteServer_Intf in '..\Modulos\Facturas de cliente\Model\schFacturasClienteServer_Intf.pas',
uBizInstaladoresServer in '..\Modulos\Contactos\Model\uBizInstaladoresServer.pas',
schContactosClient_Intf in '..\Modulos\Contactos\Model\schContactosClient_Intf.pas',
schContactosServer_Intf in '..\Modulos\Contactos\Model\schContactosServer_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';
+ schContratosClienteServer_Intf in '..\Modulos\Contratos de cliente\Model\schContratosClienteServer_Intf.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 f87b9622..99748af2 100644
--- a/Source/Servidor/FactuGES_Server.dproj
+++ b/Source/Servidor/FactuGES_Server.dproj
@@ -28,7 +28,7 @@
Delphi.Personality
- FalseTrueFalseTrueFalse5000FalseFalseFalseFalseFalse30821252Rodax Software S.L.5.0.0.0FactuGES (Servidor)5.0.0.0martes, 25 de febrero de 2025 17:26
+ FalseTrueFalseTrueFalse5220FalseFalseFalseFalseFalse30821252Rodax Software S.L.5.2.2.0FactuGES (Servidor)5.2.2.0lunes, 26 de mayo de 2025 10:34
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.rc b/Source/Servidor/FactuGES_Server.rc
index 6c52cb25..e72091ad 100644
--- a/Source/Servidor/FactuGES_Server.rc
+++ b/Source/Servidor/FactuGES_Server.rc
@@ -1,7 +1,7 @@
MAINICON ICON "C:\Codigo Acana\Resources\Iconos\Servidor.ico"
1 VERSIONINFO
-FILEVERSION 5,0,0,0
-PRODUCTVERSION 5,0,0,0
+FILEVERSION 5,2,2,0
+PRODUCTVERSION 5,2,2,0
FILEFLAGSMASK 0x3FL
FILEFLAGS 0x00L
FILEOS 0x40004L
@@ -13,10 +13,10 @@ BEGIN
BLOCK "0C0A04E4"
BEGIN
VALUE "CompanyName", "Rodax Software S.L.\0"
- VALUE "FileVersion", "5.0.0.0\0"
+ VALUE "FileVersion", "5.2.2.0\0"
VALUE "ProductName", "FactuGES (Servidor)\0"
- VALUE "ProductVersion", "5.0.0.0\0"
- VALUE "CompileDate", "martes, 25 de febrero de 2025 18:22\0"
+ VALUE "ProductVersion", "5.2.2.0\0"
+ VALUE "CompileDate", "lunes, 20 de octubre de 2025 11:20\0"
END
END
BLOCK "VarFileInfo"
diff --git a/Source/Servidor/FactuGES_Server.res b/Source/Servidor/FactuGES_Server.res
index 2f81ea48..0fc86396 100644
Binary files a/Source/Servidor/FactuGES_Server.res and b/Source/Servidor/FactuGES_Server.res differ