示例#1
0
        private void InitializeCarePlanIntervention()
        {
            Client.Core.Individual.Case.MemberCaseCareIntervention carePlanIntervention = CarePlanIntervention;

            if (carePlanIntervention == null)
            {
                return;
            }


            //System.Web.UI.HtmlControls.HtmlControl titlePanel = (System.Web.UI.HtmlControls.HtmlControl)FindControl ("TitlePanel_" + carePlanIntervention.Status.ToString ());

            //if (titlePanel != null) { titlePanel.Visible = true; }


            // MAP PROPERTY VALUES INTO CONTROLS

            // CarePlanInterventionEditName.Text = CarePlanInterventionName.Text = carePlanIntervention.Name;



            CareInterventionAssociationsGrid.Rebind();

            CarePlanInterventionActivitiesGrid.Rebind();

            return;
        }
示例#2
0
        protected void CarePlanInterventionActivitiesGrid_OnItemCommand(Object sender, Telerik.Web.UI.GridCommandEventArgs e)
        {
            if (CarePlanIntervention == null)
            {
                return;
            }

            Mercury.Server.Application.MemberCaseModificationResponse response;

            switch (e.CommandName)
            {
            case Telerik.Web.UI.RadGrid.InitInsertCommandName:

                break;

            case Telerik.Web.UI.RadGrid.PerformInsertCommandName:

                #region Perform Insert of New Intervention


                // RETREIVE REFERENCES TO ALL TEMPLATED CONTROLS

                //RadioButtonList AddCarePlanInterventionTypeSelection = (RadioButtonList)e.Item.FindControl ("AddCarePlanInterventionTypeSelection");

                //if (AddCarePlanInterventionTypeSelection == null) { return; }

                //Telerik.Web.UI.RadTextBox AddCarePlanInterventionName = (Telerik.Web.UI.RadTextBox)e.Item.FindControl ("AddCarePlanInterventionName");

                //if (AddCarePlanInterventionName == null) { return; }

                //Telerik.Web.UI.RadComboBox AddCarePlanInterventionExistingSelection = (Telerik.Web.UI.RadComboBox)e.Item.FindControl ("AddCarePlanInterventionExistingSelection");

                //if (AddCarePlanInterventionExistingSelection == null) { return; }


                //Int64 selectedBaselineInterventionId = (AddCarePlanInterventionTypeSelection.SelectedValue == "0") ? Convert.ToInt64 (AddCarePlanInterventionExistingSelection.SelectedValue) : 0;

                //String carePlanInterventionName = (AddCarePlanInterventionTypeSelection.SelectedValue == "1") ? AddCarePlanInterventionName.Text : String.Empty;


                //response = MercuryApplication.MemberCaseCarePlanIntervention_Add (ParentMemberCasePage.Case, CarePlan.Id, selectedBaselineInterventionId, carePlanInterventionName);

                //if (response.HasException) { ParentMemberCasePage.ExceptionMessage = response.Exception.Message; }

                //else { ParentMemberCasePage.Case = new Client.Core.Individual.Case.MemberCase (MercuryApplication, response.MemberCase); }


                #endregion

                break;

            case Telerik.Web.UI.RadGrid.DeleteCommandName:

                //response = MercuryApplication.MemberCaseCarePlanIntervention_Delete (ParentMemberCasePage.Case, CarePlanIntervention.Activities[e.Item.ItemIndex].Id);

                //if (response.HasException) { ParentMemberCasePage.ExceptionMessage = response.Exception.Message; }

                //else { ParentMemberCasePage.Case = new Client.Core.Individual.Case.MemberCase (MercuryApplication, response.MemberCase); }

                break;

            case Telerik.Web.UI.RadGrid.CancelCommandName:

            case Telerik.Web.UI.RadGrid.RebindGridCommandName:

                CarePlanInterventionActivitiesGrid.DataSource = CarePlanIntervention.Activities;

                CarePlanInterventionActivitiesGrid.DataBind();

                break;

            default:

                break;
            }

            return;
        }