equipmentDetail.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533
  1. <template>
  2. <view>
  3. <u-navbar title="接地线无杆(新)"></u-navbar>
  4. <!-- 图片 -->
  5. <view class="picture">
  6. <img :src="info.img" alt="">
  7. <view class="amount">
  8. <text>1</text>/
  9. <text>5</text>
  10. </view>
  11. </view>
  12. <!-- 信息 -->
  13. <view class="main">
  14. <view class="title">
  15. 接地线无杆(新)
  16. </view>
  17. <!-- 标签 -->
  18. <view class="tabs ">
  19. <u-tabs bar-width="120" inactive-color="#999999" active-color="#000000" :list="list" :is-scroll="false" :current="current" @change="change"></u-tabs>
  20. </view>
  21. <view class="content">
  22. <!-- 设备信息 -->
  23. <view class="infos">
  24. <view class="name">
  25. <view class="icon"><img src="@/assets/img/riLine-robot-line@1x.png" alt=""></view>
  26. <view class="text">
  27. 设备信息
  28. </view>
  29. </view>
  30. <view class="details">
  31. <view class="item">
  32. <view class="item-title">
  33. 规格
  34. </view>
  35. <view class="item-value">
  36. 220kV
  37. </view>
  38. </view>
  39. <view class="item" >
  40. <view class="item-title">
  41. 购置时间
  42. </view>
  43. <view class="item-value">
  44. 2022.5
  45. </view>
  46. </view>
  47. <view class="item" >
  48. <view class="item-title">
  49. 数量
  50. </view>
  51. <view class="item-value">
  52. 48
  53. </view>
  54. </view>
  55. <view class="item" >
  56. <view class="item-title">
  57. 设备状况
  58. </view>
  59. <view class="item-value">
  60. 合格
  61. </view>
  62. </view>
  63. <view class="item" >
  64. <view class="item-title">
  65. 单位
  66. </view>
  67. <view class="item-value">
  68. </view>
  69. </view>
  70. <view class="item" >
  71. <view class="item-title">
  72. 试验时间
  73. </view>
  74. <view class="item-value">
  75. 2022.05.19
  76. </view>
  77. </view>
  78. <view class="item" >
  79. <view class="item-title">
  80. 制造厂家
  81. </view>
  82. <view class="item-value">
  83. 鸿瑞电力工程有限公司
  84. </view>
  85. </view>
  86. <view class="item" >
  87. <view class="item-title">
  88. 试验周期
  89. </view>
  90. <view class="item-value">
  91. 1年
  92. </view>
  93. </view>
  94. <view class="item" >
  95. <view class="item-title">
  96. 单价
  97. </view>
  98. <view class="item-value">
  99. </view>
  100. </view>
  101. </view>
  102. </view>
  103. </view>
  104. <!-- 存放地点 -->
  105. <view class="content">
  106. <view class="infos">
  107. <view class="name">
  108. <view class="icon"><img src="@/assets/img/riLine-robot-line@1x.png" alt=""></view>
  109. <view class="text">
  110. 存放地点
  111. </view>
  112. </view>
  113. <view class="details">
  114. <view class="location">
  115. 荆力总包仓库A区C货架2-12
  116. </view>
  117. </view>
  118. </view>
  119. </view>
  120. <!-- 巡检记录 -->
  121. <view class="content">
  122. <view class="infos">
  123. <view class="name">
  124. <view class="icon"><img src="@/assets/img/riLine-device-recover-line@1x.png" alt=""></view>
  125. <view class="text">
  126. 巡检记录
  127. </view>
  128. <view class="all">
  129. 全部记录<u-icon name="arrow-right"></u-icon>
  130. </view>
  131. </view>
  132. <!-- 提示 -->
  133. <view class="hint">
  134. <u-alert-tips icon="bell-fill" type="warning" :show-icon="true" :title="title" :description="description"></u-alert-tips>
  135. </view>
  136. <view class="inspection-contents">
  137. <view class="inspection-title">
  138. <view class="text">
  139. 巡检内容名称
  140. </view>
  141. <view class="state">
  142. 合格
  143. </view>
  144. </view>
  145. <view class="inspection-infos">
  146. <view class="inspection-personnel">
  147. <view class="inspection-name">
  148. 巡检人:
  149. </view>
  150. <view class="value">
  151. 孙斌
  152. </view>
  153. </view>
  154. <view class="inspection-date">
  155. 2023/03/15 09:45:21
  156. </view>
  157. </view>
  158. </view>
  159. </view>
  160. </view>
  161. <!-- 出入库记录 -->
  162. <view class="content">
  163. <view class="infos">
  164. <view class="name">
  165. <view class="icon"><img src="@/assets/img/riLine-todo-line@1x.png" alt=""></view>
  166. <view class="text">
  167. 出入库记录
  168. </view>
  169. <view class="all">
  170. 全部记录<u-icon name="arrow-right"></u-icon>
  171. </view>
  172. </view>
  173. <view class="records">
  174. <view class="records-title">
  175. 洪湖华电光伏线路
  176. </view>
  177. <view class="records-infos">
  178. <view class="item">
  179. <view class="item-title">
  180. 借用数量:
  181. </view>
  182. <view class="item-value">
  183. 4
  184. </view>
  185. </view>
  186. <view class="item">
  187. <view class="item-title">
  188. 借出时间:
  189. </view>
  190. <view class="item-value">
  191. 2023.2.13
  192. </view>
  193. </view>
  194. <view class="item">
  195. <view class="item-title">
  196. 借用人:
  197. </view>
  198. <view class="item-value">
  199. 丁文
  200. </view>
  201. </view>
  202. <view class="item">
  203. <view class="item-title">
  204. 归还时间:
  205. </view>
  206. <view class="item-value highlight">
  207. 未归还
  208. </view>
  209. </view>
  210. </view>
  211. </view>
  212. <view class="records">
  213. <view class="records-title">
  214. 仙桃华润恒升线路
  215. </view>
  216. <view class="records-infos">
  217. <view class="item">
  218. <view class="item-title">
  219. 借用数量:
  220. </view>
  221. <view class="item-value">
  222. 4
  223. </view>
  224. </view>
  225. <view class="item">
  226. <view class="item-title">
  227. 借出时间:
  228. </view>
  229. <view class="item-value">
  230. 2023.2.13
  231. </view>
  232. </view>
  233. <view class="item">
  234. <view class="item-title">
  235. 借用人:
  236. </view>
  237. <view class="item-value">
  238. 丁文
  239. </view>
  240. </view>
  241. <view class="item">
  242. <view class="item-title">
  243. 归还时间:
  244. </view>
  245. <view class="item-value">
  246. 2023.4.1
  247. </view>
  248. </view>
  249. </view>
  250. </view>
  251. </view>
  252. </view>
  253. </view>
  254. </view>
  255. </template>
  256. <script>
  257. import * as API from '@/apis/pagejs/index.js'
  258. export default {
  259. data() {
  260. return {
  261. info:{},
  262. description: '下次巡检时间:2023/03/30',
  263. list: [{
  264. name: '设备信息'
  265. }, {
  266. name: '设备位置'
  267. }
  268. // , {
  269. // name: '巡检记录',
  270. // },{
  271. // name:'出入库记录'
  272. // },
  273. ],
  274. current: 0,
  275. title:""
  276. }
  277. },
  278. methods: {
  279. onLoad(op){
  280. this.name=op.name
  281. this.getInfo()
  282. },
  283. getInfo(){
  284. uni.showLoading({
  285. title: "加载中",
  286. mask: true,
  287. })
  288. API.deviceDetailsByName({
  289. name:this.name
  290. }).then((res) => {
  291. uni.hideLoading();
  292. }).catch(error => {
  293. uni.showToast({
  294. title: error,
  295. icon: "none"
  296. })
  297. })
  298. },
  299. change(index) {
  300. this.current = index;
  301. }
  302. }
  303. }
  304. </script>
  305. <style lang="scss" scoped>
  306. page{
  307. padding-bottom:100px;
  308. }
  309. /deep/.u-line-1{
  310. overflow: inherit;
  311. }
  312. // 图片
  313. .picture{
  314. width: 100%;
  315. height: 400rpx;
  316. overflow: hidden;
  317. position: relative;
  318. img{
  319. width: 100%;
  320. height: 100%;
  321. }
  322. .amount{
  323. width: 108rpx;
  324. height: 48rpx;
  325. line-height: 48rpx;
  326. border-radius: 4px;
  327. background-color: rgba(0, 0, 0, 1);
  328. color: rgba(255, 255, 255, 1);
  329. font-size: 28rpx;
  330. text-align: center;
  331. font-family: Arial;
  332. position: absolute;
  333. bottom: 48rpx;
  334. right: 32rpx;
  335. }
  336. }
  337. // 信息
  338. .main{
  339. border-radius: 16px 16px 0px 0px;
  340. background-color: #ffffff;
  341. padding-top: 24rpx;
  342. margin-top:-24rpx;
  343. z-index: 999;
  344. position: relative;
  345. .title{
  346. color: rgba(51, 51, 51, 1);
  347. font-size: 36rpx;
  348. margin-bottom: 24rpx;
  349. padding:0 32rpx;
  350. }
  351. // 标签
  352. .tabs{
  353. position: sticky;
  354. top: 0;
  355. z-index: 9999;
  356. /deep/.u-tab-bar{
  357. background-color: #2A8EFB !important;
  358. bottom:-8rpx;
  359. }
  360. }
  361. .content{
  362. border-top: 1px solid #B7BDBF;
  363. .infos{
  364. padding: 32rpx;
  365. }
  366. .name{
  367. font-size: 32rpx;
  368. margin-bottom: 16rpx;
  369. display: flex;
  370. align-items: center;
  371. color: rgba(51, 51, 51, 1);
  372. .icon{
  373. width: 32rpx;
  374. height: 32rpx;
  375. margin-right: 8rpx;
  376. img{
  377. width: 100%;
  378. height: 100%;
  379. }
  380. }
  381. .text{
  382. line-height: 50rpx;
  383. }
  384. }
  385. .all{
  386. margin-left: auto;
  387. color: rgba(119, 119, 119, 1);
  388. font-size: 24rpx;
  389. }
  390. // 提示
  391. .hint{
  392. /deep/.u-alert-desc{
  393. color: rgba(255, 121, 0, 1);
  394. font-size: 28rpx
  395. }
  396. }
  397. .details{
  398. border-radius: 8px;
  399. background-color: rgba(245, 246, 249, 1);
  400. padding: 24rpx 24rpx 8rpx 24rpx;
  401. display: flex;
  402. justify-content: space-between;
  403. flex-wrap: wrap;
  404. .item{
  405. display: flex;
  406. margin-bottom: 16rpx;
  407. font-size: 24rpx;
  408. width: 45%;
  409. .item-title{
  410. width: 96rpx;
  411. color: rgba(119, 119, 119, 1);
  412. }
  413. @media screen and (max-width: 375px) {
  414. .item-title{
  415. width: 120rpx;
  416. }
  417. }
  418. @media screen and (max-width: 300px) {
  419. .item-title{
  420. width: 130rpx;
  421. }
  422. }
  423. .item-value{
  424. flex: 1;
  425. color: rgba(51, 51, 51, 1);
  426. margin-left: 16rpx;
  427. white-space: nowrap;
  428. overflow: hidden;
  429. text-overflow: ellipsis;
  430. }
  431. }
  432. .location{
  433. color: rgba(51, 51, 51, 1);
  434. padding-bottom: 8rpx;
  435. }
  436. }
  437. }
  438. .inspection-contents{
  439. border-radius: 8px;
  440. background-color: rgba(245, 246, 249, 1);
  441. padding: 24rpx ;
  442. margin-top: 16rpx;
  443. .inspection-title{
  444. display: flex;
  445. justify-content: space-between;
  446. align-items: center;
  447. font-weight: bold;
  448. color: rgba(51, 51, 51, 1);
  449. .state{
  450. width: 80rpx;
  451. height: 48rpx;
  452. line-height: 48rpx;
  453. border-radius: 4px;
  454. background-color: rgba(255, 255, 255, 1);
  455. color: rgba(0, 185, 98, 1);
  456. font-size: 24rpx;
  457. text-align: center;
  458. font-family: Microsoft Yahei;
  459. border: 1px solid rgba(141, 217, 181, 1);
  460. }
  461. }
  462. .inspection-infos{
  463. display: flex;
  464. justify-content: space-between;
  465. align-items: center;
  466. font-size: 24rpx;
  467. margin-top: 8rpx;
  468. line-height: 36rpx;
  469. .inspection-personnel{
  470. display: flex;
  471. align-items: center;
  472. color: rgba(119, 119, 119, 1);
  473. };
  474. .date{
  475. color: rgba(119, 119, 119, 1);
  476. }
  477. }
  478. }
  479. // 出入库记录
  480. .records{
  481. border-radius: 8px;
  482. background-color: rgba(245, 246, 249, 1);
  483. padding: 24rpx 24rpx 8rpx 24rpx ;
  484. margin-top: 16rpx;
  485. .records-title{
  486. font-weight: bold;
  487. color: #333333;
  488. }
  489. .records-infos{
  490. display: flex;
  491. flex-wrap: wrap;
  492. margin-top: 16rpx;
  493. .item{
  494. font-size: 24rpx;
  495. width: 300rpx;
  496. display: flex;
  497. margin-bottom: 16rpx;
  498. color: rgba(119, 119, 119, 1);
  499. }
  500. }
  501. }
  502. }
  503. .highlight{
  504. color:#E60012
  505. }
  506. </style>