Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
yd-backend
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
AutogeneralShanghai
yd-backend
Commits
13dd5f03
Commit
13dd5f03
authored
Jul 23, 2020
by
yao.xiao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改商机预测sql
parent
649aedd0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
3 deletions
+2
-3
yd-api/src/main/resources/mapper/agms/AgmsDashboardMapper.xml
+2
-3
No files found.
yd-api/src/main/resources/mapper/agms/AgmsDashboardMapper.xml
View file @
13dd5f03
...
...
@@ -15,7 +15,7 @@ select if(b.branch_name is null,'暂无公司',b.branch_name) branchName,
sum(case when YEAR(t.track_time)=YEAR(now()) then t.track_score else 0 end) scoreYear,
sum(case when t.track_score is not null then t.track_score else 0 end) scoreTotal
from ag_acl_practitioner p
left join ag_mkt_leads_assigneds a on p.id = a.assigned_practitioner_id
left join ag_mkt_leads_assigneds a on p.id = a.assigned_practitioner_id
and a.is_active = 1
left join ag_mkt_leads_assigned_track t on t.leads_assigned_id = a.id
left join ag_acl_insurer_branch b on b.id = p.insurer_branch_id
left join ag_acl_practitioner_subordinate_system s on s.id = p.subordinate_system_id
...
...
@@ -74,14 +74,13 @@ select if(b.branch_name is null,'暂无公司',b.branch_name) branchName,
</when>
</choose>
from ag_acl_practitioner p
left join ag_mkt_leads_assigneds a on p.id = a.assigned_practitioner_id
left join ag_mkt_leads_assigneds a on p.id = a.assigned_practitioner_id
and a.is_active = 1
left join ag_acl_insurer_branch b on b.id = p.insurer_branch_id
left join ag_acl_practitioner_subordinate_system s on s.id = p.subordinate_system_id
left join ag_acl_practitioner_setting ps on ps.practitioner_id = p.id
where
ps.practitioner_type_id = 28
and p.is_active = 1
and a.is_active = 1
and not EXISTS(
select tt.leads_assigned_id
from ag_mkt_leads_assigned_track tt
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment