Repaso de releaciones entre modulos
git-svn-id: https://192.168.0.254/svn/Proyectos.LuisLeon_FactuGES2/trunk@60 b2cfbe5a-eba1-4a0c-8b32-7feea0a119f2
This commit is contained in:
parent
ecbc916cb9
commit
3310838d46
@ -141,7 +141,8 @@ begin
|
|||||||
try
|
try
|
||||||
case Tipo of
|
case Tipo of
|
||||||
txArticulo: AArticulo := CloneDataTable(tbl_Articulos);
|
txArticulo: AArticulo := CloneDataTable(tbl_Articulos);
|
||||||
txProveedor: AArticulo := CloneDataTable(tbl_ArticulosParaCompra);
|
// txProveedor: AArticulo := CloneDataTable(tbl_ArticulosParaCompra); En el caso de tener varios proveedores para un mismo artículo
|
||||||
|
txProveedor: AArticulo := CloneDataTable(tbl_Articulos);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
AsignarClaseNegocio(AArticulo);
|
AsignarClaseNegocio(AArticulo);
|
||||||
|
|||||||
@ -9,6 +9,8 @@
|
|||||||
<Projects Include="..\..\Cliente\FactuGES.dproj" />
|
<Projects Include="..\..\Cliente\FactuGES.dproj" />
|
||||||
<Projects Include="..\..\GUIBase\GUIBase.dproj" />
|
<Projects Include="..\..\GUIBase\GUIBase.dproj" />
|
||||||
<Projects Include="..\..\Servidor\FactuGES_Server.dproj" />
|
<Projects Include="..\..\Servidor\FactuGES_Server.dproj" />
|
||||||
|
<Projects Include="..\Contactos\Controller\Contactos_controller.dproj" />
|
||||||
|
<Projects Include="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" />
|
||||||
<Projects Include="Controller\Comisiones_controller.dproj" />
|
<Projects Include="Controller\Comisiones_controller.dproj" />
|
||||||
<Projects Include="Data\Comisiones_data.dproj" />
|
<Projects Include="Data\Comisiones_data.dproj" />
|
||||||
<Projects Include="Model\Comisiones_model.dproj" />
|
<Projects Include="Model\Comisiones_model.dproj" />
|
||||||
@ -111,14 +113,32 @@
|
|||||||
<Target Name="FactuGES_Server:Make">
|
<Target Name="FactuGES_Server:Make">
|
||||||
<MSBuild Projects="..\..\Servidor\FactuGES_Server.dproj" Targets="Make" />
|
<MSBuild Projects="..\..\Servidor\FactuGES_Server.dproj" Targets="Make" />
|
||||||
</Target>
|
</Target>
|
||||||
|
<Target Name="FacturasCliente_controller">
|
||||||
|
<MSBuild Projects="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" Targets="" />
|
||||||
|
</Target>
|
||||||
|
<Target Name="FacturasCliente_controller:Clean">
|
||||||
|
<MSBuild Projects="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" Targets="Clean" />
|
||||||
|
</Target>
|
||||||
|
<Target Name="FacturasCliente_controller:Make">
|
||||||
|
<MSBuild Projects="..\Facturas de cliente\Controller\FacturasCliente_controller.dproj" Targets="Make" />
|
||||||
|
</Target>
|
||||||
|
<Target Name="Contactos_controller">
|
||||||
|
<MSBuild Projects="..\Contactos\Controller\Contactos_controller.dproj" Targets="" />
|
||||||
|
</Target>
|
||||||
|
<Target Name="Contactos_controller:Clean">
|
||||||
|
<MSBuild Projects="..\Contactos\Controller\Contactos_controller.dproj" Targets="Clean" />
|
||||||
|
</Target>
|
||||||
|
<Target Name="Contactos_controller:Make">
|
||||||
|
<MSBuild Projects="..\Contactos\Controller\Contactos_controller.dproj" Targets="Make" />
|
||||||
|
</Target>
|
||||||
<Target Name="Build">
|
<Target Name="Build">
|
||||||
<CallTarget Targets="Base;GUIBase;ApplicationBase;Comisiones_model;Comisiones_data;Comisiones_controller;Comisiones_view;Comisiones_plugin;FactuGES;FactuGES_Server" />
|
<CallTarget Targets="Base;GUIBase;ApplicationBase;Comisiones_model;Comisiones_data;Comisiones_controller;Comisiones_view;Comisiones_plugin;FactuGES;FactuGES_Server;FacturasCliente_controller;Contactos_controller" />
|
||||||
</Target>
|
</Target>
|
||||||
<Target Name="Clean">
|
<Target Name="Clean">
|
||||||
<CallTarget Targets="Base:Clean;GUIBase:Clean;ApplicationBase:Clean;Comisiones_model:Clean;Comisiones_data:Clean;Comisiones_controller:Clean;Comisiones_view:Clean;Comisiones_plugin:Clean;FactuGES:Clean;FactuGES_Server:Clean" />
|
<CallTarget Targets="Base:Clean;GUIBase:Clean;ApplicationBase:Clean;Comisiones_model:Clean;Comisiones_data:Clean;Comisiones_controller:Clean;Comisiones_view:Clean;Comisiones_plugin:Clean;FactuGES:Clean;FactuGES_Server:Clean;FacturasCliente_controller:Clean;Contactos_controller:Clean" />
|
||||||
</Target>
|
</Target>
|
||||||
<Target Name="Make">
|
<Target Name="Make">
|
||||||
<CallTarget Targets="Base:Make;GUIBase:Make;ApplicationBase:Make;Comisiones_model:Make;Comisiones_data:Make;Comisiones_controller:Make;Comisiones_view:Make;Comisiones_plugin:Make;FactuGES:Make;FactuGES_Server:Make" />
|
<CallTarget Targets="Base:Make;GUIBase:Make;ApplicationBase:Make;Comisiones_model:Make;Comisiones_data:Make;Comisiones_controller:Make;Comisiones_view:Make;Comisiones_plugin:Make;FactuGES:Make;FactuGES_Server:Make;FacturasCliente_controller:Make;Contactos_controller:Make" />
|
||||||
</Target>
|
</Target>
|
||||||
<Import Condition="Exists('$(MSBuildBinPath)\Borland.Group.Targets')" Project="$(MSBuildBinPath)\Borland.Group.Targets" />
|
<Import Condition="Exists('$(MSBuildBinPath)\Borland.Group.Targets')" Project="$(MSBuildBinPath)\Borland.Group.Targets" />
|
||||||
</Project>
|
</Project>
|
||||||
@ -173,42 +173,66 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TComisionesController.AsignarImporteTotal(AComision: IBizComisiones; const ImporteTotal: Variant);
|
procedure TComisionesController.AsignarImporteTotal(AComision: IBizComisiones; const ImporteTotal: Variant);
|
||||||
|
var
|
||||||
|
AEdicion: Boolean;
|
||||||
begin
|
begin
|
||||||
if Assigned(AComision) then
|
if Assigned(AComision) then
|
||||||
begin
|
begin
|
||||||
if (not VarIsNull(ImporteTotal))
|
if (not VarIsNull(ImporteTotal))
|
||||||
and (AComision.DataTable.FieldByName(fld_ComisionesIMPORTE_TOTAL).IsNull or (AComision.IMPORTE_TOTAL <> ImporteTotal)) then
|
and (AComision.DataTable.FieldByName(fld_ComisionesIMPORTE_TOTAL).IsNull or (AComision.IMPORTE_TOTAL <> ImporteTotal)) then
|
||||||
begin
|
begin
|
||||||
AComision.Edit;
|
AEdicion := AComision.DataTable.Editing;
|
||||||
|
if not AEdicion then
|
||||||
|
AComision.Edit;
|
||||||
|
|
||||||
AComision.IMPORTE_TOTAL := ImporteTotal;
|
AComision.IMPORTE_TOTAL := ImporteTotal;
|
||||||
AComision.Post;
|
AComision.Post;
|
||||||
|
|
||||||
|
if AEdicion then
|
||||||
|
AComision.Edit;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TComisionesController.BuscarFacturasDesglosadas(AFacturas: IBizFacturaCliente): IBizFacturasComision;
|
function TComisionesController.BuscarFacturasDesglosadas(AFacturas: IBizFacturaCliente): IBizFacturasComision;
|
||||||
var
|
var
|
||||||
Cadena: String;
|
Condicion: TDAWhereExpression;
|
||||||
|
AArray : Array of TDAWhereExpression;
|
||||||
|
i: Integer;
|
||||||
|
|
||||||
begin
|
begin
|
||||||
if Assigned(AFacturas) then
|
Result := FDataModule.GetFacturasDesglosadas;
|
||||||
|
with Result.DataTable.DynamicWhere do
|
||||||
begin
|
begin
|
||||||
with AFacturas.DataTable do
|
//Solo sacaremos las facturas elegidas y pasadas por parámetro
|
||||||
|
if Assigned(AFacturas) then
|
||||||
begin
|
begin
|
||||||
if not Active then Active := True;
|
with AFacturas.DataTable do
|
||||||
First;
|
|
||||||
Cadena := '';
|
|
||||||
While not Eof do
|
|
||||||
begin
|
begin
|
||||||
if (Length(Cadena) > 0) then
|
if not Active then Active := True;
|
||||||
Cadena := Cadena + ', ';
|
SetLength(AArray, AFacturas.DataTable.RecordCount);
|
||||||
Cadena := Cadena + IntToStr(AFacturas.ID);
|
First;
|
||||||
Next;
|
i := 0;
|
||||||
|
While not Eof do
|
||||||
|
begin
|
||||||
|
AArray[i] := NewConstant(AFacturas.ID, datInteger);
|
||||||
|
Next;
|
||||||
|
Inc(i);
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
Condicion := NewBinaryExpression(NewField('', fld_Facturas_ComisionID_FACTURA), NewList(AArray), dboIn);
|
||||||
|
|
||||||
|
if IsEmpty then
|
||||||
|
Expression := Condicion
|
||||||
|
else
|
||||||
|
Expression := NewBinaryExpression(Expression, Condicion, dboAnd);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
// Showmessage(Cadena);
|
|
||||||
Result := FDataModule.GetFacturasDesglosadas;
|
|
||||||
|
{
|
||||||
with Result.DataTable.Where do
|
with Result.DataTable.Where do
|
||||||
begin
|
begin
|
||||||
if NotEmpty then
|
if NotEmpty then
|
||||||
@ -217,6 +241,7 @@ begin
|
|||||||
AddText('ID_FACTURA in (' + Cadena + ')');
|
AddText('ID_FACTURA in (' + Cadena + ')');
|
||||||
CloseBraket;
|
CloseBraket;
|
||||||
end;
|
end;
|
||||||
|
}
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TComisionesController.BuscarTodos: IBizComisiones;
|
function TComisionesController.BuscarTodos: IBizComisiones;
|
||||||
@ -295,25 +320,28 @@ var
|
|||||||
AEditor : IEditorComision;
|
AEditor : IEditorComision;
|
||||||
begin
|
begin
|
||||||
AEditor := NIL;
|
AEditor := NIL;
|
||||||
ShowHourglassCursor;
|
|
||||||
try
|
|
||||||
// RecuperarObjetos(ARemesaCliente);
|
|
||||||
|
|
||||||
CreateEditor('EditorComision', IEditorComision, AEditor);
|
CreateEditor('EditorComision', IEditorComision, AEditor);
|
||||||
with (AEditor as IEditorComision) do
|
|
||||||
begin
|
|
||||||
Controller := Self; //OJO ORDEN MUY IMPORTANTE
|
|
||||||
Comision := AComision;
|
|
||||||
end;
|
|
||||||
finally
|
|
||||||
HideHourglassCursor;
|
|
||||||
end;
|
|
||||||
|
|
||||||
if Assigned(AEditor) then
|
if Assigned(AEditor) then
|
||||||
try
|
try
|
||||||
AEditor.ShowModal;
|
AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
|
||||||
AEditor.Release;
|
AEditor.Comision := AComision;
|
||||||
|
|
||||||
|
//MODO CONSULTAR
|
||||||
|
// if not EsModificable(AComision) then
|
||||||
|
// begin
|
||||||
|
// SetDataTableReadOnly(AComision.DataTable, True);
|
||||||
|
// AEditor.ReadOnly := True;
|
||||||
|
// end;
|
||||||
|
|
||||||
|
AEditor.ShowModal;
|
||||||
|
|
||||||
|
//MODO CONSULTAR (Se deja la tabla como estaba)
|
||||||
|
// if AEditor.ReadOnly then
|
||||||
|
// SetDataTableReadOnly(AComision.DataTable, False);
|
||||||
finally
|
finally
|
||||||
|
AEditor.Release;
|
||||||
AEditor := NIL;
|
AEditor := NIL;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
@ -323,24 +351,28 @@ var
|
|||||||
AEditor : IEditorComisiones;
|
AEditor : IEditorComisiones;
|
||||||
begin
|
begin
|
||||||
AEditor := NIL;
|
AEditor := NIL;
|
||||||
ShowHourglassCursor;
|
|
||||||
try
|
|
||||||
CreateEditor('EditorComisiones', IEditorComisiones, AEditor);
|
|
||||||
with AEditor do
|
|
||||||
begin
|
|
||||||
Controller := Self; //OJO ORDEN MUY IMPORTANTE
|
|
||||||
Comisiones := AComision;
|
|
||||||
end;
|
|
||||||
finally
|
|
||||||
HideHourglassCursor;
|
|
||||||
end;
|
|
||||||
|
|
||||||
|
CreateEditor('EditorComisiones', IEditorComisiones, AEditor);
|
||||||
if Assigned(AEditor) then
|
if Assigned(AEditor) then
|
||||||
try
|
try
|
||||||
AEditor.ShowEmbedded;
|
// if not EsCadenaVacia(AWindowCaption) then
|
||||||
|
// AEditor.WindowCaption := AWindowCaption;
|
||||||
|
|
||||||
|
// if not EsCadenaVacia(AHeaderText) then
|
||||||
|
// AEditor.HeaderText := AHeaderText;
|
||||||
|
|
||||||
|
AEditor.Controller := Self; //OJO ORDEN MUY IMPORTANTE
|
||||||
|
AEditor.Comisiones := AComision;
|
||||||
|
// AEditor.MultiSelect := True;
|
||||||
|
// if AVerModal then
|
||||||
|
// AEditor.ShowModal
|
||||||
|
// else
|
||||||
|
AEditor.ShowEmbedded;
|
||||||
finally
|
finally
|
||||||
AEditor := NIL;
|
// if AVerModal then
|
||||||
end;
|
// AEditor.Release;
|
||||||
|
AEditor := Nil;
|
||||||
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TComisionesController.ElegirFacturasComision(AComision: IBizComisiones): Boolean;
|
function TComisionesController.ElegirFacturasComision(AComision: IBizComisiones): Boolean;
|
||||||
@ -380,7 +412,8 @@ begin
|
|||||||
ShowHourglassCursor;
|
ShowHourglassCursor;
|
||||||
try
|
try
|
||||||
AFacturasDesglosadas := BuscarFacturasDesglosadas(AFacturasSeleccionadas);
|
AFacturasDesglosadas := BuscarFacturasDesglosadas(AFacturasSeleccionadas);
|
||||||
|
AFacturasDesglosadas.DataTable.Active := True;
|
||||||
|
|
||||||
//Copia las facturas desglosadas de las facturas seleccionadas
|
//Copia las facturas desglosadas de las facturas seleccionadas
|
||||||
DuplicarRegistros(AFacturasDesglosadas.DataTable, AComision.Facturas.DataTable, mdrTodos, True, True, False);
|
DuplicarRegistros(AFacturasDesglosadas.DataTable, AComision.Facturas.DataTable, mdrTodos, True, True, False);
|
||||||
|
|
||||||
|
|||||||
@ -65,17 +65,21 @@ begin
|
|||||||
AStream := FDataModule.GetReport(AComisionID, DesglosadoProv,'', '', Null);
|
AStream := FDataModule.GetReport(AComisionID, DesglosadoProv,'', '', Null);
|
||||||
try
|
try
|
||||||
CreateEditor('EditorComisionesPreview', IEditorComisionesPreview, AEditor);
|
CreateEditor('EditorComisionesPreview', IEditorComisionesPreview, AEditor);
|
||||||
AEditor.DataModule := FDataModule;
|
if Assigned(AEditor) then
|
||||||
AEditor.LoadFromStream(AStream);
|
try
|
||||||
|
AEditor.DataModule := FDataModule;
|
||||||
|
AEditor.LoadFromStream(AStream);
|
||||||
|
AEditor.Preview;
|
||||||
|
finally
|
||||||
|
AEditor.Release;
|
||||||
|
end;
|
||||||
finally
|
finally
|
||||||
AStream.Free;
|
FreeAndNil(AStream);
|
||||||
|
AEditor := Nil;
|
||||||
end;
|
end;
|
||||||
finally
|
finally
|
||||||
HideHourglassCursor;
|
HideHourglassCursor;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
if Assigned(AEditor) then
|
|
||||||
AEditor.Preview;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TComisionesReportController.Print(const AComisionID : Variant; const DesglosadoProv: Boolean);
|
procedure TComisionesReportController.Print(const AComisionID : Variant; const DesglosadoProv: Boolean);
|
||||||
@ -87,20 +91,24 @@ begin
|
|||||||
|
|
||||||
ShowHourglassCursor;
|
ShowHourglassCursor;
|
||||||
try
|
try
|
||||||
AStream := FDataModule.GetReport(AComisionID, DesglosadoProv, '', '', Null);
|
AStream := FDataModule.GetReport(AComisionID, DesglosadoProv,'', '', Null);
|
||||||
try
|
try
|
||||||
CreateEditor('EditorComisionesPreview', IEditorComisionesPreview, AEditor);
|
CreateEditor('EditorComisionesPreview', IEditorComisionesPreview, AEditor);
|
||||||
AEditor.DataModule := FDataModule;
|
if Assigned(AEditor) then
|
||||||
AEditor.LoadFromStream(AStream);
|
try
|
||||||
|
AEditor.DataModule := FDataModule;
|
||||||
|
AEditor.LoadFromStream(AStream);
|
||||||
|
AEditor.Print;
|
||||||
|
finally
|
||||||
|
AEditor.Release;
|
||||||
|
end;
|
||||||
finally
|
finally
|
||||||
AStream.Free;
|
FreeAndNil(AStream);
|
||||||
|
AEditor := Nil;
|
||||||
end;
|
end;
|
||||||
finally
|
finally
|
||||||
HideHourglassCursor;
|
HideHourglassCursor;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
if Assigned(AEditor) then
|
|
||||||
AEditor.Print
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
inherited DataModuleComisiones: TDataModuleComisiones
|
inherited DataModuleComisiones: TDataModuleComisiones
|
||||||
OnCreate = DAClientDataModuleCreate
|
OnCreate = DAClientDataModuleCreate
|
||||||
Height = 248
|
Height = 251
|
||||||
Width = 390
|
Width = 414
|
||||||
object RORemoteService: TRORemoteService
|
object RORemoteService: TRORemoteService
|
||||||
Message = dmConexion.ROMessage
|
Message = dmConexion.ROMessage
|
||||||
Channel = dmConexion.ROChannel
|
Channel = dmConexion.ROChannel
|
||||||
@ -79,6 +79,7 @@ inherited DataModuleComisiones: TDataModuleComisiones
|
|||||||
DataType = datString
|
DataType = datString
|
||||||
Size = 255
|
Size = 255
|
||||||
DisplayLabel = 'Comisiones_NOMBRE'
|
DisplayLabel = 'Comisiones_NOMBRE'
|
||||||
|
ServerAutoRefresh = True
|
||||||
DictionaryEntry = 'Comisiones_NOMBRE'
|
DictionaryEntry = 'Comisiones_NOMBRE'
|
||||||
end>
|
end>
|
||||||
Params = <>
|
Params = <>
|
||||||
@ -175,15 +176,10 @@ inherited DataModuleComisiones: TDataModuleComisiones
|
|||||||
end
|
end
|
||||||
item
|
item
|
||||||
Name = 'IMPORTE_COMISION'
|
Name = 'IMPORTE_COMISION'
|
||||||
DataType = datCurrency
|
DataType = datFloat
|
||||||
DictionaryEntry = 'Facturas_Comision_IMPORTE_COMISION'
|
DictionaryEntry = 'Facturas_Comision_IMPORTE_COMISION'
|
||||||
end>
|
end>
|
||||||
Params = <
|
Params = <>
|
||||||
item
|
|
||||||
Name = 'ID_COMISION'
|
|
||||||
Value = ''
|
|
||||||
ParamType = daptInput
|
|
||||||
end>
|
|
||||||
MasterMappingMode = mmWhere
|
MasterMappingMode = mmWhere
|
||||||
StreamingOptions = [soDisableEventsWhileStreaming]
|
StreamingOptions = [soDisableEventsWhileStreaming]
|
||||||
RemoteDataAdapter = rda_Comisiones
|
RemoteDataAdapter = rda_Comisiones
|
||||||
@ -280,7 +276,7 @@ inherited DataModuleComisiones: TDataModuleComisiones
|
|||||||
end
|
end
|
||||||
item
|
item
|
||||||
Name = 'IMPORTE_COMISION'
|
Name = 'IMPORTE_COMISION'
|
||||||
DataType = datCurrency
|
DataType = datFloat
|
||||||
DictionaryEntry = 'V_Detalles_Facturas_Comision_IMPORTE_COMISION'
|
DictionaryEntry = 'V_Detalles_Facturas_Comision_IMPORTE_COMISION'
|
||||||
end>
|
end>
|
||||||
Params = <>
|
Params = <>
|
||||||
|
|||||||
@ -3,15 +3,15 @@ unit schComisionesClient_Intf;
|
|||||||
interface
|
interface
|
||||||
|
|
||||||
uses
|
uses
|
||||||
Classes, DB, SysUtils, uROClasses, uDAInterfaces, uDADataTable, FmtBCD, uROXMLIntf;
|
Classes, DB, schBase_Intf, SysUtils, uROClasses, uDAInterfaces, uDADataTable, FmtBCD, uROXMLIntf;
|
||||||
|
|
||||||
const
|
const
|
||||||
{ Data table rules ids
|
{ Data table rules ids
|
||||||
Feel free to change them to something more human readable
|
Feel free to change them to something more human readable
|
||||||
but make sure they are unique in the context of your application }
|
but make sure they are unique in the context of your application }
|
||||||
RID_Facturas_Comision = '{69C6A9C2-1439-4AAC-9471-8B3FB42EDFE3}';
|
RID_Facturas_Comision = '{80CF12AA-6D93-492A-BAEF-84156B2B83AE}';
|
||||||
RID_Comisiones = '{81E932F0-7BF0-4C1D-A22F-2FED176FD36A}';
|
RID_Comisiones = '{2E6A5B1C-EC92-4E6D-B986-2445F4AC11D4}';
|
||||||
RID_V_Detalles_Facturas_Comision = '{C60C13FF-26D0-444D-85A3-03DC05AAB574}';
|
RID_V_Detalles_Facturas_Comision = '{01AA2110-3187-4E1E-BE6C-6587A5BEF596}';
|
||||||
|
|
||||||
{ Data table names }
|
{ Data table names }
|
||||||
nme_Facturas_Comision = 'Facturas_Comision';
|
nme_Facturas_Comision = 'Facturas_Comision';
|
||||||
@ -111,7 +111,7 @@ const
|
|||||||
type
|
type
|
||||||
{ IFacturas_Comision }
|
{ IFacturas_Comision }
|
||||||
IFacturas_Comision = interface(IDAStronglyTypedDataTable)
|
IFacturas_Comision = interface(IDAStronglyTypedDataTable)
|
||||||
['{C147ECB9-0DAF-46FD-B1F6-007A2D40E218}']
|
['{6DD26EF2-D21F-4324-94B3-11F17FC3A310}']
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
function GetID_EMPRESAValue: Integer;
|
function GetID_EMPRESAValue: Integer;
|
||||||
procedure SetID_EMPRESAValue(const aValue: Integer);
|
procedure SetID_EMPRESAValue(const aValue: Integer);
|
||||||
@ -169,8 +169,8 @@ type
|
|||||||
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency);
|
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency);
|
||||||
function GetIMPORTE_COMISIONABLEIsNull: Boolean;
|
function GetIMPORTE_COMISIONABLEIsNull: Boolean;
|
||||||
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean);
|
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean);
|
||||||
function GetIMPORTE_COMISIONValue: Currency;
|
function GetIMPORTE_COMISIONValue: Float;
|
||||||
procedure SetIMPORTE_COMISIONValue(const aValue: Currency);
|
procedure SetIMPORTE_COMISIONValue(const aValue: Float);
|
||||||
function GetIMPORTE_COMISIONIsNull: Boolean;
|
function GetIMPORTE_COMISIONIsNull: Boolean;
|
||||||
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean);
|
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean);
|
||||||
|
|
||||||
@ -204,12 +204,12 @@ type
|
|||||||
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
||||||
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
||||||
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
||||||
property IMPORTE_COMISION: Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
property IMPORTE_COMISION: Float read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
||||||
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ TFacturas_ComisionDataTableRules }
|
{ TFacturas_ComisionDataTableRules }
|
||||||
TFacturas_ComisionDataTableRules = class(TDADataTableRules, IFacturas_Comision)
|
TFacturas_ComisionDataTableRules = class(TIntfObjectDADataTableRules, IFacturas_Comision)
|
||||||
private
|
private
|
||||||
protected
|
protected
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
@ -269,8 +269,8 @@ type
|
|||||||
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
||||||
function GetIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
function GetIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
||||||
function GetIMPORTE_COMISIONValue: Currency; virtual;
|
function GetIMPORTE_COMISIONValue: Float; virtual;
|
||||||
procedure SetIMPORTE_COMISIONValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONValue(const aValue: Float); virtual;
|
||||||
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
||||||
|
|
||||||
@ -303,7 +303,7 @@ type
|
|||||||
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
||||||
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
||||||
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
||||||
property IMPORTE_COMISION: Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
property IMPORTE_COMISION: Float read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
||||||
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
||||||
|
|
||||||
public
|
public
|
||||||
@ -314,7 +314,7 @@ type
|
|||||||
|
|
||||||
{ IComisiones }
|
{ IComisiones }
|
||||||
IComisiones = interface(IDAStronglyTypedDataTable)
|
IComisiones = interface(IDAStronglyTypedDataTable)
|
||||||
['{08412911-08D5-4CB6-BD93-E55E146EB577}']
|
['{72453F7B-858F-4439-A873-81D7B0CAE940}']
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
function GetIDValue: Integer;
|
function GetIDValue: Integer;
|
||||||
procedure SetIDValue(const aValue: Integer);
|
procedure SetIDValue(const aValue: Integer);
|
||||||
@ -376,7 +376,7 @@ type
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
{ TComisionesDataTableRules }
|
{ TComisionesDataTableRules }
|
||||||
TComisionesDataTableRules = class(TDADataTableRules, IComisiones)
|
TComisionesDataTableRules = class(TIntfObjectDADataTableRules, IComisiones)
|
||||||
private
|
private
|
||||||
protected
|
protected
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
@ -445,7 +445,7 @@ type
|
|||||||
|
|
||||||
{ IV_Detalles_Facturas_Comision }
|
{ IV_Detalles_Facturas_Comision }
|
||||||
IV_Detalles_Facturas_Comision = interface(IDAStronglyTypedDataTable)
|
IV_Detalles_Facturas_Comision = interface(IDAStronglyTypedDataTable)
|
||||||
['{DF8D0894-2A3B-4713-86FE-C8B816CB3256}']
|
['{8397080E-A3D6-4F0C-B038-85A52551E790}']
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
function GetID_EMPRESAValue: Integer;
|
function GetID_EMPRESAValue: Integer;
|
||||||
procedure SetID_EMPRESAValue(const aValue: Integer);
|
procedure SetID_EMPRESAValue(const aValue: Integer);
|
||||||
@ -503,8 +503,8 @@ type
|
|||||||
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency);
|
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency);
|
||||||
function GetIMPORTE_COMISIONABLEIsNull: Boolean;
|
function GetIMPORTE_COMISIONABLEIsNull: Boolean;
|
||||||
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean);
|
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean);
|
||||||
function GetIMPORTE_COMISIONValue: Currency;
|
function GetIMPORTE_COMISIONValue: Float;
|
||||||
procedure SetIMPORTE_COMISIONValue(const aValue: Currency);
|
procedure SetIMPORTE_COMISIONValue(const aValue: Float);
|
||||||
function GetIMPORTE_COMISIONIsNull: Boolean;
|
function GetIMPORTE_COMISIONIsNull: Boolean;
|
||||||
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean);
|
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean);
|
||||||
|
|
||||||
@ -538,12 +538,12 @@ type
|
|||||||
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
||||||
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
||||||
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
||||||
property IMPORTE_COMISION: Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
property IMPORTE_COMISION: Float read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
||||||
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ TV_Detalles_Facturas_ComisionDataTableRules }
|
{ TV_Detalles_Facturas_ComisionDataTableRules }
|
||||||
TV_Detalles_Facturas_ComisionDataTableRules = class(TDADataTableRules, IV_Detalles_Facturas_Comision)
|
TV_Detalles_Facturas_ComisionDataTableRules = class(TIntfObjectDADataTableRules, IV_Detalles_Facturas_Comision)
|
||||||
private
|
private
|
||||||
protected
|
protected
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
@ -603,8 +603,8 @@ type
|
|||||||
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
||||||
function GetIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
function GetIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
||||||
function GetIMPORTE_COMISIONValue: Currency; virtual;
|
function GetIMPORTE_COMISIONValue: Float; virtual;
|
||||||
procedure SetIMPORTE_COMISIONValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONValue(const aValue: Float); virtual;
|
||||||
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
||||||
|
|
||||||
@ -637,7 +637,7 @@ type
|
|||||||
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull;
|
||||||
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
property IMPORTE_COMISIONABLE: Currency read GetIMPORTE_COMISIONABLEValue write SetIMPORTE_COMISIONABLEValue;
|
||||||
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
property IMPORTE_COMISIONABLEIsNull: Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
||||||
property IMPORTE_COMISION: Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
property IMPORTE_COMISION: Float read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
||||||
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
||||||
|
|
||||||
public
|
public
|
||||||
@ -955,14 +955,14 @@ begin
|
|||||||
DataTable.Fields[idx_Facturas_ComisionIMPORTE_COMISIONABLE].AsVariant := Null;
|
DataTable.Fields[idx_Facturas_ComisionIMPORTE_COMISIONABLE].AsVariant := Null;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TFacturas_ComisionDataTableRules.GetIMPORTE_COMISIONValue: Currency;
|
function TFacturas_ComisionDataTableRules.GetIMPORTE_COMISIONValue: Float;
|
||||||
begin
|
begin
|
||||||
result := DataTable.Fields[idx_Facturas_ComisionIMPORTE_COMISION].AsCurrency;
|
result := DataTable.Fields[idx_Facturas_ComisionIMPORTE_COMISION].AsFloat;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TFacturas_ComisionDataTableRules.SetIMPORTE_COMISIONValue(const aValue: Currency);
|
procedure TFacturas_ComisionDataTableRules.SetIMPORTE_COMISIONValue(const aValue: Float);
|
||||||
begin
|
begin
|
||||||
DataTable.Fields[idx_Facturas_ComisionIMPORTE_COMISION].AsCurrency := aValue;
|
DataTable.Fields[idx_Facturas_ComisionIMPORTE_COMISION].AsFloat := aValue;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TFacturas_ComisionDataTableRules.GetIMPORTE_COMISIONIsNull: boolean;
|
function TFacturas_ComisionDataTableRules.GetIMPORTE_COMISIONIsNull: boolean;
|
||||||
@ -1483,14 +1483,14 @@ begin
|
|||||||
DataTable.Fields[idx_V_Detalles_Facturas_ComisionIMPORTE_COMISIONABLE].AsVariant := Null;
|
DataTable.Fields[idx_V_Detalles_Facturas_ComisionIMPORTE_COMISIONABLE].AsVariant := Null;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TV_Detalles_Facturas_ComisionDataTableRules.GetIMPORTE_COMISIONValue: Currency;
|
function TV_Detalles_Facturas_ComisionDataTableRules.GetIMPORTE_COMISIONValue: Float;
|
||||||
begin
|
begin
|
||||||
result := DataTable.Fields[idx_V_Detalles_Facturas_ComisionIMPORTE_COMISION].AsCurrency;
|
result := DataTable.Fields[idx_V_Detalles_Facturas_ComisionIMPORTE_COMISION].AsFloat;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TV_Detalles_Facturas_ComisionDataTableRules.SetIMPORTE_COMISIONValue(const aValue: Currency);
|
procedure TV_Detalles_Facturas_ComisionDataTableRules.SetIMPORTE_COMISIONValue(const aValue: Float);
|
||||||
begin
|
begin
|
||||||
DataTable.Fields[idx_V_Detalles_Facturas_ComisionIMPORTE_COMISION].AsCurrency := aValue;
|
DataTable.Fields[idx_V_Detalles_Facturas_ComisionIMPORTE_COMISION].AsFloat := aValue;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TV_Detalles_Facturas_ComisionDataTableRules.GetIMPORTE_COMISIONIsNull: boolean;
|
function TV_Detalles_Facturas_ComisionDataTableRules.GetIMPORTE_COMISIONIsNull: boolean;
|
||||||
|
|||||||
@ -9,14 +9,14 @@ const
|
|||||||
{ Delta rules ids
|
{ Delta rules ids
|
||||||
Feel free to change them to something more human readable
|
Feel free to change them to something more human readable
|
||||||
but make sure they are unique in the context of your application }
|
but make sure they are unique in the context of your application }
|
||||||
RID_Facturas_ComisionDelta = '{88A76329-95DC-43B9-B006-2105266C4624}';
|
RID_Facturas_ComisionDelta = '{4C5DE436-DABE-4CF3-82F0-DBE9E5E15ED4}';
|
||||||
RID_ComisionesDelta = '{09A69155-5018-438D-B5C6-F0C7C44D67A1}';
|
RID_ComisionesDelta = '{68D578AF-F1C5-407E-8982-243DEDD3DBC7}';
|
||||||
RID_V_Detalles_Facturas_ComisionDelta = '{E0EC6778-1F46-4E20-AFD3-40F830E827D0}';
|
RID_V_Detalles_Facturas_ComisionDelta = '{F4B4675E-F31B-456C-8523-3BB2CEB9A910}';
|
||||||
|
|
||||||
type
|
type
|
||||||
{ IFacturas_ComisionDelta }
|
{ IFacturas_ComisionDelta }
|
||||||
IFacturas_ComisionDelta = interface(IFacturas_Comision)
|
IFacturas_ComisionDelta = interface(IFacturas_Comision)
|
||||||
['{88A76329-95DC-43B9-B006-2105266C4624}']
|
['{4C5DE436-DABE-4CF3-82F0-DBE9E5E15ED4}']
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
function GetOldID_EMPRESAValue : Integer;
|
function GetOldID_EMPRESAValue : Integer;
|
||||||
function GetOldID_AGENTEValue : Integer;
|
function GetOldID_AGENTEValue : Integer;
|
||||||
@ -32,7 +32,7 @@ type
|
|||||||
function GetOldPROVEEDORValue : String;
|
function GetOldPROVEEDORValue : String;
|
||||||
function GetOldCOMISIONValue : Float;
|
function GetOldCOMISIONValue : Float;
|
||||||
function GetOldIMPORTE_COMISIONABLEValue : Currency;
|
function GetOldIMPORTE_COMISIONABLEValue : Currency;
|
||||||
function GetOldIMPORTE_COMISIONValue : Currency;
|
function GetOldIMPORTE_COMISIONValue : Float;
|
||||||
|
|
||||||
{ Properties }
|
{ Properties }
|
||||||
property OldID_EMPRESA : Integer read GetOldID_EMPRESAValue;
|
property OldID_EMPRESA : Integer read GetOldID_EMPRESAValue;
|
||||||
@ -49,7 +49,7 @@ type
|
|||||||
property OldPROVEEDOR : String read GetOldPROVEEDORValue;
|
property OldPROVEEDOR : String read GetOldPROVEEDORValue;
|
||||||
property OldCOMISION : Float read GetOldCOMISIONValue;
|
property OldCOMISION : Float read GetOldCOMISIONValue;
|
||||||
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
||||||
property OldIMPORTE_COMISION : Currency read GetOldIMPORTE_COMISIONValue;
|
property OldIMPORTE_COMISION : Float read GetOldIMPORTE_COMISIONValue;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ TFacturas_ComisionBusinessProcessorRules }
|
{ TFacturas_ComisionBusinessProcessorRules }
|
||||||
@ -141,11 +141,11 @@ type
|
|||||||
function GetOldIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
function GetOldIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
||||||
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
||||||
function GetIMPORTE_COMISIONValue: Currency; virtual;
|
function GetIMPORTE_COMISIONValue: Float; virtual;
|
||||||
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
||||||
function GetOldIMPORTE_COMISIONValue: Currency; virtual;
|
function GetOldIMPORTE_COMISIONValue: Float; virtual;
|
||||||
function GetOldIMPORTE_COMISIONIsNull: Boolean; virtual;
|
function GetOldIMPORTE_COMISIONIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONValue(const aValue: Float); virtual;
|
||||||
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
||||||
|
|
||||||
{ Properties }
|
{ Properties }
|
||||||
@ -205,9 +205,9 @@ type
|
|||||||
property IMPORTE_COMISIONABLEIsNull : Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
property IMPORTE_COMISIONABLEIsNull : Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
||||||
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
||||||
property OldIMPORTE_COMISIONABLEIsNull : Boolean read GetOldIMPORTE_COMISIONABLEIsNull;
|
property OldIMPORTE_COMISIONABLEIsNull : Boolean read GetOldIMPORTE_COMISIONABLEIsNull;
|
||||||
property IMPORTE_COMISION : Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
property IMPORTE_COMISION : Float read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
||||||
property IMPORTE_COMISIONIsNull : Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
property IMPORTE_COMISIONIsNull : Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
||||||
property OldIMPORTE_COMISION : Currency read GetOldIMPORTE_COMISIONValue;
|
property OldIMPORTE_COMISION : Float read GetOldIMPORTE_COMISIONValue;
|
||||||
property OldIMPORTE_COMISIONIsNull : Boolean read GetOldIMPORTE_COMISIONIsNull;
|
property OldIMPORTE_COMISIONIsNull : Boolean read GetOldIMPORTE_COMISIONIsNull;
|
||||||
|
|
||||||
public
|
public
|
||||||
@ -218,7 +218,7 @@ type
|
|||||||
|
|
||||||
{ IComisionesDelta }
|
{ IComisionesDelta }
|
||||||
IComisionesDelta = interface(IComisiones)
|
IComisionesDelta = interface(IComisiones)
|
||||||
['{09A69155-5018-438D-B5C6-F0C7C44D67A1}']
|
['{68D578AF-F1C5-407E-8982-243DEDD3DBC7}']
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
function GetOldIDValue : Integer;
|
function GetOldIDValue : Integer;
|
||||||
function GetOldID_EMPRESAValue : Integer;
|
function GetOldID_EMPRESAValue : Integer;
|
||||||
@ -348,7 +348,7 @@ type
|
|||||||
|
|
||||||
{ IV_Detalles_Facturas_ComisionDelta }
|
{ IV_Detalles_Facturas_ComisionDelta }
|
||||||
IV_Detalles_Facturas_ComisionDelta = interface(IV_Detalles_Facturas_Comision)
|
IV_Detalles_Facturas_ComisionDelta = interface(IV_Detalles_Facturas_Comision)
|
||||||
['{E0EC6778-1F46-4E20-AFD3-40F830E827D0}']
|
['{F4B4675E-F31B-456C-8523-3BB2CEB9A910}']
|
||||||
{ Property getters and setters }
|
{ Property getters and setters }
|
||||||
function GetOldID_EMPRESAValue : Integer;
|
function GetOldID_EMPRESAValue : Integer;
|
||||||
function GetOldID_AGENTEValue : Integer;
|
function GetOldID_AGENTEValue : Integer;
|
||||||
@ -364,7 +364,7 @@ type
|
|||||||
function GetOldPROVEEDORValue : String;
|
function GetOldPROVEEDORValue : String;
|
||||||
function GetOldCOMISIONValue : Float;
|
function GetOldCOMISIONValue : Float;
|
||||||
function GetOldIMPORTE_COMISIONABLEValue : Currency;
|
function GetOldIMPORTE_COMISIONABLEValue : Currency;
|
||||||
function GetOldIMPORTE_COMISIONValue : Currency;
|
function GetOldIMPORTE_COMISIONValue : Float;
|
||||||
|
|
||||||
{ Properties }
|
{ Properties }
|
||||||
property OldID_EMPRESA : Integer read GetOldID_EMPRESAValue;
|
property OldID_EMPRESA : Integer read GetOldID_EMPRESAValue;
|
||||||
@ -381,7 +381,7 @@ type
|
|||||||
property OldPROVEEDOR : String read GetOldPROVEEDORValue;
|
property OldPROVEEDOR : String read GetOldPROVEEDORValue;
|
||||||
property OldCOMISION : Float read GetOldCOMISIONValue;
|
property OldCOMISION : Float read GetOldCOMISIONValue;
|
||||||
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
||||||
property OldIMPORTE_COMISION : Currency read GetOldIMPORTE_COMISIONValue;
|
property OldIMPORTE_COMISION : Float read GetOldIMPORTE_COMISIONValue;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
{ TV_Detalles_Facturas_ComisionBusinessProcessorRules }
|
{ TV_Detalles_Facturas_ComisionBusinessProcessorRules }
|
||||||
@ -473,11 +473,11 @@ type
|
|||||||
function GetOldIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
function GetOldIMPORTE_COMISIONABLEIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONABLEValue(const aValue: Currency); virtual;
|
||||||
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONABLEIsNull(const aValue: Boolean); virtual;
|
||||||
function GetIMPORTE_COMISIONValue: Currency; virtual;
|
function GetIMPORTE_COMISIONValue: Float; virtual;
|
||||||
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
function GetIMPORTE_COMISIONIsNull: Boolean; virtual;
|
||||||
function GetOldIMPORTE_COMISIONValue: Currency; virtual;
|
function GetOldIMPORTE_COMISIONValue: Float; virtual;
|
||||||
function GetOldIMPORTE_COMISIONIsNull: Boolean; virtual;
|
function GetOldIMPORTE_COMISIONIsNull: Boolean; virtual;
|
||||||
procedure SetIMPORTE_COMISIONValue(const aValue: Currency); virtual;
|
procedure SetIMPORTE_COMISIONValue(const aValue: Float); virtual;
|
||||||
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual;
|
||||||
|
|
||||||
{ Properties }
|
{ Properties }
|
||||||
@ -537,9 +537,9 @@ type
|
|||||||
property IMPORTE_COMISIONABLEIsNull : Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
property IMPORTE_COMISIONABLEIsNull : Boolean read GetIMPORTE_COMISIONABLEIsNull write SetIMPORTE_COMISIONABLEIsNull;
|
||||||
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
property OldIMPORTE_COMISIONABLE : Currency read GetOldIMPORTE_COMISIONABLEValue;
|
||||||
property OldIMPORTE_COMISIONABLEIsNull : Boolean read GetOldIMPORTE_COMISIONABLEIsNull;
|
property OldIMPORTE_COMISIONABLEIsNull : Boolean read GetOldIMPORTE_COMISIONABLEIsNull;
|
||||||
property IMPORTE_COMISION : Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
property IMPORTE_COMISION : Float read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue;
|
||||||
property IMPORTE_COMISIONIsNull : Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
property IMPORTE_COMISIONIsNull : Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull;
|
||||||
property OldIMPORTE_COMISION : Currency read GetOldIMPORTE_COMISIONValue;
|
property OldIMPORTE_COMISION : Float read GetOldIMPORTE_COMISIONValue;
|
||||||
property OldIMPORTE_COMISIONIsNull : Boolean read GetOldIMPORTE_COMISIONIsNull;
|
property OldIMPORTE_COMISIONIsNull : Boolean read GetOldIMPORTE_COMISIONIsNull;
|
||||||
|
|
||||||
public
|
public
|
||||||
@ -998,7 +998,7 @@ begin
|
|||||||
BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISIONABLE] := Null;
|
BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISIONABLE] := Null;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TFacturas_ComisionBusinessProcessorRules.GetIMPORTE_COMISIONValue: Currency;
|
function TFacturas_ComisionBusinessProcessorRules.GetIMPORTE_COMISIONValue: Float;
|
||||||
begin
|
begin
|
||||||
result := BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISION];
|
result := BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISION];
|
||||||
end;
|
end;
|
||||||
@ -1008,7 +1008,7 @@ begin
|
|||||||
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISION]);
|
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISION]);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TFacturas_ComisionBusinessProcessorRules.GetOldIMPORTE_COMISIONValue: Currency;
|
function TFacturas_ComisionBusinessProcessorRules.GetOldIMPORTE_COMISIONValue: Float;
|
||||||
begin
|
begin
|
||||||
result := BusinessProcessor.CurrentChange.OldValueByName[fld_Facturas_ComisionIMPORTE_COMISION];
|
result := BusinessProcessor.CurrentChange.OldValueByName[fld_Facturas_ComisionIMPORTE_COMISION];
|
||||||
end;
|
end;
|
||||||
@ -1018,7 +1018,7 @@ begin
|
|||||||
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_Facturas_ComisionIMPORTE_COMISION]);
|
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_Facturas_ComisionIMPORTE_COMISION]);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TFacturas_ComisionBusinessProcessorRules.SetIMPORTE_COMISIONValue(const aValue: Currency);
|
procedure TFacturas_ComisionBusinessProcessorRules.SetIMPORTE_COMISIONValue(const aValue: Float);
|
||||||
begin
|
begin
|
||||||
BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISION] := aValue;
|
BusinessProcessor.CurrentChange.NewValueByName[fld_Facturas_ComisionIMPORTE_COMISION] := aValue;
|
||||||
end;
|
end;
|
||||||
@ -1766,7 +1766,7 @@ begin
|
|||||||
BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISIONABLE] := Null;
|
BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISIONABLE] := Null;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TV_Detalles_Facturas_ComisionBusinessProcessorRules.GetIMPORTE_COMISIONValue: Currency;
|
function TV_Detalles_Facturas_ComisionBusinessProcessorRules.GetIMPORTE_COMISIONValue: Float;
|
||||||
begin
|
begin
|
||||||
result := BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION];
|
result := BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION];
|
||||||
end;
|
end;
|
||||||
@ -1776,7 +1776,7 @@ begin
|
|||||||
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION]);
|
result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION]);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TV_Detalles_Facturas_ComisionBusinessProcessorRules.GetOldIMPORTE_COMISIONValue: Currency;
|
function TV_Detalles_Facturas_ComisionBusinessProcessorRules.GetOldIMPORTE_COMISIONValue: Float;
|
||||||
begin
|
begin
|
||||||
result := BusinessProcessor.CurrentChange.OldValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION];
|
result := BusinessProcessor.CurrentChange.OldValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION];
|
||||||
end;
|
end;
|
||||||
@ -1786,7 +1786,7 @@ begin
|
|||||||
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION]);
|
result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION]);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TV_Detalles_Facturas_ComisionBusinessProcessorRules.SetIMPORTE_COMISIONValue(const aValue: Currency);
|
procedure TV_Detalles_Facturas_ComisionBusinessProcessorRules.SetIMPORTE_COMISIONValue(const aValue: Float);
|
||||||
begin
|
begin
|
||||||
BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION] := aValue;
|
BusinessProcessor.CurrentChange.NewValueByName[fld_V_Detalles_Facturas_ComisionIMPORTE_COMISION] := aValue;
|
||||||
end;
|
end;
|
||||||
|
|||||||
@ -98,10 +98,6 @@ procedure TBizComisiones.SetFacturas(const Value: IBizFacturasComision);
|
|||||||
begin
|
begin
|
||||||
FFacturas := Value;
|
FFacturas := Value;
|
||||||
EnlazarMaestroDetalle(FFacturasLink, FFacturas);
|
EnlazarMaestroDetalle(FFacturasLink, FFacturas);
|
||||||
|
|
||||||
if Assigned(FFacturas) then
|
|
||||||
if not FFacturas.DataTable.Active then
|
|
||||||
FFacturas.DataTable.Active := True;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
initialization
|
initialization
|
||||||
|
|||||||
@ -3,76 +3,112 @@ unit uBizComisionesServer;
|
|||||||
interface
|
interface
|
||||||
|
|
||||||
uses
|
uses
|
||||||
schComisionesServer_Intf, uDAInterfaces,
|
uDAInterfaces, uDADelta, uDABusinessProcessor,
|
||||||
uDADataTable, uDABusinessProcessor;
|
schComisionesServer_Intf;
|
||||||
|
|
||||||
const
|
const
|
||||||
BIZ_SERVER_COMISIONES = 'Server.Comisiones';
|
BIZ_SERVER_COMISIONES = 'Server.Comisiones';
|
||||||
REF_COMISIONES = 'REF_COMISIONES';
|
|
||||||
|
|
||||||
type
|
type
|
||||||
TBizComisionesServer = class(TComisionesBusinessProcessorRules)
|
TBizComisionesServer = class(TComisionesBusinessProcessorRules)
|
||||||
|
private
|
||||||
|
FReferenciaAutomatica : Boolean;
|
||||||
|
function DarReferencia : String;
|
||||||
|
function IncrementarReferencia : Boolean;
|
||||||
protected
|
protected
|
||||||
procedure BeforeProcessChange(Sender: TDABusinessProcessor;
|
procedure BeforeProcessDelta(Sender: TDABusinessProcessor; const aDelta: IDADelta); override;
|
||||||
aChangeType: TDAChangeType; aChange: TDADeltaChange;
|
procedure AfterProcessChange(Sender: TDABusinessProcessor; aChange: TDADeltaChange; Processed: Boolean;
|
||||||
var ProcessChange: Boolean); override;
|
var CanRemoveFromDelta: Boolean); override;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
implementation
|
implementation
|
||||||
|
|
||||||
uses
|
|
||||||
Dialogs, SysUtils, Variants, uDataModuleServer, uDAClasses, DARemoteService_Impl,
|
|
||||||
schComisionesClient_Intf, uBusinessUtils, uReferenciasUtils, uROClasses;
|
|
||||||
|
|
||||||
{ TBizComisionesServer }
|
{ TBizComisionesServer }
|
||||||
|
|
||||||
procedure TBizComisionesServer.BeforeProcessChange(
|
uses
|
||||||
Sender: TDABusinessProcessor; aChangeType: TDAChangeType;
|
Variants, uDAClasses, uBusinessUtils, uROClasses, uROServer, SysUtils,
|
||||||
aChange: TDADeltaChange; var ProcessChange: Boolean);
|
uDataModuleServer, schComisionesClient_Intf, FactuGES_Intf;
|
||||||
var
|
|
||||||
ASchema : TDASchema;
|
|
||||||
ACurrentConn : IDAConnection;
|
|
||||||
dsData: IDADataset;
|
|
||||||
Empresa : Variant;
|
|
||||||
|
|
||||||
|
const
|
||||||
|
REF_COMISIONES = 'REF_COMISIONES';
|
||||||
|
|
||||||
|
procedure TBizComisionesServer.AfterProcessChange(Sender: TDABusinessProcessor;
|
||||||
|
aChange: TDADeltaChange; Processed: Boolean; var CanRemoveFromDelta: Boolean);
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
case aChangeType of
|
case aChange.ChangeType of
|
||||||
|
ctInsert: begin
|
||||||
|
// Insert_Asiento_Factura(aChange);
|
||||||
|
end;
|
||||||
|
ctUpdate: begin
|
||||||
|
// Update_Asiento_Factura(aChange);
|
||||||
|
end;
|
||||||
|
ctDelete: begin
|
||||||
|
// Delete_Asiento_Factura(aChange);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
{ Por defecto, mantenemos los deltas por si alguna tabla hija los necesita }
|
||||||
|
CanRemoveFromDelta := False;
|
||||||
|
|
||||||
|
case aChange.ChangeType of
|
||||||
|
ctInsert, ctUpdate: begin
|
||||||
|
if FReferenciaAutomatica then
|
||||||
|
begin
|
||||||
|
IncrementarReferencia;
|
||||||
|
FReferenciaAutomatica := False;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
procedure TBizComisionesServer.BeforeProcessDelta(Sender: TDABusinessProcessor;
|
||||||
|
const aDelta: IDADelta);
|
||||||
|
begin
|
||||||
|
FReferenciaAutomatica := False;
|
||||||
|
|
||||||
|
case Sender.CurrentChange.ChangeType of
|
||||||
ctInsert, ctUpdate: begin
|
ctInsert, ctUpdate: begin
|
||||||
//Si la referencia no ha sido asignada le asignamos una nosotros
|
//Si la referencia no ha sido asignada le asignamos una nosotros
|
||||||
if (VarIsNull(aChange.NewValueByName[fld_ComisionesREFERENCIA]))
|
if REFERENCIAIsNull or (Length(REFERENCIA) = 0) then
|
||||||
or (VarToStr(aChange.NewValueByName[fld_ComisionesREFERENCIA]) = '') then
|
|
||||||
begin
|
begin
|
||||||
ASchema := BusinessProcessor.Schema;
|
FReferenciaAutomatica := True;
|
||||||
ACurrentConn := GetBusinessProcessorConnection(BusinessProcessor);
|
REFERENCIA := DarReferencia;
|
||||||
|
|
||||||
try
|
|
||||||
//Siempre va a estar rellena
|
|
||||||
Empresa := aChange.NewValueByName[fld_ComisionesID_EMPRESA];
|
|
||||||
|
|
||||||
dsData := ASchema.NewDataset(ACurrentConn, 'DarReferencia', ['CODIGO', 'EMPRESA'], [REF_COMISIONES, Empresa]);
|
|
||||||
except
|
|
||||||
RaiseError('No existe la tabla REFERENCIAS');
|
|
||||||
end;
|
|
||||||
|
|
||||||
dsData.Active := True;
|
|
||||||
|
|
||||||
if dsData.IsEmpty then
|
|
||||||
RaiseError('NO HAY REFERENCIA ' + REF_COMISIONES + ' DECLARADA EN TABLA REFERENCIAS');
|
|
||||||
|
|
||||||
REFERENCIA := dsData.FieldByName('VALOR').AsString;
|
|
||||||
|
|
||||||
try
|
|
||||||
ASchema.NewCommand(ACurrentConn, 'ModificarReferencia', ['CODIGO', 'VALOR', 'ID_EMPRESA'], [REF_COMISIONES, DarReferenciaSiguiente(REFERENCIA), Empresa]);
|
|
||||||
except
|
|
||||||
RaiseError('Error al asignar la nueva ' + REFERENCIA + ' referencia en tabla');
|
|
||||||
end;
|
|
||||||
|
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
function TBizComisionesServer.DarReferencia: String;
|
||||||
|
var
|
||||||
|
AReferenciasService : IsrvReferencias;
|
||||||
|
Intf : IInterface;
|
||||||
|
AClientID : TGUID;
|
||||||
|
begin
|
||||||
|
// Aunque sea un abono, la referencia es la misma que una factura
|
||||||
|
|
||||||
|
CreateGUID(AClientID);
|
||||||
|
|
||||||
|
GetClassFactory('srvReferencias').CreateInstance(AClientID, Intf);
|
||||||
|
AReferenciasService := Intf as IsrvReferencias;
|
||||||
|
Result := AReferenciasService.DarNuevaReferencia(REF_COMISIONES, ID_EMPRESA)
|
||||||
|
end;
|
||||||
|
|
||||||
|
function TBizComisionesServer.IncrementarReferencia: Boolean;
|
||||||
|
var
|
||||||
|
AReferenciasService : IsrvReferencias;
|
||||||
|
Intf : IInterface;
|
||||||
|
AClientID : TGUID;
|
||||||
|
begin
|
||||||
|
// Aunque sea un abono, la referencia es la misma que una factura
|
||||||
|
|
||||||
|
CreateGUID(AClientID);
|
||||||
|
|
||||||
|
GetClassFactory('srvReferencias').CreateInstance(AClientID, Intf);
|
||||||
|
AReferenciasService := Intf as IsrvReferencias;
|
||||||
|
Result := AReferenciasService.IncrementarValorReferencia(REF_COMISIONES, Self.REFERENCIA, ID_EMPRESA)
|
||||||
|
end;
|
||||||
|
|
||||||
initialization
|
initialization
|
||||||
RegisterBusinessProcessorRules(BIZ_SERVER_COMISIONES, TBizComisionesServer);
|
RegisterBusinessProcessorRules(BIZ_SERVER_COMISIONES, TBizComisionesServer);
|
||||||
|
|
||||||
|
|||||||
935
Source/Modulos/Comisiones/Reports/uRptComisiones_Server.dfm
Normal file
935
Source/Modulos/Comisiones/Reports/uRptComisiones_Server.dfm
Normal file
@ -0,0 +1,935 @@
|
|||||||
|
object RptComisiones: TRptComisiones
|
||||||
|
OldCreateOrder = True
|
||||||
|
OnCreate = DataModuleCreate
|
||||||
|
Height = 405
|
||||||
|
Width = 447
|
||||||
|
object DADataCabecera: TDADataSource
|
||||||
|
DataSet = tbl_Comisiones.Dataset
|
||||||
|
DataTable = tbl_Comisiones
|
||||||
|
Left = 264
|
||||||
|
Top = 72
|
||||||
|
end
|
||||||
|
object tbl_Comisiones: TDACDSDataTable
|
||||||
|
RemoteUpdatesOptions = []
|
||||||
|
Fields = <>
|
||||||
|
Params = <>
|
||||||
|
MasterMappingMode = mmDataRequest
|
||||||
|
LogChanges = False
|
||||||
|
StreamingOptions = [soDisableEventsWhileStreaming]
|
||||||
|
RemoteFetchEnabled = False
|
||||||
|
LocalSchema = schReport
|
||||||
|
LocalDataStreamer = Bin2DataStreamer
|
||||||
|
IndexDefs = <>
|
||||||
|
Left = 264
|
||||||
|
Top = 128
|
||||||
|
end
|
||||||
|
object frxRichObject1: TfrxRichObject
|
||||||
|
Left = 48
|
||||||
|
Top = 296
|
||||||
|
end
|
||||||
|
object frxBarCodeObject1: TfrxBarCodeObject
|
||||||
|
Left = 144
|
||||||
|
Top = 296
|
||||||
|
end
|
||||||
|
object frxOLEObject1: TfrxOLEObject
|
||||||
|
Left = 48
|
||||||
|
Top = 344
|
||||||
|
end
|
||||||
|
object frxCrossObject1: TfrxCrossObject
|
||||||
|
Left = 144
|
||||||
|
Top = 344
|
||||||
|
end
|
||||||
|
object frxCheckBoxObject1: TfrxCheckBoxObject
|
||||||
|
Left = 256
|
||||||
|
Top = 296
|
||||||
|
end
|
||||||
|
object frxGradientObject1: TfrxGradientObject
|
||||||
|
Left = 360
|
||||||
|
Top = 296
|
||||||
|
end
|
||||||
|
object frxChartObject1: TfrxChartObject
|
||||||
|
Left = 256
|
||||||
|
Top = 344
|
||||||
|
end
|
||||||
|
object schReport: TDASchema
|
||||||
|
ConnectionManager = dmServer.ConnectionManager
|
||||||
|
DataDictionary = DataDictionary
|
||||||
|
Datasets = <
|
||||||
|
item
|
||||||
|
Params = <>
|
||||||
|
Statements = <
|
||||||
|
item
|
||||||
|
Connection = 'IBX'
|
||||||
|
TargetTable = 'V_AGENTES_COMISIONES_DET_FAC'
|
||||||
|
SQL =
|
||||||
|
'select'#10' COMISIONES_LIQUIDADAS.FECHA AS FECHA_COMISION,'#10' ' +
|
||||||
|
' COMISIONES_LIQUIDADAS.REFERENCIA AS REFERENCIA_COMISION,'#10' ' +
|
||||||
|
' COMISIONES_LIQUIDADAS.DESCRIPCION,'#10' COMISIONES_LIQUIDA' +
|
||||||
|
'DAS.IMPORTE_TOTAL,'#10#10' V_AGENTES_COMISIONES_DET_FAC.ID_EMPRE' +
|
||||||
|
'SA, EMPRESAS.NIF_CIF as NIF_CIF_EMPRESA, COALESCE(EMPRESAS.RAZON' +
|
||||||
|
'_SOCIAL, EMPRESAS.NOMBRE) as RAZON_SOCIAL,'#10' EMPRESAS.CALLE' +
|
||||||
|
' as CALLE_EMPRESA, EMPRESAS.POBLACION as POBLACION_EMPRESA,'#10' ' +
|
||||||
|
' EMPRESAS.PROVINCIA as PROVINCIA_EMPRESA, EMPRESAS.CODIGO_POST' +
|
||||||
|
'AL as CODIGO_POSTAL_EMPRESA,'#10' EMPRESAS.TELEFONO_1, EMPRESA' +
|
||||||
|
'S.FAX, EMPRESAS.MOVIL_1, EMPRESAS.EMAIL_1,'#10' EMPRESAS.PAGIN' +
|
||||||
|
'A_WEB, EMPRESAS.REGISTRO_MERCANTIL,'#10#10' V_AGENTES_COMISIONES' +
|
||||||
|
'_DET_FAC.ID_AGENTE, CONTACTOS1.NOMBRE as AGENTE,'#10' V_AGENTE' +
|
||||||
|
'S_COMISIONES_DET_FAC.ID_FACTURA,'#10' V_AGENTES_COMISIONES_DET' +
|
||||||
|
'_FAC.ID_COMISION_LIQUIDADA,'#10' V_AGENTES_COMISIONES_DET_FAC.' +
|
||||||
|
'FECHA,'#10' V_AGENTES_COMISIONES_DET_FAC.REFERENCIA,'#10' V_' +
|
||||||
|
'AGENTES_COMISIONES_DET_FAC.SITUACION,'#10' V_AGENTES_COMISIONE' +
|
||||||
|
'S_DET_FAC.ID_CLIENTE,'#10' CONTACTOS2.NOMBRE as CLIENTE,'#10#10' ' +
|
||||||
|
' SUM(V_AGENTES_COMISIONES_DET_FAC.IMPORTE_TOTAL) as IMPORTE_CO' +
|
||||||
|
'MISIONABLE,'#10' SUM(V_AGENTES_COMISIONES_DET_FAC.IMPORTE_COMI' +
|
||||||
|
'SION) as IMPORTE_COMISION'#10#10#10'from V_AGENTES_COMISIONES_DET_FAC'#10'LE' +
|
||||||
|
'FT JOIN COMISIONES_LIQUIDADAS ON (COMISIONES_LIQUIDADAS.ID = V_A' +
|
||||||
|
'GENTES_COMISIONES_DET_FAC.ID_COMISION_LIQUIDADA)'#10'LEFT JOIN EMPRE' +
|
||||||
|
'SAS ON EMPRESAS.ID = V_AGENTES_COMISIONES_DET_FAC.ID_EMPRESA'#10'LEF' +
|
||||||
|
'T JOIN CONTACTOS CONTACTOS1 ON (CONTACTOS1.ID = V_AGENTES_COMISI' +
|
||||||
|
'ONES_DET_FAC.ID_AGENTE)'#10'LEFT JOIN CONTACTOS CONTACTOS2 ON (CONTA' +
|
||||||
|
'CTOS2.ID = V_AGENTES_COMISIONES_DET_FAC.ID_CLIENTE)'#10'LEFT JOIN CO' +
|
||||||
|
'NTACTOS CONTACTOS3 ON (CONTACTOS3.ID = V_AGENTES_COMISIONES_DET_' +
|
||||||
|
'FAC.ID_PROVEEDOR)'#10'WHERE V_AGENTES_COMISIONES_DET_FAC.ID_COMISION' +
|
||||||
|
'_LIQUIDADA IS NOT NULL'#10'and {where}'#10'GROUP BY 1, 2, 3, 4, 5, 6, 7,' +
|
||||||
|
' 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 2' +
|
||||||
|
'4, 25, 26'#10'ORDER BY 1'#10
|
||||||
|
StatementType = stSQL
|
||||||
|
ColumnMappings = <
|
||||||
|
item
|
||||||
|
DatasetField = 'REFERENCIA'
|
||||||
|
TableField = 'REFERENCIA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_EMPRESA'
|
||||||
|
TableField = 'ID_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_CLIENTE'
|
||||||
|
TableField = 'ID_CLIENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'REFERENCIA_COMISION'
|
||||||
|
TableField = 'REFERENCIA_COMISION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'DESCRIPCION'
|
||||||
|
TableField = 'DESCRIPCION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_AGENTE'
|
||||||
|
TableField = 'ID_AGENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'AGENTE'
|
||||||
|
TableField = 'AGENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_FACTURA'
|
||||||
|
TableField = 'ID_FACTURA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_COMISION_LIQUIDADA'
|
||||||
|
TableField = 'ID_COMISION_LIQUIDADA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'FECHA'
|
||||||
|
TableField = 'FECHA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'SITUACION'
|
||||||
|
TableField = 'SITUACION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'CLIENTE'
|
||||||
|
TableField = 'CLIENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'IMPORTE_COMISIONABLE'
|
||||||
|
TableField = 'IMPORTE_COMISIONABLE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'IMPORTE_COMISION'
|
||||||
|
TableField = 'IMPORTE_COMISION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'FECHA_COMISION'
|
||||||
|
TableField = 'FECHA_COMISION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'IMPORTE_TOTAL'
|
||||||
|
TableField = 'IMPORTE_TOTAL'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'NIF_CIF_EMPRESA'
|
||||||
|
TableField = 'NIF_CIF_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'RAZON_SOCIAL'
|
||||||
|
TableField = 'RAZON_SOCIAL'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'CALLE_EMPRESA'
|
||||||
|
TableField = 'CALLE_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'POBLACION_EMPRESA'
|
||||||
|
TableField = 'POBLACION_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'PROVINCIA_EMPRESA'
|
||||||
|
TableField = 'PROVINCIA_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'CODIGO_POSTAL_EMPRESA'
|
||||||
|
TableField = 'CODIGO_POSTAL_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'TELEFONO_1'
|
||||||
|
TableField = 'TELEFONO_1'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'FAX'
|
||||||
|
TableField = 'FAX'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'MOVIL_1'
|
||||||
|
TableField = 'MOVIL_1'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'EMAIL_1'
|
||||||
|
TableField = 'EMAIL_1'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'PAGINA_WEB'
|
||||||
|
TableField = 'PAGINA_WEB'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'REGISTRO_MERCANTIL'
|
||||||
|
TableField = 'REGISTRO_MERCANTIL'
|
||||||
|
end>
|
||||||
|
end>
|
||||||
|
Name = 'InformeComisiones'
|
||||||
|
Fields = <
|
||||||
|
item
|
||||||
|
Name = 'FECHA_COMISION'
|
||||||
|
DataType = datDateTime
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'REFERENCIA_COMISION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'DESCRIPCION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'IMPORTE_TOTAL'
|
||||||
|
DataType = datCurrency
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_EMPRESA'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'NIF_CIF_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 15
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'RAZON_SOCIAL'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'CALLE_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'POBLACION_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'PROVINCIA_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'CODIGO_POSTAL_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 10
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'TELEFONO_1'
|
||||||
|
DataType = datString
|
||||||
|
Size = 25
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FAX'
|
||||||
|
DataType = datString
|
||||||
|
Size = 25
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'MOVIL_1'
|
||||||
|
DataType = datString
|
||||||
|
Size = 25
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'EMAIL_1'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'PAGINA_WEB'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'REGISTRO_MERCANTIL'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_AGENTE'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'AGENTE'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_FACTURA'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_COMISION_LIQUIDADA'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FECHA'
|
||||||
|
DataType = datDateTime
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'REFERENCIA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'SITUACION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 19
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_CLIENTE'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'CLIENTE'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'IMPORTE_COMISIONABLE'
|
||||||
|
DataType = datCurrency
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'IMPORTE_COMISION'
|
||||||
|
DataType = datFloat
|
||||||
|
end>
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Params = <>
|
||||||
|
Statements = <
|
||||||
|
item
|
||||||
|
Connection = 'IBX'
|
||||||
|
TargetTable = 'V_AGENTES_COMISIONES_DET_FAC'
|
||||||
|
SQL =
|
||||||
|
'select'#10' COMISIONES_LIQUIDADAS.FECHA AS FECHA_COMISION,'#10' ' +
|
||||||
|
' COMISIONES_LIQUIDADAS.REFERENCIA AS REFERENCIA_COMISION,'#10' ' +
|
||||||
|
' COMISIONES_LIQUIDADAS.DESCRIPCION,'#10' COMISIONES_LIQUIDA' +
|
||||||
|
'DAS.IMPORTE_TOTAL,'#10#10' V_AGENTES_COMISIONES_DET_FAC.ID_EMPRE' +
|
||||||
|
'SA, EMPRESAS.NIF_CIF as NIF_CIF_EMPRESA, COALESCE(EMPRESAS.RAZON' +
|
||||||
|
'_SOCIAL, EMPRESAS.NOMBRE) as RAZON_SOCIAL,'#10' EMPRESAS.CALLE' +
|
||||||
|
' as CALLE_EMPRESA, EMPRESAS.POBLACION as POBLACION_EMPRESA,'#10' ' +
|
||||||
|
' EMPRESAS.PROVINCIA as PROVINCIA_EMPRESA, EMPRESAS.CODIGO_POST' +
|
||||||
|
'AL as CODIGO_POSTAL_EMPRESA,'#10' EMPRESAS.TELEFONO_1, EMPRESA' +
|
||||||
|
'S.FAX, EMPRESAS.MOVIL_1, EMPRESAS.EMAIL_1,'#10' EMPRESAS.PAGIN' +
|
||||||
|
'A_WEB, EMPRESAS.REGISTRO_MERCANTIL,'#10#10' V_AGENTES_COMISIONES' +
|
||||||
|
'_DET_FAC.ID_AGENTE, CONTACTOS1.NOMBRE as AGENTE,'#10' V_AGENTE' +
|
||||||
|
'S_COMISIONES_DET_FAC.ID_FACTURA,'#10' V_AGENTES_COMISIONES_DET' +
|
||||||
|
'_FAC.ID_COMISION_LIQUIDADA,'#10' V_AGENTES_COMISIONES_DET_FAC.' +
|
||||||
|
'FECHA,'#10' V_AGENTES_COMISIONES_DET_FAC.REFERENCIA,'#10' V_' +
|
||||||
|
'AGENTES_COMISIONES_DET_FAC.SITUACION,'#10' V_AGENTES_COMISIONE' +
|
||||||
|
'S_DET_FAC.ID_CLIENTE,'#10' CONTACTOS2.NOMBRE as CLIENTE,'#10' ' +
|
||||||
|
' V_AGENTES_COMISIONES_DET_FAC.ID_PROVEEDOR,'#10' CONTACTOS3.N' +
|
||||||
|
'OMBRE as PROVEEDOR,'#10' V_AGENTES_COMISIONES_DET_FAC.COMISION' +
|
||||||
|
','#10#10' SUM(V_AGENTES_COMISIONES_DET_FAC.IMPORTE_TOTAL) as IMP' +
|
||||||
|
'ORTE_COMISIONABLE,'#10' SUM(V_AGENTES_COMISIONES_DET_FAC.IMPOR' +
|
||||||
|
'TE_COMISION) as IMPORTE_COMISION'#10#10#10'from V_AGENTES_COMISIONES_DET' +
|
||||||
|
'_FAC'#10'LEFT JOIN COMISIONES_LIQUIDADAS ON (COMISIONES_LIQUIDADAS.I' +
|
||||||
|
'D = V_AGENTES_COMISIONES_DET_FAC.ID_COMISION_LIQUIDADA)'#10'LEFT JOI' +
|
||||||
|
'N EMPRESAS ON EMPRESAS.ID = V_AGENTES_COMISIONES_DET_FAC.ID_EMPR' +
|
||||||
|
'ESA'#10'LEFT JOIN CONTACTOS CONTACTOS1 ON (CONTACTOS1.ID = V_AGENTES' +
|
||||||
|
'_COMISIONES_DET_FAC.ID_AGENTE)'#10'LEFT JOIN CONTACTOS CONTACTOS2 ON' +
|
||||||
|
' (CONTACTOS2.ID = V_AGENTES_COMISIONES_DET_FAC.ID_CLIENTE)'#10'LEFT ' +
|
||||||
|
'JOIN CONTACTOS CONTACTOS3 ON (CONTACTOS3.ID = V_AGENTES_COMISION' +
|
||||||
|
'ES_DET_FAC.ID_PROVEEDOR)'#10'WHERE V_AGENTES_COMISIONES_DET_FAC.ID_C' +
|
||||||
|
'OMISION_LIQUIDADA IS NOT NULL'#10'and {where}'#10'GROUP BY 1, 2, 3, 4, 5' +
|
||||||
|
', 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22' +
|
||||||
|
', 23, 24, 25, 26, 27, 28, 29'#10'ORDER BY 1'#10
|
||||||
|
StatementType = stSQL
|
||||||
|
ColumnMappings = <
|
||||||
|
item
|
||||||
|
DatasetField = 'REFERENCIA'
|
||||||
|
TableField = 'REFERENCIA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_EMPRESA'
|
||||||
|
TableField = 'ID_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_CLIENTE'
|
||||||
|
TableField = 'ID_CLIENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'REFERENCIA_COMISION'
|
||||||
|
TableField = 'REFERENCIA_COMISION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'DESCRIPCION'
|
||||||
|
TableField = 'DESCRIPCION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_AGENTE'
|
||||||
|
TableField = 'ID_AGENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'AGENTE'
|
||||||
|
TableField = 'AGENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_FACTURA'
|
||||||
|
TableField = 'ID_FACTURA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_COMISION_LIQUIDADA'
|
||||||
|
TableField = 'ID_COMISION_LIQUIDADA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'FECHA'
|
||||||
|
TableField = 'FECHA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'SITUACION'
|
||||||
|
TableField = 'SITUACION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'CLIENTE'
|
||||||
|
TableField = 'CLIENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'ID_PROVEEDOR'
|
||||||
|
TableField = 'ID_PROVEEDOR'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'PROVEEDOR'
|
||||||
|
TableField = 'PROVEEDOR'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'COMISION'
|
||||||
|
TableField = 'COMISION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'IMPORTE_COMISIONABLE'
|
||||||
|
TableField = 'IMPORTE_COMISIONABLE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'IMPORTE_COMISION'
|
||||||
|
TableField = 'IMPORTE_COMISION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'FECHA_COMISION'
|
||||||
|
TableField = 'FECHA_COMISION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'IMPORTE_TOTAL'
|
||||||
|
TableField = 'IMPORTE_TOTAL'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'NIF_CIF_EMPRESA'
|
||||||
|
TableField = 'NIF_CIF_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'RAZON_SOCIAL'
|
||||||
|
TableField = 'RAZON_SOCIAL'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'CALLE_EMPRESA'
|
||||||
|
TableField = 'CALLE_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'POBLACION_EMPRESA'
|
||||||
|
TableField = 'POBLACION_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'PROVINCIA_EMPRESA'
|
||||||
|
TableField = 'PROVINCIA_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'CODIGO_POSTAL_EMPRESA'
|
||||||
|
TableField = 'CODIGO_POSTAL_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'TELEFONO_1'
|
||||||
|
TableField = 'TELEFONO_1'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'FAX'
|
||||||
|
TableField = 'FAX'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'MOVIL_1'
|
||||||
|
TableField = 'MOVIL_1'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'EMAIL_1'
|
||||||
|
TableField = 'EMAIL_1'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'PAGINA_WEB'
|
||||||
|
TableField = 'PAGINA_WEB'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
DatasetField = 'REGISTRO_MERCANTIL'
|
||||||
|
TableField = 'REGISTRO_MERCANTIL'
|
||||||
|
end>
|
||||||
|
end>
|
||||||
|
Name = 'InformeComisionesDesglosado'
|
||||||
|
Fields = <
|
||||||
|
item
|
||||||
|
Name = 'FECHA_COMISION'
|
||||||
|
DataType = datDateTime
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'REFERENCIA_COMISION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'DESCRIPCION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'IMPORTE_TOTAL'
|
||||||
|
DataType = datCurrency
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_EMPRESA'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'NIF_CIF_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 15
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'RAZON_SOCIAL'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'CALLE_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'POBLACION_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'PROVINCIA_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'CODIGO_POSTAL_EMPRESA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 10
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'TELEFONO_1'
|
||||||
|
DataType = datString
|
||||||
|
Size = 25
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FAX'
|
||||||
|
DataType = datString
|
||||||
|
Size = 25
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'MOVIL_1'
|
||||||
|
DataType = datString
|
||||||
|
Size = 25
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'EMAIL_1'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'PAGINA_WEB'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'REGISTRO_MERCANTIL'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_AGENTE'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'AGENTE'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_FACTURA'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_COMISION_LIQUIDADA'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FECHA'
|
||||||
|
DataType = datDateTime
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'REFERENCIA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'SITUACION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 19
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_CLIENTE'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'CLIENTE'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'ID_PROVEEDOR'
|
||||||
|
DataType = datInteger
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'PROVEEDOR'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'COMISION'
|
||||||
|
DataType = datFloat
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'IMPORTE_COMISIONABLE'
|
||||||
|
DataType = datCurrency
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'IMPORTE_COMISION'
|
||||||
|
DataType = datFloat
|
||||||
|
end>
|
||||||
|
end>
|
||||||
|
JoinDataTables = <>
|
||||||
|
UnionDataTables = <>
|
||||||
|
Commands = <>
|
||||||
|
RelationShips = <>
|
||||||
|
UpdateRules = <>
|
||||||
|
Version = 0
|
||||||
|
Left = 48
|
||||||
|
Top = 16
|
||||||
|
end
|
||||||
|
object DataDictionary: TDADataDictionary
|
||||||
|
Fields = <
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_ID'
|
||||||
|
DataType = datAutoInc
|
||||||
|
Required = True
|
||||||
|
DisplayLabel = 'ID'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_ID_EMPRESA'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = 'ID_EMPRESA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_ID_CONTRATO'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = 'ID_CONTRATO'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_FECHA_FACTURA'
|
||||||
|
DataType = datDateTime
|
||||||
|
DisplayLabel = 'Fecha de las factura'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_VENCIMIENTO'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = 'Vencimiento'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_SITUACION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 255
|
||||||
|
DisplayLabel = 'Situaci'#243'n'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_BASE_IMPONIBLE'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'Base imponible'
|
||||||
|
Alignment = taRightJustify
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_IMPORTE_DESCUENTO'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'Importe dto.'
|
||||||
|
Alignment = taRightJustify
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_IMPORTE_IVA'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'Importe IVA'
|
||||||
|
Alignment = taRightJustify
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_IMPORTE_TOTAL'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'Importe total'
|
||||||
|
Alignment = taRightJustify
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_FORMA_PAGO'
|
||||||
|
DataType = datMemo
|
||||||
|
DisplayLabel = 'Forma de pago'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_ID_CLIENTE'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = 'ID_CLIENTE'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_NIF_CIF'
|
||||||
|
DataType = datString
|
||||||
|
Size = 15
|
||||||
|
DisplayLabel = 'NIF/CIF'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_CODIGO_POSTAL'
|
||||||
|
DataType = datString
|
||||||
|
Size = 10
|
||||||
|
DisplayLabel = 'C'#243'd. postal'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_FECHA_ALTA'
|
||||||
|
DataType = datDateTime
|
||||||
|
DisplayLabel = 'FECHA_ALTA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_FECHA_MODIFICACION'
|
||||||
|
DataType = datDateTime
|
||||||
|
DisplayLabel = 'FECHA_MODIFICACION'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_OBSERVACIONES'
|
||||||
|
DataType = datMemo
|
||||||
|
DisplayLabel = 'Observaciones'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_NOMBRE'
|
||||||
|
DataType = datString
|
||||||
|
Size = 100
|
||||||
|
DisplayLabel = 'Cliente'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_CALLE'
|
||||||
|
DataType = datString
|
||||||
|
Size = 150
|
||||||
|
DisplayLabel = 'Direcci'#243'n'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_PROVINCIA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 30
|
||||||
|
DisplayLabel = 'Provincia'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_POBLACION'
|
||||||
|
DataType = datString
|
||||||
|
Size = 150
|
||||||
|
DisplayLabel = 'Poblaci'#243'n'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_IVA'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'IVA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_USUARIO'
|
||||||
|
DataType = datString
|
||||||
|
Size = 100
|
||||||
|
DisplayLabel = 'USUARIO'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_REFERENCIA'
|
||||||
|
DataType = datString
|
||||||
|
Size = 20
|
||||||
|
DisplayLabel = 'Referencia'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_DESCUENTO'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'Dto.'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_ID'
|
||||||
|
DataType = datAutoInc
|
||||||
|
Required = True
|
||||||
|
DisplayLabel = 'ID'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_ID_FACTURA'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = 'ID_FACTURA'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_TIPO_DETALLE'
|
||||||
|
DataType = datString
|
||||||
|
Size = 10
|
||||||
|
DisplayLabel = 'Tipo detalle'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_CONCEPTO'
|
||||||
|
DataType = datString
|
||||||
|
Size = 2000
|
||||||
|
DisplayLabel = 'Concepto'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_IMPORTE_UNIDAD'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'Importe unidad'
|
||||||
|
Alignment = taRightJustify
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_IMPORTE_TOTAL'
|
||||||
|
DataType = datFloat
|
||||||
|
DisplayLabel = 'Importe total'
|
||||||
|
Alignment = taRightJustify
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_VISIBLE'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = #191'Visible?'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_POSICION'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = 'Posici'#243'n'
|
||||||
|
end
|
||||||
|
item
|
||||||
|
Name = 'FacturasCliente_Detalles_CANTIDAD'
|
||||||
|
DataType = datInteger
|
||||||
|
DisplayLabel = 'Cantidad'
|
||||||
|
end>
|
||||||
|
Left = 46
|
||||||
|
Top = 158
|
||||||
|
end
|
||||||
|
object frxReport: TfrxReport
|
||||||
|
Version = '4.7.71'
|
||||||
|
DotMatrixReport = False
|
||||||
|
EngineOptions.DoublePass = True
|
||||||
|
IniFile = '\Software\Fast Reports'
|
||||||
|
PreviewOptions.Buttons = [pbPrint, pbLoad, pbSave, pbExport, pbZoom, pbFind, pbOutline, pbPageSetup, pbTools, pbEdit, pbNavigator, pbExportQuick]
|
||||||
|
PreviewOptions.OutlineWidth = 180
|
||||||
|
PreviewOptions.Zoom = 1.000000000000000000
|
||||||
|
PrintOptions.Printer = 'Default'
|
||||||
|
PrintOptions.PrintOnSheet = 0
|
||||||
|
ReportOptions.CreateDate = 37871.995398692100000000
|
||||||
|
ReportOptions.LastChange = 39266.688905347220000000
|
||||||
|
ReportOptions.VersionBuild = '1'
|
||||||
|
ReportOptions.VersionMajor = '12'
|
||||||
|
ReportOptions.VersionMinor = '13'
|
||||||
|
ReportOptions.VersionRelease = '1'
|
||||||
|
ScriptLanguage = 'PascalScript'
|
||||||
|
ScriptText.Strings = (
|
||||||
|
'procedure DatosEmpresaOnBeforePrint(Sender: TfrxComponent);'
|
||||||
|
'var'
|
||||||
|
' Cadena: String;'
|
||||||
|
'begin'
|
||||||
|
' DatosEmpresa.Lines.Clear;'
|
||||||
|
' DatosEmpresa.Lines.Add(<frxDBCabecera."RAZON_SOCIAL">);'
|
||||||
|
' DatosEmpresa.Lines.Add(<frxDBCabecera."CALLE_EMPRESA">);'
|
||||||
|
''
|
||||||
|
' Cadena := '#39#39';'
|
||||||
|
' if (<frxDBCabecera."TELEFONO_1"> <> '#39#39') then'
|
||||||
|
' Cadena := '#39'TLF: '#39' + <frxDBCabecera."TELEFONO_1">;'
|
||||||
|
' if (<frxDBCabecera."FAX"> <> '#39#39') then'
|
||||||
|
' Cadena := Cadena + '#39' FAX: '#39' + <frxDBCabecera."FAX">;'
|
||||||
|
' DatosEmpresa.Lines.Add(Cadena);'
|
||||||
|
''
|
||||||
|
' Cadena := '#39#39';'
|
||||||
|
' if (<frxDBCabecera."CODIGO_POSTAL_EMPRESA"> <> '#39#39') then'
|
||||||
|
' Cadena := <frxDBCabecera."CODIGO_POSTAL_EMPRESA">;'
|
||||||
|
' if (<frxDBCabecera."POBLACION_EMPRESA"> <> '#39#39') then'
|
||||||
|
|
||||||
|
' Cadena := Cadena + '#39' '#39' + <frxDBCabecera."POBLACION_EMPRES' +
|
||||||
|
'A">;'
|
||||||
|
' if (<frxDBCabecera."PROVINCIA_EMPRESA"> <> '#39#39') then'
|
||||||
|
|
||||||
|
' Cadena := Cadena + '#39' - '#39' + <frxDBCabecera."PROVINCIA_EMPR' +
|
||||||
|
'ESA">;'
|
||||||
|
' DatosEmpresa.Lines.Add(Cadena);'
|
||||||
|
'end;'
|
||||||
|
''
|
||||||
|
'procedure Memo26OnBeforePrint(Sender: TfrxComponent);'
|
||||||
|
'begin'
|
||||||
|
' if (<FechaIni> <> '#39#39') then'
|
||||||
|
' Memo31.Visible := True'
|
||||||
|
' else'
|
||||||
|
' Memo31.Visible := False;'
|
||||||
|
'end;'
|
||||||
|
''
|
||||||
|
'BEGIN'
|
||||||
|
''
|
||||||
|
'END.')
|
||||||
|
ShowProgress = False
|
||||||
|
StoreInDFM = False
|
||||||
|
Left = 169
|
||||||
|
Top = 16
|
||||||
|
end
|
||||||
|
object frxDBCabecera: TfrxDBDataset
|
||||||
|
UserName = 'frxDBCabecera'
|
||||||
|
CloseDataSource = False
|
||||||
|
DataSource = DADataCabecera
|
||||||
|
BCDToCurrency = False
|
||||||
|
Left = 264
|
||||||
|
Top = 16
|
||||||
|
end
|
||||||
|
object Bin2DataStreamer: TDABin2DataStreamer
|
||||||
|
Left = 48
|
||||||
|
Top = 88
|
||||||
|
end
|
||||||
|
end
|
||||||
146
Source/Modulos/Comisiones/Reports/uRptComisiones_Server.pas
Normal file
146
Source/Modulos/Comisiones/Reports/uRptComisiones_Server.pas
Normal file
@ -0,0 +1,146 @@
|
|||||||
|
unit uRptComisiones_Server;
|
||||||
|
|
||||||
|
interface
|
||||||
|
|
||||||
|
uses
|
||||||
|
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
|
||||||
|
Dialogs, frxClass, frxDBSet, uDAScriptingProvider,
|
||||||
|
uDADataTable, uDACDSDataTable, DB, uDAClasses, frxChart, frxGradient,
|
||||||
|
frxChBox, frxCross, frxOLE, frxBarcode, frxRich, uDABINAdapter, uROTypes,
|
||||||
|
uDAInterfaces, uDADataStreamer, uDABin2DataStreamer;
|
||||||
|
|
||||||
|
type
|
||||||
|
TRptComisiones = class(TDataModule)
|
||||||
|
DADataCabecera: TDADataSource;
|
||||||
|
tbl_Comisiones: TDACDSDataTable;
|
||||||
|
frxRichObject1: TfrxRichObject;
|
||||||
|
frxBarCodeObject1: TfrxBarCodeObject;
|
||||||
|
frxOLEObject1: TfrxOLEObject;
|
||||||
|
frxCrossObject1: TfrxCrossObject;
|
||||||
|
frxCheckBoxObject1: TfrxCheckBoxObject;
|
||||||
|
frxGradientObject1: TfrxGradientObject;
|
||||||
|
frxChartObject1: TfrxChartObject;
|
||||||
|
frxDBCabecera: TfrxDBDataset;
|
||||||
|
frxReport: TfrxReport;
|
||||||
|
Bin2DataStreamer: TDABin2DataStreamer;
|
||||||
|
schReport: TDASchema;
|
||||||
|
DataDictionary: TDADataDictionary;
|
||||||
|
procedure DataModuleCreate(Sender: TObject);
|
||||||
|
private
|
||||||
|
FConnection: IDAConnection;
|
||||||
|
public
|
||||||
|
function GenerarComision(const AComisionID : Variant; const DesglosadoProv: Boolean; FechaIni: String; FechaFin: String; AAgenteID: Variant): Binary;
|
||||||
|
end;
|
||||||
|
|
||||||
|
implementation
|
||||||
|
|
||||||
|
{$R *.dfm}
|
||||||
|
|
||||||
|
uses
|
||||||
|
uSistemaFunc, uDataModuleServer, schComisionesClient_Intf;
|
||||||
|
|
||||||
|
const
|
||||||
|
rptComision = 'InfComisiones.fr3';
|
||||||
|
rptComisionDesglosado = 'InfComisionesDesglosado.fr3';
|
||||||
|
|
||||||
|
{ Dataset names for schReport }
|
||||||
|
ds_InformeComisiones = 'InformeComisiones';
|
||||||
|
ds_InformeComisionesDesglosado = 'InformeComisionesDesglosado';
|
||||||
|
|
||||||
|
|
||||||
|
{ TRptComision }
|
||||||
|
|
||||||
|
procedure TRptComisiones.DataModuleCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
schReport.ConnectionManager := dmServer.ConnectionManager;
|
||||||
|
FConnection := dmServer.DarNuevaConexion;
|
||||||
|
frxReport.EngineOptions.NewSilentMode := simReThrow;
|
||||||
|
end;
|
||||||
|
|
||||||
|
function TRptComisiones.GenerarComision(const AComisionID : Variant; const DesglosadoProv: Boolean; FechaIni: String; FechaFin: String; AAgenteID: Variant): Binary;
|
||||||
|
var
|
||||||
|
dsMaster: IDADataset;
|
||||||
|
AStream: TMemoryStream;
|
||||||
|
AInforme: Variant;
|
||||||
|
Condicion: TDAWhereExpression;
|
||||||
|
|
||||||
|
begin
|
||||||
|
AStream := TMemoryStream.Create;
|
||||||
|
Result := Binary.Create;
|
||||||
|
FConnection.BeginTransaction;
|
||||||
|
try
|
||||||
|
if DesglosadoProv then
|
||||||
|
dsMaster := schReport.NewDataset(FConnection, ds_InformeComisionesDesglosado,[], [], False)
|
||||||
|
else
|
||||||
|
dsMaster := schReport.NewDataset(FConnection, ds_InformeComisiones,[], [], False);
|
||||||
|
|
||||||
|
// Filtrar las facturas actuales por empresa
|
||||||
|
with dsMaster.DynamicWhere do
|
||||||
|
begin
|
||||||
|
if not VarIsNull(AComisionID) then
|
||||||
|
begin
|
||||||
|
Condicion := NewBinaryExpression(NewField('', fld_Facturas_ComisionID_COMISION_LIQUIDADA), NewConstant(VarToStr(AComisionID), datString), dboEqual);
|
||||||
|
if IsEmpty then
|
||||||
|
Expression := Condicion
|
||||||
|
else
|
||||||
|
Expression := NewBinaryExpression(Expression, Condicion, dboAnd);
|
||||||
|
end;
|
||||||
|
|
||||||
|
if not VarIsNull(AAgenteID) then
|
||||||
|
begin
|
||||||
|
Condicion := NewBinaryExpression(NewField('', fld_Facturas_ComisionID_AGENTE), NewConstant(VarToStr(AAgenteID), datString), dboEqual);
|
||||||
|
if IsEmpty then
|
||||||
|
Expression := Condicion
|
||||||
|
else
|
||||||
|
Expression := NewBinaryExpression(Expression, Condicion, dboAnd);
|
||||||
|
end;
|
||||||
|
|
||||||
|
if (Length(FechaIni) > 0)
|
||||||
|
and (Length(FechaFin) > 0) then
|
||||||
|
begin
|
||||||
|
// (FECHA_INICIO between FECHA_FIN)
|
||||||
|
Condicion := NewBinaryExpression(NewField('', fld_Facturas_ComisionFecha), NewConstant(FechaIni, datString), dboGreaterOrEqual);
|
||||||
|
Condicion := NewBinaryExpression(NewBinaryExpression(NewField('', fld_Facturas_ComisionFecha), NewConstant(FechaFin, datString), dboLessOrEqual), Condicion, dboAnd);
|
||||||
|
|
||||||
|
if IsEmpty then
|
||||||
|
Expression := Condicion
|
||||||
|
else
|
||||||
|
Expression := NewBinaryExpression(Expression, Condicion, dboAnd);
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
dsMaster.Open;
|
||||||
|
|
||||||
|
AStream.Clear;
|
||||||
|
Bin2DataStreamer.WriteDataset(AStream, dsMaster, [woRows, woSchema], -1);
|
||||||
|
Bin2DataStreamer.ReadDataset(AStream, tbl_Comisiones, TRUE, '', TRUE, TRUE);
|
||||||
|
|
||||||
|
if DesglosadoProv then
|
||||||
|
begin
|
||||||
|
AInforme := DarRutaFichero(DarRutaInformes, rptComisionDesglosado, tbl_Comisiones.FieldByName('ID_EMPRESA').AsString);
|
||||||
|
if VarIsNull(AInforme) then
|
||||||
|
raise Exception.Create (('Error Servidor: _GenerarComision, no encuentra informe ' + rptComisionDesglosado));
|
||||||
|
|
||||||
|
frxReport.LoadFromFile(AInforme, True);
|
||||||
|
end
|
||||||
|
else
|
||||||
|
begin
|
||||||
|
AInforme := DarRutaFichero(DarRutaInformes, rptComision, tbl_Comisiones.FieldByName('ID_EMPRESA').AsString);
|
||||||
|
if VarIsNull(AInforme) then
|
||||||
|
raise Exception.Create (('Error Servidor: _GenerarComision, no encuentra informe ' + rptComision));
|
||||||
|
|
||||||
|
frxReport.LoadFromFile(AInforme, True);
|
||||||
|
end;
|
||||||
|
|
||||||
|
frxReport.Variables['FechaIni'] := QuotedStr(FechaIni);
|
||||||
|
frxReport.Variables['FechaFin'] := QuotedStr(FechaFin);
|
||||||
|
frxReport.PrepareReport;
|
||||||
|
frxReport.PreviewPages.SaveToStream(Result);
|
||||||
|
finally
|
||||||
|
AStream.Free;
|
||||||
|
dsMaster := Nil;
|
||||||
|
FConnection.RollbackTransaction;
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
|
end.
|
||||||
@ -77,12 +77,7 @@ object srvComisiones: TsrvComisiones
|
|||||||
Diagrams = Diagrams
|
Diagrams = Diagrams
|
||||||
Datasets = <
|
Datasets = <
|
||||||
item
|
item
|
||||||
Params = <
|
Params = <>
|
||||||
item
|
|
||||||
Name = 'ID_COMISION'
|
|
||||||
Value = ''
|
|
||||||
ParamType = daptInput
|
|
||||||
end>
|
|
||||||
Statements = <
|
Statements = <
|
||||||
item
|
item
|
||||||
Connection = 'IBX'
|
Connection = 'IBX'
|
||||||
@ -104,9 +99,8 @@ object srvComisiones: TsrvComisiones
|
|||||||
'V_AGENTES_COMISIONES_DET_FAC.ID_AGENTE)'#10'LEFT JOIN CONTACTOS CONT' +
|
'V_AGENTES_COMISIONES_DET_FAC.ID_AGENTE)'#10'LEFT JOIN CONTACTOS CONT' +
|
||||||
'ACTOS2 ON (CONTACTOS2.ID = V_AGENTES_COMISIONES_DET_FAC.ID_CLIEN' +
|
'ACTOS2 ON (CONTACTOS2.ID = V_AGENTES_COMISIONES_DET_FAC.ID_CLIEN' +
|
||||||
'TE)'#10'LEFT JOIN CONTACTOS CONTACTOS3 ON (CONTACTOS3.ID = V_AGENTES' +
|
'TE)'#10'LEFT JOIN CONTACTOS CONTACTOS3 ON (CONTACTOS3.ID = V_AGENTES' +
|
||||||
'_COMISIONES_DET_FAC.ID_PROVEEDOR)'#10'WHERE V_AGENTES_COMISIONES_DET' +
|
'_COMISIONES_DET_FAC.ID_PROVEEDOR)'#10' WHERE {Where}'#10'GROUP BY 1, 2,' +
|
||||||
'_FAC.ID_COMISION_LIQUIDADA = :ID_COMISION'#10'GROUP BY 1, 2, 3, 4, 5' +
|
' 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13'#10
|
||||||
', 6, 7, 8, 9, 10, 11, 12, 13'
|
|
||||||
StatementType = stSQL
|
StatementType = stSQL
|
||||||
ColumnMappings = <
|
ColumnMappings = <
|
||||||
item
|
item
|
||||||
@ -249,7 +243,7 @@ object srvComisiones: TsrvComisiones
|
|||||||
end
|
end
|
||||||
item
|
item
|
||||||
Name = 'IMPORTE_COMISION'
|
Name = 'IMPORTE_COMISION'
|
||||||
DataType = datCurrency
|
DataType = datFloat
|
||||||
DictionaryEntry = 'Facturas_Comision_IMPORTE_COMISION'
|
DictionaryEntry = 'Facturas_Comision_IMPORTE_COMISION'
|
||||||
end>
|
end>
|
||||||
end
|
end
|
||||||
@ -350,6 +344,7 @@ object srvComisiones: TsrvComisiones
|
|||||||
Name = 'NOMBRE'
|
Name = 'NOMBRE'
|
||||||
DataType = datString
|
DataType = datString
|
||||||
Size = 255
|
Size = 255
|
||||||
|
ServerAutoRefresh = True
|
||||||
DictionaryEntry = 'Comisiones_NOMBRE'
|
DictionaryEntry = 'Comisiones_NOMBRE'
|
||||||
end>
|
end>
|
||||||
end
|
end
|
||||||
@ -376,8 +371,8 @@ object srvComisiones: TsrvComisiones
|
|||||||
' V_AGENTES_COMISIONES_DET_FAC.ID_AGENTE)'#10'LEFT JOIN CONTACTOS CON' +
|
' V_AGENTES_COMISIONES_DET_FAC.ID_AGENTE)'#10'LEFT JOIN CONTACTOS CON' +
|
||||||
'TACTOS2 ON (CONTACTOS2.ID = V_AGENTES_COMISIONES_DET_FAC.ID_CLIE' +
|
'TACTOS2 ON (CONTACTOS2.ID = V_AGENTES_COMISIONES_DET_FAC.ID_CLIE' +
|
||||||
'NTE)'#10'LEFT JOIN CONTACTOS CONTACTOS3 ON (CONTACTOS3.ID = V_AGENTE' +
|
'NTE)'#10'LEFT JOIN CONTACTOS CONTACTOS3 ON (CONTACTOS3.ID = V_AGENTE' +
|
||||||
'S_COMISIONES_DET_FAC.ID_PROVEEDOR)'#10'GROUP BY 1, 2, 3, 4, 5, 6, 7,' +
|
'S_COMISIONES_DET_FAC.ID_PROVEEDOR)'#10'where {where}'#10'GROUP BY 1, 2, ' +
|
||||||
' 8, 9, 10, 11, 12, 13'
|
'3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13'#10
|
||||||
StatementType = stSQL
|
StatementType = stSQL
|
||||||
ColumnMappings = <
|
ColumnMappings = <
|
||||||
item
|
item
|
||||||
@ -519,7 +514,7 @@ object srvComisiones: TsrvComisiones
|
|||||||
end
|
end
|
||||||
item
|
item
|
||||||
Name = 'IMPORTE_COMISION'
|
Name = 'IMPORTE_COMISION'
|
||||||
DataType = datCurrency
|
DataType = datFloat
|
||||||
DictionaryEntry = 'V_Detalles_Facturas_Comision_IMPORTE_COMISION'
|
DictionaryEntry = 'V_Detalles_Facturas_Comision_IMPORTE_COMISION'
|
||||||
end>
|
end>
|
||||||
end>
|
end>
|
||||||
@ -754,7 +749,15 @@ object srvComisiones: TsrvComisiones
|
|||||||
end>
|
end>
|
||||||
Name = 'Update_Comisiones'
|
Name = 'Update_Comisiones'
|
||||||
end>
|
end>
|
||||||
RelationShips = <>
|
RelationShips = <
|
||||||
|
item
|
||||||
|
Name = 'FK_Comision_Facturas'
|
||||||
|
MasterDatasetName = 'Comisiones'
|
||||||
|
MasterFields = 'ID'
|
||||||
|
DetailDatasetName = 'Facturas_Comision'
|
||||||
|
DetailFields = 'ID_COMISION_LIQUIDADA'
|
||||||
|
RelationshipType = rtForeignKey
|
||||||
|
end>
|
||||||
UpdateRules = <
|
UpdateRules = <
|
||||||
item
|
item
|
||||||
Name = 'Insert Comisiones'
|
Name = 'Insert Comisiones'
|
||||||
@ -819,7 +822,7 @@ object srvComisiones: TsrvComisiones
|
|||||||
DeleteCommandName = 'Delete_Comisiones'
|
DeleteCommandName = 'Delete_Comisiones'
|
||||||
UpdateCommandName = 'Update_Comisiones'
|
UpdateCommandName = 'Update_Comisiones'
|
||||||
ReferencedDataset = 'Comisiones'
|
ReferencedDataset = 'Comisiones'
|
||||||
ProcessorOptions = [poPrepareCommands]
|
ProcessorOptions = [poAutoGenerateRefreshDataset, poPrepareCommands]
|
||||||
UpdateMode = updWhereKeyOnly
|
UpdateMode = updWhereKeyOnly
|
||||||
Left = 248
|
Left = 248
|
||||||
Top = 24
|
Top = 24
|
||||||
|
|||||||
@ -38,8 +38,9 @@ implementation
|
|||||||
|
|
||||||
{$R *.dfm}
|
{$R *.dfm}
|
||||||
uses
|
uses
|
||||||
{Generated:} FactuGES_Invk, uDataModuleServer,
|
{Generated:} FactuGES_Invk, uDataModuleServer,
|
||||||
uDatabaseUtils, schComisionesClient_Intf, uRestriccionesUsuarioUtils;
|
uDatabaseUtils, schComisionesClient_Intf, uRestriccionesUsuarioUtils,
|
||||||
|
uBizComisionesServer, uRptComisiones_Server;
|
||||||
|
|
||||||
procedure Create_srvComisiones(out anInstance : IUnknown);
|
procedure Create_srvComisiones(out anInstance : IUnknown);
|
||||||
begin
|
begin
|
||||||
@ -50,6 +51,8 @@ end;
|
|||||||
procedure TsrvComisiones.DARemoteServiceCreate(Sender: TObject);
|
procedure TsrvComisiones.DARemoteServiceCreate(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
//SessionManager := dmServer.SessionManager;
|
//SessionManager := dmServer.SessionManager;
|
||||||
|
//SessionManager := dmServer.SessionManager;
|
||||||
|
bpComisiones.BusinessRulesID := BIZ_SERVER_COMISIONES;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TsrvComisiones.DataAbstractServiceBeforeAcquireConnection(
|
procedure TsrvComisiones.DataAbstractServiceBeforeAcquireConnection(
|
||||||
@ -61,16 +64,15 @@ end;
|
|||||||
function TsrvComisiones.GenerateReport(const AComisionID: Variant;
|
function TsrvComisiones.GenerateReport(const AComisionID: Variant;
|
||||||
const DesglosadoProv: Boolean; const FechaIni, FechaFin: String;
|
const DesglosadoProv: Boolean; const FechaIni, FechaFin: String;
|
||||||
const AAgenteID: Variant): Binary;
|
const AAgenteID: Variant): Binary;
|
||||||
//var
|
var
|
||||||
// AReportGenerator : TRptComisiones;
|
AReportGenerator : TRptComisiones;
|
||||||
begin
|
begin
|
||||||
{ AReportGenerator := TRptComisiones.Create(nil);
|
AReportGenerator := TRptComisiones.Create(nil);
|
||||||
try
|
try
|
||||||
Result := AReportGenerator.GenerarComision(AComisionID, DesglosadoProv, FechaIni, FechaFin, AAgenteID);
|
Result := AReportGenerator.GenerarComision(AComisionID, DesglosadoProv, FechaIni, FechaFin, AAgenteID);
|
||||||
finally
|
finally
|
||||||
FreeAndNIL(AReportGenerator);
|
FreeAndNIL(AReportGenerator);
|
||||||
end;
|
end;
|
||||||
}
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
initialization
|
initialization
|
||||||
|
|||||||
@ -29,11 +29,62 @@ requires
|
|||||||
Contactos_controller,
|
Contactos_controller,
|
||||||
Contactos_model,
|
Contactos_model,
|
||||||
GUIBase,
|
GUIBase,
|
||||||
ApplicationBase;
|
ApplicationBase,
|
||||||
|
rtl,
|
||||||
|
vcl,
|
||||||
|
dbrtl,
|
||||||
|
vcldb,
|
||||||
|
PngComponentsD10,
|
||||||
|
PNG_D10,
|
||||||
|
vclactnband,
|
||||||
|
vclx,
|
||||||
|
cxLibraryD11,
|
||||||
|
dxThemeD11,
|
||||||
|
dxGDIPlusD11,
|
||||||
|
dxCoreD11,
|
||||||
|
cxEditorsD11,
|
||||||
|
cxDataD11,
|
||||||
|
vcljpg,
|
||||||
|
DataAbstract_Core_D11,
|
||||||
|
dsnap,
|
||||||
|
adortl,
|
||||||
|
RemObjects_Core_D11,
|
||||||
|
GUISDK_D11R,
|
||||||
|
designide,
|
||||||
|
xmlrtl,
|
||||||
|
dxLayoutControlD11,
|
||||||
|
dxComnD11,
|
||||||
|
JvCoreD11R,
|
||||||
|
JclVcl,
|
||||||
|
Jcl,
|
||||||
|
JvAppFrmD11R,
|
||||||
|
JvCtrlsD11R,
|
||||||
|
JvSystemD11R,
|
||||||
|
JvStdCtrlsD11R,
|
||||||
|
cxGridD11,
|
||||||
|
cxPageControlD11,
|
||||||
|
cxExtEditorsD11,
|
||||||
|
cxExportD11,
|
||||||
|
tb2k_d10,
|
||||||
|
tbx_d10,
|
||||||
|
JvPageCompsD11R,
|
||||||
|
frx11,
|
||||||
|
fs11,
|
||||||
|
fqb110,
|
||||||
|
bdertl,
|
||||||
|
frxe11,
|
||||||
|
frxTee11,
|
||||||
|
fsTee11,
|
||||||
|
tee,
|
||||||
|
teeUI;
|
||||||
|
|
||||||
contains
|
contains
|
||||||
uComisionesViewRegister in 'uComisionesViewRegister.pas',
|
uComisionesViewRegister in 'uComisionesViewRegister.pas',
|
||||||
uViewComisiones in 'uViewComisiones.pas' {frViewComisiones: TFrame},
|
uViewComisiones in 'uViewComisiones.pas' {frViewComisiones: TFrame},
|
||||||
uEditorComisiones in 'uEditorComisiones.pas' {fEditorComisiones: TfEditorComisiones};
|
uEditorComisiones in 'uEditorComisiones.pas' {fEditorComisiones: TfEditorComisiones},
|
||||||
|
uViewComision in 'uViewComision.pas' {frViewComision: TFrame},
|
||||||
|
uViewFacturasComision in 'uViewFacturasComision.pas' {frViewFacturasComision: TFrame},
|
||||||
|
uEditorComision in 'uEditorComision.pas' {fEditorComision: TfEditorComision},
|
||||||
|
uEditorComisionesReport in 'uEditorComisionesReport.pas' {fEditorComisionesReport: TfEditorComisionesReport};
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|||||||
@ -31,70 +31,92 @@
|
|||||||
<Borland.Personality>Delphi.Personality</Borland.Personality>
|
<Borland.Personality>Delphi.Personality</Borland.Personality>
|
||||||
<Borland.ProjectType>Package</Borland.ProjectType>
|
<Borland.ProjectType>Package</Borland.ProjectType>
|
||||||
<BorlandProject>
|
<BorlandProject>
|
||||||
<BorlandProject> <Delphi.Personality> <Parameters>
|
<BorlandProject><Delphi.Personality><Parameters><Parameters Name="UseLauncher">False</Parameters><Parameters Name="LoadAllSymbols">True</Parameters><Parameters Name="LoadUnspecifiedSymbols">False</Parameters></Parameters><Package_Options><Package_Options Name="ImplicitBuild">False</Package_Options><Package_Options Name="DesigntimeOnly">False</Package_Options><Package_Options Name="RuntimeOnly">False</Package_Options></Package_Options><VersionInfo><VersionInfo Name="IncludeVerInfo">True</VersionInfo><VersionInfo Name="AutoIncBuild">False</VersionInfo><VersionInfo Name="MajorVer">1</VersionInfo><VersionInfo Name="MinorVer">0</VersionInfo><VersionInfo Name="Release">0</VersionInfo><VersionInfo Name="Build">0</VersionInfo><VersionInfo Name="Debug">False</VersionInfo><VersionInfo Name="PreRelease">False</VersionInfo><VersionInfo Name="Special">False</VersionInfo><VersionInfo Name="Private">False</VersionInfo><VersionInfo Name="DLL">False</VersionInfo><VersionInfo Name="Locale">3082</VersionInfo><VersionInfo Name="CodePage">1252</VersionInfo></VersionInfo><VersionInfoKeys><VersionInfoKeys Name="CompanyName"></VersionInfoKeys><VersionInfoKeys Name="FileDescription"></VersionInfoKeys><VersionInfoKeys Name="FileVersion">1.0.0.0</VersionInfoKeys><VersionInfoKeys Name="InternalName"></VersionInfoKeys><VersionInfoKeys Name="LegalCopyright"></VersionInfoKeys><VersionInfoKeys Name="LegalTrademarks"></VersionInfoKeys><VersionInfoKeys Name="OriginalFilename"></VersionInfoKeys><VersionInfoKeys Name="ProductName"></VersionInfoKeys><VersionInfoKeys Name="ProductVersion">1.0.0.0</VersionInfoKeys><VersionInfoKeys Name="Comments"></VersionInfoKeys></VersionInfoKeys><Source><Source Name="MainSource">Comisiones_view.dpk</Source></Source></Delphi.Personality></BorlandProject></BorlandProject>
|
||||||
<Parameters Name="UseLauncher">False</Parameters>
|
|
||||||
<Parameters Name="LoadAllSymbols">True</Parameters>
|
|
||||||
<Parameters Name="LoadUnspecifiedSymbols">False</Parameters>
|
|
||||||
</Parameters>
|
|
||||||
<Package_Options>
|
|
||||||
<Package_Options Name="ImplicitBuild">False</Package_Options>
|
|
||||||
<Package_Options Name="DesigntimeOnly">False</Package_Options>
|
|
||||||
<Package_Options Name="RuntimeOnly">False</Package_Options>
|
|
||||||
</Package_Options>
|
|
||||||
<VersionInfo>
|
|
||||||
<VersionInfo Name="IncludeVerInfo">True</VersionInfo>
|
|
||||||
<VersionInfo Name="AutoIncBuild">False</VersionInfo>
|
|
||||||
<VersionInfo Name="MajorVer">1</VersionInfo>
|
|
||||||
<VersionInfo Name="MinorVer">0</VersionInfo>
|
|
||||||
<VersionInfo Name="Release">0</VersionInfo>
|
|
||||||
<VersionInfo Name="Build">0</VersionInfo>
|
|
||||||
<VersionInfo Name="Debug">False</VersionInfo>
|
|
||||||
<VersionInfo Name="PreRelease">False</VersionInfo>
|
|
||||||
<VersionInfo Name="Special">False</VersionInfo>
|
|
||||||
<VersionInfo Name="Private">False</VersionInfo>
|
|
||||||
<VersionInfo Name="DLL">False</VersionInfo>
|
|
||||||
<VersionInfo Name="Locale">3082</VersionInfo>
|
|
||||||
<VersionInfo Name="CodePage">1252</VersionInfo>
|
|
||||||
</VersionInfo>
|
|
||||||
<VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="CompanyName"></VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="FileDescription"></VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="FileVersion">1.0.0.0</VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="InternalName"></VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="LegalCopyright"></VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="LegalTrademarks"></VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="OriginalFilename"></VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="ProductName"></VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="ProductVersion">1.0.0.0</VersionInfoKeys>
|
|
||||||
<VersionInfoKeys Name="Comments"></VersionInfoKeys>
|
|
||||||
</VersionInfoKeys>
|
|
||||||
<Source>
|
|
||||||
<Source Name="MainSource">Comisiones_view.dpk</Source>
|
|
||||||
</Source>
|
|
||||||
</Delphi.Personality> </BorlandProject></BorlandProject>
|
|
||||||
</ProjectExtensions>
|
</ProjectExtensions>
|
||||||
<Import Project="$(MSBuildBinPath)\Borland.Delphi.Targets" />
|
<Import Project="$(MSBuildBinPath)\Borland.Delphi.Targets" />
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<DelphiCompile Include="Comisiones_view.dpk">
|
<DelphiCompile Include="Comisiones_view.dpk">
|
||||||
<MainSource>MainSource</MainSource>
|
<MainSource>MainSource</MainSource>
|
||||||
</DelphiCompile>
|
</DelphiCompile>
|
||||||
<DCCReference Include="..\Plugin\ApplicationBase.dcp" />
|
<DCCReference Include="adortl.dcp" />
|
||||||
<DCCReference Include="..\Plugin\Comisiones_controller.dcp" />
|
<DCCReference Include="ApplicationBase.dcp" />
|
||||||
<DCCReference Include="..\Plugin\Contactos_controller.dcp" />
|
<DCCReference Include="bdertl.dcp" />
|
||||||
<DCCReference Include="..\Plugin\Contactos_model.dcp" />
|
<DCCReference Include="Comisiones_controller.dcp" />
|
||||||
<DCCReference Include="..\Plugin\GUIBase.dcp" />
|
<DCCReference Include="Contactos_controller.dcp" />
|
||||||
|
<DCCReference Include="Contactos_model.dcp" />
|
||||||
|
<DCCReference Include="cxDataD11.dcp" />
|
||||||
|
<DCCReference Include="cxEditorsD11.dcp" />
|
||||||
|
<DCCReference Include="cxExportD11.dcp" />
|
||||||
|
<DCCReference Include="cxExtEditorsD11.dcp" />
|
||||||
|
<DCCReference Include="cxGridD11.dcp" />
|
||||||
|
<DCCReference Include="cxLibraryD11.dcp" />
|
||||||
|
<DCCReference Include="cxPageControlD11.dcp" />
|
||||||
|
<DCCReference Include="DataAbstract_Core_D11.dcp" />
|
||||||
|
<DCCReference Include="dbrtl.dcp" />
|
||||||
|
<DCCReference Include="designide.dcp" />
|
||||||
|
<DCCReference Include="dsnap.dcp" />
|
||||||
|
<DCCReference Include="dxComnD11.dcp" />
|
||||||
|
<DCCReference Include="dxCoreD11.dcp" />
|
||||||
|
<DCCReference Include="dxGDIPlusD11.dcp" />
|
||||||
|
<DCCReference Include="dxLayoutControlD11.dcp" />
|
||||||
|
<DCCReference Include="dxThemeD11.dcp" />
|
||||||
|
<DCCReference Include="fqb110.dcp" />
|
||||||
|
<DCCReference Include="frx11.dcp" />
|
||||||
|
<DCCReference Include="frxe11.dcp" />
|
||||||
|
<DCCReference Include="frxTee11.dcp" />
|
||||||
|
<DCCReference Include="fs11.dcp" />
|
||||||
|
<DCCReference Include="fsTee11.dcp" />
|
||||||
|
<DCCReference Include="GUIBase.dcp" />
|
||||||
|
<DCCReference Include="GUISDK_D11R.dcp" />
|
||||||
|
<DCCReference Include="Jcl.dcp" />
|
||||||
|
<DCCReference Include="JclVcl.dcp" />
|
||||||
|
<DCCReference Include="JvAppFrmD11R.dcp" />
|
||||||
|
<DCCReference Include="JvCoreD11R.dcp" />
|
||||||
|
<DCCReference Include="JvCtrlsD11R.dcp" />
|
||||||
|
<DCCReference Include="JvPageCompsD11R.dcp" />
|
||||||
|
<DCCReference Include="JvStdCtrlsD11R.dcp" />
|
||||||
|
<DCCReference Include="JvSystemD11R.dcp" />
|
||||||
|
<DCCReference Include="PngComponentsD10.dcp" />
|
||||||
|
<DCCReference Include="PNG_D10.dcp" />
|
||||||
|
<DCCReference Include="RemObjects_Core_D11.dcp" />
|
||||||
|
<DCCReference Include="rtl.dcp" />
|
||||||
|
<DCCReference Include="tb2k_d10.dcp" />
|
||||||
|
<DCCReference Include="tbx_d10.dcp" />
|
||||||
|
<DCCReference Include="tee.dcp" />
|
||||||
|
<DCCReference Include="teeUI.dcp" />
|
||||||
<DCCReference Include="uComisionesViewRegister.pas" />
|
<DCCReference Include="uComisionesViewRegister.pas" />
|
||||||
|
<DCCReference Include="uEditorComision.pas">
|
||||||
|
<Form>fEditorComision</Form>
|
||||||
|
<DesignClass>TfEditorComisiones</DesignClass>
|
||||||
|
</DCCReference>
|
||||||
<DCCReference Include="uEditorComisiones.pas">
|
<DCCReference Include="uEditorComisiones.pas">
|
||||||
<Form>fEditorComisiones</Form>
|
<Form>fEditorComisiones</Form>
|
||||||
<DesignClass>TfEditorComisiones</DesignClass>
|
<DesignClass>TfEditorComisiones</DesignClass>
|
||||||
</DCCReference>
|
</DCCReference>
|
||||||
|
<DCCReference Include="uEditorComisionesReport.pas">
|
||||||
|
<Form>fEditorComisionesRepor</Form>
|
||||||
|
<DesignClass>TfEditorComisiones</DesignClass>
|
||||||
|
</DCCReference>
|
||||||
|
<DCCReference Include="uViewComision.pas">
|
||||||
|
<Form>frViewComision</Form>
|
||||||
|
<DesignClass>TFrame</DesignClass>
|
||||||
|
</DCCReference>
|
||||||
<DCCReference Include="uViewComisiones.pas">
|
<DCCReference Include="uViewComisiones.pas">
|
||||||
<Form>frViewComisiones</Form>
|
<Form>frViewComisiones</Form>
|
||||||
<DesignClass>TFrame</DesignClass>
|
<DesignClass>TFrame</DesignClass>
|
||||||
</DCCReference>
|
</DCCReference>
|
||||||
|
<DCCReference Include="uViewFacturasComision.pas">
|
||||||
|
<Form>frViewFacturasComision</Form>
|
||||||
|
<DesignClass>TFrame</DesignClass>
|
||||||
|
</DCCReference>
|
||||||
|
<DCCReference Include="vcl.dcp" />
|
||||||
|
<DCCReference Include="vclactnband.dcp" />
|
||||||
|
<DCCReference Include="vcldb.dcp" />
|
||||||
|
<DCCReference Include="vcljpg.dcp" />
|
||||||
|
<DCCReference Include="vclx.dcp" />
|
||||||
|
<DCCReference Include="xmlrtl.dcp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
|
||||||
<!-- EurekaLog First Line
|
<!-- EurekaLog First Line
|
||||||
[Exception Log]
|
[Exception Log]
|
||||||
EurekaLog Version=6011
|
EurekaLog Version=6011
|
||||||
|
|||||||
@ -9,22 +9,22 @@ implementation
|
|||||||
|
|
||||||
uses
|
uses
|
||||||
uEditorRegistryUtils,
|
uEditorRegistryUtils,
|
||||||
// uEditorComisionesReport,
|
uEditorComisionesReport,
|
||||||
// uEditorComision,
|
uEditorComision,
|
||||||
uEditorComisiones;
|
uEditorComisiones;
|
||||||
|
|
||||||
procedure RegisterViews;
|
procedure RegisterViews;
|
||||||
begin
|
begin
|
||||||
EditorRegistry.RegisterClass(TfEditorComisiones, 'EditorComisiones');
|
EditorRegistry.RegisterClass(TfEditorComisiones, 'EditorComisiones');
|
||||||
// EditorRegistry.RegisterClass(TfEditorComision, 'EditorComision');
|
EditorRegistry.RegisterClass(TfEditorComision, 'EditorComision');
|
||||||
// EditorRegistry.RegisterClass(TfEditorComisionesPreview, 'EditorComisionesPreview');
|
EditorRegistry.RegisterClass(TfEditorComisionesPreview, 'EditorComisionesPreview');
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure UnregisterViews;
|
procedure UnregisterViews;
|
||||||
begin
|
begin
|
||||||
EditorRegistry.UnRegisterClass(TfEditorComisiones);
|
EditorRegistry.UnRegisterClass(TfEditorComisiones);
|
||||||
// EditorRegistry.UnRegisterClass(TfEditorComision);
|
EditorRegistry.UnRegisterClass(TfEditorComision);
|
||||||
// EditorRegistry.UnRegisterClass(TfEditorComisionesPreview);
|
EditorRegistry.UnRegisterClass(TfEditorComisionesPreview);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|||||||
@ -17,7 +17,7 @@ inherited fEditorComision: TfEditorComision
|
|||||||
Caption = 'Liquidaci'#243'n de comisiones'
|
Caption = 'Liquidaci'#243'n de comisiones'
|
||||||
ExplicitWidth = 611
|
ExplicitWidth = 611
|
||||||
inherited Image1: TImage
|
inherited Image1: TImage
|
||||||
Left = 584
|
Left = 478
|
||||||
Picture.Data = {
|
Picture.Data = {
|
||||||
0A54504E474F626A65637489504E470D0A1A0A0000000D494844520000001800
|
0A54504E474F626A65637489504E470D0A1A0A0000000D494844520000001800
|
||||||
0000180806000000E0773DF80000000970485973000017120000171201679FD2
|
0000180806000000E0773DF80000000970485973000017120000171201679FD2
|
||||||
@ -57,6 +57,12 @@ inherited fEditorComision: TfEditorComision
|
|||||||
4FB2402F1C4138F79E0000000049454E44AE426082}
|
4FB2402F1C4138F79E0000000049454E44AE426082}
|
||||||
ExplicitLeft = 607
|
ExplicitLeft = 607
|
||||||
end
|
end
|
||||||
|
inherited lblDesbloquear: TcxLabel
|
||||||
|
Left = 513
|
||||||
|
ExplicitLeft = 513
|
||||||
|
AnchorX = 558
|
||||||
|
AnchorY = 14
|
||||||
|
end
|
||||||
end
|
end
|
||||||
inherited TBXDock: TTBXDock
|
inherited TBXDock: TTBXDock
|
||||||
Width = 611
|
Width = 611
|
||||||
@ -114,20 +120,20 @@ inherited fEditorComision: TfEditorComision
|
|||||||
end
|
end
|
||||||
end
|
end
|
||||||
inherited pgPaginas: TPageControl
|
inherited pgPaginas: TPageControl
|
||||||
Width = 611
|
Width = 605
|
||||||
Height = 403
|
Height = 397
|
||||||
MultiLine = True
|
MultiLine = True
|
||||||
ExplicitWidth = 611
|
ExplicitWidth = 605
|
||||||
ExplicitHeight = 403
|
ExplicitHeight = 397
|
||||||
inherited pagGeneral: TTabSheet
|
inherited pagGeneral: TTabSheet
|
||||||
ExplicitLeft = 4
|
ExplicitLeft = 4
|
||||||
ExplicitTop = 24
|
ExplicitTop = 24
|
||||||
ExplicitWidth = 603
|
ExplicitWidth = 597
|
||||||
ExplicitHeight = 375
|
ExplicitHeight = 369
|
||||||
inline frViewComision1: TfrViewComision
|
inline frViewComision1: TfrViewComision
|
||||||
Left = 0
|
Left = 0
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 603
|
Width = 597
|
||||||
Height = 127
|
Height = 127
|
||||||
Align = alTop
|
Align = alTop
|
||||||
Font.Charset = DEFAULT_CHARSET
|
Font.Charset = DEFAULT_CHARSET
|
||||||
@ -138,15 +144,15 @@ inherited fEditorComision: TfEditorComision
|
|||||||
ParentFont = False
|
ParentFont = False
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
ReadOnly = False
|
ReadOnly = False
|
||||||
ExplicitWidth = 603
|
ExplicitWidth = 597
|
||||||
ExplicitHeight = 127
|
ExplicitHeight = 127
|
||||||
inherited dxLayoutControlComision: TdxLayoutControl
|
inherited dxLayoutControlComision: TdxLayoutControl
|
||||||
Width = 603
|
Width = 597
|
||||||
Height = 127
|
Height = 127
|
||||||
ExplicitWidth = 603
|
ExplicitWidth = 597
|
||||||
ExplicitHeight = 127
|
ExplicitHeight = 127
|
||||||
DesignSize = (
|
DesignSize = (
|
||||||
603
|
597
|
||||||
127)
|
127)
|
||||||
inherited eReferencia: TcxDBTextEdit
|
inherited eReferencia: TcxDBTextEdit
|
||||||
ExplicitWidth = 164
|
ExplicitWidth = 164
|
||||||
@ -157,8 +163,8 @@ inherited fEditorComision: TfEditorComision
|
|||||||
Width = 108
|
Width = 108
|
||||||
end
|
end
|
||||||
inherited edtFecha: TcxDBDateEdit
|
inherited edtFecha: TcxDBDateEdit
|
||||||
Left = 355
|
Left = 351
|
||||||
ExplicitLeft = 355
|
ExplicitLeft = 351
|
||||||
ExplicitWidth = 170
|
ExplicitWidth = 170
|
||||||
Width = 170
|
Width = 170
|
||||||
end
|
end
|
||||||
@ -171,11 +177,12 @@ inherited fEditorComision: TfEditorComision
|
|||||||
object dxLayoutControl1: TdxLayoutControl
|
object dxLayoutControl1: TdxLayoutControl
|
||||||
Left = 0
|
Left = 0
|
||||||
Top = 127
|
Top = 127
|
||||||
Width = 603
|
Width = 597
|
||||||
Height = 248
|
Height = 242
|
||||||
Align = alClient
|
Align = alClient
|
||||||
ParentBackground = True
|
ParentBackground = True
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
|
TabStop = False
|
||||||
AutoContentSizes = [acsWidth, acsHeight]
|
AutoContentSizes = [acsWidth, acsHeight]
|
||||||
LookAndFeel = frViewComision1.dxLayoutOfficeLookAndFeel1
|
LookAndFeel = frViewComision1.dxLayoutOfficeLookAndFeel1
|
||||||
inline frViewFacturasComision1: TfrViewFacturasComision
|
inline frViewFacturasComision1: TfrViewFacturasComision
|
||||||
@ -210,17 +217,31 @@ inherited fEditorComision: TfEditorComision
|
|||||||
Kind = skSum
|
Kind = skSum
|
||||||
Column = frViewFacturasComision1.cxGridViewIMPORTE_COMISION
|
Column = frViewFacturasComision1.cxGridViewIMPORTE_COMISION
|
||||||
end>
|
end>
|
||||||
DataController.Summary.OnAfterSummary = frViewFacturasComision1cxGridViewDataControllerSummaryAfterSummary
|
inherited cxGridViewID: TcxGridDBColumn
|
||||||
|
IsCaptionAssigned = True
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
inherited ToolBar1: TToolBar
|
inherited ToolBar1: TToolBar
|
||||||
Width = 607
|
Width = 607
|
||||||
ExplicitWidth = 607
|
ExplicitWidth = 607
|
||||||
|
inherited ToolButton1: TToolButton
|
||||||
|
ExplicitWidth = 113
|
||||||
|
end
|
||||||
|
inherited ToolButton4: TToolButton
|
||||||
|
ExplicitWidth = 113
|
||||||
|
end
|
||||||
|
inherited ToolButton2: TToolButton
|
||||||
|
ExplicitWidth = 113
|
||||||
|
end
|
||||||
|
inherited ToolButton7: TToolButton
|
||||||
|
ExplicitWidth = 113
|
||||||
|
end
|
||||||
inherited ToolButton3: TToolButton
|
inherited ToolButton3: TToolButton
|
||||||
ExplicitWidth = 98
|
ExplicitWidth = 113
|
||||||
end
|
end
|
||||||
inherited ToolButton8: TToolButton
|
inherited ToolButton8: TToolButton
|
||||||
ExplicitWidth = 99
|
ExplicitWidth = 113
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -275,148 +296,242 @@ inherited fEditorComision: TfEditorComision
|
|||||||
ExplicitHeight = 46
|
ExplicitHeight = 46
|
||||||
inherited dxLayoutControl1: TdxLayoutControl
|
inherited dxLayoutControl1: TdxLayoutControl
|
||||||
Width = 611
|
Width = 611
|
||||||
|
Height = 46
|
||||||
ExplicitWidth = 611
|
ExplicitWidth = 611
|
||||||
inherited Bevel1: TBevel
|
ExplicitHeight = 46
|
||||||
Left = 92
|
|
||||||
Top = 91
|
|
||||||
Width = 73
|
|
||||||
ExplicitLeft = 92
|
|
||||||
ExplicitTop = 91
|
|
||||||
ExplicitWidth = 73
|
|
||||||
end
|
|
||||||
inherited Bevel3: TBevel
|
inherited Bevel3: TBevel
|
||||||
Left = 305
|
Left = 345
|
||||||
Top = 10
|
Top = 10
|
||||||
Height = 30
|
Height = 30
|
||||||
ExplicitLeft = 305
|
ExplicitLeft = 345
|
||||||
ExplicitTop = 10
|
ExplicitTop = 10
|
||||||
ExplicitHeight = 30
|
ExplicitHeight = 30
|
||||||
end
|
end
|
||||||
inherited Bevel4: TBevel
|
inherited Bevel4: TBevel
|
||||||
Left = 417
|
Left = 457
|
||||||
Top = 91
|
Top = 52
|
||||||
Width = 192
|
Width = 192
|
||||||
ExplicitLeft = 417
|
ExplicitLeft = 457
|
||||||
ExplicitTop = 91
|
ExplicitTop = 52
|
||||||
ExplicitWidth = 192
|
ExplicitWidth = 192
|
||||||
end
|
end
|
||||||
|
inherited Bevel1: TBevel
|
||||||
|
Left = 457
|
||||||
|
Top = 168
|
||||||
|
Width = 73
|
||||||
|
ExplicitLeft = 457
|
||||||
|
ExplicitTop = 168
|
||||||
|
ExplicitWidth = 73
|
||||||
|
end
|
||||||
|
inherited Bevel2: TBevel
|
||||||
|
Left = 119
|
||||||
|
Top = 170
|
||||||
|
Width = 368
|
||||||
|
ExplicitLeft = 119
|
||||||
|
ExplicitTop = 170
|
||||||
|
ExplicitWidth = 368
|
||||||
|
end
|
||||||
inherited ImporteDto: TcxDBCurrencyEdit
|
inherited ImporteDto: TcxDBCurrencyEdit
|
||||||
Left = 163
|
Left = 190
|
||||||
Top = 111
|
Top = 37
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 163
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 111
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 190
|
||||||
|
ExplicitTop = 37
|
||||||
ExplicitWidth = 93
|
ExplicitWidth = 93
|
||||||
Width = 93
|
Width = 93
|
||||||
end
|
end
|
||||||
inherited ImporteIVA: TcxDBCurrencyEdit
|
inherited ImporteIVA: TcxDBCurrencyEdit
|
||||||
Left = 488
|
Left = 528
|
||||||
Top = 37
|
Top = 87
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 488
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 37
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 528
|
||||||
|
ExplicitTop = 87
|
||||||
ExplicitWidth = 137
|
ExplicitWidth = 137
|
||||||
Width = 137
|
Width = 137
|
||||||
end
|
end
|
||||||
inherited ImporteTotal: TcxDBCurrencyEdit
|
inherited ImporteTotal: TcxDBCurrencyEdit
|
||||||
Left = 418
|
Left = 458
|
||||||
Top = 111
|
Top = 141
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 418
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 111
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 458
|
||||||
|
ExplicitTop = 141
|
||||||
ExplicitWidth = 137
|
ExplicitWidth = 137
|
||||||
Width = 137
|
Width = 137
|
||||||
end
|
end
|
||||||
inherited edtDescuento: TcxDBSpinEdit
|
inherited edtDescuento: TcxDBSpinEdit
|
||||||
Left = 92
|
Left = 119
|
||||||
Top = 111
|
|
||||||
DataBinding.DataField = ''
|
|
||||||
Style.IsFontAssigned = True
|
|
||||||
ExplicitLeft = 92
|
|
||||||
ExplicitTop = 111
|
|
||||||
end
|
|
||||||
inherited edtIVA: TcxDBSpinEdit
|
|
||||||
Left = 417
|
|
||||||
Top = 37
|
Top = 37
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 417
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 119
|
||||||
ExplicitTop = 37
|
ExplicitTop = 37
|
||||||
end
|
end
|
||||||
|
inherited edtIVA: TcxDBSpinEdit
|
||||||
|
Left = 457
|
||||||
|
Top = 87
|
||||||
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
|
Style.IsFontAssigned = True
|
||||||
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 457
|
||||||
|
ExplicitTop = 87
|
||||||
|
end
|
||||||
inherited ImporteBase: TcxDBCurrencyEdit
|
inherited ImporteBase: TcxDBCurrencyEdit
|
||||||
Left = 417
|
Left = 457
|
||||||
Top = 10
|
Top = 10
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 417
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 457
|
||||||
ExplicitTop = 10
|
ExplicitTop = 10
|
||||||
ExplicitWidth = 92
|
ExplicitWidth = 92
|
||||||
Width = 92
|
Width = 92
|
||||||
end
|
end
|
||||||
inherited edtRE: TcxDBSpinEdit
|
inherited edtRE: TcxDBSpinEdit
|
||||||
Left = 417
|
Left = 457
|
||||||
Top = 64
|
Top = 114
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 417
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 64
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 457
|
||||||
|
ExplicitTop = 114
|
||||||
end
|
end
|
||||||
inherited ImporteRE: TcxDBCurrencyEdit
|
inherited ImporteRE: TcxDBCurrencyEdit
|
||||||
Left = 488
|
Left = 528
|
||||||
Top = 64
|
Top = 114
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 488
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 64
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 528
|
||||||
|
ExplicitTop = 114
|
||||||
ExplicitWidth = 56
|
ExplicitWidth = 56
|
||||||
Width = 56
|
Width = 56
|
||||||
end
|
end
|
||||||
inherited eImporteNeto: TcxDBCurrencyEdit
|
inherited eImporteNeto: TcxDBCurrencyEdit
|
||||||
Left = 92
|
Left = 119
|
||||||
Top = 10
|
Top = 10
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 92
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 119
|
||||||
ExplicitTop = 10
|
ExplicitTop = 10
|
||||||
ExplicitWidth = 147
|
ExplicitWidth = 147
|
||||||
Width = 147
|
Width = 147
|
||||||
end
|
end
|
||||||
inherited ePorte: TcxDBCurrencyEdit
|
inherited ePorte: TcxDBCurrencyEdit
|
||||||
Left = 92
|
Left = 119
|
||||||
Top = 138
|
Top = 64
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
Style.IsFontAssigned = True
|
Style.IsFontAssigned = True
|
||||||
ExplicitLeft = 92
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 138
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 119
|
||||||
|
ExplicitTop = 64
|
||||||
ExplicitWidth = 147
|
ExplicitWidth = 147
|
||||||
Width = 147
|
Width = 147
|
||||||
end
|
end
|
||||||
inherited eIVA: TcxDBLookupComboBox
|
inherited eIVA: TcxDBLookupComboBox
|
||||||
Left = 92
|
Left = 119
|
||||||
Top = 37
|
Top = 91
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
ExplicitLeft = 92
|
Style.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 37
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 119
|
||||||
|
ExplicitTop = 91
|
||||||
ExplicitWidth = 81
|
ExplicitWidth = 81
|
||||||
Width = 81
|
Width = 81
|
||||||
end
|
end
|
||||||
inherited bTiposIVA: TButton
|
inherited bTiposIVA: TButton
|
||||||
Left = 157
|
Left = 197
|
||||||
Top = 37
|
Top = 91
|
||||||
ExplicitLeft = 157
|
ExplicitLeft = 197
|
||||||
ExplicitTop = 37
|
ExplicitTop = 91
|
||||||
end
|
end
|
||||||
inherited cbRecargoEquivalencia: TcxDBCheckBox
|
inherited cbRecargoEquivalencia: TcxDBCheckBox
|
||||||
Left = 92
|
Left = 119
|
||||||
Top = 64
|
Top = 118
|
||||||
DataBinding.DataField = ''
|
DataBinding.DataField = ''
|
||||||
ExplicitLeft = 92
|
Style.LookAndFeel.SkinName = ''
|
||||||
ExplicitTop = 64
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 119
|
||||||
|
ExplicitTop = 118
|
||||||
ExplicitWidth = 219
|
ExplicitWidth = 219
|
||||||
Width = 219
|
Width = 219
|
||||||
end
|
end
|
||||||
|
inherited edtRetencion: TcxDBSpinEdit
|
||||||
|
Left = 457
|
||||||
|
Top = 188
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
|
Style.IsFontAssigned = True
|
||||||
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 457
|
||||||
|
ExplicitTop = 188
|
||||||
|
end
|
||||||
|
inherited edtImporteRetencion: TcxDBCurrencyEdit
|
||||||
|
Left = 528
|
||||||
|
Top = 188
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
|
Style.IsFontAssigned = True
|
||||||
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 528
|
||||||
|
ExplicitTop = 188
|
||||||
|
ExplicitWidth = 180
|
||||||
|
Width = 180
|
||||||
|
end
|
||||||
|
inherited edtFechaRetencion: TcxDBDateEdit
|
||||||
|
Left = 119
|
||||||
|
Top = 190
|
||||||
|
Style.LookAndFeel.SkinName = ''
|
||||||
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 119
|
||||||
|
ExplicitTop = 190
|
||||||
|
ExplicitWidth = 280
|
||||||
|
Width = 280
|
||||||
|
end
|
||||||
inherited dxLayoutControl1Group_Root: TdxLayoutGroup
|
inherited dxLayoutControl1Group_Root: TdxLayoutGroup
|
||||||
inherited dxLayoutControl1Group1: TdxLayoutGroup
|
inherited dxLayoutControl1Group1: TdxLayoutGroup
|
||||||
ShowCaption = False
|
ShowCaption = False
|
||||||
@ -432,15 +547,15 @@ inherited fEditorComision: TfEditorComision
|
|||||||
inherited dxLayoutControl1Item12: TdxLayoutItem
|
inherited dxLayoutControl1Item12: TdxLayoutItem
|
||||||
Visible = False
|
Visible = False
|
||||||
end
|
end
|
||||||
|
inherited dxLayoutControl1Item14: TdxLayoutItem
|
||||||
|
Visible = False
|
||||||
|
end
|
||||||
inherited dxLayoutControl1Group9: TdxLayoutGroup
|
inherited dxLayoutControl1Group9: TdxLayoutGroup
|
||||||
Visible = False
|
Visible = False
|
||||||
end
|
end
|
||||||
inherited dxLayoutControl1Group8: TdxLayoutGroup
|
inherited dxLayoutControl1Group8: TdxLayoutGroup
|
||||||
Visible = False
|
Visible = False
|
||||||
end
|
end
|
||||||
inherited dxLayoutControl1Item14: TdxLayoutItem
|
|
||||||
Visible = False
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@ -15,7 +15,7 @@ uses
|
|||||||
uIEditorComision, uComisionesController, JvExComCtrls,
|
uIEditorComision, uComisionesController, JvExComCtrls,
|
||||||
JvStatusBar, dxLayoutLookAndFeels, uViewGridBase, uViewGrid,
|
JvStatusBar, dxLayoutLookAndFeels, uViewGridBase, uViewGrid,
|
||||||
uViewDetallesGenerico, uViewFacturasComision, dxLayoutControl, cxControls,
|
uViewDetallesGenerico, uViewFacturasComision, dxLayoutControl, cxControls,
|
||||||
uViewTotales;
|
uViewTotales, uDAInterfaces, cxContainer, cxEdit, cxLabel;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfEditorComision = class(TfEditorDBItem, IEditorComision)
|
TfEditorComision = class(TfEditorDBItem, IEditorComision)
|
||||||
@ -36,8 +36,7 @@ type
|
|||||||
procedure JvFormStorageRestorePlacement(Sender: TObject);
|
procedure JvFormStorageRestorePlacement(Sender: TObject);
|
||||||
procedure JvFormStorageSavePlacement(Sender: TObject);
|
procedure JvFormStorageSavePlacement(Sender: TObject);
|
||||||
procedure dsDataTableDataChange(Sender: TObject; Field: TField);
|
procedure dsDataTableDataChange(Sender: TObject; Field: TField);
|
||||||
procedure frViewFacturasComision1cxGridViewDataControllerSummaryAfterSummary(
|
procedure OnFacturasComisionSummaryAfterSummary(ASender: TcxDataSummary);
|
||||||
ASender: TcxDataSummary);
|
|
||||||
protected
|
protected
|
||||||
FController : IComisionesController;
|
FController : IComisionesController;
|
||||||
FComision: IBizComisiones;
|
FComision: IBizComisiones;
|
||||||
@ -72,7 +71,7 @@ implementation
|
|||||||
|
|
||||||
uses
|
uses
|
||||||
uDataTableUtils, uDataModuleUsuarios, uDialogUtils, uCustomEditor,
|
uDataTableUtils, uDataModuleUsuarios, uDialogUtils, uCustomEditor,
|
||||||
uDataModuleBase;
|
uDataModuleBase, uFactuGES_App;
|
||||||
|
|
||||||
{
|
{
|
||||||
******************************* TfEditorComision *******************************
|
******************************* TfEditorComision *******************************
|
||||||
@ -167,7 +166,7 @@ begin
|
|||||||
|
|
||||||
inherited PonerTitulos(FTitulo);
|
inherited PonerTitulos(FTitulo);
|
||||||
|
|
||||||
Self.Caption := FTitulo + ' (' + dmUsuarios.EmpresaActual.NOMBRE + ')';
|
Self.Caption := FTitulo + ' (' + AppFactuGES.EmpresaActiva.NOMBRE + ')';
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfEditorComision.PrevisualizarInterno;
|
procedure TfEditorComision.PrevisualizarInterno;
|
||||||
@ -232,9 +231,11 @@ begin
|
|||||||
raise Exception.Create('No hay ningún almacén asignado');
|
raise Exception.Create('No hay ningún almacén asignado');
|
||||||
|
|
||||||
Comision.DataTable.Active := True;
|
Comision.DataTable.Active := True;
|
||||||
|
|
||||||
|
frViewFacturasComision1.cxGridView.DataController.Summary.OnAfterSummary := OnFacturasComisionSummaryAfterSummary;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfEditorComision.frViewFacturasComision1cxGridViewDataControllerSummaryAfterSummary(ASender: TcxDataSummary);
|
procedure TfEditorComision.OnFacturasComisionSummaryAfterSummary(ASender: TcxDataSummary);
|
||||||
Var
|
Var
|
||||||
AImporteTotal: Variant;
|
AImporteTotal: Variant;
|
||||||
begin
|
begin
|
||||||
@ -288,6 +289,7 @@ procedure TfEditorComision.CustomEditorClose(Sender: TObject;
|
|||||||
var Action: TCloseAction);
|
var Action: TCloseAction);
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
|
frViewFacturasComision1.cxGridView.DataController.Summary.OnAfterSummary := Nil;
|
||||||
dsDataTable.DataTable := NIL;
|
dsDataTable.DataTable := NIL;
|
||||||
FViewComision := NIL;
|
FViewComision := NIL;
|
||||||
FComision := NIL;
|
FComision := NIL;
|
||||||
|
|||||||
@ -1,11 +1,10 @@
|
|||||||
inherited fEditorComisionesPreview: TfEditorComisionesPreview
|
inherited fEditorComisionesPreview: TfEditorComisionesPreview
|
||||||
Caption = 'Previsualizar la factura'
|
Caption = 'Previsualizar la factura'
|
||||||
ExplicitWidth = 803
|
|
||||||
PixelsPerInch = 96
|
PixelsPerInch = 96
|
||||||
TextHeight = 13
|
TextHeight = 13
|
||||||
inherited JvNavPanelHeader: TJvNavPanelHeader
|
inherited JvNavPanelHeader: TJvNavPanelHeader
|
||||||
inherited Image1: TImage
|
inherited Image1: TImage
|
||||||
Left = 768
|
ExplicitLeft = 768
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
object pnlFiltrar: TTBXDockablePanel [3]
|
object pnlFiltrar: TTBXDockablePanel [3]
|
||||||
@ -23,6 +22,7 @@ inherited fEditorComisionesPreview: TfEditorComisionesPreview
|
|||||||
ShowCaptionWhenDocked = False
|
ShowCaptionWhenDocked = False
|
||||||
SupportedDocks = [dkStandardDock, dkMultiDock]
|
SupportedDocks = [dkStandardDock, dkMultiDock]
|
||||||
TabOrder = 3
|
TabOrder = 3
|
||||||
|
Visible = False
|
||||||
object Label1: TLabel
|
object Label1: TLabel
|
||||||
Left = 261
|
Left = 261
|
||||||
Top = 50
|
Top = 50
|
||||||
@ -149,11 +149,6 @@ inherited fEditorComisionesPreview: TfEditorComisionesPreview
|
|||||||
Left = 59
|
Left = 59
|
||||||
Top = 88
|
Top = 88
|
||||||
end
|
end
|
||||||
inherited frxReport1: TfrxReport
|
|
||||||
Datasets = <>
|
|
||||||
Variables = <>
|
|
||||||
Style = <>
|
|
||||||
end
|
|
||||||
object dsAgentes: TDADataSource
|
object dsAgentes: TDADataSource
|
||||||
Left = 144
|
Left = 144
|
||||||
Top = 96
|
Top = 96
|
||||||
|
|||||||
@ -13,7 +13,8 @@ uses
|
|||||||
JvExComCtrls, JvStatusBar, StdCtrls, Buttons, cxRadioGroup, cxMaskEdit,
|
JvExComCtrls, JvStatusBar, StdCtrls, Buttons, cxRadioGroup, cxMaskEdit,
|
||||||
cxDropDownEdit, cxCalendar, cxControls, cxContainer, cxEdit, cxTextEdit,
|
cxDropDownEdit, cxCalendar, cxControls, cxContainer, cxEdit, cxTextEdit,
|
||||||
TBXDkPanels, cxGraphics, DB, uDADataTable, cxLookupEdit, cxDBLookupEdit,
|
TBXDkPanels, cxGraphics, DB, uDADataTable, cxLookupEdit, cxDBLookupEdit,
|
||||||
cxDBLookupComboBox, uIDataModuleComisionesReport;
|
cxDBLookupComboBox, uIDataModuleComisionesReport, uDAInterfaces,
|
||||||
|
frxExportText, frxExportRTF, frxExportMail, frxExportXLS;
|
||||||
|
|
||||||
type
|
type
|
||||||
TfEditorComisionesPreview = class(TfEditorPreview, IEditorComisionesPreview)
|
TfEditorComisionesPreview = class(TfEditorPreview, IEditorComisionesPreview)
|
||||||
|
|||||||
@ -1,7 +1,8 @@
|
|||||||
inherited frViewComision: TfrViewComision
|
inherited frViewComision: TfrViewComision
|
||||||
Width = 451
|
Width = 451
|
||||||
Height = 130
|
Height = 304
|
||||||
Align = alClient
|
Align = alClient
|
||||||
|
OnCreate = CustomViewCreate
|
||||||
OnDestroy = CustomViewDestroy
|
OnDestroy = CustomViewDestroy
|
||||||
OnShow = CustomViewShow
|
OnShow = CustomViewShow
|
||||||
ExplicitWidth = 451
|
ExplicitWidth = 451
|
||||||
@ -10,16 +11,16 @@ inherited frViewComision: TfrViewComision
|
|||||||
Left = 0
|
Left = 0
|
||||||
Top = 0
|
Top = 0
|
||||||
Width = 451
|
Width = 451
|
||||||
Height = 130
|
Height = 304
|
||||||
Align = alClient
|
Align = alClient
|
||||||
ParentBackground = True
|
ParentBackground = True
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
|
TabStop = False
|
||||||
AutoContentSizes = [acsWidth]
|
AutoContentSizes = [acsWidth]
|
||||||
LookAndFeel = dxLayoutOfficeLookAndFeel1
|
LookAndFeel = dxLayoutOfficeLookAndFeel1
|
||||||
ExplicitHeight = 304
|
|
||||||
DesignSize = (
|
DesignSize = (
|
||||||
451
|
451
|
||||||
130)
|
304)
|
||||||
object eReferencia: TcxDBTextEdit
|
object eReferencia: TcxDBTextEdit
|
||||||
Left = 85
|
Left = 85
|
||||||
Top = 30
|
Top = 30
|
||||||
|
|||||||
@ -10,8 +10,9 @@ uses
|
|||||||
cxDBEdit, dxLayoutControl, cxCheckBox, PngSpeedButton, cxImage, ActnList,
|
cxDBEdit, dxLayoutControl, cxCheckBox, PngSpeedButton, cxImage, ActnList,
|
||||||
ImgList, PngImageList, cxGraphics, cxMaskEdit, cxDropDownEdit,
|
ImgList, PngImageList, cxGraphics, cxMaskEdit, cxDropDownEdit,
|
||||||
uComisionesController, cxSpinEdit, cxCurrencyEdit,
|
uComisionesController, cxSpinEdit, cxCurrencyEdit,
|
||||||
uBizComisiones, cxCalendar,
|
uBizComisiones, cxCalendar, uAgentesController, uBizContactos,
|
||||||
dxLayoutLookAndFeels, cxLookupEdit, cxDBLookupEdit, cxDBLookupComboBox;
|
dxLayoutLookAndFeels, cxLookupEdit, cxDBLookupEdit, cxDBLookupComboBox,
|
||||||
|
uDAInterfaces;
|
||||||
|
|
||||||
type
|
type
|
||||||
IViewComision = interface(IViewBase)
|
IViewComision = interface(IViewBase)
|
||||||
@ -34,9 +35,13 @@ type
|
|||||||
dsAgentes: TDADataSource;
|
dsAgentes: TDADataSource;
|
||||||
procedure CustomViewShow(Sender: TObject);
|
procedure CustomViewShow(Sender: TObject);
|
||||||
procedure CustomViewDestroy(Sender: TObject);
|
procedure CustomViewDestroy(Sender: TObject);
|
||||||
|
procedure CustomViewCreate(Sender: TObject);
|
||||||
|
|
||||||
protected
|
protected
|
||||||
FComision: IBizComisiones;
|
FComision: IBizComisiones;
|
||||||
|
FAgentes: IBizContacto;
|
||||||
|
FAgentesController: IAgentesController;
|
||||||
|
|
||||||
function GetComision: IBizComisiones;
|
function GetComision: IBizComisiones;
|
||||||
procedure SetComision(const Value: IBizComisiones); virtual;
|
procedure SetComision(const Value: IBizComisiones); virtual;
|
||||||
public
|
public
|
||||||
@ -48,7 +53,7 @@ implementation
|
|||||||
{$R *.dfm}
|
{$R *.dfm}
|
||||||
|
|
||||||
uses
|
uses
|
||||||
uDataModuleUsuarios, uAgentesController, uBizContactos;
|
uDataModuleUsuarios;
|
||||||
|
|
||||||
|
|
||||||
{ TfrViewComisions }
|
{ TfrViewComisions }
|
||||||
@ -57,27 +62,28 @@ uses
|
|||||||
******************************* TfrViewComisions ********************************
|
******************************* TfrViewComisions ********************************
|
||||||
}
|
}
|
||||||
|
|
||||||
|
procedure TfrViewComision.CustomViewCreate(Sender: TObject);
|
||||||
|
begin
|
||||||
|
inherited;
|
||||||
|
FAgentesController := TAgentesController.Create;
|
||||||
|
FAgentes := NIL;
|
||||||
|
// FAgentes := FAgentesController.BuscarTodos;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TfrViewComision.CustomViewDestroy(Sender: TObject);
|
procedure TfrViewComision.CustomViewDestroy(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
|
FAgentesController := NIL;
|
||||||
|
FAgentes := NIL;
|
||||||
dsAgentes.DataTable := Nil;
|
dsAgentes.DataTable := Nil;
|
||||||
inherited;
|
inherited;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TfrViewComision.CustomViewShow(Sender: TObject);
|
procedure TfrViewComision.CustomViewShow(Sender: TObject);
|
||||||
Var
|
|
||||||
AAgentes: IBizContacto;
|
|
||||||
FAgentesController: IAgentesController;
|
|
||||||
begin
|
begin
|
||||||
inherited;
|
inherited;
|
||||||
try
|
FAgentes := FAgentesController.BuscarTodos;
|
||||||
FAgentesController := TAgentesController.Create;
|
dsAgentes.DataTable := FAgentes.DataTable;
|
||||||
AAgentes := FAgentesController.BuscarTodos;
|
dsAgentes.DataTable.Active := True;
|
||||||
AAgentes.DataTable.Active := True;
|
|
||||||
dsAgentes.DataTable := AAgentes.DataTable;
|
|
||||||
finally
|
|
||||||
AAgentes := Nil;
|
|
||||||
FAgentesController := Nil;
|
|
||||||
end;
|
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TfrViewComision.GetComision: IBizComisiones;
|
function TfrViewComision.GetComision: IBizComisiones;
|
||||||
|
|||||||
@ -29,6 +29,11 @@ inherited frViewComisiones: TfrViewComisiones
|
|||||||
Column = cxGridViewREFERENCIA
|
Column = cxGridViewREFERENCIA
|
||||||
end>
|
end>
|
||||||
OptionsBehavior.PullFocusing = True
|
OptionsBehavior.PullFocusing = True
|
||||||
|
object cxGridViewID: TcxGridDBColumn
|
||||||
|
DataBinding.FieldName = 'ID'
|
||||||
|
Visible = False
|
||||||
|
VisibleForCustomization = False
|
||||||
|
end
|
||||||
object cxGridViewREFERENCIA: TcxGridDBColumn
|
object cxGridViewREFERENCIA: TcxGridDBColumn
|
||||||
Caption = 'Referencia'
|
Caption = 'Referencia'
|
||||||
DataBinding.FieldName = 'REFERENCIA'
|
DataBinding.FieldName = 'REFERENCIA'
|
||||||
@ -80,24 +85,31 @@ inherited frViewComisiones: TfrViewComisiones
|
|||||||
Width = 121
|
Width = 121
|
||||||
end
|
end
|
||||||
inherited edtFechaFinFiltro: TcxDateEdit
|
inherited edtFechaFinFiltro: TcxDateEdit
|
||||||
|
Left = 225
|
||||||
Style.LookAndFeel.SkinName = ''
|
Style.LookAndFeel.SkinName = ''
|
||||||
StyleDisabled.LookAndFeel.SkinName = ''
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
StyleFocused.LookAndFeel.SkinName = ''
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
StyleHot.LookAndFeel.SkinName = ''
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 225
|
||||||
ExplicitWidth = 121
|
ExplicitWidth = 121
|
||||||
Width = 121
|
Width = 121
|
||||||
end
|
end
|
||||||
inherited eLista: TcxComboBox
|
inherited eLista: TcxComboBox
|
||||||
|
Left = 383
|
||||||
Style.LookAndFeel.SkinName = ''
|
Style.LookAndFeel.SkinName = ''
|
||||||
StyleDisabled.LookAndFeel.SkinName = ''
|
StyleDisabled.LookAndFeel.SkinName = ''
|
||||||
StyleFocused.LookAndFeel.SkinName = ''
|
StyleFocused.LookAndFeel.SkinName = ''
|
||||||
StyleHot.LookAndFeel.SkinName = ''
|
StyleHot.LookAndFeel.SkinName = ''
|
||||||
|
ExplicitLeft = 383
|
||||||
ExplicitWidth = 215
|
ExplicitWidth = 215
|
||||||
Width = 215
|
Width = 215
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
inherited pnlAgrupaciones: TTBXDockablePanel
|
||||||
|
ExplicitWidth = 607
|
||||||
|
end
|
||||||
inherited dxComponentPrinter: TdxComponentPrinter
|
inherited dxComponentPrinter: TdxComponentPrinter
|
||||||
inherited dxComponentPrinterLink: TdxGridReportLink
|
inherited dxComponentPrinterLink: TdxGridReportLink
|
||||||
ReportDocument.CreationDate = 38673.842406053240000000
|
ReportDocument.CreationDate = 38673.842406053240000000
|
||||||
|
|||||||
@ -31,6 +31,7 @@ type
|
|||||||
cxGridViewDESCRIPCION: TcxGridDBColumn;
|
cxGridViewDESCRIPCION: TcxGridDBColumn;
|
||||||
cxGridViewAGENTE: TcxGridDBColumn;
|
cxGridViewAGENTE: TcxGridDBColumn;
|
||||||
cxGridViewIMPORTE_TOTAL: TcxGridDBColumn;
|
cxGridViewIMPORTE_TOTAL: TcxGridDBColumn;
|
||||||
|
cxGridViewID: TcxGridDBColumn;
|
||||||
procedure cxGridViewIDCustomDrawCell(
|
procedure cxGridViewIDCustomDrawCell(
|
||||||
Sender: TcxCustomGridTableView; ACanvas: TcxCanvas;
|
Sender: TcxCustomGridTableView; ACanvas: TcxCanvas;
|
||||||
AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
AViewInfo: TcxGridTableDataCellViewInfo; var ADone: Boolean);
|
||||||
|
|||||||
@ -88,6 +88,9 @@ inherited frViewFacturasComision: TfrViewFacturasComision
|
|||||||
object cxGridViewIMPORTE_COMISIONABLE: TcxGridDBColumn
|
object cxGridViewIMPORTE_COMISIONABLE: TcxGridDBColumn
|
||||||
Caption = 'Importe comisionable'
|
Caption = 'Importe comisionable'
|
||||||
DataBinding.FieldName = 'IMPORTE_COMISIONABLE'
|
DataBinding.FieldName = 'IMPORTE_COMISIONABLE'
|
||||||
|
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||||
|
Properties.Alignment.Horz = taRightJustify
|
||||||
|
HeaderAlignmentHorz = taRightJustify
|
||||||
end
|
end
|
||||||
object cxGridViewCOMISION: TcxGridDBColumn
|
object cxGridViewCOMISION: TcxGridDBColumn
|
||||||
Caption = 'Porcentaje'
|
Caption = 'Porcentaje'
|
||||||
@ -96,10 +99,14 @@ inherited frViewFacturasComision: TfrViewFacturasComision
|
|||||||
Properties.Alignment.Horz = taRightJustify
|
Properties.Alignment.Horz = taRightJustify
|
||||||
Properties.DisplayFormat = '0.0 %;-0.0 %'
|
Properties.DisplayFormat = '0.0 %;-0.0 %'
|
||||||
Properties.MaxValue = 100.000000000000000000
|
Properties.MaxValue = 100.000000000000000000
|
||||||
|
HeaderAlignmentHorz = taRightJustify
|
||||||
end
|
end
|
||||||
object cxGridViewIMPORTE_COMISION: TcxGridDBColumn
|
object cxGridViewIMPORTE_COMISION: TcxGridDBColumn
|
||||||
Caption = 'Importe comisi'#243'n'
|
Caption = 'Importe comisi'#243'n'
|
||||||
DataBinding.FieldName = 'IMPORTE_COMISION'
|
DataBinding.FieldName = 'IMPORTE_COMISION'
|
||||||
|
PropertiesClassName = 'TcxCurrencyEditProperties'
|
||||||
|
Properties.Alignment.Horz = taRightJustify
|
||||||
|
HeaderAlignmentHorz = taRightJustify
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
@ -120,13 +127,13 @@ inherited frViewFacturasComision: TfrViewFacturasComision
|
|||||||
end
|
end
|
||||||
object ToolButton3: TToolButton
|
object ToolButton3: TToolButton
|
||||||
Left = 336
|
Left = 336
|
||||||
Top = 2
|
Top = 0
|
||||||
Action = actExpandir
|
Action = actExpandir
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
end
|
end
|
||||||
object ToolButton8: TToolButton
|
object ToolButton8: TToolButton
|
||||||
Left = 434
|
Left = 434
|
||||||
Top = 2
|
Top = 0
|
||||||
Action = actContraer
|
Action = actContraer
|
||||||
AutoSize = True
|
AutoSize = True
|
||||||
end
|
end
|
||||||
|
|||||||
@ -10,7 +10,7 @@ uses
|
|||||||
cxGridTableView, cxGridDBTableView, cxClasses, cxControls, cxGridCustomView,
|
cxGridTableView, cxGridDBTableView, cxClasses, cxControls, cxGridCustomView,
|
||||||
cxGrid, cxImageComboBox, cxCurrencyEdit, uDataModuleComisiones,
|
cxGrid, cxImageComboBox, cxCurrencyEdit, uDataModuleComisiones,
|
||||||
uBizComisiones, uComisionesController, Grids, DBGrids, cxSpinEdit,
|
uBizComisiones, uComisionesController, Grids, DBGrids, cxSpinEdit,
|
||||||
dxLayoutControl;
|
dxLayoutControl, uDAInterfaces;
|
||||||
|
|
||||||
type
|
type
|
||||||
IViewFacturasComision = interface
|
IViewFacturasComision = interface
|
||||||
|
|||||||
@ -398,6 +398,7 @@ begin
|
|||||||
ShowHourglassCursor;
|
ShowHourglassCursor;
|
||||||
try
|
try
|
||||||
Result := BuscarTodos;
|
Result := BuscarTodos;
|
||||||
|
|
||||||
with Result.DataTable.DynamicWhere do
|
with Result.DataTable.DynamicWhere do
|
||||||
begin
|
begin
|
||||||
//Todas las facturas de un agente determinado
|
//Todas las facturas de un agente determinado
|
||||||
|
|||||||
@ -396,15 +396,15 @@ object srvFacturasProveedor: TsrvFacturasProveedor
|
|||||||
' FACTURAS_PROVEEDOR_DETALLES.VISIBLE,'#10#10' FACTURAS_PROVEEDOR_DE' +
|
' FACTURAS_PROVEEDOR_DETALLES.VISIBLE,'#10#10' FACTURAS_PROVEEDOR_DE' +
|
||||||
'TALLES.ID_ARTICULO, FACTURAS_PROVEEDOR_DETALLES.DESCUENTO,'#10' F' +
|
'TALLES.ID_ARTICULO, FACTURAS_PROVEEDOR_DETALLES.DESCUENTO,'#10' F' +
|
||||||
'ACTURAS_PROVEEDOR_DETALLES.IMPORTE_PORTE,'#10' ARTICULOS.REFERENC' +
|
'ACTURAS_PROVEEDOR_DETALLES.IMPORTE_PORTE,'#10' ARTICULOS.REFERENC' +
|
||||||
'IA, ARTICULOS_PROVEEDORES.REFERENCIA_PROV as REFERENCIA_PROVEEDO' +
|
'IA, ARTICULOS.REFERENCIA_PROV as REFERENCIA_PROVEEDOR,'#10' ARTIC' +
|
||||||
'R,'#10' ARTICULOS.REFERENCIA_FABR as REFERENCIA_FABRICANTE'#10#10'FROM ' +
|
'ULOS.REFERENCIA_FABR as REFERENCIA_FABRICANTE'#10#10'FROM FACTURAS_PRO' +
|
||||||
'FACTURAS_PROVEEDOR_DETALLES'#10'LEFT JOIN ARTICULOS ON FACTURAS_PROV' +
|
'VEEDOR_DETALLES'#10'LEFT JOIN ARTICULOS ON FACTURAS_PROVEEDOR_DETALL' +
|
||||||
'EEDOR_DETALLES.ID_ARTICULO = ARTICULOS.ID'#10'LEFT JOIN FACTURAS_PRO' +
|
'ES.ID_ARTICULO = ARTICULOS.ID'#10'LEFT JOIN FACTURAS_PROVEEDOR ON (F' +
|
||||||
'VEEDOR ON (FACTURAS_PROVEEDOR.ID = FACTURAS_PROVEEDOR_DETALLES.I' +
|
'ACTURAS_PROVEEDOR.ID = FACTURAS_PROVEEDOR_DETALLES.ID_FACTURA)'#10'L' +
|
||||||
'D_FACTURA)'#10'LEFT JOIN ARTICULOS_PROVEEDORES ON ((ARTICULOS_PROVEE' +
|
'EFT JOIN ARTICULOS_PROVEEDORES ON ((ARTICULOS_PROVEEDORES.ID_ART' +
|
||||||
'DORES.ID_ARTICULO = ARTICULOS.ID) AND (ARTICULOS_PROVEEDORES.ID_' +
|
'ICULO = ARTICULOS.ID) AND (ARTICULOS_PROVEEDORES.ID_PROVEEDOR = ' +
|
||||||
'PROVEEDOR = FACTURAS_PROVEEDOR.ID_PROVEEDOR))'#10#10'WHERE {where}'#10'ORD' +
|
'FACTURAS_PROVEEDOR.ID_PROVEEDOR))'#10#10'WHERE {where}'#10'ORDER BY POSICI' +
|
||||||
'ER BY POSICION;'#10#10#10
|
'ON;'#10#10#10
|
||||||
StatementType = stSQL
|
StatementType = stSQL
|
||||||
ColumnMappings = <
|
ColumnMappings = <
|
||||||
item
|
item
|
||||||
|
|||||||
@ -77,7 +77,6 @@ inherited fEditorFacturasProveedor: TfEditorFacturasProveedor
|
|||||||
Left = 427
|
Left = 427
|
||||||
Visible = True
|
Visible = True
|
||||||
ExplicitLeft = 427
|
ExplicitLeft = 427
|
||||||
ExplicitWidth = 179
|
|
||||||
object TBXItem41: TTBXItem
|
object TBXItem41: TTBXItem
|
||||||
Action = actDomiciliacion
|
Action = actDomiciliacion
|
||||||
end
|
end
|
||||||
@ -271,11 +270,15 @@ inherited fEditorFacturasProveedor: TfEditorFacturasProveedor
|
|||||||
object actInformes: TAction
|
object actInformes: TAction
|
||||||
Category = 'Acciones'
|
Category = 'Acciones'
|
||||||
Caption = 'Informes'
|
Caption = 'Informes'
|
||||||
|
Enabled = False
|
||||||
|
Visible = False
|
||||||
OnExecute = actInformesExecute
|
OnExecute = actInformesExecute
|
||||||
end
|
end
|
||||||
object actDomiciliacion: TAction
|
object actDomiciliacion: TAction
|
||||||
Category = 'Acciones'
|
Category = 'Acciones'
|
||||||
Caption = 'Asignar domiciliaci'#243'n'
|
Caption = 'Asignar domiciliaci'#243'n'
|
||||||
|
Enabled = False
|
||||||
|
Visible = False
|
||||||
OnExecute = actDomiciliacionExecute
|
OnExecute = actDomiciliacionExecute
|
||||||
OnUpdate = actDomiciliacionUpdate
|
OnUpdate = actDomiciliacionUpdate
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user