Se adaptan los montajes para que los montajes de baños tengan una ficha de beneficios especifica por defecto. Se arregla el calculo de comisiones para que se pueda filtrar por familia y se agranda el capo forma de pago para los pagos

git-svn-id: https://192.168.0.254/svn/Proyectos.AlonsoYSal_FactuGES/trunk@15 9a1d36f3-7752-2d40-8ccb-50eb49674c68
This commit is contained in:
roberto 2009-06-04 14:37:09 +00:00
parent 993283eefd
commit ab2f55bcfa
21 changed files with 308 additions and 131 deletions

View File

@ -21,7 +21,7 @@ CREATE DOMAIN "CORREOS" AS VARCHAR(60);
CREATE DOMAIN "DESCRIPCIONES" AS VARCHAR(2000); CREATE DOMAIN "DESCRIPCIONES" AS VARCHAR(2000);
CREATE DOMAIN "FAMILIAS" AS VARCHAR(50); CREATE DOMAIN "FAMILIAS" AS VARCHAR(50);
CREATE DOMAIN "FECHAS" AS DATE; CREATE DOMAIN "FECHAS" AS DATE;
CREATE DOMAIN "FORMASPAGO" AS VARCHAR(50); CREATE DOMAIN "FORMASPAGO" AS VARCHAR(200);
CREATE DOMAIN "IMPORTES2" AS NUMERIC(11,2) DEFAULT 0; CREATE DOMAIN "IMPORTES2" AS NUMERIC(11,2) DEFAULT 0;
CREATE DOMAIN "IMPORTES4" AS NUMERIC(13,4) DEFAULT 0; CREATE DOMAIN "IMPORTES4" AS NUMERIC(13,4) DEFAULT 0;
CREATE DOMAIN "IMPORTES6" AS NUMERIC(15,6) DEFAULT 0; CREATE DOMAIN "IMPORTES6" AS NUMERIC(15,6) DEFAULT 0;

View File

@ -114,7 +114,7 @@ IncludeVerInfo=1
AutoIncBuild=0 AutoIncBuild=0
MajorVer=1 MajorVer=1
MinorVer=5 MinorVer=5
Release=1 Release=2
Build=0 Build=0
Debug=0 Debug=0
PreRelease=0 PreRelease=0
@ -126,13 +126,13 @@ CodePage=1252
[Version Info Keys] [Version Info Keys]
CompanyName=Rodax Software S.L. CompanyName=Rodax Software S.L.
FileDescription= FileDescription=
FileVersion=1.5.1.0 FileVersion=1.5.2.0
InternalName=FactuGES InternalName=FactuGES
LegalCopyright= LegalCopyright=
LegalTrademarks= LegalTrademarks=
OriginalFilename= OriginalFilename=
ProductName=FactuGES ProductName=FactuGES
ProductVersion=1.5.1.0 ProductVersion=1.5.2.0
Comments= Comments=
[Excluded Packages] [Excluded Packages]
C:\Archivos de programa\Borland\Delphi7\Projects\Bpl\cxLibraryVCLD7.bpl=Express Cross Platform Library (VCL Edition) by Developer Express Inc. C:\Archivos de programa\Borland\Delphi7\Projects\Bpl\cxLibraryVCLD7.bpl=Express Cross Platform Library (VCL Edition) by Developer Express Inc.
@ -183,8 +183,8 @@ Count=1
Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE; Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
[HistoryLists\hlSearchPath] [HistoryLists\hlSearchPath]
Count=16 Count=16
Item0=..\Modulos\Presupuestos\Reglas;..\Modulos\Contactos\Reglas;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Albaranes de cliente\Reglas Item0=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Intervalos;..\Modulos\Documentos asociados;..\Modulos\Contactos\Cliente;..\Modulos\Contactos\Reglas;..\Modulos\Presupuestos\Cliente;..\Modulos\Presupuestos\Reglas;..\Modulos\Albaranes de cliente\Cliente;..\Modulos\Albaranes de cliente\Reglas;..\Modulos\Facturas de cliente\Cliente;..\Modulos\Facturas de cliente\Reglas;..\Modulos\Pedidos a proveedor\Cliente;..\Modulos\Pedidos a proveedor\Reglas;..\Modulos\Facturas de proveedor\Cliente;..\Modulos\Facturas de proveedor\Reglas;..\Modulos\Montajes\Reglas;..\Modulos\Montajes\Cliente;..\Modulos\Articulos\Cliente;..\Modulos\Articulos\Reglas;..\Modulos\Almacenes\Reglas;..\Modulos\Almacenes\Cliente;..\Modulos\Pagos\Reglas;..\Modulos\Pagos\Cliente;..\Modulos\Cuentas\Reglas;..\Modulos\Cuentas\Cliente;..\Modulos\Asientos\Reglas;..\Modulos\Asientos\Cliente;..\Modulos\Calendarios\Cliente;..\Modulos\Calendarios\Reglas
Item1=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Intervalos;..\Modulos\Documentos asociados;..\Modulos\Contactos\Cliente;..\Modulos\Contactos\Reglas;..\Modulos\Presupuestos\Cliente;..\Modulos\Presupuestos\Reglas;..\Modulos\Albaranes de cliente\Cliente;..\Modulos\Albaranes de cliente\Reglas;..\Modulos\Facturas de cliente\Cliente;..\Modulos\Facturas de cliente\Reglas;..\Modulos\Pedidos a proveedor\Cliente;..\Modulos\Pedidos a proveedor\Reglas;..\Modulos\Facturas de proveedor\Cliente;..\Modulos\Facturas de proveedor\Reglas;..\Modulos\Montajes\Reglas;..\Modulos\Montajes\Cliente;..\Modulos\Articulos\Cliente;..\Modulos\Articulos\Reglas;..\Modulos\Almacenes\Reglas;..\Modulos\Almacenes\Cliente;..\Modulos\Pagos\Reglas;..\Modulos\Pagos\Cliente;..\Modulos\Cuentas\Reglas;..\Modulos\Cuentas\Cliente;..\Modulos\Asientos\Reglas;..\Modulos\Asientos\Cliente;..\Modulos\Calendarios\Cliente;..\Modulos\Calendarios\Reglas Item1=..\Modulos\Presupuestos\Reglas;..\Modulos\Contactos\Reglas;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Albaranes de cliente\Reglas
Item2=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente;..\..\Cuentas\Cliente Item2=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente;..\..\Cuentas\Cliente
Item3=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente Item3=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente
Item4=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente Item4=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente
@ -204,8 +204,8 @@ Count=1
Item0=.\ Item0=.\
[HistoryLists\hlOutputDirectorry] [HistoryLists\hlOutputDirectorry]
Count=2 Count=2
Item0=..\Output\Servidor Item0=..\Output\Cliente
Item1=..\Output\Cliente Item1=..\Output\Servidor
[HistoryLists\hlBPLOutput] [HistoryLists\hlBPLOutput]
Count=3 Count=3
Item0=..\..\..\Output\Cliente Item0=..\..\..\Output\Cliente

Binary file not shown.

View File

@ -10,6 +10,8 @@ object dmComisiones: TdmComisiones
ParamType = fResult ParamType = fResult
DataType = rtString DataType = rtString
end> end>
Left = 1265
Top = 212
Height = 668 Height = 668
Width = 358 Width = 358
object RORemoteService: TRORemoteService object RORemoteService: TRORemoteService
@ -321,6 +323,18 @@ object dmComisiones: TdmComisiones
Lookup = False Lookup = False
LookupCache = False LookupCache = False
end end
item
Name = 'TIPO'
DataType = datString
Size = 6
BlobType = dabtUnknown
DisplayWidth = 0
Alignment = taLeftJustify
InPrimaryKey = False
Calculated = False
Lookup = False
LookupCache = False
end
item item
Name = 'CODIGOCATEGORIA' Name = 'CODIGOCATEGORIA'
DataType = datInteger DataType = datInteger

View File

@ -2,7 +2,7 @@ unit uDataModuleComisiones;
interface interface
uses {vcl:} SysUtils, Classes, DB, DBClient, uses {vcl:} SysUtils, Classes, DB, DBClient,
{RemObjects:} uDAClientDataModule, uDADataTable, uDABINAdapter, {RemObjects:} uDAClientDataModule, uDADataTable, uDABINAdapter,
uROServiceComponent, uRORemoteService, uROClient, uROBinMessage, uROServiceComponent, uRORemoteService, uROClient, uROBinMessage,
uROWinInetHttpChannel, uDataModuleBase, uDAScriptingProvider, uROWinInetHttpChannel, uDataModuleBase, uDAScriptingProvider,
@ -29,7 +29,7 @@ type
procedure SetComision(Codigo : Integer; Comision : Float); procedure SetComision(Codigo : Integer; Comision : Float);
procedure CalcularComisiones; procedure CalcularComisiones;
function GetCobrosComision(FechaInicial, FechaFinal : TDateTime): IBizCobrosComision; function GetCobrosComision(FechaInicial, FechaFinal : TDateTime; const Tipo: String): IBizCobrosComision;
end; end;
var var
@ -37,7 +37,7 @@ var
implementation implementation
uses FactuGES_Intf, DataAbstract_Intf, Controls, forms, uDataTableUtils, uses FactuGES_Intf, DataAbstract_Intf, uDAInterfaces, Controls, forms, uDataTableUtils,
uGUIBase, uEditorComisiones, schComisionesClient_Intf; uGUIBase, uEditorComisiones, schComisionesClient_Intf;
{$R *.DFM} {$R *.DFM}
@ -65,7 +65,7 @@ begin
RORemoteService.Message := dmBase.ROMessage; RORemoteService.Message := dmBase.ROMessage;
end; end;
function TdmComisiones.GetCobrosComision(FechaInicial, FechaFinal: TDateTime): IBizCobrosComision; function TdmComisiones.GetCobrosComision(FechaInicial, FechaFinal: TDateTime; const Tipo: String): IBizCobrosComision;
var var
dtCobrosComision: TDACDSDataTable; dtCobrosComision: TDACDSDataTable;
AParams : TDADatasetParamArray; AParams : TDADatasetParamArray;
@ -94,6 +94,27 @@ begin
DataRequestCall.ParamByName(par_Params).AsComplexType := AParams; DataRequestCall.ParamByName(par_Params).AsComplexType := AParams;
end; end;
if Tipo = 'Cocina' then
begin
with dtCobrosComision.Where do
begin
AddOperator(opAND);
OpenBraket;
AddText('V_TIPOS_PAGO.' + fld_COBROSCOMISIONTIPO + ' = ''Cocina''', False);
CloseBraket;
end;
end
else if Tipo = 'Baño' then
begin
with dtCobrosComision.Where do
begin
AddOperator(opAND);
OpenBraket;
AddText('V_TIPOS_PAGO.' + fld_COBROSCOMISIONTIPO + ' = ''Baño''', False);
CloseBraket;
end;
end;
(dtCobrosComision as IBizCobrosComision).VendedoresComision := GetVendedoresComision; (dtCobrosComision as IBizCobrosComision).VendedoresComision := GetVendedoresComision;
Result := (dtCobrosComision as IBizCobrosComision); Result := (dtCobrosComision as IBizCobrosComision);

View File

@ -54,8 +54,9 @@ inherited fEditorComisiones: TfEditorComisiones
inherited TBXDock: TTBXDock inherited TBXDock: TTBXDock
Width = 843 Width = 843
inherited tbxFiltro: TTBXToolbar inherited tbxFiltro: TTBXToolbar
Left = 185 Left = 184
DockPos = 184 DockPos = 184
Visible = False
inherited TBXItem37: TTBXItem inherited TBXItem37: TTBXItem
Visible = False Visible = False
end end
@ -67,15 +68,15 @@ inherited fEditorComisiones: TfEditorComisiones
end end
object dxLayoutControl1: TdxLayoutControl [3] object dxLayoutControl1: TdxLayoutControl [3]
Left = 0 Left = 0
Top = 76 Top = 102
Width = 843 Width = 843
Height = 533 Height = 507
Align = alClient Align = alClient
TabOrder = 3 TabOrder = 3
AutoContentSizes = [acsWidth, acsHeight] AutoContentSizes = [acsWidth, acsHeight]
LookAndFeel = dxLayoutOfficeLookAndFeel1 LookAndFeel = dxLayoutOfficeLookAndFeel1
object edtFechaIni: TcxDateEdit object edtFechaIni: TcxDateEdit
Left = 61 Left = 63
Top = 30 Top = 30
Properties.DateButtons = [btnToday] Properties.DateButtons = [btnToday]
Properties.DateOnError = deToday Properties.DateOnError = deToday
@ -98,7 +99,7 @@ inherited fEditorComisiones: TfEditorComisiones
Width = 297 Width = 297
end end
object edtFechaFin: TcxDateEdit object edtFechaFin: TcxDateEdit
Left = 400 Left = 401
Top = 30 Top = 30
Properties.DateButtons = [btnToday] Properties.DateButtons = [btnToday]
Properties.DateOnError = deToday Properties.DateOnError = deToday
@ -131,10 +132,10 @@ inherited fEditorComisiones: TfEditorComisiones
end end
object cxGrid: TcxGrid object cxGrid: TcxGrid
Left = 22 Left = 22
Top = 357 Top = 331
Width = 799 Width = 799
Height = 160 Height = 160
TabOrder = 5 TabOrder = 6
LookAndFeel.Kind = lfOffice11 LookAndFeel.Kind = lfOffice11
LookAndFeel.NativeStyle = True LookAndFeel.NativeStyle = True
object cxGridView: TcxGridDBTableView object cxGridView: TcxGridDBTableView
@ -218,7 +219,7 @@ inherited fEditorComisiones: TfEditorComisiones
end end
object edtImporteCobros: TcxCurrencyEdit object edtImporteCobros: TcxCurrencyEdit
Left = 685 Left = 685
Top = 306 Top = 280
Properties.Alignment.Horz = taRightJustify Properties.Alignment.Horz = taRightJustify
Properties.ReadOnly = True Properties.ReadOnly = True
Style.BorderColor = clWindowFrame Style.BorderColor = clWindowFrame
@ -231,15 +232,15 @@ inherited fEditorComisiones: TfEditorComisiones
StyleFocused.LookAndFeel.NativeStyle = True StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.Kind = lfStandard StyleHot.LookAndFeel.Kind = lfStandard
StyleHot.LookAndFeel.NativeStyle = True StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 3 TabOrder = 4
Width = 136 Width = 136
end end
object cxGrid1: TcxGrid object cxGrid1: TcxGrid
Left = 22 Left = 22
Top = 85 Top = 112
Width = 799 Width = 799
Height = 215 Height = 215
TabOrder = 4 TabOrder = 5
LookAndFeel.Kind = lfOffice11 LookAndFeel.Kind = lfOffice11
LookAndFeel.NativeStyle = True LookAndFeel.NativeStyle = True
object cxGridDBTableView1: TcxGridDBTableView object cxGridDBTableView1: TcxGridDBTableView
@ -367,31 +368,64 @@ inherited fEditorComisiones: TfEditorComisiones
Height = 5 Height = 5
AlignSplitter = salTop AlignSplitter = salTop
end end
object cxFamilia: TcxComboBox
Left = 63
Top = 61
Properties.DropDownListStyle = lsFixedList
Properties.DropDownRows = 4
Properties.Items.Strings = (
'Todas'
'Cocina'
'Ba'#241'o')
Style.BorderColor = clWindowFrame
Style.BorderStyle = ebs3D
Style.HotTrack = False
Style.LookAndFeel.NativeStyle = True
Style.ButtonStyle = bts3D
Style.PopupBorderStyle = epbsFrame3D
StyleDisabled.LookAndFeel.NativeStyle = True
StyleFocused.LookAndFeel.NativeStyle = True
StyleHot.LookAndFeel.NativeStyle = True
TabOrder = 3
Text = 'Todas'
Width = 121
end
object dxLayoutControl1Group_Root: TdxLayoutGroup object dxLayoutControl1Group_Root: TdxLayoutGroup
ShowCaption = False ShowCaption = False
Hidden = True Hidden = True
ShowBorder = False ShowBorder = False
object dxLayoutControl1Group1: TdxLayoutGroup object dxLayoutControl1Group1: TdxLayoutGroup
Caption = 'Seleccione el rango de fechas' Caption = 'Seleccione el rango de fechas'
LayoutDirection = ldHorizontal object dxLayoutControl1Group4: TdxLayoutGroup
object dxLayoutControl1Item1: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'Desde:'
Control = edtFechaIni
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item2: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'hasta:'
Control = edtFechaFin
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item5: TdxLayoutItem
Caption = 'New Item'
ShowCaption = False ShowCaption = False
Control = Button1 Hidden = True
LayoutDirection = ldHorizontal
ShowBorder = False
object dxLayoutControl1Item1: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'Desde:'
Control = edtFechaIni
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item2: TdxLayoutItem
AutoAligns = [aaVertical]
AlignHorz = ahClient
Caption = 'hasta:'
Control = edtFechaFin
ControlOptions.ShowBorder = False
end
object dxLayoutControl1Item5: TdxLayoutItem
Caption = 'New Item'
ShowCaption = False
Control = Button1
ControlOptions.ShowBorder = False
end
end
object dxLayoutControl1Item7: TdxLayoutItem
AutoAligns = [aaVertical]
Caption = 'Familia:'
Control = cxFamilia
ControlOptions.ShowBorder = False ControlOptions.ShowBorder = False
end end
end end
@ -521,7 +555,7 @@ inherited fEditorComisiones: TfEditorComisiones
PrinterPage.ScaleMode = smFit PrinterPage.ScaleMode = smFit
PrinterPage._dxMeasurementUnits_ = 0 PrinterPage._dxMeasurementUnits_ = 0
PrinterPage._dxLastMU_ = 2 PrinterPage._dxLastMU_ = 2
ReportDocument.CreationDate = 39393.710588645830000000 ReportDocument.CreationDate = 39968.541274768520000000
ReportDocument.IsCaptionAssigned = True ReportDocument.IsCaptionAssigned = True
ShrinkToPageWidth = True ShrinkToPageWidth = True
Items = < Items = <
@ -557,7 +591,7 @@ inherited fEditorComisiones: TfEditorComisiones
PrinterPage.ScaleMode = smFit PrinterPage.ScaleMode = smFit
PrinterPage._dxMeasurementUnits_ = 0 PrinterPage._dxMeasurementUnits_ = 0
PrinterPage._dxLastMU_ = 2 PrinterPage._dxLastMU_ = 2
ReportDocument.CreationDate = 39393.710588645830000000 ReportDocument.CreationDate = 39968.541274768520000000
ReportTitle.Font.Charset = DEFAULT_CHARSET ReportTitle.Font.Charset = DEFAULT_CHARSET
ReportTitle.Font.Color = clBlack ReportTitle.Font.Color = clBlack
ReportTitle.Font.Height = -16 ReportTitle.Font.Height = -16
@ -594,7 +628,7 @@ inherited fEditorComisiones: TfEditorComisiones
PrinterPage.ScaleMode = smFit PrinterPage.ScaleMode = smFit
PrinterPage._dxMeasurementUnits_ = 0 PrinterPage._dxMeasurementUnits_ = 0
PrinterPage._dxLastMU_ = 2 PrinterPage._dxLastMU_ = 2
ReportDocument.CreationDate = 39393.710588645830000000 ReportDocument.CreationDate = 39968.541274768520000000
ReportTitle.Font.Charset = DEFAULT_CHARSET ReportTitle.Font.Charset = DEFAULT_CHARSET
ReportTitle.Font.Color = clBlack ReportTitle.Font.Color = clBlack
ReportTitle.Font.Height = -16 ReportTitle.Font.Height = -16

View File

@ -73,6 +73,9 @@ type
dxComponentPrinterLink3: TdxGridReportLink; dxComponentPrinterLink3: TdxGridReportLink;
dxComponentPrinterLink2: TdxCompositionReportLink; dxComponentPrinterLink2: TdxCompositionReportLink;
cxStyle1: TcxStyle; cxStyle1: TcxStyle;
cxFamilia: TcxComboBox;
dxLayoutControl1Item7: TdxLayoutItem;
dxLayoutControl1Group4: TdxLayoutGroup;
procedure Button1Click(Sender: TObject); procedure Button1Click(Sender: TObject);
procedure FormShow(Sender: TObject); procedure FormShow(Sender: TObject);
procedure edtFechaIniPropertiesValidate(Sender: TObject; procedure edtFechaIniPropertiesValidate(Sender: TObject;
@ -109,7 +112,7 @@ begin
if Assigned(FCobrosComision) then if Assigned(FCobrosComision) then
FCobrosComision := Nil; FCobrosComision := Nil;
FCobrosComision := dmComisiones.GetCobrosComision(edtFechaIni.Date, edtFechaFin.Date); FCobrosComision := dmComisiones.GetCobrosComision(edtFechaIni.Date, edtFechaFin.Date, cxFamilia.text);
DADataSource.DataTable := FCobrosComision.DataTable; DADataSource.DataTable := FCobrosComision.DataTable;
DADataSource2.DataTable := FCobrosComision.VendedoresComision.DataTable; DADataSource2.DataTable := FCobrosComision.VendedoresComision.DataTable;
FCobrosComision.OnTotalChanged := OnTotalChanged; FCobrosComision.OnTotalChanged := OnTotalChanged;

View File

@ -9,9 +9,9 @@ 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_VENDEDORESCOMISION = '{1BC4C0DE-A875-4DF3-BD41-683A8C4F961F}'; RID_VENDEDORESCOMISION = '{1991386F-7432-48B0-A983-6E486684278E}';
RID_COMISIONES = '{6B2BBEE4-C97B-44C0-9D4B-A66082B1A01F}'; RID_COMISIONES = '{E02C1BEE-E392-4BA3-AF6E-F0767D43EEED}';
RID_COBROSCOMISION = '{766D9F94-5866-441D-A089-C4411C671E01}'; RID_COBROSCOMISION = '{9A01A4E9-2DE3-4E5B-B0EE-97BD47A2F4CC}';
{ Data table names } { Data table names }
nme_VENDEDORESCOMISION = 'VENDEDORESCOMISION'; nme_VENDEDORESCOMISION = 'VENDEDORESCOMISION';
@ -44,6 +44,7 @@ const
fld_COBROSCOMISIONIMPORTE = 'IMPORTE'; fld_COBROSCOMISIONIMPORTE = 'IMPORTE';
fld_COBROSCOMISIONFORMAPAGO = 'FORMAPAGO'; fld_COBROSCOMISIONFORMAPAGO = 'FORMAPAGO';
fld_COBROSCOMISIONDESCRIPCION = 'DESCRIPCION'; fld_COBROSCOMISIONDESCRIPCION = 'DESCRIPCION';
fld_COBROSCOMISIONTIPO = 'TIPO';
fld_COBROSCOMISIONCODIGOCATEGORIA = 'CODIGOCATEGORIA'; fld_COBROSCOMISIONCODIGOCATEGORIA = 'CODIGOCATEGORIA';
fld_COBROSCOMISIONCATEGORIA = 'CATEGORIA'; fld_COBROSCOMISIONCATEGORIA = 'CATEGORIA';
@ -57,13 +58,14 @@ const
idx_COBROSCOMISIONIMPORTE = 6; idx_COBROSCOMISIONIMPORTE = 6;
idx_COBROSCOMISIONFORMAPAGO = 7; idx_COBROSCOMISIONFORMAPAGO = 7;
idx_COBROSCOMISIONDESCRIPCION = 8; idx_COBROSCOMISIONDESCRIPCION = 8;
idx_COBROSCOMISIONCODIGOCATEGORIA = 9; idx_COBROSCOMISIONTIPO = 9;
idx_COBROSCOMISIONCATEGORIA = 10; idx_COBROSCOMISIONCODIGOCATEGORIA = 10;
idx_COBROSCOMISIONCATEGORIA = 11;
type type
{ IVENDEDORESCOMISION } { IVENDEDORESCOMISION }
IVENDEDORESCOMISION = interface(IDAStronglyTypedDataTable) IVENDEDORESCOMISION = interface(IDAStronglyTypedDataTable)
['{4B0EE488-AE5C-4F1B-907A-08A753A211FC}'] ['{240371ED-0F0F-4D1F-B6D2-98F2C95F9090}']
{ Property getters and setters } { Property getters and setters }
function GetVENDEDORValue: String; function GetVENDEDORValue: String;
procedure SetVENDEDORValue(const aValue: String); procedure SetVENDEDORValue(const aValue: String);
@ -104,7 +106,7 @@ type
{ ICOMISIONES } { ICOMISIONES }
ICOMISIONES = interface(IDAStronglyTypedDataTable) ICOMISIONES = interface(IDAStronglyTypedDataTable)
['{16E451A9-2317-4BCF-A569-278333EEAB2C}'] ['{E5981A96-57D7-4E08-874A-0EEA50CD28DE}']
{ Property getters and setters } { Property getters and setters }
function GetCOMISIONValue: Float; function GetCOMISIONValue: Float;
procedure SetCOMISIONValue(const aValue: Float); procedure SetCOMISIONValue(const aValue: Float);
@ -133,7 +135,7 @@ type
{ ICOBROSCOMISION } { ICOBROSCOMISION }
ICOBROSCOMISION = interface(IDAStronglyTypedDataTable) ICOBROSCOMISION = interface(IDAStronglyTypedDataTable)
['{3B95C673-4F15-449B-9757-2074539B57AC}'] ['{227279E8-9B85-40AC-97BE-1A7D46C7EA4E}']
{ Property getters and setters } { Property getters and setters }
function GetSELECCIONValue: Integer; function GetSELECCIONValue: Integer;
procedure SetSELECCIONValue(const aValue: Integer); procedure SetSELECCIONValue(const aValue: Integer);
@ -153,6 +155,8 @@ type
procedure SetFORMAPAGOValue(const aValue: String); procedure SetFORMAPAGOValue(const aValue: String);
function GetDESCRIPCIONValue: String; function GetDESCRIPCIONValue: String;
procedure SetDESCRIPCIONValue(const aValue: String); procedure SetDESCRIPCIONValue(const aValue: String);
function GetTIPOValue: String;
procedure SetTIPOValue(const aValue: String);
function GetCODIGOCATEGORIAValue: Integer; function GetCODIGOCATEGORIAValue: Integer;
procedure SetCODIGOCATEGORIAValue(const aValue: Integer); procedure SetCODIGOCATEGORIAValue(const aValue: Integer);
function GetCATEGORIAValue: String; function GetCATEGORIAValue: String;
@ -169,6 +173,7 @@ type
property IMPORTE: Float read GetIMPORTEValue write SetIMPORTEValue; property IMPORTE: Float read GetIMPORTEValue write SetIMPORTEValue;
property FORMAPAGO: String read GetFORMAPAGOValue write SetFORMAPAGOValue; property FORMAPAGO: String read GetFORMAPAGOValue write SetFORMAPAGOValue;
property DESCRIPCION: String read GetDESCRIPCIONValue write SetDESCRIPCIONValue; property DESCRIPCION: String read GetDESCRIPCIONValue write SetDESCRIPCIONValue;
property TIPO: String read GetTIPOValue write SetTIPOValue;
property CODIGOCATEGORIA: Integer read GetCODIGOCATEGORIAValue write SetCODIGOCATEGORIAValue; property CODIGOCATEGORIA: Integer read GetCODIGOCATEGORIAValue write SetCODIGOCATEGORIAValue;
property CATEGORIA: String read GetCATEGORIAValue write SetCATEGORIAValue; property CATEGORIA: String read GetCATEGORIAValue write SetCATEGORIAValue;
end; end;
@ -196,6 +201,8 @@ type
procedure SetFORMAPAGOValue(const aValue: String); virtual; procedure SetFORMAPAGOValue(const aValue: String); virtual;
function GetDESCRIPCIONValue: String; virtual; function GetDESCRIPCIONValue: String; virtual;
procedure SetDESCRIPCIONValue(const aValue: String); virtual; procedure SetDESCRIPCIONValue(const aValue: String); virtual;
function GetTIPOValue: String; virtual;
procedure SetTIPOValue(const aValue: String); virtual;
function GetCODIGOCATEGORIAValue: Integer; virtual; function GetCODIGOCATEGORIAValue: Integer; virtual;
procedure SetCODIGOCATEGORIAValue(const aValue: Integer); virtual; procedure SetCODIGOCATEGORIAValue(const aValue: Integer); virtual;
function GetCATEGORIAValue: String; virtual; function GetCATEGORIAValue: String; virtual;
@ -211,6 +218,7 @@ type
property IMPORTE: Float read GetIMPORTEValue write SetIMPORTEValue; property IMPORTE: Float read GetIMPORTEValue write SetIMPORTEValue;
property FORMAPAGO: String read GetFORMAPAGOValue write SetFORMAPAGOValue; property FORMAPAGO: String read GetFORMAPAGOValue write SetFORMAPAGOValue;
property DESCRIPCION: String read GetDESCRIPCIONValue write SetDESCRIPCIONValue; property DESCRIPCION: String read GetDESCRIPCIONValue write SetDESCRIPCIONValue;
property TIPO: String read GetTIPOValue write SetTIPOValue;
property CODIGOCATEGORIA: Integer read GetCODIGOCATEGORIAValue write SetCODIGOCATEGORIAValue; property CODIGOCATEGORIA: Integer read GetCODIGOCATEGORIAValue write SetCODIGOCATEGORIAValue;
property CATEGORIA: String read GetCATEGORIAValue write SetCATEGORIAValue; property CATEGORIA: String read GetCATEGORIAValue write SetCATEGORIAValue;
@ -389,6 +397,16 @@ begin
DataTable.Fields[idx_COBROSCOMISIONDESCRIPCION].AsString := aValue; DataTable.Fields[idx_COBROSCOMISIONDESCRIPCION].AsString := aValue;
end; end;
function TCOBROSCOMISIONDataTableRules.GetTIPOValue: String;
begin
result := DataTable.Fields[idx_COBROSCOMISIONTIPO].AsString;
end;
procedure TCOBROSCOMISIONDataTableRules.SetTIPOValue(const aValue: String);
begin
DataTable.Fields[idx_COBROSCOMISIONTIPO].AsString := aValue;
end;
function TCOBROSCOMISIONDataTableRules.GetCODIGOCATEGORIAValue: Integer; function TCOBROSCOMISIONDataTableRules.GetCODIGOCATEGORIAValue: Integer;
begin begin
result := DataTable.Fields[idx_COBROSCOMISIONCODIGOCATEGORIA].AsInteger; result := DataTable.Fields[idx_COBROSCOMISIONCODIGOCATEGORIA].AsInteger;

View File

@ -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_VENDEDORESCOMISIONDelta = '{47FDF38D-3FF4-4F15-A4B1-212E3669BFAA}'; RID_VENDEDORESCOMISIONDelta = '{AF94D568-59E7-44E9-9FDD-59EDEA47900F}';
RID_COMISIONESDelta = '{DCCDF3B3-6238-4524-80E8-5533335061DD}'; RID_COMISIONESDelta = '{9705E926-9D16-4A15-A5F5-E33C2AB163C2}';
RID_COBROSCOMISIONDelta = '{15955B4C-796B-49D4-8F2B-07BA91EECB3D}'; RID_COBROSCOMISIONDelta = '{9C3DE44E-1C94-4E84-A840-8855CEACFEEB}';
type type
{ IVENDEDORESCOMISIONDelta } { IVENDEDORESCOMISIONDelta }
IVENDEDORESCOMISIONDelta = interface(IVENDEDORESCOMISION) IVENDEDORESCOMISIONDelta = interface(IVENDEDORESCOMISION)
['{47FDF38D-3FF4-4F15-A4B1-212E3669BFAA}'] ['{AF94D568-59E7-44E9-9FDD-59EDEA47900F}']
{ Property getters and setters } { Property getters and setters }
function GetOldVENDEDORValue : String; function GetOldVENDEDORValue : String;
function GetOldPORCENTAJEValue : Float; function GetOldPORCENTAJEValue : Float;
@ -59,7 +59,7 @@ type
{ ICOMISIONESDelta } { ICOMISIONESDelta }
ICOMISIONESDelta = interface(ICOMISIONES) ICOMISIONESDelta = interface(ICOMISIONES)
['{DCCDF3B3-6238-4524-80E8-5533335061DD}'] ['{9705E926-9D16-4A15-A5F5-E33C2AB163C2}']
{ Property getters and setters } { Property getters and setters }
function GetOldCOMISIONValue : Float; function GetOldCOMISIONValue : Float;
@ -88,7 +88,7 @@ type
{ ICOBROSCOMISIONDelta } { ICOBROSCOMISIONDelta }
ICOBROSCOMISIONDelta = interface(ICOBROSCOMISION) ICOBROSCOMISIONDelta = interface(ICOBROSCOMISION)
['{15955B4C-796B-49D4-8F2B-07BA91EECB3D}'] ['{9C3DE44E-1C94-4E84-A840-8855CEACFEEB}']
{ Property getters and setters } { Property getters and setters }
function GetOldSELECCIONValue : Integer; function GetOldSELECCIONValue : Integer;
function GetOldCODIGOEMPRESAValue : Integer; function GetOldCODIGOEMPRESAValue : Integer;
@ -99,6 +99,7 @@ type
function GetOldIMPORTEValue : Float; function GetOldIMPORTEValue : Float;
function GetOldFORMAPAGOValue : String; function GetOldFORMAPAGOValue : String;
function GetOldDESCRIPCIONValue : String; function GetOldDESCRIPCIONValue : String;
function GetOldTIPOValue : String;
function GetOldCODIGOCATEGORIAValue : Integer; function GetOldCODIGOCATEGORIAValue : Integer;
function GetOldCATEGORIAValue : String; function GetOldCATEGORIAValue : String;
@ -112,6 +113,7 @@ type
property OldIMPORTE : Float read GetOldIMPORTEValue; property OldIMPORTE : Float read GetOldIMPORTEValue;
property OldFORMAPAGO : String read GetOldFORMAPAGOValue; property OldFORMAPAGO : String read GetOldFORMAPAGOValue;
property OldDESCRIPCION : String read GetOldDESCRIPCIONValue; property OldDESCRIPCION : String read GetOldDESCRIPCIONValue;
property OldTIPO : String read GetOldTIPOValue;
property OldCODIGOCATEGORIA : Integer read GetOldCODIGOCATEGORIAValue; property OldCODIGOCATEGORIA : Integer read GetOldCODIGOCATEGORIAValue;
property OldCATEGORIA : String read GetOldCATEGORIAValue; property OldCATEGORIA : String read GetOldCATEGORIAValue;
end; end;
@ -148,6 +150,9 @@ type
function GetDESCRIPCIONValue: String; virtual; function GetDESCRIPCIONValue: String; virtual;
function GetOldDESCRIPCIONValue: String; virtual; function GetOldDESCRIPCIONValue: String; virtual;
procedure SetDESCRIPCIONValue(const aValue: String); virtual; procedure SetDESCRIPCIONValue(const aValue: String); virtual;
function GetTIPOValue: String; virtual;
function GetOldTIPOValue: String; virtual;
procedure SetTIPOValue(const aValue: String); virtual;
function GetCODIGOCATEGORIAValue: Integer; virtual; function GetCODIGOCATEGORIAValue: Integer; virtual;
function GetOldCODIGOCATEGORIAValue: Integer; virtual; function GetOldCODIGOCATEGORIAValue: Integer; virtual;
procedure SetCODIGOCATEGORIAValue(const aValue: Integer); virtual; procedure SetCODIGOCATEGORIAValue(const aValue: Integer); virtual;
@ -174,6 +179,8 @@ type
property OldFORMAPAGO : String read GetOldFORMAPAGOValue; property OldFORMAPAGO : String read GetOldFORMAPAGOValue;
property DESCRIPCION : String read GetDESCRIPCIONValue write SetDESCRIPCIONValue; property DESCRIPCION : String read GetDESCRIPCIONValue write SetDESCRIPCIONValue;
property OldDESCRIPCION : String read GetOldDESCRIPCIONValue; property OldDESCRIPCION : String read GetOldDESCRIPCIONValue;
property TIPO : String read GetTIPOValue write SetTIPOValue;
property OldTIPO : String read GetOldTIPOValue;
property CODIGOCATEGORIA : Integer read GetCODIGOCATEGORIAValue write SetCODIGOCATEGORIAValue; property CODIGOCATEGORIA : Integer read GetCODIGOCATEGORIAValue write SetCODIGOCATEGORIAValue;
property OldCODIGOCATEGORIA : Integer read GetOldCODIGOCATEGORIAValue; property OldCODIGOCATEGORIA : Integer read GetOldCODIGOCATEGORIAValue;
property CATEGORIA : String read GetCATEGORIAValue write SetCATEGORIAValue; property CATEGORIA : String read GetCATEGORIAValue write SetCATEGORIAValue;
@ -420,6 +427,21 @@ begin
BusinessProcessor.CurrentChange.NewValueByName[fld_COBROSCOMISIONDESCRIPCION] := aValue; BusinessProcessor.CurrentChange.NewValueByName[fld_COBROSCOMISIONDESCRIPCION] := aValue;
end; end;
function TCOBROSCOMISIONBusinessProcessorRules.GetTIPOValue: String;
begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_COBROSCOMISIONTIPO];
end;
function TCOBROSCOMISIONBusinessProcessorRules.GetOldTIPOValue: String;
begin
result := BusinessProcessor.CurrentChange.OldValueByName[fld_COBROSCOMISIONTIPO];
end;
procedure TCOBROSCOMISIONBusinessProcessorRules.SetTIPOValue(const aValue: String);
begin
BusinessProcessor.CurrentChange.NewValueByName[fld_COBROSCOMISIONTIPO] := aValue;
end;
function TCOBROSCOMISIONBusinessProcessorRules.GetCODIGOCATEGORIAValue: Integer; function TCOBROSCOMISIONBusinessProcessorRules.GetCODIGOCATEGORIAValue: Integer;
begin begin
result := BusinessProcessor.CurrentChange.NewValueByName[fld_COBROSCOMISIONCODIGOCATEGORIA]; result := BusinessProcessor.CurrentChange.NewValueByName[fld_COBROSCOMISIONCODIGOCATEGORIA];

View File

@ -142,12 +142,12 @@ Count=1
Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE; Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
[HistoryLists\hlSearchPath] [HistoryLists\hlSearchPath]
Count=16 Count=16
Item0=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente;..\..\Cuentas\Cliente Item0=..\Modulos\Presupuestos\Reglas;..\Modulos\Contactos\Reglas;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Albaranes de cliente\Reglas
Item1=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente Item1=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Intervalos;..\Modulos\Documentos asociados;..\Modulos\Contactos\Cliente;..\Modulos\Contactos\Reglas;..\Modulos\Presupuestos\Cliente;..\Modulos\Presupuestos\Reglas;..\Modulos\Albaranes de cliente\Cliente;..\Modulos\Albaranes de cliente\Reglas;..\Modulos\Facturas de cliente\Cliente;..\Modulos\Facturas de cliente\Reglas;..\Modulos\Pedidos a proveedor\Cliente;..\Modulos\Pedidos a proveedor\Reglas;..\Modulos\Facturas de proveedor\Cliente;..\Modulos\Facturas de proveedor\Reglas;..\Modulos\Montajes\Reglas;..\Modulos\Montajes\Cliente;..\Modulos\Articulos\Cliente;..\Modulos\Articulos\Reglas;..\Modulos\Almacenes\Reglas;..\Modulos\Almacenes\Cliente;..\Modulos\Pagos\Reglas;..\Modulos\Pagos\Cliente;..\Modulos\Cuentas\Reglas;..\Modulos\Cuentas\Cliente;..\Modulos\Asientos\Reglas;..\Modulos\Asientos\Cliente;..\Modulos\Calendarios\Cliente;..\Modulos\Calendarios\Reglas
Item2=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente Item2=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente;..\..\Cuentas\Cliente
Item3=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente Item3=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente
Item4=..\Modulos\Presupuestos\Reglas;..\Modulos\Contactos\Reglas;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Albaranes de cliente\Reglas Item4=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente
Item5=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Intervalos;..\Modulos\Documentos asociados;..\Modulos\Contactos\Cliente;..\Modulos\Contactos\Reglas;..\Modulos\Presupuestos\Cliente;..\Modulos\Presupuestos\Reglas;..\Modulos\Albaranes de cliente\Cliente;..\Modulos\Albaranes de cliente\Reglas;..\Modulos\Facturas de cliente\Cliente;..\Modulos\Facturas de cliente\Reglas;..\Modulos\Pedidos a proveedor\Cliente;..\Modulos\Pedidos a proveedor\Reglas;..\Modulos\Facturas de proveedor\Cliente;..\Modulos\Facturas de proveedor\Reglas;..\Modulos\Montajes\Reglas;..\Modulos\Montajes\Cliente;..\Modulos\Articulos\Cliente;..\Modulos\Articulos\Reglas;..\Modulos\Almacenes\Reglas;..\Modulos\Almacenes\Cliente;..\Modulos\Pagos\Reglas;..\Modulos\Pagos\Cliente;..\Modulos\Cuentas\Reglas;..\Modulos\Cuentas\Cliente;..\Modulos\Asientos\Reglas;..\Modulos\Asientos\Cliente;..\Modulos\Calendarios\Cliente;..\Modulos\Calendarios\Reglas Item5=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente
Item6=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\..\Usuarios;..\..\Montajes\Cliente;..\..\Documentos asociados;..\..\Contactos\Cliente;..\..\Almacenes\Cliente Item6=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\..\Usuarios;..\..\Montajes\Cliente;..\..\Documentos asociados;..\..\Contactos\Cliente;..\..\Almacenes\Cliente
Item7=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\..\Usuarios;..\..\Documentos asociados Item7=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\..\Usuarios;..\..\Documentos asociados
Item8=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\..\Usuarios;..\..\Montajes\Cliente;..\..\Documentos asociados;..\..\Contactos\Cliente Item8=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\..\Usuarios;..\..\Montajes\Cliente;..\..\Documentos asociados;..\..\Contactos\Cliente

View File

@ -522,7 +522,13 @@ object dmMontajes: TdmMontajes
Lookup = False Lookup = False
LookupCache = False LookupCache = False
end> end>
Params = <> Params = <
item
Name = 'tipo'
BlobType = dabtUnknown
Value = ''
ParamType = daptInput
end>
MasterMappingMode = mmDataRequest MasterMappingMode = mmDataRequest
StreamingOptions = [soDisableEventsWhileStreaming] StreamingOptions = [soDisableEventsWhileStreaming]
SchemaCall.MethodName = 'GetDatasetSchema' SchemaCall.MethodName = 'GetDatasetSchema'

View File

@ -33,7 +33,7 @@ type
procedure PreviewEtiquetas(const Codigo : Integer; const NumEtiquetas : Integer); procedure PreviewEtiquetas(const Codigo : Integer; const NumEtiquetas : Integer);
procedure PrintEtiquetas(const Codigo : Integer; const NumEtiquetas : Integer); procedure PrintEtiquetas(const Codigo : Integer; const NumEtiquetas : Integer);
function PuedoEliminarMontaje(Codigo : Integer) : Boolean; function PuedoEliminarMontaje(Codigo : Integer) : Boolean;
function darFichaBeneficiosAux: IFichaBeneficios_Aux; function darFichaBeneficiosAux(const Tipo: String): IFichaBeneficios_Aux;
procedure NuevoMontaje(AMontaje: IBizMontaje; APresupuesto: IBizPresupuestos); procedure NuevoMontaje(AMontaje: IBizMontaje; APresupuesto: IBizPresupuestos);
function CambiarSituacion(CodigoPresupuesto: Integer; Situacion: TEnumSituacion): String; function CambiarSituacion(CodigoPresupuesto: Integer; Situacion: TEnumSituacion): String;
function DarNuevaReferencia (TipoMontaje : String) : String; function DarNuevaReferencia (TipoMontaje : String) : String;
@ -288,6 +288,10 @@ begin
AMontaje.DataTable.Active := True; AMontaje.DataTable.Active := True;
end; end;
//Siempre antes de la inserción que en el onnew de la clase de negocio se sepa que tipo de montaje será
//y poder generar la ficha de beneficios correspondiente
AMontaje.TipoFichaBeneficios := APresupuesto.TIPO;
AMontaje.Insert; AMontaje.Insert;
AMontaje.Presupuesto := APresupuesto; AMontaje.Presupuesto := APresupuesto;
AMontaje.Post; AMontaje.Post;
@ -297,7 +301,7 @@ begin
// raise Exception.Create('Error al crear ficha de beneficios'); // raise Exception.Create('Error al crear ficha de beneficios');
end; end;
function TdmMontajes.darFichaBeneficiosAux: IFichaBeneficios_Aux; function TdmMontajes.darFichaBeneficiosAux(const Tipo: String): IFichaBeneficios_Aux;
var var
dtFichaBeneficiosAux: TDACDSDataTable; dtFichaBeneficiosAux: TDACDSDataTable;
ACursor: TCursor; ACursor: TCursor;
@ -308,6 +312,7 @@ begin
dtFichaBeneficiosAux := TDACDSDataTable.Create(NIL); dtFichaBeneficiosAux := TDACDSDataTable.Create(NIL);
CloneDataTable(tbl_FichaBeneficios_Aux, dtFichaBeneficiosAux); CloneDataTable(tbl_FichaBeneficios_Aux, dtFichaBeneficiosAux);
dtFichaBeneficiosAux.BusinessRulesID := 'BizFichaBeneficiosAux'; dtFichaBeneficiosAux.BusinessRulesID := 'BizFichaBeneficiosAux';
dtFichaBeneficiosAux.ParamByName('TIPO').AsString := Tipo;
Result := (dtFichaBeneficiosAux as IFichaBeneficios_Aux); Result := (dtFichaBeneficiosAux as IFichaBeneficios_Aux);
finally finally
Screen.Cursor := ACursor; Screen.Cursor := ACursor;

View File

@ -1,10 +1,7 @@
inherited frViewFichaBeneficiosMontaje: TfrViewFichaBeneficiosMontaje inherited frViewFichaBeneficiosMontaje: TfrViewFichaBeneficiosMontaje
Width = 582
Height = 437
inherited cxGrid: TcxGrid inherited cxGrid: TcxGrid
Top = 25 Top = 127
Width = 582 Height = 143
Height = 412
inherited cxGridView: TcxGridDBTableView inherited cxGridView: TcxGridDBTableView
DataController.DataModeController.SmartRefresh = False DataController.DataModeController.SmartRefresh = False
DataController.DataModeController.SyncMode = True DataController.DataModeController.SyncMode = True
@ -89,7 +86,7 @@ inherited frViewFichaBeneficiosMontaje: TfrViewFichaBeneficiosMontaje
object ToolBar1: TToolBar [1] object ToolBar1: TToolBar [1]
Left = 0 Left = 0
Top = 0 Top = 0
Width = 582 Width = 443
Height = 25 Height = 25
ButtonWidth = 63 ButtonWidth = 63
Caption = 'ToolBar1' Caption = 'ToolBar1'
@ -100,7 +97,7 @@ inherited frViewFichaBeneficiosMontaje: TfrViewFichaBeneficiosMontaje
Images = PngImageList Images = PngImageList
List = True List = True
ShowCaptions = True ShowCaptions = True
TabOrder = 1 TabOrder = 2
object ToolButton1: TToolButton object ToolButton1: TToolButton
Left = 0 Left = 0
Top = 0 Top = 0
@ -120,6 +117,24 @@ inherited frViewFichaBeneficiosMontaje: TfrViewFichaBeneficiosMontaje
Style = tbsSeparator Style = tbsSeparator
end end
end end
inherited frViewFiltroBase1: TfrViewFiltroBase
Top = 25
inherited TBXDock1: TTBXDock
inherited TBXDockablePanel1: TTBXDockablePanel
inherited dxLayoutControl1: TdxLayoutControl
inherited txtFiltroTodo: TcxTextEdit
Width = 273
end
inherited edtFechaIniFiltro: TcxDateEdit
Width = 121
end
inherited edtFechaFinFiltro: TcxDateEdit
Width = 121
end
end
end
end
end
inherited ActionList1: TActionList inherited ActionList1: TActionList
Images = PngImageList Images = PngImageList
Left = 8 Left = 8

View File

@ -12,7 +12,7 @@ uses
JvFormAutoSize, PngImageList, ImgList, dxPSGlbl, dxPSUtl, dxPSEngn, JvFormAutoSize, PngImageList, ImgList, dxPSGlbl, dxPSUtl, dxPSEngn,
dxPrnPg, dxBkgnd, dxWrap, dxPrnDev, dxPSCompsProvider, dxPSFillPatterns, dxPrnPg, dxBkgnd, dxWrap, dxPrnDev, dxPSCompsProvider, dxPSFillPatterns,
dxPSEdgePatterns, cxIntlPrintSys3, dxPSCore, dxPScxCommon, dxPScxGridLnk, dxPSEdgePatterns, cxIntlPrintSys3, dxPSCore, dxPScxCommon, dxPScxGridLnk,
ComCtrls, ToolWin, cxCurrencyEdit, Grids, DBGrids; ComCtrls, ToolWin, cxCurrencyEdit, Grids, DBGrids, uViewFiltroBase;
type type
IViewFichaBeneficiosMontaje = interface(IViewGrid) IViewFichaBeneficiosMontaje = interface(IViewGrid)

View File

@ -9,14 +9,14 @@ 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_ListaAnosMontajes = '{8A77AA23-1850-4C51-9890-61883469A21D}'; RID_ListaAnosMontajes = '{10881790-553A-425B-9F2E-0CC35DFE857E}';
RID_darNuevaReferencia = '{98BF35DF-261B-4AF5-B3EC-024D293CB3BF}'; RID_darNuevaReferencia = '{60945159-4D44-4B8E-BC3E-1C95824A8AC2}';
RID_InformeCabeceraFicha = '{9FCA86CA-5B72-45D8-8B2E-623344608585}'; RID_InformeCabeceraFicha = '{E3EB8788-472C-486F-BCFC-E98118F19998}';
RID_Montajes = '{EA56C374-7E7B-4FC5-8C42-1D65BA1BD7EF}'; RID_Montajes = '{A14C4188-93BF-4D1D-BE0A-9654CC28F4FD}';
RID_Refresh_Montajes = '{A948AC0C-F4EF-465D-B2DD-FA4301D3B029}'; RID_Refresh_Montajes = '{82271F6F-81CF-4FF7-B441-119ECDA6237D}';
RID_FichaBeneficios = '{8572BE0C-91B5-4D2C-B729-BB13BAEBC13D}'; RID_FichaBeneficios = '{B6BF0EDB-B4F1-4168-8DC7-1292216AA53C}';
RID_InformeDetallesFicha = '{D3E3E171-62A4-465E-A954-3EDF6EB38F6F}'; RID_InformeDetallesFicha = '{807EBD75-BB62-492F-A95D-D8FBE5A02B7E}';
RID_FichaBeneficios_Aux = '{5D3EC453-7D49-4AB0-98C0-7F0807279919}'; RID_FichaBeneficios_Aux = '{EB05CA72-57ED-46B0-AEAD-E782D88B0E28}';
{ Data table names } { Data table names }
nme_ListaAnosMontajes = 'ListaAnosMontajes'; nme_ListaAnosMontajes = 'ListaAnosMontajes';
@ -177,7 +177,7 @@ const
type type
{ IListaAnosMontajes } { IListaAnosMontajes }
IListaAnosMontajes = interface(IDAStronglyTypedDataTable) IListaAnosMontajes = interface(IDAStronglyTypedDataTable)
['{6FCA63AA-AE36-4EF9-BFCB-91693E467AE1}'] ['{C41C6AA9-6F44-4CBF-9DA5-0BD9378E0EB1}']
{ Property getters and setters } { Property getters and setters }
function GetANOValue: String; function GetANOValue: String;
procedure SetANOValue(const aValue: String); procedure SetANOValue(const aValue: String);
@ -206,7 +206,7 @@ type
{ IdarNuevaReferencia } { IdarNuevaReferencia }
IdarNuevaReferencia = interface(IDAStronglyTypedDataTable) IdarNuevaReferencia = interface(IDAStronglyTypedDataTable)
['{A6774E16-4A24-4A3D-A8D6-93ADD76C90AF}'] ['{0EBF89CD-1B5F-4D69-BC2A-FF9944E763CA}']
{ Property getters and setters } { Property getters and setters }
function GetREFERENCIAValue: String; function GetREFERENCIAValue: String;
procedure SetREFERENCIAValue(const aValue: String); procedure SetREFERENCIAValue(const aValue: String);
@ -235,7 +235,7 @@ type
{ IInformeCabeceraFicha } { IInformeCabeceraFicha }
IInformeCabeceraFicha = interface(IDAStronglyTypedDataTable) IInformeCabeceraFicha = interface(IDAStronglyTypedDataTable)
['{232A3364-2478-4717-BD42-3DBAE60B11CC}'] ['{D4FB53A7-C48C-4E41-A377-566F6B62C634}']
{ Property getters and setters } { Property getters and setters }
function GetREFERENCIAValue: String; function GetREFERENCIAValue: String;
procedure SetREFERENCIAValue(const aValue: String); procedure SetREFERENCIAValue(const aValue: String);
@ -348,7 +348,7 @@ type
{ IMontajes } { IMontajes }
IMontajes = interface(IDAStronglyTypedDataTable) IMontajes = interface(IDAStronglyTypedDataTable)
['{E50B9717-4671-4DC6-896B-F2C3EC14C399}'] ['{46E79BA3-95C8-4752-8D16-6C04CD5B50F3}']
{ Property getters and setters } { Property getters and setters }
function GetCODIGOEMPRESAValue: Integer; function GetCODIGOEMPRESAValue: Integer;
procedure SetCODIGOEMPRESAValue(const aValue: Integer); procedure SetCODIGOEMPRESAValue(const aValue: Integer);
@ -449,7 +449,7 @@ type
{ IRefresh_Montajes } { IRefresh_Montajes }
IRefresh_Montajes = interface(IDAStronglyTypedDataTable) IRefresh_Montajes = interface(IDAStronglyTypedDataTable)
['{B31A8001-6DF2-4389-9347-423642175B74}'] ['{C2E98C33-4903-4F19-B7A3-1E9AD4B2C68D}']
{ Property getters and setters } { Property getters and setters }
function GetCODIGOEMPRESAValue: Integer; function GetCODIGOEMPRESAValue: Integer;
procedure SetCODIGOEMPRESAValue(const aValue: Integer); procedure SetCODIGOEMPRESAValue(const aValue: Integer);
@ -550,7 +550,7 @@ type
{ IFichaBeneficios } { IFichaBeneficios }
IFichaBeneficios = interface(IDAStronglyTypedDataTable) IFichaBeneficios = interface(IDAStronglyTypedDataTable)
['{CBD6AD21-2417-45BD-B514-D9D3ACA64E4F}'] ['{F149E069-825A-4961-8C4E-68BE037A4715}']
{ Property getters and setters } { Property getters and setters }
function GetCODIGOMONTAJEValue: Integer; function GetCODIGOMONTAJEValue: Integer;
procedure SetCODIGOMONTAJEValue(const aValue: Integer); procedure SetCODIGOMONTAJEValue(const aValue: Integer);
@ -615,7 +615,7 @@ type
{ IInformeDetallesFicha } { IInformeDetallesFicha }
IInformeDetallesFicha = interface(IDAStronglyTypedDataTable) IInformeDetallesFicha = interface(IDAStronglyTypedDataTable)
['{CDD0B24E-43DC-4BE9-9451-49126D130C35}'] ['{CF37FBE7-A946-4E20-8A4F-2753773DD9D4}']
{ Property getters and setters } { Property getters and setters }
function GetDESCRIPCIONValue: String; function GetDESCRIPCIONValue: String;
procedure SetDESCRIPCIONValue(const aValue: String); procedure SetDESCRIPCIONValue(const aValue: String);
@ -668,7 +668,7 @@ type
{ IFichaBeneficios_Aux } { IFichaBeneficios_Aux }
IFichaBeneficios_Aux = interface(IDAStronglyTypedDataTable) IFichaBeneficios_Aux = interface(IDAStronglyTypedDataTable)
['{AE5C37AD-B172-4181-8726-C94153D32E9B}'] ['{15BA870E-19D0-43B0-9878-9031439519B1}']
{ Property getters and setters } { Property getters and setters }
function GetNUMCONCEPTOValue: Integer; function GetNUMCONCEPTOValue: Integer;
procedure SetNUMCONCEPTOValue(const aValue: Integer); procedure SetNUMCONCEPTOValue(const aValue: Integer);

View File

@ -9,19 +9,19 @@ 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_ListaAnosMontajesDelta = '{A1079675-6804-43A1-8113-4C69034E612B}'; RID_ListaAnosMontajesDelta = '{54D6F856-69C9-46C4-9708-EB06E21F64C9}';
RID_darNuevaReferenciaDelta = '{B926E1E9-D5FE-4AD9-81B6-6DB568BAF1AC}'; RID_darNuevaReferenciaDelta = '{DB02E16C-17A8-44E1-8A09-5B7E5A5D5C70}';
RID_InformeCabeceraFichaDelta = '{295D1406-43D2-4AB6-90C5-3C77F026EEF1}'; RID_InformeCabeceraFichaDelta = '{07C12000-AFBD-4F89-9F4B-1CF8AE219608}';
RID_MontajesDelta = '{2E686B2F-A149-44D8-B8A0-978EF00888B3}'; RID_MontajesDelta = '{5DAAEE09-4F1D-481F-9E6A-6362687F33E2}';
RID_Refresh_MontajesDelta = '{A0465C98-DB95-4236-B3CE-5D2580AED7A0}'; RID_Refresh_MontajesDelta = '{6AE4BF82-8A34-4805-A201-83D27D7FA6C5}';
RID_FichaBeneficiosDelta = '{E75F17B7-C959-49D7-84B3-55AA239759FC}'; RID_FichaBeneficiosDelta = '{B0843E14-B2C0-4CB1-BF0D-8848AB746CF6}';
RID_InformeDetallesFichaDelta = '{E97CAB1B-CCB0-4710-95F3-9AD8D1C9305F}'; RID_InformeDetallesFichaDelta = '{DBF71433-4943-46FE-A536-15E29D1E77D8}';
RID_FichaBeneficios_AuxDelta = '{BB83B8A0-16FB-43C4-8776-0A2DDCE8A85B}'; RID_FichaBeneficios_AuxDelta = '{C55A8142-1206-48A0-9CB1-FE4EF597289F}';
type type
{ IListaAnosMontajesDelta } { IListaAnosMontajesDelta }
IListaAnosMontajesDelta = interface(IListaAnosMontajes) IListaAnosMontajesDelta = interface(IListaAnosMontajes)
['{A1079675-6804-43A1-8113-4C69034E612B}'] ['{54D6F856-69C9-46C4-9708-EB06E21F64C9}']
{ Property getters and setters } { Property getters and setters }
function GetOldANOValue : String; function GetOldANOValue : String;
@ -50,7 +50,7 @@ type
{ IdarNuevaReferenciaDelta } { IdarNuevaReferenciaDelta }
IdarNuevaReferenciaDelta = interface(IdarNuevaReferencia) IdarNuevaReferenciaDelta = interface(IdarNuevaReferencia)
['{B926E1E9-D5FE-4AD9-81B6-6DB568BAF1AC}'] ['{DB02E16C-17A8-44E1-8A09-5B7E5A5D5C70}']
{ Property getters and setters } { Property getters and setters }
function GetOldREFERENCIAValue : String; function GetOldREFERENCIAValue : String;
@ -79,7 +79,7 @@ type
{ IInformeCabeceraFichaDelta } { IInformeCabeceraFichaDelta }
IInformeCabeceraFichaDelta = interface(IInformeCabeceraFicha) IInformeCabeceraFichaDelta = interface(IInformeCabeceraFicha)
['{295D1406-43D2-4AB6-90C5-3C77F026EEF1}'] ['{07C12000-AFBD-4F89-9F4B-1CF8AE219608}']
{ Property getters and setters } { Property getters and setters }
function GetOldREFERENCIAValue : String; function GetOldREFERENCIAValue : String;
function GetOldFECHAINICIOValue : DateTime; function GetOldFECHAINICIOValue : DateTime;
@ -206,7 +206,7 @@ type
{ IMontajesDelta } { IMontajesDelta }
IMontajesDelta = interface(IMontajes) IMontajesDelta = interface(IMontajes)
['{2E686B2F-A149-44D8-B8A0-978EF00888B3}'] ['{5DAAEE09-4F1D-481F-9E6A-6362687F33E2}']
{ Property getters and setters } { Property getters and setters }
function GetOldCODIGOEMPRESAValue : Integer; function GetOldCODIGOEMPRESAValue : Integer;
function GetOldCODIGOValue : Integer; function GetOldCODIGOValue : Integer;
@ -319,7 +319,7 @@ type
{ IRefresh_MontajesDelta } { IRefresh_MontajesDelta }
IRefresh_MontajesDelta = interface(IRefresh_Montajes) IRefresh_MontajesDelta = interface(IRefresh_Montajes)
['{A0465C98-DB95-4236-B3CE-5D2580AED7A0}'] ['{6AE4BF82-8A34-4805-A201-83D27D7FA6C5}']
{ Property getters and setters } { Property getters and setters }
function GetOldCODIGOEMPRESAValue : Integer; function GetOldCODIGOEMPRESAValue : Integer;
function GetOldCODIGOValue : Integer; function GetOldCODIGOValue : Integer;
@ -432,7 +432,7 @@ type
{ IFichaBeneficiosDelta } { IFichaBeneficiosDelta }
IFichaBeneficiosDelta = interface(IFichaBeneficios) IFichaBeneficiosDelta = interface(IFichaBeneficios)
['{E75F17B7-C959-49D7-84B3-55AA239759FC}'] ['{B0843E14-B2C0-4CB1-BF0D-8848AB746CF6}']
{ Property getters and setters } { Property getters and setters }
function GetOldCODIGOMONTAJEValue : Integer; function GetOldCODIGOMONTAJEValue : Integer;
function GetOldNUMCONCEPTOValue : Integer; function GetOldNUMCONCEPTOValue : Integer;
@ -503,7 +503,7 @@ type
{ IInformeDetallesFichaDelta } { IInformeDetallesFichaDelta }
IInformeDetallesFichaDelta = interface(IInformeDetallesFicha) IInformeDetallesFichaDelta = interface(IInformeDetallesFicha)
['{E97CAB1B-CCB0-4710-95F3-9AD8D1C9305F}'] ['{DBF71433-4943-46FE-A536-15E29D1E77D8}']
{ Property getters and setters } { Property getters and setters }
function GetOldDESCRIPCIONValue : String; function GetOldDESCRIPCIONValue : String;
function GetOldMODELOValue : String; function GetOldMODELOValue : String;
@ -560,7 +560,7 @@ type
{ IFichaBeneficios_AuxDelta } { IFichaBeneficios_AuxDelta }
IFichaBeneficios_AuxDelta = interface(IFichaBeneficios_Aux) IFichaBeneficios_AuxDelta = interface(IFichaBeneficios_Aux)
['{BB83B8A0-16FB-43C4-8776-0A2DDCE8A85B}'] ['{C55A8142-1206-48A0-9CB1-FE4EF597289F}']
{ Property getters and setters } { Property getters and setters }
function GetOldNUMCONCEPTOValue : Integer; function GetOldNUMCONCEPTOValue : Integer;
function GetOldDESCRIPCIONValue : String; function GetOldDESCRIPCIONValue : String;

View File

@ -23,7 +23,7 @@ Type
IBizFichaBeneficiosMontaje = interface(IFichaBeneficios) IBizFichaBeneficiosMontaje = interface(IFichaBeneficios)
['{1A7191CB-6F5C-4E1C-9024-E71C5718EF8B}'] ['{1A7191CB-6F5C-4E1C-9024-E71C5718EF8B}']
procedure AnadirFichaBeneficiosDefecto(const pCodigoMontaje: integer); procedure AnadirFichaBeneficiosDefecto(const pCodigoMontaje: integer; const Tipo: String);
end; end;
IBizMontaje = interface(IMONTAJES) IBizMontaje = interface(IMONTAJES)
@ -47,6 +47,10 @@ Type
procedure SetFichaBeneficios(Value: IBizFichaBeneficiosMontaje); procedure SetFichaBeneficios(Value: IBizFichaBeneficiosMontaje);
property FichaBeneficios: IBizFichaBeneficiosMontaje read GetFichaBeneficios write SetFichaBeneficios; property FichaBeneficios: IBizFichaBeneficiosMontaje read GetFichaBeneficios write SetFichaBeneficios;
function GetTipoFichaBeneficios: String;
procedure SetTipoFichaBeneficios(Value: String);
property TipoFichaBeneficios: String read GetTipoFichaBeneficios write SetTipoFichaBeneficios;
procedure PreviewLabels; procedure PreviewLabels;
procedure PrintLabels; procedure PrintLabels;
function GetLabelCount: Integer; function GetLabelCount: Integer;
@ -61,6 +65,7 @@ Type
FPresupuesto : IBizPresupuestos; FPresupuesto : IBizPresupuestos;
FFichaBeneficios : IBizFichaBeneficiosMontaje; FFichaBeneficios : IBizFichaBeneficiosMontaje;
FFichaBeneficiosLink: TDADataSource; FFichaBeneficiosLink: TDADataSource;
FTipoFichaBeneficios : String;
FSelectedRows : TSelectedRowList; FSelectedRows : TSelectedRowList;
FLabelCount : Integer; FLabelCount : Integer;
procedure ShowToSelect; procedure ShowToSelect;
@ -79,6 +84,8 @@ Type
procedure SetPresupuesto(Value: IBizPresupuestos); procedure SetPresupuesto(Value: IBizPresupuestos);
function GetFichaBeneficios: IBizFichaBeneficiosMontaje; function GetFichaBeneficios: IBizFichaBeneficiosMontaje;
procedure SetFichaBeneficios(Value: IBizFichaBeneficiosMontaje); procedure SetFichaBeneficios(Value: IBizFichaBeneficiosMontaje);
function GetTipoFichaBeneficios: String;
procedure SetTipoFichaBeneficios(Value: String);
procedure OnNewRecord(Sender: TDADataTable); override; procedure OnNewRecord(Sender: TDADataTable); override;
function GetSelectedRows : TSelectedRowList; virtual; function GetSelectedRows : TSelectedRowList; virtual;
procedure ShowApplyUpdateFailed (const Error: EDAApplyUpdateFailed); virtual; procedure ShowApplyUpdateFailed (const Error: EDAApplyUpdateFailed); virtual;
@ -95,6 +102,7 @@ Type
property Cliente: IBizCliente read GetCliente write SetCliente; property Cliente: IBizCliente read GetCliente write SetCliente;
property Presupuesto: IBizPresupuestos read GetPresupuesto write SetPresupuesto; property Presupuesto: IBizPresupuestos read GetPresupuesto write SetPresupuesto;
property FichaBeneficios: IBizFichaBeneficiosMontaje read GetFichaBeneficios write SetFichaBeneficios; property FichaBeneficios: IBizFichaBeneficiosMontaje read GetFichaBeneficios write SetFichaBeneficios;
property TipoFichaBeneficios: String read GetTipoFichaBeneficios write SetTipoFichaBeneficios;
procedure PreviewLabels; procedure PreviewLabels;
procedure PrintLabels; procedure PrintLabels;
property LabelCount: Integer read GetLabelCount write SetLabelCount; property LabelCount: Integer read GetLabelCount write SetLabelCount;
@ -109,7 +117,7 @@ Type
procedure OnNewRecord(Sender: TDADataTable); override; procedure OnNewRecord(Sender: TDADataTable); override;
procedure ShowApplyUpdateFailed (const Error: EDAApplyUpdateFailed); virtual; procedure ShowApplyUpdateFailed (const Error: EDAApplyUpdateFailed); virtual;
public public
procedure AnadirFichaBeneficiosDefecto(const pCodigoMontaje: integer); procedure AnadirFichaBeneficiosDefecto(const pCodigoMontaje: integer; const Tipo: String);
end; end;
procedure ValidarMontaje (const AMontaje : IBizMontaje); procedure ValidarMontaje (const AMontaje : IBizMontaje);
@ -145,7 +153,7 @@ begin
SITUACION := SITUACION_PENDIENTERECEPCION; SITUACION := SITUACION_PENDIENTERECEPCION;
//Añadimos la ficha de beneficios por defecto //Añadimos la ficha de beneficios por defecto
FichaBeneficios.AnadirFichaBeneficiosDefecto(CODIGO); FichaBeneficios.AnadirFichaBeneficiosDefecto(CODIGO, FTipoFichaBeneficios);
end; end;
procedure TBizMontajeDataTableRules.Show; procedure TBizMontajeDataTableRules.Show;
@ -187,6 +195,7 @@ begin
FCliente := Nil; FCliente := Nil;
FPresupuesto := Nil; FPresupuesto := Nil;
FFichaBeneficiosLink := TDADataSource.Create(NIL); FFichaBeneficiosLink := TDADataSource.Create(NIL);
FTipoFichaBeneficios := 'Cocina'; //Por defecto el tipo de ficha es de cocina
FSelectedRows := TSelectedRowList.Create(aDataTable); FSelectedRows := TSelectedRowList.Create(aDataTable);
aDataTable.OnBeforeApplyUpdates := BeforeApplyUpdates; aDataTable.OnBeforeApplyUpdates := BeforeApplyUpdates;
aDataTable.OnAfterApplyUpdates := AfterApplyUpdates; aDataTable.OnAfterApplyUpdates := AfterApplyUpdates;
@ -346,11 +355,11 @@ end;
{ TBizFichaBeneficiosMontajeDataTableRules } { TBizFichaBeneficiosMontajeDataTableRules }
procedure TBizFichaBeneficiosMontajeDataTableRules.AnadirFichaBeneficiosDefecto(const pCodigoMontaje: integer); procedure TBizFichaBeneficiosMontajeDataTableRules.AnadirFichaBeneficiosDefecto(const pCodigoMontaje: integer; const Tipo: String);
var var
FichaBeneficiosAux: IFichaBeneficios_Aux; FichaBeneficiosAux: IFichaBeneficios_Aux;
begin begin
FichaBeneficiosAux := dmMontajes.darFichaBeneficiosAux; FichaBeneficiosAux := dmMontajes.darFichaBeneficiosAux(Tipo);
try try
with FichaBeneficiosAux.DataTable do with FichaBeneficiosAux.DataTable do
begin begin
@ -424,6 +433,16 @@ begin
FFichaBeneficios.DataTable.MasterSource := FFichaBeneficiosLink; FFichaBeneficios.DataTable.MasterSource := FFichaBeneficiosLink;
end; end;
function TBizMontajeDataTableRules.GetTipoFichaBeneficios: String;
begin
Result := FTipoFichaBeneficios;
end;
procedure TBizMontajeDataTableRules.SetTipoFichaBeneficios(Value: String);
begin
FTipoFichaBeneficios := Value;
end;
initialization initialization
RegisterDataTableRules('BizMontaje', TBizMontajeDataTableRules); RegisterDataTableRules('BizMontaje', TBizMontajeDataTableRules);
RegisterDataTableRules('BizFichaBeneficiosMontaje', TBizFichaBeneficiosMontajeDataTableRules); RegisterDataTableRules('BizFichaBeneficiosMontaje', TBizFichaBeneficiosMontajeDataTableRules);

View File

@ -1020,14 +1020,20 @@ object srvMontajes: TsrvMontajes
BusinessRulesServer.ScriptLanguage = rslPascalScript BusinessRulesServer.ScriptLanguage = rslPascalScript
end end
item item
Params = <> Params = <
item
Name = 'tipo'
BlobType = dabtUnknown
Value = ''
ParamType = daptInput
end>
Statements = < Statements = <
item item
Connection = 'IBX' Connection = 'IBX'
TargetTable = 'FICHABENEFICIOS' TargetTable = 'FICHABENEFICIOS'
SQL = SQL =
'SELECT '#10' NUMCONCEPTO, DESCRIPCION'#10'FROM FICHABENEFICIOS_AUX'#10'OR' + 'SELECT '#10' NUMCONCEPTO, DESCRIPCION'#10'FROM FICHABENEFICIOS_AUX'#10'wh' +
'DER BY NUMCONCEPTO' 'ere tipo = :tipo'#10'ORDER BY NUMCONCEPTO'
StatementType = stSQL StatementType = stSQL
ColumnMappings = < ColumnMappings = <
item item

View File

@ -114,7 +114,7 @@ IncludeVerInfo=1
AutoIncBuild=0 AutoIncBuild=0
MajorVer=1 MajorVer=1
MinorVer=5 MinorVer=5
Release=1 Release=2
Build=0 Build=0
Debug=0 Debug=0
PreRelease=0 PreRelease=0
@ -126,13 +126,13 @@ CodePage=1252
[Version Info Keys] [Version Info Keys]
CompanyName=Rodax Software S.L. CompanyName=Rodax Software S.L.
FileDescription= FileDescription=
FileVersion=1.5.1.0 FileVersion=1.5.2.0
InternalName= InternalName=
LegalCopyright= LegalCopyright=
LegalTrademarks= LegalTrademarks=
OriginalFilename= OriginalFilename=
ProductName=FactuGES Server ProductName=FactuGES Server
ProductVersion=1.5.1.0 ProductVersion=1.5.2.0
Comments= Comments=
[Excluded Packages] [Excluded Packages]
C:\Archivos de programa\Borland\Delphi7\Projects\Bpl\cxLibraryVCLD7.bpl=Express Cross Platform Library (VCL Edition) by Developer Express Inc. C:\Archivos de programa\Borland\Delphi7\Projects\Bpl\cxLibraryVCLD7.bpl=Express Cross Platform Library (VCL Edition) by Developer Express Inc.
@ -183,8 +183,8 @@ Count=1
Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE; Item0=WinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE;
[HistoryLists\hlSearchPath] [HistoryLists\hlSearchPath]
Count=16 Count=16
Item0=..\Modulos\Presupuestos\Reglas;..\Modulos\Contactos\Reglas;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Albaranes de cliente\Reglas Item0=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Intervalos;..\Modulos\Documentos asociados;..\Modulos\Contactos\Cliente;..\Modulos\Contactos\Reglas;..\Modulos\Presupuestos\Cliente;..\Modulos\Presupuestos\Reglas;..\Modulos\Albaranes de cliente\Cliente;..\Modulos\Albaranes de cliente\Reglas;..\Modulos\Facturas de cliente\Cliente;..\Modulos\Facturas de cliente\Reglas;..\Modulos\Pedidos a proveedor\Cliente;..\Modulos\Pedidos a proveedor\Reglas;..\Modulos\Facturas de proveedor\Cliente;..\Modulos\Facturas de proveedor\Reglas;..\Modulos\Montajes\Reglas;..\Modulos\Montajes\Cliente;..\Modulos\Articulos\Cliente;..\Modulos\Articulos\Reglas;..\Modulos\Almacenes\Reglas;..\Modulos\Almacenes\Cliente;..\Modulos\Pagos\Reglas;..\Modulos\Pagos\Cliente;..\Modulos\Cuentas\Reglas;..\Modulos\Cuentas\Cliente;..\Modulos\Asientos\Reglas;..\Modulos\Asientos\Cliente;..\Modulos\Calendarios\Cliente;..\Modulos\Calendarios\Reglas
Item1=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Intervalos;..\Modulos\Documentos asociados;..\Modulos\Contactos\Cliente;..\Modulos\Contactos\Reglas;..\Modulos\Presupuestos\Cliente;..\Modulos\Presupuestos\Reglas;..\Modulos\Albaranes de cliente\Cliente;..\Modulos\Albaranes de cliente\Reglas;..\Modulos\Facturas de cliente\Cliente;..\Modulos\Facturas de cliente\Reglas;..\Modulos\Pedidos a proveedor\Cliente;..\Modulos\Pedidos a proveedor\Reglas;..\Modulos\Facturas de proveedor\Cliente;..\Modulos\Facturas de proveedor\Reglas;..\Modulos\Montajes\Reglas;..\Modulos\Montajes\Cliente;..\Modulos\Articulos\Cliente;..\Modulos\Articulos\Reglas;..\Modulos\Almacenes\Reglas;..\Modulos\Almacenes\Cliente;..\Modulos\Pagos\Reglas;..\Modulos\Pagos\Cliente;..\Modulos\Cuentas\Reglas;..\Modulos\Cuentas\Cliente;..\Modulos\Asientos\Reglas;..\Modulos\Asientos\Cliente;..\Modulos\Calendarios\Cliente;..\Modulos\Calendarios\Reglas Item1=..\Modulos\Presupuestos\Reglas;..\Modulos\Contactos\Reglas;..\Base;..\Configuracion;..\Usuarios;..\Modulos\Albaranes de cliente\Reglas
Item2=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente;..\..\Cuentas\Cliente Item2=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente;..\..\Cuentas\Cliente
Item3=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente Item3=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente;..\..\Asientos\Cliente
Item4=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente Item4=$(DELPHI)\Lib\Debug;D:\PROYEC~1\COMPON~1\jcl\lib\D7\debug;..\..\..\Base;..\..\..\Servidor;..\..\Contactos\Cliente;..\..\Presupuestos\Cliente;..\..\..\Usuarios;..\..\Albaranes de cliente\Cliente;..\..\Documentos asociados;..\..\Pagos\Cliente;..\..\Intervalos\Cliente
@ -204,8 +204,8 @@ Count=1
Item0=.\ Item0=.\
[HistoryLists\hlOutputDirectorry] [HistoryLists\hlOutputDirectorry]
Count=2 Count=2
Item0=..\Output\Servidor Item0=..\Output\Cliente
Item1=..\Output\Cliente Item1=..\Output\Servidor
[HistoryLists\hlBPLOutput] [HistoryLists\hlBPLOutput]
Count=3 Count=3
Item0=..\..\..\Output\Cliente Item0=..\..\..\Output\Cliente

Binary file not shown.

View File

@ -146,14 +146,16 @@ object srvComisiones: TsrvComisiones
SQL = SQL =
'SELECT'#10' 1 as SELECCION, PAGOS.CODIGOEMPRESA, PAGOS.CODIGO, PA' + 'SELECT'#10' 1 as SELECCION, PAGOS.CODIGOEMPRESA, PAGOS.CODIGO, PA' +
'GOS.CODIGOCONTACTO,'#10' CONTACTOS.NOMBRE, PAGOS.FECHAPAGO, PAGOS' + 'GOS.CODIGOCONTACTO,'#10' CONTACTOS.NOMBRE, PAGOS.FECHAPAGO, PAGOS' +
'.IMPORTE, PAGOS.FORMAPAGO, PAGOS.DESCRIPCION,'#10' CONTACTOSCATEG' + '.IMPORTE, PAGOS.FORMAPAGO,'#10' PAGOS.DESCRIPCION, V_TIPOS_PAGO.T' +
'ORIAS.CODIGOCATEGORIA, CATEGORIAS.DESCRIPCION as CATEGORIA'#10#10'FROM' + 'IPO,'#10' CONTACTOSCATEGORIAS.CODIGOCATEGORIA, CATEGORIAS.DESCRIP' +
' PAGOS'#10'LEFT JOIN CONTACTOS ON (PAGOS.CODIGOCONTACTO = CONTACTOS.' + 'CION as CATEGORIA'#10#10'FROM PAGOS'#10'LEFT JOIN CONTACTOS ON (PAGOS.CODI' +
'CODIGO)'#10'LEFT JOIN CONTACTOSCATEGORIAS ON (CONTACTOS.CODIGO = CON' + 'GOCONTACTO = CONTACTOS.CODIGO)'#10'LEFT JOIN CONTACTOSCATEGORIAS ON ' +
'TACTOSCATEGORIAS.CODIGOCONTACTO)'#10'LEFT JOIN CATEGORIAS ON (CONTAC' + '(CONTACTOS.CODIGO = CONTACTOSCATEGORIAS.CODIGOCONTACTO)'#10'LEFT JOI' +
'TOSCATEGORIAS.CODIGOCATEGORIA = CATEGORIAS.CODIGO)'#10#10'WHERE CONTAC' + 'N CATEGORIAS ON (CONTACTOSCATEGORIAS.CODIGOCATEGORIA = CATEGORIA' +
'TOSCATEGORIAS.CODIGOCATEGORIA = 1'#10'AND PAGOS.FECHAPAGO between :F' + 'S.CODIGO)'#10'LEFT JOIN V_TIPOS_PAGO ON (V_TIPOS_PAGO.CODIGO = PAGOS' +
'ECHAINI and :FECHAFIN'#10'ORDER BY PAGOS.FECHAPAGO DESC' '.CODIGO)'#10#10'WHERE CONTACTOSCATEGORIAS.CODIGOCATEGORIA = 1'#10'AND PAGO' +
'S.FECHAPAGO between :FECHAINI and :FECHAFIN'#10'ORDER BY PAGOS.FECHA' +
'PAGO DESC'
StatementType = stSQL StatementType = stSQL
ColumnMappings = < ColumnMappings = <
item item
@ -308,6 +310,18 @@ object srvComisiones: TsrvComisiones
Lookup = False Lookup = False
LookupCache = False LookupCache = False
end end
item
Name = 'TIPO'
DataType = datString
Size = 6
BlobType = dabtUnknown
DisplayWidth = 0
Alignment = taLeftJustify
InPrimaryKey = False
Calculated = False
Lookup = False
LookupCache = False
end
item item
Name = 'CODIGOCATEGORIA' Name = 'CODIGOCATEGORIA'
DataType = datInteger DataType = datInteger