From 7d1c0b9247ce050e1557ef0530e49e545dbcd45e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E7=A3=8A?= <45566618@qq.com> Date: Tue, 23 Jul 2024 22:41:36 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8A=80=E5=B8=88=E8=AF=84=E5=88=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/resources/mapper/artificer/ArtificerDao.xml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/resources/mapper/artificer/ArtificerDao.xml b/src/main/resources/mapper/artificer/ArtificerDao.xml index def60cf..5cac07f 100644 --- a/src/main/resources/mapper/artificer/ArtificerDao.xml +++ b/src/main/resources/mapper/artificer/ArtificerDao.xml @@ -7,7 +7,7 @@ select * from (select a.*,u.phone,s.code as classifyName,u.status as artificerStatus,u.consortia_id,c.consortia_name, (select count(*) from collect_artificer o where o.artificer_id=a.artificer_id and classify=1) as collectCount, (select count(*) from orders o where o.artificer_id=a.artificer_id and o.status in (3,5)) as ordersCount, - ifnull((select avg(c.score) from taking_commnt c where c.artificer_id=a.artificer_id ),0.00) as ordersScore, + ifnull((select avg(c.score) from taking_commnt c where c.artificer_id=a.artificer_id ),5.00) as ordersScore, (select count(*) from taking_commnt c where c.artificer_id=a.artificer_id ) as commentCount, (st_distance (point (a.longitude, a.latitude),point(#{longitude},#{latitude}) ) *111195) as distance, v.vip_name as technicianTypeName,v.rate as technicianTypeRate ,(CASE WHEN DATEDIFF(CURDATE(), a.create_time) <=7 THEN 1 ELSE 2 END) AS isNewer @@ -84,7 +84,7 @@ (select code from sys_dict o where o.id = a.classify_id) as classifyName, (select count(*) from collect_artificer o where o.artificer_id = a.artificer_id and classify = 1) as collectCount, (select count(*) from collect_artificer o where o.artificer_id = a.artificer_id and o.user_id = #{userId} and classify = 1) as myCollectCount, - ifnull((select avg(c.score) from taking_commnt c where c.artificer_id = a.artificer_id), 0.00) as ordersScore, + ifnull((select avg(c.score) from taking_commnt c where c.artificer_id = a.artificer_id), 5.00) as ordersScore, (st_distance(point(a.longitude, a.latitude), point(#{longitude}, #{latitude})) * 111195) as distance, v.vip_name as technicianTypeName,v.rate as technicianTypeRate ,(CASE WHEN DATEDIFF(CURDATE(), a.create_time) <=7 THEN 1 ELSE 2 END) AS isNewer from artificer a @@ -99,7 +99,7 @@ select a.*, (select count(*) from orders o where o.artificer_id = a.artificer_id and o.status in (3,5)) as ordersCount, ifnull((select avg(c.score) from taking_commnt c where c.artificer_id = a.artificer_id), - 0.00) as ordersScore + 5.00) as ordersScore from artificer a left join tb_user u on a.user_id = u.user_id where a.user_id = #{artificerId} @@ -140,7 +140,7 @@ u.status as artificerStatus, (select count(*) from collect_artificer o where o.artificer_id=a.artificer_id and classify=1) as collectCount, (select count(*) from orders o where o.artificer_id=a.artificer_id and o.status in (3,5)) as ordersCount, - ifnull((select avg(c.score) from taking_commnt c where c.artificer_id=a.artificer_id ),0.00) as ordersScore, + ifnull((select avg(c.score) from taking_commnt c where c.artificer_id=a.artificer_id ),5.00) as ordersScore, (select count(*) from taking_commnt c where c.artificer_id=a.artificer_id ) as commentCount, (select ifnull(sum(o.shop_money),0.00) as money from orders o where o.shop_user_id=#{shopId}