📄 preordain.jsp
字号:
<script language="JavaScript">
function checkadd()
{
if(document.addthis.warename.value.length==0)
{
alert("请填写商品名称");
document.addthis.warename.focus();
return false;
}
if(document.addthis.num.value.length==0)
{
alert("请填写预定商品的数量");
document.addthis.num.focus();
return false;
}
if(document.addthis.pricenum.value.length==0)
{
alert("请告诉我们您希望商品的金额");
document.addthis.pricenum.focus();
return false;
}
if(document.addthis.text.value.length==0)
{
alert("请填写商品说明");
document.addthis.text.focus();
return false;
}
if(document.addthis.yx.value.length==0)
{
alert("请填写商品预定有效期");
document.addthis.yx.focus();
return false;
}
if(document.addthis.mode.value=="no")
{
alert("请选择支付方式");
document.addthis.mode.focus();
return false;
}
}
</script>
<table width="500" border="0" align="center" cellpadding="0" cellspacing="0" class="defaulttext">
<tr>
<td width="40" height="20"><div align="center"><font color="#990000">序号</font></div></td>
<td width="80"><div align="center"><font color="#990000">定单号</font></div></td>
<td width="260"><div align="center"></div></td>
<td width="60"><div align="center"><font color="#990000">定单状态</font></div></td>
<td width="60"><div align="center"><font color="#990000">定单操作</font></div></td>
</tr>
<tr>
<td height="1" bgcolor="#E3E2E2" colspan="6"></td>
</tr>
<%
sql="select * from dingdan where buyid='"+member+"' and preordainShop='"+"1"+"' and send='"+"0"+"'";
rs=data.executeQuery(sql);
int i=0;
id=0;
String censor_yes="";
while(rs.next())
{
i++;
id=rs.getInt("dingdanid");
censor_yes=rs.getString("censor_yes");
if(censor_yes.compareTo("0")==0)
{ censor_yes="<font color='#0000FF'>未审核</font>"; }
else{ censor_yes="<font color='#FF0000'>已审核</font>"; }
%>
<tr>
<td width="40" height="20"><div align="center"><%=i%></div></td>
<td width="80"><div align="center"><a href="javascript:see(<%=id%>)"><%=id%></a></div></td>
<td width="260"><div align="center"></div></td>
<td width="60"><div align="center"><%=censor_yes%></div></td>
<td width="60"><div align="center"><a href="deldingdan.jsp?id=<%=id%>">取消定单</a></div></td>
</tr>
<tr>
<td height="1" bgcolor="#E3E2E2" colspan="6"></td>
</tr>
<%}if(i==0){%>
<div align="center" class="defaulttext"><font color="#FF0000">您尚未预定任何商品</font></div>
<%}%>
</table><br><br><br>
<%
sql="select id,ddnum from manager where name='"+member+"'";
rs=data.executeQuery(sql);
rs.next();
int getid=rs.getInt("id");
int getnum=rs.getInt("ddnum");
rs.close();
getnum=getnum+1;
String num=getid+"000"+getnum;
int numid=Integer.parseInt(num);
%>
<form action="addyuding.jsp" method="post" name="addthis" onSubmit="return checkadd()" enctype="multipart/form-data">
<input type="hidden" name="numid" value="<%=numid%>">
<table width="500" border="0" align="center" cellpadding="0" cellspacing="0" class="defaulttext">
<tr bgcolor="#63bce6">
<td height="25" colspan="3"><div align="center">添加预定商品</div></td>
</tr>
<tr>
<td width="120" height="25"><div align="right">定单ID:</div></td>
<td width="20"></td>
<td><font color="#FF0000"><%=numid%></font></td>
</tr>
<tr>
<td height="25"><div align="right">商品名称:</div></td>
<td></td>
<td><input type="text" size="20" name="warename" maxlength="50" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva"></td>
</tr>
<tr>
<td height="25"><div align="right">数量:</div></td>
<td></td>
<td><input type="text" size="1" name="num" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva">
件(个)</td>
</tr>
<tr>
<td height="25"><div align="right">价格:</div></td>
<td></td>
<td><select name="price" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva">
<option value="少于">少于</option>
<option value="超过">超过</option>
</select> <input name="pricenum" type="text" id="pricenum" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva" size="1">
元 </td>
</tr>
<tr>
<td height="25" valign="top"><div align="right">商品说明:</div></td>
<td></td>
<td><textarea name="text" cols="50" rows="10" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva"></textarea></td>
</tr>
<tr>
<td height="25"><div align="right">预定有效期:</div></td>
<td></td>
<td><input name="yx" type="text" id="yx" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva" size="1">
<select name="yxdate" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva">
<option value="天">天</option>
<option value="周">周</option>
<option value="月">月</option>
<option value="年">年</option>
</select></td>
</tr>
<tr>
<td height="25"><div align="right">交易方式:</div></td>
<td></td>
<td><select name="mode" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva">
<option value="no">请选择</option>
<%
sql="select * from mode";
rs=data.executeQuery(sql);
String mode="";
while(rs.next())
{
mode=rs.getString("mode");
%>
<option value="<%=mode%>"><%=mode%></option>
<%} %>
</select></td>
</tr>
<tr>
<td height="25"><div align="right">参考图片:</div></td>
<td></td>
<td><input type="file" name="pic" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva" size="40"></td>
</tr>
<tr>
<td height="15" colspan="3"></td>
</tr>
<tr>
<td height="25" colspan="3"><div align="center"><input type="submit" value="提交预定单" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva">
<input type="reset" value="取消" style="background-color:#ECECEC; border-style:1; font-size: 11; color: #000000; font-family: arial, verdana, geneva"></div></td>
</tr>
</table>
</form>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -