Browse Source

Merge branch 'master' of https://git.nanodreamtech.com/Boss/yizhizan-h5

7 months ago
parent
commit
0bff61f4af

+ 34 - 0
common/queue.js

@@ -387,4 +387,38 @@ module.exports = {
 		    console.log('tabbar 更新完成');
 		  },100);
 	},
+	// 核心年龄计算函数
+	        calculateAgeFromBirthday:function(birthday) {
+	            const birthDate = new Date(birthday);
+	            const currentDate = new Date();
+	            
+	            // 验证日期有效性
+	            if (isNaN(birthDate.getTime())) {
+	                throw new Error('无效的生日日期');
+	            }
+	            
+	            if (birthDate > currentDate) {
+	                throw new Error('生日日期不能晚于当前日期');
+	            }
+	            
+	            let years = currentDate.getFullYear() - birthDate.getFullYear();
+	            let months = currentDate.getMonth() - birthDate.getMonth();
+	            let days = currentDate.getDate() - birthDate.getDate();
+	            
+	            // 处理天数负数情况
+	            if (days < 0) {
+	                months--;
+	                // 获取上个月的天数
+	                const lastMonth = new Date(currentDate.getFullYear(), currentDate.getMonth(), 0);
+	                days += lastMonth.getDate();
+	            }
+	            
+	            // 处理月份负数情况
+	            if (months < 0) {
+	                years--;
+	                months += 12;
+	            }
+	            
+	            return years;
+	        }
 };

+ 14 - 3
components/hg-level4-address/hgLevel4Address.vue

