git-svn-id: https://192.168.0.254/svn/Proyectos.LuisLeon_FactuGES/tags/1.2.0@6 c93665c3-c93d-084d-9b98-7d5f4a9c3376
78 lines
2.6 KiB
ObjectPascal
78 lines
2.6 KiB
ObjectPascal
unit srvFamilias_Impl;
|
|
|
|
{----------------------------------------------------------------------------}
|
|
{ This unit was automatically generated by the RemObjects SDK after reading }
|
|
{ the RODL file associated with this project . }
|
|
{ }
|
|
{ This is where you are supposed to code the implementation of your objects. }
|
|
{----------------------------------------------------------------------------}
|
|
|
|
interface
|
|
|
|
uses
|
|
{vcl:} Classes, SysUtils,
|
|
{RemObjects:} uROClientIntf, uROTypes, uROServer, uROServerIntf, uROSessions,
|
|
{Ancestor Implementation:} DARemoteService_Impl,
|
|
{Used RODLs:} DataAbstract_Intf,
|
|
{Generated:} FactuGES_Intf, uDADataTable, uDABINAdapter, uDAClasses,
|
|
uDAScriptingProvider, uDABusinessProcessor, uDAInterfaces;
|
|
|
|
type
|
|
{ TsrvFamilias }
|
|
TsrvFamilias = class(TDARemoteService, IsrvFamilias)
|
|
Diagrams: TDADiagrams;
|
|
DABINAdapter: TDABINAdapter;
|
|
schFamilias: TDASchema;
|
|
DataDictionary: TDADataDictionary;
|
|
procedure DARemoteServiceBeforeAcquireConnection(Sender: TDARemoteService;
|
|
var ConnectionName: string);
|
|
procedure DARemoteServiceAfterGetDatasetData(const Dataset: IDADataset;
|
|
const IncludeSchema: Boolean; const MaxRecords: Integer);
|
|
procedure DARemoteServiceCreate(Sender: TObject);
|
|
{ IsrvFamilias methods }
|
|
end;
|
|
|
|
implementation
|
|
|
|
{$R *.dfm}
|
|
uses
|
|
{Generated:} FactuGES_Invk, uDataModuleServer,
|
|
uDatabaseUtils, schFamiliasClient_Intf, uRestriccionesUsuarioUtils;
|
|
|
|
procedure Create_srvFamilias(out anInstance : IUnknown);
|
|
begin
|
|
anInstance := TsrvFamilias.Create(NIL);
|
|
end;
|
|
|
|
{ srvFamilias }
|
|
procedure TsrvFamilias.DARemoteServiceAfterGetDatasetData(
|
|
const Dataset: IDADataset; const IncludeSchema: Boolean;
|
|
const MaxRecords: Integer);
|
|
begin
|
|
if DataSet.Name = nme_Familias then
|
|
begin
|
|
{ Aquí se asegura que el usuario sólo accede a los almacenes
|
|
de las empresas a las que tiene permiso para acceder
|
|
filtrando DataSet por ID_EMPRESA. }
|
|
// FiltrarAccesoUsuario(Session, Connection, schAlmacenes, DataSet, fld_AlmacenesID_EMPRESA);
|
|
end;
|
|
end;
|
|
|
|
procedure TsrvFamilias.DARemoteServiceBeforeAcquireConnection(
|
|
Sender: TDARemoteService; var ConnectionName: string);
|
|
begin
|
|
ConnectionName := dmServer.ConnectionName;
|
|
end;
|
|
|
|
procedure TsrvFamilias.DARemoteServiceCreate(Sender: TObject);
|
|
begin
|
|
SessionManager := dmServer.SessionManager;
|
|
end;
|
|
|
|
initialization
|
|
TROClassFactory.Create('srvFamilias', Create_srvFamilias, TsrvFamilias_Invoker);
|
|
|
|
finalization
|
|
|
|
end.
|