forecastThreeLineDrawer.vue 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183
  1. <template>
  2. <view class="container">
  3. <!-- 抽屜 -->
  4. <uni-drawer :visible="drawerIsShow" :width="width" @close="closeDrawer" style="z-index: 99999;">
  5. <view style="padding:0rpx; background-color:#1A1A1A;">
  6. <view class="picture">
  7. <view class="sisGroup">预测功能分组
  8. <view class="iconImgage">
  9. </view>
  10. </view>
  11. <view v-for="(item,index) in drawerList" :class="[changeGary==index?'statusMonitoring':'item']" :key="index" @click="clickChangeColor(index)">
  12. <div v-if="(index==0)" @click="startSwitch()">
  13. {{item.name}}
  14. </div>
  15. <div v-if="(index==1)" @tap="common.navTo('/components/monitor/StatusMonitor')">
  16. {{item.name}}
  17. </div>
  18. <div v-if="(index==2)" @tap="common.navTo('/components/monitor/MatrixMonitor')">
  19. {{item.name}}
  20. </div>
  21. <div v-if="(index==3)" @tap="common.navTo('/components/monitor/WindMonitor')">
  22. {{item.name}}
  23. </div>
  24. <div v-if="(index==4)" @tap="common.navTo('/components/monitor/PersonalMonitor')">
  25. {{item.name}}
  26. </div>
  27. </view>
  28. </view>
  29. <view class="cu-bar tabbar bg-black">
  30. <view class="action">
  31. <view class="icon cuIcon-repair text-black">
  32. </view>
  33. <view class="text-black">设置</view>
  34. </view>
  35. <view class="action" style="margin-left: 30px;">
  36. <view class="icon cuIcon-command text-black">
  37. </view>
  38. <view class="text-black">修改密码</view>
  39. </view>
  40. </view>
  41. </view>
  42. </uni-drawer>
  43. </view>
  44. </template>
  45. <script>
  46. import uniDrawer from "@/uni-drawer/uni-drawer.vue"
  47. import uniList from '@/uni-list/uni-list.vue'
  48. import uniListItem from '@/uni-list-item/uni-list-item.vue'
  49. import uniIcons from '@/uni-icons/uni-icons.vue'
  50. export default {
  51. components: {
  52. uniDrawer,
  53. uniList,
  54. uniListItem,
  55. uniIcons
  56. },
  57. data: function() {
  58. return {
  59. drawerIsShow: false,
  60. drawerList: [],
  61. width: 250,
  62. inconList: [],
  63. changeGary: -1,
  64. toggleSwitch:false,
  65. }
  66. },
  67. methods: {
  68. openDrawer: function(width, drawerList, inconList) {
  69. this.drawerIsShow = true;
  70. this.drawerList = drawerList;
  71. this.width = width;
  72. this.inconList = inconList;
  73. },
  74. closeDrawer: function() {
  75. this.drawerIsShow = false;
  76. //#ifdef H5
  77. this.$emit("leftbar");
  78. //#endif
  79. //#ifdef APP-PLUS
  80. this.$parent.leftbar();
  81. //#endif
  82. },
  83. clickChangeColor: function(index) {
  84. this.changeGary = index;
  85. },
  86. goToIndex:function(){
  87. uni.switchTab({
  88. url: '/pages/index/Index'
  89. });
  90. },
  91. startSwitch:function(){
  92. this.$parent.$root.toggleSwitch = true;
  93. }
  94. }
  95. }
  96. </script>
  97. <style>
  98. .container{
  99. }
  100. .sisGroup {
  101. width: 90%;
  102. height: 65px;
  103. color: silver;
  104. font-size: 13px;
  105. padding-top: 40px;
  106. margin-left: 5%;
  107. font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Helvetica Neue", STHeiti, "Microsoft Yahei", Tahoma, Simsun, sans-serif;
  108. }
  109. .statusMonitoring {
  110. background-color: #393939;
  111. width: 90%;
  112. margin-left: 5%;
  113. height: 40px;
  114. margin-top: 10px;
  115. /* text-align: center; */
  116. color: silver;
  117. font-size: 14px;
  118. padding-top: 10px;
  119. padding-left: 10px;
  120. font-family: Helvetica Neue, Helvetica, sans-serif;
  121. }
  122. .picture {
  123. width: 300px;
  124. height: 700px;
  125. background-color: #1A1A1A;
  126. }
  127. .cu-bar {
  128. position: fixed;
  129. top: calc(100% - 50px);
  130. width: 100%;
  131. background-color: #1A1A1A;
  132. }
  133. .icon {
  134. float: left;
  135. }
  136. .text-black {
  137. float: left;
  138. line-height: 28px;
  139. font-size: 15px;
  140. background-color: #1A1A1A;
  141. color: silver;
  142. }
  143. .iconImgage{
  144. width: 29px;
  145. height: 35px;
  146. background-color: red;
  147. margin-left: 82px;
  148. margin-top: -25px;
  149. background-image: url(../../static/picture/i.jpg);
  150. }
  151. .item {
  152. width: 90%;
  153. height: 40px;
  154. margin-top: 10px;
  155. margin-left: 5%;
  156. /* float: right; */
  157. /* margin-right: 10px; */
  158. background-color: #272727;
  159. /* text-align: center; */
  160. color: silver;
  161. font-size: 14px;
  162. padding-top: 10px;
  163. padding-left: 10px;
  164. font-family: Helvetica Neue, Helvetica, sans-serif;
  165. }
  166. </style>