unit schCitasServer_Intf;

interface

uses
  Classes, DB, SysUtils, uROClasses, uDADataTable, uDABusinessProcessor, schCitasClient_Intf;

const
  { Delta rules ids 
       Feel free to change them to something more human readable
       but make sure they are unique in the context of your application }
  RID_CITASDelta = '{5090F644-9CFB-4232-9EEE-7F7E7168EBB7}';
  RID_VENDEDORESDelta = '{DD67A3C2-3DE7-439A-B460-DC5BD2BB3032}';

type
  { ICITASDelta }
  ICITASDelta = interface(ICITAS)
  ['{5090F644-9CFB-4232-9EEE-7F7E7168EBB7}']
    { Property getters and setters }
    function GetOldIDValue : Integer;
    function GetOldPARENTIDValue : Integer;
    function GetOldSTARTValue : DateTime;
    function GetOldTIPOValue : Integer;
    function GetOldFINISHValue : DateTime;
    function GetOldOPTIONSValue : Integer;
    function GetOldCAPTIONValue : String;
    function GetOldMENSAJEValue : String;
    function GetOldRECURRENCEINDEXValue : Integer;
    function GetOldRESOURCEIDValue : Integer;
    function GetOldLOCATIONValue : String;
    function GetOldREMINDERValue : Integer;
    function GetOldSTATEValue : Integer;
    function GetOldLABELCOLORValue : Integer;
    function GetOldCODIGOCONTRATOValue : String;
    function GetOldTIPOTAREAValue : String;
    function GetOldNOMBRECLIENTEValue : String;
    function GetOldPARTIDAValue : String;
    function GetOldCOMPLETADAValue : DateTime;
    function GetOldNOMBREPROVEEDORValue : String;
    function GetOldCODIGOCOLUMNAValue : Integer;
    function GetOldCODIGOFILAValue : Integer;
    function GetOldEMPRESAValue : Integer;

    { Properties }
    property OldID : Integer read GetOldIDValue;
    property OldPARENTID : Integer read GetOldPARENTIDValue;
    property OldSTART : DateTime read GetOldSTARTValue;
    property OldTIPO : Integer read GetOldTIPOValue;
    property OldFINISH : DateTime read GetOldFINISHValue;
    property OldOPTIONS : Integer read GetOldOPTIONSValue;
    property OldCAPTION : String read GetOldCAPTIONValue;
    property OldMENSAJE : String read GetOldMENSAJEValue;
    property OldRECURRENCEINDEX : Integer read GetOldRECURRENCEINDEXValue;
    property OldRESOURCEID : Integer read GetOldRESOURCEIDValue;
    property OldLOCATION : String read GetOldLOCATIONValue;
    property OldREMINDER : Integer read GetOldREMINDERValue;
    property OldSTATE : Integer read GetOldSTATEValue;
    property OldLABELCOLOR : Integer read GetOldLABELCOLORValue;
    property OldCODIGOCONTRATO : String read GetOldCODIGOCONTRATOValue;
    property OldTIPOTAREA : String read GetOldTIPOTAREAValue;
    property OldNOMBRECLIENTE : String read GetOldNOMBRECLIENTEValue;
    property OldPARTIDA : String read GetOldPARTIDAValue;
    property OldCOMPLETADA : DateTime read GetOldCOMPLETADAValue;
    property OldNOMBREPROVEEDOR : String read GetOldNOMBREPROVEEDORValue;
    property OldCODIGOCOLUMNA : Integer read GetOldCODIGOCOLUMNAValue;
    property OldCODIGOFILA : Integer read GetOldCODIGOFILAValue;
    property OldEMPRESA : Integer read GetOldEMPRESAValue;
  end;

  { TCITASBusinessProcessorRules }
  TCITASBusinessProcessorRules = class(TDABusinessProcessorRules, ICITAS, ICITASDelta)
  private
  protected
    { Property getters and setters }
    function GetIDValue: Integer; virtual;
    function GetOldIDValue: Integer; virtual;
    procedure SetIDValue(const aValue: Integer); virtual;
    function GetPARENTIDValue: Integer; virtual;
    function GetOldPARENTIDValue: Integer; virtual;
    procedure SetPARENTIDValue(const aValue: Integer); virtual;
    function GetSTARTValue: DateTime; virtual;
    function GetOldSTARTValue: DateTime; virtual;
    procedure SetSTARTValue(const aValue: DateTime); virtual;
    function GetTIPOValue: Integer; virtual;
    function GetOldTIPOValue: Integer; virtual;
    procedure SetTIPOValue(const aValue: Integer); virtual;
    function GetFINISHValue: DateTime; virtual;
    function GetOldFINISHValue: DateTime; virtual;
    procedure SetFINISHValue(const aValue: DateTime); virtual;
    function GetOPTIONSValue: Integer; virtual;
    function GetOldOPTIONSValue: Integer; virtual;
    procedure SetOPTIONSValue(const aValue: Integer); virtual;
    function GetCAPTIONValue: String; virtual;
    function GetOldCAPTIONValue: String; virtual;
    procedure SetCAPTIONValue(const aValue: String); virtual;
    function GetMENSAJEValue: String; virtual;
    function GetOldMENSAJEValue: String; virtual;
    procedure SetMENSAJEValue(const aValue: String); virtual;
    function GetRECURRENCEINDEXValue: Integer; virtual;
    function GetOldRECURRENCEINDEXValue: Integer; virtual;
    procedure SetRECURRENCEINDEXValue(const aValue: Integer); virtual;
    function GetRESOURCEIDValue: Integer; virtual;
    function GetOldRESOURCEIDValue: Integer; virtual;
    procedure SetRESOURCEIDValue(const aValue: Integer); virtual;
    function GetLOCATIONValue: String; virtual;
    function GetOldLOCATIONValue: String; virtual;
    procedure SetLOCATIONValue(const aValue: String); virtual;
    function GetREMINDERValue: Integer; virtual;
    function GetOldREMINDERValue: Integer; virtual;
    procedure SetREMINDERValue(const aValue: Integer); virtual;
    function GetSTATEValue: Integer; virtual;
    function GetOldSTATEValue: Integer; virtual;
    procedure SetSTATEValue(const aValue: Integer); virtual;
    function GetLABELCOLORValue: Integer; virtual;
    function GetOldLABELCOLORValue: Integer; virtual;
    procedure SetLABELCOLORValue(const aValue: Integer); virtual;
    function GetCODIGOCONTRATOValue: String; virtual;
    function GetOldCODIGOCONTRATOValue: String; virtual;
    procedure SetCODIGOCONTRATOValue(const aValue: String); virtual;
    function GetTIPOTAREAValue: String; virtual;
    function GetOldTIPOTAREAValue: String; virtual;
    procedure SetTIPOTAREAValue(const aValue: String); virtual;
    function GetNOMBRECLIENTEValue: String; virtual;
    function GetOldNOMBRECLIENTEValue: String; virtual;
    procedure SetNOMBRECLIENTEValue(const aValue: String); virtual;
    function GetPARTIDAValue: String; virtual;
    function GetOldPARTIDAValue: String; virtual;
    procedure SetPARTIDAValue(const aValue: String); virtual;
    function GetCOMPLETADAValue: DateTime; virtual;
    function GetOldCOMPLETADAValue: DateTime; virtual;
    procedure SetCOMPLETADAValue(const aValue: DateTime); virtual;
    function GetNOMBREPROVEEDORValue: String; virtual;
    function GetOldNOMBREPROVEEDORValue: String; virtual;
    procedure SetNOMBREPROVEEDORValue(const aValue: String); virtual;
    function GetCODIGOCOLUMNAValue: Integer; virtual;
    function GetOldCODIGOCOLUMNAValue: Integer; virtual;
    procedure SetCODIGOCOLUMNAValue(const aValue: Integer); virtual;
    function GetCODIGOFILAValue: Integer; virtual;
    function GetOldCODIGOFILAValue: Integer; virtual;
    procedure SetCODIGOFILAValue(const aValue: Integer); virtual;
    function GetEMPRESAValue: Integer; virtual;
    function GetOldEMPRESAValue: Integer; virtual;
    procedure SetEMPRESAValue(const aValue: Integer); virtual;

    { Properties }
    property ID : Integer read GetIDValue write SetIDValue;
    property OldID : Integer read GetOldIDValue;
    property PARENTID : Integer read GetPARENTIDValue write SetPARENTIDValue;
    property OldPARENTID : Integer read GetOldPARENTIDValue;
    property START : DateTime read GetSTARTValue write SetSTARTValue;
    property OldSTART : DateTime read GetOldSTARTValue;
    property TIPO : Integer read GetTIPOValue write SetTIPOValue;
    property OldTIPO : Integer read GetOldTIPOValue;
    property FINISH : DateTime read GetFINISHValue write SetFINISHValue;
    property OldFINISH : DateTime read GetOldFINISHValue;
    property OPTIONS : Integer read GetOPTIONSValue write SetOPTIONSValue;
    property OldOPTIONS : Integer read GetOldOPTIONSValue;
    property CAPTION : String read GetCAPTIONValue write SetCAPTIONValue;
    property OldCAPTION : String read GetOldCAPTIONValue;
    property MENSAJE : String read GetMENSAJEValue write SetMENSAJEValue;
    property OldMENSAJE : String read GetOldMENSAJEValue;
    property RECURRENCEINDEX : Integer read GetRECURRENCEINDEXValue write SetRECURRENCEINDEXValue;
    property OldRECURRENCEINDEX : Integer read GetOldRECURRENCEINDEXValue;
    property RESOURCEID : Integer read GetRESOURCEIDValue write SetRESOURCEIDValue;
    property OldRESOURCEID : Integer read GetOldRESOURCEIDValue;
    property LOCATION : String read GetLOCATIONValue write SetLOCATIONValue;
    property OldLOCATION : String read GetOldLOCATIONValue;
    property REMINDER : Integer read GetREMINDERValue write SetREMINDERValue;
    property OldREMINDER : Integer read GetOldREMINDERValue;
    property STATE : Integer read GetSTATEValue write SetSTATEValue;
    property OldSTATE : Integer read GetOldSTATEValue;
    property LABELCOLOR : Integer read GetLABELCOLORValue write SetLABELCOLORValue;
    property OldLABELCOLOR : Integer read GetOldLABELCOLORValue;
    property CODIGOCONTRATO : String read GetCODIGOCONTRATOValue write SetCODIGOCONTRATOValue;
    property OldCODIGOCONTRATO : String read GetOldCODIGOCONTRATOValue;
    property TIPOTAREA : String read GetTIPOTAREAValue write SetTIPOTAREAValue;
    property OldTIPOTAREA : String read GetOldTIPOTAREAValue;
    property NOMBRECLIENTE : String read GetNOMBRECLIENTEValue write SetNOMBRECLIENTEValue;
    property OldNOMBRECLIENTE : String read GetOldNOMBRECLIENTEValue;
    property PARTIDA : String read GetPARTIDAValue write SetPARTIDAValue;
    property OldPARTIDA : String read GetOldPARTIDAValue;
    property COMPLETADA : DateTime read GetCOMPLETADAValue write SetCOMPLETADAValue;
    property OldCOMPLETADA : DateTime read GetOldCOMPLETADAValue;
    property NOMBREPROVEEDOR : String read GetNOMBREPROVEEDORValue write SetNOMBREPROVEEDORValue;
    property OldNOMBREPROVEEDOR : String read GetOldNOMBREPROVEEDORValue;
    property CODIGOCOLUMNA : Integer read GetCODIGOCOLUMNAValue write SetCODIGOCOLUMNAValue;
    property OldCODIGOCOLUMNA : Integer read GetOldCODIGOCOLUMNAValue;
    property CODIGOFILA : Integer read GetCODIGOFILAValue write SetCODIGOFILAValue;
    property OldCODIGOFILA : Integer read GetOldCODIGOFILAValue;
    property EMPRESA : Integer read GetEMPRESAValue write SetEMPRESAValue;
    property OldEMPRESA : Integer read GetOldEMPRESAValue;

  public
    constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
    destructor Destroy; override;

  end;

  { IVENDEDORESDelta }
  IVENDEDORESDelta = interface(IVENDEDORES)
  ['{DD67A3C2-3DE7-439A-B460-DC5BD2BB3032}']
    { Property getters and setters }
    function GetOldCODIGOEMPRESAValue : Integer;
    function GetOldCODIGOValue : Integer;
    function GetOldFECHAALTAValue : DateTime;
    function GetOldUSUARIOValue : String;
    function GetOldNIFCIFValue : String;
    function GetOldNOMBREValue : String;
    function GetOldNOTASValue : String;
    function GetOldCALLEValue : String;
    function GetOldPROVINCIAValue : String;
    function GetOldCODIGOPOSTALValue : String;
    function GetOldPOBLACIONValue : String;
    function GetOldTELEFONO1Value : String;
    function GetOldTELEFONO2Value : String;
    function GetOldMOVILValue : String;
    function GetOldFAXValue : String;
    function GetOldCORREO1Value : String;
    function GetOldCORREO2Value : String;
    function GetOldPAGINAWEBValue : String;
    function GetOldPERSONACONTACTOValue : String;

    { Properties }
    property OldCODIGOEMPRESA : Integer read GetOldCODIGOEMPRESAValue;
    property OldCODIGO : Integer read GetOldCODIGOValue;
    property OldFECHAALTA : DateTime read GetOldFECHAALTAValue;
    property OldUSUARIO : String read GetOldUSUARIOValue;
    property OldNIFCIF : String read GetOldNIFCIFValue;
    property OldNOMBRE : String read GetOldNOMBREValue;
    property OldNOTAS : String read GetOldNOTASValue;
    property OldCALLE : String read GetOldCALLEValue;
    property OldPROVINCIA : String read GetOldPROVINCIAValue;
    property OldCODIGOPOSTAL : String read GetOldCODIGOPOSTALValue;
    property OldPOBLACION : String read GetOldPOBLACIONValue;
    property OldTELEFONO1 : String read GetOldTELEFONO1Value;
    property OldTELEFONO2 : String read GetOldTELEFONO2Value;
    property OldMOVIL : String read GetOldMOVILValue;
    property OldFAX : String read GetOldFAXValue;
    property OldCORREO1 : String read GetOldCORREO1Value;
    property OldCORREO2 : String read GetOldCORREO2Value;
    property OldPAGINAWEB : String read GetOldPAGINAWEBValue;
    property OldPERSONACONTACTO : String read GetOldPERSONACONTACTOValue;
  end;

  { TVENDEDORESBusinessProcessorRules }
  TVENDEDORESBusinessProcessorRules = class(TDABusinessProcessorRules, IVENDEDORES, IVENDEDORESDelta)
  private
  protected
    { Property getters and setters }
    function GetCODIGOEMPRESAValue: Integer; virtual;
    function GetOldCODIGOEMPRESAValue: Integer; virtual;
    procedure SetCODIGOEMPRESAValue(const aValue: Integer); virtual;
    function GetCODIGOValue: Integer; virtual;
    function GetOldCODIGOValue: Integer; virtual;
    procedure SetCODIGOValue(const aValue: Integer); virtual;
    function GetFECHAALTAValue: DateTime; virtual;
    function GetOldFECHAALTAValue: DateTime; virtual;
    procedure SetFECHAALTAValue(const aValue: DateTime); virtual;
    function GetUSUARIOValue: String; virtual;
    function GetOldUSUARIOValue: String; virtual;
    procedure SetUSUARIOValue(const aValue: String); virtual;
    function GetNIFCIFValue: String; virtual;
    function GetOldNIFCIFValue: String; virtual;
    procedure SetNIFCIFValue(const aValue: String); virtual;
    function GetNOMBREValue: String; virtual;
    function GetOldNOMBREValue: String; virtual;
    procedure SetNOMBREValue(const aValue: String); virtual;
    function GetNOTASValue: String; virtual;
    function GetOldNOTASValue: String; virtual;
    procedure SetNOTASValue(const aValue: String); virtual;
    function GetCALLEValue: String; virtual;
    function GetOldCALLEValue: String; virtual;
    procedure SetCALLEValue(const aValue: String); virtual;
    function GetPROVINCIAValue: String; virtual;
    function GetOldPROVINCIAValue: String; virtual;
    procedure SetPROVINCIAValue(const aValue: String); virtual;
    function GetCODIGOPOSTALValue: String; virtual;
    function GetOldCODIGOPOSTALValue: String; virtual;
    procedure SetCODIGOPOSTALValue(const aValue: String); virtual;
    function GetPOBLACIONValue: String; virtual;
    function GetOldPOBLACIONValue: String; virtual;
    procedure SetPOBLACIONValue(const aValue: String); virtual;
    function GetTELEFONO1Value: String; virtual;
    function GetOldTELEFONO1Value: String; virtual;
    procedure SetTELEFONO1Value(const aValue: String); virtual;
    function GetTELEFONO2Value: String; virtual;
    function GetOldTELEFONO2Value: String; virtual;
    procedure SetTELEFONO2Value(const aValue: String); virtual;
    function GetMOVILValue: String; virtual;
    function GetOldMOVILValue: String; virtual;
    procedure SetMOVILValue(const aValue: String); virtual;
    function GetFAXValue: String; virtual;
    function GetOldFAXValue: String; virtual;
    procedure SetFAXValue(const aValue: String); virtual;
    function GetCORREO1Value: String; virtual;
    function GetOldCORREO1Value: String; virtual;
    procedure SetCORREO1Value(const aValue: String); virtual;
    function GetCORREO2Value: String; virtual;
    function GetOldCORREO2Value: String; virtual;
    procedure SetCORREO2Value(const aValue: String); virtual;
    function GetPAGINAWEBValue: String; virtual;
    function GetOldPAGINAWEBValue: String; virtual;
    procedure SetPAGINAWEBValue(const aValue: String); virtual;
    function GetPERSONACONTACTOValue: String; virtual;
    function GetOldPERSONACONTACTOValue: String; virtual;
    procedure SetPERSONACONTACTOValue(const aValue: String); virtual;

    { Properties }
    property CODIGOEMPRESA : Integer read GetCODIGOEMPRESAValue write SetCODIGOEMPRESAValue;
    property OldCODIGOEMPRESA : Integer read GetOldCODIGOEMPRESAValue;
    property CODIGO : Integer read GetCODIGOValue write SetCODIGOValue;
    property OldCODIGO : Integer read GetOldCODIGOValue;
    property FECHAALTA : DateTime read GetFECHAALTAValue write SetFECHAALTAValue;
    property OldFECHAALTA : DateTime read GetOldFECHAALTAValue;
    property USUARIO : String read GetUSUARIOValue write SetUSUARIOValue;
    property OldUSUARIO : String read GetOldUSUARIOValue;
    property NIFCIF : String read GetNIFCIFValue write SetNIFCIFValue;
    property OldNIFCIF : String read GetOldNIFCIFValue;
    property NOMBRE : String read GetNOMBREValue write SetNOMBREValue;
    property OldNOMBRE : String read GetOldNOMBREValue;
    property NOTAS : String read GetNOTASValue write SetNOTASValue;
    property OldNOTAS : String read GetOldNOTASValue;
    property CALLE : String read GetCALLEValue write SetCALLEValue;
    property OldCALLE : String read GetOldCALLEValue;
    property PROVINCIA : String read GetPROVINCIAValue write SetPROVINCIAValue;
    property OldPROVINCIA : String read GetOldPROVINCIAValue;
    property CODIGOPOSTAL : String read GetCODIGOPOSTALValue write SetCODIGOPOSTALValue;
    property OldCODIGOPOSTAL : String read GetOldCODIGOPOSTALValue;
    property POBLACION : String read GetPOBLACIONValue write SetPOBLACIONValue;
    property OldPOBLACION : String read GetOldPOBLACIONValue;
    property TELEFONO1 : String read GetTELEFONO1Value write SetTELEFONO1Value;
    property OldTELEFONO1 : String read GetOldTELEFONO1Value;
    property TELEFONO2 : String read GetTELEFONO2Value write SetTELEFONO2Value;
    property OldTELEFONO2 : String read GetOldTELEFONO2Value;
    property MOVIL : String read GetMOVILValue write SetMOVILValue;
    property OldMOVIL : String read GetOldMOVILValue;
    property FAX : String read GetFAXValue write SetFAXValue;
    property OldFAX : String read GetOldFAXValue;
    property CORREO1 : String read GetCORREO1Value write SetCORREO1Value;
    property OldCORREO1 : String read GetOldCORREO1Value;
    property CORREO2 : String read GetCORREO2Value write SetCORREO2Value;
    property OldCORREO2 : String read GetOldCORREO2Value;
    property PAGINAWEB : String read GetPAGINAWEBValue write SetPAGINAWEBValue;
    property OldPAGINAWEB : String read GetOldPAGINAWEBValue;
    property PERSONACONTACTO : String read GetPERSONACONTACTOValue write SetPERSONACONTACTOValue;
    property OldPERSONACONTACTO : String read GetOldPERSONACONTACTOValue;

  public
    constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
    destructor Destroy; override;

  end;

implementation

uses
  Variants, uROBinaryHelpers;

{ TCITASBusinessProcessorRules }
constructor TCITASBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
begin
  inherited;
end;

destructor TCITASBusinessProcessorRules.Destroy;
begin
  inherited;
end;

function TCITASBusinessProcessorRules.GetIDValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASID];
end;

function TCITASBusinessProcessorRules.GetOldIDValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASID];
end;

procedure TCITASBusinessProcessorRules.SetIDValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASID] := aValue;
end;

function TCITASBusinessProcessorRules.GetPARENTIDValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASPARENTID];
end;

function TCITASBusinessProcessorRules.GetOldPARENTIDValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASPARENTID];
end;

procedure TCITASBusinessProcessorRules.SetPARENTIDValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASPARENTID] := aValue;
end;

function TCITASBusinessProcessorRules.GetSTARTValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASSTART];
end;

function TCITASBusinessProcessorRules.GetOldSTARTValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASSTART];
end;

procedure TCITASBusinessProcessorRules.SetSTARTValue(const aValue: DateTime);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASSTART] := aValue;
end;

function TCITASBusinessProcessorRules.GetTIPOValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASTIPO];
end;

function TCITASBusinessProcessorRules.GetOldTIPOValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASTIPO];
end;

