Example #1
0
    private void LoadBasicData()
    {
        ShiftTypeDA sda = new ShiftTypeDA();

        AllShiftTypes = sda.GetAllShiftType();

        WardDA wda = new WardDA();

        AllWards = wda.GetAllWard();

        StaffingDataDA stda = new StaffingDataDA();

        AllStaffing = stda.GetAllStaffing();

        StaffingDateRangeDA stfda = new StaffingDateRangeDA();

        AllStaffingDateRanges = stfda.GetAllStaffingDateRanges();

        //string safeMitigations = WebConfigurationManager.AppSettings["SafeMitigationActions"];
        //this.SafeMitigations = new List<string>();
        //this.SafeMitigations.AddRange(safeMitigations.Split('|'));

        MitigationActionsDA mtada = new MitigationActionsDA();

        this.UnSafeMitigations = mtada.GetAllMitigationActions();
    }
        private void BindInitialData()
        {
            // Bind users to Grid.
            WardDA wda = new WardDA();

            currentWards             = wda.GetAllWard();
            WardData_Grid.DataSource = currentWards;
            WardData_Grid.DataBind();
        }
        private void FilterDataGrid()
        {
            WardDA wda = new WardDA();

            currentWards = wda.GetAllWard();

            // Filter by ward name
            if (!string.IsNullOrEmpty(wardNameTextbox.Text))
            {
                currentWards = currentWards.Where(ward
                                                  => ward.WardName.ToUpperInvariant().Contains(wardNameTextbox.Text.ToUpperInvariant())).ToList();
            }

            if (null != currentWards)
            {
                WardData_Grid.DataSource = currentWards;
                WardData_Grid.DataBind();
            }
        }
Example #4
0
        private void BindInitialData()
        {
            // Bind users to Grid.
            WardDA wda = new WardDA();

            currentWards = wda.GetAllWard();

            foreach (Ward ward in currentWards)
            {
                if (ward.WardCode.Equals(ID))
                {
                    WardCode_TextBox.Text = ward.WardCode;
                    WardName_TextBox.Text = ward.WardName;
                    Devision_TextBox.Text = ward.Division;

                    WardDataEntryFound_HiddenField.Text = "true";
                    break;
                }
                else
                {
                    WardDataEntryFound_HiddenField.Text = "false";
                }
            }
        }
Example #5
0
    public void RefreshWardData()
    {
        WardDA wda = new WardDA();

        AllWards = wda.GetAllWard();
    }