瀏覽代碼

fix 修改招商统计分析榜单不全的问题,每个页面变成两个榜单

Administrator 4 年之前
父節點
當前提交
88373b1888

+ 39 - 2
ruoyi-admin/src/main/java/com/ruoyi/web/controller/project/BmDeptPlanController.java

@@ -117,7 +117,7 @@ public class BmDeptPlanController extends BaseController {
     /**
      * 统计分析-在谈线索-两区及乡镇
      */
-    @Log(title = " 单位榜单", businessType = BusinessType.INSERT)
+    @Log(title = " 两区及乡镇榜单", businessType = BusinessType.INSERT)
     @PostMapping("/unitClueList")
     public TableDataInfo unitClueList( String year) {
         if (StringUtils.isBlank(year)){
@@ -128,6 +128,20 @@ public class BmDeptPlanController extends BaseController {
     }
 
 
+    /**
+     * 统计分析-在谈线索-市直榜单
+     */
+    @Log(title = " 市直榜单", businessType = BusinessType.INSERT)
+    @PostMapping("/unitClueListCity")
+    public TableDataInfo unitClueListCity( String year) {
+        if (StringUtils.isBlank(year)){
+            year = DateUtils.getYear();
+        }
+        List<BmDeptPlanVo> bmDeptPlanVos = bmDeptPlanService.selectUnitClueCityList(year);
+        return getDataTable(bmDeptPlanVos);
+    }
+
+
     /**
      * 统计分析-签约项目-两区及乡镇榜单
      */
@@ -154,7 +168,6 @@ public class BmDeptPlanController extends BaseController {
         return getDataTable(bmDeptPlanVos);
     }
 
-
     /**
      * 统计分析-在建项目-市直榜单
      */
@@ -167,6 +180,18 @@ public class BmDeptPlanController extends BaseController {
         return AjaxResult.success(bmDeptPlanVos);
     }
 
+    /**
+     * 统计分析-在建项目-两区及乡镇
+     */
+    @PostMapping("/projectAreaAmountUnit")
+    public AjaxResult projectAreaAmountUnit( String year) {
+        if (StringUtils.isBlank(year)){
+            year = DateUtils.getYear();
+        }
+        List<BmDeptPlanVo> bmDeptPlanVos = bmDeptPlanService.selectProjectAreaAmountUnit(year);
+        return AjaxResult.success(bmDeptPlanVos);
+    }
+
     /**
      * 统计分析-在建项目-柱状图
      */
@@ -191,6 +216,18 @@ public class BmDeptPlanController extends BaseController {
         return getDataTable(bmDeptPlanVos);
     }
 
+    /**
+     * 统计分析-投产项目-市直榜单
+     */
+    @PostMapping("/investmentCityList")
+    public TableDataInfo investmentCityList( String year) {
+        if (StringUtils.isBlank(year)){
+            year = DateUtils.getYear();
+        }
+        List<BmDeptPlanVo> bmDeptPlanVos = bmDeptPlanService.selectInvestmentCityList(year);
+        return getDataTable(bmDeptPlanVos);
+    }
+
     /**
      * 统计分析-投产项目-柱状图
      */

+ 1 - 1
ruoyi-admin/src/main/resources/application.yml

@@ -44,7 +44,7 @@ spring:
     # 国际化资源文件路径
     basename: i18n/messages
   profiles:
-    active: prod
+    active: druid
   # 文件上传
   servlet:
      multipart:

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

@@ -77,6 +77,12 @@ public interface BmDeptPlanMapper
      */
     public List<BmDeptPlanVo> selectUnitClueList(@Param("year")String year);
 
+    /**
+     * 统计分析-在谈线索-市直榜单
+     * @return
+     */
+    public List<BmDeptPlanVo> selectUnitClueCityList(@Param("year")String year);
+
     /**
      * 两区及乡镇榜单
      * @return
@@ -102,6 +108,13 @@ public interface BmDeptPlanMapper
      */
     public List<BmDeptPlanVo> selectProjectUnitAmountUnit(@Param("year")String year);
 
+    /**
+     * 统计分析-在建项目-两区及乡镇
+     * @param year
+     * @return
+     */
+    public List<BmDeptPlanVo> selectProjectAreaAmountUnit(@Param("year")String year);
+
     /**
      * 统计分析-投产项目-两区及乡镇入归榜单
      * >8 根据字典值来判断是否是已经入归(项目完成)状态
@@ -109,6 +122,13 @@ public interface BmDeptPlanMapper
      */
     public List<BmDeptPlanVo> selectInvestmentList(@Param("year")String year);
 
+    /**
+     * 统计分析-投产项目-市直榜单
+     * >8 根据字典值来判断是否是已经入归(项目完成)状态
+     * @return
+     */
+    public List<BmDeptPlanVo> selectInvestmentCityList(@Param("year")String year);
+
     /**
      * 统计分析-投产项目-柱状图
      * @param year

+ 32 - 0
ruoyi-system/src/main/java/com/ruoyi/system/service/impl/project/BmDeptPlanServiceImpl.java

@@ -126,6 +126,17 @@ public class BmDeptPlanServiceImpl implements IBmDeptPlanService
         return bmDeptPlanVos;
     }
 
+    /**
+     * 统计分析-在谈线索-市直
+     * @param year
+     * @return
+     */
+    @Override
+    public List<BmDeptPlanVo> selectUnitClueCityList(String year) {
+        List<BmDeptPlanVo> bmDeptPlanVos = bmDeptPlanMapper.selectUnitClueCityList(year);
+        return bmDeptPlanVos;
+    }
+
     /**
      * 统计分析-签约项目-两区及乡镇榜单
      * @return
@@ -179,6 +190,17 @@ public class BmDeptPlanServiceImpl implements IBmDeptPlanService
         return bmDeptPlanVos;
     }
 
+    /**
+     * 统计分析-在建项目-两区及乡镇
+     * @param year
+     * @return
+     */
+    @Override
+    public List<BmDeptPlanVo> selectProjectAreaAmountUnit(String year) {
+        List<BmDeptPlanVo> bmDeptPlanVos = bmDeptPlanMapper.selectProjectAreaAmountUnit(year);
+        return bmDeptPlanVos;
+    }
+
     /**
      * 统计分析-投产项目-两区及乡镇入归榜单
      * @return
@@ -190,6 +212,16 @@ public class BmDeptPlanServiceImpl implements IBmDeptPlanService
         return bmDeptPlanVos;
     }
 
+    /**
+     * 统计分析-投产项目-市直榜单
+     * @return
+     */
+    @Override
+    public List<BmDeptPlanVo> selectInvestmentCityList(String year) {
+        List<BmDeptPlanVo> bmDeptPlanVos = bmDeptPlanMapper.selectInvestmentCityList(year);
+        return bmDeptPlanVos;
+    }
+
     /**
      * 统计分析-投产项目-柱状图
      * @param year

+ 20 - 1
ruoyi-system/src/main/java/com/ruoyi/system/service/project/IBmDeptPlanService.java

@@ -71,11 +71,17 @@ public interface IBmDeptPlanService
 
 
     /**
-     * 统计分析-谈线索-两区及乡镇
+     * 统计分析-谈线索-两区及乡镇
      * @return
      */
     public List<BmDeptPlanVo> selectUnitClueList(String year);
 
+    /**
+     * 统计分析-在谈线索-市直榜单
+     * @return
+     */
+    public List<BmDeptPlanVo> selectUnitClueCityList(String year);
+
     /**
      * 统计分析-签约项目-两区及乡镇榜单
      * @return
@@ -103,12 +109,25 @@ public interface IBmDeptPlanService
      */
     public List<BmDeptPlanVo> selectProjectUnitAmountUnit(String year);
 
+    /**
+     * 统计分析-在建项目-两区及乡镇
+     * @param year
+     * @return
+     */
+    public List<BmDeptPlanVo> selectProjectAreaAmountUnit(String year);
+
     /**
      * 统计分析-投产项目-两区及乡镇入归榜单
      * @return
      */
     public List<BmDeptPlanVo> selectInvestmentList(String year);
 
+    /**
+     * 统计分析-投产项目-市直榜单
+     * @return
+     */
+    public List<BmDeptPlanVo> selectInvestmentCityList(String year);
+
     /**
      * 统计分析-投产项目-柱状图
      * @param year

+ 96 - 0
ruoyi-system/src/main/resources/mapper/system/project/BmDeptPlanMapper.xml

@@ -138,6 +138,39 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 	plan DESC
     </select>
 
+	<select id="selectUnitClueCityList" parameterType="string"  resultType="com.ruoyi.system.domain.vo.BmDeptPlanVo">
+    SELECT
+	ifnull( s1.dept_name, '' ) AS deptName,
+	ifnull( s1.target_arrival_amount, 0 ) AS targetArrivalAmount,
+	ifnull( count( p.id ), 0 ) AS successMission
+    FROM
+	(
+	SELECT
+		sd.dept_id,
+		sd.dept_name,
+		sd.parent_id,
+		a.sys_dept_id,
+		a.target_arrival_amount
+	FROM
+		sys_dept sd
+		LEFT JOIN `bm_dept_plan` a ON a.sys_dept_id = sd.dept_id
+		AND a.is_del = '0'
+	WHERE
+		sd.del_flag = '0'
+	) s1
+	LEFT JOIN bm_project p ON p.dept_id = s1.sys_dept_id
+	AND p.is_del = '0'
+	and year(p.create_time) = #{year}
+	where
+	s1.parent_id = 124
+	and p.project_status in (1,2,3,4)
+    GROUP BY
+	s1.dept_id
+    ORDER BY
+	successMission DESC,
+	targetArrivalAmount DESC
+    </select>
+
     <select id="selectTargetSigningList" parameterType="String"  resultType="com.ruoyi.system.domain.vo.BmDeptPlanVo">
     SELECT
 	ifnull(s1.dept_name,'') AS deptName,
@@ -252,6 +285,34 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 	s1.payForMoney DESC
     </select>
 
+	<select id="selectProjectAreaAmountUnit"  parameterType="string" resultType="com.ruoyi.system.domain.vo.BmDeptPlanVo">
+    SELECT
+	ifnull(s1.dept_name,'') AS deptName,
+	ifnull(s1.target_signing_num,0) AS targetSigningNum,
+	ifnull(count( p.id ),0) AS successMission
+    FROM
+	(
+	SELECT
+	    sd.dept_id,
+		sd.dept_name,
+		sd.parent_id,
+		a.sys_dept_id,
+		(ifnull(a.project_million_num,0)+ ifnull(a.project_pro_num,0)+ ifnull(a.project_investment_num,0))as target_signing_num
+	FROM
+	    sys_dept sd
+		LEFT JOIN `bm_dept_plan_area` a ON a.sys_dept_id = sd.dept_id and a.is_del = '0'
+		where sd.del_flag = '0'
+	) s1
+	LEFT JOIN bm_project p ON p.dept_id = s1.sys_dept_id
+	and p.is_del = '0' and p.project_status in (8,9) and year(p.create_time) = #{year}
+	where
+	s1.parent_id = 105
+    GROUP BY
+	s1.dept_id
+    ORDER BY
+	successMission DESC,
+	targetSigningNum DESC
+    </select>
 
     <select id="selectInvestmentList" parameterType="string"  resultType="com.ruoyi.system.domain.vo.BmDeptPlanVo">
     SELECT
@@ -270,6 +331,41 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
 	targetSigningNum DESC
     </select>
 
+	<select id="selectInvestmentCityList" parameterType="string"  resultType="com.ruoyi.system.domain.vo.BmDeptPlanVo">
+    SELECT
+	sd.dept_name AS deptName,
+	ifnull( s1.payForMoney, 0 ) AS payForMoney,
+	ifnull( count(p.id), 0 ) AS successMission
+    FROM
+	sys_dept sd
+	LEFT JOIN `bm_project` p ON p.dept_id = sd.dept_id and p.project_status &gt; 8
+	AND p.is_del = '0' and year(p.create_time) = #{year}
+	LEFT JOIN (
+	SELECT
+		sum( s.payForMoney ) AS payForMoney,
+		s.dept_id
+	FROM
+		(
+		SELECT
+			cp.pay_for_money AS payForMoney,
+			p.dept_id
+		FROM
+			bm_project p
+			LEFT JOIN bm_construction_pay cp ON cp.bm_project_id = p.id
+			AND p.is_del = '0' and year(cp.create_time) = #{year}
+		) s
+	GROUP BY
+		s.dept_id
+	) s1 ON s1.dept_id = p.dept_id
+	WHERE
+	sd.del_flag = '0'
+	and sd.parent_id = 124
+	GROUP BY
+	sd.dept_id
+    ORDER BY
+	s1.payForMoney DESC
+    </select>
+
 
 
     <select id="selectProjectInvestmentEharts"  parameterType="string" resultType="com.ruoyi.system.domain.vo.BmDeptPlanVo">

+ 25 - 1
ruoyi-ui/src/api/statistical/index.js

@@ -78,6 +78,14 @@ export function getUnitClueList() {
   })
 }
 
+// 统计分析-在谈线索-市直榜单
+export function getUnitClueListCity() {
+  return request({
+    url: '/deptPlan/plan/unitClueListCity',
+    method: 'post'
+  })
+}
+
 // 统计分析-签约项目-榜单
 export function getUnitAmountList() {
   return request({
@@ -85,7 +93,15 @@ export function getUnitAmountList() {
     method: 'post'
   })
 }
-// 统计分析-在建项目-资金榜单
+
+// 统计分析-在建项目-两区及乡镇榜单
+export function setProjectAreaAmountUnit() {
+  return request({
+    url: '/deptPlan/plan/projectAreaAmountUnit',
+    method: 'post'
+  })
+}
+// 统计分析-在建项目-市直榜单
 export function setProjectUnitAmountUnit() {
   return request({
     url: '/deptPlan/plan/projectUnitAmountUnit',
@@ -99,6 +115,14 @@ export function setInvestmentList() {
     method: 'post'
   })
 }
+
+// 统计分析-投产项目-市直榜单
+export function setInvestmentCityList() {
+  return request({
+    url: '/deptPlan/plan/investmentCityList',
+    method: 'post'
+  })
+}
 // 统计分析-在建项目-资金榜单
 export function getTotAmtList() {
   return request({

+ 4 - 4
ruoyi-ui/src/settings.js

@@ -1,7 +1,7 @@
 module.exports = {
   title: '招商引资管理系统',
-  urls: 'http://47.99.82.249:80',
-  // urls: 'http://192.168.101.11:8010',
+  // urls: 'http://47.99.82.249:80',
+  urls: 'http://192.168.101.11:8010',
 
   /**
    * 侧边栏主题 深色主题theme-dark,浅色主题theme-light
@@ -35,6 +35,6 @@ module.exports = {
    * If you want to also use it in dev, you can pass ['production', 'development']
    */
   errorLog: 'production',
-  // apiUrl: 'http://192.168.101.11:8010'
-  apiUrl: 'http://47.99.82.249:80'
+  apiUrl: 'http://192.168.101.11:8010'
+  // apiUrl: 'http://47.99.82.249:80'
 }

+ 32 - 1
ruoyi-ui/src/views/statistical/clue/index.vue

@@ -54,6 +54,29 @@
             </div>
           </div>
         </div>
+        <div class="rig_tab_top" style="background-color: #1C84C6;">
+          <div class="rig_title">
+            市直榜单
+          </div>
+          <div class="rig_tab_top">
+            <div class="rig_tab_item">
+              单位名称
+            </div>
+            <div class="rig_tab_item">
+              新签约金额目标
+            </div>
+            <div class="rig_tab_item">
+              在谈线索
+            </div>
+          </div>
+          <div class="rig_cont">
+            <div class="rig_items" v-for="(item,index) in szList" :key="index">
+              <span>{{item.deptName}}</span>
+              <span>{{item.targetArrivalAmount?item.targetArrivalAmount:0}}万元</span>
+              <span>{{item.successMission?item.successMission:0}}个</span>
+            </div>
+          </div>
+        </div>
       </el-col>
     </el-row>
   </div>
@@ -68,8 +91,9 @@
     setReject,
     getUnitAmountList,
     getUnitClueList,
+    getUnitClueCityList,
     setPass,
-    getIndexEharts
+    getIndexEharts, getUnitClueListCity
   } from '@/api/statistical'
   export default {
     data() {
@@ -84,6 +108,7 @@
         },
         loading: false,
         unitList: [],
+        szList: [],
         flags: false,
         lb_value: '2021', // 柱状图类别
       }
@@ -96,6 +121,7 @@
       this.bd_btn()
       this.zht_fn()
       this.eharts_fn()
+      this.sz_btn()
     },
     methods: {
       picher_fn() {
@@ -117,6 +143,11 @@
           this.unitList = res.rows
         })
       },
+      sz_btn() {
+        getUnitClueListCity().then(res => {
+          this.szList = res.rows
+        })
+      },
       dec_btn(row) {
         this.$router.push({
           path: '/management/row/index',

+ 31 - 2
ruoyi-ui/src/views/statistical/putProduction/index.vue

@@ -54,6 +54,29 @@
             </div>
           </div>
         </div>
+        <div class="rig_tab_top" style="background-color: #1C84C6;">
+          <div class="rig_title">
+          市直榜单
+          </div>
+          <div class="rig_tab_top">
+            <div class="rig_tab_item">
+              单位名称
+            </div>
+            <div class="rig_tab_item">
+              实际到资
+            </div>
+            <div class="rig_tab_item">
+              投产项目
+            </div>
+          </div>
+          <div class="rig_cont">
+            <div class="rig_items" v-for="(item,index) in cityList" :key="index">
+              <span>{{item.deptName}}</span>
+              <span>{{item.payForMoney != '0.0000'?item.payForMoney:0}}万元</span>
+              <span>{{item.successMission?item.successMission:0}}个</span>
+            </div>
+          </div>
+        </div>
       </el-col>
     </el-row>
   </div>
@@ -67,7 +90,7 @@
     setExamine,
     setReject,
     setInvestmentList,
-    getProjectInvestmentEharts
+    getProjectInvestmentEharts, setInvestmentCityList
   } from '@/api/statistical'
   export default {
     data() {
@@ -82,6 +105,7 @@
         },
         loading: false,
         unitList: [],
+        cityList: [],
         flags: false,
         lb_value: '2021', // 柱状图类别
       }
@@ -93,6 +117,7 @@
       this.getList()
       this.bd_btn()
       this.eharts_fn()
+      this.city_btn()
     },
     methods: {
       picher_fn() {
@@ -107,11 +132,15 @@
         })
       },
       bd_btn() {
-        console.log(222)
         setInvestmentList().then(res => {
           this.unitList = res.rows
         })
       },
+      city_btn() {
+        setInvestmentCityList().then(res => {
+          this.unitList = res.rows
+        })
+      },
       dec_btn(row) {
         this.$router.push({
           path: '/management/row/index',

+ 33 - 3
ruoyi-ui/src/views/statistical/underConstruction/index.vue

@@ -33,7 +33,30 @@
       <el-col :span="6" style="padding: 24px 12px 24px 0 ;">
         <div class="in_right">
           <div class="rig_title">
-           市直单位
+           两区及乡镇
+          </div>
+          <div class="rig_tab_top">
+            <div class="rig_tab_item">
+              单位名称
+            </div>
+            <div class="rig_tab_item">
+              目标任务
+            </div>
+            <div class="rig_tab_item">
+              在建个数
+            </div>
+          </div>
+          <div class="rig_cont">
+            <div class="rig_items" v-for="(item,index) in areaList" :key="index">
+              <span>{{item.deptName}}</span>
+              <span>{{item.successMission?item.successMission:0}}个</span>
+              <span>{{item.targetSigningNum?item.targetSigningNum:0}}个</span>
+            </div>
+          </div>
+        </div>
+        <div class="rig_tab_top" style="background-color: #1C84C6;">
+          <div class="rig_title">
+            市直单位
           </div>
           <div class="rig_tab_top">
             <div class="rig_tab_item">
@@ -66,8 +89,8 @@
     toBeReviewedList,
     setExamine,
     setReject,
-    setProjectUnitAmountUnit ,
-    getProjectUnitAmountEharts
+    setProjectUnitAmountUnit,
+    getProjectUnitAmountEharts, setProjectAreaAmountUnit
   } from '@/api/statistical'
   export default {
     data() {
@@ -82,6 +105,7 @@
         },
         loading: false,
         unitList: [],
+        areaList: [],
         flags: false,
         lb_value: '2021', // 柱状图类别
       }
@@ -94,6 +118,7 @@
       this.bd_btn()
       this.zht_fn()
       this.eharts_fn()
+      this.area_btn()
     },
     methods: {
       picher_fn() {
@@ -115,6 +140,11 @@
           this.unitList = res.data
         })
       },
+      area_btn() {
+        setProjectAreaAmountUnit().then(res => {
+          this.areaList = res.data
+        })
+      },
       dec_btn(row) {
         this.$router.push({
           path: '/management/row/index',