123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534 |
- <template>
- <view>
- <u-navbar :title="info.title"></u-navbar>
- <!-- 图片 -->
- <view class="picture">
- <img :src="info.imgUrl" alt="">
- <view class="amount" v-if="false">
- <text>1</text>/
- <text>5</text>
- </view>
- </view>
- <!-- 信息 -->
- <view class="main">
- <view class="title">
- {{info.title}}
- </view>
- <!-- 标签 -->
- <view class="tabs " v-if="false">
- <u-tabs bar-width="120" inactive-color="#999999" active-color="#000000" :list="list" :is-scroll="false" :current="current" @change="change"></u-tabs>
- </view>
- <view class="content">
- <!-- 设备信息 -->
- <view class="infos">
- <view class="name">
- <view class="icon"><img src="@/assets/img/riLine-robot-line@1x.png" alt=""></view>
- <view class="text">
- 设备信息
- </view>
- </view>
-
- <view class="details">
- <view class="item">
- <view class="item-title">
- 规格
- </view>
- <view class="item-value">
- {{info.specifications}}
- </view>
- </view>
-
-
- <view class="item" >
- <view class="item-title">
- 库存数量
- </view>
- <view class="item-value">
- {{count}}
- </view>
- </view>
-
- <view class="item" >
- <view class="item-title">
- 单位
- </view>
- <view class="item-value">
- {{info.unit}}
- </view>
- </view>
- <view class="item" >
- <view class="item-title">
- 制造厂家
- </view>
- <view class="item-value">
- {{info.manufactor}}
- </view>
- </view>
- <!-- <view class="item" >
- <view class="item-title">
- 单价
- </view>
- <view class="item-value">
- {{info.unitPrice?info.unitPrice+'元':'无'}}
- </view>
- </view> -->
- <view class="item " style="width: 100%;" v-if="false">
- <view class="item-title">
- 购置时间
- </view>
- <view class="item-value">
- {{info.buyTime}}
- </view>
- </view>
- <view class="item" style="width: 100%;" v-if="false" >
- <view class="item-title">
- 巡检时间
- </view>
- <view class="item-value">
- {{info.experimentLastTime}}
- </view>
- </view>
-
- <view class="item" v-if="false">
- <view class="item-title">
- 试验周期
- </view>
- <view class="item-value">
- {{info.experimentPeriod?info.experimentPeriod+'天':''}}
- </view>
- </view>
-
- </view>
-
- </view>
- </view>
- <!-- 存放地点 -->
- <view class="content">
- <view class="infos">
- <view class="name">
- <view class="icon"><img src="@/assets/img/riLine-robot-line@1x.png" alt=""></view>
- <view class="text">
- 存放地点
- </view>
- </view>
-
- <view class="details">
- <view class="location">
- {{info.addressId}}
- </view>
- </view>
-
- </view>
- </view>
- <!-- 巡检记录 -->
- <view class="content" v-if="false">
- <view class="infos">
- <view class="name">
- <view class="icon"><img src="@/assets/img/riLine-device-recover-line@1x.png" alt=""></view>
- <view class="text">
- 巡检记录
- </view>
-
- <view class="all">
- 全部记录<u-icon name="arrow-right"></u-icon>
- </view>
- </view>
- <!-- 提示 -->
- <view class="hint">
- <!-- <u-alert-tips icon="bell-fill" type="warning" :show-icon="true" :title="title" :description="description"></u-alert-tips>-->
- </view>
-
- <view class="inspection-contents">
- <view class="inspection-title">
- <view class="text">
- 巡检内容名称
- </view>
- <view class="state">
- 合格
- </view>
- </view>
- <view class="inspection-infos">
- <view class="inspection-personnel">
- <view class="inspection-name">
- 巡检人:
- </view>
- <view class="value">
- 孙斌
- </view>
- </view>
- <view class="inspection-date">
- 2023/03/15 09:45:21
- </view>
- </view>
-
- </view>
- </view>
- </view>
- <!-- 出入库记录 -->
- <view class="content" v-if="false">
- <view class="infos">
- <view class="name">
- <view class="icon"><img src="@/assets/img/riLine-todo-line@1x.png" alt=""></view>
- <view class="text">
- 出入库记录
- </view>
- <view class="all">
- 全部记录<u-icon name="arrow-right"></u-icon>
- </view>
- </view>
- <view class="records">
- <view class="records-title">
- 洪湖华电光伏线路
- </view>
- <view class="records-infos">
- <view class="item">
- <view class="item-title">
- 借用数量:
- </view>
- <view class="item-value">
- 4
- </view>
- </view>
- <view class="item">
- <view class="item-title">
- 借出时间:
- </view>
- <view class="item-value">
- 2023.2.13
- </view>
- </view>
- <view class="item">
- <view class="item-title">
- 借用人:
- </view>
- <view class="item-value">
- 丁文
- </view>
- </view>
- <view class="item">
- <view class="item-title">
- 归还时间:
- </view>
- <view class="item-value highlight">
- 未归还
- </view>
- </view>
- </view>
- </view>
-
- <view class="records">
- <view class="records-title">
- 仙桃华润恒升线路
- </view>
- <view class="records-infos">
- <view class="item">
- <view class="item-title">
- 借用数量:
- </view>
- <view class="item-value">
- 4
- </view>
- </view>
- <view class="item">
- <view class="item-title">
- 借出时间:
- </view>
- <view class="item-value">
- 2023.2.13
- </view>
- </view>
- <view class="item">
- <view class="item-title">
- 借用人:
- </view>
- <view class="item-value">
- 丁文
- </view>
- </view>
- <view class="item">
- <view class="item-title">
- 归还时间:
- </view>
- <view class="item-value">
- 2023.4.1
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- import * as API from '@/apis/pagejs/index.js'
-
- export default {
- data() {
- return {
- name:"",
- count:"",
- info:{},
- description: '下次巡检时间:2023/03/30',
- list: [{
- name: '设备信息'
- }, {
- name: '设备位置'
- }
- // , {
- // name: '巡检记录',
- // },{
- // name:'出入库记录'
- // },
-
- ],
- current: 0,
- title:""
- }
- },
- methods: {
- onLoad(op){
- this.name=op.name
- this.getInfo()
- },
- getInfo(){
- uni.showLoading({
- title: "加载中",
- mask: true,
- })
- API.deviceDetailsByName({
-
- name:this.name
- }).then((res) => {
- uni.hideLoading();
- this.info=res.data.deviceInfo;
- this.count=res.data.count;
- }).catch(error => {
- uni.showToast({
- title: error,
- icon: "none"
- })
- })
- },
- change(index) {
- this.current = index;
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- page{
- padding-bottom:100px;
- }
- /deep/.u-line-1{
- overflow: inherit;
- }
- // 图片
- .picture{
- width: 100%;
- height: 400rpx;
- overflow: hidden;
- position: relative;
- img{
- width: 100%;
- height: 100%;
- }
- .amount{
- width: 108rpx;
- height: 48rpx;
- line-height: 48rpx;
- border-radius: 4px;
- background-color: rgba(0, 0, 0, 1);
- color: rgba(255, 255, 255, 1);
- font-size: 28rpx;
- text-align: center;
- font-family: Arial;
- position: absolute;
- bottom: 48rpx;
- right: 32rpx;
- }
- }
- // 信息
- .main{
- border-radius: 16px 16px 0px 0px;
- background-color: #ffffff;
- padding-top: 24rpx;
- margin-top:-24rpx;
- // z-index: 999;
- position: relative;
- .title{
- color: rgba(51, 51, 51, 1);
- font-size: 36rpx;
- margin-bottom: 24rpx;
- padding:0 32rpx;
- }
- // 标签
- .tabs{
- position: sticky;
- top: 0;
- z-index: 9999;
- /deep/.u-tab-bar{
- background-color: #2A8EFB !important;
- bottom:-8rpx;
- }
- }
-
-
- .content{
-
- border-top: 1px solid #B7BDBF;
- .infos{
- padding: 32rpx;
- }
- .name{
- font-size: 32rpx;
- margin-bottom: 16rpx;
- display: flex;
- align-items: center;
- color: rgba(51, 51, 51, 1);
- .icon{
- width: 32rpx;
- height: 32rpx;
- margin-right: 8rpx;
- img{
- width: 100%;
- height: 100%;
- }
- }
- .text{
- line-height: 50rpx;
- }
- }
- .all{
- margin-left: auto;
- color: rgba(119, 119, 119, 1);
- font-size: 24rpx;
- }
- // 提示
- .hint{
- /deep/.u-alert-desc{
- color: rgba(255, 121, 0, 1);
- font-size: 28rpx
- }
- }
- .details{
- border-radius: 8px;
- background-color: rgba(245, 246, 249, 1);
- padding: 24rpx 24rpx 8rpx 24rpx;
- display: flex;
- justify-content: space-between;
- flex-wrap: wrap;
-
- .item{
- display: flex;
- margin-bottom: 16rpx;
- font-size: 24rpx;
- width: 45%;
- .item-title{
- width: 96rpx;
- color: rgba(119, 119, 119, 1);
- }
- @media screen and (max-width: 375px) {
- .item-title{
- width: 120rpx;
-
- }
- }
- @media screen and (max-width: 300px) {
- .item-title{
- width: 130rpx;
-
- }
- }
- .item-value{
- flex: 1;
- color: rgba(51, 51, 51, 1);
- margin-left: 16rpx;
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- }
- }
-
- .location{
- color: rgba(51, 51, 51, 1);
- padding-bottom: 8rpx;
- }
- }
- }
-
- .inspection-contents{
- border-radius: 8px;
- background-color: rgba(245, 246, 249, 1);
- padding: 24rpx ;
- margin-top: 16rpx;
- .inspection-title{
- display: flex;
- justify-content: space-between;
- align-items: center;
- font-weight: bold;
- color: rgba(51, 51, 51, 1);
- .state{
- width: 80rpx;
- height: 48rpx;
- line-height: 48rpx;
- border-radius: 4px;
- background-color: rgba(255, 255, 255, 1);
- color: rgba(0, 185, 98, 1);
- font-size: 24rpx;
- text-align: center;
- font-family: Microsoft Yahei;
- border: 1px solid rgba(141, 217, 181, 1);
- }
-
- }
- .inspection-infos{
- display: flex;
- justify-content: space-between;
- align-items: center;
- font-size: 24rpx;
- margin-top: 8rpx;
- line-height: 36rpx;
- .inspection-personnel{
- display: flex;
- align-items: center;
- color: rgba(119, 119, 119, 1);
-
- };
- .date{
- color: rgba(119, 119, 119, 1);
-
- }
- }
-
- }
- // 出入库记录
- .records{
- border-radius: 8px;
- background-color: rgba(245, 246, 249, 1);
- padding: 24rpx 24rpx 8rpx 24rpx ;
- margin-top: 16rpx;
- .records-title{
- font-weight: bold;
- color: #333333;
- }
- .records-infos{
- display: flex;
- flex-wrap: wrap;
- margin-top: 16rpx;
- .item{
- font-size: 24rpx;
- width: 300rpx;
- display: flex;
- margin-bottom: 16rpx;
- color: rgba(119, 119, 119, 1);
- }
- }
- }
- }
- .highlight{
- color:#E60012
- }
- </style>
|