예제 #1
0
        protected void gvList_RowDeleting(object sender, GridViewDeleteEventArgs e)
        {
            GridView gv  = (GridView)sender;
            Int32    _id = (int)gv.DataKeys[e.RowIndex].Value;

            BllProxyGroupFacility.SetGroupFacility(_id, facilityId, false);

            setFacilityGroups(facilityId);
            this.showTextMessage("Group has been removed");

            e.Cancel = true;
        }
        ///---------------------------------------------------------------------------------
        protected void gvList_RowEditing(object sender, GridViewEditEventArgs e)
        {
            GridView gv  = (GridView)sender;
            Int32    _id = (int)gv.DataKeys[e.NewEditIndex].Value;


            BllProxyGroupFacility.SetGroupFacility(groupId, _id, true);

            setGroupFacilities(groupId);
            this.showTextMessage("Facility has been added");

            e.Cancel = true;
        }
예제 #3
0
        public void UcDataBind()
        {
            GroupDS.GroupFacilityDSDataTable dt = BllProxyGroupFacility.GetAllGroupFacilities(facilityId);

            if (dt.Rows.Count != 0)
            {
                objectdatasourceList.SelectParameters.Clear();
                objectdatasourceList.SelectParameters.Add("facility_id", facilityId.ToString());

                gvList.Sort(sortExpression, sortDirection);
            }
            else
            {
                this.showErrorMessage("Facility does not exist!");
            }
        }
        public void UcDataBind()
        {
            GroupDS.GroupFacilityDSDataTable dt = BllProxyGroupFacility.GetAllGroupFacilities(groupId);

            if (dt.Rows.Count != 0)
            {
                //lblSurvey.Text = dt[0].survey_name;

                objectdatasourceList.SelectParameters.Clear();
                objectdatasourceList.SelectParameters.Add("group_id", groupId.ToString());

                gvList.Sort(sortExpression, sortDirection);
            }
            else
            {
                this.showErrorMessage("Group does not exist!");
            }
        }