派生自 wuyushui/SewerAndRainNetwork

ChenZeping
2021-04-27 4e725a04dbe02d7c631a82da0526c5ef5defa15c
src/components/BaseNav/WasteSolid/PublicTable.vue
@@ -5,7 +5,7 @@
    <span></span>
    <span></span>
    <div class="main-table">
      <el-table :data="listData" style="width: 100%" height="325px" :row-class-name="tableRowClassName">
      <el-table :data="listData" style="width: 100%" height="200px" :row-class-name="tableRowClassName">
        <el-table-column v-for="(item, index) in listLabel" :key="index" :prop="item.prop"
                         :label="item.label" :show-overflow-tooltip="true"></el-table-column>
      </el-table>
@@ -14,6 +14,8 @@
</template>
<script>
import mapApi from '@/api/mapApi'
export default {
  name: 'PublicTable',
  props: ['displayContentTable'],
@@ -52,12 +54,21 @@
      ]
    }
  },
  mounted () {
    this.$nextTick(() => {
      this.listData.push(this.displayContentTable[0], {}, {}, {}, {}, {}, {})
    })
  },
  // mounted () {
  //   this.$nextTick(() => {
  //
  //   })
  // },
  methods: {
    async refsDataTable (data) {
      const StoragePlaceId = {
        StoragePlaceId: data
      }
      const result = await mapApi.getSolidWasteDetail(StoragePlaceId)
      this.listData = result.Result.DataInfo[0]
      this.listData.push({}, {}, {}, {}, {})
      // console.log(this.listData)
    },
    // 隔行颜色设置
    tableRowClassName ({
      row,
@@ -75,12 +86,20 @@
</script>
<style lang="less" scoped>
.main-table {
  border: 1px #02a6b5 solid;
/deep/ .el-table thead tr {
  color: #02a6b5 !important;
  //.el-table .has-gutter tr th .cell {
  //  //color: #fff; 435
  //}
}
/deep/ .el-table td {
  border-bottom: none !important;
}
/deep/ .el-table .has-gutter tr th {
  border: none;
}
/deep/ .el-table th.is-leaf {
@@ -88,8 +107,8 @@
}
/deep/ .el-table td {
  height: 45px !important;
  line-height: 45px !important;
  height: 30px !important;
  line-height: 30px !important;
}
/deep/ .el-table tbody tr:hover > td {
@@ -99,16 +118,22 @@
.slotChildTable {
  position: relative;
  background: rgba(33, 41, 69, 0.9);
  //border: 1px solid red;
  .main-table {
    border: 1px #396d83 solid;
  }
}
.slotChildTable span {
  padding: 6px;
  border-style: solid;
  border-color: #02a6b5;
}
.slotChildTable span:nth-child(1) {
  position: absolute;
  left: -1px;
  top: -1px;
  padding: 10px;
  border-style: solid;
  border-color: #02a6b5;
  border-width: 1px 0 0 1px;
}
@@ -116,9 +141,6 @@
  position: absolute;
  right: -1px;
  top: -1px;
  padding: 10px;
  border-style: solid;
  border-color: #02a6b5;
  border-width: 1px 1px 0 0;
}
@@ -126,9 +148,6 @@
  position: absolute;
  right: -1px;
  bottom: -1px;
  padding: 10px;
  border-style: solid;
  border-color: #02a6b5;
  border-width: 0 1px 1px 0;
}
@@ -136,9 +155,6 @@
  position: absolute;
  left: -1px;
  bottom: -1px;
  padding: 10px;
  border-style: solid;
  border-color: #02a6b5;
  border-width: 0 0 1px 1px;
}