unit Business_u;

interface

uses
  Winapi.Windows, Winapi.Messages, System.SysUtils, System.Variants, System.Classes, Vcl.Graphics,
  Vcl.Controls, Vcl.Forms, Vcl.Dialogs, Vcl.StdCtrls, Vcl.Imaging.pngimage,
  Vcl.ExtCtrls,UserLogin_u,AdminAdd_u, AdminLogin_u;

type
  TfrmBusiness = class(TForm)
    Image1: TImage;
    btnAdmin: TButton;
    btnLogin: TButton;
    procedure btnLoginClick(Sender: TObject);
    procedure FormClose(Sender: TObject; var Action: TCloseAction);
    procedure close();
    procedure btnAdminClick(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }

  end;

var
  frmBusiness: TfrmBusiness;

implementation

{$R *.dfm}


procedure TfrmBusiness.btnAdminClick(Sender: TObject);
begin
  frmBusiness.Hide;
  FrmAdminLogin.Show;
end;

procedure TfrmBusiness.btnLoginClick(Sender: TObject);
begin
  frmUserLogin:= TfrmUserLogin.Create(nil);
  frmUserLogin.show;
  frmBusiness.hide;
end;

procedure TfrmBusiness.close;
begin
  frmUserLogin.free;
  frmBusiness.show;
end;

procedure TfrmBusiness.FormClose(Sender: TObject; var Action: TCloseAction);
begin
  Application.Terminate;
end;

end.