procedure TCITASBusinessProcessorRules.SetTIPOValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASTIPO] := aValue;
end;

function TCITASBusinessProcessorRules.GetFINISHValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASFINISH];
end;

function TCITASBusinessProcessorRules.GetOldFINISHValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASFINISH];
end;

procedure TCITASBusinessProcessorRules.SetFINISHValue(const aValue: DateTime);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASFINISH] := aValue;
end;

function TCITASBusinessProcessorRules.GetOPTIONSValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASOPTIONS];
end;

function TCITASBusinessProcessorRules.GetOldOPTIONSValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASOPTIONS];
end;

procedure TCITASBusinessProcessorRules.SetOPTIONSValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASOPTIONS] := aValue;
end;

function TCITASBusinessProcessorRules.GetCAPTIONValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCAPTION];
end;

function TCITASBusinessProcessorRules.GetOldCAPTIONValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASCAPTION];
end;

procedure TCITASBusinessProcessorRules.SetCAPTIONValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCAPTION] := aValue;
end;

function TCITASBusinessProcessorRules.GetMENSAJEValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASMENSAJE];
end;

function TCITASBusinessProcessorRules.GetOldMENSAJEValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASMENSAJE];
end;

procedure TCITASBusinessProcessorRules.SetMENSAJEValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASMENSAJE] := aValue;
end;

