Browse Source

会议室图片

zouling 10 tháng trước cách đây
mục cha
commit
cdc6538f06

+ 2 - 2
config.js

@@ -1,7 +1,7 @@
 // 应用全局配置
 module.exports = {
-  baseUrl: 'https://zxyyq.qs163.cn/prod-api',
-  // baseUrl: 'http://47.99.82.249:5010/prod-api',
+  // baseUrl: 'https://zxyyq.qs163.cn/prod-api',
+  baseUrl: 'http://47.99.82.249:5010/prod-api',
   // baseUrl: 'http://192.168.101.168:8065',
   // baseUrl: 'http://192.168.101.245:8065',
   // baseUrlimg: 'http://114.99.127.243:2001',

+ 2 - 2
manifest.json

@@ -2,8 +2,8 @@
     "name" : "智慧园区",
     "appid" : "__UNI__9ACE566",
     "description" : "",
-    "versionName" : "1.0.2",
-    "versionCode" : 102,
+    "versionName" : "1.0.3",
+    "versionCode" : 103,
     "transformPx" : false,
     "app-plus" : {
         "usingComponents" : true,

+ 2 - 2
pages/order/come.vue

@@ -363,11 +363,11 @@
 			}
 			var str='预约成功'
 			// if(this.inputValue==0){
-			// 	this.$toast('请输入参观人数')
+			// 	this.$toast('请输入来访人数')
 			// 	return
 			// }
 			// if(this.inputValue<0){
-			// 	this.$toast('请输入正确的参观人数')
+			// 	this.$toast('请输入正确的来访人数')
 			// 	return
 			// }
 			if(!this.datainfo.visitNum){

+ 112 - 0
work/components/yuyue/hysbanner.vue

@@ -0,0 +1,112 @@
+<template>
+	<view class="hometop">
+		<swiper class="swiper" circular :indicator-active-color="activecolor" :current="currentidx" :indicator-dots="indicatorDots" :autoplay="autoplay" :interval="interval"
+			:duration="duration">
+			<block v-for="(ite,idx) in bannerlist" :key='idx'>
+				<swiper-item>
+					<image  :src="baseUrl+ite" class="swiperimg" @click.stop="getPreviewImage(idx)"></image>
+				</swiper-item>
+			</block>
+		</swiper>
+		<block v-if="bannerlist.length>1">
+			<image :src="leftimg" class="arrow arrowleft" @click.stop="prev"></image>
+			<image :src="rightimg" class="arrow arrowright" @click.stop="next"></image>
+		</block>
+	</view>
+</template>
+
+<script>
+	import config from '@/config.js';
+	export default{
+		props:{
+			bannerlist:{
+				type: Array,
+				default () {
+					return []
+				}
+			},
+			type:{
+				type: String,
+				default () {
+					return 'zhao'
+				}
+			},
+			currentdate:{
+				type: String,
+				default () {
+					return ''
+				}
+			}
+		},
+		data(){
+			return{
+				leftimg:require('@/work/static/yuy/left.png'),
+				rightimg:require('@/work/static/yuy/right.png'),
+				background: ['color1', 'color2', 'color3'],
+				activecolor:'#ffffff',
+				indicatorDots: true,
+				autoplay: false,
+				interval: 2000,
+				duration: 500,
+				baseUrl:config.baseUrl,
+				currentidx:0,
+			}
+		},
+		methods:{
+			getPreviewImage(idx){
+				var newArr=[];
+				var arr=this.bannerlist
+				arr.forEach(ite=>{
+					var ds=this.baseUrl+ite
+					newArr.push(ds)
+				})
+				uni.previewImage({
+					urls: newArr,
+					current:idx,
+					success: function(data) {
+						
+					},
+					fail: function(err) {
+						
+					}
+				});
+			},
+			prev(){
+				var len=this.bannerlist.length
+				this.currentidx=(this.currentidx-1+len)%len
+			},
+			next(){
+				var len=this.bannerlist.length
+				this.currentidx=(this.currentidx+1)%len
+			}
+		},
+		mounted() {
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+	.hometop{position: relative;}
+	.arrow{width: 30rpx;height: 30rpx;position: absolute;top: 50%;transform: translateY(-50%);
+		&.arrowleft{left: 26rpx;}
+		&.arrowright{right: 26rpx;}
+	}
+	// height: 246rpx;
+	.swiper{height: 322rpx;position: relative;border-radius: 10rpx;overflow: hidden;
+		.swiperimg{width: 100%;height: 100%;border-radius: 10rpx;overflow: hidden;}
+	}
+	.swiper /deep/ .uni-swiper-wrapper .uni-swiper-dot{
+		width:12rpx;height:12rpx;border-radius: 50%;background: rgba(0, 0, 0, 0.5);
+		}
+	.swiper /deep/ .uni-swiper-wrapper .uni-swiper-dot-active{
+		width: 20rpx;height: 12rpx;border-radius: 6rpx;background-color: #ffffff;
+	}
+	// wx
+	.swiper /deep/ .wx-swiper-wrapper .wx-swiper-dot{
+		width:12rpx;height:12rpx;border-radius: 50%;background: rgba(0, 0, 0, 0.5);
+		}
+	.swiper /deep/ .wx-swiper-wrapper .wx-swiper-dot-active{
+		width: 20rpx;height: 12rpx;border-radius: 6rpx;background-color: #ffffff;
+	}
+	.bannerfot{position: absolute;left: 0;right: 0;height: 70rpx;background-color: rgba(0, 0, 0, 0.5);padding: 0 32rpx;bottom: 0;display: flex;align-items: center;justify-content: space-between;}
+</style>

+ 23 - 6
work/pages/yyorder/meetadd.vue

@@ -15,9 +15,15 @@
 							<view class="yttit">选择会议室</view>
 							<view class="mb12" v-for="(ite,idx) in hyslist" :key="ite.conferenceRoomId">
 								<view class="mlists" :class="meetid==ite.conferenceRoomId?'act':''" @click="getMeetId(ite)">
-									<view class="mtit">{{ite.conferenceRoomName}}</view>
-									<view class="mtxt bga" v-if="ite.type=='N'"><text class="cir"></text>当前空闲</view>
-									<view class="mtxt bgb" v-if="ite.type=='Y'"><text class="cir"></text>当前占用</view>
+									<!-- 会议图片 -->
+									<view class="banbox mb12" v-if="ite.conferenceRoomUrl&&meetid==ite.conferenceRoomId" @click.stop="getStop">
+										<hys-banner :bannerlist="ite.conferenceRoomUrl"></hys-banner>
+									</view>
+									<view class="flexc"  >
+										<view class="mtit">{{ite.conferenceRoomName}}</view>
+										<view class="mtxt bga" v-if="ite.type=='N'"><text class="cir"></text>当前空闲</view>
+										<view class="mtxt bgb" v-if="ite.type=='Y'"><text class="cir"></text>当前占用</view>
+									</view>
 								</view>
 								<!--已经预约的时间段 -->
 								<view class="tlist" v-show="meetid==ite.conferenceRoomId">
@@ -120,8 +126,9 @@
 	import {getRoomNoList,getRoomyyAdd,getRoomyyPut,getRoomyyDetail,getRoomtimeNoList} from "@/api/mine/work.js"
 	import {getDictionaryFn} from "@/api/mine/register.js"
 	import wSelect from "@/work/components/w-select/w-select.vue"
+	import hysBanner from "@/work/components/yuyue/hysbanner.vue"
 	export default {
-		components: {wSelect},
+		components: {wSelect,hysBanner},
 		data() {
 			return {
 				hupimg:require("@/static/images/order/hup.png"),
@@ -164,6 +171,7 @@
 				chooseValue:'',
 				name:this.$store.state.user.name,
 				userId:this.$store.state.user.userId,
+				bannerlist:[]
 			}
 		},
 		onPageScroll(e) {
@@ -208,6 +216,9 @@
 				uni.navigateBack({
 					delta: 1
 				})
+			},
+			getStop(){
+				
 			},
 			bindTimeChangea(e){
 				var val=e.detail.value;
@@ -363,7 +374,13 @@
 			getRoomNoList() {
 				getRoomNoList().then(res => {
 					if (res.code == 200) {
-						this.hyslist=res.rows
+						var newArr=res.rows;
+						newArr.forEach(ite=>{
+							if(ite.conferenceRoomUrl){
+								ite.conferenceRoomUrl=ite.conferenceRoomUrl.split(',')
+							}
+						})
+						this.hyslist=newArr
 					} else {
 						this.$toast(res.msg)
 					}
@@ -434,7 +451,7 @@ color: #FF0000;}
 	min-height: calc(100vh - 44px);		
 }
 // 会议室列表
-.mlists{display: flex;align-items: center;border-radius: 6rpx;border: 2rpx solid #C1C1C1;min-height: 90rpx;box-sizing: border-box;
+.mlists{border-radius: 6rpx;border: 2rpx solid #C1C1C1;min-height: 90rpx;box-sizing: border-box;
 padding: 24rpx 26rpx;
 	&.act{border: 2rpx solid #0391FD;
 		.mtit{font-weight: bold;color: #0391FD;}

BIN
work/static/yuy/left.png


BIN
work/static/yuy/right.png