uFactuGES_App.pas -> Limpieza de código

git-svn-id: https://192.168.0.254/svn/Proyectos.Acana_FactuGES2/trunk@298 f4e31baf-9722-1c47-927c-6f952f962d4b
This commit is contained in:
David Arranz 2008-07-29 15:54:03 +00:00
parent da135bbbc2
commit bc9ba0bcf4

View File

@ -75,23 +75,12 @@ type
property Terminated : Boolean read GetTerminated;
property Configuracion : IConfiguracionController read GetConfiguracionController;
{ function getVAR_IDTIENDA : Integer;
procedure setVAR_IDTIENDA (AValue : Integer);
function getVAR_TIENDA : String;
procedure setVAR_TIENDA (AValue : String);
property VAR_IDTIENDA: Integer read getVAR_IDTIENDA write SetVAR_IDTIENDA;
property VAR_TIENDA: String read getVAR_TIENDA write setVAR_TIENDA;}
procedure ShowCapado;
end;
TAppFactuGES = class(TInterfacedObject, IAppFactuGES)
private
FVAR_IDTIENDA: Integer;
FVAR_TIENDA: String;
FEmpresasController : IEmpresasController;
FUsuariosController: IUsuariosController;
FEmpresaActiva: IBizEmpresa;
@ -141,7 +130,6 @@ type
procedure UpdateSplashForm;
public
constructor Create; virtual;
destructor Destroy; override;
@ -171,14 +159,6 @@ type
property Terminated : Boolean read GetTerminated;
property Configuracion : IConfiguracionController read GetConfiguracionController;
function getVAR_IDTIENDA : Integer;
procedure setVAR_IDTIENDA (AValue : Integer);
function getVAR_TIENDA : String;
procedure setVAR_TIENDA (AValue : String);
property VAR_IDTIENDA: Integer read getVAR_IDTIENDA write setVAR_IDTIENDA;
property VAR_TIENDA: String read getVAR_TIENDA write setVAR_TIENDA;
procedure ShowCapado;
end;
@ -257,14 +237,16 @@ begin
end;
procedure TAppFactuGES.BuscarTiendaPorDefecto;
var
AIDTienda : IBizEmpresaTienda;
begin
//Nos devuelve el id de la tienda a la que pertenece el vendedor que tiene asignado
//el usuario con el que ha accedido a la aplicación.
//Esto funciona mientras la relación sea 1 a 1, cuando sea 1 a n (un usuario pertenece a varios vendedores deja de funcionar)
FTiendaActiva := EmpresasController.DarTiendaUsuario(EmpresaActiva, UsuarioActivo.ID);
FTiendaActiva.DataTable.Open;
Assert(Assigned(FTiendaActiva));
if Assigned(FTiendaActiva) then
FTiendaActiva.DataTable.Open;
end;
constructor TAppFactuGES.Create;
@ -298,7 +280,10 @@ begin
FConfiguracionController := NIL;
FTiendaActiva := NIL;
FEjercicioActivo := NIL;
FEmpresaActiva := NIL;
FUsuariosController := NIL;
FEmpresasController := NIL;
@ -399,16 +384,6 @@ begin
Result := FUsuariosController;
end;
function TAppFactuGES.getVAR_IDTIENDA: Integer;
begin
Result := FVAR_IDTIENDA;
end;
function TAppFactuGES.getVAR_TIENDA: String;
begin
Result := FVAR_TIENDA;
end;
procedure TAppFactuGES.HideSplashForm;
begin
if Assigned(FAppSplashForm) then
@ -463,7 +438,7 @@ begin
FDoLoadModulesEvent := ALoadModulesEvent;
end;
procedure TAppFactuGES.setVAR_IDTIENDA(AValue: Integer);
{procedure TAppFactuGES.setVAR_IDTIENDA(AValue: Integer);
begin
FVAR_IDTIENDA := Avalue;
end;
@ -471,7 +446,7 @@ end;
procedure TAppFactuGES.setVAR_TIENDA(AValue: String);
begin
FVAR_TIENDA := Avalue;
end;
end;}
procedure TAppFactuGES.ShowCapado;
begin