From 04bf59bbc3fad774c57a2ee5ebf07db24b476bf2 Mon Sep 17 00:00:00 2001
From: liukangdong <898885815@qq.com>
Date: 星期二, 17 十二月 2024 17:43:14 +0800
Subject: [PATCH] Merge branch 'master' of http://139.186.142.91:10010/r/productDev/dmvisit
---
h5/pages/staff/task/vDangetAppr.vue | 274 ++++++++++++++++++++++++++++++++++++++++--------------
1 files changed, 200 insertions(+), 74 deletions(-)
diff --git a/h5/pages/staff/task/vDangetAppr.vue b/h5/pages/staff/task/vDangetAppr.vue
index 3a13b23..3138b6b 100644
--- a/h5/pages/staff/task/vDangetAppr.vue
+++ b/h5/pages/staff/task/vDangetAppr.vue
@@ -9,10 +9,14 @@
class="status_img"></image>
<view>{{ info.content }}</view>
<view class="file_list">
- <view class="img_wrap" v-for="item in info.submitFileList" :key="item.id">
+ <view class="img_wrap" v-for="item,i in info.submitFileList" :key="item.id">
<image v-if="item.type == 0" :src="item.fileurlFull" @click="priviewImage(item.fileurlFull)" mode="widthFix"
class="img" />
- <video v-if="item.type == 1" :src="item.fileurlFull" class="video" controls />
+ <view v-if="item.type == 1" @click="videoClick(item, i)" class="video_wrap">
+ <video :id="'id' + i" :show-center-play-btn="false" :src="item.fileurlFull" muted class="video"
+ :controls="false" />
+ <image src="@/static/play.png" class="play" mode=""></image>
+ </view>
</view>
</view>
<view class="text_wrap">
@@ -29,6 +33,7 @@
<!-- -->
<view class="emyty"></view>
<view v-if="info.status == 1 || info.status == 2" class="module_list">
+ <view class="title">澶勭悊缁撴灉</view>
<view class="item">
<view class="label">澶勭悊缁撴灉</view>
<view class="value primaryColor" :class="{ red: info.status == 2 }">{{ statusMap[info.status] }}</view>
@@ -37,8 +42,9 @@
<view class="label">{{info.status == '1' ? '鏁存敼鍓�' : '瑙嗛/鍥剧墖'}}</view>
<view class="value">
<view class="adduser_list_item_ipt1_upload" v-for="(item, i) in info.dealBeforeFileList" :key="i">
- <image v-if="item.type == 0" :src="item.fileurlFull" mode="widthFix"></image>
- <video v-if="item.type == 1" :src="item.fileurlFull"></video>
+ <image v-if="item.type == 0" @click="priviewImage(item.fileurlFull)" :src="item.fileurlFull"
+ mode="widthFix"></image>
+ <video v-if="item.type == 1" @click="videoClick(item, i)" :src="item.fileurlFull" :controls="false"></video>
</view>
</view>
</view>
@@ -46,13 +52,14 @@
<view class="label">鏁存敼鍚�</view>
<view class="value">
<view class="adduser_list_item_ipt1_upload" v-for="(item, i) in info.dealAfterFileList" :key="i">
- <image v-if="item.type == 0" :src="item.fileurlFull" mode="widthFix"></image>
- <video v-if="item.type == 1" :src="item.fileurlFull"></video>
+ <image v-if="item.type == 0" @click="priviewImage(item.fileurlFull)" :src="item.fileurlFull"
+ mode="widthFix"></image>
+ <video v-if="item.type == 1" @click="videoClick(item, i)" :src="item.fileurlFull" :controls="false"></video>
</view>
</view>
</view>
<view class="item">
- <view class="label">鏁存敼璇存槑</view>
+ <view class="label">{{info.status == '1' ? '鏁存敼璇存槑' : '閫�鍥炶鏄�'}}</view>
<view class="value">{{ info.checkInfo }}</view>
</view>
</view>
@@ -67,7 +74,7 @@
v-if="info.status == 1 || index < flowList.length - 1" />
<image src="@/static/staff/liucheng_fail@2x.png" class="status"
v-if="info.status == 2 && index == flowList.length - 1" />
- <image v-if="item.avatar != null && item.avatar != ''" :src="item.avatar" class="img" alt="" />
+ <image v-if="item.avatar != null && item.avatar != ''" :src="item.avatar" class="img" alt="" />
<!-- <image v-else src="@/static/default_avatar.png" class="img" mode=""></image> -->
<span v-if="item.avatar == null || item.avatar == ''"
class="img_name">{{ item.createUserName && item.createUserName.slice(0, 1) }}</span>
@@ -75,7 +82,7 @@
<view class="content">
<view class="head">
<view class="event">{{ item.title }}</view>
- <view class="time">{{ item.createDate }}</view>
+ <view class="time" v-if="item.createDate">{{ item.createDate.slice(0,16) }}</view>
</view>
<view class="line">
<view class="company">
@@ -95,10 +102,12 @@
</view>
</view>
<view class="emyty"></view>
- <view class="main_footer">
- <view v-if="info.status==0&& info.checkUserId == userInfo.memberId" class="btn" @click="handleBack">閫�鍥�</view>
- <view v-if="info.status==0 && info.checkUserId == userInfo.memberId" class="btn transfer" @click="handleTransfer">杞氦</view>
- <view v-if="info.status==0&& info.checkUserId == userInfo.memberId" class="btn handle" @click="handleOpen">澶勭悊</view>
+ <view class="main_footer" v-if="info.status==0&& info.checkUserId == userInfo.memberId">
+ <view v-if="info.status==0&& info.checkUserId == userInfo.memberId" class="btn" @click="handleBack">閫�鍥�</view>
+ <view v-if="info.status==0&& info.checkUserId == userInfo.memberId" class="btn transfer" @click="handleTransfer">
+ 杞氦</view>
+ <view v-if="info.status==0&& info.checkUserId == userInfo.memberId" class="btn handle" @click="handleOpen">澶勭悊
+ </view>
</view>
<!-- 閫�鍥� -->
@@ -126,8 +135,9 @@
<view class="adduser_list_item_ipt1_upload" v-for="(item, i) in dealBeforeFileList" :key="i">
<u-icon class="close" size="20" name="close-circle-fill" color="red"
@click="fileDel('dealBeforeFileList', i)"></u-icon>
- <image v-if="item.type == 0" :src="item.fileurlFull" mode="widthFix"></image>
- <video v-if="item.type == 1" :src="item.fileurlFull"></video>
+ <image v-if="item.type == 0" @click="priviewImage(item.fileurlFull)" :src="item.fileurlFull"
+ mode="widthFix"></image>
+ <video v-if="item.type == 1" @click="videoClick(item, i)" :src="item.fileurlFull" :controls="false"></video>
</view>
</view>
<view class="label">閫�鍥炶鏄�</view>
@@ -167,7 +177,7 @@
<u-icon class="close" size="20" name="close-circle-fill" color="red"
@click="fileDel('dealBeforeFileList', i)"></u-icon>
<image v-if="item.type == 0" :src="item.fileurlFull" mode="widthFix"></image>
- <video v-if="item.type == 1" :src="item.fileurlFull"></video>
+ <video v-if="item.type == 1" :src="item.fileurlFull" :controls="false"></video>
</view>
</view>
<view class="label">
@@ -183,7 +193,7 @@
<u-icon class="close" size="20" name="close-circle-fill" color="red"
@click="fileDel('dealAfterFileList', i)"></u-icon>
<image v-if="item.type == 0" :src="item.fileurlFull" mode="widthFix"></image>
- <video v-if="item.type == 1" :src="item.fileurlFull"></video>
+ <video v-if="item.type == 1" :src="item.fileurlFull" :controls="false"></video>
</view>
</view>
<view class="label">鏁存敼璇存槑</view>
@@ -225,8 +235,8 @@
<view class="member_list">
<view class="mt24 placeholder6">鍏眥{ memberList.length }}鏉℃暟鎹�</view>
<view v-for="item in memberList" :key="item.id" class="line">
- <image :src="item.faceImgFull ? item.faceImgFull : require('@/static/meeting/common/default_user@2x.png')"
- class="avatar" mode=""></image>
+ <image v-if="item.faceImgFull" :src="item.faceImgFull" class="avatar"></image>
+ <span v-else class="img_name">{{item.name && item.name.slice(0,1)}}</span>
<view class="content">
<view class="info">
<text class="name">{{ item.name }}</text>
@@ -234,10 +244,9 @@
</view>
<view class="depart">{{ item.companyName }}</view>
</view>
- <image @click="changeMem(item)" v-if="transferParam.id == item.id"
- src="@/static/checkbox_sel@2x.png" mode="widthFix" class="checked"></image>
- <image @click="changeMem(item)" v-else src="@/static/video@2x.png" mode="widthFix"
- class="checked"></image>
+ <image @click="changeMem(item)" v-if="transferParam.id == item.id" src="@/static/checkbox_sel@2x.png"
+ mode="widthFix" class="checked"></image>
+ <image @click="changeMem(item)" v-else src="@/static/video@2x.png" mode="widthFix" class="checked"></image>
<text></text>
</view>
<view class="empty"></view>
@@ -249,11 +258,19 @@
</view>
</u-popup>
<!-- 閫�鍥炴椂闂� -->
- <u-datetime-picker :show="isShowBackDate" @confirm="confirmBackDate" @cancel="isShowBackDate = false"
+ <u-datetime-picker :show="isShowBackDate" :minDate="new Date().getTime()" :closeOnClickOverlay="false"
+ @confirm="confirmBackDate" @close="isShowBackDate = false" @cancel="isShowBackDate = false"
mode="datetime"></u-datetime-picker>
<u-datetime-picker :minDate="new Date().getTime()" :show="isShowHandleDate" @confirm="confirmHandleDate"
@cancel="isShowHandleDate = false" mode="datetime"></u-datetime-picker>
+ <!-- -->
+
+ <view v-if="videoPlay" class="video_app" >
+ <video controls autoplay muted x5-video-player-type="h5"
+ x5-video-player-fullscreen="true" id="myvideo" :src="videoUrl" @fullscreenchange="screenChange"></video>
+ <view class="bg" @click="closeVideo"></view>
+ </view>
</view>
</template>
@@ -272,7 +289,7 @@
return {
isShowBack: false,
param: {},
- info: {},
+ info: {},
userInfo: this.$store.state.userInfo,
flowList: [],
@@ -324,7 +341,11 @@
page: 1,
capacity: 50
},
- memberList: []
+ memberList: [],
+
+ videoPlay: false,
+ videoContext: null,
+ videoUrl: ''
};
},
onLoad(op) {
@@ -338,16 +359,38 @@
urls: [url]
});
},
+ screenChange(e) {
+ let fullScreen = e.detail.fullScreen; // 鍊紅rue涓鸿繘鍏ュ叏灞忥紝false涓洪��鍑哄叏灞�
+ if (!fullScreen) {
+ //閫�鍑哄叏灞�
+ this.videoPlay = false; // 闅愯棌鎾斁鐩掑瓙
+ }
+ },
+ closeVideo() {
+ this.videoPlay = false
+ this.videoContext = null
+ },
+ videoClick(item, i) {
+ this.videoPlay = true;
+ this.videoContext = uni.createVideoContext("myvideo", this); // this杩欎釜鏄疄渚嬪璞� 蹇呬紶
+ this.videoUrl = item.fileurlFull;
+ this.videoContext.requestFullScreen();
+ this.$nextTick(() => {
+ this.videoContext.play();
+ })
+
+ },
handleOpen() {
this.isShowHandle = true;
- const submitFileList = this.info.submitFileList || []
+ const submitFileList = this.info.submitFileList || []
+ this.dealBeforeFileList = [...submitFileList]
this.submitFileList = [...submitFileList];
this.$set(this.handleParam, 'dealTime', dayjs().format('YYYY-MM-DD HH:mm:ss'));
},
handleBack() {
- this.isShowBack = true;
+ this.isShowBack = true;
// const submitFileList = this.info.submitFileList || []
- // this.submitFileList = [...submitFileList];
+ // this.submitFileList = [...submitFileList];
this.dealBeforeFileList = []
this.$set(this.backParam, 'dealTime', dayjs().format('YYYY-MM-DD HH:mm:ss'));
},
@@ -434,10 +477,8 @@
},
getMemList() {
findHiddenAreaMemberList({
- model: {
- ...this.transferModel,
- id: this.info.areaId
- },
+ ...this.transferModel,
+ id: this.info.areaId,
...this.pagination
}).then(res => {
this.memberList = res.data || [];
@@ -481,7 +522,7 @@
this.showUploadBe = false;
let token = uni.getStorageSync('token') || '';
uni.chooseImage({
- count: 4,
+ count: 9,
success: chooseImageRes => {
uni.showLoading({
title: '涓婁紶涓�',
@@ -572,7 +613,7 @@
this.showUploadAf = false;
let token = uni.getStorageSync('token') || '';
uni.chooseImage({
- count: 4,
+ count: 9,
success: chooseImageRes => {
uni.showLoading({
title: '涓婁紶涓�',
@@ -660,7 +701,7 @@
this.showUpload = false;
let token = uni.getStorageSync('token') || '';
uni.chooseImage({
- count: 4,
+ count: 9,
success: chooseImageRes => {
uni.showLoading({
title: '涓婁紶涓�',
@@ -747,25 +788,29 @@
}
};
</script>
-<style>
+
+<style lang="scss">
page {
background-color: #f7f7f7;
+
+ ::v-deep .u-popup__content {
+ border-top: 1rpx solid #cccccc;
+ }
}
-</style>
-<style lang="scss">
+
.main_app {
background-color: #fff;
padding-bottom: 0;
- .flow_wrap {
- padding: 30rpx 0;
+ .flow_title {
+ font-weight: 600;
+ font-size: 32rpx;
+ color: #222222;
+ margin-bottom: 24rpx;
+ }
- .flow_title {
- font-weight: 600;
- font-size: 32rpx;
- color: #222222;
- margin-bottom: 24rpx;
- }
+ .flow_wrap {
+ padding: 30rpx 0 90rpx;
.list {
.item {
@@ -802,6 +847,7 @@
position: absolute;
right: 0;
bottom: 0;
+ z-index: 999;
}
}
@@ -832,17 +878,19 @@
}
}
- .line{
- .company{
- font-size: 26rpx;
- color: #777777;
- }
- .status-green{
- color: $uni-color-primary;
- }
- .status-red{
- color: red;
- }
+ .line {
+ .company {
+ font-size: 26rpx;
+ color: #777777;
+ }
+
+ .status-green {
+ color: $uni-color-primary;
+ }
+
+ .status-red {
+ color: red;
+ }
}
.remark {
@@ -890,9 +938,9 @@
}
.adduser_list_item_ipt1_upload {
- width: 120rpx;
- height: 120rpx;
- margin-right: 24rpx;
+ width: 156rpx;
+ height: 156rpx;
+ margin-right: 20rpx;
border: 2rpx solid #e5e5e5;
background: #f7f7f7;
color: #666666;
@@ -902,6 +950,10 @@
align-items: center;
justify-content: center;
position: relative;
+
+ &:nth-of-type(4n) {
+ margin-right: 0;
+ }
.close {
position: absolute;
@@ -917,11 +969,18 @@
video {
width: 100%;
- max-height: 120rpx;
+ max-height: 156rpx;
}
}
.module_list {
+ .title {
+ font-weight: 600;
+ font-size: 32rpx;
+ color: #222222;
+ padding-top: 28rpx;
+ }
+
.item {
padding: 30rpx 0;
border-bottom: 1rpx solid #e5e5e5;
@@ -985,23 +1044,45 @@
.file_list {
display: flex;
margin-bottom: 20rpx;
- overflow-x: auto;
+ flex-wrap: wrap;
.img_wrap {
margin-top: 24rpx;
- min-width: 160rpx;
- height: 160rpx;
+ width: 156rpx;
+ height: 156rpx;
border: 2rpx solid #e5e5e5;
background: #f7f7f7;
color: #666666;
font-size: 22rpx;
display: flex;
+ border-radius: 4rpx;
flex-direction: column;
align-items: center;
justify-content: center;
position: relative;
- margin-right: 16rpx;
+ margin-right: 20rpx;
flex-shrink: 0;
+
+ &:nth-of-type(4n) {
+ margin-right: 0;
+ }
+ }
+
+ .video_wrap {
+ position: relative;
+ border: 1px solid;
+ width: 156rpx;
+ height: 156rpx;
+ border-radius: 4rpx;
+
+ .play {
+ width: 60rpx;
+ height: 60rpx;
+ position: absolute;
+ top: 50%;
+ left: 50%;
+ transform: translate(-50%, -50%);
+ }
}
.img {
@@ -1010,7 +1091,8 @@
}
.video {
- height: 160rpx;
+ width: 100%;
+ max-height: 100%;
}
}
@@ -1021,9 +1103,13 @@
margin-top: 20rpx;
.line {
- margin-bottom: 12rpx;
+ margin-bottom: 18rpx;
display: flex;
font-size: 24rpx;
+
+ &:nth-last-child(1) {
+ margin-bottom: 0;
+ }
.label {
color: #999999;
@@ -1040,7 +1126,7 @@
line-height: 60rpx;
padding: 0 32rpx;
border-radius: 0rpx 0rpx 0rpx 30rpx;
- background-color: #e9edff;
+ background: rgba(39, 155, 170, 0.12);
color: $uni-color-primary;
}
@@ -1056,6 +1142,7 @@
position: fixed;
bottom: 0;
width: 100%;
+ z-index: 9999;
left: 0;
padding: 30rpx 10rpx 60rpx;
display: flex;
@@ -1154,10 +1241,10 @@
}
.adduser_list_item_ipt1_upload {
- margin-top: 24rpx;
- width: 120rpx;
- height: 120rpx;
- margin-right: 24rpx;
+ margin-top: 20rpx;
+ width: 156rpx;
+ height: 156rpx;
+ margin-right: 20rpx;
border: 2rpx solid #e5e5e5;
background: #f7f7f7;
color: #666666;
@@ -1167,6 +1254,10 @@
align-items: center;
justify-content: center;
position: relative;
+
+ &:nth-of-type(4n) {
+ margin-right: 0;
+ }
.close {
position: absolute;
@@ -1182,7 +1273,7 @@
video {
width: 100%;
- max-height: 120rpx;
+ height: 100%;
}
}
}
@@ -1223,6 +1314,19 @@
border-radius: 50%;
overflow: hidden;
margin-right: 20rpx;
+ }
+
+ .img_name {
+ width: 64rpx;
+ height: 64rpx;
+ line-height: 64rpx;
+ text-align: center;
+ border-radius: 50%;
+ overflow: hidden;
+ margin-right: 20rpx;
+ background: $uni-color-primary;
+ color: #fff;
+ border: 1rpx solid $uni-color-primary;
}
.content {
@@ -1280,6 +1384,28 @@
}
}
+ .video_app {
+ overflow: hidden;
+ position: fixed;
+ left: 0;
+ top: 0;
+ width: 100vw;
+ height: 100vh;
+ display: flex;
+ align-items: center;
+ .bg{
+ background-color: rgba(0,0,0,.6);
+ position: absolute;
+ width: 100%;
+ height: 100%;
+ z-index: -1;
+ }
+ video {
+ width: 100%;
+ height: 42vh;
+ }
+ }
+
.Transfer_footer {
display: flex;
--
Gitblit v1.9.3