SpringMVC----RESTFUL_CRUD_修改操作
2021-05-20 15:28
阅读:458
YPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
标签:lan why body str 信息 html4 文件中 orm BMI
1.注意:
2.代码:
list.jsp pageEncoding="UTF-8"%>Insert title here
ID | LastName | Gender | Department | Edit | Delete | |
---|---|---|---|---|---|---|
${emp.id } | ${emp.lastName } | ${emp.email } | ${emp.gender == 0 ? ‘Female‘ : ‘Male‘ } | ${emp.department.departmentName } | Edit | class="delete" href="http://www.soscw.com/emp/${emp.id}">Delete |
Add New Employee input.jsp import="java.util.HashMap"%> import="java.util.Map"%> pageEncoding="UTF-8"%>
email:
Map
Department:
java代码: package com.yikuan.springmvc.crud.handlers; import java.util.Map; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Controller; import org.springframework.web.bind.annotation.ModelAttribute; import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestParam; import com.yikuan.springmvc.crud.dao.DepartmentDao; import com.yikuan.springmvc.crud.dao.EmployeeDao; import com.yikuan.springmvc.crud.entities.Employee; @Controller public class EmployeeHandler { @Autowired private EmployeeDao employeeDao; @Autowired private DepartmentDao departmentDao; @ModelAttribute public void getEmployee(@RequestParam(value="id",required=false)Integer id, Map
SpringMVC----RESTFUL_CRUD_修改操作
标签:lan why body str 信息 html4 文件中 orm BMI
原文地址:https://www.cnblogs.com/yikuan-919/p/9741153.html
文章来自:搜素材网的编程语言模块,转载请注明文章出处。
文章标题:SpringMVC----RESTFUL_CRUD_修改操作
文章链接:http://soscw.com/index.php/essay/87921.html
文章标题:SpringMVC----RESTFUL_CRUD_修改操作
文章链接:http://soscw.com/index.php/essay/87921.html
评论
亲,登录后才可以留言!