unit schComisionesClient_Intf; {$D-} interface uses Classes, DB, schBase_Intf, SysUtils, uROClasses, uDAInterfaces, uDADataTable, FmtBCD, uROXMLIntf; const { Data table rules ids Feel free to change them to something more human readable but make sure they are unique in the context of your application } RID_ListaAnosComisiones = '{78483533-9B74-4043-A46A-11B7E74BE132}'; RID_FacturasComision = '{8544F07A-17AF-4577-85FC-9EF71E768D98}'; RID_Comisiones = '{AD2CE43E-76BF-46DE-8F1A-35EE59D709C2}'; { Data table names } nme_ListaAnosComisiones = 'ListaAnosComisiones'; nme_FacturasComision = 'FacturasComision'; nme_Comisiones = 'Comisiones'; { ListaAnosComisiones fields } fld_ListaAnosComisionesANO = 'ANO'; { ListaAnosComisiones field indexes } idx_ListaAnosComisionesANO = 0; { FacturasComision fields } fld_FacturasComisionID = 'ID'; fld_FacturasComisionID_EMPRESA = 'ID_EMPRESA'; fld_FacturasComisionFECHA_FACTURA = 'FECHA_FACTURA'; fld_FacturasComisionREFERENCIA = 'REFERENCIA'; fld_FacturasComisionSITUACION = 'SITUACION'; fld_FacturasComisionID_COMISION_LIQUIDADA = 'ID_COMISION_LIQUIDADA'; fld_FacturasComisionID_CLIENTE = 'ID_CLIENTE'; fld_FacturasComisionID_AGENTE = 'ID_AGENTE'; fld_FacturasComisionBASE_IMPONIBLE = 'BASE_IMPONIBLE'; fld_FacturasComisionCOMISION = 'COMISION'; fld_FacturasComisionIMPORTE_COMISION = 'IMPORTE_COMISION'; { FacturasComision field indexes } idx_FacturasComisionID = 0; idx_FacturasComisionID_EMPRESA = 1; idx_FacturasComisionFECHA_FACTURA = 2; idx_FacturasComisionREFERENCIA = 3; idx_FacturasComisionSITUACION = 4; idx_FacturasComisionID_COMISION_LIQUIDADA = 5; idx_FacturasComisionID_CLIENTE = 6; idx_FacturasComisionID_AGENTE = 7; idx_FacturasComisionBASE_IMPONIBLE = 8; idx_FacturasComisionCOMISION = 9; idx_FacturasComisionIMPORTE_COMISION = 10; { Comisiones fields } fld_ComisionesID = 'ID'; fld_ComisionesID_EMPRESA = 'ID_EMPRESA'; fld_ComisionesREFERENCIA = 'REFERENCIA'; fld_ComisionesID_AGENTE = 'ID_AGENTE'; fld_ComisionesAGENTE = 'AGENTE'; fld_ComisionesDESCRIPCION = 'DESCRIPCION'; fld_ComisionesFECHA = 'FECHA'; fld_ComisionesIMPORTE_TOTAL = 'IMPORTE_TOTAL'; fld_ComisionesUSUARIO = 'USUARIO'; { Comisiones field indexes } idx_ComisionesID = 0; idx_ComisionesID_EMPRESA = 1; idx_ComisionesREFERENCIA = 2; idx_ComisionesID_AGENTE = 3; idx_ComisionesAGENTE = 4; idx_ComisionesDESCRIPCION = 5; idx_ComisionesFECHA = 6; idx_ComisionesIMPORTE_TOTAL = 7; idx_ComisionesUSUARIO = 8; type { IListaAnosComisiones } IListaAnosComisiones = interface(IDAStronglyTypedDataTable) ['{F701F56E-8083-4DE8-9063-C28DB8F75246}'] { Property getters and setters } function GetANOValue: String; procedure SetANOValue(const aValue: String); function GetANOIsNull: Boolean; procedure SetANOIsNull(const aValue: Boolean); { Properties } property ANO: String read GetANOValue write SetANOValue; property ANOIsNull: Boolean read GetANOIsNull write SetANOIsNull; end; { TListaAnosComisionesDataTableRules } TListaAnosComisionesDataTableRules = class(TIntfObjectDADataTableRules, IListaAnosComisiones) private protected { Property getters and setters } function GetANOValue: String; virtual; procedure SetANOValue(const aValue: String); virtual; function GetANOIsNull: Boolean; virtual; procedure SetANOIsNull(const aValue: Boolean); virtual; { Properties } property ANO: String read GetANOValue write SetANOValue; property ANOIsNull: Boolean read GetANOIsNull write SetANOIsNull; public constructor Create(aDataTable: TDADataTable); override; destructor Destroy; override; end; { IFacturasComision } IFacturasComision = interface(IDAStronglyTypedDataTable) ['{C31FD4C8-31FB-4324-90F4-890CFBB72AB9}'] { Property getters and setters } function GetIDValue: Integer; procedure SetIDValue(const aValue: Integer); function GetIDIsNull: Boolean; procedure SetIDIsNull(const aValue: Boolean); function GetID_EMPRESAValue: Integer; procedure SetID_EMPRESAValue(const aValue: Integer); function GetID_EMPRESAIsNull: Boolean; procedure SetID_EMPRESAIsNull(const aValue: Boolean); function GetFECHA_FACTURAValue: DateTime; procedure SetFECHA_FACTURAValue(const aValue: DateTime); function GetFECHA_FACTURAIsNull: Boolean; procedure SetFECHA_FACTURAIsNull(const aValue: Boolean); function GetREFERENCIAValue: String; procedure SetREFERENCIAValue(const aValue: String); function GetREFERENCIAIsNull: Boolean; procedure SetREFERENCIAIsNull(const aValue: Boolean); function GetSITUACIONValue: String; procedure SetSITUACIONValue(const aValue: String); function GetSITUACIONIsNull: Boolean; procedure SetSITUACIONIsNull(const aValue: Boolean); function GetID_COMISION_LIQUIDADAValue: Integer; procedure SetID_COMISION_LIQUIDADAValue(const aValue: Integer); function GetID_COMISION_LIQUIDADAIsNull: Boolean; procedure SetID_COMISION_LIQUIDADAIsNull(const aValue: Boolean); function GetID_CLIENTEValue: Integer; procedure SetID_CLIENTEValue(const aValue: Integer); function GetID_CLIENTEIsNull: Boolean; procedure SetID_CLIENTEIsNull(const aValue: Boolean); function GetID_AGENTEValue: Integer; procedure SetID_AGENTEValue(const aValue: Integer); function GetID_AGENTEIsNull: Boolean; procedure SetID_AGENTEIsNull(const aValue: Boolean); function GetBASE_IMPONIBLEValue: Currency; procedure SetBASE_IMPONIBLEValue(const aValue: Currency); function GetBASE_IMPONIBLEIsNull: Boolean; procedure SetBASE_IMPONIBLEIsNull(const aValue: Boolean); function GetCOMISIONValue: Currency; procedure SetCOMISIONValue(const aValue: Currency); function GetCOMISIONIsNull: Boolean; procedure SetCOMISIONIsNull(const aValue: Boolean); function GetIMPORTE_COMISIONValue: Currency; procedure SetIMPORTE_COMISIONValue(const aValue: Currency); function GetIMPORTE_COMISIONIsNull: Boolean; procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); { Properties } property ID: Integer read GetIDValue write SetIDValue; property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull; property ID_EMPRESA: Integer read GetID_EMPRESAValue write SetID_EMPRESAValue; property ID_EMPRESAIsNull: Boolean read GetID_EMPRESAIsNull write SetID_EMPRESAIsNull; property FECHA_FACTURA: DateTime read GetFECHA_FACTURAValue write SetFECHA_FACTURAValue; property FECHA_FACTURAIsNull: Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull; property REFERENCIA: String read GetREFERENCIAValue write SetREFERENCIAValue; property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull; property SITUACION: String read GetSITUACIONValue write SetSITUACIONValue; property SITUACIONIsNull: Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull; property ID_COMISION_LIQUIDADA: Integer read GetID_COMISION_LIQUIDADAValue write SetID_COMISION_LIQUIDADAValue; property ID_COMISION_LIQUIDADAIsNull: Boolean read GetID_COMISION_LIQUIDADAIsNull write SetID_COMISION_LIQUIDADAIsNull; property ID_CLIENTE: Integer read GetID_CLIENTEValue write SetID_CLIENTEValue; property ID_CLIENTEIsNull: Boolean read GetID_CLIENTEIsNull write SetID_CLIENTEIsNull; property ID_AGENTE: Integer read GetID_AGENTEValue write SetID_AGENTEValue; property ID_AGENTEIsNull: Boolean read GetID_AGENTEIsNull write SetID_AGENTEIsNull; property BASE_IMPONIBLE: Currency read GetBASE_IMPONIBLEValue write SetBASE_IMPONIBLEValue; property BASE_IMPONIBLEIsNull: Boolean read GetBASE_IMPONIBLEIsNull write SetBASE_IMPONIBLEIsNull; property COMISION: Currency read GetCOMISIONValue write SetCOMISIONValue; property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull; property IMPORTE_COMISION: Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue; property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull; end; { TFacturasComisionDataTableRules } TFacturasComisionDataTableRules = class(TIntfObjectDADataTableRules, IFacturasComision) private protected { Property getters and setters } function GetIDValue: Integer; virtual; procedure SetIDValue(const aValue: Integer); virtual; function GetIDIsNull: Boolean; virtual; procedure SetIDIsNull(const aValue: Boolean); virtual; function GetID_EMPRESAValue: Integer; virtual; procedure SetID_EMPRESAValue(const aValue: Integer); virtual; function GetID_EMPRESAIsNull: Boolean; virtual; procedure SetID_EMPRESAIsNull(const aValue: Boolean); virtual; function GetFECHA_FACTURAValue: DateTime; virtual; procedure SetFECHA_FACTURAValue(const aValue: DateTime); virtual; function GetFECHA_FACTURAIsNull: Boolean; virtual; procedure SetFECHA_FACTURAIsNull(const aValue: Boolean); virtual; function GetREFERENCIAValue: String; virtual; procedure SetREFERENCIAValue(const aValue: String); virtual; function GetREFERENCIAIsNull: Boolean; virtual; procedure SetREFERENCIAIsNull(const aValue: Boolean); virtual; function GetSITUACIONValue: String; virtual; procedure SetSITUACIONValue(const aValue: String); virtual; function GetSITUACIONIsNull: Boolean; virtual; procedure SetSITUACIONIsNull(const aValue: Boolean); virtual; function GetID_COMISION_LIQUIDADAValue: Integer; virtual; procedure SetID_COMISION_LIQUIDADAValue(const aValue: Integer); virtual; function GetID_COMISION_LIQUIDADAIsNull: Boolean; virtual; procedure SetID_COMISION_LIQUIDADAIsNull(const aValue: Boolean); virtual; function GetID_CLIENTEValue: Integer; virtual; procedure SetID_CLIENTEValue(const aValue: Integer); virtual; function GetID_CLIENTEIsNull: Boolean; virtual; procedure SetID_CLIENTEIsNull(const aValue: Boolean); virtual; function GetID_AGENTEValue: Integer; virtual; procedure SetID_AGENTEValue(const aValue: Integer); virtual; function GetID_AGENTEIsNull: Boolean; virtual; procedure SetID_AGENTEIsNull(const aValue: Boolean); virtual; function GetBASE_IMPONIBLEValue: Currency; virtual; procedure SetBASE_IMPONIBLEValue(const aValue: Currency); virtual; function GetBASE_IMPONIBLEIsNull: Boolean; virtual; procedure SetBASE_IMPONIBLEIsNull(const aValue: Boolean); virtual; function GetCOMISIONValue: Currency; virtual; procedure SetCOMISIONValue(const aValue: Currency); virtual; function GetCOMISIONIsNull: Boolean; virtual; procedure SetCOMISIONIsNull(const aValue: Boolean); virtual; function GetIMPORTE_COMISIONValue: Currency; virtual; procedure SetIMPORTE_COMISIONValue(const aValue: Currency); virtual; function GetIMPORTE_COMISIONIsNull: Boolean; virtual; procedure SetIMPORTE_COMISIONIsNull(const aValue: Boolean); virtual; { Properties } property ID: Integer read GetIDValue write SetIDValue; property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull; property ID_EMPRESA: Integer read GetID_EMPRESAValue write SetID_EMPRESAValue; property ID_EMPRESAIsNull: Boolean read GetID_EMPRESAIsNull write SetID_EMPRESAIsNull; property FECHA_FACTURA: DateTime read GetFECHA_FACTURAValue write SetFECHA_FACTURAValue; property FECHA_FACTURAIsNull: Boolean read GetFECHA_FACTURAIsNull write SetFECHA_FACTURAIsNull; property REFERENCIA: String read GetREFERENCIAValue write SetREFERENCIAValue; property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull; property SITUACION: String read GetSITUACIONValue write SetSITUACIONValue; property SITUACIONIsNull: Boolean read GetSITUACIONIsNull write SetSITUACIONIsNull; property ID_COMISION_LIQUIDADA: Integer read GetID_COMISION_LIQUIDADAValue write SetID_COMISION_LIQUIDADAValue; property ID_COMISION_LIQUIDADAIsNull: Boolean read GetID_COMISION_LIQUIDADAIsNull write SetID_COMISION_LIQUIDADAIsNull; property ID_CLIENTE: Integer read GetID_CLIENTEValue write SetID_CLIENTEValue; property ID_CLIENTEIsNull: Boolean read GetID_CLIENTEIsNull write SetID_CLIENTEIsNull; property ID_AGENTE: Integer read GetID_AGENTEValue write SetID_AGENTEValue; property ID_AGENTEIsNull: Boolean read GetID_AGENTEIsNull write SetID_AGENTEIsNull; property BASE_IMPONIBLE: Currency read GetBASE_IMPONIBLEValue write SetBASE_IMPONIBLEValue; property BASE_IMPONIBLEIsNull: Boolean read GetBASE_IMPONIBLEIsNull write SetBASE_IMPONIBLEIsNull; property COMISION: Currency read GetCOMISIONValue write SetCOMISIONValue; property COMISIONIsNull: Boolean read GetCOMISIONIsNull write SetCOMISIONIsNull; property IMPORTE_COMISION: Currency read GetIMPORTE_COMISIONValue write SetIMPORTE_COMISIONValue; property IMPORTE_COMISIONIsNull: Boolean read GetIMPORTE_COMISIONIsNull write SetIMPORTE_COMISIONIsNull; public constructor Create(aDataTable: TDADataTable); override; destructor Destroy; override; end; { IComisiones } IComisiones = interface(IDAStronglyTypedDataTable) ['{A44ADB7B-CA5F-48C5-A770-B2A415A581F0}'] { Property getters and setters } function GetIDValue: Integer; procedure SetIDValue(const aValue: Integer); function GetIDIsNull: Boolean; procedure SetIDIsNull(const aValue: Boolean); function GetID_EMPRESAValue: Integer; procedure SetID_EMPRESAValue(const aValue: Integer); function GetID_EMPRESAIsNull: Boolean; procedure SetID_EMPRESAIsNull(const aValue: Boolean); function GetREFERENCIAValue: String; procedure SetREFERENCIAValue(const aValue: String); function GetREFERENCIAIsNull: Boolean; procedure SetREFERENCIAIsNull(const aValue: Boolean); function GetID_AGENTEValue: Integer; procedure SetID_AGENTEValue(const aValue: Integer); function GetID_AGENTEIsNull: Boolean; procedure SetID_AGENTEIsNull(const aValue: Boolean); function GetAGENTEValue: String; procedure SetAGENTEValue(const aValue: String); function GetAGENTEIsNull: Boolean; procedure SetAGENTEIsNull(const aValue: Boolean); function GetDESCRIPCIONValue: String; procedure SetDESCRIPCIONValue(const aValue: String); function GetDESCRIPCIONIsNull: Boolean; procedure SetDESCRIPCIONIsNull(const aValue: Boolean); function GetFECHAValue: DateTime; procedure SetFECHAValue(const aValue: DateTime); function GetFECHAIsNull: Boolean; procedure SetFECHAIsNull(const aValue: Boolean); function GetIMPORTE_TOTALValue: Currency; procedure SetIMPORTE_TOTALValue(const aValue: Currency); function GetIMPORTE_TOTALIsNull: Boolean; procedure SetIMPORTE_TOTALIsNull(const aValue: Boolean); function GetUSUARIOValue: String; procedure SetUSUARIOValue(const aValue: String); function GetUSUARIOIsNull: Boolean; procedure SetUSUARIOIsNull(const aValue: Boolean); { Properties } property ID: Integer read GetIDValue write SetIDValue; property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull; property ID_EMPRESA: Integer read GetID_EMPRESAValue write SetID_EMPRESAValue; property ID_EMPRESAIsNull: Boolean read GetID_EMPRESAIsNull write SetID_EMPRESAIsNull; property REFERENCIA: String read GetREFERENCIAValue write SetREFERENCIAValue; property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull; property ID_AGENTE: Integer read GetID_AGENTEValue write SetID_AGENTEValue; property ID_AGENTEIsNull: Boolean read GetID_AGENTEIsNull write SetID_AGENTEIsNull; property AGENTE: String read GetAGENTEValue write SetAGENTEValue; property AGENTEIsNull: Boolean read GetAGENTEIsNull write SetAGENTEIsNull; property DESCRIPCION: String read GetDESCRIPCIONValue write SetDESCRIPCIONValue; property DESCRIPCIONIsNull: Boolean read GetDESCRIPCIONIsNull write SetDESCRIPCIONIsNull; property FECHA: DateTime read GetFECHAValue write SetFECHAValue; property FECHAIsNull: Boolean read GetFECHAIsNull write SetFECHAIsNull; property IMPORTE_TOTAL: Currency read GetIMPORTE_TOTALValue write SetIMPORTE_TOTALValue; property IMPORTE_TOTALIsNull: Boolean read GetIMPORTE_TOTALIsNull write SetIMPORTE_TOTALIsNull; property USUARIO: String read GetUSUARIOValue write SetUSUARIOValue; property USUARIOIsNull: Boolean read GetUSUARIOIsNull write SetUSUARIOIsNull; end; { TComisionesDataTableRules } TComisionesDataTableRules = class(TIntfObjectDADataTableRules, IComisiones) private protected { Property getters and setters } function GetIDValue: Integer; virtual; procedure SetIDValue(const aValue: Integer); virtual; function GetIDIsNull: Boolean; virtual; procedure SetIDIsNull(const aValue: Boolean); virtual; function GetID_EMPRESAValue: Integer; virtual; procedure SetID_EMPRESAValue(const aValue: Integer); virtual; function GetID_EMPRESAIsNull: Boolean; virtual; procedure SetID_EMPRESAIsNull(const aValue: Boolean); virtual; function GetREFERENCIAValue: String; virtual; procedure SetREFERENCIAValue(const aValue: String); virtual; function GetREFERENCIAIsNull: Boolean; virtual; procedure SetREFERENCIAIsNull(const aValue: Boolean); virtual; function GetID_AGENTEValue: Integer; virtual; procedure SetID_AGENTEValue(const aValue: Integer); virtual; function GetID_AGENTEIsNull: Boolean; virtual; procedure SetID_AGENTEIsNull(const aValue: Boolean); virtual; function GetAGENTEValue: String; virtual; procedure SetAGENTEValue(const aValue: String); virtual; function GetAGENTEIsNull: Boolean; virtual; procedure SetAGENTEIsNull(const aValue: Boolean); virtual; function GetDESCRIPCIONValue: String; virtual; procedure SetDESCRIPCIONValue(const aValue: String); virtual; function GetDESCRIPCIONIsNull: Boolean; virtual; procedure SetDESCRIPCIONIsNull(const aValue: Boolean); virtual; function GetFECHAValue: DateTime; virtual; procedure SetFECHAValue(const aValue: DateTime); virtual; function GetFECHAIsNull: Boolean; virtual; procedure SetFECHAIsNull(const aValue: Boolean); virtual; function GetIMPORTE_TOTALValue: Currency; virtual; procedure SetIMPORTE_TOTALValue(const aValue: Currency); virtual; function GetIMPORTE_TOTALIsNull: Boolean; virtual; procedure SetIMPORTE_TOTALIsNull(const aValue: Boolean); virtual; function GetUSUARIOValue: String; virtual; procedure SetUSUARIOValue(const aValue: String); virtual; function GetUSUARIOIsNull: Boolean; virtual; procedure SetUSUARIOIsNull(const aValue: Boolean); virtual; { Properties } property ID: Integer read GetIDValue write SetIDValue; property IDIsNull: Boolean read GetIDIsNull write SetIDIsNull; property ID_EMPRESA: Integer read GetID_EMPRESAValue write SetID_EMPRESAValue; property ID_EMPRESAIsNull: Boolean read GetID_EMPRESAIsNull write SetID_EMPRESAIsNull; property REFERENCIA: String read GetREFERENCIAValue write SetREFERENCIAValue; property REFERENCIAIsNull: Boolean read GetREFERENCIAIsNull write SetREFERENCIAIsNull; property ID_AGENTE: Integer read GetID_AGENTEValue write SetID_AGENTEValue; property ID_AGENTEIsNull: Boolean read GetID_AGENTEIsNull write SetID_AGENTEIsNull; property AGENTE: String read GetAGENTEValue write SetAGENTEValue; property AGENTEIsNull: Boolean read GetAGENTEIsNull write SetAGENTEIsNull; property DESCRIPCION: String read GetDESCRIPCIONValue write SetDESCRIPCIONValue; property DESCRIPCIONIsNull: Boolean read GetDESCRIPCIONIsNull write SetDESCRIPCIONIsNull; property FECHA: DateTime read GetFECHAValue write SetFECHAValue; property FECHAIsNull: Boolean read GetFECHAIsNull write SetFECHAIsNull; property IMPORTE_TOTAL: Currency read GetIMPORTE_TOTALValue write SetIMPORTE_TOTALValue; property IMPORTE_TOTALIsNull: Boolean read GetIMPORTE_TOTALIsNull write SetIMPORTE_TOTALIsNull; property USUARIO: String read GetUSUARIOValue write SetUSUARIOValue; property USUARIOIsNull: Boolean read GetUSUARIOIsNull write SetUSUARIOIsNull; public constructor Create(aDataTable: TDADataTable); override; destructor Destroy; override; end; implementation uses Variants, uROBinaryHelpers; { TListaAnosComisionesDataTableRules } constructor TListaAnosComisionesDataTableRules.Create(aDataTable: TDADataTable); begin inherited; end; destructor TListaAnosComisionesDataTableRules.Destroy; begin inherited; end; function TListaAnosComisionesDataTableRules.GetANOValue: String; begin result := DataTable.Fields[idx_ListaAnosComisionesANO].AsString; end; procedure TListaAnosComisionesDataTableRules.SetANOValue(const aValue: String); begin DataTable.Fields[idx_ListaAnosComisionesANO].AsString := aValue; end; function TListaAnosComisionesDataTableRules.GetANOIsNull: boolean; begin result := DataTable.Fields[idx_ListaAnosComisionesANO].IsNull; end; procedure TListaAnosComisionesDataTableRules.SetANOIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ListaAnosComisionesANO].AsVariant := Null; end; { TFacturasComisionDataTableRules } constructor TFacturasComisionDataTableRules.Create(aDataTable: TDADataTable); begin inherited; end; destructor TFacturasComisionDataTableRules.Destroy; begin inherited; end; function TFacturasComisionDataTableRules.GetIDValue: Integer; begin result := DataTable.Fields[idx_FacturasComisionID].AsInteger; end; procedure TFacturasComisionDataTableRules.SetIDValue(const aValue: Integer); begin DataTable.Fields[idx_FacturasComisionID].AsInteger := aValue; end; function TFacturasComisionDataTableRules.GetIDIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionID].IsNull; end; procedure TFacturasComisionDataTableRules.SetIDIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionID].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetID_EMPRESAValue: Integer; begin result := DataTable.Fields[idx_FacturasComisionID_EMPRESA].AsInteger; end; procedure TFacturasComisionDataTableRules.SetID_EMPRESAValue(const aValue: Integer); begin DataTable.Fields[idx_FacturasComisionID_EMPRESA].AsInteger := aValue; end; function TFacturasComisionDataTableRules.GetID_EMPRESAIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionID_EMPRESA].IsNull; end; procedure TFacturasComisionDataTableRules.SetID_EMPRESAIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionID_EMPRESA].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetFECHA_FACTURAValue: DateTime; begin result := DataTable.Fields[idx_FacturasComisionFECHA_FACTURA].AsDateTime; end; procedure TFacturasComisionDataTableRules.SetFECHA_FACTURAValue(const aValue: DateTime); begin DataTable.Fields[idx_FacturasComisionFECHA_FACTURA].AsDateTime := aValue; end; function TFacturasComisionDataTableRules.GetFECHA_FACTURAIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionFECHA_FACTURA].IsNull; end; procedure TFacturasComisionDataTableRules.SetFECHA_FACTURAIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionFECHA_FACTURA].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetREFERENCIAValue: String; begin result := DataTable.Fields[idx_FacturasComisionREFERENCIA].AsString; end; procedure TFacturasComisionDataTableRules.SetREFERENCIAValue(const aValue: String); begin DataTable.Fields[idx_FacturasComisionREFERENCIA].AsString := aValue; end; function TFacturasComisionDataTableRules.GetREFERENCIAIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionREFERENCIA].IsNull; end; procedure TFacturasComisionDataTableRules.SetREFERENCIAIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionREFERENCIA].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetSITUACIONValue: String; begin result := DataTable.Fields[idx_FacturasComisionSITUACION].AsString; end; procedure TFacturasComisionDataTableRules.SetSITUACIONValue(const aValue: String); begin DataTable.Fields[idx_FacturasComisionSITUACION].AsString := aValue; end; function TFacturasComisionDataTableRules.GetSITUACIONIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionSITUACION].IsNull; end; procedure TFacturasComisionDataTableRules.SetSITUACIONIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionSITUACION].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetID_COMISION_LIQUIDADAValue: Integer; begin result := DataTable.Fields[idx_FacturasComisionID_COMISION_LIQUIDADA].AsInteger; end; procedure TFacturasComisionDataTableRules.SetID_COMISION_LIQUIDADAValue(const aValue: Integer); begin DataTable.Fields[idx_FacturasComisionID_COMISION_LIQUIDADA].AsInteger := aValue; end; function TFacturasComisionDataTableRules.GetID_COMISION_LIQUIDADAIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionID_COMISION_LIQUIDADA].IsNull; end; procedure TFacturasComisionDataTableRules.SetID_COMISION_LIQUIDADAIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionID_COMISION_LIQUIDADA].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetID_CLIENTEValue: Integer; begin result := DataTable.Fields[idx_FacturasComisionID_CLIENTE].AsInteger; end; procedure TFacturasComisionDataTableRules.SetID_CLIENTEValue(const aValue: Integer); begin DataTable.Fields[idx_FacturasComisionID_CLIENTE].AsInteger := aValue; end; function TFacturasComisionDataTableRules.GetID_CLIENTEIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionID_CLIENTE].IsNull; end; procedure TFacturasComisionDataTableRules.SetID_CLIENTEIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionID_CLIENTE].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetID_AGENTEValue: Integer; begin result := DataTable.Fields[idx_FacturasComisionID_AGENTE].AsInteger; end; procedure TFacturasComisionDataTableRules.SetID_AGENTEValue(const aValue: Integer); begin DataTable.Fields[idx_FacturasComisionID_AGENTE].AsInteger := aValue; end; function TFacturasComisionDataTableRules.GetID_AGENTEIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionID_AGENTE].IsNull; end; procedure TFacturasComisionDataTableRules.SetID_AGENTEIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionID_AGENTE].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetBASE_IMPONIBLEValue: Currency; begin result := DataTable.Fields[idx_FacturasComisionBASE_IMPONIBLE].AsCurrency; end; procedure TFacturasComisionDataTableRules.SetBASE_IMPONIBLEValue(const aValue: Currency); begin DataTable.Fields[idx_FacturasComisionBASE_IMPONIBLE].AsCurrency := aValue; end; function TFacturasComisionDataTableRules.GetBASE_IMPONIBLEIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionBASE_IMPONIBLE].IsNull; end; procedure TFacturasComisionDataTableRules.SetBASE_IMPONIBLEIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionBASE_IMPONIBLE].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetCOMISIONValue: Currency; begin result := DataTable.Fields[idx_FacturasComisionCOMISION].AsCurrency; end; procedure TFacturasComisionDataTableRules.SetCOMISIONValue(const aValue: Currency); begin DataTable.Fields[idx_FacturasComisionCOMISION].AsCurrency := aValue; end; function TFacturasComisionDataTableRules.GetCOMISIONIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionCOMISION].IsNull; end; procedure TFacturasComisionDataTableRules.SetCOMISIONIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionCOMISION].AsVariant := Null; end; function TFacturasComisionDataTableRules.GetIMPORTE_COMISIONValue: Currency; begin result := DataTable.Fields[idx_FacturasComisionIMPORTE_COMISION].AsCurrency; end; procedure TFacturasComisionDataTableRules.SetIMPORTE_COMISIONValue(const aValue: Currency); begin DataTable.Fields[idx_FacturasComisionIMPORTE_COMISION].AsCurrency := aValue; end; function TFacturasComisionDataTableRules.GetIMPORTE_COMISIONIsNull: boolean; begin result := DataTable.Fields[idx_FacturasComisionIMPORTE_COMISION].IsNull; end; procedure TFacturasComisionDataTableRules.SetIMPORTE_COMISIONIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_FacturasComisionIMPORTE_COMISION].AsVariant := Null; end; { TComisionesDataTableRules } constructor TComisionesDataTableRules.Create(aDataTable: TDADataTable); begin inherited; end; destructor TComisionesDataTableRules.Destroy; begin inherited; end; function TComisionesDataTableRules.GetIDValue: Integer; begin result := DataTable.Fields[idx_ComisionesID].AsInteger; end; procedure TComisionesDataTableRules.SetIDValue(const aValue: Integer); begin DataTable.Fields[idx_ComisionesID].AsInteger := aValue; end; function TComisionesDataTableRules.GetIDIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesID].IsNull; end; procedure TComisionesDataTableRules.SetIDIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesID].AsVariant := Null; end; function TComisionesDataTableRules.GetID_EMPRESAValue: Integer; begin result := DataTable.Fields[idx_ComisionesID_EMPRESA].AsInteger; end; procedure TComisionesDataTableRules.SetID_EMPRESAValue(const aValue: Integer); begin DataTable.Fields[idx_ComisionesID_EMPRESA].AsInteger := aValue; end; function TComisionesDataTableRules.GetID_EMPRESAIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesID_EMPRESA].IsNull; end; procedure TComisionesDataTableRules.SetID_EMPRESAIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesID_EMPRESA].AsVariant := Null; end; function TComisionesDataTableRules.GetREFERENCIAValue: String; begin result := DataTable.Fields[idx_ComisionesREFERENCIA].AsString; end; procedure TComisionesDataTableRules.SetREFERENCIAValue(const aValue: String); begin DataTable.Fields[idx_ComisionesREFERENCIA].AsString := aValue; end; function TComisionesDataTableRules.GetREFERENCIAIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesREFERENCIA].IsNull; end; procedure TComisionesDataTableRules.SetREFERENCIAIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesREFERENCIA].AsVariant := Null; end; function TComisionesDataTableRules.GetID_AGENTEValue: Integer; begin result := DataTable.Fields[idx_ComisionesID_AGENTE].AsInteger; end; procedure TComisionesDataTableRules.SetID_AGENTEValue(const aValue: Integer); begin DataTable.Fields[idx_ComisionesID_AGENTE].AsInteger := aValue; end; function TComisionesDataTableRules.GetID_AGENTEIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesID_AGENTE].IsNull; end; procedure TComisionesDataTableRules.SetID_AGENTEIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesID_AGENTE].AsVariant := Null; end; function TComisionesDataTableRules.GetAGENTEValue: String; begin result := DataTable.Fields[idx_ComisionesAGENTE].AsString; end; procedure TComisionesDataTableRules.SetAGENTEValue(const aValue: String); begin DataTable.Fields[idx_ComisionesAGENTE].AsString := aValue; end; function TComisionesDataTableRules.GetAGENTEIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesAGENTE].IsNull; end; procedure TComisionesDataTableRules.SetAGENTEIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesAGENTE].AsVariant := Null; end; function TComisionesDataTableRules.GetDESCRIPCIONValue: String; begin result := DataTable.Fields[idx_ComisionesDESCRIPCION].AsString; end; procedure TComisionesDataTableRules.SetDESCRIPCIONValue(const aValue: String); begin DataTable.Fields[idx_ComisionesDESCRIPCION].AsString := aValue; end; function TComisionesDataTableRules.GetDESCRIPCIONIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesDESCRIPCION].IsNull; end; procedure TComisionesDataTableRules.SetDESCRIPCIONIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesDESCRIPCION].AsVariant := Null; end; function TComisionesDataTableRules.GetFECHAValue: DateTime; begin result := DataTable.Fields[idx_ComisionesFECHA].AsDateTime; end; procedure TComisionesDataTableRules.SetFECHAValue(const aValue: DateTime); begin DataTable.Fields[idx_ComisionesFECHA].AsDateTime := aValue; end; function TComisionesDataTableRules.GetFECHAIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesFECHA].IsNull; end; procedure TComisionesDataTableRules.SetFECHAIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesFECHA].AsVariant := Null; end; function TComisionesDataTableRules.GetIMPORTE_TOTALValue: Currency; begin result := DataTable.Fields[idx_ComisionesIMPORTE_TOTAL].AsCurrency; end; procedure TComisionesDataTableRules.SetIMPORTE_TOTALValue(const aValue: Currency); begin DataTable.Fields[idx_ComisionesIMPORTE_TOTAL].AsCurrency := aValue; end; function TComisionesDataTableRules.GetIMPORTE_TOTALIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesIMPORTE_TOTAL].IsNull; end; procedure TComisionesDataTableRules.SetIMPORTE_TOTALIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesIMPORTE_TOTAL].AsVariant := Null; end; function TComisionesDataTableRules.GetUSUARIOValue: String; begin result := DataTable.Fields[idx_ComisionesUSUARIO].AsString; end; procedure TComisionesDataTableRules.SetUSUARIOValue(const aValue: String); begin DataTable.Fields[idx_ComisionesUSUARIO].AsString := aValue; end; function TComisionesDataTableRules.GetUSUARIOIsNull: boolean; begin result := DataTable.Fields[idx_ComisionesUSUARIO].IsNull; end; procedure TComisionesDataTableRules.SetUSUARIOIsNull(const aValue: Boolean); begin if aValue then DataTable.Fields[idx_ComisionesUSUARIO].AsVariant := Null; end; initialization RegisterDataTableRules(RID_ListaAnosComisiones, TListaAnosComisionesDataTableRules); RegisterDataTableRules(RID_FacturasComision, TFacturasComisionDataTableRules); RegisterDataTableRules(RID_Comisiones, TComisionesDataTableRules); end.