📄 booklist.aspx
字号:
<%@ Register TagPrefix="MyBookShop" TagName="HeaderMenu" Src="UserControls/HeaderMenu.ascx" %>
<%@ Page Language="c#" Inherits="MyBookShop.Web.BookList" CodeFile="BookList.aspx.cs" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" >
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
<title>浏览图书|</title>
<link href="Styles/Style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<form id="Form1" method="post" runat="server">
<table id="Table1" style="z-index: 101; left: 8px; position: static;
top: 8px;" cellspacing="0" cellpadding="0" width="504" border="0">
<tr>
<td colspan="4" style="height: 58px; text-align: center">
<asp:Image ID="Image1" runat="server" ImageUrl="~/Images/banner.JPG" /></td>
</tr>
<tr>
<td colspan="4" style="height: 36px; text-align: center;">
<MyBookShop:HeaderMenu ID="headerMenu" runat="server" ></MyBookShop:HeaderMenu>
</td>
</tr>
<tr>
<td style="width: 133px; height: 16px;">
>>浏览图书</td>
<td style="width: 142px; height: 16px;">
</td>
<td style="width: 196px; height: 16px;">
</td>
<td style="width: 1px; height: 16px;">
</td>
</tr>
<tr style="background-color: aqua">
<td colspan="1" rowspan="1" style="height: 21px; background-color: olive; width: 133px;">
※书名:
<asp:TextBox ID="TextBoxBookName" runat="server" Width="66px"></asp:TextBox></td>
<td style="height: 21px; background-color: olive; width: 142px;" colspan="1" rowspan="1">
※类别:
<asp:DropDownList ID="DropDownListCategory" runat="server" style="text-align: right" Height="5px">
</asp:DropDownList></td>
<td style="height: 21px; background-color: olive; width: 196px;">
※排序:
<asp:DropDownList ID="DropDownListSortColumn" runat="server">
<asp:ListItem Value="SaleCount">销量</asp:ListItem>
<asp:ListItem Value="PublishDate">出版日期</asp:ListItem>
<asp:ListItem Value="Price">价格</asp:ListItem>
</asp:DropDownList><asp:DropDownList ID="DropDownListSortType" runat="server">
<asp:ListItem Value="Desc">递减</asp:ListItem>
<asp:ListItem Value="Asc">递增</asp:ListItem>
</asp:DropDownList></td>
<td style="height: 21px; background-color:blue; width: 1px;">
<asp:Button ID="ButtonQuery" runat="server" Text="查询" Width="48px" OnClick="ButtonQuery_Click">
</asp:Button></td>
</tr>
<tr>
<td colspan="4">
<asp:GridView ID="GV" runat="server" AutoGenerateColumns="False" AllowPaging="True"
PageSize="5" OnPageIndexChanging="GV_PageIndexChanging" BackColor="#DEBA84" BorderColor="#DEBA84" BorderStyle="None" BorderWidth="1px" CellPadding="3" CellSpacing="2" Height="187px" Width="500px">
<Columns>
<asp:TemplateField>
<ItemTemplate>
<asp:CheckBox ID="chkSelected" Checked="False" Visible="True" GroupName="chk" runat="server">
</asp:CheckBox></ItemTemplate>
</asp:TemplateField>
<asp:BoundField DataField="BookId" HeaderText="编号" />
<asp:BoundField DataField="BookName" HeaderText="图书名" />
<asp:BoundField DataField="Author" HeaderText="作者" />
<asp:BoundField DataField="Publisher" HeaderText="出版社" />
<asp:BoundField DataField="PublishDate" HeaderText="出版日期" DataFormatString="{0:yyyy-MM-dd}" />
<asp:BoundField DataField="Price" HeaderText="价格" DataFormatString="{0:C}" />
<asp:HyperLinkField HeaderText="详细信息" DataTextFormatString="详细信息" Text="详细信息" DataNavigateUrlFormatString="BookDetail.aspx?book_id={0}"
DataNavigateUrlFields="BookId" />
</Columns>
<FooterStyle BackColor="#F7DFB5" ForeColor="#8C4510" />
<RowStyle BackColor="#FFF7E7" ForeColor="#8C4510" />
<SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="White" />
<PagerStyle ForeColor="#8C4510" HorizontalAlign="Center" />
<HeaderStyle BackColor="#A55129" Font-Bold="True" ForeColor="White" />
</asp:GridView>
<asp:Label ID="LabelPageInfo" runat="server"></asp:Label></td>
</tr>
<tr style="background-color: aqua">
<td align="left" style="background-color: silver" colspan="2" rowspan="1">
<asp:Button ID="ButtonDelete" runat="server" Text="删除" Width="48px" OnClick="ButtonDelete_Click">
</asp:Button></td>
<td align="right" style="background-color: silver" colspan="2" rowspan="1">
把
<asp:TextBox ID="TextBoxAmount" runat="server" Width="26px">1</asp:TextBox>本选中的图书<asp:Button
ID="ButtonAdd2Cart" runat="server" Text="放入购物车" OnClick="ButtonAdd2Cart_Click"></asp:Button></td>
</tr>
</table>
</form>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -