//


        // CONSTRUCTORS
        //To-setup the view.
        public Login_View(bool toDisplay, ref Shared_Data xSD) : this(toDisplay)
        {
            SD = xSD;
            Employees_Data EmloyeesData = new Employees_Data(ref SD);

            EmployeesLogins = EmloyeesData.GetEmployeesLoginsPasswords();
        }
        public Login_Form()
        {
            SD = new Shared_Data();

            SD.LoginForm = this;

            InitializeComponent();
        }
示例#3
0
        public Response_Team_Information_Form(ref Shared_Data xSD) : base(ref xSD, "Receive Call")
        {
            InitializeComponent();

            // CHANGE
            Response_Team = xSD.ResponseTeams[0];
            SD            = xSD;
        }
        //

        public Main_Form(ref Shared_Data xSD)
        {
            InitializeComponent();

            // Setting up the form.
            SD = xSD;

            SD.AddMain_Form(this);
        }
示例#5
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            Shared_Data SD = new Shared_Data();

            Application.Run(new Main_Form(ref SD));
        }
示例#6
0
        //


        public void UpdateSD(ref Shared_Data xSD)
        {
            Calls              = xSD.GetCalls();
            Emergencies        = xSD.GetEmergencies();
            EMTs               = xSD.GetEMTs();
            ResponseTeams      = xSD.GetResponseTeams();
            Dispatches         = xSD.GetDispatches();
            DispatchReports    = xSD.GetDispatchReports();
            BaseStationRecords = xSD.GetBaseStationRecords();
            Patients           = xSD.GetPatients();
            Managers           = xSD.GetManagers();
        }
示例#7
0
        // FUNCTIONAL METHODS
        //This method is called from the outside and has the data to be populated.
        public void PopulateSideBar(ref Shared_Data xSD, List <Type> xAcccessibleViews, Employee xUser)
        {
            SD = xSD;

            // To-Do: If an EMT, show a Response Team ID to which they belong.
            lbUser.Text        = xUser.GetName() + " " + xUser.GetLast_Name();
            lbAccessLevel.Text = xUser.GetType().ToString();

            layoutPanel.Width       = this.Width;
            layoutPanel.BorderStyle = BorderStyle.None;

            PopulateMenu(xAcccessibleViews);
        }
示例#8
0
        //


        // CONSTRUCTOR
        public Employees_Data(ref Shared_Data xSD)
        {
            SetupOperators(xSD.GetOperators());
            SetupSupervisors(xSD.GetSupervisors());
            SetupEMTs(xSD.GetEMTs());
            SetupManagers(xSD.GetManagers());

            // TEST SUPER USER: FAKE EMPOYEE
            Employee fakePerson = new Employee();

            fakePerson.SetName("Fake");
            fakePerson.SetLast_Name("Employee");
            fakePerson.SetAddress("Cupertino, California");

            FakeEmpoyee = Tuple.Create(fakePerson, 666, string.Empty);
            //
        }
 public void UpdateSD(Shared_Data xSD)
 {
     SD = xSD;
 }
 public Emergency_Management_Form(ref Shared_Data xSD) : base(ref xSD, "Emergency Management")
 {
     InitializeComponent();
 }
示例#11
0
        public Response_Team_Information_Form(Emergency xEmergency, Response_Team xRT, ref Shared_Data xSD) : this(ref xSD)
        {
            InitializeComponent();

            Name          = "Receive Call";
            Emergency     = xEmergency;
            Response_Team = xRT;

            // RE-DO THIS
            int j = 0;
            for (int i = 0; i < SD.OpenForms.GetLength(0); i++)
            {
                if (SD.OpenForms[0, i] != null)
                {
                    j++;
                }
            }

            CWFs = new Emergency_Management_Form[j];

            for (int i = 0; i < SD.OpenForms.GetLength(0); i++)
            {
                if (SD.OpenForms[0, i] != null)
                {
                    CWFs[i] = (Emergency_Management_Form)SD.OpenForms[0, i];
                }
            }
        }
示例#12
0
        //


        // FUNCTIONAL METHODS
        public void SetSideBar(ref Shared_Data xSD, List <Type> xAcccessibleViews, Employee xUser)
        {
            Current_User = xUser;

            sideBar.PopulateSideBar(ref SD, xAcccessibleViews, Current_User);
        }
示例#13
0
 public LinkPatient(ref Shared_Data xSD) : base(ref xSD, "Link Patient")
 {
     InitializeComponent();
 }