Browse Source

修改退役军人码页面以及细节问题

空白格 3 years ago
parent
commit
4073504d74

+ 4 - 2
h5_web/components/tki-qrcode/tki-qrcode.vue

@@ -6,7 +6,7 @@
 		<!-- #ifdef MP-ALIPAY -->
 		<canvas :id="cid" :width="cpSize" :height="cpSize" class="tki-qrcode-canvas" />
 		<!-- #endif -->
-		<image v-show="show" :src="result" :style="{width:cpSize+'px',height:cpSize+'px'}" />
+		<image v-show="show" :src="result" :style="{ width: cpSize + 'px',height: cpSize + 'px', padding: '10rpx', backgroundColor: val ? '#fff' : 'transparent'}" />
 	</view>
 </template>
 
@@ -118,7 +118,9 @@ export default {
 		},
 		_clearCode() {
 			this._result('')
-			qrcode.clear()
+			if (qrcode) {
+				qrcode.clear()
+			}
 		},
 		_saveCode() {
 			let that = this;

+ 8 - 1
h5_web/pages/cooperativeEnterprise/cooperativeEnterprise.vue

@@ -74,7 +74,12 @@
 				// 选中类型
 				tradeType: '',
 				// tab
-				tabList: [],
+				tabList: [
+					{
+						value: '',
+						name: '全部'
+					}
+				],
 				// tab选中项
 				tabCur: 0,
 				// 公司列表
@@ -111,12 +116,14 @@
 							title: res.msg,
 							type: 'error'
 						})
+						this.$refs.paging.complete([])
 					}
 				}).catch(err => {
 					this.$refs.uToast.show({
 						title: '系统异常!',
 						type: 'error'
 					})
+					this.$refs.paging.complete([])
 				})
 			},
 			/**

+ 2 - 1
h5_web/pages/index/index.vue

@@ -171,7 +171,8 @@
 						this.newsList = res.rows;
 					}else{
 						uni.showToast({
-							icon:'none',
+							icon: 'none',
+							type: 'error',
 							title:res.msg
 						})
 					}

+ 7 - 0
h5_web/pages/mine/mine.scss

@@ -44,6 +44,13 @@
 					color: #fff;
 					font-size: 40rpx;
 					font-family: 'PingFangSC-Medium, PingFang SC';
+					// width: 180rpx;
+					// overflow: hidden !important;
+					// word-break: break-all;  /* break-all(允许在单词内换行。) */
+					// text-overflow: ellipsis;  /* 超出部分省略号 */
+					// display: -webkit-box; /** 对象作为伸缩盒子模型显示 **/
+					// -webkit-box-orient: vertical; /** 设置或检索伸缩盒对象的子元素的排列方式 **/
+					// -webkit-line-clamp: 1; /** 显示的行数 **/
 				}
 			}
 			

+ 1 - 0
h5_web/pages/myInterview/myInterview.scss

@@ -0,0 +1 @@
+/* 我的面试 */

+ 4 - 3
h5_web/pages/myInterview/myInterview.vue

@@ -1,5 +1,6 @@
+<!-- 我的面试 -->
 <template>
-	<view>
+	<view class="interview">
 		我的面试
 	</view>
 </template>
@@ -17,6 +18,6 @@
 	}
 </script>
 
-<style>
-
+<style lang="scss" scoped>
+@import './myInterview.scss';
 </style>

+ 149 - 111
h5_web/pages/mycode/mycode.vue

@@ -1,124 +1,162 @@
-	<!-- 0审核中,1不通过,2通过,9未提交 -->
-<template>
-	<view>
-		<image class="bg" src="../../static/img/mycode-bg.png" mode="widthFix"></image>
-		<view class="content" style="padding-top: 20vh;">
-			<view class="qrimg">
-			    <tki-qrcode
-			    ref="qrcode"
-			    cid="cid"
-				:showLoading="false"
-			    :val="memberinfo.id"
-			    :size="300"
-			    background="#000"
-			    foreground="#fff"
-			    pdground="#fff"
-				:icon="icon"
-				:iconSize="40"
-				:usingComponents="true"
-			    :onval="true"
-			    @result="qrR" />
+<!-- 0审核中,1不通过,2通过,9未提交 -->
+	<template>
+		<view>
+			<image class="bg" src="../../static/img/mycode-bg.png" mode="widthFix"></image>
+			<view class="content" style="padding-top: 20vh;">
+				<view class="qrimg">
+					<tki-qrcode
+						ref="qrcode"
+						cid="cid"
+						:showLoading="false"
+						:val="memberinfo.id"
+						:size="384"
+						background="#000"
+						foreground="#fff"
+						pdground="#fff"
+						:usingComponents="true"
+						:onval="true"
+						@result="qrR"
+					/>
+					<!-- :icon="icon"
+						:iconSize="40" -->
+				</view>
 			</view>
-		</view>
-		<view class="code-text" v-show="memberinfo.auditStatus==2">
-			<view class="code-id">{{memberinfo.id}}</view>
-			<view class="thanks">
-				{{memberinfo.name}}{{memberinfo.menSex|verifySexFilter}},感谢您为国家的付出
+			<view class="code-text" v-if="memberinfo.auditStatus == 2">
+				<view class="code-id">{{ memberinfo.id }}</view>
+				<view class="thanks">
+					{{memberinfo.name}}{{memberinfo.menSex | verifySexFilter}},感谢您为国家的付出
+				</view>
+				<view v-if="!memberinfo.id">还没有退役军人码</view>
 			</view>
-			<view v-if="!memberinfo.id">还没有退役军人码</view>
-		</view>
-		<view class="content fixed" v-if="memberinfo.auditStatus==9">
-			<!-- 9未提交 -->
-			<view class="tip">
-				提交退役军人身份审核,获取退役军人码,并享受平台提供的专享培训、就业服务。
+			<view class="content fixed" v-if="memberinfo.auditStatus == 9">
+				<!-- 9未提交 -->
+				<view class="tip">
+					提交退役军人身份审核,获取退役军人码,并享受平台提供的专享培训、就业服务。
+				</view>
 			</view>
-		</view>
-		<view class="content fixed" v-else-if="memberinfo.auditStatus==0">
+			<view class="content fixed" v-else-if="memberinfo.auditStatus == 0">
 				<!-- 0审核中 -->
-			<view class="tip">
-				您已提交退役军人身份审核,通过后生成退役军人码,并可享受平台提供的专享培训、就业服务,请耐心等待。
+				<view class="tip">
+					您已提交退役军人身份审核,通过后生成退役军人码,并可享受平台提供的专享培训、就业服务,请耐心等待。
+				</view>
 			</view>
-		</view>
-		<view class="content fixed" v-else-if="memberinfo.auditStatus==1">
-			<!-- 1不通过 -->
-			<view class="tip">
-				很抱歉,您提交的退役军人身份信息未通过审核,请审查后重新提交。
+			<view class="content fixed" v-else-if="memberinfo.auditStatus==1">
+				<!-- 1不通过 -->
+				<view class="tip">
+					很抱歉,您提交的退役军人身份信息未通过审核,请审查后重新提交。
+				</view>
 			</view>
+
+			<!-- ########################## -- 底部导航栏 -- ################################ -->
+			<u-tabbar :list="tabbarConfig.tabbarList" :height="tabbarConfig.height" :mid-button="tabbarConfig.midButton"
+				:inactive-color="tabbarConfig.inactiveColor" :active-color="tabbarConfig.activeColor"
+				:mid-button-size="tabbarConfig.midButtonSize"></u-tabbar>
 		</view>
-    
-    <!-- ########################## -- 底部导航栏 -- ################################ -->
-    <u-tabbar
-      :list="tabbarConfig.tabbarList"
-      :height="tabbarConfig.height"
-      :mid-button="tabbarConfig.midButton"
-      :inactive-color="tabbarConfig.inactiveColor"
-      :active-color="tabbarConfig.activeColor"
-      :mid-button-size="tabbarConfig.midButtonSize"
-    ></u-tabbar>
-	</view>
-</template>
+	</template>
 
-<script>
-	import tkiQrcode from "@/components/tki-qrcode/tki-qrcode.vue";
-  import tabbarconfig from 'tabbarconfig.js';
-  
-	export default{
-		components: {tkiQrcode},
-		data(){
-			return{
-				memberinfo:[],
-				icon:'/static/icons/index.png',
-        tabbarConfig: tabbarconfig
-			}
-		},
-		onLoad(page){
-			
-		},
-		onShow(){
-			this.getmemberinfo();
-		},
-		filters:{
-			verifySexFilter(value){
-			  if (value == 0) {
-				return '先生';
-			  }else if(value == 1){
-				return '女士';
-			  }
-			 }
-		},
-		methods:{
-			getmemberinfo(){
-				this.$u.api.getmemberinfo().then(res=>{
-					if(res.code==200){
-						this.memberinfo = res.data;
-						if(this.memberinfo.auditStatus!==2){
-							this.memberinfo.id = null
-						}
-						console.log('this',this)
-						console.log('this.memberinfo',JSON.parse(JSON.stringify(this.memberinfo)));
-					}else{
-						uni.showToast({
-							icon:'none',
-							title:res.msg
-						})
+	<script>
+		import tkiQrcode from "@/components/tki-qrcode/tki-qrcode.vue";
+		import tabbarconfig from 'tabbarconfig.js';
+		export default {
+			components: {
+				tkiQrcode
+			},
+			data() {
+				return {
+					memberinfo: {},
+					icon: '/static/icons/index.png',
+					tabbarConfig: tabbarconfig
+				}
+			},
+			onLoad(page) {
+
+			},
+			onShow() {
+				this.getmemberinfo();
+			},
+			filters: {
+				verifySexFilter(value) {
+					if (value == 0) {
+						return '先生';
+					} else if (value == 1) {
+						return '女士';
 					}
-				})
+				}
 			},
-			qrR(e){
-				// console.log(e)
+			methods: {
+				getmemberinfo() {
+					this.$u.api.getmemberinfo().then(res => {
+						if (res.code == 200) {
+							this.memberinfo = res.data;
+							if (this.memberinfo.auditStatus !== 2) {
+								this.memberinfo.id = null;
+								this.$refs.qrcode._clearCode()
+							}
+						} else {
+							uni.showToast({
+								icon: 'none',
+								title: res.msg
+							})
+						}
+					})
+				},
+				qrR(e) {
+					// console.log(e)
+				}
 			}
 		}
-	}
-</script>
+	</script>
+
+	<style lang="scss" scoped>
+		.bg {
+			z-index: -1;
+			width: 100%;
+			height: auto;
+			position: fixed;
+			left: 0;
+			top: 100rpx;
+			opacity: 0.2;
+		}
+
+		.qrimg {
+			min-height: 100rpx;
+		}
+
+		.content {
+			text-align: center;
+			padding: 60vh 24rpx 24rpx;
+		}
+
+		.content.fixed {
+			position: absolute;
+			left: 0;
+			top: 60vh;
+			right: 0;
+			padding-top: 0;
+		}
 
-<style lang="scss" scoped>
-	.bg{z-index: -1;width: 100%;height: auto;position: fixed;left: 0;top: 100rpx;opacity: 0.2;}
-	.qrimg{min-height: 100rpx;}
-	.content{text-align: center;padding: 60vh 24rpx 24rpx;}
-	.content.fixed{position: absolute;left: 0;top: 60vh;right: 0;padding-top: 0;}
-	.content .tip{font-size: 36rpx;margin: 0 24rpx;text-align: left;text-indent: 2em;}
-	.code-text{margin: 24rpx auto;text-align: center;}
-	.code-id{font-size: 36rpx;font-weight: bold;}
-	.thanks{margin-top: 100rpx;}
-	// @import  './mycode.scss'
-</style>
+		.content .tip {
+			font-size: 32rpx;
+			margin: 0 24rpx;
+			text-align: left;
+			text-indent: 2em;
+			color: #3D5D4C;
+		}
+
+		.code-text {
+			margin: 0 auto;
+			text-align: center;
+		}
+
+		.code-id {
+			font-size: 36rpx;
+			font-weight: 500;
+			color: #000000;
+		}
+
+		.thanks {
+			margin-top: 100rpx;
+			font-size: 36rpx;
+			color: #3D5D4C;
+		}
+	</style>

+ 14 - 2
h5_web/pages/newsInformation/newsInformation.vue

@@ -21,6 +21,7 @@
 				</view>
 			</view>
 		</z-paging>
+		<u-toast ref="uToast" />
 	</view>
 </template>
 
@@ -29,8 +30,7 @@
 		data() {
 			return {
 				// 新闻列表
-				newsList: [],
-				
+				newsList: []
 			}
 		},
 		methods: {
@@ -45,7 +45,19 @@
 				}).then(res => {
 					if (res.code === 200) {
 						this.$refs.paging.complete(res.rows)
+					} else {
+						this.$refs.uToast.show({
+							title: err.msg,
+							type: 'error'
+						})
+						this.$refs.paging.complete([])
 					}
+				}).catch((err) => {
+					this.$refs.uToast.show({
+						title: '系统异常!',
+						type: 'error'
+					})
+					this.$refs.paging.complete([])
 				})
 			},
 			/**

+ 5 - 7
h5_web/pages/professionalDetails/professionalDetails.vue

@@ -28,13 +28,11 @@
 			}
 		},
 		onShow() {
-			uni.showLoading({
-				title: '加载中'
-			})
 			if (this.professionalId) {
-				setTimeout(() => {
-					this.getProfessionalInfo(this.professionalId)
-				}, 300)
+				uni.showLoading({
+					title: '加载中'
+				})
+				this.getProfessionalInfo(this.professionalId)
 			}
 		},
 		methods: {
@@ -70,7 +68,7 @@
 		text-align: center;
 		font-size: 42rpx;
 		color: #3D5D4C;
-		font-weight: 500;
+		font-weight: 600;
 	}
 	&-code {
 		color: #606060;

+ 13 - 0
h5_web/pages/schools/schools.vue

@@ -31,6 +31,7 @@
 				</view>
 			</view>
 		</z-paging>
+		<u-toast ref="uToast" />
 	</view>
 </template>
 
@@ -70,7 +71,19 @@
 				}).then(res => {
 					if (res.code === 200) {
 						this.$refs.paging.complete(res.rows)
+					} else {
+						this.$refs.uToast.show({
+							title: res.msg,
+							type: 'error'
+						})
+						this.$refs.paging.complete([])
 					}
+				}).catch(() => {
+					this.$refs.uToast.show({
+						title: '系统异常!',
+						type: 'error'
+					})
+					this.$refs.paging.complete([])
 				})
 			},
 			/**