index.vue 3.36 KB
Newer Older
1 2 3
<template>
  <div class="add">
    <div class="add-tab">
yanzhongrong's avatar
yanzhongrong committed
4
      <el-tabs v-model="activeName" :stretc="true">
neogcg's avatar
neogcg committed
5
        <el-tab-pane label="铁路线" name="0">
yanzhongrong's avatar
yanzhongrong committed
6
          <div v-if="activeName === '0'" class="content">
neogcg's avatar
neogcg committed
7
            <div class="content-title">添加铁路线</div>
yanzhongrong's avatar
yanzhongrong committed
8
            <railWay />
neogcg's avatar
neogcg committed
9
          </div>
neogcg's avatar
neogcg committed
10 11 12
        </el-tab-pane>

        <el-tab-pane label="站点" name="1">
yanzhongrong's avatar
yanzhongrong committed
13
          <div v-if="activeName === '1'" class="content">
neogcg's avatar
neogcg committed
14
            <div class="content-title">添加站点</div>
yanzhongrong's avatar
yanzhongrong committed
15
            <station />
neogcg's avatar
neogcg committed
16 17 18
          </div>
        </el-tab-pane>
        <el-tab-pane label="FSU" name="2">
yanzhongrong's avatar
yanzhongrong committed
19
          <div v-if="activeName === '2'" class="content">
neogcg's avatar
neogcg committed
20
            <div class="content-title">添加FSU</div>
yanzhongrong's avatar
yanzhongrong committed
21
            <FSU />
neogcg's avatar
neogcg committed
22 23 24
          </div>
        </el-tab-pane>
        <el-tab-pane label="监测设备" name="3">
yanzhongrong's avatar
yanzhongrong committed
25
          <div v-if="activeName === '3'" class="content">
neogcg's avatar
neogcg committed
26
            <div class="content-title">添加监测设备</div>
yanzhongrong's avatar
yanzhongrong committed
27
            <monitorEquip />
neogcg's avatar
neogcg committed
28 29 30
          </div>
        </el-tab-pane>
        <el-tab-pane label="漏缆" name="4">
yanzhongrong's avatar
yanzhongrong committed
31
          <div v-if="activeName === '4'" class="content">
neogcg's avatar
neogcg committed
32
            <div class="content-title">添加漏缆</div>
yanzhongrong's avatar
yanzhongrong committed
33
            <leakyCable />
neogcg's avatar
neogcg committed
34 35 36
          </div>
        </el-tab-pane>
        <el-tab-pane label="天馈线" name="5">
yanzhongrong's avatar
yanzhongrong committed
37
          <div v-if="activeName === '5'" class="content">
neogcg's avatar
neogcg committed
38
            <div class="content-title">添加天馈线</div>
yanzhongrong's avatar
yanzhongrong committed
39
            <antennaFeeder />
neogcg's avatar
neogcg committed
40 41
          </div>
        </el-tab-pane>
42 43 44 45 46 47
      </el-tabs>
    </div>
  </div>
</template>

<script>
neogcg's avatar
neogcg committed
48 49 50 51 52
import railWay from "./comp/railWay.vue";
import monitorEquip from "./comp/monitorEquip.vue";
import station from "./comp/station.vue";
import FSU from "./comp/FSU.vue";
import leakyCable from "./comp/leakyCable.vue";
yanzhongrong's avatar
yanzhongrong committed
53
import antennaFeeder from "./comp/line.vue";
54
export default {
neogcg's avatar
neogcg committed
55 56 57 58 59
  components: {
    monitorEquip,
    station,
    railWay,
    FSU,
yanzhongrong's avatar
yanzhongrong committed
60 61
    leakyCable,
    antennaFeeder
neogcg's avatar
neogcg committed
62
  },
63 64
  data() {
    return {
neogcg's avatar
neogcg committed
65
      activeName: "0",
66 67
      tabs: [
        {
neogcg's avatar
neogcg committed
68
          label: "铁路线",
yanzhongrong's avatar
yanzhongrong committed
69
          key: "0"
70 71
        },
        {
neogcg's avatar
neogcg committed
72
          label: "站点",
yanzhongrong's avatar
yanzhongrong committed
73
          key: "1"
74 75
        },
        {
neogcg's avatar
neogcg committed
76
          label: "FSU",
yanzhongrong's avatar
yanzhongrong committed
77
          key: "2"
78 79
        },
        {
neogcg's avatar
neogcg committed
80
          label: "监测设备",
yanzhongrong's avatar
yanzhongrong committed
81
          key: "3"
82 83
        },
        {
neogcg's avatar
neogcg committed
84
          label: "漏缆",
yanzhongrong's avatar
yanzhongrong committed
85
          key: "4"
86 87
        },
        {
neogcg's avatar
neogcg committed
88
          label: "天馈线",
yanzhongrong's avatar
yanzhongrong committed
89 90 91 92
          key: "5"
        }
      ]
    }
93 94
  },
  methods: {
yanzhongrong's avatar
yanzhongrong committed
95 96
  }
}
97 98 99 100 101 102
</script>

<style lang="scss" scoped>
::v-deep .el-tabs__nav {
  display: flex;
  width: 100%;
103
  padding-bottom: 10px;
104 105 106
  .el-tabs__item {
    flex: 1;
    text-align: center;
107 108 109 110 111 112 113 114
    font-size: 18px;
    color: #666;
  }
  .el-tabs__item.is-active {
    color: #1e64f6;
  }
  .el-tabs__active-bar {
    background-color: #1e64f6;
115 116
  }
}
117 118 119 120 121 122 123 124 125
.add {
  padding: 10px;
  .tab {
    // width: 600px;
    margin: 0 auto;
  }
  .content {
    border: 1px solid #e3e3e3;
    border-radius: 10px;
neogcg's avatar
neogcg committed
126 127
    // height: 700px;
    // overflow-y: scroll;
128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143
    .content-title {
      width: 100%;
      height: 60px;
      background: rgba(226, 235, 255, 0.39);
      line-height: 60px;
      font-size: 18px;
      color: #333;
      font-weight: 500;
      text-align: center;
      border-bottom: 1px solid #e3e3e3;
    }
    .form {
      padding: 20px 0;
      width: 600px;
      margin: 0 auto;
    }
144
  }
145 146 147 148 149 150
  .btn {
    padding-top: 50px;
    text-align: center;
    button {
      width: 120px;
    }
151 152 153
  }
}
</style>