General -> Sincronizar la barra lateral con la elección de empresa hecha en la pantalla de selección de empresa
git-svn-id: https://192.168.0.254/svn/Proyectos.Tecsitel_FactuGES2/trunk@808 0c75b7a4-871f-7646-8a2f-f78d34cc349f
This commit is contained in:
parent
51a087ba8f
commit
31fcb2ec62
@ -353,7 +353,7 @@ begin
|
||||
JsDialog.Content.Add('Selección de empresa');
|
||||
JsDialog.Instruction.Text := 'Elija la empresa con la que desea trabajar.';
|
||||
JsDialog.DialogOptions := [doCommandLinks, doModal];
|
||||
JsDialog.ButtonBar.Buttons := [cbOk];
|
||||
JsDialog.ButtonBar.Buttons := [cbCancel];
|
||||
JsDialog.Width := 600;
|
||||
|
||||
|
||||
|
||||
@ -2,8 +2,8 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
Left = 358
|
||||
Top = 250
|
||||
Caption = 'Pantalla principal'
|
||||
ClientHeight = 453
|
||||
ClientWidth = 751
|
||||
ClientHeight = 553
|
||||
ClientWidth = 886
|
||||
Color = clWindow
|
||||
Font.Charset = DEFAULT_CHARSET
|
||||
Font.Color = clWindowText
|
||||
@ -23,8 +23,8 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
object pnlContenido: TTBXAlignmentPanel
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 751
|
||||
Height = 431
|
||||
Width = 886
|
||||
Height = 531
|
||||
Margins.Left = 5
|
||||
Margins.Top = 5
|
||||
Margins.Right = 5
|
||||
@ -36,7 +36,7 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
Left = 215
|
||||
Top = 5
|
||||
Width = 5
|
||||
Height = 421
|
||||
Height = 521
|
||||
ResizeStyle = rsPattern
|
||||
ExplicitLeft = 210
|
||||
ExplicitHeight = 570
|
||||
@ -45,7 +45,7 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
Left = 5
|
||||
Top = 5
|
||||
Width = 210
|
||||
Height = 421
|
||||
Height = 521
|
||||
ActivePage = pagInicio
|
||||
Align = alLeft
|
||||
AutoHeaders = True
|
||||
@ -90,7 +90,7 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
Left = 0
|
||||
Top = 0
|
||||
Width = 208
|
||||
Height = 348
|
||||
Height = 448
|
||||
Background.Stretch = False
|
||||
Background.Proportional = False
|
||||
Background.Center = False
|
||||
@ -100,7 +100,7 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
ImageIndex = 0
|
||||
object Panel1: TPanel
|
||||
Left = 0
|
||||
Top = 262
|
||||
Top = 362
|
||||
Width = 208
|
||||
Height = 86
|
||||
Align = alBottom
|
||||
@ -153,8 +153,8 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
object pnlBorde: TJvXPContainer
|
||||
Left = 220
|
||||
Top = 5
|
||||
Width = 526
|
||||
Height = 421
|
||||
Width = 661
|
||||
Height = 521
|
||||
BoundColor = clActiveCaption
|
||||
BoundLines = [blLeft, blTop, blRight, blBottom]
|
||||
Caption = 'pnlBorde'
|
||||
@ -162,8 +162,8 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
object pnlMain: TTBXAlignmentPanel
|
||||
Left = 1
|
||||
Top = 1
|
||||
Width = 524
|
||||
Height = 419
|
||||
Width = 659
|
||||
Height = 519
|
||||
Align = alClient
|
||||
Color = clWindow
|
||||
TabOrder = 0
|
||||
@ -203,8 +203,8 @@ object fPantallaPrincipal: TfPantallaPrincipal
|
||||
end
|
||||
object TBXStatusBar1: TTBXStatusBar
|
||||
Left = 0
|
||||
Top = 431
|
||||
Width = 751
|
||||
Top = 531
|
||||
Width = 886
|
||||
Images = StatusPanelImageList
|
||||
Panels = <
|
||||
item
|
||||
|
||||
@ -186,6 +186,8 @@ begin
|
||||
end;
|
||||
|
||||
procedure TfPantallaPrincipal.FormShow(Sender: TObject);
|
||||
var
|
||||
AIDEmpresa : Integer;
|
||||
begin
|
||||
InicializarUI;
|
||||
|
||||
@ -197,11 +199,13 @@ begin
|
||||
|
||||
//Sacamos la lista de empresas para que el usuario elija con la que va a trabajar
|
||||
AppFactuGES.SeleccionarEmpresa;
|
||||
RefrescarUI;
|
||||
end;
|
||||
|
||||
procedure TfPantallaPrincipal.RefrescarUI;
|
||||
var
|
||||
ATitulo : String;
|
||||
i: Integer;
|
||||
begin
|
||||
ATitulo := AppFactuGES.GetAppFullName;
|
||||
|
||||
@ -220,6 +224,14 @@ begin
|
||||
TBXStatusBar1.Panels[1].Caption := AppFactuGES.UsuarioActivo.UserName
|
||||
else
|
||||
TBXStatusBar1.Panels[1].Caption := '';
|
||||
|
||||
|
||||
// Comprobar que el panel lateral tiene la empresa activa
|
||||
if Assigned(AppFactuGES.EmpresaActiva) then
|
||||
for i := 0 to JvNavigationPane.PageCount - 1 do
|
||||
if (JvNavigationPane.Pages[i].Tag = AppFactuGES.EmpresaActiva.ID) and
|
||||
(JvNavigationPane.ActivePageIndex <> i) then
|
||||
JvNavigationPane.ActivePageIndex := i;
|
||||
end;
|
||||
|
||||
procedure TfPantallaPrincipal.ReleaseEmbedded;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user