顾绍勇 5 lat temu
rodzic
commit
0bee94f2cd

+ 2
- 1
src/main/resources/mapper/TaRecommendCustomerMapper.xml Wyświetl plik

@@ -582,7 +582,7 @@
582 582
         IF( t.sex = 1, '男', IF ( t.sex = 2, '女', '未知' ) ) AS sex,
583 583
         t.create_date,
584 584
         concat( t.country, t.province ) AS province,
585
-        t.intention,
585
+        z.intention,
586 586
         IF(t.building_id is null or t.building_id = '','否','是') AS belongStatus,
587 587
         IFNULL( t2.building_name, '暂无' ) AS buildingName,
588 588
         t5.scene_alias as sceneType,
@@ -598,6 +598,7 @@
598 598
         LEFT JOIN td_wx_dict t5 ON t4.scene_id = t5.scene_id
599 599
         LEFT JOIN (select sum(points_amount) as points,person_id from ta_points_records where org_id = #{orgId} GROUP BY
600 600
         person_id) t6 on t.person_id = t6.person_id
601
+        left join (select sum(ti.intention) as intention,ti.person_id From ta_person_intention_record ti where ti.org_id = #{orgId} group by ti.person_id) z on z.person_id = t.person_id
601 602
         WHERE
602 603
         t.`status` > 0
603 604
         AND t.verify_status = 1