diff --git a/Source/ApplicationBase/ApplicationBase.dpk b/Source/ApplicationBase/ApplicationBase.dpk
index e90d3289..99a906ee 100644
--- a/Source/ApplicationBase/ApplicationBase.dpk
+++ b/Source/ApplicationBase/ApplicationBase.dpk
@@ -65,8 +65,6 @@ contains
uEditorEmpresa in 'Empresas\Views\uEditorEmpresa.pas' {fEditorEmpresa: TCustomEditor},
uEmpresasViewRegister in 'Empresas\Views\uEmpresasViewRegister.pas',
uViewDatosBancarios in 'Empresas\Views\uViewDatosBancarios.pas' {frViewDatosBancarios: TCustomView},
- schUsuariosServer_Intf in 'Usuarios\Model\schUsuariosServer_Intf.pas',
- schUsuariosClient_Intf in 'Usuarios\Model\schUsuariosClient_Intf.pas',
uIEditorLogin in 'Usuarios\Controller\View\uIEditorLogin.pas',
uEditorLogin in 'Usuarios\Views\uEditorLogin.pas' {fEditorLogin: TCustomEditor},
uUsuariosViewRegister in 'Usuarios\Views\uUsuariosViewRegister.pas',
@@ -109,6 +107,8 @@ contains
uViewConfiguracionBase in 'Configuracion\Views\uViewConfiguracionBase.pas' {frViewConfiguracionBase: TCustomView},
uEditorConfiguracion in 'Configuracion\Views\uEditorConfiguracion.pas' {fConfiguracionEditor},
uViewConfiguracionGeneral in 'Configuracion\Views\uViewConfiguracionGeneral.pas' {frViewConfiguracionGeneral: TFrame},
- uIViewConfiguracionBase in 'Configuracion\Controller\Views\uIViewConfiguracionBase.pas';
+ uIViewConfiguracionBase in 'Configuracion\Controller\Views\uIViewConfiguracionBase.pas',
+ schUsuariosClient_Intf in 'Usuarios\Model\schUsuariosClient_Intf.pas',
+ schUsuariosServer_Intf in 'Usuarios\Model\schUsuariosServer_Intf.pas';
end.
diff --git a/Source/ApplicationBase/ApplicationBase.dproj b/Source/ApplicationBase/ApplicationBase.dproj
index c92ec926..be86c29a 100644
--- a/Source/ApplicationBase/ApplicationBase.dproj
+++ b/Source/ApplicationBase/ApplicationBase.dproj
@@ -46,15 +46,6 @@
Package
FalseTrueFalseFalseFalseFalseTrueFalse1000FalseFalseFalseFalseFalse308212521.0.0.01.0.0.0
-
-
-
-
-
-
-
-
-
RemObjects Data Abstract - SQLite Driver
Microsoft Office 2000 Sample Automation Server Wrapper Components
Microsoft Office XP Sample Automation Server Wrapper Components
@@ -65,22 +56,6 @@
MainSource
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
@@ -179,10 +154,26 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
TCustomEditor
diff --git a/Source/ApplicationBase/Empresas/Controller/View/uIEditorTiendaEmpresa.pas b/Source/ApplicationBase/Empresas/Controller/View/uIEditorTiendaEmpresa.pas
index ffb2d8bb..133625ed 100644
--- a/Source/ApplicationBase/Empresas/Controller/View/uIEditorTiendaEmpresa.pas
+++ b/Source/ApplicationBase/Empresas/Controller/View/uIEditorTiendaEmpresa.pas
@@ -13,9 +13,9 @@ type
procedure SetController (const Value : ITiendasEmpresaController);
property Controller : ITiendasEmpresaController read GetController write SetController;
- function GetTienda: IBizEmpresasTiendas;
- procedure SetTienda(const Value: IBizEmpresasTiendas);
- property Tienda: IBizEmpresasTiendas read GetTienda write SetTienda;
+ function GetTienda: IBizEmpresaTienda;
+ procedure SetTienda(const Value: IBizEmpresaTienda);
+ property Tienda: IBizEmpresaTienda read GetTienda write SetTienda;
function ShowModal : Integer;
procedure Release;
diff --git a/Source/ApplicationBase/Empresas/Controller/uEmpresasController.pas b/Source/ApplicationBase/Empresas/Controller/uEmpresasController.pas
index d07a6d97..06471ca7 100644
--- a/Source/ApplicationBase/Empresas/Controller/uEmpresasController.pas
+++ b/Source/ApplicationBase/Empresas/Controller/uEmpresasController.pas
@@ -5,7 +5,8 @@ interface
uses
Windows, Forms, Classes, Controls, Contnrs, SysUtils,
- uBizEmpresas, uIDataModuleEmpresas, uDADataTable, uControllerBase;
+ uBizEmpresas, uIDataModuleEmpresas, uDADataTable, uControllerBase,
+ uBizEmpresasTiendas, uTiendasEmpresaController;
type
IEmpresasController = interface(IControllerBase)
@@ -24,19 +25,25 @@ type
function ToStringList(AEmpresa : IBizEmpresa) : TStringList;
function DarListaTiendas(AEmpresa : IBizEmpresa): TStringList;
+ function DarTiendaUsuario(AEmpresa: IBizEmpresa; const ID_USUARIO: Integer): IBizEmpresaTienda;
+
+ function GetTiendasController : ITiendasEmpresaController;
+ property TiendasController : ITiendasEmpresaController read GetTiendasController;
end;
TEmpresasController = class(TControllerBase, IEmpresasController)
protected
FDataModule : IDataModuleEmpresas;
+ FTiendasController : ITiendasEmpresaController;
function ValidarEmpresa(AEmpresa : IBizEmpresa): Boolean; virtual;
+ function GetTiendasController : ITiendasEmpresaController;
public
constructor Create; override;
destructor Destroy; override;
function Eliminar(const ID : Integer): Boolean; overload;
- function Eliminar(AEmpresa : IBizEmpresa): Boolean; overload;
- function Guardar(AEmpresa : IBizEmpresa): Boolean;
+ function Eliminar(AEmpresa : IBizEmpresa): Boolean; overload;
+ function Guardar(AEmpresa : IBizEmpresa): Boolean;
procedure DescartarCambios(AEmpresa : IBizEmpresa); virtual;
function Existe(const ID: Integer) : Boolean; virtual;
procedure Anadir(AEmpresa : IBizEmpresa); virtual;
@@ -48,14 +55,17 @@ type
procedure VerTodos(AEmpresas: IBizEmpresa); virtual;
function ToStringList(AEmpresa : IBizEmpresa) : TStringList; virtual;
- function DarListaTiendas(AEmpresa : IBizEmpresa): TStringList;
+ function DarListaTiendas(AEmpresa : IBizEmpresa): TStringList;
+ function DarTiendaUsuario(AEmpresa: IBizEmpresa; const ID_USUARIO: Integer): IBizEmpresaTienda;
+
+ property TiendasController : ITiendasEmpresaController read GetTiendasController;
end;
implementation
uses
- uEditorRegistryUtils, cxControls, DB, uFactuGES_App,
- uDataModuleEmpresas, uIEditorEmpresa, uBizEmpresasTiendas;
+ uEditorRegistryUtils, cxControls, DB, uFactuGES_App,
+ uDataModuleEmpresas, uIEditorEmpresa;
{ TEmpresasController }
@@ -78,12 +88,13 @@ constructor TEmpresasController.Create;
begin
inherited;
FDataModule := TDataModuleEmpresas.Create(Nil);
+ FTiendasController := TTiendasEmpresaController.Create;
end;
function TEmpresasController.DarListaTiendas(
AEmpresa: IBizEmpresa): TStringList;
var
- ATiendas: IBizEmpresasTiendas;
+ ATiendas: IBizEmpresaTienda;
begin
if not Assigned(AEmpresa) then
raise Exception.Create ('Empresa no asignada (DarListaTiendas)');
@@ -109,6 +120,14 @@ begin
end;
end;
+function TEmpresasController.DarTiendaUsuario(AEmpresa: IBizEmpresa; const ID_USUARIO: Integer): IBizEmpresaTienda;
+var
+ AIDTienda : Integer;
+begin
+ AIDTienda := FDataModule.DarTiendaUsuario(AEmpresa.ID, ID_USUARIO);
+ Result := FTiendasController.Buscar(AIDTienda);
+end;
+
procedure TEmpresasController.DescartarCambios(AEmpresa: IBizEmpresa);
begin
if not Assigned(AEmpresa) then
@@ -128,6 +147,7 @@ end;
destructor TEmpresasController.Destroy;
begin
FDataModule := NIL;
+ FTiendasController := NIL;
inherited;
end;
@@ -175,6 +195,11 @@ begin
end;
end;
+function TEmpresasController.GetTiendasController: ITiendasEmpresaController;
+begin
+ Result := FTiendasController;
+end;
+
function TEmpresasController.Guardar(AEmpresa: IBizEmpresa): Boolean;
begin
Result := False;
@@ -256,11 +281,10 @@ procedure TEmpresasController.VerTodos(AEmpresas: IBizEmpresa);
{var
AEditor : IEditorEmpresas;}
begin
-{
- AEditor := NIL;
+{ AEditor := NIL;
ShowHourglassCursor;
try
- CreateEditor('EditorEmpresas', IEditorClientes, AEditor);
+ CreateEditor('EditorEmpresas', IEditorEmpresas, AEditor);
if Assigned(AEditor) then
with AEditor do
begin
@@ -271,8 +295,7 @@ begin
finally
AEditor := NIL;
HideHourglassCursor;
- end;
-}
+ end;}
end;
end.
diff --git a/Source/ApplicationBase/Empresas/Controller/uTiendasEmpresaController.pas b/Source/ApplicationBase/Empresas/Controller/uTiendasEmpresaController.pas
index 5042c039..4c3efdbb 100644
--- a/Source/ApplicationBase/Empresas/Controller/uTiendasEmpresaController.pas
+++ b/Source/ApplicationBase/Empresas/Controller/uTiendasEmpresaController.pas
@@ -9,18 +9,22 @@ uses
type
ITiendasEmpresaController = interface(IControllerBase)
['{5DCF4163-7FA0-4560-9E5E-FA2A99EA4F59}']
- procedure VerTienda(ATienda : IBizEmpresasTiendas);
- function DarListaTiendas: TStringList;
+ function Buscar(const ID: Integer): IBizEmpresaTienda;
+ function BuscarTodas: IBizEmpresaTienda;
+ procedure Ver(ATienda : IBizEmpresaTienda);
+ function Nueva : IBizEmpresaTienda;
end;
TTiendasEmpresaController = class(TControllerBase, ITiendasEmpresaController)
private
FDataModule : IDataModuleEmpresas;
public
- procedure VerTienda(ATienda : IBizEmpresasTiendas);
- function DarListaTiendas: TStringList;
constructor Create; override;
destructor Destroy; override;
+ function Buscar(const ID: Integer): IBizEmpresaTienda;
+ function BuscarTodas: IBizEmpresaTienda;
+ procedure Ver(ATienda : IBizEmpresaTienda);
+ function Nueva : IBizEmpresaTienda;
end;
implementation
@@ -31,44 +35,34 @@ uses
uDataModuleEmpresas, schEmpresasClient_Intf, uIEditorTiendaEmpresa,
uEditorRegistryUtils, cxControls, uFactuGES_App;
+function TTiendasEmpresaController.Buscar(const ID: Integer): IBizEmpresaTienda;
+begin
+ Result := FDataModule.GetTienda(ID);
+end;
+
+function TTiendasEmpresaController.BuscarTodas: IBizEmpresaTienda;
+begin
+ Result := FDataModule.GetTiendas;
+end;
+
constructor TTiendasEmpresaController.Create;
begin
inherited;
FDataModule := TDataModuleEmpresas.Create(Nil);
end;
-function TTiendasEmpresaController.DarListaTiendas: TStringList;
-var
- ATiendas: IBizEmpresasTiendas;
-begin
- ATiendas := AppFactuGES.EmpresaActiva.Tiendas;
- ATiendas.DataTable.Active := True;
-
- Result := TStringList.Create;
- try
- with Result do
- begin
- Add(Format('%s=%d', [CTE_TODAS, CTE_ID_TODAS]));
-
- ATiendas.DataTable.First;
- while not ATiendas.DataTable.EOF do
- begin
- Add(Format('%s=%d', [ATiendas.NOMBRE, ATiendas.ID]));
- ATiendas.DataTable.Next;
- end;
- end;
- finally
- ATiendas := NIL;
- end;
-end;
-
destructor TTiendasEmpresaController.Destroy;
begin
FDataModule := Nil;
inherited;
end;
-procedure TTiendasEmpresaController.VerTienda(ATienda: IBizEmpresasTiendas);
+function TTiendasEmpresaController.Nueva: IBizEmpresaTienda;
+begin
+ Result := FDataModule.NewTienda;
+end;
+
+procedure TTiendasEmpresaController.Ver(ATienda: IBizEmpresaTienda);
var
AEditor : IEditorTiendaEmpresa;
begin
diff --git a/Source/ApplicationBase/Empresas/Data/uDataModuleEmpresas.pas b/Source/ApplicationBase/Empresas/Data/uDataModuleEmpresas.pas
index f9a94bba..576e396d 100644
--- a/Source/ApplicationBase/Empresas/Data/uDataModuleEmpresas.pas
+++ b/Source/ApplicationBase/Empresas/Data/uDataModuleEmpresas.pas
@@ -2,7 +2,7 @@ unit uDataModuleEmpresas;
interface
-uses {vcl:} SysUtils, Classes, DB, DBClient,
+uses {vcl:} SysUtils, Classes, DB, DBClient,
{RemObjects:} uDADataTable, uDAScriptingProvider,
uDACDSDataTable, uDABINAdapter, uRORemoteService,
uROClient, uROBinMessage, uROWinInetHttpChannel, uDADesigntimeCall,
@@ -25,11 +25,15 @@ type
procedure DAClientDataModuleCreate(Sender: TObject);
private
function _GetDatosBancarios : IBizEmpresasDatosBancarios;
- function _GetTiendas : IBizEmpresasTiendas;
public
function GetItem(const ID : Integer) : IBizEmpresa;
function NewItem : IBizEmpresa;
function GetItems : IBizEmpresa;
+ function DarTiendaUsuario(const ID_EMPRESA: Integer; const ID_USUARIO: Integer): Integer;
+
+ function NewTienda : IBizEmpresaTienda;
+ function GetTiendas : IBizEmpresaTienda;
+ function GetTienda(const ID : Integer) : IBizEmpresaTienda;
end;
implementation
@@ -46,6 +50,12 @@ begin
RORemoteService.Message := dmConexion.Message;
end;
+function TDataModuleEmpresas.DarTiendaUsuario(const ID_EMPRESA,
+ ID_USUARIO: Integer): Integer;
+begin
+ Result := (RORemoteService as IsrvEmpresas).DarTiendaUsuario(ID_EMPRESA, ID_USUARIO)
+end;
+
function TDataModuleEmpresas.GetItem(const ID: Integer): IBizEmpresa;
begin
ShowHourglassCursor;
@@ -75,7 +85,7 @@ begin
with TBizEmpresa(AEmpresa.BusinessEventsObj) do
begin
DatosBancarios := _GetDatosBancarios;
- Tiendas := _GetTiendas;
+ Tiendas := GetTiendas;
end;
Result := (AEmpresa as IBizEmpresa);
@@ -89,6 +99,11 @@ begin
Result := GetItem(ID_NULO)
end;
+function TDataModuleEmpresas.NewTienda: IBizEmpresaTienda;
+begin
+ Result := GetTienda(ID_NULO);
+end;
+
function TDataModuleEmpresas._GetDatosBancarios: IBizEmpresasDatosBancarios;
var
ADatosBancarios : TDAMemDataTable;
@@ -108,7 +123,24 @@ begin
end;
end;
-function TDataModuleEmpresas._GetTiendas: IBizEmpresasTiendas;
+function TDataModuleEmpresas.GetTienda(const ID: Integer): IBizEmpresaTienda;
+begin
+ ShowHourglassCursor;
+ try
+ Result := Self.GetTiendas;
+
+ with Result.DataTable.DynamicWhere do
+ begin
+ Clear;
+ // (ID = :ID)
+ Expression := NewBinaryExpression(NewField('', fld_EmpresasTiendasID), NewConstant(ID, datInteger), dboEqual);
+ end;
+ finally
+ HideHourglassCursor;
+ end;
+end;
+
+function TDataModuleEmpresas.GetTiendas: IBizEmpresaTienda;
var
ATiendas : TDAMemDataTable;
begin
@@ -121,7 +153,7 @@ begin
DetailOptions := DetailOptions -
[dtDisableLogOfCascadeDeletes, dtDisableLogOfCascadeUpdates];
end;
- Result := (ATiendas as IBizEmpresasTiendas);
+ Result := (ATiendas as IBizEmpresaTienda);
finally
HideHourglassCursor;
end;
diff --git a/Source/ApplicationBase/Empresas/Model/Data/uIDataModuleEmpresas.pas b/Source/ApplicationBase/Empresas/Model/Data/uIDataModuleEmpresas.pas
index e87571fa..2e8daf85 100644
--- a/Source/ApplicationBase/Empresas/Model/Data/uIDataModuleEmpresas.pas
+++ b/Source/ApplicationBase/Empresas/Model/Data/uIDataModuleEmpresas.pas
@@ -3,8 +3,7 @@ unit uIDataModuleEmpresas;
interface
uses
- SysUtils, Classes,
- uBizEmpresas;
+ SysUtils, Classes, uBizEmpresas, uBizEmpresasTiendas;
type
IDataModuleEmpresas = interface
@@ -12,6 +11,12 @@ type
function GetItem(const ID : Integer) : IBizEmpresa;
function NewItem : IBizEmpresa;
function GetItems : IBizEmpresa;
+
+ function NewTienda : IBizEmpresaTienda;
+ function GetTienda(const ID : Integer) : IBizEmpresaTienda;
+ function GetTiendas : IBizEmpresaTienda;
+
+ function DarTiendaUsuario(const ID_EMPRESA: Integer; const ID_USUARIO: Integer): Integer;
end;
implementation
diff --git a/Source/ApplicationBase/Empresas/Model/uBizEmpresas.pas b/Source/ApplicationBase/Empresas/Model/uBizEmpresas.pas
index 36880993..07eb1006 100644
Binary files a/Source/ApplicationBase/Empresas/Model/uBizEmpresas.pas and b/Source/ApplicationBase/Empresas/Model/uBizEmpresas.pas differ
diff --git a/Source/ApplicationBase/Empresas/Model/uBizEmpresasTiendas.pas b/Source/ApplicationBase/Empresas/Model/uBizEmpresasTiendas.pas
index fc99c844..2b07053b 100644
--- a/Source/ApplicationBase/Empresas/Model/uBizEmpresasTiendas.pas
+++ b/Source/ApplicationBase/Empresas/Model/uBizEmpresasTiendas.pas
@@ -7,17 +7,17 @@ uses
schEmpresasClient_Intf;
const
- BIZ_CLIENT_EMPRESAS_TIENDAS = 'Client.EmpresasTiendas';
+ BIZ_CLIENT_EMPRESAS_TIENDAS = 'Client.EmpresaTienda';
CTE_ID_TODAS = 0;
CTE_TODAS = 'Todas';
type
- IBizEmpresasTiendas = interface(IEmpresasTiendas)
+ IBizEmpresaTienda = interface(IEmpresasTiendas)
['{564205A6-82A6-45E1-9523-6751BB5A8708}']
function EsNuevo : Boolean;
end;
- TBizEmpresasTiendas = class(TEmpresasTiendasDataTableRules, IBizEmpresasTiendas)
+ TBizEmpresaTienda = class(TEmpresasTiendasDataTableRules, IBizEmpresaTienda)
protected
procedure BeforeInsert(Sender: TDADataTable); override;
public
@@ -31,7 +31,7 @@ uses
{ TBizEmpresasTiendas }
-procedure TBizEmpresasTiendas.BeforeInsert(Sender: TDADataTable);
+procedure TBizEmpresaTienda.BeforeInsert(Sender: TDADataTable);
var
AMasterTable : TDADataTable;
begin
@@ -41,13 +41,13 @@ begin
AMasterTable.Post;
end;
-function TBizEmpresasTiendas.EsNuevo: Boolean;
+function TBizEmpresaTienda.EsNuevo: Boolean;
begin
Result := (ID < 0);
end;
initialization
- RegisterDataTableRules(BIZ_CLIENT_EMPRESAS_TIENDAS, TBizEmpresasTiendas);
+ RegisterDataTableRules(BIZ_CLIENT_EMPRESAS_TIENDAS, TBizEmpresaTienda);
end.
diff --git a/Source/ApplicationBase/Empresas/Servidor/srvEmpresas_Impl.pas b/Source/ApplicationBase/Empresas/Servidor/srvEmpresas_Impl.pas
index 68407ec0..48514023 100644
--- a/Source/ApplicationBase/Empresas/Servidor/srvEmpresas_Impl.pas
+++ b/Source/ApplicationBase/Empresas/Servidor/srvEmpresas_Impl.pas
@@ -32,6 +32,7 @@ type
const aMaxRecords: Integer);
private
protected
+ function DarTiendaUsuario(const ID_EMPRESA: Integer; const ID_USUARIO: Integer): Integer;
end;
implementation
@@ -54,6 +55,16 @@ begin
SessionManager := dmServer.SessionManager;
end;
+function TsrvEmpresas.DarTiendaUsuario(const ID_EMPRESA, ID_USUARIO: Integer): Integer;
+var
+ AContactosService : IsrvContactos;
+ Intf : IInterface;
+begin
+ GetClassFactory('srvContactos').CreateInstance(ClientID, Intf);
+ AContactosService := Intf as IsrvContactos;
+ Result := AContactosService.DarTiendaDeUsuario(ID_EMPRESA, ID_USUARIO)
+end;
+
procedure TsrvEmpresas.DataAbstractServiceBeforeAcquireConnection(
aSender: TObject; var aConnectionName: string);
begin
diff --git a/Source/ApplicationBase/Empresas/Views/uEditorTiendaEmpresa.pas b/Source/ApplicationBase/Empresas/Views/uEditorTiendaEmpresa.pas
index 4d203094..9d544098 100644
--- a/Source/ApplicationBase/Empresas/Views/uEditorTiendaEmpresa.pas
+++ b/Source/ApplicationBase/Empresas/Views/uEditorTiendaEmpresa.pas
@@ -6,7 +6,10 @@ uses Windows, SysUtils, Classes, Graphics, Forms, Controls, StdCtrls,
Buttons, ExtCtrls, Mask, DBCtrls, DB, uDADataTable, PngSpeedButton,
cxControls, cxContainer, cxEdit, cxTextEdit, cxHyperLinkEdit, cxDBEdit,
uIEditorTiendaEmpresa, uTiendasEmpresaController, uBizEmpresasTiendas,
- cxCurrencyEdit, uDAInterfaces, cxGraphics, cxMaskEdit, cxDropDownEdit;
+ cxCurrencyEdit, uDAInterfaces, cxGraphics, cxMaskEdit, cxDropDownEdit,
+ dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinOffice2007Black,
+ dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
+ dxSkinOffice2007Silver, dxSkinSilver, dxSkinsDefaultPainters;
type
TfEditorTiendaEmpresa = class(TForm, IEditorTiendaEmpresa)
@@ -53,17 +56,17 @@ type
procedure CargarPoblaciones;
protected
FController : ITiendasEmpresaController;
- FTienda: IBizEmpresasTiendas;
+ FTienda: IBizEmpresaTienda;
function GetController : ITiendasEmpresaController;
procedure SetController (const Value : ITiendasEmpresaController);
- function GetTienda: IBizEmpresasTiendas;
- procedure SetTienda(const Value: IBizEmpresasTiendas);
+ function GetTienda: IBizEmpresaTienda;
+ procedure SetTienda(const Value: IBizEmpresaTienda);
public
constructor Create(AOwner: TComponent); override;
destructor Destroy; override;
property Controller : ITiendasEmpresaController read GetController write SetController;
- property Tienda: IBizEmpresasTiendas read GetTienda write SetTienda;
+ property Tienda: IBizEmpresaTienda read GetTienda write SetTienda;
end;
implementation
@@ -206,7 +209,7 @@ begin
Result := FController;
end;
-function TfEditorTiendaEmpresa.GetTienda: IBizEmpresasTiendas;
+function TfEditorTiendaEmpresa.GetTienda: IBizEmpresaTienda;
begin
Result := FTienda;
end;
@@ -221,7 +224,7 @@ begin
FController := Value;
end;
-procedure TfEditorTiendaEmpresa.SetTienda(const Value: IBizEmpresasTiendas);
+procedure TfEditorTiendaEmpresa.SetTienda(const Value: IBizEmpresaTienda);
begin
FTienda := Value;
if Assigned(FTienda) then
diff --git a/Source/ApplicationBase/Empresas/Views/uViewTienda.pas b/Source/ApplicationBase/Empresas/Views/uViewTienda.pas
index 4bd4eb30..459bae9c 100644
--- a/Source/ApplicationBase/Empresas/Views/uViewTienda.pas
+++ b/Source/ApplicationBase/Empresas/Views/uViewTienda.pas
@@ -131,8 +131,8 @@ begin
end;
procedure TfrViewTienda.SetIDTienda(const ID: Integer);
-var
- AIndex: Integer;
+{var
+AIndex: Integer;}
begin
{ if FListaIDTiendas.Find(ID, AIndex) then
cbTienda.Text := FListaTiendas.Strings[AIndex];}
diff --git a/Source/ApplicationBase/Empresas/Views/uViewTiendas.pas b/Source/ApplicationBase/Empresas/Views/uViewTiendas.pas
index c5fb19da..967f515d 100644
--- a/Source/ApplicationBase/Empresas/Views/uViewTiendas.pas
+++ b/Source/ApplicationBase/Empresas/Views/uViewTiendas.pas
@@ -10,7 +10,10 @@ uses
cxGridDBBandedTableView, cxClasses, cxControls, cxGridCustomView, cxGrid,
uDADataTable, Grids, DBGrids, ActnList, ImgList, PngImageList, ComCtrls,
ToolWin, cxGridDBTableView, uViewDetallesGenerico, cxCurrencyEdit,
- uDAInterfaces;
+ uDAInterfaces, dxSkinsCore, dxSkinBlack, dxSkinBlue, dxSkinOffice2007Black,
+ dxSkinOffice2007Blue, dxSkinOffice2007Green, dxSkinOffice2007Pink,
+ dxSkinOffice2007Silver, dxSkinSilver, dxSkinsDefaultPainters,
+ dxSkinscxPCPainter;
type
TfrViewTiendas = class(TfrViewDetallesGenerico)
@@ -48,19 +51,18 @@ begin
end;
procedure TfrViewTiendas.AnadirInterno;
+var
+ ATiendasController : ITiendasEmpresaController;
begin
inherited;
+ ATiendasController := TTiendasEmpresaController.Create;
try
- with TTiendasEmpresaController.Create do
- try
- VerTienda((dsDetalles.DataTable) as IBizEmpresasTiendas);
- finally
- Free;
- end;
- finally
+ ATiendasController.Ver((dsDetalles.DataTable) as IBizEmpresaTienda);
if (dsDetalles.DataTable.State in dsEditModes) then
dsDetalles.DataTable.Post;
+ finally
+ ATiendasController := NIL;
end;
end;
@@ -90,7 +92,7 @@ begin
inherited;
AController := TTiendasEmpresaController.Create;
try
- AController.VerTienda((dsDetalles.DataTable) as IBizEmpresasTiendas);
+ AController.Ver((dsDetalles.DataTable) as IBizEmpresaTienda);
finally
AController := NIL;
end;
diff --git a/Source/ApplicationBase/Usuarios/Controller/uUsuariosController.pas b/Source/ApplicationBase/Usuarios/Controller/uUsuariosController.pas
index 770b4186..a0809b49 100644
--- a/Source/ApplicationBase/Usuarios/Controller/uUsuariosController.pas
+++ b/Source/ApplicationBase/Usuarios/Controller/uUsuariosController.pas
@@ -22,7 +22,7 @@ type
procedure VerPerfil(const AIDPerfil: Integer); overload;
procedure VerPerfil(APerfil : IBizPerfilUsuario); overload;
-
+
procedure _ShowUserManager;
procedure _ShowProfileManager;
procedure _ShowLogManager;
@@ -67,8 +67,6 @@ type
procedure SetUsarPasswordsSeguras(const Value: Boolean);
property UsarPasswordsSeguras : Boolean read GetUsarPasswordsSeguras write SetUsarPasswordsSeguras;
- procedure darIDTiendaVendedorUsuario(const IdUsuario: Integer; var AIdTienda: Integer; var ATienda: String);
-
{
procedure ChangePassword(IDUser: Integer; NewPassword: String);
procedure AddRight(idUser: Integer; ItemRight: TObject; FullPath: Boolean = True); overload;
@@ -86,8 +84,6 @@ type
end;
TUsuariosController = class(TControllerBase, IUsuariosController)
- private
- procedure FiltrarEmpresa(AUsuario: IBizUsuario);
protected
FDataModule : IDataModuleUsuarios;
FUserControl: TUserControl;
@@ -163,7 +159,7 @@ type
function ValidarPassword(const APassword : string; const ALogin : String;
const ANombre: String; out AMsg : String): boolean;
- procedure darIDTiendaVendedorUsuario(const IdUsuario: Integer; var AIdTienda: Integer; var ATienda: String);
+ //procedure DarIDTiendaVendedorUsuario(const IdUsuario: Integer; var AIdTienda: Integer; var ATienda: String);
property UsarPasswordsSeguras : Boolean read GetUsarPasswordsSeguras write SetUsarPasswordsSeguras;
property UserControl : TUserControl read FUserControl;
@@ -289,13 +285,11 @@ end;
function TUsuariosController.BuscarTodosUsuarios: IBizUsuario;
begin
Result := FDataModule.GetUsuarios;
- FiltrarEmpresa(Result);
end;
function TUsuariosController.BuscarUsuario(const AIDUser: Integer): IBizUsuario;
begin
Result := FDataModule.GetUsuario(AIDUser);
- FiltrarEmpresa(Result);
end;
function TUsuariosController.CambiarPassword(const AIDUser: Integer;
@@ -311,7 +305,7 @@ var
AEditorCambiar : TfEditorCambiarPassword;
begin
Result := False;
-
+
AUser := FDataModule.GetUsuario(AIDUser);
if Assigned(AUser) then
begin
@@ -372,11 +366,6 @@ begin
Result := Supports(EditorRegistry.CreateEditor(AName), IID, Intf);
end;
-procedure TUsuariosController.darIDTiendaVendedorUsuario(const IdUsuario: Integer; var AIdTienda: Integer; var ATienda: String);
-begin
- FDataModule.DarIDTiendaVendedorUsuario(IdUsuario, AIdTienda, ATienda);
-end;
-
function TUsuariosController.DarListaPerfilesUsuario: TStringList;
var
APerfilesUsuario: IBizPerfilUsuario;
@@ -919,30 +908,5 @@ begin
end;
end;
-procedure TUsuariosController.FiltrarEmpresa(AUsuario: IBizUsuario);
-{var
- Condicion: TDAWhereExpression;}
-begin
-
- // AQUI HAY QUE TENER EN CUENTA QUE UN USUARIO PUEDE QUE NO TENGA ACCESO
- // EN UNA DETERMINADA EMPRESA
-
-
-{ if AUsuario.DataTable.Active then
- AUsuario.DataTable.Active := False;
-
- // Filtrar los contactos actuales por empresa
- with AUsuario.DataTable.DynamicWhere do
- begin
- Condicion := NewBinaryExpression(NewField('', fld_U
- ContactosID_EMPRESA), NewConstant(AppFactuGES.EmpresaActiva.ID, datInteger), dboEqual);
-
- if IsEmpty then
- Expression := Condicion
- else
- Expression := NewBinaryExpression(Expression, Condicion, dboAnd);
- end;}
-end;
-
end.
diff --git a/Source/ApplicationBase/Usuarios/Data/uDataModuleUsuarios.pas b/Source/ApplicationBase/Usuarios/Data/uDataModuleUsuarios.pas
index b0bd30a6..43f82090 100644
--- a/Source/ApplicationBase/Usuarios/Data/uDataModuleUsuarios.pas
+++ b/Source/ApplicationBase/Usuarios/Data/uDataModuleUsuarios.pas
@@ -37,7 +37,7 @@ type
function GetPerfil (const ID : Integer) : IBizPerfilUsuario;
procedure InicializarUserControl (AUserControl : TUserControl);
- procedure DarIDTiendaVendedorUsuario(const ID_USUARIO: Integer; var AIdTienda: Integer; var ATienda: String);
+ function DarTiendaUsuario(const ID_Usuario: Integer; var AID_Tienda: Integer; var ATienda: String) : Boolean;
end;
@@ -75,14 +75,22 @@ begin
Result := GetUsuario(ID_NULO)
end;
-procedure TDataModuleUsuarios.DarIDTiendaVendedorUsuario(const ID_USUARIO: Integer; var AIdTienda: Integer; var ATienda: String);
+{procedure TDataModuleUsuarios.DarIDTiendaVendedorUsuario(const ID_USUARIO: Integer; var AIdTienda: Integer; var ATienda: String);
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)
(srvUsuarios as IsrvUsuarios).darIDTiendaVendedorUsuario(ID_USUARIO, AIdTienda, ATienda);
+end;}
+
+function TDataModuleUsuarios.DarTiendaUsuario(const ID_Usuario: Integer; var AID_Tienda: Integer; var ATienda: String) : Boolean;
+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)
end;
+
procedure TDataModuleUsuarios.DataModuleCreate(Sender: TObject);
begin
inherited;
diff --git a/Source/ApplicationBase/Usuarios/Model/Data/uIDataModuleUsuarios.pas b/Source/ApplicationBase/Usuarios/Model/Data/uIDataModuleUsuarios.pas
index a89f04b8..5cceb718 100644
--- a/Source/ApplicationBase/Usuarios/Model/Data/uIDataModuleUsuarios.pas
+++ b/Source/ApplicationBase/Usuarios/Model/Data/uIDataModuleUsuarios.pas
@@ -18,7 +18,7 @@ type
function GetPerfiles : IBizPerfilUsuario;
function GetPerfil(const ID : Integer) : IBizPerfilUsuario;
- procedure DarIDTiendaVendedorUsuario(const ID_USUARIO: Integer; var AIdTienda: Integer; var ATienda: String);
+ function DarTiendaUsuario(const ID_Usuario: Integer; var AID_Tienda: Integer; var ATienda: String) : Boolean;
end;
implementation
diff --git a/Source/ApplicationBase/Usuarios/Model/schUsuariosClient_Intf.pas b/Source/ApplicationBase/Usuarios/Model/schUsuariosClient_Intf.pas
index 0429711e..85e511f7 100644
--- a/Source/ApplicationBase/Usuarios/Model/schUsuariosClient_Intf.pas
+++ b/Source/ApplicationBase/Usuarios/Model/schUsuariosClient_Intf.pas
@@ -9,14 +9,16 @@ 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_USUARIOS = '{33D6AE2E-8518-4E35-9BED-D5952F0A8931}';
- RID_USUARIOS_EVENTOS = '{3310F829-00D6-43CE-B41E-60922A628503}';
- RID_USUARIOS_LOGON = '{E45B7C80-1F27-4D73-BCA4-CD0C2C1B7CEB}';
- RID_PERMISOS = '{0000D1FE-8EC8-4BC6-A499-2F3C215EF8F9}';
- RID_PERMISOSEX = '{7424313C-3027-4073-97AE-4126FD866607}';
- RID_PERFILES = '{9CEB3528-1A72-48AE-AA40-D7307185B2FD}';
+ RID_DarTiendaUsuario = '{6E391DEF-F7EA-4159-BE3F-09458A45161B}';
+ RID_USUARIOS = '{5048D7CF-BE6A-4908-9359-FF38B82D059C}';
+ RID_USUARIOS_EVENTOS = '{AB4A1797-6311-4C66-9926-42AB459932C8}';
+ RID_USUARIOS_LOGON = '{51E280BB-1009-4E18-B1BF-C05318F75D97}';
+ RID_PERMISOS = '{14944C0A-3708-4797-9016-18030A86267F}';
+ RID_PERMISOSEX = '{09010D1A-F883-438B-8630-1A8814CD14F9}';
+ RID_PERFILES = '{68158A81-21D1-48B1-8F41-4B218AD21231}';
{ Data table names }
+ nme_DarTiendaUsuario = 'DarTiendaUsuario';
nme_USUARIOS = 'USUARIOS';
nme_USUARIOS_EVENTOS = 'USUARIOS_EVENTOS';
nme_USUARIOS_LOGON = 'USUARIOS_LOGON';
@@ -24,6 +26,14 @@ const
nme_PERMISOSEX = 'PERMISOSEX';
nme_PERFILES = 'PERFILES';
+ { DarTiendaUsuario fields }
+ fld_DarTiendaUsuarioID_TIENDA = 'ID_TIENDA';
+ fld_DarTiendaUsuarioTIENDA = 'TIENDA';
+
+ { DarTiendaUsuario field indexes }
+ idx_DarTiendaUsuarioID_TIENDA = 0;
+ idx_DarTiendaUsuarioTIENDA = 1;
+
{ USUARIOS fields }
fld_USUARIOSID = 'ID';
fld_USUARIOSUSERNAME = 'USERNAME';
@@ -127,9 +137,56 @@ const
idx_PERFILESTIPO = 3;
type
+ { IDarTiendaUsuario }
+ IDarTiendaUsuario = interface(IDAStronglyTypedDataTable)
+ ['{544B73C1-70CD-40F9-BCD6-4C83C1E2B4DD}']
+ { Property getters and setters }
+ function GetID_TIENDAValue: Integer;
+ procedure SetID_TIENDAValue(const aValue: Integer);
+ function GetID_TIENDAIsNull: Boolean;
+ procedure SetID_TIENDAIsNull(const aValue: Boolean);
+ function GetTIENDAValue: String;
+ procedure SetTIENDAValue(const aValue: String);
+ function GetTIENDAIsNull: Boolean;
+ procedure SetTIENDAIsNull(const aValue: Boolean);
+
+
+ { Properties }
+ property ID_TIENDA: Integer read GetID_TIENDAValue write SetID_TIENDAValue;
+ property ID_TIENDAIsNull: Boolean read GetID_TIENDAIsNull write SetID_TIENDAIsNull;
+ property TIENDA: String read GetTIENDAValue write SetTIENDAValue;
+ property TIENDAIsNull: Boolean read GetTIENDAIsNull write SetTIENDAIsNull;
+ end;
+
+ { TDarTiendaUsuarioDataTableRules }
+ TDarTiendaUsuarioDataTableRules = class(TIntfObjectDADataTableRules, IDarTiendaUsuario)
+ private
+ protected
+ { Property getters and setters }
+ function GetID_TIENDAValue: Integer; virtual;
+ procedure SetID_TIENDAValue(const aValue: Integer); virtual;
+ function GetID_TIENDAIsNull: Boolean; virtual;
+ procedure SetID_TIENDAIsNull(const aValue: Boolean); virtual;
+ function GetTIENDAValue: String; virtual;
+ procedure SetTIENDAValue(const aValue: String); virtual;
+ function GetTIENDAIsNull: Boolean; virtual;
+ procedure SetTIENDAIsNull(const aValue: Boolean); virtual;
+
+ { Properties }
+ property ID_TIENDA: Integer read GetID_TIENDAValue write SetID_TIENDAValue;
+ property ID_TIENDAIsNull: Boolean read GetID_TIENDAIsNull write SetID_TIENDAIsNull;
+ property TIENDA: String read GetTIENDAValue write SetTIENDAValue;
+ property TIENDAIsNull: Boolean read GetTIENDAIsNull write SetTIENDAIsNull;
+
+ public
+ constructor Create(aDataTable: TDADataTable); override;
+ destructor Destroy; override;
+
+ end;
+
{ IUSUARIOS }
IUSUARIOS = interface(IDAStronglyTypedDataTable)
- ['{609EF276-E3F0-44BE-897A-B99980AB6CA6}']
+ ['{8F61797A-69C1-46D0-A77F-9008A4A13118}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -296,7 +353,7 @@ type
{ IUSUARIOS_EVENTOS }
IUSUARIOS_EVENTOS = interface(IDAStronglyTypedDataTable)
- ['{57EB0AE4-C30E-4AEA-BB87-FBC94F54B462}']
+ ['{1B4FFD5F-7D38-4BEE-8289-8C0001E01899}']
{ Property getters and setters }
function GetAPLICACIONValue: String;
procedure SetAPLICACIONValue(const aValue: String);
@@ -427,7 +484,7 @@ type
{ IUSUARIOS_LOGON }
IUSUARIOS_LOGON = interface(IDAStronglyTypedDataTable)
- ['{341AC508-0746-40B5-A092-8C1D9CDBC604}']
+ ['{41DCA6DD-2B8F-407C-A620-FBE083802B0F}']
{ Property getters and setters }
function GetLOGONIDValue: String;
procedure SetLOGONIDValue(const aValue: String);
@@ -510,7 +567,7 @@ type
{ IPERMISOS }
IPERMISOS = interface(IDAStronglyTypedDataTable)
- ['{323F36F2-E464-4CAB-AE8C-B72295B949A4}']
+ ['{080033E7-82B8-4563-AB39-D114EC371228}']
{ Property getters and setters }
function GetID_USUARIOValue: Integer;
procedure SetID_USUARIOValue(const aValue: Integer);
@@ -581,7 +638,7 @@ type
{ IPERMISOSEX }
IPERMISOSEX = interface(IDAStronglyTypedDataTable)
- ['{84605C14-E7FC-4E1E-BE35-A0EBC3E7A02F}']
+ ['{19C86BFC-8B28-43D9-AF89-B92C9C6DB2AB}']
{ Property getters and setters }
function GetID_USUARIOValue: Integer;
procedure SetID_USUARIOValue(const aValue: Integer);
@@ -664,7 +721,7 @@ type
{ IPERFILES }
IPERFILES = interface(IDAStronglyTypedDataTable)
- ['{A0804B85-AECF-4F9A-A3C1-85068D16D302}']
+ ['{5578704D-1574-4705-AC6D-4D7FEEDB7E3E}']
{ Property getters and setters }
function GetIDValue: Integer;
procedure SetIDValue(const aValue: Integer);
@@ -737,6 +794,60 @@ implementation
uses Variants, uROBinaryHelpers;
+{ TDarTiendaUsuarioDataTableRules }
+constructor TDarTiendaUsuarioDataTableRules.Create(aDataTable: TDADataTable);
+begin
+ inherited;
+end;
+
+destructor TDarTiendaUsuarioDataTableRules.Destroy;
+begin
+ inherited;
+end;
+
+function TDarTiendaUsuarioDataTableRules.GetID_TIENDAValue: Integer;
+begin
+ result := DataTable.Fields[idx_DarTiendaUsuarioID_TIENDA].AsInteger;
+end;
+
+procedure TDarTiendaUsuarioDataTableRules.SetID_TIENDAValue(const aValue: Integer);
+begin
+ DataTable.Fields[idx_DarTiendaUsuarioID_TIENDA].AsInteger := aValue;
+end;
+
+function TDarTiendaUsuarioDataTableRules.GetID_TIENDAIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_DarTiendaUsuarioID_TIENDA].IsNull;
+end;
+
+procedure TDarTiendaUsuarioDataTableRules.SetID_TIENDAIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_DarTiendaUsuarioID_TIENDA].AsVariant := Null;
+end;
+
+function TDarTiendaUsuarioDataTableRules.GetTIENDAValue: String;
+begin
+ result := DataTable.Fields[idx_DarTiendaUsuarioTIENDA].AsString;
+end;
+
+procedure TDarTiendaUsuarioDataTableRules.SetTIENDAValue(const aValue: String);
+begin
+ DataTable.Fields[idx_DarTiendaUsuarioTIENDA].AsString := aValue;
+end;
+
+function TDarTiendaUsuarioDataTableRules.GetTIENDAIsNull: boolean;
+begin
+ result := DataTable.Fields[idx_DarTiendaUsuarioTIENDA].IsNull;
+end;
+
+procedure TDarTiendaUsuarioDataTableRules.SetTIENDAIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ DataTable.Fields[idx_DarTiendaUsuarioTIENDA].AsVariant := Null;
+end;
+
+
{ TUSUARIOSDataTableRules }
constructor TUSUARIOSDataTableRules.Create(aDataTable: TDADataTable);
begin
@@ -1636,6 +1747,7 @@ end;
initialization
+ RegisterDataTableRules(RID_DarTiendaUsuario, TDarTiendaUsuarioDataTableRules);
RegisterDataTableRules(RID_USUARIOS, TUSUARIOSDataTableRules);
RegisterDataTableRules(RID_USUARIOS_EVENTOS, TUSUARIOS_EVENTOSDataTableRules);
RegisterDataTableRules(RID_USUARIOS_LOGON, TUSUARIOS_LOGONDataTableRules);
diff --git a/Source/ApplicationBase/Usuarios/Model/schUsuariosServer_Intf.pas b/Source/ApplicationBase/Usuarios/Model/schUsuariosServer_Intf.pas
index 9fac71c7..6622cc33 100644
--- a/Source/ApplicationBase/Usuarios/Model/schUsuariosServer_Intf.pas
+++ b/Source/ApplicationBase/Usuarios/Model/schUsuariosServer_Intf.pas
@@ -9,17 +9,64 @@ 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_USUARIOSDelta = '{0CF1FB0D-0814-43C8-9EEA-C73F89D9EEFC}';
- RID_USUARIOS_EVENTOSDelta = '{70259783-5480-4B8A-8C19-E5F3AF2ADF5E}';
- RID_USUARIOS_LOGONDelta = '{664180AD-0611-4CF4-BDE0-AA2BA4AC9973}';
- RID_PERMISOSDelta = '{820DAE3D-63A0-4EEB-862C-A85EDF85E804}';
- RID_PERMISOSEXDelta = '{A01553FE-193F-4827-A0F2-9904D94C140F}';
- RID_PERFILESDelta = '{E7F3AB12-F120-4630-8AD5-01021379CC52}';
+ RID_DarTiendaUsuarioDelta = '{F68B88F5-A005-4557-A9A3-7DADC274C549}';
+ RID_USUARIOSDelta = '{01398090-5678-4007-B853-CF463D600568}';
+ RID_USUARIOS_EVENTOSDelta = '{641B4130-F1C0-47D5-8BDF-6FF343CE1718}';
+ RID_USUARIOS_LOGONDelta = '{BAFFEAF0-C43F-43FC-B103-1E065D54C103}';
+ RID_PERMISOSDelta = '{D0B890F9-EEFC-4F17-ACCB-6467CE37D354}';
+ RID_PERMISOSEXDelta = '{FE39DC21-84C6-4B6E-987C-1498ACA90759}';
+ RID_PERFILESDelta = '{E8793C8F-9FEE-4129-A03B-6423C4724DC2}';
type
+ { IDarTiendaUsuarioDelta }
+ IDarTiendaUsuarioDelta = interface(IDarTiendaUsuario)
+ ['{F68B88F5-A005-4557-A9A3-7DADC274C549}']
+ { Property getters and setters }
+ function GetOldID_TIENDAValue : Integer;
+ function GetOldTIENDAValue : String;
+
+ { Properties }
+ property OldID_TIENDA : Integer read GetOldID_TIENDAValue;
+ property OldTIENDA : String read GetOldTIENDAValue;
+ end;
+
+ { TDarTiendaUsuarioBusinessProcessorRules }
+ TDarTiendaUsuarioBusinessProcessorRules = class(TDABusinessProcessorRules, IDarTiendaUsuario, IDarTiendaUsuarioDelta)
+ private
+ protected
+ { Property getters and setters }
+ function GetID_TIENDAValue: Integer; virtual;
+ function GetID_TIENDAIsNull: Boolean; virtual;
+ function GetOldID_TIENDAValue: Integer; virtual;
+ function GetOldID_TIENDAIsNull: Boolean; virtual;
+ procedure SetID_TIENDAValue(const aValue: Integer); virtual;
+ procedure SetID_TIENDAIsNull(const aValue: Boolean); virtual;
+ function GetTIENDAValue: String; virtual;
+ function GetTIENDAIsNull: Boolean; virtual;
+ function GetOldTIENDAValue: String; virtual;
+ function GetOldTIENDAIsNull: Boolean; virtual;
+ procedure SetTIENDAValue(const aValue: String); virtual;
+ procedure SetTIENDAIsNull(const aValue: Boolean); virtual;
+
+ { Properties }
+ property ID_TIENDA : Integer read GetID_TIENDAValue write SetID_TIENDAValue;
+ property ID_TIENDAIsNull : Boolean read GetID_TIENDAIsNull write SetID_TIENDAIsNull;
+ property OldID_TIENDA : Integer read GetOldID_TIENDAValue;
+ property OldID_TIENDAIsNull : Boolean read GetOldID_TIENDAIsNull;
+ property TIENDA : String read GetTIENDAValue write SetTIENDAValue;
+ property TIENDAIsNull : Boolean read GetTIENDAIsNull write SetTIENDAIsNull;
+ property OldTIENDA : String read GetOldTIENDAValue;
+ property OldTIENDAIsNull : Boolean read GetOldTIENDAIsNull;
+
+ public
+ constructor Create(aBusinessProcessor: TDABusinessProcessor); override;
+ destructor Destroy; override;
+
+ end;
+
{ IUSUARIOSDelta }
IUSUARIOSDelta = interface(IUSUARIOS)
- ['{0CF1FB0D-0814-43C8-9EEA-C73F89D9EEFC}']
+ ['{01398090-5678-4007-B853-CF463D600568}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldUSERNAMEValue : String;
@@ -185,7 +232,7 @@ type
{ IUSUARIOS_EVENTOSDelta }
IUSUARIOS_EVENTOSDelta = interface(IUSUARIOS_EVENTOS)
- ['{70259783-5480-4B8A-8C19-E5F3AF2ADF5E}']
+ ['{641B4130-F1C0-47D5-8BDF-6FF343CE1718}']
{ Property getters and setters }
function GetOldAPLICACIONValue : String;
function GetOldID_USUARIOValue : Integer;
@@ -316,7 +363,7 @@ type
{ IUSUARIOS_LOGONDelta }
IUSUARIOS_LOGONDelta = interface(IUSUARIOS_LOGON)
- ['{664180AD-0611-4CF4-BDE0-AA2BA4AC9973}']
+ ['{BAFFEAF0-C43F-43FC-B103-1E065D54C103}']
{ Property getters and setters }
function GetOldLOGONIDValue : String;
function GetOldID_USUARIOValue : Integer;
@@ -398,7 +445,7 @@ type
{ IPERMISOSDelta }
IPERMISOSDelta = interface(IPERMISOS)
- ['{820DAE3D-63A0-4EEB-862C-A85EDF85E804}']
+ ['{D0B890F9-EEFC-4F17-ACCB-6467CE37D354}']
{ Property getters and setters }
function GetOldID_USUARIOValue : Integer;
function GetOldMODULOValue : String;
@@ -468,7 +515,7 @@ type
{ IPERMISOSEXDelta }
IPERMISOSEXDelta = interface(IPERMISOSEX)
- ['{A01553FE-193F-4827-A0F2-9904D94C140F}']
+ ['{FE39DC21-84C6-4B6E-987C-1498ACA90759}']
{ Property getters and setters }
function GetOldID_USUARIOValue : Integer;
function GetOldMODULOValue : String;
@@ -550,7 +597,7 @@ type
{ IPERFILESDelta }
IPERFILESDelta = interface(IPERFILES)
- ['{E7F3AB12-F120-4630-8AD5-01021379CC52}']
+ ['{E8793C8F-9FEE-4129-A03B-6423C4724DC2}']
{ Property getters and setters }
function GetOldIDValue : Integer;
function GetOldUSERNAMEValue : String;
@@ -623,6 +670,80 @@ implementation
uses
Variants, uROBinaryHelpers, uDAInterfaces;
+{ TDarTiendaUsuarioBusinessProcessorRules }
+constructor TDarTiendaUsuarioBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
+begin
+ inherited;
+end;
+
+destructor TDarTiendaUsuarioBusinessProcessorRules.Destroy;
+begin
+ inherited;
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetID_TIENDAValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioID_TIENDA];
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetID_TIENDAIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioID_TIENDA]);
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetOldID_TIENDAValue: Integer;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_DarTiendaUsuarioID_TIENDA];
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetOldID_TIENDAIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_DarTiendaUsuarioID_TIENDA]);
+end;
+
+procedure TDarTiendaUsuarioBusinessProcessorRules.SetID_TIENDAValue(const aValue: Integer);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioID_TIENDA] := aValue;
+end;
+
+procedure TDarTiendaUsuarioBusinessProcessorRules.SetID_TIENDAIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioID_TIENDA] := Null;
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetTIENDAValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioTIENDA];
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetTIENDAIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioTIENDA]);
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetOldTIENDAValue: String;
+begin
+ result := BusinessProcessor.CurrentChange.OldValueByName[fld_DarTiendaUsuarioTIENDA];
+end;
+
+function TDarTiendaUsuarioBusinessProcessorRules.GetOldTIENDAIsNull: Boolean;
+begin
+ result := VarIsNull(BusinessProcessor.CurrentChange.OldValueByName[fld_DarTiendaUsuarioTIENDA]);
+end;
+
+procedure TDarTiendaUsuarioBusinessProcessorRules.SetTIENDAValue(const aValue: String);
+begin
+ BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioTIENDA] := aValue;
+end;
+
+procedure TDarTiendaUsuarioBusinessProcessorRules.SetTIENDAIsNull(const aValue: Boolean);
+begin
+ if aValue then
+ BusinessProcessor.CurrentChange.NewValueByName[fld_DarTiendaUsuarioTIENDA] := Null;
+end;
+
+
{ TUSUARIOSBusinessProcessorRules }
constructor TUSUARIOSBusinessProcessorRules.Create(aBusinessProcessor: TDABusinessProcessor);
begin
@@ -1913,6 +2034,7 @@ end;
initialization
+ RegisterBusinessProcessorRules(RID_DarTiendaUsuarioDelta, TDarTiendaUsuarioBusinessProcessorRules);
RegisterBusinessProcessorRules(RID_USUARIOSDelta, TUSUARIOSBusinessProcessorRules);
RegisterBusinessProcessorRules(RID_USUARIOS_EVENTOSDelta, TUSUARIOS_EVENTOSBusinessProcessorRules);
RegisterBusinessProcessorRules(RID_USUARIOS_LOGONDelta, TUSUARIOS_LOGONBusinessProcessorRules);
diff --git a/Source/ApplicationBase/Usuarios/Model/uBizUsuarios.pas b/Source/ApplicationBase/Usuarios/Model/uBizUsuarios.pas
index 7d39a13a..f9bbfebb 100644
--- a/Source/ApplicationBase/Usuarios/Model/uBizUsuarios.pas
+++ b/Source/ApplicationBase/Usuarios/Model/uBizUsuarios.pas
@@ -15,11 +15,12 @@ type
IBizUsuario = interface (IUSUARIOS)
['{1DB69F36-969C-4078-B862-6D697670BCFD}']
function EsNuevo : Boolean;
+ function EsAdministrador : Boolean;
end;
IBizPerfilUsuario = interface (IPERFILES)
['{D14DF996-A8CD-400A-BF74-C8B660199C74}']
- function EsNuevo : Boolean;
+ function EsNuevo : Boolean;
end;
@@ -28,6 +29,7 @@ type
procedure OnNewRecord(Sender: TDADataTable); override;
public
function EsNuevo : Boolean;
+ function EsAdministrador : Boolean;
procedure IniciarValoresUsuarioNuevo;
end;
@@ -45,6 +47,11 @@ implementation
{ TBizUsuario }
+function TBizUsuario.EsAdministrador: Boolean;
+begin
+ Result := (USERNAME = 'admin');
+end;
+
function TBizUsuario.EsNuevo: Boolean;
begin
Result := (ID < 0);
diff --git a/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.dfm b/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.dfm
index 1ba79156..f3fd9c02 100644
--- a/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.dfm
+++ b/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.dfm
@@ -118,11 +118,17 @@ object srvUsuarios: TsrvUsuarios
Diagrams = Diagrams
Datasets = <
item
+ IsPublic = False
Params = <
item
Name = 'ID_USUARIO'
- Value = ''
- ParamType = daptInput
+ DataType = datInteger
+ Value = '6'
+ end
+ item
+ Name = 'ID_EMPRESA'
+ DataType = datInteger
+ Value = '1'
end>
Statements = <
item
@@ -132,9 +138,9 @@ object srvUsuarios: TsrvUsuarios
TargetTable = 'V_VENDEDORES'
Name = 'IBX'
SQL =
- 'select ID_TIENDA, TIENDA'#10'from V_VENDEDORES'#10'left join USUARIOS on' +
- ' (USUARIOS.ID = V_VENDEDORES.ID_USUARIO)'#10'where USUARIOS.ID = :ID' +
- '_USUARIO'#10
+ 'select ID_TIENDA, TIENDA'#10' from V_VENDEDORES'#10' where V_VENDEDORES' +
+ '.ID = :ID_USUARIO and'#10' V_VENDEDORES.ID_EMPRESA = :ID_EMPRE' +
+ 'SA'#10
StatementType = stSQL
ColumnMappings = <
item
@@ -146,7 +152,7 @@ object srvUsuarios: TsrvUsuarios
TableField = 'TIENDA'
end>
end>
- Name = 'darTiendaVendedorUsuario'
+ Name = 'DarTiendaUsuario'
Fields = <
item
Name = 'ID_TIENDA'
diff --git a/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.pas b/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.pas
index a418b5a0..111a07c5 100644
--- a/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.pas
+++ b/Source/ApplicationBase/Usuarios/Servidor/srvUsuarios_Impl.pas
@@ -29,9 +29,6 @@ type
procedure DataAbstractServiceBeforeAcquireConnection(aSender: TObject;
var aConnectionName: string);
procedure DataAbstractServiceCreate(Sender: TObject);
-
- protected
- procedure DarIDTiendaVendedorUsuario(const ID_USUARIO: Integer; var AIdTienda: Integer; var ATienda: String);
end;
implementation
@@ -40,53 +37,12 @@ implementation
uses
{Generated:} FactuGES_Invk, uROClasses, uDAInterfaces, uDataModuleServer;
-const
- CTE_ID_TODAS = 0;
- CTE_TODAS = 'Todas';
-
-
procedure Create_srvUsuarios(out anInstance : IUnknown);
begin
anInstance := TsrvUsuarios.Create(nil);
end;
{ srvUsuarios }
-procedure TsrvUsuarios.DarIDTiendaVendedorUsuario(const ID_USUARIO: Integer; var AIdTienda: Integer; var ATienda: String);
-var
- AConn : IDAConnection;
- dsData: IDADataset;
-
-begin
- AConn := dmServer.ConnectionManager.NewConnection(dmServer.ConnectionManager.GetDefaultConnectionName);
-
- try
- try
- dsData := schUsuarios.NewDataset(AConn, 'darTiendaVendedorUsuario', ['ID_USUARIO'], [ID_USUARIO]);
- dsData.Active := True;
-
- case dsData.RecordCount of
- 0: begin
- AIdTienda := CTE_ID_TODAS;
- ATienda := CTE_TODAS;
- end;
- 1: begin
- AIdTienda := dsData.FieldByName('ID_TIENDA').AsInteger;
- ATienda := dsData.FieldByName('TIENDA').AsString;
- end
- else
- RaiseError('Error al buscar tienda por defecto para el usuario');
- end;
-
- AConn.CommitTransaction;
-
- except
- RaiseError('Error al buscar ejercicio activo de la empresa');
- AConn.RollbackTransaction;
- end;
- finally
- dsData := NIL;
- end;
-end;
procedure TsrvUsuarios.DataAbstractServiceBeforeAcquireConnection(
aSender: TObject; var aConnectionName: string);
diff --git a/Source/ApplicationBase/Usuarios/Views/uEditorLogin.dfm b/Source/ApplicationBase/Usuarios/Views/uEditorLogin.dfm
index 74b79e37..6f1167fe 100644
--- a/Source/ApplicationBase/Usuarios/Views/uEditorLogin.dfm
+++ b/Source/ApplicationBase/Usuarios/Views/uEditorLogin.dfm
@@ -25,7 +25,7 @@ object fEditorLogin: TfEditorLogin
Width = 39
Height = 13
Caption = 'Usuario:'
- Transparent = False
+ Transparent = True
end
object Label4: TLabel
Left = 24
@@ -33,7 +33,7 @@ object fEditorLogin: TfEditorLogin
Width = 57
Height = 13
Caption = 'Contrase'#241'a:'
- Transparent = False
+ Transparent = True
end
object Label1: TLabel
Left = 16
diff --git a/Source/ApplicationBase/uFactuGES_App.pas b/Source/ApplicationBase/uFactuGES_App.pas
index fae47c24..d3a46e16 100644
--- a/Source/ApplicationBase/uFactuGES_App.pas
+++ b/Source/ApplicationBase/uFactuGES_App.pas
@@ -4,7 +4,8 @@ interface
uses
SysUtils, Classes, Forms, uBizUsuarios, uBizEmpresas, uBizEjercicios, uControllerBase,
- uEmpresasController, uUsuariosController, uHostManager, uConfiguracionController;
+ uEmpresasController, uUsuariosController, uHostManager, uConfiguracionController,
+ uBizEmpresasTiendas;
type
TDoLoadModulesEvent = procedure;
@@ -30,11 +31,12 @@ type
function GetAppVersion: String;
function GetUsuarioActivo: IBizUsuario;
function GetEmpresaActiva: IBizEmpresa;
+ function GetTiendaActiva: IBizEmpresaTienda;
function GetEjercicioActivo: IBizEjercicio;
function GetModuleManager : THostManager;
function GetTerminated: Boolean;
function GetConfiguracionController : IConfiguracionController;
-
+
function GetLoadModulesEvent : TDoLoadModulesEvent;
procedure SetLoadModulesEvent (ALoadModulesEvent : TDoLoadModulesEvent);
@@ -45,6 +47,7 @@ type
procedure SetAppSplashForm (AAppSplashForm : IAppSplashForm);
procedure CambiarEmpresa(const AIDEmpresa : Integer);
+ procedure CambiarEmpresaPorDefecto;
procedure CambiarEjercicio(const AIDEmpresa : Integer);
procedure ShowSplashForm;
@@ -60,6 +63,7 @@ type
property AppFullName : String read GetAppFullName;
property MainForm : TCustomForm read GetMainForm;
property EmpresaActiva : IBizEmpresa read GetEmpresaActiva;
+ property TiendaActiva : IBizEmpresaTienda read GetTiendaActiva;
property EjercicioActivo : IBizEjercicio read GetEjercicioActivo;
property UsuarioActivo : IBizUsuario read GetUsuarioActivo;
property EmpresasController : IEmpresasController read GetEmpresasController;
@@ -71,12 +75,12 @@ type
property Terminated : Boolean read GetTerminated;
property Configuracion : IConfiguracionController read GetConfiguracionController;
- function getVAR_IDTIENDA : Integer;
+{ 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;
+ property VAR_TIENDA: String read getVAR_TIENDA write setVAR_TIENDA;}
procedure ShowCapado;
@@ -91,6 +95,7 @@ type
FEmpresasController : IEmpresasController;
FUsuariosController: IUsuariosController;
FEmpresaActiva: IBizEmpresa;
+ FTiendaActiva: IBizEmpresaTienda;
FEjercicioActivo: IBizEjercicio;
FConfiguracionController : IConfiguracionController;
@@ -109,6 +114,7 @@ type
function GetAppVersion: String;
function GetUsuarioActivo: IBizUsuario;
function GetEmpresaActiva: IBizEmpresa;
+ function GetTiendaActiva: IBizEmpresaTienda;
function GetEjercicioActivo: IBizEjercicio;
function GetModuleManager : THostManager;
function GetTerminated: Boolean;
@@ -125,8 +131,7 @@ type
procedure AfterLoadModule(Sender: TObject; AModuleInfo: TModuleInfo);
procedure RegisterModule(AModuleInfo : TModuleInfo);
- procedure PonerTiendaPorDefecto;
-
+ procedure BuscarTiendaPorDefecto;
protected
procedure DoMainForm;
@@ -146,6 +151,7 @@ type
procedure Configurar;
procedure CambiarEmpresa(const AIDEmpresa : Integer);
+ procedure CambiarEmpresaPorDefecto;
procedure CambiarEjercicio(const AIDEmpresa : Integer);
property AppVersion : String read GetAppVersion;
@@ -153,6 +159,7 @@ type
property AppFullName : String read GetAppFullName;
property MainForm : TCustomForm read GetMainForm;
property EmpresaActiva : IBizEmpresa read GetEmpresaActiva;
+ property TiendaActiva : IBizEmpresaTienda read GetTiendaActiva;
property EjercicioActivo : IBizEjercicio read GetEjercicioActivo;
property AppSplashForm : IAppSplashForm read GetAppSplashForm write SetAppSplashForm;
property UsuarioActivo : IBizUsuario read GetUsuarioActivo;
@@ -163,7 +170,7 @@ type
property DoLoadModulesEvent : TDoLoadModulesEvent read GetLoadModulesEvent write SetLoadModulesEvent;
property Terminated : Boolean read GetTerminated;
property Configuracion : IConfiguracionController read GetConfiguracionController;
-
+
function getVAR_IDTIENDA : Integer;
procedure setVAR_IDTIENDA (AValue : Integer);
function getVAR_TIENDA : String;
@@ -176,7 +183,7 @@ type
end;
var
- AppFactuGES : IAppFactuGES = nil;
+ AppFactuGES : IAppFactuGES;
implementation
@@ -217,6 +224,22 @@ begin
//Establece el ejercicio activo de la empresa activa
CambiarEjercicio(AIDEmpresa);
+ BuscarTiendaPorDefecto;
+end;
+
+procedure TAppFactuGES.CambiarEmpresaPorDefecto;
+var
+ AEmpresas : IBizEmpresa;
+begin
+ AEmpresas := FEmpresasController.BuscarTodos;
+ try
+ AEmpresas.DataTable.Active := True;
+ if AEmpresas.DataTable.RecordCount > 0 then
+ CambiarEmpresa(AEmpresas.ID);
+ AEmpresas.DataTable.Active := False;
+ finally
+ AEmpresas := NIL;
+ end;
end;
procedure TAppFactuGES.CargarModulos;
@@ -230,19 +253,18 @@ end;
procedure TAppFactuGES.Configurar;
begin
FConfiguracionController.ConfigurarAplicacion;
+ FConfiguracionController.AplicarConfiguracion;
end;
-procedure TAppFactuGES.PonerTiendaPorDefecto;
+procedure TAppFactuGES.BuscarTiendaPorDefecto;
var
- AIdTienda: Integer;
- ATienda: String;
+ 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)
- UsuariosController.DarIDTiendaVendedorUsuario(UsuarioActivo.ID, AIdTienda, ATienda);
- VAR_IDTIENDA := AIdTienda;
- VAR_TIENDA := ATienda;
+ FTiendaActiva := EmpresasController.DarTiendaUsuario(EmpresaActiva, UsuarioActivo.ID);
+ FTiendaActiva.DataTable.Open;
end;
constructor TAppFactuGES.Create;
@@ -333,7 +355,7 @@ end;
function TAppFactuGES.GetEmpresaActiva: IBizEmpresa;
begin
- Result := FEmpresaActiva;
+ Result := FEmpresaActiva
end;
function TAppFactuGES.GetEmpresasController: IEmpresasController;
@@ -359,6 +381,11 @@ begin
Result := FTerminated;
end;
+function TAppFactuGES.GetTiendaActiva: IBizEmpresaTienda;
+begin
+ Result := FTiendaActiva;
+end;
+
function TAppFactuGES.GetUsuarioActivo: IBizUsuario;
begin
Result := UsuariosController.CurrentUser;
@@ -384,9 +411,7 @@ end;
procedure TAppFactuGES.HideSplashForm;
begin
- if not Assigned(FAppSplashForm) then
- raise Exception.Create('AppSplashForm no asignado (HideSplashForm)');
-
+ if Assigned(FAppSplashForm) then
FAppSplashForm.Hide;
end;
@@ -398,19 +423,20 @@ end;
procedure TAppFactuGES.RegisterModule(AModuleInfo: TModuleInfo);
begin
- AppSplashForm.Mensaje := 'Cargando ''' + AModuleInfo.Module.ModuleName + '''...';
+ if Assigned(FAppSplashForm) then
+ FAppSplashForm.Mensaje := 'Cargando ''' + AModuleInfo.Module.ModuleName + '''...';
end;
procedure TAppFactuGES.Run;
begin
+ FConfiguracionController.AplicarConfiguracion;
if UsuariosController.StartLogin then
begin
ShowHourglassCursor;
try
- //ShowSplashForm;
+ ShowSplashForm;
CargarModulos;
DoMainForm;
- PonerTiendaPorDefecto;
finally
HideHourglassCursor;
HideSplashForm;
@@ -454,11 +480,11 @@ end;
procedure TAppFactuGES.ShowSplashForm;
begin
- if not Assigned(FAppSplashForm) then
- raise Exception.Create('AppSplashForm no asignado (ShowSplashForm)');
-
- FAppSplashForm.Show;
- FAppSplashForm.Update;
+ if Assigned(FAppSplashForm) then
+ begin
+ FAppSplashForm.Show;
+ FAppSplashForm.Update;
+ end;
end;
procedure TAppFactuGES.Terminate;
@@ -474,13 +500,15 @@ end;
initialization
// Pongo esto aquí por ahora
+ AppFactuGES := NIL;
+
uUsuariosViewRegister.RegisterViews;
uEmpresasViewRegister.RegisterViews;
finalization
// Pongo esto aquí por ahora
AppFactuGES := NIL;
-
+
uUsuariosViewRegister.UnregisterViews;
uEmpresasViewRegister.UnregisterViews;
diff --git a/Source/Cliente/FactuGES.dpr b/Source/Cliente/FactuGES.dpr
index 476de4b4..6eaa1e4d 100644
--- a/Source/Cliente/FactuGES.dpr
+++ b/Source/Cliente/FactuGES.dpr
@@ -10,12 +10,14 @@ uses
uMenuUtils in 'Utiles\uMenuUtils.pas',
uSplash in 'uSplash.pas' {SplashScreen},
uAcercaDe in 'uAcercaDe.pas',
- uNavPaneController in 'uNavPaneController.pas',
+ udxNavPaneController in 'udxNavPaneController.pas',
uNavPaneUtils in 'Utiles\uNavPaneUtils.pas',
uMainMenuController in 'uMainMenuController.pas',
uClienteUtils in 'Utiles\uClienteUtils.pas',
uBootStrap in 'uBootStrap.pas',
- VCLFlickerReduce in 'Utiles\VCLFlickerReduce.pas';
+ VCLFlickerReduce in 'Utiles\VCLFlickerReduce.pas',
+ uPantallaPrincipal2 in 'uPantallaPrincipal2.pas' {fPantallaPrincipal2},
+ uNavPaneController in 'uNavPaneController.pas';
{$R *.res}
diff --git a/Source/Cliente/FactuGES.dproj b/Source/Cliente/FactuGES.dproj
index 8b01e4c4..a30c7948 100644
--- a/Source/Cliente/FactuGES.dproj
+++ b/Source/Cliente/FactuGES.dproj
@@ -66,8 +66,7 @@
- ExpressPrinting System by Developer Express Inc.
- PluginSDK for Delphi 10 (Runtime)
+ RemObjects Data Abstract - SQLite Driver
Microsoft Office 2000 Sample Automation Server Wrapper Components
Microsoft Office XP Sample Automation Server Wrapper Components
FactuGES.dprFalse
@@ -79,11 +78,15 @@
+
+
+
+
@@ -91,6 +94,7 @@
+