forked from CheckmarxDemo/bookstore
-
Notifications
You must be signed in to change notification settings - Fork 2
/
BookMaint.aspx
150 lines (131 loc) · 6.12 KB
/
BookMaint.aspx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
<%@ Page language="c#" Inherits="Book_Store.BookMaint" CodeFile="BookMaint.cs" %>
<%@ Register TagPrefix="CC" TagName="Header" Src="Header.ascx" %><%@ Register TagPrefix="CC" TagName="Footer" Src="Footer.ascx" %><%@Register TagPrefix="CC" TagName="Pager" Src="CCPager.ascx"%>
<html>
<head>
<title>Book Store</title>
<meta name=vs_targetSchema content="http://schemas.microsoft.com/intellisense/ie3-2nav3-0">
<meta name="GENERATOR" content="YesSoftware CodeCharge v.2.0.5 using 'ASP.NET C#.ccp' build 9/27/2001">
<meta name="CODE_LANGUAGE" Content="C#">
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"></head>
<body style="background-color: #FFFFFF; color: #000000; font-family: Arial, Tahoma, Verdana, Helveticabackground-color: #FFFFFF; color: #000000; font-family: Arial, Tahoma, Verdana, Helvetica">
<form method="post" runat="server">
<CC:Header id="Header" runat="server"/>
<input type=hidden id=p_Book_item_id runat=server />
<table><tr><td valign="top" >
<table id="Book_holder" runat="Server" style="width:100%">
<tr><td colspan=2 style="background-color: #336699; text-align: Center; border-style: outset; border-width: 1"><font style="font-size: 12pt; color: #FFFFFF; font-weight: bold"><asp:label id="BookForm_Title" runat="server">Book</asp:label></font><br>
</td></tr>
<tr><td colspan="2" style="background-color: #FFFFFF; border-width: 1">
<asp:Label id=Book_ValidationSummary style="background-color: #FFFFFF; border-width: 1" runat="server" Visible="false"></asp:Label>
<input type="Hidden" id="Book_item_id" value="" runat="server">
</td></tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Title</font>
<asp:RequiredFieldValidator id=Book_name_Validator_Req runat="server" ErrorMessage="The value in field Title is required." ControlToValidate="Book_name" display="None" EnableClientScript="False"></asp:RequiredFieldValidator></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:TextBox
id=Book_name
Columns=30 MaxLength=100
runat="server"/>
</td>
</tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Author</font></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:TextBox
id=Book_author
Columns=30 MaxLength=100
runat="server"/>
</td>
</tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Category</font>
<asp:RequiredFieldValidator id=Book_category_id_Validator_Req runat="server" ErrorMessage="The value in field Category is required." ControlToValidate="Book_category_id" display="None" EnableClientScript="False"></asp:RequiredFieldValidator>
<asp:CustomValidator id=Book_category_id_Validator_Num OnServerValidate="ValidateNumeric" runat="server" EnableClientScript="False" ErrorMessage="The value in field Category is incorrect." ControlToValidate="Book_category_id" display="None"></asp:CustomValidator ></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:DropDownList style="font-size: 10pt; color: #000000"
id=Book_category_id
DataTextField="name"
DataValueField="category_id"
runat="server"/>
</td>
</tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Price</font>
<asp:RequiredFieldValidator id=Book_price_Validator_Req runat="server" ErrorMessage="The value in field Price is required." ControlToValidate="Book_price" display="None" EnableClientScript="False"></asp:RequiredFieldValidator>
<asp:CustomValidator id=Book_price_Validator_Num OnServerValidate="ValidateNumeric" runat="server" EnableClientScript="False" ErrorMessage="The value in field Price is incorrect." ControlToValidate="Book_price" display="None"></asp:CustomValidator ></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:TextBox
id=Book_price
Columns=10
runat="server"/>
</td>
</tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Product URL</font></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:TextBox
id=Book_product_url
Columns=40 MaxLength=100
runat="server"/>
</td>
</tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Image URL</font></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:TextBox
id=Book_image_url
Columns=40 MaxLength=100
runat="server"/>
</td>
</tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Notes</font></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:TextBox id=Book_notes
style="font-size: 10pt; color: #000000" TextMode=MultiLine Rows=8 Columns=60 runat="server">
</asp:TextBox>
</td>
</tr>
<tr>
<td style="background-color: #FFEAC5; border-style: inset; border-width: 0"><font style="font-size: 10pt; color: #000000">Recommended</font></td>
<td style="background-color: #FFFFFF; border-width: 1">
<asp:CheckBox style="font-size: 10pt; color: #000000" id=Book_is_recommended runat="server"/>
</td>
</tr>
<tr><td align=right colspan=2 >
<input type="button"
id=Book_insert
Value="Add"
runat="server" >
<input type="button"
id=Book_update
Value="Update"
runat="server" >
<input type="button"
id=Book_delete
Value="Delete"
runat="server" >
<input type="button"
id=Book_cancel
Value="Cancel"
runat="server" >
</td></tr>
</table>
<SCRIPT Language="JavaScript">
if (document.forms["Book"])
document.Book.onsubmit=delconf;
function delconf() {
if (document.Book.FormAction.value == 'delete')
return confirm('Delete record?');
}
</SCRIPT>
</td>
</tr></table>
<CC:Footer id="Footer" runat="server"/>
</form>
</body>
</html>