public void BindGroupListGrid()
    {
        messageContent.InnerHtml = "";
        _hotelGroupEntity.LogMessages = new HotelVp.Common.Logger.LogMessage();
        _hotelGroupEntity.LogMessages.Userid = UserSession.Current.UserAccount;
        _hotelGroupEntity.LogMessages.Username = UserSession.Current.UserDspName;
        _hotelGroupEntity.LogMessages.IpAddress = UserSession.Current.UserIP;
        _hotelGroupEntity.HotelGroupDBEntity = new List<HotelGroupDBEntity>();
        HotelGroupDBEntity hotelGroupDBEntity = new HotelGroupDBEntity();
        hotelGroupDBEntity.HotelGroupID = "";
        _hotelGroupEntity.HotelGroupDBEntity.Add(hotelGroupDBEntity);

        DataSet dsResult = HotelGroupBP.Select(_hotelGroupEntity).QueryResult;

        gridViewCSHGroupList.DataSource = dsResult.Tables[0].DefaultView;
        gridViewCSHGroupList.DataKeyNames = new string[] { "ID" };//主键
        gridViewCSHGroupList.DataBind();

        if (!String.IsNullOrEmpty(refushFlag.Value))
        {
            if ("1".Equals(hiddenType.Value.Trim()))
            {
                messageContent.InnerHtml = GetLocalResourceObject("InsertSuccess").ToString();
            }
            else
            {
                messageContent.InnerHtml = GetLocalResourceObject("UpdateSuccess").ToString();
            }

            refushFlag.Value = "";
            hiddenType.Value = "";
        }
    }
    public void btnUpdateChannel(string actionType)
    {
        _hotelGroupEntity.HotelGroupDBEntity = new List<HotelGroupDBEntity>();

        _hotelGroupEntity.LogMessages = new HotelVp.Common.Logger.LogMessage();
        _commonEntity.LogMessages = new HotelVp.Common.Logger.LogMessage();
        _hotelGroupEntity.LogMessages.Userid = UserSession.Current.UserAccount;
        _hotelGroupEntity.LogMessages.Username = UserSession.Current.UserDspName;
        _hotelGroupEntity.LogMessages.IpAddress = UserSession.Current.UserIP;
        _hotelGroupEntity.HotelGroupDBEntity = new List<HotelGroupDBEntity>();

        HotelGroupDBEntity hotelGroupDBEntity = new HotelGroupDBEntity();

        hotelGroupDBEntity.HotelGroupID = hidGroupNo.Value;
        hotelGroupDBEntity.Name_CN = txtHotelGroupNM.Value.Trim();
        hotelGroupDBEntity.HotelGroupCode = txtHotelGroupCode.Value.Trim();
        hotelGroupDBEntity.Description = txtDescribe.Text.Trim();
        hotelGroupDBEntity.BandType = ddpGroupTypeList.SelectedValue;
        hotelGroupDBEntity.OnlineStatus = ddpStatusList.SelectedValue;
        hotelGroupDBEntity.Type = actionType;
        _hotelGroupEntity.HotelGroupDBEntity.Add(hotelGroupDBEntity);

        int iResult = "2".Equals(actionType) ? HotelGroupBP.Insert(_hotelGroupEntity) : HotelGroupBP.Update(_hotelGroupEntity);

        _commonEntity.LogMessages = _hotelGroupEntity.LogMessages;
        _commonEntity.CommonDBEntity = new List<CommonDBEntity>();
        CommonDBEntity commonDBEntity = new CommonDBEntity();

        commonDBEntity.Event_Type = "酒店集团管理-修改";
        commonDBEntity.Event_ID = hidGroupNo.Value;

        //detailMessageContent.InnerHtml = "支付方式更新成功!";
        string conTent = "";
        if (String.IsNullOrEmpty(hidGroupNo.Value))
        {
            conTent = GetLocalResourceObject("EventInsertMessage").ToString();
        }
        else
        {
            conTent = GetLocalResourceObject("EventUpdateMessage").ToString();
        }

        conTent = string.Format(conTent, txtHotelGroupNM.Value, txtHotelGroupCode.Value, ddpGroupTypeList.SelectedValue);
        commonDBEntity.Event_Content = conTent;

        if (iResult == 1)
        {
            Response.Write("<script>window.returnValue=true;window.opener = null;window.close();</script>");
            if (String.IsNullOrEmpty(hidGroupNo.Value))
            {
                commonDBEntity.Event_Result = GetLocalResourceObject("InsertSuccess").ToString();
            }
            else
            {
                commonDBEntity.Event_Result = GetLocalResourceObject("UpdateSuccess").ToString();
            }
        }
        else if (iResult == 2)
        {
            detailMessageContent.InnerHtml = GetLocalResourceObject("UpdateError2").ToString();
            commonDBEntity.Event_Result = GetLocalResourceObject("UpdateError2").ToString();
        }
        else
        {
            detailMessageContent.InnerHtml = GetLocalResourceObject("UpdateError").ToString();
            commonDBEntity.Event_Result = GetLocalResourceObject("UpdateError").ToString();
        }
        _commonEntity.CommonDBEntity.Add(commonDBEntity);
        CommonBP.InsertEventHistory(_commonEntity);
    }
    private void BindHotelGroupDetail(string HotelGroupID, string strType)
    {
        _hotelGroupEntity.LogMessages = new HotelVp.Common.Logger.LogMessage();
        _hotelGroupEntity.LogMessages.Userid = UserSession.Current.UserAccount;
        _hotelGroupEntity.LogMessages.Username = UserSession.Current.UserDspName;
        _hotelGroupEntity.LogMessages.IpAddress = UserSession.Current.UserIP;
        _hotelGroupEntity.HotelGroupDBEntity = new List<HotelGroupDBEntity>();
        HotelGroupDBEntity hotelGroupDBEntity = new HotelGroupDBEntity();
        hotelGroupDBEntity.HotelGroupID = HotelGroupID;
        _hotelGroupEntity.HotelGroupDBEntity.Add(hotelGroupDBEntity);

        DataSet dsMainResult = HotelGroupBP.Select(_hotelGroupEntity).QueryResult;
        if (dsMainResult.Tables.Count > 0 && dsMainResult.Tables[0].Rows.Count > 0)
        {
            txtHotelGroupNM.Value = dsMainResult.Tables[0].Rows[0]["GROUPNM"].ToString();
            txtHotelGroupCode.Value = dsMainResult.Tables[0].Rows[0]["GROUPCODE"].ToString();
            ddpGroupTypeList.SelectedValue = dsMainResult.Tables[0].Rows[0]["BANDTYPE"].ToString();
            ddpStatusList.SelectedValue = dsMainResult.Tables[0].Rows[0]["STATUS"].ToString();
            txtDescribe.Text = dsMainResult.Tables[0].Rows[0]["GROUPDESC"].ToString();
        }
        else
        {
            detailMessageContent.InnerHtml = GetLocalResourceObject("WarningMessage").ToString();
            //btnDelete.Visible = false;
            btnUpdate.Visible = false;
        }
    }