导演:李相日
主演:渡边谦 柄本明 佐藤浩市 柳乐优弥 忽那汐里 小池荣子 国村隼
关键词:剧情 动作 历史
";
String name = "侠客·釜山行";
String image = "http://localho
";
String name = "侠客·釜山行";
String image = "http://localhost:8080/lequan/uploadsImage/1533898456016.png";
String video_link = "http://localhost:8080/lequan/uploadsVideo/1533898455768.mp4";
List<Theater> theaters = new ArrayList<>();
public static void insert() {
String sql = "insert into movie(name,description,image,video_link,create_time,update_time) values(?,?,?,?,?,?)";
Connection conn = null;
PreparedStatement pstmt = null;
try {
conn = DBconnect.getConnection();
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, name);
pstmt.setString(2, description);
pstmt.setString(3, image);
pstmt.setString(4, video_link);
pstmt.setTimestamp(5, Timestamp.valueOf(LocalDateTime.now()));
pstmt.setTimestamp(6, Timestamp.valueOf(LocalDateTime.now()));
pstmt.executeUpdate();
pstmt.close();
conn.close();
System.out.println("新增数据成功");
Movie movie = MovieDAO.findByName(name);
Theater as = new Theater("深圳万象影城",10,true,movie.id);
Theater bs = new Theater("深圳龙岗影城",10,true,movie.id);
Theater cs = new Theater("新华影院",10,true,movie.id);
TheaterService.insert(as);
TheaterService.insert(bs);
TheaterService.insert(cs);
System.out.println("批量新增数据成功");
} catch (Exception e) {
e.printStackTrace();
}
}
public static void findByName() {
Movie movie = MovieDAO.findByName(name);
System.out.println(movie);
}
public static void findById() {
Movie movie = MovieDAO.findById(id);
System.out.println(movie);
}
public static void delete() {
MovieService.delete(id);
System.out.println("删除数据成功");
}
public static void update() {
String name1 = "侠客·釜山行";
String image = "http://localhost:8080/lequan/uploadsImage/1533898456016.png";
String video_link = "http://localhost:8080/lequan/uploadsVideo/1533898455768.mp4";
String introduce = "本片讲述了明治维新前夜,年轻的志士织起了幕府垮台的阴谋网络,另一方面则为保护幕府总裁老中井田正则,动用一切力量。最后,幕府悬赏捉拿志士为由,搬出了野武士釜田佐助(武田铁矢饰)以激怒志士,相继引出了中井田的重孙勘吉(北大路欢喜饰)和花屋敷后藤(三船敏郎)的出场。在悬赏金的逼压下,佐助和勘吉二人都被迫成为梟雄的刺客。";
String description = "由大和武士小山田以劫持总裁老中村主持的阴谋成功结束了德川幕府的统治,明治政府巍然确立";
Movie movie = MovieDAO.findById(id);
movie.setName(name1);
movie.setDescription(description);
movie.setImage(image);
movie.setVideo_link(video_link);
movie.setIntroduce(introduce);
MovieService.update(movie);
System.out.println("更新数据成功");
}
public static void main(String[] args) {
//insert();
findById();
}
}
详情