Browse Source

修改banner图,添加 mac 地址

chenminghua 2 years ago
parent
commit
e256ed77d9

+ 28 - 2
exam-06173-uni - reg/App.vue

@@ -21,7 +21,8 @@
 			}
 		},
 		onShow: function() {
-
+			let mac = this.getDeviceMac();
+			uni.setStorageSync("mac", mac);
 		},
 		onHide: function() {
 
@@ -40,7 +41,32 @@
 						reject(err)
 					})
 				})
-			}
+			},
+			//获取设备的mac地址
+			getDeviceMac() {
+				//获取本机Mac地址
+				var deviceMac = 'pc';
+				if (uni.getSystemInfoSync().platform == "android") {
+					var net = plus.android.importClass('java.net.NetworkInterface');
+					var wl0 = net.getByName('wlan0');
+					var macByte = wl0.getHardwareAddress();
+					deviceMac = '';
+					for (var i = 0; i < macByte.length; i++) {
+						var tmp = '';
+						var num = macByte[i];
+						if (num < 0) {
+							tmp = (255 + num + 1).toString(16);
+						} else {
+							tmp = num.toString(16);
+						}
+						if (tmp.length == 1) {
+							tmp = '0' + tmp;
+						}
+						deviceMac += tmp;
+					}
+				}
+				return deviceMac;
+			},
 		}
 	}
 </script>

+ 6 - 6
exam-06173-uni - reg/common/config.js

@@ -5,18 +5,18 @@ let urls = {
 
 if(process.env.NODE_ENV === 'development'){
     // 开发环境
-    // urls.api = 'http://localhost:8617'
-    // urls.socket = 'ws://localhost:8617'
-	urls.api = 'http://124.70.18.168:8617'
-	urls.socket = 'ws://124.70.18.168:8617'
+    urls.api = 'http://10.155.32.18:8088'
+    urls.socket = 'ws://10.155.32.18:8088'
+	// urls.api = 'http://124.70.18.168:8617'
+	// urls.socket = 'ws://124.70.18.168:8617'
 }else{
     // t2预发布环境
     // urls.api = 'https://t2-api.jeegen.com'
     // urls.socket = 'wss://t2-api.jeegen.com'
 	
 	// 生产环境
-	urls.api = 'http://10.155.32.18:8617'
-	urls.socket = 'ws://10.155.32.18:8617'
+	urls.api = 'http://10.155.32.18:8088'
+	urls.socket = 'ws://10.155.32.18:8088'
 	
 	// 同域
 	// urls.api = ''

+ 2 - 1
exam-06173-uni - reg/pages.json

@@ -138,7 +138,8 @@
         ,{
             "path" : "pages/paper/list",
             "style" : {
-				"navigationBarTitleText": "考试列表"
+				"navigationBarTitleText": "考试列表",
+				"enablePullDownRefresh": true
 			}
         }
         ,{

+ 2 - 6
exam-06173-uni - reg/pages/index/index.vue

@@ -72,14 +72,10 @@
 				},
 				imgList: [
 				{
-					url: 'https://cdn.yfhl.net/static/banner/ob1.jpg',
-					id: 3
-				},
-				{
-					url: 'https://cdn.yfhl.net/static/banner/ob2.jpg',
+					url: 'http://10.155.32.18:8617/upload/file/banner/ob2.jpg',
 					id: 3
 				}, {
-					url: 'https://cdn.yfhl.net/static/banner/ob3.jpg',
+					url: 'http://10.155.32.18:8617/upload/file/banner/ob3.jpg',
 					id: 4
 				}]
 				// imgList: [

+ 3 - 3
exam-06173-uni - reg/pages/paper/detail.vue

@@ -8,16 +8,16 @@
 				
 				<!-- 显示感谢文字加分数 -->
 				<!-- <result-score v-if="paperData.resultType===2" :data="paperData" /> -->
-				<uni-forms-item label="姓名" name="realName">
+				<uni-forms-item label="姓名" name="realName" style="margin-bottom: 0px;">
 					<view style="height: 36px;line-height: 36px;">{{postForm.realName}}</view>
 				</uni-forms-item>
 
 
-				<uni-forms-item label="身份证号" name="idCard">
+				<uni-forms-item label="身份证号" name="idCard" style="margin-bottom: 0px;">
 					<view style="height: 36px;line-height: 36px;">{{postForm.idCard}}</view>
 				</uni-forms-item>
 
-				<uni-forms-item label="手机号" name="mobile">
+				<uni-forms-item label="手机号" name="mobile" style="margin-bottom: 10px;">
 					<view style="height: 36px;line-height: 36px;">{{postForm.mobile}}</view>
 				</uni-forms-item>
 				<view style="height: 150px;display: flex;justify-content: space-around;">

+ 2 - 6
exam-06173-uni/pages/index/index.vue

@@ -72,14 +72,10 @@
 				},
 				imgList: [
 				{
-					url: 'https://cdn.yfhl.net/static/banner/ob1.jpg',
-					id: 3
-				},
-				{
-					url: 'https://cdn.yfhl.net/static/banner/ob2.jpg',
+					url: 'http://10.155.32.18:8617/upload/file/banner/ob2.jpg',
 					id: 3
 				}, {
-					url: 'https://cdn.yfhl.net/static/banner/ob3.jpg',
+					url: 'http://10.155.32.18:8617/upload/file/banner/ob3.jpg',
 					id: 4
 				}]
 				// imgList: [