Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
site-project
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
hqzhdj
site-project
Commits
60995989
Commit
60995989
authored
Mar 25, 2025
by
阳浪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
数据隔离
parent
2685eca0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
cloud-site-service/src/main/resources/mapper/EventTrackMapper.xml
+8
-8
No files found.
cloud-site-service/src/main/resources/mapper/EventTrackMapper.xml
View file @
60995989
...
...
@@ -14,14 +14,14 @@
case when e.type in (11,12,13) and DATE_FORMAT(e.create_time, '%Y-%m-%d') = #{date} then 1 else 0 end as admireNum,
case when e.type in (11,12,13) and DATE_SUB(DATE_FORMAT(e.create_time, '%Y-%m-%d'), INTERVAL -1 DAY) = #{date} then 1 else 0 end as admirePreNum
from event_track e where e.deleted =0
and e.dept_id in (
select id from
SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})) a
and e.dept_id in (SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})) a
</select>
<select
id=
"queryNumByType"
resultType=
"com.yizhi.site.application.vo.site.EventTrackTypeNumVo"
>
select
e.type,e.sub_type as subType,count(1) as num from event_track e
where e.deleted =0
and e.dept_id in (
select id from
SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
and e.dept_id in (SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
<if
test=
"date==4"
>
and WEEK(e.create_time) = WEEK(now()) and DATE_FORMAT(e.create_time, '%Y') = DATE_FORMAT(now(), '%Y')
</if>
...
...
@@ -56,7 +56,7 @@
select
e.dept_id as deptId,e.dept_name as deptName,count(1) as num from event_track e
where e.deleted =0
and e.dept_id in (
select id from
SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
and e.dept_id in (SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
<if
test=
"date==4"
>
and WEEK(e.create_time) = WEEK(now()) and DATE_FORMAT(e.create_time, '%Y') = DATE_FORMAT(now(), '%Y')
</if>
...
...
@@ -111,7 +111,7 @@
then 1 else
0 end as preNum from event_track e
where e.deleted =0
and e.dept_id in (
select id from
SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
and e.dept_id in (SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
<if
test=
"types!=null and types.size()>0"
>
AND e.type IN
<foreach
collection=
"types"
item=
"item"
open=
"("
separator=
","
close=
")"
>
#{item}
</foreach>
...
...
@@ -152,12 +152,12 @@
</if>
then 1 else
0 end as preNum from publication e
and
e.site_id = #{siteId}
where
e.site_id = #{siteId}
) a
</select>
<select
id=
"getNum"
resultType=
"java.lang.Integer"
>
select count(1) from event_track e where e.deleted =0
and e.dept_id in (
select id from
SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
and e.dept_id in (SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
and e.type=#{type} and e.business_id = #{businessId}
</select>
<select
id=
"queryGropByList"
resultType=
"com.yizhi.site.application.vo.site.EventTrackDeptNumVo"
>
...
...
@@ -165,12 +165,12 @@
aug.name as deptName,
0 as num
FROM cloud_system.authz_user_group aug
and
aug.site_id = #{siteId}
where
aug.site_id = #{siteId}
</select>
<select
id=
"getExamTotal"
resultType=
"java.lang.Integer"
>
SELECT COUNT(DISTINCT create_by_id) FROM cloud_portal.event_track
WHERE sub_type =#{subType} and DATE_FORMAT(create_time,'%Y') = #{year}
and
e.dept_id in (select id from
SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
and
dept_id in (
SELECT id FROM cloud_system.authz_user_group where site_id = #{siteId})
</select>
<select
id=
"queryTgNumByDept"
resultType=
"com.yizhi.site.application.vo.site.EventTrackTypeNumVo"
>
select count(1) num ,DATE_FORMAT(create_time, '%m' ) subType from publication where dept_name=#{deptName}
...
...
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