chakanjiluneirong.aspx.cs
资源名称:OASystem.rar [点击查看]
上传用户:lishan0805
上传日期:2019-12-08
资源大小:12048k
文件大小:2k
源码类别:
OA系统
开发平台:
C#
- using System;
- using System.Data;
- using System.Configuration;
- using System.Collections;
- using System.Web;
- using System.Web.Security;
- using System.Web.UI;
- using System.Web.UI.WebControls;
- using System.Web.UI.WebControls.WebParts;
- using System.Web.UI.HtmlControls;
- using COM.OA.BLL;
- using System.Collections.Generic;
- using COM.OA.Entity;
- public partial class chakanjiluneirong : System.Web.UI.Page
- {
- protected void Page_Load(object sender, EventArgs e)
- {
- //接收消息ID
- string idd=this.Request["id"];
- //判断是否为空
- if (idd != null && idd!="")
- {
- //格式化ID为int类型
- int id = Int32.Parse(idd);
- //设置WHERE语句
- string where = "m_id='{0}'";
- where = string.Format(where, id);
- //查询数据库
- IList<message> list = messageBLL.Select(where);
- //判断是否为空
- if (list.Count != 0)
- {
- //用实体接收显示
- message m = list[0];
- m.m_isreturn = 1;
- messageBLL.Update(m);
- this.txt_biaoti.Text = m.m_title;
- this.txt_neirong.Text = m.m_content;
- //把发送人ID转换成中文名字
- users uu = usersBLL.Select(m.m_u_id);
- this.txt_fabiaoren.Text = uu.u_username;
- }
- //如果为空,显示数据库中无此数据
- else
- {
- this.Response.Write(string.Format(GetRedirect.WINALERT, "数据库中无此数据"));
- }
- }
- //如果接收的发送消息ID为空,跳回发送记录页
- else
- {
- this.Response.Write(string.Format(GetRedirect.REDIRECT,"jieshouxinxi.aspx"));
- }
- }
- }