Преглед изворни кода

Merge remote-tracking branch 'origin/2025北京诚祥' into 2025北京诚祥

wangxy пре 2 месеци
родитељ
комит
5b676a0986

+ 12 - 0
api/jiazheng.js

@@ -96,6 +96,18 @@ export function getJiazhengZhiye(data = {}) {
 	})
 }
 
+export function getJiazhengZhiyeAll(data = {}) {
+	return request({
+		url: '/app/user/jiazheng/ops/zhiye/all',
+		headers: {
+			isToken: false
+		},
+		method: 'post',
+		data,
+		timeout: 20000
+	})
+}
+
 export function getJiazhengXueli(data = {}) {
 	return request({
 		url: '/app/user/jiazheng/ops/xueli',

+ 12 - 0
api/login.js

@@ -24,3 +24,15 @@ export function getConfig(data = {}) {
     timeout: 20000
   })
 }
+
+export function getVersion(data = {}) {
+  return request({
+    'url': '/common/app/version',
+    headers: {
+      isToken: false
+    },
+    method: 'post',
+    data,
+    timeout: 20000
+  })
+}

+ 6 - 1
common/styles/global/components.scss

@@ -478,4 +478,9 @@ margin-right: 18rpx;display: inline-block;vertical-align: middle;}
 	.not-confirm-btn{color: #666;}
 	.confirm-btn{border-left-color: #f0f0f0;border-left-style: solid;border-left-width: 1px;color: #3fd2a1;}
 	.code-img{width: 500rpx;height: 500rpx;display: block;margin: 0 auto;}
-}	
+}	
+.phone-tip-dialog{
+	width: 580rpx;border-radius: 12rpx;background-color: #fff;padding: 24rpx;
+	.tip-title{padding-top: 24rpx;font-size: 34rpx;color: #333;text-align: center;}
+	.tip-content{font-size: 32rpx;color: #666;margin:32rpx 30rpx 56rpx;line-height: 1.6;}
+}

+ 3 - 2
common/styles/global/pages.scss

@@ -238,8 +238,9 @@
 		width: 100%;
 		.ks-item-top {
 			display: flex;justify-content: space-between;margin-bottom: 20rpx;
-			.ks-name {font-size: 34rpx;color: #000;}
-			.ks-zyLevelName {font-size: 26rpx;padding: 4rpx 24rpx;border-radius: 4px;border: 1px solid #3fd2a1;color:#3fd2a1;}
+			.ks-name {font-size: 34rpx;color: #000;@include single-line-ellipsis();}
+			.ks-zyLevelName {font-size: 26rpx;padding: 4rpx 24rpx;border-radius: 4px;
+			border: 1px solid #3fd2a1;color:#3fd2a1;flex-shrink: 0;}
 		}
 		.ks-totalTm-row{display: flex;align-items: center;}
 		.ks-totalTm {font-size: 26rpx;color: #333;margin-bottom: 20rpx;line-height: 1;margin-left: 40rpx;}

+ 38 - 0
components/dialog/tipDialog.vue

@@ -0,0 +1,38 @@
+<template>
+	<uni-popup ref="tipPopup" :animation="false" :is-mask-click="false"
+	 mask-background-color="rgba(0, 0, 0, 0.4)">
+	 <view class="phone-tip-dialog">
+			<view class="common-body-box">
+				<view class="tip-title">{{title}}</view>
+				<view class="tip-content" :class="dialogContentClass">{{content}}</view>
+			</view>
+	 </view>
+	</uni-popup>
+</template>
+
+<script setup>
+	import { ref } from 'vue';
+	const props = defineProps({
+		title: {
+		  type: String,
+		  default: ''
+		},
+	  content: {
+	    type: String,
+		require: true,
+	    default: ''
+	  },
+	});
+	const tipPopup = ref(null); // 索引
+	const $emit = defineEmits(['confirm-btn'])
+	// 打开弹窗
+	function handleShow() {
+		tipPopup.value.open();
+	}
+	defineExpose({
+			handleShow
+		})
+</script>
+
+<style>
+</style>

+ 20 - 1
pages/Login/components/adminloginBox.vue

@@ -23,10 +23,12 @@
 		<!-- 已加密的:{{lliPassword}} -->
 		</view>
 		<passwordLli ref="passLLiRef" :password="password" @lli-password="onLliPassword" />
+		<tip-dialog ref="tipDialogRef" :title="tipTitle" :content="tipContent"></tip-dialog>
 	</view>
 </template>
 
 <script setup>
+	import {onShow} from '@dcloudio/uni-app';
 	import cacheManager from '@/utils/cacheManager.js'
 	import * as httpApi from "@/api/login.js"
 	import passwordLli from "@/components/password-lli/password-lli.vue";
@@ -34,6 +36,7 @@
 	import {toast} from "@/utils/common";
 	import {useIsCanBack} from "@/store/isCanBack.js"
 	import config from '../../../config.js'
+	import tipDialog from '@/components/dialog/tipDialog.vue';
 	
 	
 	const userName = ref('') // 用户名
@@ -45,7 +48,10 @@
 	const clearPwIcon= ref(false)
 	
 	const store = useIsCanBack();
-	const version = config.version;
+	const version = config.appInfo.version;
+	const tipDialogRef = ref(null);
+	const tipTitle = '升级提醒';
+	const tipContent = '您的APP不是最新版本,请升级至最新版本。';
 	
 	// 加密
 	function handleUpdateLLiPassword() {
@@ -134,6 +140,19 @@
           url: `/pages/admin/ShouYe/shouye`
         })
 		}
+		
+	function getLoginInit(){
+		httpApi.getVersion({}).then(res => {
+			console.log(version,res,'version+res');
+			if(version!=res.data.version){
+				tipDialogRef.value.handleShow();
+			}
+		})
+	}
+	
+	onShow(() => {
+		// getLoginInit()
+	})	
 </script>
 
 <style>

+ 32 - 13
pages/admin/Jiazheng/index.vue

@@ -7,7 +7,7 @@
 		</view>
 		<view class="jiazheng-search-box">
 			<view @click.stop="clickAlltype" class="select-item-box">
-				<text class="select-text">{{data.leixing}}</text>
+				<text class="select-text">{{data.zyName}}</text>
 				<icon :class="allJtClass" />
 			</view>
 
@@ -35,7 +35,8 @@
 		</view>
 		<view>
 			<scroll-view scroll-y="true" refresher-enabled="true" :refresher-triggered="data.loading"
-				:refresher-threshold="50" refresher-background="transparent" @refresherrefresh="onRefresh"
+				:refresher-threshold="50" @scrolltolower="onScrolltolower" refresher-background="transparent" @refresherrefresh="onRefresh"
+		
 				class="jz-scroll-view">
 				<uni-list class="admin-list-box">
 					<view class="jz-new-btn-box">
@@ -67,8 +68,9 @@
 									<view class="content-text-row">
 										{{item.jiguanShengName === item.jiguanShiName ? item.jiguanShengName  : `${item.jiguanShengName} ${item.jiguanShiName}`}}人
 									</view>
-									<view class="content-lx-box">
-										<view class="content-lx-item" v-for="item2 in item.leixing" :key="item2">
+						
+									<view v-if="item.zyNames.length>0"  class="content-lx-box">
+										<view class="content-lx-item" v-for="item2 in item.zyNames" :key="item2">
 											{{item2}}
 										</view>
 									</view>
@@ -101,6 +103,7 @@
 	import {
 		getJiazhengList,
 		getJiazhengJineng,
+		getJiazhengZhiyeAll,
 		getJiazhengLeixing
 	} from "@/api/jiazheng.js"
 	import dataChecked from './common/dataChecked.vue';
@@ -111,7 +114,8 @@
 	const shareRef = ref(null);
 	let allType = ref([])
 	let data = reactive({
-		leixing: '全部类型',
+		zyId: '',
+		zyName: '全部职业',
 		page: 0,
 		size: 10,
 		realName: '',
@@ -170,6 +174,11 @@
 		refreshData()
 	}
 
+	function onScrolltolower(){
+		getMore()
+	}
+	
+	
 	function luruTimeClick() {
 		data.sortType = 2
 		const isFirst = isFirstClickluru.value == 'true';
@@ -308,7 +317,8 @@
 
 	function selectChangeSkill(item) {
 		if (item.length > 0) {
-			data.leixing = item[0].name
+			data.zyId = item[0].id
+			data.zyName = item[0].name
 			console.log('selectChangeSkill', item);
 			data.page = 0;
 			refreshData()
@@ -317,7 +327,7 @@
 
 	function refreshData() {
 		const opt = {
-			"leixing": data.leixing == '全部类型' ? '' : data.leixing,
+			"zyId": data.zyId == '全部职业' ? '' : data.zyId,
 			"page": 1,
 			"realName": data.realName,
 			"size": 10,
@@ -339,7 +349,11 @@
 				const newItem = {
 					...item
 				};
-				newItem.leixing = item.leixing.split(',');
+				if(item.zyNames ==''){
+					newItem.zyNames = []
+				}else{
+				newItem.zyNames = item.zyNames.split(',');
+				}
 				return newItem;
 			})
 			data.loading = false;
@@ -359,7 +373,7 @@
 
 	function getMore() {
 		const opt = {
-			"leixing": data.leixing == '全部类型' ? '' : data.leixing,
+			"zyId": data.zyId == '全部职业' ? '' : data.zyId,
 			"page": 1,
 			"realName": data.realName,
 			"size": 10,
@@ -379,7 +393,11 @@
 				const newItem = {
 					...item
 				};
-				newItem.leixing = item.leixing.split(',');
+				if(item.zyNames ==''){
+					newItem.zyNames = []
+				}else{
+				newItem.zyNames = item.zyNames.split(',');
+				}
 				return newItem;
 			})
 			console.log('data.list', data.list);
@@ -400,9 +418,10 @@
 
 	function getLeixing() {
 		let req = {}
-		getJiazhengJineng(req).then(res => {
-			res.data.unshift("全部类型");
-			allType = dataConversionObject(res.data)
+		getJiazhengZhiyeAll(req).then(res => {
+			res.data.unshift({id:'',name:'全部职业'});
+			allType = res.data
+		//	allType = dataConversionObject(res.data)
 			console.log('allType', allType);
 		})
 	}

+ 6 - 3
pages/admin/Jiazheng/jiazhengUserInfo.vue

@@ -26,9 +26,9 @@
 			</view>
 
 			<view class="jianli-body-box">
-				<view class="leixing-row">
-					<view class="jbxx-label">类 型:</view>
-					<text class="leixing-content">{{jianliInfo.leixing}}</text>
+				<view v-if="jianliInfo.zyNames" class="leixing-row">
+					<view class="jbxx-label">职 业:</view>
+					<text class="leixing-content">{{jianliInfo.zyNames}}</text>
 				</view>
 				<view class="body-jbxx-box">
 					<view class="jbxx-title">基本信息</view>
@@ -133,6 +133,9 @@
 						this.jianliInfo = {
 							...res.data
 						};
+						// if(this.jianliInfo.zyNames){
+							
+						// }
 					}
 				})
 			},

+ 21 - 1
pages/admin/ShouYe/shouye.vue

@@ -68,6 +68,7 @@
 	</view>	
 	<!-- 页面底端 -->
 	<customTabbarAdminVue :current-tab="0"></customTabbarAdminVue>
+	<tip-dialog ref="tipDialogRef" :title="tipTitle" :content="tipContent"></tip-dialog>
   </view>
 </template>
 
@@ -76,7 +77,14 @@ import {onLoad,onShow} from '@dcloudio/uni-app';
 import {reactive,ref} from "vue";
 import customTabbarAdminVue from "@/components/custom-tabbar/custom-tabbar-admin.vue";
 import {getAppNoticeList,getAppNoticeWait,getGlIndexInfo,getIndexKechengList} from '@/api/shouye.js'
-
+import tipDialog from '@/components/dialog/tipDialog.vue';
+import config from '../../../config.js'
+import * as httpApi from "@/api/login.js"
+const version = config.appInfo.version;
+const tipDialogRef = ref(null);
+const tipTitle = '升级提醒';
+const tipContent = '您的APP不是最新版本,请升级至最新版本。';
+	
 const tjBtn = ref(1);
 const tzNum = ref(0);
 const tzContent = ref('');
@@ -208,5 +216,17 @@ function tjBtnClick(data){
 				break;
 		}
 	}
+	function getLoginInit(){
+			httpApi.getVersion({}).then(res => {
+				console.log(version,res,'version+res');
+				if(version!=res.data.version){
+					tipDialogRef.value.handleShow();
+				}
+			})
+		}
+		
+		onShow(() => {
+			// getLoginInit()
+		})
 </script>
 

+ 3 - 3
pages/client/jiazheng/shareImage.vue

@@ -23,9 +23,9 @@
 			</view>
 
 			<view class="jianli-body-box">
-				<view class="leixing-row">
-					<view class="jbxx-label">类 型:</view>
-					<text class="leixing-content">{{jianliInfo.leixing}}</text>
+				<view v-if="jianliInfo.zyNames" class="leixing-row">
+					<view class="jbxx-label">职 业:</view>
+					<text class="leixing-content">{{jianliInfo.zyNames}}</text>
 				</view>
 				<view class="body-jbxx-box">
 					<view class="jbxx-title">基本信息</view>