后端推荐系统相关接口实现

Change-Id: Ia9ec3d4edb7dc554fe36e1695f1cc7d8f58ad174
diff --git a/ruoyi-admin/src/main/resources/mapper/system/BtTorrentMapper.xml b/ruoyi-admin/src/main/resources/mapper/system/BtTorrentMapper.xml
index e19128a..4f5cf3f 100644
--- a/ruoyi-admin/src/main/resources/mapper/system/BtTorrentMapper.xml
+++ b/ruoyi-admin/src/main/resources/mapper/system/BtTorrentMapper.xml
@@ -45,6 +45,19 @@
         where torrent_id = #{torrentId}
     </select>
 
+    <select id="selectBtTorrentsByIdsOrdered" resultType="BtTorrent">
+        SELECT * FROM bt_torrent
+        WHERE id IN
+        <foreach collection="list" item="id" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+        ORDER BY FIELD(id
+        <foreach collection="list" item="id" separator=",">
+            #{id}
+        </foreach>
+        )
+    </select>
+
     <insert id="insertBtTorrent" parameterType="BtTorrent" useGeneratedKeys="true" keyProperty="torrentId">
         insert into bt_torrent
         <trim prefix="(" suffix=")" suffixOverrides=",">