From 7a352693c7fa090da0f8af9a62dec2e85adc83ab Mon Sep 17 00:00:00 2001
From: wjt <1797368093@qq.com>
Date: 星期五, 21 六月 2024 09:05:14 +0800
Subject: [PATCH] 添加扫码页面

---
 static/policy/error.png         |    0 
 pages.json                      |    8 +
 policy/scodePage/scodePage.vue  |  102 ++++++++++++++++++++
 static/policy/back.png          |    0 
 static/policy/success.png       |    0 
 policy/scodePage/scodePage.scss |  161 ++++++++++++++++++++++++++++++++
 static/policy/qrcode-border.png |    0 
 7 files changed, 271 insertions(+), 0 deletions(-)

diff --git a/pages.json b/pages.json
index 9668040..c3df2bb 100644
--- a/pages.json
+++ b/pages.json
@@ -149,6 +149,14 @@
 					{
 						"navigationBarTitleText" : ""
 					}
+				},
+				{
+					"path" : "scodePage/scodePage",
+					"style" : 
+					{
+						"navigationBarTitleText" : "",
+						"navigationStyle": "custom"
+					}
 				}
 			]
 		}
diff --git a/policy/scodePage/scodePage.scss b/policy/scodePage/scodePage.scss
new file mode 100644
index 0000000..7659470
--- /dev/null
+++ b/policy/scodePage/scodePage.scss
@@ -0,0 +1,161 @@
+.page-box{
+	position: absolute;
+	top: 0;
+	width: 100%;
+	.code-hint{
+		position: absolute;
+		top: 170rpx;
+		width: 100%;
+		text-align: center;
+		font-size: 56rpx;
+		color: white;
+		box-sizing: border-box;
+		image{
+			width: 68rpx;
+			height: 68rpx;
+			vertical-align: middle;
+			margin-right: 16rpx;
+		}
+		.hint{
+			font-size: 28rpx;
+			margin-top: 24rpx;
+		}
+	}
+	.qrcode{
+		text-align: center;
+		position: absolute;
+		top: 381rpx;
+		width: 100%;
+		.border{
+			width: 500rpx;
+			height: 500rpx;	
+			position: absolute;
+			left: 50%;
+			transform: translateX(-50%);
+		}
+		.qrcode-1{
+			position: absolute;
+			left: 50%;
+			top: 15rpx;
+			width: 470rpx;
+			height: 470rpx;
+			transform: translateX(-50%);
+		}
+		.code-time{
+			position: absolute;
+			left: 50%;
+			bottom: 24rpx;
+			top: 520rpx;
+			width: 100%;
+			color: #7E8596;
+			font-size: 24rpx;
+			transform: translateX(-50%);
+			
+			text{
+				color: #C3C6CD;
+			}
+		}
+	}
+	.code{
+		 
+		position: absolute;
+		top: 950rpx;
+		background-color: #F4F4F4;
+		padding:  24rpx 30rpx;
+		width: 80%;
+		box-sizing: border-box;
+		margin: 0 auto;
+		border-radius: 10rpx;
+		left: 10%;
+		font-size: 28rpx;
+		.item{
+			display: flex;
+			justify-content: space-between;
+			align-items: center;
+			.label{
+				color: #7E8596;
+			}
+			.value{
+				color: #4A4E60;
+			}
+		}
+		.write-border{
+			width: 100%;
+			border-bottom: 2rpx solid white;
+			margin: 24rpx 0;
+		}
+	}
+	.hint-text{
+		position: absolute;
+		top: 1250rpx;
+		width: 100%;
+		padding: 0 26rpx;
+		font-size: 28rpx;
+		color: white;
+		z-index: 1000;
+		box-sizing: border-box;
+		text{
+			font-size: 36rpx;
+		}
+	}
+	.down-block{
+		position: absolute;
+		top: 1260rpx;
+		background-color: #4F86F3;
+		width: 100%;
+		padding-top: 55rpx;
+		.box{
+			margin: 20rpx 32rpx;
+			background-color: white;
+			padding: 24rpx;
+			border-radius: 10rpx;
+			.title{
+				font-size: 32rpx;
+				font-weight: 700;
+				margin-bottom: 12rpx;
+			}
+			.user-news{
+				display: flex;
+				justify-content: flex-start;
+				align-items: center;
+				font-size: 28rpx;
+				color: #4A4E60;
+				margin-bottom: 12rpx;
+				.driver{
+					width: 2rpx ;
+					height: 20rpx;
+					background-color: #F4F4F4;
+					margin: 0 10rpx;
+				}
+			}
+			.border{
+				border: 2rpx dotted #F4F4F4;
+				margin: 24rpx 0;
+			}
+			.font-13{
+				font-size: 26rpx;
+				color: #4A4E60;
+				text{
+					color: #C3C6CD;
+				}
+			}
+			.font-12{
+				font-size: 24rpx;
+				color: #4A4E60;
+				text{
+					color: #C3C6CD;
+				}
+			}
+			.margin-bottom{
+				margin-bottom: 12rpx;
+			}
+			
+		}
+	}
+}
+.back-image{
+	width: 100%;
+}
+.hide-canvas{
+	display: none;
+}
\ No newline at end of file
diff --git a/policy/scodePage/scodePage.vue b/policy/scodePage/scodePage.vue
new file mode 100644
index 0000000..6ca01de
--- /dev/null
+++ b/policy/scodePage/scodePage.vue
@@ -0,0 +1,102 @@
+<template>
+	<view>
+		  <u-navbar
+				@rightClick="rightClick"
+				:autoBack="true"
+				:placeholder="false"
+				bgColor="transparent"
+				leftIconColor="white"
+			>
+			</u-navbar>
+		<image src="/static/policy/back.png" mode="widthFix" class="back-image"></image>
+		<view class="page-box">
+			<view class="code-hint">
+				<view>
+					<image src="/static/policy/success.png" mode="widthFix"></image>
+					<!-- <image src="/static/policy/error.png" mode="widthFix"></image> -->
+					<text>鎴愬姛-缁跨爜</text>
+					<!-- <text>澶辫触-绾㈢爜</text> -->
+				</view>
+				<view class="hint">
+					鍙姝や紒涓氳繘琛屾牳鏌�
+				</view>
+				<view class="hint">
+					璇锋牳鏌ヤ紒涓氫俊鎭�
+				</view>
+			</view>
+			<!-- 浜岀淮鐮� -->
+			<view class="qrcode">
+				<image src="/static/policy/qrcode-border.png" class="border" mode="widthFix"></image>
+				<image :src="uqrcodeImage" mode="widthFix" class="qrcode-1"></image>
+				<view class="code-time">
+					<text>鎵爜鏃堕棿锛�</text>2024-05-12 12:00
+				</view>
+			</view>
+			<view class="code">
+				<view class="item">
+					<text class="label">鎵ф硶浜哄憳</text>
+					<text class="value">鐜嬪皬涓�</text>
+				</view>
+				<view class="write-border"></view>
+				<view class="item">
+					<text class="label">鎵ф硶閮ㄩ棬</text>
+					<text class="value">宸ュ晢绠$悊灞�</text>
+				</view>
+			</view>
+			<view class="hint-text">
+				褰撳墠浼佷笟瀛樺湪<text>1</text>鏉℃湭瀹屾垚鐨勬墽娉曚换鍔�
+			</view>
+			<view class="down-block">
+				<view class="box">
+					<view class="title">24骞�5鏈堢獊鍑绘鏌ユ秷闃插畨鍏�</view>
+					<view class="user-news">
+						<text>鐜嬫�濋洦</text>
+						<view class="driver"></view>
+						<text>宸ュ晢绠$悊灞�</text>
+					</view>
+					<view class="font-13">
+						<text>鎵ф硶瀵硅薄锛�</text>娌冲崡瑙夐啋绉戞妧鏈夐檺鍏徃
+					</view>
+					<view class="border"></view>
+					<view class="font-12 margin-bottom">
+						<text>鎵ф硶鏃堕棿锛�</text>2024-05-12 12:00
+					</view>
+					<view class="font-12">
+						<text>鐢宠鏃堕棿锛�</text>2024-05-12 12:00:12
+					</view>
+				</view>
+			</view>
+		</view>
+		<uqrcode class="hide-canvas" :size="470" sizeUnit="rpx" v-if="companyCode" ref="uqrcode" canvas-id="qrcode" :value="companyCode" :options="{ backgroundColor: 'green',useDynamicSize: true,  areaColor: '#ffffff', foregroundColor: '#ffffff' }"></uqrcode>
+		
+	</view>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				companyCode: 'code===',
+				uqrcodeImage: ''
+			}
+		},
+		onReady() {
+			this.$refs.uqrcode.toTempFilePath({
+			  success: res => {
+				this.uqrcodeImage = res.tempFilePath
+			  }
+			});
+		},
+		methods: {
+			
+		}
+	}
+</script>
+<style>
+	page{
+		padding-bottom: 20rpx;
+	}
+</style>
+<style lang="scss" scoped>
+@import "./scodePage.scss";
+</style>
diff --git a/static/policy/back.png b/static/policy/back.png
new file mode 100644
index 0000000..3e08f69
--- /dev/null
+++ b/static/policy/back.png
Binary files differ
diff --git a/static/policy/error.png b/static/policy/error.png
new file mode 100644
index 0000000..f7f57ed
--- /dev/null
+++ b/static/policy/error.png
Binary files differ
diff --git a/static/policy/qrcode-border.png b/static/policy/qrcode-border.png
new file mode 100644
index 0000000..fedbe51
--- /dev/null
+++ b/static/policy/qrcode-border.png
Binary files differ
diff --git a/static/policy/success.png b/static/policy/success.png
new file mode 100644
index 0000000..0fce4b9
--- /dev/null
+++ b/static/policy/success.png
Binary files differ

--
Gitblit v1.9.1