function TCITASBusinessProcessorRules.GetRECURRENCEINDEXValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASRECURRENCEINDEX];
end;

function TCITASBusinessProcessorRules.GetOldRECURRENCEINDEXValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASRECURRENCEINDEX];
end;

procedure TCITASBusinessProcessorRules.SetRECURRENCEINDEXValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASRECURRENCEINDEX] := aValue;
end;

function TCITASBusinessProcessorRules.GetRESOURCEIDValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASRESOURCEID];
end;

function TCITASBusinessProcessorRules.GetOldRESOURCEIDValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASRESOURCEID];
end;

procedure TCITASBusinessProcessorRules.SetRESOURCEIDValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASRESOURCEID] := aValue;
end;

function TCITASBusinessProcessorRules.GetLOCATIONValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASLOCATION];
end;

function TCITASBusinessProcessorRules.GetOldLOCATIONValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASLOCATION];
end;

procedure TCITASBusinessProcessorRules.SetLOCATIONValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASLOCATION] := aValue;
end;

function TCITASBusinessProcessorRules.GetREMINDERValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASREMINDER];
end;

function TCITASBusinessProcessorRules.GetOldREMINDERValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASREMINDER];
end;

procedure TCITASBusinessProcessorRules.SetREMINDERValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASREMINDER] := aValue;
end;

