bihuisong 1 jaar geleden
bovenliggende
commit
a6b332746c
16 gewijzigde bestanden met toevoegingen van 411 en 0 verwijderingen
  1. 37 0
      ruoyi-admin/src/main/java/com/ruoyi/web/controller/visual/VisualController.java
  2. 20 0
      ruoyi-system/src/main/java/com/ruoyi/system/domain/CensusElements.java
  3. 28 0
      ruoyi-system/src/main/java/com/ruoyi/system/domain/CensusItemNegativeInformation.java
  4. 17 0
      ruoyi-system/src/main/java/com/ruoyi/system/domain/DailyTrafficRanking.java
  5. 20 0
      ruoyi-system/src/main/java/com/ruoyi/system/mapper/CensusElementsMapper.java
  6. 20 0
      ruoyi-system/src/main/java/com/ruoyi/system/mapper/CensusItemNegativeInformationMapper.java
  7. 20 0
      ruoyi-system/src/main/java/com/ruoyi/system/mapper/DailyTrafficRankingMapper.java
  8. 14 0
      ruoyi-system/src/main/java/com/ruoyi/system/service/ICensusElementsService.java
  9. 14 0
      ruoyi-system/src/main/java/com/ruoyi/system/service/ICensusItemNegativeInformationService.java
  10. 14 0
      ruoyi-system/src/main/java/com/ruoyi/system/service/IDailyTrafficRankingService.java
  11. 33 0
      ruoyi-system/src/main/java/com/ruoyi/system/service/impl/CensusElementsServiceImpl.java
  12. 33 0
      ruoyi-system/src/main/java/com/ruoyi/system/service/impl/CensusItemNegativeInformationServiceImpl.java
  13. 33 0
      ruoyi-system/src/main/java/com/ruoyi/system/service/impl/DailyTrafficRankingServiceImpl.java
  14. 35 0
      ruoyi-system/src/main/resources/mapper/system/CensusElementsMapper.xml
  15. 39 0
      ruoyi-system/src/main/resources/mapper/system/CensusItemNegativeInformationMapper.xml
  16. 34 0
      ruoyi-system/src/main/resources/mapper/system/DailyTrafficRankingMapper.xml

+ 37 - 0
ruoyi-admin/src/main/java/com/ruoyi/web/controller/visual/VisualController.java

@@ -32,6 +32,12 @@ public class VisualController {
     private ICountyAndDistrictMisprintService countyAndDistrictMisprintService;
     @Autowired
     private IMunicipalErrorLinkMonitorService municipalErrorLinkMonitorService;
+    @Autowired
+    private ICensusElementsService censusElementsService;
+    @Autowired
+    private ICensusItemNegativeInformationService censusItemNegativeInformationService;
+    @Autowired
+    private IDailyTrafficRankingService dailyTrafficRankingService;
 
 
     /**
@@ -124,5 +130,36 @@ public class VisualController {
         return Result.ok();
     }
 
+    /**
+     * 网站普查指标监测-网站普查要素-数据推送接口
+     */
+    @PostMapping("putCensusElements")
+    @ResponseBody
+    public Result<?> insertCensusElements(List<CensusElements> list) {
+        censusElementsService.insertBatch(list);
+        return Result.ok();
+    }
+
+    /**
+     * 网站普查指标监测-网站普查单项否信息-数据推送接口
+     */
+    @PostMapping("putCensusItemNegativeInformation")
+    @ResponseBody
+    public Result<?> insertCensusItemNegativeInformation(List<CensusItemNegativeInformation> list) {
+        censusItemNegativeInformationService.insertBatch(list);
+        return Result.ok();
+    }
+
+    /**
+     * 市直部门日更新访问量排名-市直部门日访问量排名-数据推送接口
+     */
+    @PostMapping("putDailyTrafficRanking")
+    @ResponseBody
+    public Result<?> insertDailyTrafficRanking(List<DailyTrafficRanking> list) {
+        dailyTrafficRankingService.insertBatch(list);
+        return Result.ok();
+    }
+
+
 
 }

