这当中 episode 的 id 获取为 null ,请问是哪里出了问题
@Select("select * from Anime t where t.id = #{id}")
@Results({
@Result(column = "id", property = "id", id = true),
@Result(column = "local_name", property = "localName"),
@Result(column = "origin_name", property = "originName"),
@Result(column = "image_path", property = "imagePath"),
@Result(column = "type", property = "type", typeHandler = BaseEnumTypeHandler.class),
@Result(column = "broadcast_time", property = "broadcastTime"),
@Result(column = "state", property = "state", typeHandler = BaseEnumTypeHandler.class),
@Result(column = "introduction_path", property = "introductionPath"),
@Result(column = "update_time", property = "updateTime"),
@Result(many = @Many(select = "org.watp.anifree.anime.dao.AnimeMapper.getSynthesizeEpisodesInfoByAnimeId"), property = "episodes", column = "id", javaType = ArrayList.class)
})
@CacheEnable(type = CacheType.PRIVATE, desc = "SynthesizeAnimeInfo", dataType = DataType.DATA, privateId = "${anime.id}")
AnimePO getSynthesizeAnimeInfoByPO(AnimePO anime);
@Select("select * from Episode t where t.anime_id = #{anime_id} order by t.ordr")
@Results({
@Result(column = "anime_id", property = "animeId"),
@Result(column = "image_path", property = "imagePath"),
@Result(many = @Many(select = "org.watp.anifree.anime.dao.AnimeMapper.getSynthesizePlaysInfoByEpisodeId"), property = "plays", column = "id", javaType = ArrayList.class)
})
List<EpisodePO> getSynthesizeEpisodesInfoByAnimeId(@Param("anime_id") String anime_id);
@Select("select * from Play t where t.episode_id = #{episode_id} order by t.ordr")
@Results({
@Result(column = "episode_id", property = "episodeId"),
@Result(column = "type", property = "type", typeHandler = BaseEnumTypeHandler.class)
})
List<PlayPO> getSynthesizePlaysInfoByEpisodeId(@Param("episode_id") String episode_id);
这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。
V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。
V2EX is a community of developers, designers and creative people.