@@ -43,6 +43,10 @@
 			city: {
 				type: [String, Number],
 				default: ''
+			},
+			county: {
+				type: [String, Number],
+				default: ''
 			}
 		},
 		data() {
@@ -103,10 +107,13 @@
 						if (city.code == this.city || city.name.indexOf(this.city) !== -1) {
 							this.selectedProvince = province
 							this.selectedCity = city
-							this.selectedArea = {
-								code: 'all',
-								name: '全部'
+							
+							for (const area of city.children || []) {
+								if (area.code == this.county || area.name.indexOf(this.county) !== -1) {
+									this.selectedArea=area
+								}
 							}
+	
 							this.selectedStreet = {
 								code: 'all',
 								name: '全部'
@@ -153,6 +160,7 @@
 
 			/** 街道选择 */
 			selectStreet(street) {
+				return this.$queue.showToast('街道选择暂未开放,')
 				this.selectedStreet = street
 			},
 
@@ -231,6 +239,9 @@
 	.street{
 		flex: 1;
 		background: linear-gradient(to right, rgba(251, 251, 251, 1), rgba(255, 255, 255, 1));
+		.item{
+			color: #ccc;
+		}
 	}
 	.item {
 		padding: 15rpx 50rpx;

+ 8 - 2
package/jobIntention/basicInfo.vue

@@ -253,7 +253,13 @@
 						title: "联系电话不能为空",
 						icon: "none"
 					})
-				} else {
+				} else if(!this.birthDateText){
+					uni.showToast({
+						title: "生日不能为空",
+						icon: "none"
+					})
+				}else{
+					this.age=this.$queue.calculateAgeFromBirthday(this.birthDateText)||0
 					let that = this
 					uni.showModal({
 						title: '温馨提示',
@@ -288,7 +294,7 @@
 			setResume() {
 				let data={
 					resumesStatus:this.selectedJobStatus,
-					resumesPhone: that.phone,
+					resumesPhone: this.phone,
 					birthday:this.birthDateText,
 					ifExp:this.ifExp
 				}

+ 44 - 8
package/screen/city.vue

@@ -5,12 +5,14 @@
 				<view class="nav-left" @click="goBack">
 					<u-icon name="close" color="#333" size="32"></u-icon>
 				</view>
-				<view class="nav-title">城市选择</view>
-				<view class="nav-right"></view>
+				<view class="nav-title">{{city||'北京'}}</view>
+				<view @click="goTo" class="nav-right">
+					<image src="../../static/images/filter.svg" mode="widthFix"></image> 筛选城市
+				</view>
 			</view>
 		</view>
 		 <view class="content">
-			<hg-level4-address :city="city"
+			<hg-level4-address :city="city" :county="county"
 			  placeholder="请选择地址"
 			  @confirm="onAddressConfirm"
 			  >         
@@ -28,14 +30,16 @@
 		data() {
 			return {
 				statusBarHeight: 0, // 状态栏高度
-				
+				city: '', //市
+				county: '', //区
 			};
 		},
-		onLoad(option) {
+		onLoad(options) {
 			// 获取状态栏高度
 			let systemInfo = uni.getSystemInfoSync();
 			this.statusBarHeight = systemInfo.statusBarHeight || 0;
-			this.city = option.city
+			this.city = options&&options.city
+			this.county = options&&options.county
 		},
 		onShow() {
 
@@ -43,7 +47,23 @@
 		methods: {
 			onAddressConfirm(selected) {
 			  console.log("选中的地址:", selected);
+							this.city = selected[1].name
+							this.county = selected[2].name
+							let data = {
+								city: this.city=='全国'||this.city=='全部'?'':this.city,
+								county: this.county == '全部' ? '' : this.county
+							}
+							uni.$emit('filterCity', data)
+							uni.navigateBack()
+						},
+			goBack(){
+				uni.navigateBack()
 			},
+			goTo(){
+				uni.navigateTo({
+					url:'/package/jobIntention/city'
+				})
+			}
 		}
 	}
 </script>
@@ -61,11 +81,27 @@
 			box-sizing: border-box;
 			padding: 0 32rpx;
 			.nav-left, .nav-right {
-				width: 60rpx;
+				width: 146rpx;
 				height: 60rpx;
 				display: flex;
 				align-items: center;
-				justify-content: center;
+				justify-content: flex-start;
+				padding-left: 20rpx;
+			}
+			.nav-right{
+				width: fit-content;
+				white-space: nowrap;
+				color: #016Bf6;
+				align-items: center;
+				justify-content: flex-start;
+				padding-left: 0rpx;
+				image{
+					width: 28rpx;
+					display: block;
+					margin-right:6rpx;
+					position: relative;
+					top:2rpx
+				}
 			}
 			.nav-title {
 				color: rgba(51, 51, 51, 1);

+ 49 - 7
package/search/search.vue

@@ -22,13 +22,14 @@
 				<view class="searchJl-box">
 					<view class="searchJl-box-header">
 						<text class="searchJl-box-title">历史搜索</text>
-						<image src="../../static/images/shanchu22.svg" style="width: 32rpx; height: 32rpx;" mode="aspectFit" @click="clearHistory"></image>
+						<image v-if="searchList.length > 0" src="../../static/images/shanchu22.svg" style="width: 32rpx; height: 32rpx;" mode="aspectFit" @click="clearHistory"></image>
 					</view>
 					<view class="searchJl-box-label flex align-center flex-wrap">
 						<view class="searchJl-box-item" @click="goSearch(item.keyWord)"
 							v-for="(item,index) in searchList" :key="index">
 							{{item.keyWord}}
 						</view>
+						<view class="no-more" v-if="searchList.length == 0">暂无记录</view>
 					</view>
 				</view>
 			</view>
@@ -38,7 +39,7 @@
 				<view class="hot-jobs-section">
 					<view class="section-header">
 						<text class="section-title">近期热招</text>
-						<image src="../../static/images/shanchu22.svg" style="width: 32rpx; height: 32rpx;" mode="aspectFit" @click="clearHotJobs"></image>
+						<!-- <image src="../../static/images/shanchu22.svg" style="width: 32rpx; height: 32rpx;" mode="aspectFit" @click="clearHotJobs"></image> -->
 					</view>
 					<view class="hot-jobs-grid">
 						<view 
@@ -74,13 +75,13 @@
 							</view>
 
 							<view v-if="currentSx==0" class="sort-container" @click="showSortModal">
-								<text class="sort-text" style="margin-right: 10rpx;">综合排序</text>
+								<text class="sort-text" style="margin-right: 10rpx;">{{sortOptions[selectedSort]}}</text>
 								<u-icon name="arrow-down" color="rgba(1, 107, 246, 1)" size="20"></u-icon>
 							</view>
 								
-							<view class="filter-container" @click="goNav('/package/screen/screen')">
-								<text class="filter-text" style="margin-right: 10rpx;">筛选</text>
-								<u-icon name="arrow-down" color="#999999" size="20"></u-icon>
+							<view class="filter-container" :class="{ activeColor: filledFieldsCount }" @click="goNav('/package/screen/screen')">
+								<text class="filter-text" style="margin-right: 10rpx;">筛选{{filledFieldsCount}}</text>
+								<u-icon name="arrow-down" :color="filledFieldsCount?'#016bf6':'#999999'" size="20"></u-icon>
 							</view>
 						</view>
 					</view>
@@ -315,6 +316,13 @@
 			this.getMyRecordList()
 			this.getHotList()
 		},
+		computed: {
+			filledFieldsCount() {
+		       const fields = [this.education, this.experience, this.industry, this.salaryRange, this.companyPeople];
+		       const count = fields.filter(item => item).length;
+		       return count > 0 ? '·' + count : '';
+			}
+		  },
 		onShow() {
 			let that = this;
 			if (!this.city) {
@@ -382,6 +390,26 @@
 			}
 		},
 		methods: {
+			// 删除历史记录
+			clearHistory(){
+				let that = this;
+				uni.showModal({
+					title: "提示",
+					content: "确定删除吗?",
+					confirmColor: "#016BF6",
+					success: function(res) {
+						that.$Request.post('/app/record/deleteRecord', {recordId:''}).then(res => {
+							if (res.code == 0) {
+								that.searchList = []
+								uni.showToast({
+									title: '删除成功',
+									icon: "none"
+								})
+							}
+						})
+					},
+				});
+			},
 			/**
 			 * 返回上一页
 			 */
@@ -582,7 +610,8 @@
 			
 			// 选择排序选项
 			selectSort(index) {
-				this.selectedSort = index
+				this.selectedSort = index;
+				
 				this.hideSortModal()
 				// 这里可以添加排序逻辑
 				this.getUserList();
@@ -759,6 +788,12 @@
 		padding: 8rpx 12rpx;
 		border-radius: 12rpx;
 		background: rgba(198, 198, 198, 0.1);
+		border:1rpx solid rgba(198, 198, 198, 0.1);
+	}
+	.activeColor{
+		color: #016bf6;
+		border:1rpx solid #016bf6;
+		background: #fff;
 	}
 
 	.searchJl {
@@ -808,6 +843,13 @@
 					text-align: left;
 					margin-top: 20rpx;
 				}
+				.no-more{
+					line-height: 20rpx;
+					padding: 12rpx;
+					font-family: DM Sans;
+					font-size: 20rpx;
+					font-weight: 400;
+				}
 			}
 		}
 	}

+ 2 - 2
pages/msg/im.vue

@@ -193,7 +193,7 @@
 						<view class="talent-content">
 							<!-- 头像和基本信息 -->
 							<view class="talent-header">
-								<image :src="resumesInfo.avatar" class="talent-avatar" mode="aspectFill"></image>
+								<image :src="resumesInfo&&resumesInfo.avatar||'../../static/logo.png'" class="talent-avatar" mode="aspectFill"></image>
 								<view class="talent-info">
 									<view class="talent-name-section">
 										<view class="talent-name">期望:{{ resumesInfo.intentionRuleClassifyName }} <text class="talentRange">{{resumesInfo.intentionSalaryRange}}</text></view>
@@ -228,7 +228,7 @@
 				
 							<!-- 技能标签 -->
 							<view class="skill-tags">
-								<view class="skill-tag" v-for="(skill, skillIndex) in resumesInfo.resumesListDtoList.intentIndustry&&resumesInfo.resumesListDtoList.intentIndustry.split('/')||[]" :key="skillIndex">
+								<view class="skill-tag" v-for="(skill, skillIndex) in resumesInfo.resumesListDtoList&&resumesInfo.resumesListDtoList.intentIndustry&&resumesInfo.resumesListDtoList.intentIndustry.split('/')||[]" :key="skillIndex">
 									{{ skill }}
 								</view>
 							</view>

+ 1 - 0
pages/my/attachment.vue

@@ -325,6 +325,7 @@
 				    });
 				  }
 				});
