一些前端后端的tips
//String usergender= request.getParameter(“usergender”);form表的input的值取出存入后端 //request.getSession().setAttribute(“usermail”, usermail); 取session值 //request.getSession().setAttribute(“usertype”, usertype); //model.addAttribute(“borrowlist”, usermail);后端计算的值显示到前端 //int id1=Integer.valueOf(userservice.getID(usermail)).intValue(); //存session //request.getSession().setAttribute(“usermail”, usermail); //request.getSession().setAttribute(“usertype”, usertype); //取session //String usermail = (String)request.getSession().getAttribute(“usermail”); //model.addAttribute(“usertype”, usertype);
Insert title here
<span class="heading">用户登录</span>
<div class="form-group">
<input type="text" class="form-control" id="Input1" name="classname" placeholder="请输入班级名称">
<i class="fa fa-user"></i>
</div>
<div class="form-group">
<input type="text" class="form-control" id="Input1" name="teacherid" placeholder="请输入任课老师邮箱">
<i class="fa fa-user"></i>
</div>
<div class="form-group">
<input type="text" class="form-control" id="Input1" name="classtype" placeholder="请输入班级类型">
<i class="fa fa-user"></i>
</div>
<div class="form-group">
<input type="text" class="form-control" id="Input1" name="information" placeholder="请输入简介">
<i class="fa fa-user"></i>
</div>
<div class="form-group">
<input type="text" class="form-control" id="Input1" name="picture" placeholder="请上传图片">
<i class="fa fa-user"></i>
</div>
<div class="form-group">
<button type="submit" name="create" class="btn btn-default">创建班级</button>
</div>
</form>
</div>
</div>
Insert title here
<thead>
<tr>
<th>收藏序号</th>
<th>论文题目</th>
<th>论文序号</th>
<th>收藏时间</th>
<th>了解更多</th></tr>
</thead>
<tbody>
<tr th:each="i:${mypaperlist}">
<td th:text="${i.id}"></td>
<td th:text="${i.title}"></td>
<td th:text="${i.paperid}"></td>
<td th:text="${i.createtime}"></td>
<td>
<div class="submit_dec">
<form action="/paperdetail" enctype='multipart/form-data' method='POST'>
<input type="submit" name="paperid" th:value="${i.paperid}" class="submit_hide">查看详情</form></div>
</td></tr>
</tbody>
</table>
</div>
|