This repository has been archived on 2024-11-28. You can view files and clone it, but cannot push or open issues or pull requests.
LuisLeon_FactuGES2/Source/Modulos/Contactos/Model/uBizAgentesObjetivosFacturas.pas

45 lines
1008 B
ObjectPascal

unit uBizAgentesObjetivosFacturas;
interface
uses
uDAInterfaces, uDADataTable,
schContactosClient_Intf;
const
BIZ_CLIENT_AGENTE_OBJETIVOS_FAC = 'Client.AgenteObjetivosFacturas';
type
IBizAgentesObjetivosFacturas = interface (IAgentes_Objetivos_facturas)
['{0063F6E3-D218-49BE-B4C0-96E1EE7A45A5}']
end;
TBizAgentesObjetivosFacturas = class(TAgentes_Objetivos_FacturasDataTableRules, IBizAgentesObjetivosFacturas)
protected
procedure BeforeInsert(Sender: TDADataTable); override;
end;
implementation
{ TBizAgentesObjetivosFacturas }
uses
DB;
procedure TBizAgentesObjetivosFacturas.BeforeInsert(Sender: TDADataTable);
var
AMasterTable : TDADataTable;
begin
inherited;
AMasterTable := DataTable.GetMasterDataTable;
if Assigned(AMasterTable) and (AMasterTable.State in dsEditModes) then
AMasterTable.Post;
end;
initialization
RegisterDataTableRules(BIZ_CLIENT_AGENTE_OBJETIVOS_FAC, TBizAgentesObjetivosFacturas);
end.