Jelajahi Sumber

修改一些细节

xklr/wlj 1 tahun lalu
induk
melakukan
c09310dc11
2 mengubah file dengan 27 tambahan dan 18 penghapusan
  1. 10 10
      App.vue
  2. 17 8
      pages/index/index.vue

+ 10 - 10
App.vue

@@ -2,7 +2,7 @@
 	import configpath from 'config/setting.config.js';
 	import api from 'api/index.js'
 	import Vue from 'vue'
-	
+
 	const inforeq = (cb) => {
 		fetch('/static/.config.json')
 			.then((res) => res.json())
@@ -30,28 +30,28 @@
 			SET_CUSTOM_BAR: 0,
 			SET_SYSTEM_INFO: {},
 			configData: {},
-			token:''
+			token: ''
 		},
 		onLaunch: function(option) {
 			let token = window.location.search.split('token=')[1]
 			console.log('App Launch')
 			console.log(token)
-		
+
 			let t = this;
-			inforeq((res)=>{
-				t.globalData.configData=res
-				if(token&&token.length>0){
+			inforeq((res) => {
+				t.globalData.configData = res
+				if (token && token.length > 0) {
 					console.log(token)
 					uni.setStorage({
 						key: 'token',
 						data: token,
-						success: function () {
+						success: function() {
 							console.log('success');
 						}
 					});
 					t.globalData.token = token
 				}
-				
+
 			})
 		},
 		onShow: function() {
@@ -120,8 +120,8 @@ this.globalData.SET_STATUS_BAR = statusBar
 	}
 
 	.my-button:after {
-		border-width: 0px;
-		border-radius: 0px;
+		border-width: 0px !important;
+		border-radius: 0px !important;
 		transform: initial;
 		background-color: transparent;
 	}

+ 17 - 8
pages/index/index.vue

@@ -121,12 +121,14 @@
 					<view class="text-center mb-3 fs-14 font-bold py-2">
 						查询
 					</view>
-					<view class=" centerY mb-3"
-						style="border-radius: 14rpx;border: 1px solid #007aff;overflow: hidden;">
-						<input type="text" v-model="valueId" class="px-2 fs-12 w-70" placeholder="请输入身份证号码"
-							placeholder-class="fs-12">
-						<button type="primary" class="d-inline-block fs-12 px-2 ml-auto w-30" style="padding: 4rpx ;"
-							@click="search">搜索</button>
+					<view class=" centerY mb-3 w-100 border-box" style="overflow: hidden; ">
+						<input type="text" v-model="valueId" class="px-2 py-2 fs-12 w-70"
+							style="border: 2px solid #007aff;border-top-left-radius: 2rpx;border-bottom-left-radius: 2rpx;"
+							placeholder="请输入身份证号码" placeholder-class="fs-12" />
+						<uni-button type="primary" class="my-button fs-12 px-2 ml-auto border-box w-30"
+							style="padding: 0x ;border: 1px solid #007aff;border-top-right-radius: 12rpx;border-bottom-right-radius: 12rpx;"
+							@click="search">搜索
+						</uni-button>
 					</view>
 				</view>
 			</uni-popup>
@@ -136,7 +138,7 @@
 					<view class="text-center mb-3 fs-14 font-bold py-2">
 						患者列表
 					</view>
-					<view class="text-left centerY mb-3" style="border-radius: 14rpx;border: 1px solid #007aff;">
+					<view class="text-left centerY mb-3" style="border-radius: 14rpx;border: 2px solid #007aff;">
 						<uni-data-select v-model="userIndex" :localdata="userArr" @change="bindPickerChange"
 							placeholder="请选择身份">
 						</uni-data-select>
@@ -215,7 +217,7 @@
 									}
 									if (item.ip == globalData.configData.prodIp) {
 										//兰溪
-										if (item.name == '开发') {
+										if (item.name == '兰溪') {
 											if (!res.data.length > 10) return
 											console.log(res)
 											let res2 = await t.$api.decrypt({
@@ -246,6 +248,13 @@
 												}
 											}
 										}
+									} else {
+										if (!uni.getStorageSync('idCard')) {
+											t.$refs.popup1.open()
+											uni.hideLoading()
+										} else {
+											t.getuserinfo(uni.getStorageSync('idCard'))
+										}
 									}
 								}, 300)