+ 20 - 0
ruoyi-system/src/main/java/com/ruoyi/system/domain/CensusElements.java

@@ -0,0 +1,20 @@
+package com.ruoyi.system.domain;
+
+import lombok.Data;
+
+
+@Data
+public class CensusElements {
+
+    private Long id;
+
+    private String siteName;
+
+    private String result;
+
+    private String censusTime;
+
+    private String remark;
+
+
+}

+ 28 - 0
ruoyi-system/src/main/java/com/ruoyi/system/domain/CensusItemNegativeInformation.java

@@ -0,0 +1,28 @@
+package com.ruoyi.system.domain;
+
+import lombok.Data;
+
+
+@Data
+public class CensusItemNegativeInformation {
+
+    private Long id;
+
+    private String siteName;
+
+    private String siteUrl;
+
+    private String homepageType;
+
+    private String trends;
+
+    private String columnFive;
+
+    private String columnTen;
+
+    private String notice;
+
+    private String monitorTime;
+
+
+}

+ 17 - 0
ruoyi-system/src/main/java/com/ruoyi/system/domain/DailyTrafficRanking.java

@@ -0,0 +1,17 @@
+package com.ruoyi.system.domain;
+
+import lombok.Data;
+
+
+@Data
+public class DailyTrafficRanking {
+
+    private Long id;
+
+    private String ranking;
+
+    private String accessName;
+
+    private String browseCount;
+
+}

+ 20 - 0
ruoyi-system/src/main/java/com/ruoyi/system/mapper/CensusElementsMapper.java

@@ -0,0 +1,20 @@
+package com.ruoyi.system.mapper;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.ColumnPageView;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+
+public interface CensusElementsMapper {
+
+    List<CensusElements> selectCensusElementsList();
+
+    void deleteCensusElementsAll();
+
+    void insertBatch(@Param("list") List<CensusElements> list);
+
+
+
+}

+ 20 - 0
ruoyi-system/src/main/java/com/ruoyi/system/mapper/CensusItemNegativeInformationMapper.java

@@ -0,0 +1,20 @@
+package com.ruoyi.system.mapper;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.CensusItemNegativeInformation;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+
+public interface CensusItemNegativeInformationMapper {
+
+    List<CensusItemNegativeInformation> selectCensusItemNegativeInformationList();
+
+    void deleteCensusItemNegativeInformationAll();
+
+    void insertBatch(@Param("list") List<CensusItemNegativeInformation> list);
+
+
+
+}

+ 20 - 0
ruoyi-system/src/main/java/com/ruoyi/system/mapper/DailyTrafficRankingMapper.java

@@ -0,0 +1,20 @@
+package com.ruoyi.system.mapper;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.DailyTrafficRanking;
+import org.apache.ibatis.annotations.Param;
+
+import java.util.List;
+
+
+public interface DailyTrafficRankingMapper {
+
+    List<DailyTrafficRanking> selectDailyTrafficRankingList();
+
+    void deleteDailyTrafficRankingAll();
+
+    void insertBatch(@Param("list") List<DailyTrafficRanking> list);
+
+
+
+}

+ 14 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/ICensusElementsService.java

@@ -0,0 +1,14 @@
+package com.ruoyi.system.service;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.ColumnPageView;
+
+import java.util.List;
+
+public interface ICensusElementsService {
+
+    List<CensusElements> selectCensusElementsList();
+
+    void insertBatch(List<CensusElements> list);
+
+}

+ 14 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/ICensusItemNegativeInformationService.java

@@ -0,0 +1,14 @@
+package com.ruoyi.system.service;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.CensusItemNegativeInformation;
+
+import java.util.List;
+
+public interface ICensusItemNegativeInformationService {
+
+    List<CensusItemNegativeInformation> selectCensusItemNegativeInformationList();
+
+    void insertBatch(List<CensusItemNegativeInformation> list);
+
+}

+ 14 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/IDailyTrafficRankingService.java