function TCITASBusinessProcessorRules.GetSTATEValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASSTATE];
end;

function TCITASBusinessProcessorRules.GetOldSTATEValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASSTATE];
end;

procedure TCITASBusinessProcessorRules.SetSTATEValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASSTATE] := aValue;
end;

function TCITASBusinessProcessorRules.GetLABELCOLORValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASLABELCOLOR];
end;

function TCITASBusinessProcessorRules.GetOldLABELCOLORValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASLABELCOLOR];
end;

procedure TCITASBusinessProcessorRules.SetLABELCOLORValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASLABELCOLOR] := aValue;
end;

function TCITASBusinessProcessorRules.GetCODIGOCONTRATOValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCODIGOCONTRATO];
end;

function TCITASBusinessProcessorRules.GetOldCODIGOCONTRATOValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASCODIGOCONTRATO];
end;

procedure TCITASBusinessProcessorRules.SetCODIGOCONTRATOValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCODIGOCONTRATO] := aValue;
end;

function TCITASBusinessProcessorRules.GetTIPOTAREAValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASTIPOTAREA];
end;

function TCITASBusinessProcessorRules.GetOldTIPOTAREAValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASTIPOTAREA];
end;

procedure TCITASBusinessProcessorRules.SetTIPOTAREAValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASTIPOTAREA] := aValue;
end;

function TCITASBusinessProcessorRules.GetNOMBRECLIENTEValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASNOMBRECLIENTE];
end;

function TCITASBusinessProcessorRules.GetOldNOMBRECLIENTEValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASNOMBRECLIENTE];
end;

procedure TCITASBusinessProcessorRules.SetNOMBRECLIENTEValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASNOMBRECLIENTE] := aValue;
end;

function TCITASBusinessProcessorRules.GetPARTIDAValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASPARTIDA];
end;

function TCITASBusinessProcessorRules.GetOldPARTIDAValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASPARTIDA];
end;

procedure TCITASBusinessProcessorRules.SetPARTIDAValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASPARTIDA] := aValue;
end;

function TCITASBusinessProcessorRules.GetCOMPLETADAValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCOMPLETADA];
end;

function TCITASBusinessProcessorRules.GetOldCOMPLETADAValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASCOMPLETADA];
end;

procedure TCITASBusinessProcessorRules.SetCOMPLETADAValue(const aValue: DateTime);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCOMPLETADA] := aValue;
end;

function TCITASBusinessProcessorRules.GetNOMBREPROVEEDORValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASNOMBREPROVEEDOR];
end;

function TCITASBusinessProcessorRules.GetOldNOMBREPROVEEDORValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASNOMBREPROVEEDOR];
end;

