⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 update_mend.jsp~49~

📁 一个完整的门户网站,基于JSP环境下开发的,使用SQL数据库.
💻 JSP~49~
字号:
<%@ page contentType="text/html; charset=GBK" %>
<%@ page import="com.bwm.model.Mend" %>
<%@ page import="com.bwm.model.Ssort" %>
<%@ page import="com.bwm.core.*" %>
<%@ page import="java.util.*" %>
<%if (!Crazyadept.UserIsOK(session,FinalConstants.STATUS_ADMIN)) return;%>
<html>
<head>
<title>update_soft</title>
</head>
<link href="../css/admin.css" rel="stylesheet" type="text/css">
<script src="../js/validate.js"></script>
<body> 
<%
String uid=ParamUtils.getRequestString(request,"mid");
BasetableFactory bf=BasetableFactory.getInstance();
Mend u=bf.SearchMend("WHERE mid='"+uid+"'");
session.removeAttribute("error");
if(u==null||u.getMid()==null||"".equals(u.getMid())){
        session.setAttribute("error","查找失败");
        response.sendRedirect("error.jsp");
}else{
%> 
<table border="1" align="center" cellpadding="0" cellspacing="0" class="tableBorder3"> 
  <tr align="center"> 
    <td colspan="2" class="TableTitle1" >添加新工具软件</td> 
  </tr> 
  <form action="modify_mend.jsp" method="post" name="forms"> 
    <tr align="center"> 
      <td width="23%">软件名称</td> 
      <td align="left"><input name="name" type="text" value="<%=u.getName()%>"></td> 
    </tr> 
    <tr align="center"> 
      <td>软件类别</td> 
      <td align="left"><select name="sid"> 
          <%
Collection coll=bf.ListSsort("");
if(coll==null||coll.size()<=0){
    out.print("<option>无软件类别</option>");
}else{
    out.print("<option>—请选择—</option>");
    Iterator it=coll.iterator();
    while(it.hasNext()){
        Ssort s=(Ssort)it.next();
        out.print("<option value='"+s.getSid()+"' "+(s.getSid()==u.getSid()?"selected":"")+">"+s.getName()+"</option>)");
    }
}%> 
        </select></td> 
    </tr> 
    <tr align="center"> 
      <td>软件类型</td> 
      <td align="left"><input type="radio" name="state" value="<%=FinalConstants.STATE_TOOL%>" <%=(u.getState()==FinalConstants.STATE_TOOL?"checked":"")%>> 
        工具
        <input name="state" type="radio" value="<%=FinalConstants.STATE_MEND%>"  <%=(u.getState()==FinalConstants.STATE_MEND?"checked":"")%>> 
        补丁</td> 
    </tr> 
    <tr align="center"> 
      <td>推荐指数</td> 
      <td align="left"><select name="commend"> 
          <option value="1" <%=u.getCommend()==1?"selected":""%>>1</option> 
          <option value="2" <%=u.getCommend()==2?"selected":""%>>2</option> 
          <option value="3" <%=u.getCommend()==3?"selected":""%>>3</option> 
          <option value="4" <%=u.getCommend()==4?"selected":""%>>4</option> 
          <option value="5" <%=u.getCommend()==5?"selected":""%>>5</option> 
        </select></td> 
    </tr> 
    <tr align="center"> 
      <td>程序大小</td> 
      <td align="left"><input name="filesize" type="text" value="<%=u.getFilesize()%>" onBlur="return filesizes()"> 
        (MB)</td> 
    </tr> 
    <tr align="center"> 
      <td>其它说明</td> 
      <td align="left"><textarea name="resume" cols="50" rows="5"><%=u.getResume()%></textarea></td> 
    </tr> 
    <tr align="center"> 
      <td height="27" colspan="2"> <input type="hidden" name="mid" value="<%=u.getMid()%>"> 
        <input type="hidden" name="action" value="modify"> 
        <input type="submit" name="Submit" value="提交" onClick="return mend()"> 
&nbsp;&nbsp; 
        <input type="reset" name="Submit2" value="重置"> </td> 
    </tr> 
  </form> 
</table> 
<table width="80%"  border="0" cellspacing="0" cellpadding="0"> 
  <tr> 
    <td height="50" colspan="5" align="right"><a href="#" onClick="Jscript:history.back()">返回</a></td> 
  </tr> 
</table> 
<%}%> 
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -