Skip to content

Commit

Permalink
when add the city, set the status default to 1
Browse files Browse the repository at this point in the history
  • Loading branch information
leedarKen committed Feb 19, 2016
1 parent a20420c commit fcb48a3
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ public String edit(@PathVariable String editType, @PathVariable long id, Model m
@RequestMapping(value="/addCity", method=RequestMethod.POST)
public String addCity(City city) {
city.setCreateTime(new java.sql.Timestamp(System.currentTimeMillis()));
city.setStatus(City.USABLED);
service.insert(city);
return "redirect:/admin/city/list";
}
Expand Down

0 comments on commit fcb48a3

Please sign in to comment.