procedure TCITASBusinessProcessorRules.SetNOMBREPROVEEDORValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASNOMBREPROVEEDOR] := aValue;
end;

function TCITASBusinessProcessorRules.GetCODIGOCOLUMNAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCODIGOCOLUMNA];
end;

function TCITASBusinessProcessorRules.GetOldCODIGOCOLUMNAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASCODIGOCOLUMNA];
end;

procedure TCITASBusinessProcessorRules.SetCODIGOCOLUMNAValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCODIGOCOLUMNA] := aValue;
end;

function TCITASBusinessProcessorRules.GetCODIGOFILAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCODIGOFILA];
end;

function TCITASBusinessProcessorRules.GetOldCODIGOFILAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASCODIGOFILA];
end;

procedure TCITASBusinessProcessorRules.SetCODIGOFILAValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASCODIGOFILA] := aValue;
end;

function TCITASBusinessProcessorRules.GetEMPRESAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_CITASEMPRESA];
end;

function TCITASBusinessProcessorRules.GetOldEMPRESAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_CITASEMPRESA];
end;

procedure TCITASBusinessProcessorRules.SetEMPRESAValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_CITASEMPRESA] := aValue;
end;


{ TVENDEDORESBusinessProcessorRules }
constructor TVENDEDORESBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
begin
  inherited;
end;

destructor TVENDEDORESBusinessProcessorRules.Destroy;
begin
  inherited;
end;

function TVENDEDORESBusinessProcessorRules.GetCODIGOEMPRESAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCODIGOEMPRESA];
end;

function TVENDEDORESBusinessProcessorRules.GetOldCODIGOEMPRESAValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESCODIGOEMPRESA];
end;

procedure TVENDEDORESBusinessProcessorRules.SetCODIGOEMPRESAValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCODIGOEMPRESA] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetCODIGOValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCODIGO];
end;

function TVENDEDORESBusinessProcessorRules.GetOldCODIGOValue: Integer;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESCODIGO];
end;

procedure TVENDEDORESBusinessProcessorRules.SetCODIGOValue(const aValue: Integer);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCODIGO] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetFECHAALTAValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESFECHAALTA];
end;

function TVENDEDORESBusinessProcessorRules.GetOldFECHAALTAValue: DateTime;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESFECHAALTA];
end;

procedure TVENDEDORESBusinessProcessorRules.SetFECHAALTAValue(const aValue: DateTime);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESFECHAALTA] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetUSUARIOValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESUSUARIO];
end;

function TVENDEDORESBusinessProcessorRules.GetOldUSUARIOValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESUSUARIO];
end;

procedure TVENDEDORESBusinessProcessorRules.SetUSUARIOValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESUSUARIO] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetNIFCIFValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESNIFCIF];
end;

function TVENDEDORESBusinessProcessorRules.GetOldNIFCIFValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESNIFCIF];
end;

procedure TVENDEDORESBusinessProcessorRules.SetNIFCIFValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESNIFCIF] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetNOMBREValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESNOMBRE];
end;

