Example #1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        CheckRole("sysmessage");

        if (!Page.IsPostBack)
        {

            this.Button3.Attributes.Add("onclick", "Javascript:return adminmessage();");
            if (Request.QueryString["M_ID"] != null && Request.QueryString["M_ID"].ToString() != "")
            {
                XYECOM.Business.Message m = new XYECOM.Business.Message();
                XYECOM.Model.MessageInfo emy = new XYECOM.Model.MessageInfo();

                emy = m.GetItem(Convert.ToInt64(Request.QueryString["M_ID"].ToString()));

                if (emy != null)
                {
                    this.U_ID.Value = emy.U_ID.ToString();
                    this.username.InnerText = emy.M_UserName.ToString();
                    this.title.Text = "回复:" + emy.M_Title.ToString();
                    if (emy.M_PHMa.ToString() != "")
                    {
                        this.phone.InnerText = emy.M_PHMa.ToString();
                    }
                    this.moblie.InnerText = emy.M_Moblie.ToString();
                    this.info.InnerHtml = emy.M_Content.ToString();
                    this.addtime.InnerText = emy.M_AddTime.ToShortDateString();
                }

                m.Update(Convert.ToInt64(XYRequest.GetQueryString("M_ID")));
            }
        }
    }
Example #2
0
    protected void Page_Load(object sender, EventArgs e)
    {
        CheckRole("sysmessage");

        if (!IsPostBack)
        {
            if (Request.QueryString["M_ID"] != null && Request.QueryString["M_ID"].ToString() != "")
            {

                XYECOM.Business.Message m = new XYECOM.Business.Message();
                XYECOM.Model.MessageInfo em = new XYECOM.Model.MessageInfo();
                em = m.GetItem(Convert.ToInt64(Request.QueryString["M_ID"]));
                if (em != null)
                {
                    this.username.InnerText = em.M_Title.ToString();
                    this.info.InnerHtml = em.M_Content.ToString();
                    this.addtime.InnerText = em.M_AddTime.ToShortDateString();
                    if (em.M_HasReply.ToString().ToLower() == "true")
                        this.HasReply.InnerHtml = "已查看";
                    else
                        this.HasReply.InnerHtml = "未查看";

                }
            }
        }
    }