|
|
@@ -53,6 +53,19 @@ public interface StoreInfoMapper extends BaseMapper<StoreInfo> {
|
|
|
" ${ew.customSqlSegment}")
|
|
|
List<StoreInfoVo> getStoreInfoVoList(@Param(Constants.WRAPPER) QueryWrapper<StoreInfoVo> queryWrapper);
|
|
|
|
|
|
+ @Select("with menu as (select store_id,GROUP_CONCAT(dish_name) dish_name from store_menu GROUP BY store_id) " +
|
|
|
+ "select a.*, b.name store_contact, b.phone store_phone, b.password, c.dish_name, a.store_type, img.img_url entranceImage, d.img_url, dict.dict_detail storeTypeStr, dict2.dict_detail businessStatusStr," +
|
|
|
+ " ROUND(ST_Distance_Sphere(ST_GeomFromText(CONCAT('POINT(', REPLACE(#{position}, ',', ' '), ')' )), ST_GeomFromText(CONCAT('POINT(', REPLACE(a.store_position, ',', ' '), ')' ))) / 1000, 2) dist " +
|
|
|
+ "from store_info a " +
|
|
|
+ "left join store_user b on a.id = b.store_id AND b.delete_flag = 0 " +
|
|
|
+ "left join menu c on a.id = c.store_id " +
|
|
|
+ "left join store_img img on img.store_id = a.id and img.img_type = 1 and img.delete_flag = 0 " +
|
|
|
+ "left join store_dictionary dict on dict.type_name = 'storeType' and dict.dict_id = a.store_type and dict.delete_flag = 0 " +
|
|
|
+ "left join store_dictionary dict2 on dict2.type_name = 'businessStatus' and a.business_status = dict2.dict_id and dict2.delete_flag = 0 " +
|
|
|
+ "left join store_img d on d.store_id = a.id and d.img_type = 10 and d.delete_flag = 0" +
|
|
|
+ " ${ew.customSqlSegment}")
|
|
|
+ List<StoreInfoVo> getStoreInfoVoListNew(@Param(Constants.WRAPPER) QueryWrapper<StoreInfoVo> queryWrapper, @Param("position") String position);
|
|
|
+
|
|
|
/**
|
|
|
* web端-门店列表
|
|
|
*
|