+				return;
 				//#endif
 				uni.navigateTo({
 					url: '/pages/index/webView?url=' + it.attachmentAddress+'&title='+it.attachmentName

+ 1 - 0
pages/my/index.vue

@@ -1935,6 +1935,7 @@
 						width: 128rpx;
 						height: 128rpx;
 						border-radius: 50%;
+						display: block;
 					}
 				}
 

+ 2 - 0
pages/my/jobApplicant/workRecord.vue

@@ -464,9 +464,11 @@ export default {
         uni.showToast({ title: "请输入出生年月", icon: "none" });
         return;
       }
+	  let age=this.$queue.calculateAgeFromBirthday(this.formData.birthDate)||0
 		let data={
 			avatar:this.formData.avatar,
 			userName:this.formData.name,
+			age,
 			sex:this.formData.gender,
 			phone:this.formData.phone
 		}

+ 1 - 0
pages/my/ruleCenter.vue

@@ -138,6 +138,7 @@ export default {
 
     // 点击轮播图
     handleBannerClick(item) {
+		return;
       if (item.link) {
         uni.navigateTo({
           url: item.link,

File diff suppressed because it is too large
+ 440 - 425
pages/my/workExperience.vue


+ 3 - 1
pages/public/forgetPwd.vue

@@ -111,7 +111,9 @@
 					this.$queue.showToast("请输入手机号");
 				} else if (phone.length !== 11) {
 					this.$queue.showToast("请输入正确的手机号");
-				} else {
+				} else if(this.sendTime != '获取验证码'){
+					return;
+				}else {
 					this.$queue.showLoading("正在发送验证码...");
 					this.$Request.getT("/app/Login/sendMsg/" + phone + "/forget").then((res) => {
 						if (res.code === 0) {

+ 11 - 9
pages/public/loginphone.vue

@@ -101,7 +101,9 @@
 					this.$queue.showToast("请输入手机号");
 				} else if (phone.length !== 11) {
 					this.$queue.showToast("请输入正确的手机号");
-				} else {
+				} else if(this.sendTime != '获取验证码'){
+					return;
+				}else {
 					this.$queue.showLoading("正在发送验证码...");
 					this.$Request.getT("/app/Login/sendMsg/" + phone + "/forget").then((res) => {
 						if (res.code === 0) {
@@ -354,14 +356,14 @@
 		background-color: #ffffff;
 	}
 
-	.send-msg {
-		border-radius: 30px;
-		color: black;
-		background: white;
-		height: 30px;
-		font-size: 14px;
-		line-height: 30px;
-	}
+	// .send-msg {
+	// 	border-radius: 30px;
+	// 	color: black;
+	// 	background: white;
+	// 	height: 30px;
+	// 	font-size: 14px;
+	// 	line-height: 30px;
+	// }
 
 	.container {
 		top: 0;

+ 19 - 17
pages/public/register.vue

@@ -213,7 +213,9 @@ export default {
         this.$queue.showToast("请输入手机号");
       } else if (phone.length !== 11) {
         this.$queue.showToast("请输入正确的手机号");
-      } else {
+      } else if(this.sendTime != '获取验证码'){
+		  return;
+	  }else {
         this.$queue.showLoading("正在发送验证码...");
         this.$Request.getT("/app/Login/sendMsg/" + phone + "/1").then((res) => {
           if (res.code === 0) {
@@ -332,20 +334,20 @@ export default {
                 res.user.avatar ? res.user.avatar : "../../static/logo.png"
               );
               this.getUserInfo();
-              setTimeout(function () {
-                // 这里判断一下看是否是第一次登录如果是就跳到引导页,如果不是就正常跳
-                // let firstLogin = uni.getStorageSync("firstLogin") || false;
-				console.log("userType:",res.user.userType)
-                if (!res.user.userType) {
-                  uni.navigateTo({
-                    url: "/pages/my/jobApplicant/guidePage",
-                  });
-                } else {
-                  uni.switchTab({
-                    url: "/pages/index/index",
-                  });
-                }
-              }, 1000);
+    //           setTimeout(function () {
+    //             // 这里判断一下看是否是第一次登录如果是就跳到引导页,如果不是就正常跳
+    //             // let firstLogin = uni.getStorageSync("firstLogin") || false;
+				// console.log("userType:",res.user.userType)
+    //             if (!res.user.userType) {
+    //               uni.navigateTo({
+    //                 url: "/pages/my/jobApplicant/guidePage",
+    //               });
+    //             } else {
+    //               uni.switchTab({
+    //                 url: "/pages/index/index",
+    //               });
+    //             }
+    //           }, 1000);
             } else {
               uni.hideLoading();
               uni.showModal({
@@ -416,8 +418,8 @@ export default {
           this.invitationCode = res.data.invitationCode;
           uni.setStorageSync("invitationCode", res.data.invitationCode);
           setTimeout(function () {
-            uni.switchTab({
-              url: "pages/my/jobApplicant/registerSuccess",//pages/my/jobApplicant/registerSuccess
+            uni.reLaunch({
+              url: "/pages/my/jobApplicant/registerSuccess",//pages/my/jobApplicant/registerSuccess
             });
           }, 1000);
 		  return

+ 1 - 0
static/images/filter.svg

@@ -0,0 +1 @@
+<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1764319656146" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="6920" xmlns:xlink="http://www.w3.org/1999/xlink" width="48" height="48"><path d="M548.8 959c-19.9 0-36-16.1-36-36V413.6c0-8.6 3.1-17 8.7-23.5l218-253h-565l200.8 254.2c5 6.4 7.8 14.2 7.8 22.3v312.6c0 19.9-16.1 36-36 36s-36-16.1-36-36V426.1L72 123.5c-8.6-10.8-10.2-25.6-4.2-38s18.6-20.3 32.4-20.3h717.9c14.1 0 26.9 8.2 32.7 21 5.9 12.8 3.7 27.8-5.5 38.5L584.8 427v496c0 19.9-16.1 36-36 36z" fill="#016bf6" p-id="6921"></path><path d="M923.4 521.6H710.1c-19.9 0-36-16.1-36-36s16.1-36 36-36h213.3c19.9 0 36 16.1 36 36s-16.1 36-36 36zM923.4 704.4H710.1c-19.9 0-36-16.1-36-36s16.1-36 36-36h213.3c19.9 0 36 16.1 36 36s-16.1 36-36 36z" fill="#016bf6" p-id="6922"></path></svg>

Some files were not shown because too many files changed in this diff