123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330 |
- <template>
- <view class="">
- <view class="navbar">
- <view class="back">
- <text class="iconfont icon-fanhui " @click="backLast()"></text>
- </view>
- <text>文件详情</text>
- </view>
-
- <view class="upload-home">
- <view class="imgList">
- <view class="img-title">文件预览</view>
- <view class="img-box">
- <view class="htz-image-upload-list">
- <view class="htz-image-upload-Item" v-for="(item,index) in fileDetail.resource" :key="index" @click="enlargeImg(item)" v-if="fileDetail.type==1">
- <image class="img" :src="item" ></image>
- </view>
- <view class="htz-text" v-if="fileDetail.type==0" v-html="containt">
- {{containt}}
- </view>
- </view>
- <!-- -->
- </view>
- <view class="frame" v-show="isShow" @click="isShow=false">
- <view class="border" >
- <image :src="bigImg" mode="aspectFit" :lazy-load="true"></image>
- </view>
-
- </view>
- </view>
- <view class="table">
- <view class="title">文件信息</view>
- <view class="text-box">
- <text class="input-key">文件名称:</text><text class="input-val">{{fileDetail.name}}</text>
- </view>
- <view class="text-box">
- <text class="input-key">上传时间:</text><text class="input-val">{{fileDetail.updated_at}}</text>
- </view>
- </view>
- </view>
- </view>
- </template>
- <script>
- var app = getApp()
- import navBar from '../../components/navBar/navbar.vue';
- export default {
- components:{
- navBar
- },
- data() {
- return {
- fileDetail: {
- updated_at: "",
- status_text: "",
- user: {
- name: ''
- },
- name: ""
- },
- isShow: false,
- bigImg: "",
- id: "",
- containt:"<div><h1>123</h1></div>"
- }
- },
-
- onLoad(options) {
- uni.showLoading()
- let id = options.id
- this.id = options.id
- app.request('/organization-activity-logs/' + id,'get').then(res => {
- this.fileDetail = res.data.data
- this.containt=res.data.data.body
- uni.hideLoading()
- console.log(res.data.data, '------------------列表详情')
- })
- },
- methods: {
- backLast:function(){
- console.log(this.url)
- uni.navigateBack({
-
- })
- },
- enlargeImg: function(e) {
- this.bigImg = e
-
- this.isShow = true
- },
-
- }
- }
- </script>
- <style lang="scss">
- page {
- background-color: #EFF1F6;
- }
- .navbar {
- font-size: 32upx;
- height: 100upx;
- line-height: 100upx;
- color: #888888;
- position: relative;
- position: fixed;
- top: 0;
- z-index: 9999999;
- width: 100%;
- background-color: #FFFFFF;
- text-align: center;
- border-bottom: solid 2upx #EFF1F6;
-
- .back {
- height: 100upx;
- width: 100upx;
- text-align: center;
- position: absolute;
- float: left;
- left: 0upx;
- font-size: 32upx;
- }
- }
- uni-page-body {
- height: 100%;
- }
- .htz-image-upload-list {
- display: flex;
- flex-wrap: wrap;
- justify-content: start;
- }
- .htz-image-upload-Item {
- // width: 200rpx;
- height: 200rpx;
- margin: 13rpx;
- border-radius: 10rpx;
- line-height: 200rpx;
- flex: 0 0 30%;
- position: relative;
- }
- .htz-text{
- height: 100%;
- border-radius: 10rpx;
- flex: 0 0 30%;
- }
- .htz-image-upload-Item:first-child {
- margin-left: 5upx !important;
- }
- .htz-image-upload-Item:nth-child(4n) {
- margin-left: 5upx !important;
- }
- .htz-image-upload-Item:nth-child(3n) {
- margin-right: 5upx !important;
- }
- .htz-image-upload-Item image {
- width: 100%;
- height: 100%;
- border-radius: 10rpx;
- border: 1px solid #FF0000;
- }
- .upload-home {
- background-color: #EFF1F6;
- width: 100%;
- height: 100%;
- padding-top: 100upx;
- .table {
- background-color: #FFFFFF;
- font-size: 28upx;
- margin-top: 30upx;
- padding: 30upx;
- .title {
- color: #666;
- font-size: 30upx;
- display: block;
- padding-bottom: 30upx;
- border-bottom: 1px solid #EFF1F6;
- }
- .text-box {
- margin-top: 20upx;
- .input-key {
- display: inline-block;
- height: 80upx;
- line-height: 80upx;
- width: 160upx;
- vertical-align: top;
- color: #555;
- font-size: 32upx;
- }
- .input-val {
- display: inline-block;
- height: 80upx;
- line-height: 80upx;
- vertical-align: top;
- width: calc(100% - 160upx);
- text-align: right;
- color: #333;
- font-size: 32upx;
- }
- }
- }
- .imgList {
- background-color: #fff;
- padding: 30upx;
- .remark {
- font-size: 26upx;
- padding-top: 20upx;
- color: #555;
- }
- .img-title {
- color: #666;
- font-size: 30upx;
- display: block;
- position: relative;
- .down-tmp {
- color: red;
- position: absolute;
- right: 0;
- }
- }
- .img-box {
- margin-top: 20upx;
- background-color: #F3F3F3;
- border-radius: 10upx;
- padding: 15upx;
- .list-img {}
- }
- }
- .htz-image-upload-list {
- display: flex;
- flex-wrap: wrap;
- }
- .htz-image-upload-Item-add {
- font-size: 105rpx;
- text-align: center;
- border: 1px dashed #d9d9d9;
- color: #d9d9d9;
- }
- .htz-image-upload-Item-del {
- background-color: #f5222d;
- font-size: 24rpx;
- position: absolute;
- width: 35rpx;
- height: 35rpx;
- line-height: 35rpx;
- text-align: center;
- top: 0;
- right: 0;
- z-index: 100;
- color: #fff;
- }
- .tips {
- margin: 90upx auto 0;
- border: 1px dashed red;
- padding: 20upx;
- width: 85%;
- border-radius: 15upx;
- font-size: 28upx;
- color: #555;
- }
- }
- .submit {
- position: fixed;
- height: 80upx;
- color: #FFFFFF;
- text-align: center;
- line-height: 80upx;
- width: 80%;
- bottom: 20upx;
- left: 10%;
- font-size: 32upx;
- border-radius: 10upx;
- background-color: #f5222d;
- }
- .frame {
- position: fixed;
- top: 0;
- left: 0;
- height: 100%;
- background-color: rgba($color: #000000, $alpha: 0.7);
- width: 100%;
- .border {
- width: 90%;
- height: 70%;
- margin: 0 auto;
- margin-top: 100upx;
- image {
- width: 100%;
- height: 100%;
- }
- }
- }
- </style>
|