Browse Source

Merge branch 'onemap_zmg' of http://47.103.92.60:3003/skyversation/qp_onemap_ui into MicroFunction

DESKTOP-6LTVLN7\Liumouren 3 weeks ago
parent
commit
858ff7bcc3

+ 61 - 0
src/api/count.js

@@ -748,6 +748,67 @@ export function serviceInfo(start, end) {
   };
   return resolveDmsMultiTableResult(postform(multiSearch, data));
 }
+export function getAppList(start, end) {
+    let data = {
+        "columnId": preCountDmsId,
+        "autoSelectItem": false,
+        "page": 1,
+        "pageSize": 999999,
+        "columnAlias": "precount",
+        "conditionsList": JSON.stringify([
+            ...notNullAndEmptyCheckers("precount", "c_application"),
+            ...timeCheckers(start, end),
+        ]),
+        "selectItem": JSON.stringify([
+            {
+                "table": "precount",
+                "column": "c_application",
+                "alias": "name"
+            }
+        ]),
+        "groupBy": JSON.stringify([
+            {
+                "table": "precount",
+                "column": "c_application"
+            }
+        ])
+    }
+    return resolveDmsMultiTableResult(postform(multiSearch, data));
+}
+export function countlmType(start, end) {
+
+    let data = {
+        "columnId": preCountDmsId,
+        "autoSelectItem": false,
+        "page": 1,
+        "pageSize": 10000,
+        "columnAlias": "precount",
+        "selectItem": JSON.stringify([
+            {
+                "table": "precount",
+                "column": "c_count",
+                "function": "sum",
+                "alias": "count"
+            }, {
+                "table": "precount",
+                "column": "c_dms_column",
+                "alias": "column"
+            }
+        ]),
+        "groupBy": JSON.stringify([
+            {
+                "table": "precount",
+                "column": "c_dms_column"
+            }
+        ]),
+        "conditionsList": JSON.stringify([
+            ...timeCheckers(start, end),
+            ...notNullAndEmptyCheckers("precount", "c_dms_column"),
+        ]),
+    }
+
+    return resolveDmsMultiTableResult(postform(multiSearch, data));
+}
 function formatDateToDb(date) {
   const year = date.getFullYear();
   const month = String(date.getMonth() + 1).padStart(2, "0");

+ 2 - 0
src/views/rwgl/Index.vue

@@ -96,6 +96,7 @@
                 effect="dark"
                 v-show="getType(scope.row.main_c_type) != null"
                 disable-transitions
+                style="background: none !important;"
                 >{{ getType(scope.row.main_c_type)?.name ?? "" }}
               </el-tag>
             </template>
@@ -107,6 +108,7 @@
                 v-show="getStatus(scope.row.main_c_state) != null"
                 :type="statusStaticInfo[scope.row.main_c_state]?.tagType ?? ''"
                 disable-transitions
+                style="background: none !important;"
                 >{{ getStatus(scope.row.main_c_state)?.name ?? "" }}</el-tag
               >
             </template>

+ 4 - 1
src/views/wgn/Example.vue

@@ -21,9 +21,12 @@ export default {
   },
   mounted() {
     window.SkySceneryConfig = {};
-    window.loadScripts([systemConfig.scriptMain]).then(() => {
+    window.loadScripts(systemConfig.example.scriptArr).then(() => {
       this.creatMap();
     });
+    // window.loadScripts([systemConfig.scriptMain]).then(() => {
+    //   this.creatMap();
+    // });
   },
   methods: {
     creatMap() {

+ 39 - 2
src/views/yxgl/StatisticalAnalysis.vue

@@ -188,10 +188,13 @@
     <div class="bigCard">
       <div class="bigCard_title">应用类信息统计</div>
       <div class="flex">
-        <div style="width: 58%; height: 400px">
+        <div style="width: 33%; height: 400px">
           <EchartsDome :chartOption="chartOptions['热点应用TOP10排名']" title="热点应用TOP10排名" />
         </div>
-        <div style="width: 38%; height: 400px">
+        <div style="width: 33%; height: 400px">
+          <EchartsDome :chartOption="chartOptions['栏目统计分布']" title="栏目统计分布" />
+        </div>
+        <div style="width: 33%; height: 400px">
           <EchartsDome :chartOption="chartOptions['应用状态分布']" title="应用状态分布" />
         </div>
       </div>
@@ -251,6 +254,7 @@ import card from "@/components/yxgl/card.vue";
 import EchartsDome from "@/components/yxgl/EchartsDome.vue";
 import Table from "@/components/yxgl/table.vue";
 import appCenter from "@/api/appCenter";
+import { countlmType } from "@/api/count";
 
 export default {
   name: "",
@@ -365,6 +369,8 @@ export default {
             this.$moment(new Date(newVal[0])).format("YYYY-MM-DD 00:00:00"),
           ];
           this.initChart();
+          // 栏目统计分布
+          this.getColumnCount();
         }
       },
       deep: true,
@@ -719,6 +725,37 @@ export default {
 
       this.dataToOption("数据质量评分", "radar", null, null);
     },
+    getColumnCount() {
+      //  this.$moment(new Date(this.nowTimes[0])).format("YYYY-MM-DD 00:00:00"),
+      //       this.$moment(new Date(this.nowTimes[1])).format("YYYY-MM-DD 23:59:59"),
+      let param = {
+          start: "2000-01-01",
+          end: this.$moment(new Date(this.nowTimes[1])).format("YYYY-MM-DD"),
+        };
+        countlmType(param.start, param.end).then((res) => {
+          console.log("========栏目统计分布=========", res);
+        })
+        let columnDatas = [
+          {count: 3, service_name: "任务"},
+          {count: 5, service_name: "反馈信息"},
+          {count: 7, service_name: "其它"},
+        ];
+
+        //   console.log("========栏目统计分布=========", res.content.dataTypes);
+        if (columnDatas && columnDatas.length > 0) {
+          this.dataToOption("栏目统计分布", "pie", [...columnDatas], {
+            pieKey: { value: "count", name: "service_name" },
+            pieData: [],
+            legend: {
+              bottom: 10,
+            },
+            radius: "60%",
+            padAngle: 0,
+            borderRadius: 0,
+            label: {},
+          });
+        }
+    },
     // 导出所选时间范围内的所有服务数据
     downFileAllServiceDatas() {
       this.exportLoading = true;

+ 18 - 6
src/views/yygl/monitor/index.vue

@@ -80,9 +80,9 @@
             >
               <el-option
                 v-for="item in selectAapplications"
-                :key="item.id"
-                :label="item.title"
-                :value="item.title"
+                :key="item.name"
+                :label="item.name"
+                :value="item.name"
               />
             </el-select>
             <div>
@@ -160,7 +160,7 @@
 <script>
 import * as echarts from "echarts";
 import appCenter from "@/api/appCenter";
-import { topApp, countAppInfo } from "@/api/count";
+import { topApp, countAppInfo, getAppList } from "@/api/count";
 import moment from "moment";
 import NumberScroll from "@/components/AppVue/numberScroll.vue";
 export default {
@@ -468,9 +468,9 @@ export default {
             createTime: moment(item.create_time).format("YYYY-MM-DD HH:mm:ss"),
           }));
           this.applications = this.itemApplications;
-          this.selectAapplications = this.applications.filter((item) => item.yylx == "0"); //yylx 0:内部 1:外部
+          // this.selectAapplications = this.applications.filter((item) => item.yylx == "0"); //yylx 0:内部 1:外部
           this.newApplications = this.applications.slice(0, 10); // 获取前十个元素
-          this.selectedAppRange = this.applications[0].title;
+          // this.selectedAppRange = this.applications[0].title;
           this.getTypeArrs();
           this.getCountAppInfo();
         } else {
@@ -479,6 +479,18 @@ export default {
           this.selectedAppRange = "";
         }
       });
+
+      let param = {
+        start: "2000-01-01",
+        end: moment().format("YYYY-MM-DD"),
+      };
+      getAppList(param.start, param.end).then((res) => {
+        console.log("=======getAppList======"+res);
+        this.selectAapplications = res;
+        this.selectedAppRange = this.selectAapplications[0].name;
+
+      });
+
     },
     getTypeArrs() {
       let that = this;