?? myaccount.aspx.cs
字號:
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 BookManage.BLL;
using BookManage.Model;
public partial class MyAccount : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
BookBusiness business = new BookBusiness();
lentList.DataSource = business.GetBookLendListByUserName(User.Identity.Name);
lentList.DataBind();
}
}
protected void lentList_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
BookLentInfo lentInfo = (BookLentInfo)e.Row.DataItem;
if (lentInfo.EndTime <=DateTime.Today)
{
e.Row.Cells[3].Text = "<span class=\"red\">" + lentInfo.EndTime.ToString("yyyy-M-dd HH:mm:ss") + "</span>";
}
}
}
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -