zhoujump 2 ヶ月 前
コミット
821f97ee59
4 ファイル変更86 行追加4 行削除
  1. 2 1
      .gitignore
  2. 3 2
      pages.json
  3. 74 0
      pages/checkIn/index.vue
  4. 7 1
      pages/index/home.vue

+ 2 - 1
.gitignore

@@ -1,4 +1,5 @@
 .hbuilderx/
 node_modules/
 unpackage/dist/
-.idea/
+.idea/
+wxcomponents

+ 3 - 2
pages.json

@@ -36,8 +36,9 @@
 		// WEBVIEW
 		{ "path": "pages/index/webview", "style": { "navigationStyle": "default", "navigationBarTitleText": "加载中...", "navigationBarBackgroundColor": "#332968" }},
 		// 观众指南
-		{ "path": "pages/files/index", "style": { "navigationBarTitleText": "观众指南" }}
-	],
+		{ "path": "pages/files/index", "style": { "navigationBarTitleText": "观众指南" }},
+		// 打卡
+		{ "path" : "pages/checkIn/index", "style" : {"navigationBarTitleText": "福利嘉年华" }}],
 	"globalStyle": {
 		"navigationStyle": "custom",
 		"navigationBarTextStyle": "white",

+ 74 - 0
pages/checkIn/index.vue

@@ -0,0 +1,74 @@
+<template>
+	<view class="outter">
+		<view class="head_title" :style="{height:head_height+'px'}">
+			<view class="title" :style="{height:title_height+'px'}">
+				<text @click="navigateBack()" class="iconfont .icon-Left"></text>
+				福利嘉年华
+			</view>
+		</view>
+		<view class="body" :style="{height:'calc(100% - '+head_height+'px)'}">
+		
+		</view>
+		<view class="side-button">
+			
+		</view>
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				head_height:0,
+				title_height:0
+			};
+		},
+		methods:{
+			getSafeHeight(){
+				let menuButtonInfo = uni.getMenuButtonBoundingClientRect()
+				this.head_height = menuButtonInfo.bottom + 25
+				this.title_height = menuButtonInfo.height
+			},
+			navigateBack(){
+				uni.navigateBack(1)
+			}
+		},
+		onLoad() {
+			this.getSafeHeight()
+		}
+	}
+</script>
+
+<style lang="scss">
+	.outter{
+		height: 100%;
+		position: relative;
+		.head_title{
+			width: 100%;
+			background: linear-gradient( 270deg, #332968 9%, #435797 44%, #382E73 92%), rgba(0,0,0,0.2);
+			padding-bottom: 25px;
+			display: flex;
+			align-items: flex-end;
+			padding-left: 28px;
+			.title{
+				display: flex;
+				align-items: center;
+				color: white;
+				font-size: 20px;
+				.iconfont{
+					font-size: 26px;
+					margin-right: 8px;
+				}
+			}
+		}
+		.body{
+			overflow: hidden;
+			overflow-y: auto;
+		}
+		.side-button{
+			position: absolute;
+			right: 32px;
+			height: 32px;
+		}
+	}
+</style>

+ 7 - 1
pages/index/home.vue

@@ -195,7 +195,13 @@ export default {
         name: '',
         is_hide: false,
         link: 'https://www.productronicachina.com.cn/travel-stay-getting-there'
-      }],
+      },
+	  {
+	    icon: 'icon-xiaochengxu-jiaotongzhinanicon',
+	    name: '打卡',
+	    is_hide: false,
+	    link: '/pages/checkIn/index'
+	  }],
       images: [],
       videos: [],
       albumPics: [],