xiangpei
2024-08-02 c047fa1a6163ecf6e9d449fdc4842ea306d26bd4
数据中心详情接口调用
2个文件已修改
1个文件已添加
31 ■■■■■ 已修改文件
src/api/platform/data-center.js 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/system/data-manage/data-detail/index.vue 8 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/system/data-manage/index.vue 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/api/platform/data-center.js
New file
@@ -0,0 +1,11 @@
import request from '@/utils/request'
// 数据中心接口
export function dataCenter(url, params) {
  return request({
    url: '/data/center/' + url,
    method: 'get',
    params: params
  })
}
src/views/system/data-manage/data-detail/index.vue
@@ -103,7 +103,7 @@
</template>
<script>
import { listPlatform, getPlatform, delPlatform, addPlatform, updatePlatform } from "@/api/platform/vehicle-data-monitor";
import { dataCenter } from "@/api/platform/data-center";
import { videoData, carData, faceData, equipment } from "./list";
import store from '@/store';
@@ -183,13 +183,13 @@
      this.tableHead = data.columns;
      this.cardList = data.card;
    }
    this.getList();
    this.getList(this.$route.query.url);
  },
  methods: {
    /** 查询卡口过车数据一致性列表 */
    getList() {
    getList(url) {
      this.loading = true;
      listPlatform(this.queryParams).then(response => {
      dataCenter(url, this.queryParams).then(response => {
        this.platformList = response.rows;
        this.total = response.total;
        this.loading = false;
src/views/system/data-manage/index.vue
@@ -26,7 +26,7 @@
          :style="item.ruleName == '' ? 'display:none' : ''"
          class="col-margin"
        >
          <el-link @click="handleDetail(item, item.ruleIndex)" style="width: 100%">
          <el-link @click="handleDetail(item, item.ruleIndex, item.apiUrl)" style="width: 100%">
            <el-card
              style="min-width: 150px;width:100%; height: 150px; text-align: center"
            >
@@ -65,7 +65,7 @@
          :style="item.ruleName == '' ? 'display:none' : ''"
          class="col-margin"
        >
          <el-link @click="handleDetail(item, item.ruleIndex)" style="width: 100%">
          <el-link @click="handleDetail(item, item.ruleIndex, item.apiUrl)" style="width: 100%">
            <el-card style="min-width: 150px;width:100%; height: 150px; text-align: center">
              <i style="font-size: 40px; padding: 15px" :class="item.icon"></i>
              <div>{{ item.ruleName }}</div>
@@ -102,7 +102,7 @@
          :style="item.ruleName == '' ? 'display:none' : ''"
          class="col-margin"
        >
          <el-link @click="handleDetail(item, item.ruleIndex)" style="width: 100%">
          <el-link @click="handleDetail(item, item.ruleIndex, item.apiUrl)" style="width: 100%">
            <el-card style="min-width: 150px;width:100%; height: 150px; text-align: center">
              <i style="font-size: 40px; padding: 15px" :class="item.icon"></i>
              <div>{{ item.ruleName }}</div>
@@ -139,7 +139,7 @@
          :style="item.ruleName == '' ? 'display:none' : ''"
          class="col-margin"
        >
          <el-link @click="handleDetail(item, item.ruleIndex)" style="width: 100%">
          <el-link @click="handleDetail(item, item.ruleIndex, item.apiUrl)" style="width: 100%">
            <el-card style="min-width: 150px;width:100%; height: 150px; text-align: center">
              <i style="font-size: 40px; padding: 15px" :class="item.icon"></i>
              <div>{{ item.ruleName }}</div>
@@ -383,9 +383,9 @@
        this.loading = false;
      });
    },
    handleDetail(item, index) {
    handleDetail(item, index, url) {
      this.$router.push({
        path: `/data-manage/data-detail/index/1/1?type=${item.ruleCategory}&index=${index}`,
        path: `/data-manage/data-detail/index/1/1?type=${item.ruleCategory}&index=${index}&url=${url}`,
      });
    },
  },