function TVENDEDORESBusinessProcessorRules.GetOldNOMBREValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESNOMBRE];
end;

procedure TVENDEDORESBusinessProcessorRules.SetNOMBREValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESNOMBRE] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetNOTASValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESNOTAS];
end;

function TVENDEDORESBusinessProcessorRules.GetOldNOTASValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESNOTAS];
end;

procedure TVENDEDORESBusinessProcessorRules.SetNOTASValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESNOTAS] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetCALLEValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCALLE];
end;

function TVENDEDORESBusinessProcessorRules.GetOldCALLEValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESCALLE];
end;

procedure TVENDEDORESBusinessProcessorRules.SetCALLEValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCALLE] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetPROVINCIAValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPROVINCIA];
end;

function TVENDEDORESBusinessProcessorRules.GetOldPROVINCIAValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESPROVINCIA];
end;

procedure TVENDEDORESBusinessProcessorRules.SetPROVINCIAValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPROVINCIA] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetCODIGOPOSTALValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCODIGOPOSTAL];
end;

function TVENDEDORESBusinessProcessorRules.GetOldCODIGOPOSTALValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESCODIGOPOSTAL];
end;

procedure TVENDEDORESBusinessProcessorRules.SetCODIGOPOSTALValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCODIGOPOSTAL] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetPOBLACIONValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPOBLACION];
end;

function TVENDEDORESBusinessProcessorRules.GetOldPOBLACIONValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESPOBLACION];
end;

procedure TVENDEDORESBusinessProcessorRules.SetPOBLACIONValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPOBLACION] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetTELEFONO1Value: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESTELEFONO1];
end;

function TVENDEDORESBusinessProcessorRules.GetOldTELEFONO1Value: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESTELEFONO1];
end;

procedure TVENDEDORESBusinessProcessorRules.SetTELEFONO1Value(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESTELEFONO1] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetTELEFONO2Value: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESTELEFONO2];
end;

function TVENDEDORESBusinessProcessorRules.GetOldTELEFONO2Value: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESTELEFONO2];
end;

procedure TVENDEDORESBusinessProcessorRules.SetTELEFONO2Value(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESTELEFONO2] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetMOVILValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESMOVIL];
end;

function TVENDEDORESBusinessProcessorRules.GetOldMOVILValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESMOVIL];
end;

procedure TVENDEDORESBusinessProcessorRules.SetMOVILValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESMOVIL] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetFAXValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESFAX];
end;

function TVENDEDORESBusinessProcessorRules.GetOldFAXValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESFAX];
end;

procedure TVENDEDORESBusinessProcessorRules.SetFAXValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESFAX] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetCORREO1Value: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCORREO1];
end;

function TVENDEDORESBusinessProcessorRules.GetOldCORREO1Value: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESCORREO1];
end;

procedure TVENDEDORESBusinessProcessorRules.SetCORREO1Value(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCORREO1] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetCORREO2Value: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCORREO2];
end;

function TVENDEDORESBusinessProcessorRules.GetOldCORREO2Value: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESCORREO2];
end;

procedure TVENDEDORESBusinessProcessorRules.SetCORREO2Value(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESCORREO2] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetPAGINAWEBValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPAGINAWEB];
end;

function TVENDEDORESBusinessProcessorRules.GetOldPAGINAWEBValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESPAGINAWEB];
end;

procedure TVENDEDORESBusinessProcessorRules.SetPAGINAWEBValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPAGINAWEB] := aValue;
end;

function TVENDEDORESBusinessProcessorRules.GetPERSONACONTACTOValue: String;
begin
  result := BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPERSONACONTACTO];
end;

function TVENDEDORESBusinessProcessorRules.GetOldPERSONACONTACTOValue: String;
begin
  result := BusinessProcessor.CurrentChange.OldValueByName[fld_VENDEDORESPERSONACONTACTO];
end;

procedure TVENDEDORESBusinessProcessorRules.SetPERSONACONTACTOValue(const aValue: String);
begin
  BusinessProcessor.CurrentChange.NewValueByName[fld_VENDEDORESPERSONACONTACTO] := aValue;
end;


initialization
  RegisterBusinessProcessorRules(RID_CITASDelta, TCITASBusinessProcessorRules);
  RegisterBusinessProcessorRules(RID_VENDEDORESDelta, TVENDEDORESBusinessProcessorRules);

end.
