开店管理导出加字段

This commit is contained in:
shuo.wang
2025-02-07 10:51:38 +08:00
parent a109c20c34
commit c87a934bde
7 changed files with 28 additions and 109 deletions

View File

@@ -1,10 +1,16 @@
package com.cool.store.mapper;
import com.cool.store.entity.FranchiseFeeDO;
import org.apache.ibatis.annotations.MapKey;
import org.apache.ibatis.annotations.Param;
import tk.mybatis.mapper.common.Mapper;
import java.util.Date;
import java.util.List;
import java.util.Map;
public interface FranchiseFeeMapper extends Mapper<FranchiseFeeDO> {
FranchiseFeeDO selectByShopId(@Param("shopId") Long shopId);
@MapKey("shopId")
Map<Long, Date> getPayTimeByShopIds(@Param("shopIds") List<Long> shopIds);
}

View File

@@ -9,4 +9,14 @@
order by create_time desc
limit 1
</select>
<select id="getPayTimeByShopIds" resultType="java.util.HashMap">
select a.shop_id AS shopId ,
b.pay_time as payTime
from xfsg_franchise_fee a
LEFT JOIN xfsg_line_pay b ON b.id = a.pay_id;
where a.shop_id in
<foreach collection="shopIds" item="shopId" open="(" separator="," close=")">
#{shopId}
</foreach>
</select>
</mapper>