public void PublishPolicy(string plid)
    {
        int  PLID = Convert.ToInt32(plid);
        bool flag = BG_PolicyLogic.PublishAppointPolicy(PLID);

        PolicyDataBind();
    }
    /// <summary>
    /// 绑定数据
    /// </summary>
    private void PolicyDataBind()
    {
        DataTable dt    = BG_PolicyLogic.GetAllPolicy();
        Store     store = this.gridpanel1.GetStore();

        store.DataSource = dt;
        store.DataBind();
    }
    private void UniformRulesDataBind()
    {
        DataTable dt = BG_PolicyLogic.GetUniformRulesDT();

        if (dt.Rows.Count > 0)
        {
            string str = dt.Rows[0]["PContent"].ToString();
            HEdit.Text = str;
        }
    }
Exemplo n.º 4
0
 protected void Page_Load(object sender, EventArgs e)
 {
     if (!X.IsAjaxRequest)
     {
         DataTable dt    = BG_PolicyLogic.GetAllPolicy();
         Store     store = this.GridPanel1.GetStore();
         store.DataSource = dt;
         store.DataBind();
         //if (dt.Rows.Count > 0)
         //{
         //    string PTitle = dt.Rows[0]["PTitle"].ToString();
         //    string PContent = dt.Rows[0]["PContent"].ToString();
         //}
     }
 }
Exemplo n.º 5
0
    private void UniformRulesDataBind()
    {
        DataTable dt = BG_PolicyLogic.GetUniformRulesDT();

        if (dt.Rows.Count > 0)
        {
            string str = dt.Rows[0]["PContent"].ToString();
            //plContent.Html = str;
            //KJEditor.Html = str;
            ctext = str;
        }
        else
        {
            btnModUR.Visible = false; X.Msg.Alert("系统提示", "管理员未填写任何口径").Show();
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        if (!X.IsAjaxRequest)
        {
            Kv        k  = new Kv();
            DataTable dt = BG_PolicyLogic.GetAllPolicy();
            for (int i = 0; i < 100; i++)
            {
                dt.Rows[0]["PTitle"] = k.Key + i;
                dt.Rows[0]["PTitle"] = k.Val + i;
            }

            Store store = this.GridPanel1.GetStore();
            store.DataSource = dt;
            store.DataBind();
        }
    }
    protected void btnMod_DirectClick(object sender, Ext.Net.DirectEventArgs e)
    {
        DataTable dt        = BG_PolicyLogic.GetUniformRulesDT();
        string    idStr     = dt.Rows[0]["PLID"].ToString();
        int       PLID      = Convert.ToInt32(idStr);
        string    str       = HEdit.Text;
        BG_Policy bg_Policy = BG_PolicyManager.GetBG_PolicyByPLID(PLID);

        bg_Policy.PContent = str;
        //KJEditor.Html = str;
        bg_Policy.PTime = DateTime.Now;
        //消息提示
        BG_PolicyManager.ModifyBG_Policy(bg_Policy);
        UniformRulesDataBind();
        X.Msg.Alert("提示", "修改成功").Show();
        Response.Redirect("PLUniformRules.aspx", true);
    }