Merge branch 'main' into yxl

This commit is contained in:
2026-01-22 14:25:27 +08:00
59 changed files with 3563 additions and 490 deletions

View File

@@ -22,9 +22,65 @@
@click="getFair('refresh')"></uni-icons>
<input class="input" placeholder="招聘会" placeholder-class="inputplace"
v-model="pageState.jobFairTitle" />
<view class="btn-feel" v-show="state.current != 3" @click="openFilter">筛选</view>
</view>
</view>
<uni-popup
ref="selectFilterModel"
type="bottom"
borderRadius="10px 10px 0 0"
background-color="#FFFFFF"
class="popup-fix"
>
<view class="popup-content">
<view class="popup-list">
<view class="content-wrapper">
<!-- 左侧筛选类别 -->
<!-- <scroll-view class="filter-nav" scroll-y>
<view
v-for="(item, index) in filterOptions"
:key="index"
class="nav-item button-click"
:class="{ active: activeTab === item.key }"
@click="scrollTo(item.key)"
>
{{ item.label }}
</view>
</scroll-view> -->
<!-- 右侧筛选内容 -->
<scroll-view class="filter-content" :scroll-into-view="activeTab" scroll-y>
<view v-for="(item, index) in filterOptions" :key="index">
<view class="content-item">
<view class="item-title" :id="item.key">{{ item.label }}</view>
<radio-group class="check-content" @change="handleSelect">
<label
v-for="option in item.options"
:key="option.value"
class="checkbox-item button-click"
:class="{
checkedstyle: selectedValues === String(option.value),
}"
>
<radio
style="display: none"
:value="String(option.value)"
:checked="selectedValues === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
</view>
</scroll-view>
</view>
</view>
<view class="popup-bottom">
<view class="btn-cancel btn-feel" @click="cleanup">重置</view>
<view class="btn-confirm btn-feel" @click="confirm">确认</view>
</view>
</view>
</uni-popup>
<!-- 主体内容区域 -->
<view class="container-main">
<scroll-view scroll-y class="main-scroll" :class="{fullHeightScroll:!showTabar}" @scrolltolower="handleScrollToLower">
@@ -151,10 +207,57 @@
onShow(() => {
// 更新自定义tabbar选中状态
tabbarManager.updateSelected(1);
getoptions();
});//
//筛选
const filterOptions = ref([]);
const activeTab = ref('');
const selectFilterModel = ref(null);
const selectedValues = ref(null);
function openFilter() {
selectFilterModel.value?.open();
}
const scrollTo = (key) => {
activeTab.value = key;
};
const handleSelect = (e) => {
selectedValues.value = e.detail.value
};
function cleanup(){
selectedValues.value = null
confirm()
}
function confirm(){
getFair("refresh");
selectFilterModel.value?.close();
}
function getoptions() {
let headers = {
'Content-Type': 'application/x-www-form-urlencoded',
}
let params = {
dictType:'administrative_division',
dictParentValue:'653100000000',
childFlag:'1',
}
filterOptions.value = [{
label: '所在区域',
key: 'area',
options: []
}];
$api.myRequest('/system/public/dict/data/getByParentValue',params,'POST',9100,headers).then(res=>{
if (res.code == 200) {
filterOptions.value[0].options = res.data.map(item=>{
return {
label: item.dictLabel,
value: item.dictValue,
}
})
}
})
activeTab.value = 'area';
}
async function thirdLogin(needToast){
let form={}
if (uni.getStorageSync('userInfo') && (uni.getStorageSync('userInfo').isCompanyUser=='1' || uni.getStorageSync('userInfo').isCompanyUser=='2')) {
@@ -339,11 +442,27 @@
// 正确映射响应为用户信息(优先使用 data 字段)
const data = resData?.data ?? resData;
userInfo.value = data || {};
if(data?.info?.entCreditCode && data?.info?.userId){
updateEnterpriseId({
unifiedSocialCreditCode: data?.info?.entCreditCode,
userId: data?.info?.userId,
})
}
getFair("refresh");
return userInfo.value;
});
}
function updateEnterpriseId(params){
const headers = {
'Content-Type':'application/json'
}
return $api.myRequest("/jobfair/public/job-fair-sign-up-enterprise/update-enterprise-id", params, "POST", 9100, headers).then((resData) => {
if(resData.code == 200 && resData.data !=0){
state.current = 3
getMyFair("refresh");
}
});
}
function getMyFair(type = "add") {
if (type === "refresh") {
pageState.pageNum = 1;
@@ -404,6 +523,7 @@
pageSize: pageState.pageSize,
jobFairTitle: pageState.jobFairTitle,
jobFairType: state.current,
dictValue: selectedValues.value,
};
if (isLogin.value) {
if (userInfo.value.userType == "ent") {
@@ -561,7 +681,168 @@
return dates;
}
</script>
<style lang="scss" scoped>
.popup-fix {
z-index: 9999 !important;
}
.popup-content {
color: #000000;
height: 70vh;
padding-bottom: 20rpx;
}
.popup-bottom {
padding: 40rpx 28rpx 20rpx 28rpx;
display: flex;
justify-content: space-between;
.btn-cancel {
font-weight: 400;
font-size: 32rpx;
color: #666d7f;
line-height: 90rpx;
width: 33%;
min-width: 222rpx;
height: 90rpx;
background: #f5f5f5;
border-radius: 12rpx 12rpx 12rpx 12rpx;
text-align: center;
}
.btn-confirm {
font-weight: 400;
font-size: 32rpx;
color: #ffffff;
text-align: center;
width: 67%;
height: 90rpx;
margin-left: 28rpx;
line-height: 90rpx;
background: #256bfa;
min-width: 444rpx;
border-radius: 12rpx 12rpx 12rpx 12rpx;
}
}
.popup-list {
display: flex;
flex-direction: row;
flex-wrap: nowrap;
align-items: center;
justify-content: space-evenly;
height: calc(77vh - 100rpx - 150rpx);
overflow: hidden;
.picker-view {
width: 100%;
height: 500rpx;
margin-top: 20rpx;
.uni-picker-view-mask {
background: rgba(0, 0, 0, 0);
}
.item {
line-height: 84rpx;
height: 84rpx;
text-align: center;
font-weight: 400;
font-size: 32rpx;
color: #cccccc;
}
.item-active {
color: #333333;
}
.uni-picker-view-indicator:after {
border-color: #e3e3e3;
}
.uni-picker-view-indicator:before {
border-color: #e3e3e3;
}
}
// .list {
// .row {
// font-weight: 400;
// font-size: 32rpx;
// color: #333333;
// line-height: 84rpx;
// text-align: center;
// }
// }
}
.content-wrapper {
flex: 1;
display: flex;
overflow: hidden;
height: 100%;
}
.filter-nav {
width: 200rpx;
background-color: #ffffff;
.nav-item {
height: 100rpx;
line-height: 100rpx;
text-align: center;
font-weight: 400;
font-size: 28rpx;
color: #666d7f;
&.active {
font-weight: 500;
font-size: 28rpx;
color: #256bfa;
}
}
}
.filter-content {
flex: 1;
padding: 20rpx;
background-color: #f6f6f6;
.content-item {
margin-top: 30rpx;
.item-title {
font-weight: 400;
font-size: 28rpx;
color: #333333;
margin-bottom: 15rpx;
}
}
.content-item:first-child {
margin-top: 0rpx;
}
.check-content {
display: grid;
gap: 16rpx;
grid-template-columns: repeat(auto-fill, minmax(300rpx, 1fr));
place-items: stretch;
.checkbox-item {
display: flex;
align-items: center;
text-align: center;
background-color: #d9d9d9;
min-width: 0;
padding: 0 10rpx;
height: 80rpx;
background: #e8eaee;
border-radius: 12rpx 12rpx 12rpx 12rpx;
.option-label {
font-size: 28rpx;
width: 100%;
white-space: nowrap;
overflow: hidden;
}
}
.checkedstyle {
height: 76rpx;
background: rgba(37, 107, 250, 0.06);
border-radius: 12rpx 12rpx 12rpx 12rpx;
border: 2rpx solid #256bfa;
color: #256bfa;
}
}
}
</style>
<style scoped lang="stylus">
.app-custom-root {
position: fixed;
@@ -623,6 +904,8 @@
padding: 0 24rpx;
width: calc(100% - 48rpx);
position: relative;
display: flex;
align-items: center;
}
.app-container .container-header .header-input .iconsearch {
@@ -638,6 +921,7 @@
background: #ffffff;
border-radius: 75rpx;
font-size: 28rpx;
flex:1
}
.app-container .container-header .header-input .inputplace {
@@ -645,7 +929,13 @@
font-size: 28rpx;
color: #b5b5b5;
}
.app-container .container-header .header-input .btn-feel {
font-weight: 400;
font-size: 28rpx;
text-align: center;
color: #484444;
width: 80rpx;
}
.app-container .container-header .header-date {
padding: 28rpx;
display: flex;

View File

@@ -134,9 +134,16 @@
<view class="message">{{ recognizedText }} {{ lastFinalText }}</view>
</view>
<view v-if="isTyping" class="self">
<text class="message msg-loading">
<span class="ai-loading"></span>
</text>
<view class="message msg-loading">
<div class="loading-content">
<span class="ai-loading">
<span></span>
<span></span>
<span></span>
</span>
<text class="loading-text">AI正在思考中...</text>
</div>
</view>
</view>
</view>
</scroll-view>
@@ -551,7 +558,9 @@ const scrollToBottom = throttle(function () {
}, 500);
function getGuess() {
$api.chatRequest('/guest', { sessionId: chatSessionID.value }, 'POST').then((res) => {
// $api.chatRequest('/guest', { sessionId: chatSessionID.value }, 'POST').then((res) => {
$api.chatRequest('/guest', undefined, 'POST').then((res) => {
console.log('getGuess ---- res:', res);
guessList.value = res.data;
showGuess.value = true;
nextTick(() => {
@@ -804,22 +813,22 @@ function refreshMarkdown(index) {
}
const jobSearchQueries = [
'青岛有哪些薪资 12K 以上的岗位适合我?',
'青岛 3 年工作经验能找到哪些 12K 以上的工作?',
'青岛哪些公司在招聘,薪资范围在 12K 以上?',
'青岛有哪些企业提供 15K 以上的岗位?',
'青岛哪些公司在招 3-5 年经验的岗位?',
'我有三年的工作经验,能否推荐一些适合我的青岛的国企 岗位?',
'青岛国企目前在招聘哪些岗位?',
'青岛有哪些适合 3 年经验的国企岗位?',
'青岛国企招聘的岗位待遇如何?',
'青岛国企岗位的薪资水平是多少?',
'青岛哪些国企支持双休 & 五险一金完善?',
'青岛有哪些公司支持远程办公?',
'青岛有哪些外企的岗位,薪资 12K 以上的多吗?',
'青岛哪些企业在招聘 Web3.0 相关岗位?',
'青岛哪些岗位支持海外远程?薪资如何?',
'青岛招聘 AI/大数据相关岗位的公司有哪些?',
'喀什地区有哪些薪资 12K 以上的岗位适合我?',
'喀什地区 3 年工作经验能找到哪些 12K 以上的工作?',
'喀什地区哪些公司在招聘,薪资范围在 12K 以上?',
'喀什地区有哪些企业提供 15K 以上的岗位?',
'喀什地区哪些公司在招 3-5 年经验的岗位?',
'我有三年的工作经验,能否推荐一些适合我的喀什地区的国企 岗位?',
'喀什地区国企目前在招聘哪些岗位?',
'喀什地区有哪些适合 3 年经验的国企岗位?',
'喀什地区国企招聘的岗位待遇如何?',
'喀什地区国企岗位的薪资水平是多少?',
'喀什地区哪些国企支持双休 & 五险一金完善?',
'喀什地区有哪些公司支持远程办公?',
'喀什地区有哪些外企的岗位,薪资 12K 以上的多吗?',
'喀什地区哪些企业在招聘 Web3.0 相关岗位?',
'喀什地区哪些岗位支持海外远程?薪资如何?',
'喀什地区招聘 AI/大数据相关岗位的公司有哪些?',
];
function changeQueries(value) {
@@ -1003,12 +1012,26 @@ image-margin-top = 40rpx
.messageNull
display: none
.msg-loading{
background: transparent;
font-size: 24rpx;
color: #8f8d8e;
background: #F6F6F6;
border-radius: 20rpx 0 20rpx 20rpx;
padding: 20rpx;
width: fit-content;
display: flex;
align-items: flex-end;
justify-content: flex-start;
align-items: center;
justify-content: center;
.loading-content{
display: flex;
align-items: center;
justify-content: center;
gap: 16rpx;
}
.loading-text{
font-size: 28rpx;
color: #666666;
font-weight: 500;
}
}
.loaded{
padding-left: 20rpx
@@ -1248,25 +1271,55 @@ image-margin-top = 40rpx
.file-border
width: 160rpx !important;
@keyframes ai-circle {
0% {
-webkit-transform: rotate(0);
transform: rotate(0);
/* 更美观的loading动画 - 兼容H5和小程序 */
@keyframes ai-loading-dots {
0%, 20%, 80%, 100% {
transform: scale(1);
opacity: 0.6;
}
100% {
-webkit-transform: rotate(360deg);
transform: rotate(360deg);
40% {
transform: scale(1.2);
opacity: 1;
}
}
.ai-loading
/* 重置默认样式 */
.ai-loading {
display: inline-flex;
vertical-align: middle;
width: 28rpx;
height: 28rpx;
background: 0 0;
align-items: center;
justify-content: center;
gap: 8rpx;
width: auto;
height: auto;
background: transparent;
border: none;
border-radius: 0;
padding: 0;
margin: 0;
}
/* 三个点的样式 - 使用标准CSS语法不使用嵌套 */
.ai-loading span {
display: inline-block;
width: 12rpx;
height: 12rpx;
border-radius: 50%;
border: 4rpx solid;
border-color: #e5e5e5 #e5e5e5 #e5e5e5 #8f8d8e;
-webkit-animation: ai-circle 1s linear infinite;
animation: ai-circle 1s linear infinite;
background-color: #256BFA;
animation: ai-loading-dots 1.4s ease-in-out infinite both;
margin: 0;
padding: 0;
}
/* 为每个点设置不同的动画延迟 */
.ai-loading span:nth-child(1) {
animation-delay: -0.32s;
}
.ai-loading span:nth-child(2) {
animation-delay: -0.16s;
}
.ai-loading span:nth-child(3) {
animation-delay: 0s;
}
</style>

425
pages/city-select/index.vue Normal file
View File

@@ -0,0 +1,425 @@
<template>
<view class="city-select-container">
<!-- 顶部导航栏 -->
<!-- <view class="nav-bar">
<view class="nav-left" @click="navBack">
<uni-icons type="left" size="24" color="#333"></uni-icons>
</view>
<view class="nav-title">选择城市</view>
<view class="nav-right"></view>
</view> -->
<!-- 搜索框 -->
<view class="search-box">
<uni-icons class="search-icon" type="search" size="20" color="#999"></uni-icons>
<input
class="search-input"
placeholder="搜索城市名/拼音"
placeholder-style="color: #999"
v-model="searchText"
@input="handleSearch"
>
</view>
<!-- 定位城市 -->
<!-- <view class="location-section">
<view class="section-title">定位城市</view>
<view class="location-city" :class="{ active: selectedCity.code === locationCity.code }" @click="selectCity(locationCity)">
{{ locationCity.name }}
</view>
</view> -->
<!-- 热门城市 -->
<!-- <view class="hot-section">
<view class="section-title">热门城市</view>
<view class="hot-cities">
<view
class="city-item"
:class="{ active: selectedCity.code === item.code }"
v-for="item in hotCities"
:key="item.code"
@click="selectCity(item)"
>
{{ item.name }}
</view>
</view>
</view> -->
<!-- 城市数量统计 -->
<!-- <view class="city-count" v-if="allCities.length > 0">
共找到 {{ allCities.length }} 个城市
</view> -->
<!-- 城市列表 -->
<view class="city-list-section">
<scroll-view
class="city-list-content"
scroll-y
:scroll-into-view="currentScrollId"
:scroll-with-animation="true"
>
<view
class="city-group"
v-for="group in cityGroups"
:key="group.letter"
:id="`city-group-${group.letter}`"
>
<view class="group-title">{{ group.letter }}</view>
<view
class="city-item"
:class="{ active: selectedCity.code === item.code }"
v-for="item in group.cities"
:key="item.code"
@click="selectCity(item)"
>
{{ item.name }}
</view>
</view>
</scroll-view>
<!-- 右侧字母索引 -->
<view class="letter-index">
<view
class="letter-item"
v-for="letter in letters"
:key="letter"
@click="scrollToLetter(letter)"
:class="{ active: currentLetter === letter }"
>
{{ letter }}
</view>
</view>
</view>
</view>
</template>
<script setup>
import { ref, reactive, onMounted, computed, inject } from 'vue';
const { $api, navTo } = inject('globalFunction');
// 搜索文本
const searchText = ref('');
// 定位城市
const locationCity = ref({ code: '110100', name: '北京' });
// 选中的城市
const selectedCity = ref({ code: '', name: '' });
// 当前显示的字母
const currentLetter = ref('');
// 当前滚动到的城市组ID
const currentScrollId = ref('');
// 城市数据
const allCities = ref([]);
// 字母列表
const letters = ref(['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z']);
// 按字母分组的城市
const cityGroups = computed(() => {
const groups = {};
const filteredCities = allCities.value.filter(city => {
if (!searchText.value) return true;
return city.name.includes(searchText.value) || city.pinyin?.includes(searchText.value.toUpperCase());
});
console.log('过滤后用于分组的城市:', filteredCities);
// 初始化字母分组
letters.value.forEach(letter => {
groups[letter] = { letter, cities: [] };
});
// 将城市分配到对应字母组
filteredCities.forEach(city => {
const firstLetter = city.pinyin || '#';
// 如果字母不在预定义列表中,将其添加到分组中
if (!groups[firstLetter]) {
groups[firstLetter] = { letter: firstLetter, cities: [] };
}
groups[firstLetter].cities.push(city);
});
const result = Object.values(groups).filter(group => group.cities.length > 0);
// 对城市组进行排序
result.sort((a, b) => {
// '#' 符号应该排在最前面
if (a.letter === '#') return -1;
if (b.letter === '#') return 1;
// 其他字母按字母顺序排序
return a.letter.localeCompare(b.letter);
});
console.log('最终分组结果:', result);
return result;
});
// 获取城市数据
const getCityData = async () => {
try {
// 直接获取所有城市数据,新接口已经返回了所有层级的数据
const res = await $api.createRequest('/cms/dict/sysarea/listCity', {});
console.log('城市数据接口返回:', res);
if (res.code === 200 && res.data) {
console.log('原始城市数据:', res.data);
// 显示接口返回的所有城市数据
const filteredCities = res.data;
console.log('过滤后城市数据:', filteredCities);
// 直接使用后端返回的zm字段作为拼音首字母并转换为大写
allCities.value = filteredCities.map(city => ({
...city,
pinyin: (city.zm || '#').toUpperCase()
}));
console.log('使用后端zm字段的城市数据:', allCities.value);
// 按拼音首字母排序
allCities.value.sort((a, b) => {
// 首先按拼音首字母排序
if (a.pinyin !== b.pinyin) {
// '#' 符号应该排在最前面
if (a.pinyin === '#') return -1;
if (b.pinyin === '#') return 1;
return a.pinyin.localeCompare(b.pinyin);
}
// 首字母相同时,按城市名称排序
return a.name.localeCompare(b.name);
});
}
} catch (error) {
console.error('获取城市数据失败:', error);
}
};
// 获取拼音首字母(使用更准确的映射表)
const getPinyinFirstLetter = (name) => {
const firstChar = name.charAt(0);
// 查找对应的拼音首字母
for (const [letter, chars] of Object.entries(pinyinMap)) {
if (chars.includes(firstChar)) {
return letter;
}
}
// 如果没有找到,返回#
return '#';
};
// 处理搜索
const handleSearch = () => {
// 搜索逻辑已在cityGroups计算属性中处理
};
// 选择城市
const selectCity = (city) => {
selectedCity.value = city;
// 返回上一页并传递选择的城市
uni.navigateBack({
delta: 1,
success: () => {
// 发送事件通知首页选择了城市
uni.$emit('citySelected', city);
}
});
};
// 滚动到指定字母
const scrollToLetter = (letter) => {
currentLetter.value = letter;
// 更新滚动ID触发scroll-view滚动
currentScrollId.value = `city-group-${letter}`;
};
// 返回上一页
const navBack = () => {
uni.navigateBack({ delta: 1 });
};
// 组件挂载时获取城市数据
onMounted(() => {
getCityData();
});
</script>
<style scoped>
.city-select-container {
background-color: #f5f5f5;
min-height: 100vh;
padding-top: 16px;
}
/* 导航栏 */
.nav-bar {
display: flex;
align-items: center;
justify-content: space-between;
height: 44px;
padding: 0 16px;
background-color: #fff;
border-bottom: 1px solid #e5e5e5;
}
.nav-left,
.nav-right {
width: 40px;
height: 40px;
display: flex;
align-items: center;
justify-content: center;
}
.nav-title {
font-size: 18px;
font-weight: 500;
color: #333;
}
/* 搜索框 */
.search-box {
display: flex;
align-items: center;
margin: 12px 16px;
padding:8px 16px;
background-color: #fff;
border-radius: 20px;
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}
.search-icon {
margin-right: 8px;
}
.search-input {
flex: 1;
font-size: 14px;
color: #333;
border: none;
outline: none;
}
/* 定位城市 */
.location-section {
padding: 16px;
background-color: #fff;
margin-bottom: 8px;
}
.section-title {
font-size: 14px;
color: #666;
margin-bottom: 12px;
}
.location-city {
display: inline-block;
padding: 8px 20px;
background-color: #f0f9ff;
color: #007aff;
border-radius: 20px;
font-size: 14px;
}
.location-city.active {
background-color: #007aff;
color: #fff;
}
/* 热门城市 */
.hot-section {
padding: 16px;
background-color: #fff;
margin-bottom: 8px;
}
.city-count {
padding: 0 16px 12px;
background-color: #fff;
font-size: 12px;
color: #999;
margin-bottom: 8px;
}
.hot-cities {
display: flex;
flex-wrap: wrap;
gap: 12px;
}
.city-item {
padding: 8px 20px;
background-color: #f5f5f5;
color: #333;
border-radius: 20px;
font-size: 14px;
}
.city-item.active {
background-color: #007aff;
color: #fff;
}
/* 城市列表 */
.city-list-section {
display: flex;
background-color: #fff;
height: calc(100vh - 180px);
}
.city-list-content {
flex: 1;
overflow-y: auto;
}
.city-group {
padding: 0 16px;
}
.group-title {
font-size: 14px;
color: #666;
margin: 12px 0 8px 0;
padding-left: 4px;
}
.city-list-content .city-item {
display: block;
padding: 12px 4px;
margin-bottom: 0;
background-color: transparent;
border-radius: 0;
border-bottom: 1px solid #f0f0f0;
}
.city-list-content .city-item.active {
background-color: transparent;
color: #007aff;
}
/* 右侧字母索引 */
.letter-index {
width: 30px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
background-color: #f5f5f5;
}
.letter-item {
width: 24px;
height: 20px;
display: flex;
align-items: center;
justify-content: center;
font-size: 12px;
color: #666;
margin: 2px 0;
}
.letter-item.active {
color: #007aff;
font-weight: bold;
}
</style>

View File

@@ -268,11 +268,11 @@ const openSelectPopup = (config) => {
// #endif
};
const tabCurrent = ref(1);
const salay = [2, 5, 10, 15, 20, 25, 30, 50, 80, 100];
const salay = [2000, 5000, 10000, 15000, 20000, 25000, 30000, 50000, 80000, 100000];
const state = reactive({
station: [],
stationCateLog: 1,
lfsalay: [2, 5, 10, 15, 20, 25, 30, 50],
lfsalay: [2000, 5000, 10000, 15000, 20000, 25000, 30000, 50000],
risalay: JSON.parse(JSON.stringify(salay)),
areaText: '',
educationText: '',
@@ -614,10 +614,10 @@ function changeSalay() {
title: '薪资',
maskClick: true,
data: [state.lfsalay, state.risalay],
unit: 'k',
unit: '',
success: (_, [min, max]) => {
fromValue.salaryMin = min.value * 1000;
fromValue.salaryMax = max.value * 1000;
fromValue.salaryMin = min.value;
fromValue.salaryMax = max.value;
state.salayText = `${fromValue.salaryMin}-${fromValue.salaryMax}`;
},
change(e) {

View File

@@ -75,15 +75,15 @@
<!-- H5端专用按钮 -->
<!-- #ifdef H5 -->
<view class="h5-action-buttons" v-if="shouldShowJobSeekerContent">
<view class="h5-action-btn press-button" @click="handleH5SalaryClick">
<!-- <view class="h5-action-btn press-button" @click="handleH5SalaryClick">
<view class="btn-text">薪酬信息</view>
</view>
<view class="h5-action-btn press-button" @click="handleServiceClick('resume-creation')">
</view> -->
<view class="h5-action-btn press-button" @click="handelGoResumeGuide()">
<view class="btn-text">简历指导</view>
</view>
</view>
<!-- #endif -->
<!-- 服务功能网格 -->
<!-- #ifndef H5 -->
<view class="service-grid" v-if="shouldShowJobSeekerContent">
@@ -148,12 +148,12 @@
</view>
<view class="service-title">职业规划推荐</view>
</view>
<view class="service-item press-button" @click="handleSalaryInfoClick">
<!-- <view class="service-item press-button" @click="handleSalaryInfoClick">
<view class="service-icon service-icon-12">
<span style="display:block;width:40rpx;height:40rpx;border-radius:100%;border:4rpx #ffffff solid;line-height:40rpx;text-align:center;"></span>
</view>
<view class="service-title">薪酬信息</view>
</view>
</view> -->
<view class="service-item press-button" @click="handleJobFairClick">
<view class="service-icon service-icon-1">
<uni-icons type="shop" size="32" color="#FFFFFF"></uni-icons>
@@ -166,6 +166,25 @@
</view>
<view class="service-title">帮扶</view>
</view>
<view class="service-item press-button" @click="handleNoticeClick">
<view class="service-icon service-icon-10">
<uni-icons type="sound" size="32" color="#FFFFFF"></uni-icons>
</view>
<view class="service-title">培训评价公告</view>
</view>
<view class="service-item press-button" @click="handleInstitutionClick('training')">
<view class="service-icon service-icon-6">
<uni-icons type="map-pin-ellipse" size="32" color="#FFFFFF"></uni-icons>
<!-- <image class="service-icon-img" src="/static/icon/pxjgxx.png" mode="aspectFit"></image> -->
</view>
<view class="service-title">培训机构信息</view>
</view>
<view class="service-item press-button" @click="handleInstitutionClick('evaluate')">
<view class="service-icon service-icon-7">
<IconfontIcon name="suzhicepingtiku" :size="48" color="#FFFFFF" />
</view>
<view class="service-title">评价机构信息</view>
</view>
</view>
<!-- #endif -->
</view>
@@ -231,10 +250,15 @@
</view>
</view>
</scroll-view>
<view class="jobs-add button-click" @click="navTo('/packageA/pages/addPosition/addPosition')">
<uni-icons class="iconsearch" color="#666D7F" type="plusempty" size="18"></uni-icons>
<text>添加</text>
</view>
<view class="jobs-add button-click" @click="navTo('/pages/city-select/index')" style="padding-right:0;">
<text>{{ selectedCity.name || '地区' }}</text>
<image class="right-sx" :class="{ active: showFilter }" src="@/static/icon/shaixun.png"></image>
</view>
</view>
<view class="filter-bottom">
<view class="btm-left">
@@ -298,7 +322,7 @@
<view class="falls-card-company" v-show="isShowJw !== 3">
{{ config.appInfo.areaName }}
<!-- {{ job.jobLocation }} -->
<dict-Label dictType="area" :value="job.jobLocationAreaCode"></dict-Label>
<dict-Label dictType="jobLocationAreaCode" :value="job.jobLocationAreaCode"></dict-Label>
</view>
<view class="falls-card-pepleNumber">
<view>
@@ -375,7 +399,7 @@
<view class="falls-card-company" v-show="isShowJw !== 3">
{{ config.appInfo.areaName }}
<!-- {{ job.jobLocation }} -->
<dict-Label dictType="area" :value="job.jobLocationAreaCode"></dict-Label>
<dict-Label dictType="jobLocationAreaCode" :value="job.jobLocationAreaCode"></dict-Label>
</view>
<view class="falls-card-pepleNumber">
<view>
@@ -590,6 +614,14 @@ const wxAuthLoginRef = ref(null);
const state = reactive({
tabIndex: 'all',
});
//帮扶模块跳转
const helpClick = () => {
navTo('/packageB/priority/helpFilter');
};
//招聘会模块跳转
const handleJobFairClick = () => {
navTo('/pages/careerfair/careerfair');
};
const list = ref([]);
const pageState = reactive({
page: 0,
@@ -604,17 +636,20 @@ const inputText = ref('');
const showFilter = ref(false);
const selectFilterModel = ref(null);
const showModel = ref(false);
// 选中的城市
const selectedCity = ref({ code: '', name: '' });
const rangeOptions = ref([
{ value: 0, text: '推荐' },
{ value: 1, text: '最热' },
{ value: 2, text: '最新发布' },
{ value: 3, text: '疆外' },
{ value: 4, text: '零工市场' }
]);
const isLoaded = ref(false);
const isInitialized = ref(false); // 添加初始化标志
const { columnCount, columnSpace } = useColumnCount(() => {
pageState.pageSize = 10 * (columnCount.value - 1);
pageState.pageSize = 10 * (columnCount.value - 1) + 10;
// 只在首次初始化时调用,避免重复调用
if (!isInitialized.value) {
@@ -679,6 +714,7 @@ const goToCompanyInfo = () => {
navTo('/pages/mine/company-info');
};
// 组件初始化时加载数据
onMounted(() => {
// 获取企业信息
@@ -694,6 +730,7 @@ onMounted(() => {
// 在组件挂载时绑定事件监听,确保只绑定一次
// 先移除可能存在的旧监听,避免重复绑定
uni.$off('showLoginModal');
uni.$off('citySelected');
// 绑定新的监听
uni.$on('showLoginModal', () => {
@@ -702,6 +739,15 @@ onMounted(() => {
pageNull.value = 0;
});
// 监听城市选择事件
uni.$on('citySelected', (city) => {
console.log('收到citySelected事件选择的城市:', city);
selectedCity.value = city;
// 可以在这里添加根据城市筛选职位的逻辑
conditionSearch.value.jobLocationAreaCode = city.code;
getJobRecommend('refresh');
});
// 获取企业信息
getCompanyInfo();
});
@@ -709,6 +755,7 @@ onMounted(() => {
onUnmounted(() => {
// 组件销毁时移除事件监听
uni.$off('showLoginModal');
uni.$off('citySelected');
});
onShow(() => {
@@ -746,21 +793,63 @@ const handleLoginSuccess = () => {
//四级联动单点及权限
getIsFourLevelLinkagePurview()
};
// H5环境下从URL获取token并自动登录
onLoad(() => {
// #ifdef H5
const token = uni.getStorageSync('zkr-token');
if (token) {
useUserStore().loginSetToken(token);
}
// #endif
});
// 处理附近工作点击
const handleNearbyClick = () => {
const handleNearbyClick = (options ) => {
// #ifdef MP-WEIXIN
if (checkLogin()) {
navTo('/pages/nearby/nearby');
}
// #endif
// #ifdef H5
const token = options.token || uni.getStorageSync('zkr-token');
if (token) {
navTo('/pages/nearby/nearby');
}
// #endif
};
const handleNoticeClick = () =>{
uni.navigateTo({
url:'/packageB/notice/index'
})
}
function handleInstitutionClick(type){
if(type=='evaluate'){
uni.navigateTo({
url:'/packageB/institution/evaluationAgency'
})
}else if (type=='training'){
uni.navigateTo({
url:'/packageB/institution/trainingInstitution'
})
}
}
// 处理服务功能点击
const handleServiceClick = (serviceType) => {
if (checkLogin()) {
navToService(serviceType);
}
};
// H5的简历指导跳转
const handelGoResumeGuide = () => {
const token = uni.getStorageSync('zkr-token');
// myToken.value = token;
if (token) {
// navTo()
navTo('/pages/resume-guide/resume-guide');
}
}
// 处理直播按钮点击
const handleLiveClick = () => {
// #ifdef MP-WEIXIN
@@ -794,17 +883,12 @@ const handleLiveClick = () => {
const handleSalaryInfoClick = () => {
navTo('/pages/service/salary-info');
};
const handleJobFairClick = () => {
navTo('/pages/careerfair/careerfair');
};
const handleH5SalaryClick = () => {
const salaryUrl = "https://www.mohrss.gov.cn/SYrlzyhshbzb/laodongguanxi_/fwyd/202506/t20250627_544623.html";
window.location.assign(salaryUrl);
};
// 处理帮扶
const helpClick = () => {
navTo('/packageB/priority/helpFilter');
};
async function loadData() {
try {
if (isLoaded.value) return;
@@ -878,15 +962,7 @@ function clearfindJob(job) {
}
function nextDetail(job) {
// 登录检查
if (checkLogin()) {
// 记录岗位类型,用作数据分析
if (job.jobCategory) {
const recordData = recommedIndexDb.JobParameter(job);
recommedIndexDb.addRecord(recordData);
}
navTo(`/packageA/pages/post/post?jobId=${encodeURIComponent(job.jobId)}`);
}
navTo(`/packageA/pages/post/post?jobId=${encodeURIComponent(job.jobId)}`);
}
function navToService(serviceType) {
@@ -982,6 +1058,12 @@ function handelHostestSearch(val) {
isShowJw.value = val.value;
pageState.search.order = val.value;
pageState.search.jobType = val.value === 3 ? 1 : 0;
if(val.value === 4) {
pageState.search.type = 4;
} else {
delete pageState.search.type;
}
if (state.tabIndex === 'all') {
getJobRecommend('refresh');
} else {
@@ -996,12 +1078,16 @@ function getJobRecommend(type = 'add') {
if (waterfallsFlowRef.value) waterfallsFlowRef.value.refresh();
}
let params = {
pageSize: pageState.pageSize,
pageSize: pageState.pageSize + 10,
sessionId: useUserStore().seesionId,
...pageState.search,
...conditionSearch.value,
isPublish: 1,
};
// 当选中零工市场(4)或疆外(3)时order参数传递0
if (pageState.search.order === 3 || pageState.search.order === 4) {
params.order = 0;
}
// 优先从store获取如果为空则从缓存获取
const storeIsCompanyUser = userInfo.value?.isCompanyUser;
const cachedUserInfo = uni.getStorageSync('userInfo') || {};
@@ -1080,11 +1166,15 @@ function getJobList(type = 'add') {
...pageState.search,
// ...conditionSearch.value,
};
// 当选中零工市场(4)或疆外(3)时order参数传递0
if (pageState.search.order === 3 || pageState.search.order === 4) {
params.order = 0;
}
$api.createRequest('/app/job/list', params).then((resData) => {
const { rows, total } = resData;
if (type === 'add') {
const str = pageState.pageSize * (pageState.page - 1);
const str = pageState.pageSize * (pageState.page - 1) + 10;
const end = list.value.length;
const reslist = dataToImg(rows);
list.value.splice(str, end, ...reslist);
@@ -1656,6 +1746,9 @@ defineExpose({ loadData });
min-width: 80rpx;
padding: 8rpx 12rpx;
white-space: nowrap;
.right-sx
width: 28rpx;
height: 28rpx;
.filter-bottom
display: flex
justify-content: space-between
@@ -1667,8 +1760,8 @@ defineExpose({ loadData });
font-weight: 400;
font-size: 32rpx;
color: #666D7F;
margin-right: 24rpx
padding: 0rpx 16rpx
margin-right: 8rpx
padding: 0rpx 6rpx
.active
font-weight: 500;
font-size: 32rpx;

View File

@@ -19,10 +19,11 @@ import IndexOne from './components/index-one.vue';
// import IndexTwo from './components/index-two.vue';
import { storeToRefs } from 'pinia';
import { useReadMsg } from '@/stores/useReadMsg';
import useUserStore from '@/stores/useUserStore';
import { tabbarManager } from '@/utils/tabbarManager';
const { unreadCount } = storeToRefs(useReadMsg());
onLoad(() => {
const userStore = useUserStore();
onLoad((options) => {
// useReadMsg().fetchMessages();
});

View File

@@ -194,7 +194,7 @@ const handleLogin = async () => {
icon: 'success'
})
// window.location.assign('http://222.80.110.161:11111/mechine-dual-vue/login')
window.location.assign('https://www.xjksly.cn/mechine-single-vue/login')
// window.location.assign('https://www.xjksly.cn/mechine-single-vue/login')
// // 跳转到首页
// uni.reLaunch({
// url: '/pages/index/index'

View File

@@ -5,7 +5,7 @@
<view class="avatar-label">编辑信息</view>
<view class="avatar-container">
<image class="company-avatar" :src="companyInfo.avatar || '/static/imgs/avatar.jpg'"></image>
<uni-icons color="#A2A2A2" type="right" size="16"></uni-icons>
<!-- <uni-icons color="#A2A2A2" type="right" size="16"></uni-icons> -->
</view>
</view>
@@ -15,7 +15,7 @@
<view class="info-label">企业名称</view>
<view class="info-content">
<text class="info-value">{{ companyInfo.name || '暂无公司名称' }}</text>
<uni-icons color="#A2A2A2" type="right" size="16"></uni-icons>
<!-- <uni-icons color="#A2A2A2" type="right" size="16"></uni-icons> -->
</view>
</view>
@@ -23,7 +23,7 @@
<view class="info-label">统一社会代码</view>
<view class="info-content">
<text class="info-value">{{ companyInfo.socialCode || '暂无统一社会代码' }}</text>
<uni-icons color="#A2A2A2" type="right" size="16"></uni-icons>
<!-- <uni-icons color="#A2A2A2" type="right" size="16"></uni-icons> -->
</view>
</view>
@@ -31,7 +31,7 @@
<view class="info-label">企业注册地点</view>
<view class="info-content">
<text class="info-value">{{ companyInfo.location || '暂无注册地点' }}</text>
<uni-icons color="#A2A2A2" type="right" size="16"></uni-icons>
<!-- <uni-icons color="#A2A2A2" type="right" size="16"></uni-icons> -->
</view>
</view>
@@ -39,7 +39,7 @@
<view class="info-label">企业信息介绍</view>
<view class="info-content">
<text class="info-value">{{ companyInfo.description || '暂无企业介绍' }}</text>
<uni-icons color="#A2A2A2" type="right" size="16"></uni-icons>
<!-- <uni-icons color="#A2A2A2" type="right" size="16"></uni-icons> -->
</view>
</view>
@@ -47,7 +47,7 @@
<view class="info-label">企业法人姓名</view>
<view class="info-content">
<text class="info-value">{{ companyInfo.legalPerson || '暂无法人信息' }}</text>
<uni-icons color="#A2A2A2" type="right" size="16"></uni-icons>
<!-- <uni-icons color="#A2A2A2" type="right" size="16"></uni-icons> -->
</view>
</view>

View File

@@ -49,9 +49,11 @@
<!-- 行动按钮 -->
<view class="action-buttons">
<!-- #ifdef MP-WEIXIN -->
<view class="primary-button button-click" @click="startCreateResume">
开始制作简历
</view>
<!-- #endif -->
<view class="secondary-button button-click" @click="viewExampleResume">
查看简历示例
</view>