1.点歌支付防抖

2.点歌记录倒序
3.下单同步保存库存记录
This commit is contained in:
2024-07-17 16:52:19 +08:00
parent d784ba8c27
commit 266bbd7381
10 changed files with 64 additions and 4 deletions

View File

@@ -19,6 +19,7 @@ public interface TbProductMapper {
TbProduct selectById(Integer id);
List<TbProduct> selectByIdIn(@Param("ids") String ids);
List<TbProduct> selectByIdInAndCheck(@Param("ids") String ids);
List<TbProduct> selectByIds(@Param("list") List<String> ids);
Integer selectByQcode(@Param("code") String code,@Param("productId") Integer productId,@Param("shopId") String shopId);

View File

@@ -35,7 +35,7 @@ public interface TbShopSongOrderMapper {
" LEFT JOIN tb_shop_song AS b ON a.song_id = b.id\n" +
" WHERE\n" +
" a.open_id = #{openId} and a.shop_id=#{shopId} " +
" <if test=\"state!=null\">AND a.state = #{state}</if></script>")
" <if test=\"state!=null\">AND a.state = #{state}</if> order by a.state asc, a.create_time desc</script>")
List<Map<String, Object>> selectByUserId(@Param("openId") String openId, @Param("state") Integer state, Integer shopId);
@Select(" SELECT\n" +
@@ -61,7 +61,7 @@ public interface TbShopSongOrderMapper {
" tb_shop_song_order AS a\n" +
" LEFT JOIN tb_shop_song AS b ON a.song_id = b.id\n" +
" WHERE\n" +
" a.open_id = #{openId} and a.state in (1, 2, 3) and a.shop_id=#{shopId}")
" a.open_id = #{openId} and a.state in (1, 2, 3) and a.shop_id=#{shopId} order by a.state asc, a.create_time desc")
List<Map<String, Object>> selectActiveOrderByUserId(@Param("openId") String openId, Integer shopId);
@Select("SELECT a.song_name songName, a.id, b.img FROM `tb_shop_song_order` as a left join tb_shop_song as b on a.song_id=b.id where state=2 limit 1")