dongdingding
董丁丁 2 years ago
parent 59a4b3e447
commit 3b6b355c62

@ -24,8 +24,6 @@ public class ZongzhiActionResponse {
private Date zhuanxiangTime;
@ApiModelProperty(value = "百分比")
private double pt;
@ApiModelProperty(value = "处理类型 1.处理有害信息 2.关闭直播平台违规账号")

@ -30,6 +30,7 @@ public interface ZongzhiScreenManageMapper {
/**
*
*/
//
public List<ZongzhiActionResponse> getaction();

@ -1,6 +1,8 @@
package com.ruoyi.zongzhi.service.impl;
import java.util.List;
import com.ruoyi.common.exception.ServiceException;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.zongzhi.mapper.TcYqFlMapper;
@ -52,6 +54,12 @@ public class TcYqFlServiceImpl implements ITcYqFlService
@Override
public int insertTcYqFl(TcYqFl tcYqFl)
{
List<TcYqFl> list =tcYqFlMapper.selectTcYqFlList(tcYqFl);
if (list.contains(tcYqFl.getMediaType())){
throw new ServiceException("此媒体类型已存在");
}else if(list.contains(tcYqFl.getEventType())){
throw new ServiceException("此涉事类型已存在");
}
return tcYqFlMapper.insertTcYqFl(tcYqFl);
}

@ -17,10 +17,10 @@
</select>
<select id="getaction" resultType="com.ruoyi.screen.domain.response.ZongzhiActionResponse">
select count(*) as count, zhuanxiang_time as zhuanxiangTime ,ROUND(count(*) * 100.0/ sum(count(*)) OVER (), 1 )
as pt,zhuanxiang_type as type
from tc_qinglang_zhuanxiang
GROUP BY zhuanxiang_type, zhuanxiang_time
select count(*) as count, month_year as zhuanxiangTime ,type
from tc_qlzxxdsj WHERE NOW() >= DATE_SUB(DATE_SUB(month_year, INTERVAL 6 MONTH), INTERVAL 1 YEAR)
AND NOW() &lt;= DATE_SUB(month_year, INTERVAL 6 MONTH);
GROUP BY type, month_year
</select>
<select id="getReportByYear" resultType="com.ruoyi.screen.domain.response.ZongzhiReportByYearResponse">

@ -10,20 +10,19 @@
from tc_network_article group by type
</select>
<select id="getAppraiser" resultType="com.ruoyi.screen.domain.response.ZongzhiAppraiserResponse">
select appraiser_type as type, ROUND(COUNT(*) * 100.0 / SUM(COUNT(*)) OVER (), 1) AS pt
from tc_network_evaluate
WHERE MONTH (create_time) = MONTH (CURDATE())
select name as type, sum(percent) AS pt
from tc_bjsj
GROUP BY type
</select>
<select id="getAppraiserComplete"
resultType="com.ruoyi.screen.domain.response.ZongzhiAppraiserCompleteResponse">
select ROUND(COUNT(*) * 100.0 / SUM(COUNT(*)) OVER (), 1) AS pt, b.name from(
select SUM(s.finish) b.name from(
SELECT
CASE
WHEN LOCATE(',', area_id) = 0 THEN TRIM(TRAILING ']' FROM SUBSTR(area_id, LOCATE('[', area_id) + 1))
ELSE TRIM(TRAILING ']' FROM SUBSTRING_INDEX(area_id, ',', -1))
END AS area_id
FROM tc_network_evaluate)s left join tc_town b on s.area_id = b.id
END AS area_id,finsh
FROM tc_wpyrwwcl)s left join tc_town b on s.area_id = b.id
GROUP BY s.area_id
</select>

@ -6,11 +6,9 @@
<select id="getSentimentType" resultType="com.ruoyi.screen.domain.response.ZongzhiSentimentTypeResponse">
select count(*) as count ,sentiment_type as type,publish_time as publishTime
from tc_network_sentiment
where sentiment_type in ("1", "2")
GROUP BY sentiment_type,publish_time
select count(*) as count , type,date_time as publishTime
from tc_yq_zs
GROUP BY type,publish_time
</select>
<select id="getSentimenCount" resultType="com.ruoyi.screen.domain.response.ZongzhiSentimentCountResponse">
select count(*) as count ,sentiment_type as type,ROUND(COUNT(*) * 100.0 / SUM(COUNT(*)) OVER (), 1) AS pt
@ -20,14 +18,14 @@
</select>
<select id="getSentimenClassificationBymediaType"
resultType="com.ruoyi.screen.domain.response.ZongzhiSentimenClassificationResponse">
select media_type as type, ROUND(COUNT(*) * 100.0 / SUM(COUNT(*)) OVER (), 1) AS pt
from tc_network_sentiment
select media_type as type,sum(media_count)as pt
from tc_yq_fl
GROUP BY media_type
</select>
<select id="getSentimenClassificationByeventType"
resultType="com.ruoyi.screen.domain.response.ZongzhiSentimenClassificationResponse">
select event_type as type, ROUND(COUNT(*) * 100.0 / SUM(COUNT(*)) OVER (), 1) AS pt
from tc_network_sentiment
select event_type as type, sum(event_count)as pt
from tc_yq_fl
GROUP BY event_type
</select>
<select id="getWordCloud" resultType="com.ruoyi.screen.domain.response.ZongzhiSentimenWordCloudResponse">

Loading…
Cancel
Save