equipmentRetrieval.vue 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251
  1. <template>
  2. <view>
  3. <!-- 搜索 -->
  4. <view class="search">
  5. <u-icon name="arrow-left" size="36"></u-icon>
  6. <view class="search-box">
  7. <u-search placeholder="搜索设备名称或型号" :show-action="false">
  8. </u-search>
  9. <view class="search-btn">
  10. <view class="text">
  11. 搜索
  12. </view>
  13. </view>
  14. </view>
  15. </view>
  16. <view class="main">
  17. <!-- 分类 -->
  18. <view class="classify">
  19. <view class="item " v-for="(item,index) in menuList" @click="toggle(index)"
  20. :class="{'checked':index ==checkindex }">
  21. {{item.name}}
  22. </view>
  23. </view>
  24. <!-- 类型 -->
  25. <view class="type" >
  26. <view class="type-item" v-for="item in 2">
  27. <view class="title">
  28. 设备类型一
  29. </view>
  30. <view class="content">
  31. <view class="item" v-for="item in 2">
  32. <view class="picture">
  33. <img src="../../../assets/img/typePic.png" alt="">
  34. </view>
  35. <view class="infos" >
  36. <view class="name">
  37. 安防摄像头
  38. </view>
  39. <view class="model">
  40. <view class="infos-title">
  41. 型号:
  42. </view>
  43. <view class="value">
  44. DAH08410512
  45. </view>
  46. </view>
  47. <view class="inventory">
  48. <view class="infos-title">
  49. 库存:
  50. </view>
  51. <view class="value">
  52. 10
  53. </view>
  54. </view>
  55. </view>
  56. </view>
  57. </view>
  58. </view>
  59. </view>
  60. </view>
  61. </view>
  62. </template>
  63. <script>
  64. export default {
  65. data() {
  66. return {
  67. checkindex: 0,
  68. menuList: [{
  69. name: '安全工器具'
  70. },
  71. {
  72. name: '测量工器具'
  73. },
  74. {
  75. name: '放线工器具'
  76. },
  77. {
  78. name: '加工设备'
  79. },
  80. {
  81. name: '起重设备'
  82. },
  83. {
  84. name: '共用设备 '
  85. },
  86. {
  87. name: '高压试验设备'
  88. },
  89. {
  90. name: '继电保护设备'
  91. },
  92. {
  93. name: '生活设备'
  94. },
  95. {
  96. name: '工程技术科'
  97. },
  98. {
  99. name: '菜单1'
  100. },
  101. {
  102. name: '菜单2'
  103. },
  104. {
  105. name: '菜单3'
  106. },
  107. {
  108. name: '菜单4'
  109. },
  110. ]
  111. }
  112. },
  113. methods: {
  114. toggle(index) {
  115. this.checkindex = index
  116. }
  117. }
  118. }
  119. </script>
  120. <style scoped lang="scss">
  121. page {
  122. background-color: #fff;
  123. }
  124. // 搜索
  125. .search {
  126. padding: 12rpx 24rpx;
  127. display: flex;
  128. border-radius: 8px;
  129. overflow: hidden;
  130. .search-box {
  131. display: flex;
  132. border-radius: 8px;
  133. overflow: hidden;
  134. }
  135. /deep/.u-search {
  136. width: 530rpx;
  137. margin: auto !important;
  138. position: relative;
  139. flex: 0;
  140. margin: 0 !important;
  141. height: 64rpx !important;
  142. }
  143. /deep/.u-content {
  144. width: 430px;
  145. border-radius: 0px !important;
  146. height: 64rpx !important;
  147. }
  148. /deep/.u-icon--right {
  149. margin-right: 16rpx;
  150. }
  151. .search-btn {
  152. width: 100rpx;
  153. height: 64rpx;
  154. background-color: #f2f2f2;
  155. .text {
  156. height: 40rpx;
  157. margin: 12rpx 0;
  158. border-left: 1px solid #999999;
  159. font-family: Microsoft Yahei;
  160. text-align: center;
  161. color: rgba(16, 98, 213, 1);
  162. font-size: 28rpx;
  163. }
  164. }
  165. }
  166. .main {
  167. display: flex;
  168. // 分类
  169. .classify {
  170. width: 200rpx;
  171. height: calc(100vh - 88rpx);
  172. background-color: #F0F0F0;
  173. overflow-y: scroll;
  174. font-size: 28rpx;
  175. .item {
  176. height: 120rpx;
  177. line-height: 120rpx;
  178. text-align: center;
  179. }
  180. .checked {
  181. background-color: #fff;
  182. color: #1062D5
  183. }
  184. }
  185. // 类型
  186. .type{
  187. padding: 24rpx 32rpx;
  188. height: calc(100vh - 88rpx);
  189. overflow-y: scroll;
  190. .type-item{
  191. margin-bottom: 80rpx;
  192. }
  193. .title{
  194. color: rgba(51, 51, 51, 1);
  195. font-size: 32rpx;
  196. margin-bottom: 24rpx;
  197. }
  198. .content{
  199. .item{
  200. display: flex;
  201. margin-bottom: 64rpx;
  202. .picture{
  203. width: 120rpx;
  204. height: 120rpx;
  205. border-radius: 8rpx;
  206. overflow: hidden;
  207. img{
  208. width: 100%;
  209. height: 100%;
  210. }
  211. }
  212. .infos{
  213. margin-left: 16rpx;
  214. .name{
  215. color: rgba(51, 51, 51, 1);
  216. font-size: 32rpx;
  217. margin-bottom: 16rpx;
  218. }
  219. .model,.inventory{
  220. color: rgba(153, 153, 153, 1);
  221. font-size: 24rpx;
  222. display: flex;
  223. margin-bottom: 8rpx;
  224. }
  225. }
  226. }
  227. }
  228. }
  229. }
  230. </style>