@@ -0,0 +1,14 @@
+package com.ruoyi.system.service;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.DailyTrafficRanking;
+
+import java.util.List;
+
+public interface IDailyTrafficRankingService {
+
+    List<DailyTrafficRanking> selectDailyTrafficRankingList();
+
+    void insertBatch(List<DailyTrafficRanking> list);
+
+}

+ 33 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/CensusElementsServiceImpl.java

@@ -0,0 +1,33 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.ColumnPageView;
+import com.ruoyi.system.mapper.CensusElementsMapper;
+import com.ruoyi.system.mapper.ColumnPageViewMapper;
+import com.ruoyi.system.service.ICensusElementsService;
+import com.ruoyi.system.service.IColumnPageViewService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+
+@Service
+public class CensusElementsServiceImpl implements ICensusElementsService {
+
+
+    @Autowired
+    private CensusElementsMapper censusElementsMapper;
+
+
+    @Override
+    public List<CensusElements> selectCensusElementsList() {
+        return censusElementsMapper.selectCensusElementsList();
+    }
+
+    @Override
+    public void insertBatch(List<CensusElements> list) {
+        censusElementsMapper.deleteCensusElementsAll();
+        censusElementsMapper.insertBatch(list);
+    }
+}

+ 33 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/CensusItemNegativeInformationServiceImpl.java

@@ -0,0 +1,33 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.CensusItemNegativeInformation;
+import com.ruoyi.system.mapper.CensusElementsMapper;
+import com.ruoyi.system.mapper.CensusItemNegativeInformationMapper;
+import com.ruoyi.system.service.ICensusElementsService;
+import com.ruoyi.system.service.ICensusItemNegativeInformationService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+
+@Service
+public class CensusItemNegativeInformationServiceImpl implements ICensusItemNegativeInformationService {
+
+
+    @Autowired
+    private CensusItemNegativeInformationMapper censusItemNegativeInformationMapper;
+
+
+    @Override
+    public List<CensusItemNegativeInformation> selectCensusItemNegativeInformationList() {
+        return censusItemNegativeInformationMapper.selectCensusItemNegativeInformationList();
+    }
+
+    @Override
+    public void insertBatch(List<CensusItemNegativeInformation> list) {
+        censusItemNegativeInformationMapper.deleteCensusItemNegativeInformationAll();
+        censusItemNegativeInformationMapper.insertBatch(list);
+    }
+}

+ 33 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/DailyTrafficRankingServiceImpl.java

@@ -0,0 +1,33 @@
+package com.ruoyi.system.service.impl;
+
+import com.ruoyi.system.domain.CensusElements;
+import com.ruoyi.system.domain.DailyTrafficRanking;
+import com.ruoyi.system.mapper.CensusElementsMapper;
+import com.ruoyi.system.mapper.DailyTrafficRankingMapper;
+import com.ruoyi.system.service.ICensusElementsService;
+import com.ruoyi.system.service.IDailyTrafficRankingService;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+
+@Service
+public class DailyTrafficRankingServiceImpl implements IDailyTrafficRankingService {
+
+
+    @Autowired
+    private DailyTrafficRankingMapper dailyTrafficRankingMapper;
+
+
+    @Override
+    public List<DailyTrafficRanking> selectDailyTrafficRankingList() {
+        return dailyTrafficRankingMapper.selectDailyTrafficRankingList();
+    }
+
+    @Override
+    public void insertBatch(List<DailyTrafficRanking> list) {
+        dailyTrafficRankingMapper.deleteDailyTrafficRankingAll();
+        dailyTrafficRankingMapper.insertBatch(list);
+    }
+}

+ 35 - 0
ruoyi-system/src/main/resources/mapper/system/CensusElementsMapper.xml

@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CensusElementsMapper">
+    
+    <resultMap type="CensusElements" id="CensusElementsResult">
+    	<id     property="id"      column="id"      />
+        <result property="siteName"    column="site_name"    />
+        <result property="result"     column="result"     />
+        <result property="censusTime"     column="census_time"     />
+        <result property="remark"     column="remark"     />
+    </resultMap>
+    
+    <sql id="selectCensusElementsVo">
+        select id, site_name, result, census_time, remark from sooka_census_elements
+    </sql>
+
+    <select id="selectCensusElementsList" parameterType="CensusElements" resultMap="CensusElementsResult">
+        <include refid="selectCensusElementsVo"/>
+    </select>
+
+	<delete id="deleteCensusElementsAll" parameterType="Long">
+		delete from sooka_census_elements
+	</delete>
+
+	<insert id="insertBatch">
+		insert into sooka_census_elements (site_name, result, census_time, remark) values
+		<foreach item="item" collection="list" separator=",">
+			(#{item.siteName},#{item.result},#{item.censusTime},#{item.remark})
+		</foreach>
+	</insert>
+
+
+</mapper>

+ 39 - 0
ruoyi-system/src/main/resources/mapper/system/CensusItemNegativeInformationMapper.xml

@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.CensusItemNegativeInformationMapper">
+    
+    <resultMap type="CensusItemNegativeInformation" id="CensusItemNegativeInformationResult">
+    	<id     property="id"      column="id"      />
+        <result property="siteName"    column="site_name"    />
+        <result property="siteUrl"     column="site_url"     />
+        <result property="homepageType"     column="homepage_type"     />
+        <result property="trends"     column="trends"     />
+        <result property="columnFive"     column="column_five"     />
+        <result property="columnTen"     column="column_ten"     />
+        <result property="notice"     column="notice"     />
+        <result property="monitorTime"     column="monitor_time"     />
+    </resultMap>
+    
+    <sql id="selectCensusItemNegativeInformationVo">
+        select id, site_name, site_url, homepage_type, trends, column_five, column_ten, notice, monitor_time from sooka_censusitem_negativeinformation
+    </sql>
+
+    <select id="selectCensusItemNegativeInformationList" parameterType="CensusItemNegativeInformation" resultMap="CensusItemNegativeInformationResult">
+        <include refid="selectCensusItemNegativeInformationVo"/>
+    </select>
+
+	<delete id="deleteCensusItemNegativeInformationAll" parameterType="Long">
+		delete from sooka_censusitem_negativeinformation
+	</delete>
+
+	<insert id="insertBatch">
+		insert into sooka_censusitem_negativeinformation (site_name, site_url, homepage_type, trends, column_five, column_ten, notice, monitor_time) values
+		<foreach item="item" collection="list" separator=",">
+			(#{item.siteName},#{item.siteUrl},#{item.homepageType},#{item.trends},#{item.columnFive},#{item.columnTen},#{item.notice},#{item.monitorTime})
+		</foreach>
+	</insert>
+
+
+</mapper>

+ 34 - 0
ruoyi-system/src/main/resources/mapper/system/DailyTrafficRankingMapper.xml

@@ -0,0 +1,34 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.ruoyi.system.mapper.DailyTrafficRankingMapper">
+    
+    <resultMap type="DailyTrafficRanking" id="DailyTrafficRankingResult">
+    	<id     property="id"      column="id"      />
+        <result property="ranking"    column="ranking"    />
+        <result property="accessName"     column="access_name"     />
+        <result property="browseCount"     column="browse_count"     />
+    </resultMap>
+    
+    <sql id="selectDailyTrafficRankingVo">
+        select id, ranking, access_name, browse_count from sooka_daily_traffic_ranking
+    </sql>
+
+    <select id="selectDailyTrafficRankingList" parameterType="DailyTrafficRanking" resultMap="DailyTrafficRankingResult">
+        <include refid="selectDailyTrafficRankingVo"/>
+    </select>
+
+	<delete id="deleteDailyTrafficRankingAll" parameterType="Long">
+		delete from sooka_daily_traffic_ranking
+	</delete>
+
+	<insert id="insertBatch">
+		insert into sooka_daily_traffic_ranking (ranking, access_name, browse_count) values
+		<foreach item="item" collection="list" separator=",">
+			(#{item.ranking},#{item.accessName},#{item.browseCount})
+		</foreach>
+	</insert>
+
+
+</mapper>