Browse Source

历史数据

wyh 11 months ago
parent
commit
0fb59eda08

+ 2 - 0
src/components/module_interLock/UEquipmentTree/UEquipmentTree.vue

@@ -204,6 +204,8 @@
   height: 100%;
   height: 100%;
   background-color: #fff;
   background-color: #fff;
   padding: 15px;
   padding: 15px;
+  border: 1px solid #CADAE6;
+  box-shadow: 0px 5px 10px 0 #CADAE6;
   .tree-container{
   .tree-container{
     width: 100%;
     width: 100%;
     height: calc(100% - 40px);
     height: calc(100% - 40px);

src/views/module_interLock/interlockHistoryData/InterlockHistoryList.vue → src/views/module_interLock/interlockHistoryData/InterlockHistory/InterlockHistoryList.vue


+ 68 - 0
src/views/module_interLock/interlockHistoryData/InterlockHistoryIndex.vue

@@ -0,0 +1,68 @@
+<template>
+    <div class="all">
+        <div class="left">
+            <u-equipment-tree @select="selectEquipment"></u-equipment-tree>
+        </div>
+        <div class="right">
+          <!-- <interlock-history-list ref="summaryList" :selectData="selectData"></interlock-history-list> -->
+          <interlock-summary-list ref="summaryList" :selectData="selectData"></interlock-summary-list>
+        </div>
+    </div>
+</template>
+
+<script>
+
+import InterlockSummaryList from '../InterlockSummary/InterlockSummaryList.vue'
+import InterlockHistoryList from './InterlockHistory/InterlockHistoryList.vue'
+    export default({
+        components: {
+          InterlockHistoryList,
+          InterlockSummaryList
+        },
+        data () {
+            return {
+                selectData: {}
+            }
+        },
+        methods: {
+            selectEquipment(selectedKeys,e){
+                // console.log(99,selectedKeys,e)
+                if (selectedKeys.length == 0) {
+                    this.$nextTick(()=>{
+                        this.$refs.summaryList.searchReset();
+                    })
+                } else {
+                    let interlockType = e.selectedNodes[0].data.props.interlockType
+                    let pid = e.selectedNodes[0].data.props.pid
+                    // console.log(88,interlockType)
+                    this.selectData.interlockType = interlockType
+                    this.selectData.pid = pid
+                    this.selectData.id = e.selectedNodes[0].data.props.id
+                    this.$nextTick(()=>{
+                        this.$refs.summaryList.getDataList();
+                    })
+                }
+            }
+        },
+    })
+</script>
+
+<style lang="less" scoped>
+.all{
+    height: calc(100vh - 65px);
+    width: 100%;
+    display: flex;
+}
+.left{
+    height: 100%;
+    width: 20%;
+    /* border: 2px solid red; */
+    margin-right: 10px;
+    margin-left: 5px;
+}
+.right{
+    height: 100%;
+    width: 80%;
+    /* border: 2px solid red; */
+}
+</style>

+ 3 - 4
src/views/module_interLock/interlockHistoryData/index.vue

@@ -2,8 +2,7 @@
   <a-card :bordered="false">
   <a-card :bordered="false">
     <a-tabs type="card" @change="callback">
     <a-tabs type="card" @change="callback">
       <a-tab-pane key="historyData" tab="历史数据">
       <a-tab-pane key="historyData" tab="历史数据">
-        Content of Tab Pane 1
-        <interlock-historyList></interlock-historyList>
+        <interlock-history-index></interlock-history-index>
       </a-tab-pane>
       </a-tab-pane>
       <a-tab-pane key="timedReport" tab="定时报表">
       <a-tab-pane key="timedReport" tab="定时报表">
         Content of Tab Pane 2
         Content of Tab Pane 2
@@ -14,13 +13,13 @@
 </template>
 </template>
 
 
 <script>
 <script>
-import InterlockHistoryList from './InterlockHistoryList.vue';
+import InterlockHistoryIndex from './InterlockHistoryIndex.vue';
 import InterlockTimedReport from './InterlockTimedReport.vue';
 import InterlockTimedReport from './InterlockTimedReport.vue';
 export default {
 export default {
   name: '',
   name: '',
   components: {
   components: {
-    InterlockHistoryList,
     InterlockTimedReport,
     InterlockTimedReport,
+    InterlockHistoryIndex,
   },
   },
   data () {
   data () {
     return {
     return {