1 Commits

Author SHA1 Message Date
francis-fh
a804e443f3 11 2026-07-16 01:06:02 +08:00
6 changed files with 777 additions and 939 deletions

View File

@@ -2,154 +2,134 @@
<view v-if="show" class="filter-container">
<!-- 头部 -->
<view class="filter-header">
<view class="header-title">筛选</view>
<view class="header-close" @click="handleClose">
<view class="close-icon"></view>
</view>
</view>
<!-- 主体内容 -->
<view class="filter-body">
<!-- 左侧标签页 -->
<view class="filter-tabs">
<view
v-for="(tab, index) in tabs"
:key="index"
class="tab-item"
:class="{ active: activeTab === tab.key }"
@click="activeTab = tab.key"
>
{{ tab.label }}
<text class="header-title">筛选</text>
<view class="header-close-btn btn-feel" @click="handleClose">
<uni-icons type="closeempty" size="18" color="#666"></uni-icons>
<text class="close-text">关闭</text>
</view>
</view>
<!-- 右侧内容区域 -->
<view class="filter-right">
<!-- 标签页和内容区域 -->
<view class="filter-body">
<view class="filter-tabs">
<view
v-for="(tab, index) in tabs"
:key="index"
class="tab-item"
:class="{ active: activeTab === tab.key }"
@click="activeTab = tab.key"
>
{{ tab.label }}
</view>
</view>
<!-- 内容区域 -->
<view class="filter-content">
<!-- 学历要求 -->
<view v-if="activeTab === 'education'" class="content-section">
<radio-group @change="(e) => handleSelect('education', e)">
<label
v-for="option in educationOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['education'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['education'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 工作经验 -->
<view v-if="activeTab === 'experience'" class="content-section">
<radio-group @change="(e) => handleSelect('experience', e)">
<label
v-for="option in experienceOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['experience'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['experience'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 薪资 -->
<view v-if="activeTab === 'salary'" class="content-section">
<radio-group @change="(e) => handleSelect('salary', e)">
<label
v-for="option in salaryOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['salary'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['salary'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 公司规模 -->
<view v-if="activeTab === 'scale'" class="content-section">
<radio-group @change="(e) => handleSelect('scale', e)">
<label
v-for="option in scaleOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['scale'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['scale'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 地区多选 -->
<view v-if="activeTab === 'area'" class="content-section">
<checkbox-group @change="(e) => handleCheckboxSelect('area', e)">
<label
v-for="option in areaOptions"
:key="option.value"
class="radio-item"
:class="{ checked: isAreaSelected(String(option.value)) }"
>
<checkbox
:value="String(option.value)"
:checked="isAreaSelected(String(option.value))"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</checkbox-group>
</view>
<!-- 岗位类型 -->
<view v-if="activeTab === 'jobType'" class="content-section">
<radio-group @change="(e) => handleSelect('jobType', e)">
<label
v-for="option in jobTypeOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['jobType'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['jobType'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 学历要求 -->
<view v-if="activeTab === 'education'" class="content-section">
<radio-group @change="(e) => handleSelect('education', e)">
<label
v-for="option in educationOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['education'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['education'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 工作经验 -->
<view v-if="activeTab === 'experience'" class="content-section">
<radio-group @change="(e) => handleSelect('experience', e)">
<label
v-for="option in experienceOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['experience'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['experience'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 公司规模 -->
<view v-if="activeTab === 'scale'" class="content-section">
<radio-group @change="(e) => handleSelect('scale', e)">
<label
v-for="option in scaleOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['scale'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['scale'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 岗位类型 -->
<view v-if="activeTab === 'jobType'" class="content-section">
<radio-group @change="(e) => handleSelect('jobType', e)">
<label
v-for="option in jobTypeOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['jobType'] === String(option.value) }"
>
<radio
:value="String(option.value)"
:checked="selectedValues['jobType'] === String(option.value)"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</radio-group>
</view>
<!-- 地区多选 -->
<view v-if="activeTab === 'area'" class="content-section">
<checkbox-group @change="(e) => handleAreaSelect(e)">
<label
v-for="option in areaOptions"
:key="option.value"
class="radio-item"
:class="{ checked: selectedValues['area'].includes(String(option.value)) }"
>
<checkbox
:value="String(option.value)"
:checked="selectedValues['area'].includes(String(option.value))"
/>
<text class="option-label">{{ option.label }}</text>
</label>
</checkbox-group>
</view>
<!-- 底部按钮 -->
<view class="filter-footer">
<button class="footer-btn clear-btn" @click="handleClear">清除</button>
<button class="footer-btn confirm-btn" @click="handleConfirm">确认</button>
</view>
</view>
</view><!-- end filter-body -->
</view>
</view>
</template>
<script setup>
import { ref, reactive, onBeforeMount } from 'vue';
import { ref, reactive, onBeforeMount, watch } from 'vue';
import useDictStore from '@/stores/useDictStore';
const dictStore = useDictStore();
const { getTransformChildren } = dictStore;
const { getTransformChildren } = useDictStore();
const props = defineProps({
show: Boolean,
@@ -171,7 +151,6 @@ const getJobTypeData = () => {
const tabs = [
{ key: 'education', label: '学历要求' },
{ key: 'experience', label: '工作经验' },
{ key: 'salary', label: '薪资' },
{ key: 'scale', label: '公司规模' },
{ key: 'jobType', label: '岗位类型' },
{ key: 'area', label: '地区' }
@@ -184,78 +163,47 @@ const activeTab = ref('education');
const selectedValues = reactive({
education: '',
experience: '',
salary: '',
scale: '',
area: [],
jobType: ''
jobType: '',
area: []
});
// 从字典获取的选项数据
const educationOptions = ref([]);
const experienceOptions = ref([]);
const scaleOptions = ref([]);
const areaOptions = ref([]);
const jobTypeOptions = ref([]);
// 薪资区间数据(单位:元/月min/max 为空表示该侧不设限
const salaryOptions = ref([
{ label: '3K以下', value: '0-3000', min: '', max: 3000 },
{ label: '3-5K', value: '3000-5000', min: 3000, max: 5000 },
{ label: '5-10K', value: '5000-10000', min: 5000, max: 10000 },
{ label: '10-20K', value: '10000-20000', min: 10000, max: 20000 },
{ label: '20-50K', value: '20000-50000', min: 20000, max: 50000 },
{ label: '50K以上', value: '50000-0', min: 50000, max: '' },
]);
// 加载状态
const loading = ref(true);
const areaOptions = ref([]);
// 初始化获取数据
onBeforeMount(async () => {
try {
// 先获取字典数据
await dictStore.getDictData();
// 再初始化选项数据
educationOptions.value = getTransformChildren('education', '学历要求').options || [];
experienceOptions.value = getTransformChildren('experience', '工作经验').options || [];
scaleOptions.value = getTransformChildren('scale', '公司规模').options || [];
areaOptions.value = getTransformChildren('area', '地区').options || [];
jobTypeOptions.value = getJobTypeData();
} catch (error) {
console.error('获取字典数据失败:', error);
} finally {
loading.value = false;
const initData = () => {
educationOptions.value = getTransformChildren('education', '学历要求').options || [];
experienceOptions.value = getTransformChildren('experience', '工作经验').options || [];
scaleOptions.value = getTransformChildren('scale', '公司规模').options || [];
jobTypeOptions.value = getJobTypeData();
areaOptions.value = getTransformChildren('area', '地区').options || [];
};
// 组件挂载时初始化数据
onBeforeMount(() => {
initData();
});
// 监听组件显示状态,当显示时重新初始化数据
watch(() => props.show, (newVal) => {
if (newVal) {
initData();
}
});
// 处理单选选项选择
// 处理选项选择(单选)
const handleSelect = (key, e) => {
selectedValues[key] = e.detail.value;
};
// 处理多选选项选择(地区)
// 兼容不同平台H5 可能返回逗号分隔字符串,小程序返回数组
const handleCheckboxSelect = (key, e) => {
let val = e.detail.value;
if (typeof val === 'string') {
selectedValues[key] = val ? val.split(',').map((s) => s.trim()) : [];
} else if (Array.isArray(val)) {
selectedValues[key] = val.map((v) => String(v));
} else {
selectedValues[key] = [];
}
};
// 判断地区选项是否被选中(兼容数组和字符串)
const isAreaSelected = (value) => {
const areaVal = selectedValues.area;
if (Array.isArray(areaVal)) {
return areaVal.includes(value);
}
if (typeof areaVal === 'string' && areaVal) {
return areaVal.split(',').includes(value);
}
return false;
// 处理地区多选
const handleAreaSelect = (e) => {
selectedValues.area = e.detail.value;
};
// 清除所有选择
@@ -271,33 +219,8 @@ const handleClear = () => {
// 确认筛选
const handleConfirm = () => {
const payload = { ...selectedValues };
// 将多选的地区数组转为逗号分隔字符串(兼容各种格式)
if (Array.isArray(payload.area) && payload.area.length > 0) {
payload.area = payload.area.map((v) => String(v)).join(',');
} else if (typeof payload.area === 'string' && payload.area) {
// 如果已经是逗号分隔字符串,保持原样
payload.area = payload.area;
} else {
payload.area = '';
}
console.log('[new-filter-page] area value to emit:', payload.area);
// 将选中的薪资区间转换为 minSalary / maxSalary 参数
// 始终带上 minSalary / maxSalary含空值便于父组件在清除时移除旧值
let minSalary = '';
let maxSalary = '';
if (payload.salary) {
const selected = salaryOptions.value.find((item) => item.value === payload.salary);
if (selected) {
minSalary = selected.min;
maxSalary = selected.max;
}
}
payload.minSalary = minSalary;
payload.maxSalary = maxSalary;
delete payload.salary;
console.log('selectedValues:', payload);
emit('confirm', payload);
console.log('selectedValues:', selectedValues);
emit('confirm', selectedValues);
handleClose();
};
@@ -319,67 +242,42 @@ const handleClose = () => {
z-index: 9999;
display: flex;
flex-direction: column;
box-sizing: border-box;
}
.filter-header {
height: 96rpx;
height: 88rpx;
display: flex;
align-items: center;
justify-content: center;
padding: 0 32rpx;
justify-content: space-between;
padding: 24rpx 32rpx;
border-bottom: 1rpx solid #eee;
background-color: #fff;
flex-shrink: 0;
position: relative;
.header-title {
font-size: 34rpx;
font-size: 48rpx;
font-weight: 600;
color: #333;
}
.header-close {
position: absolute;
right: 32rpx;
top: 50%;
transform: translateY(-50%);
width: 48rpx;
height: 48rpx;
.header-close-btn {
display: flex;
align-items: center;
justify-content: center;
padding: 10rpx;
border-radius: 50%;
transition: all 0.3s ease;
gap: 8rpx;
padding: 12rpx 24rpx;
border-radius: 8rpx;
border: 1rpx solid #256BFA;
background: rgba(37, 107, 250, 0.08);
&:active {
background-color: rgba(37, 107, 250, 0.1);
.close-text {
font-size: 39rpx;
color: #256BFA;
}
.close-icon {
position: relative;
width: 28rpx;
height: 28rpx;
&::before,
&::after {
content: '';
position: absolute;
left: 50%;
top: 50%;
width: 4rpx;
height: 28rpx;
border-radius: 2rpx;
background: #5A5A68;
}
&::before {
transform: translate(-50%, -50%) rotate(45deg);
}
&::after {
transform: translate(-50%, -50%) rotate(-45deg);
}
&:active {
background: rgba(37, 107, 250, 0.18);
transform: scale(0.96);
}
}
}
@@ -392,35 +290,40 @@ const handleClose = () => {
}
.filter-tabs {
width: 200rpx;
border-right: 1rpx solid #eee;
background-color: #f8f8f8;
display: flex;
flex-direction: column;
width: 250rpx;
border-right: 1rpx solid #eee;
background-color: #f9f9f9;
box-shadow: 3rpx 0 15rpx rgba(0, 0, 0, 0.05);
height: 100%;
box-sizing: border-box;
.tab-item {
height: 100rpx;
line-height: 100rpx;
height: 130rpx;
line-height: 130rpx;
text-align: center;
font-size: 28rpx;
font-size: 42rpx;
color: #666;
position: relative;
transition: all 0.3s ease;
border-bottom: 1rpx solid #f0f0f0;
&.active {
color: #256BFA;
font-weight: 600;
background-color: #fff;
box-shadow: 3rpx 0 10rpx rgba(37, 107, 250, 0.1);
&::after {
content: '';
position: absolute;
left: 0;
right: 0;
top: 25%;
width: 4rpx;
width: 6rpx;
height: 50%;
background-color: #256BFA;
border-radius: 2rpx;
border-radius: 3rpx 0 0 3rpx;
}
}
@@ -430,24 +333,23 @@ const handleClose = () => {
}
}
.filter-right {
flex: 1;
display: flex;
flex-direction: column;
position: relative;
}
.filter-content {
flex: 1;
padding: 40rpx 32rpx;
overflow-y: auto;
padding: 30rpx 0rpx;
display: flex;
flex-direction: column;
padding-bottom: 160rpx;
box-sizing: border-box;
}
.content-section {
padding: 0 4%;
overflow-y: auto;
flex: 12;
.radio-item {
display: flex;
align-items: center;
padding: 30rpx 0;
padding: 45rpx 0;
border-bottom: 1rpx solid #f0f0f0;
transition: all 0.3s ease;
position: relative;
@@ -461,9 +363,9 @@ const handleClose = () => {
}
radio {
width: 28rpx;
height: 28rpx;
margin-right: 24rpx;
width: 42rpx;
height: 42rpx;
margin-right: 36rpx;
transform: scale(1);
display: flex;
align-items: center;
@@ -471,10 +373,10 @@ const handleClose = () => {
}
radio .wx-radio-input {
width: 28rpx;
height: 28rpx;
width: 42rpx;
height: 42rpx;
border-radius: 50%;
border: 2rpx solid #ccc;
border: 3rpx solid #ccc;
background: transparent;
}
@@ -484,11 +386,11 @@ const handleClose = () => {
}
radio .wx-radio-input::before {
width: 16rpx;
height: 16rpx;
line-height: 16rpx;
width: 24rpx;
height: 24rpx;
line-height: 24rpx;
text-align: center;
font-size: 12rpx;
font-size: 18rpx;
color: #fff;
background: transparent;
transform: translate(-50%, -50%) scale(0);
@@ -501,38 +403,40 @@ const handleClose = () => {
}
.option-label {
font-size: 30rpx;
font-size: 45rpx;
color: #333;
flex: 1;
font-weight: 400;
line-height: 40rpx;
line-height: 60rpx;
}
}
}
.filter-footer {
height: 160rpx;
height: 200rpx;
flex: 1;
display: flex;
border-top: 1rpx solid #eee;
background-color: #fff;
box-shadow: 0 -2rpx 10rpx rgba(0, 0, 0, 0.05);
padding: 20rpx 32rpx 100rpx;
box-shadow: 0 -3rpx 15rpx rgba(0, 0, 0, 0.05);
padding: 30rpx 0;
flex-shrink: 0;
position: relative;
z-index: 10;
margin-top: auto;
box-sizing: border-box;
.footer-btn {
flex: 1;
margin: 0;
border-radius: 16rpx;
height: 80rpx;
line-height: 80rpx;
font-size: 32rpx;
margin: 0 40rpx;
border-radius: 24rpx;
height: 100rpx;
line-height: 100rpx;
font-size: 45rpx;
transition: all 0.3s ease;
font-weight: 500;
&:first-child {
margin-right: 20rpx;
margin-right: 30rpx;
background-color: #f5f5f5;
color: #666;
border: 1rpx solid #e0e0e0;

View File

@@ -21,8 +21,14 @@
</view>
<view class="card-bottom">
<view>{{ job.postingDate }}</view>
<view class="card-bottom-right">
<text v-if="job.regionName">地区{{ job.regionName }}</text>
<view>
<convert-distance
:alat="job.latitude"
:along="job.longitude"
:blat="latitude"
:blong="longitude"
></convert-distance>
{{ job.regionName || config.appInfo.areaName }}
</view>
</view>
</view>
@@ -34,6 +40,7 @@
<script setup>
import { inject, computed, toRaw } from 'vue';
import config from '@/config.js';
const { insertSortData, navTo, vacanciesTo } = inject('globalFunction');
import { useRecommedIndexedDBStore } from '@/stores/useRecommedIndexedDBStore.js';
const recommedIndexDb = useRecommedIndexedDBStore();

View File

@@ -63,9 +63,8 @@
<header class="head">
<view class="main-header">
<image src="/static/icon/Hamburger-button.png" @click="toggleDrawer"></image>
<view class="back-home-btn" @click="navTo('/pages/index/index')">
<text class="back-home-text">返回</text>
</view>
<!-- <view class="title">{{ config.appInfo.areaName }}岗位推荐</view> -->
<!-- <view class="title">{{ config.appInfo.areaName }}岗位推荐</view> -->
<image src="/static/icon/Comment-one.png" @click="addNewDialogue"></image>
</view>
</header>
@@ -376,19 +375,6 @@ footer-height = 98rpx
image
width: 36rpx;
height: 37rpx;
.back-home-btn
display: flex
align-items: center
justify-content: center
padding: 0 20rpx
height: 60rpx
border-radius: 12rpx
&:active
background: rgba(0, 0, 0, 0.05)
.back-home-text
font-size: 30rpx
color: #333
font-weight: 500
.chatmain-warpper
height: 'calc(100% - %s)' %( header-height + footer-height)

View File

@@ -227,12 +227,8 @@
placeholder-class="inputplaceholder"
class="input"
@confirm="sendMessage"
@click="handleInputClick"
@focus="handleInputFocus"
:disabled="isTyping"
:adjust-position="true"
:focus="inputFocused"
cursor-spacing="20"
placeholder="请输入您想找的岗位信息或就政策信息【比如:设计师、10000-12000、广州】【比如:今年喀什地区高校毕业生有什么就业政策】"
v-show="!isVoice"
/>
@@ -425,7 +421,6 @@ const { speak, pause, resume, isSpeaking, isPaused, cancelAudio } = useTTSPlayer
const instance = getCurrentInstance();
// state
const ACTIVE_TAB_KEY = 'chat_active_tab';
const activeTab = ref('policy'); // 'policy' or 'job'
const queries = ref([]);
const guessList = ref([]);
@@ -444,7 +439,6 @@ const feebackData = ref(null);
// 删除功能相关状态
const isSelectMode = ref(false);
const selectedMessages = ref([]);
const inputFocused = ref(false);
// ref for DOM element
const voiceBtn = ref(null);
const feeback = ref(null);
@@ -472,16 +466,7 @@ const audiowaveStyle = computed(() => {
: '#f1f1f1';
});
function setActiveTab(tab) {
activeTab.value = tab;
uni.setStorageSync(ACTIVE_TAB_KEY, tab);
}
onMounted(async () => {
const cachedActiveTab = uni.getStorageSync(ACTIVE_TAB_KEY);
if (cachedActiveTab === 'policy' || cachedActiveTab === 'job') {
activeTab.value = cachedActiveTab;
}
changeQueries();
scrollToBottom();
isAudioPermission.value = await requestMicPermission();
@@ -556,13 +541,10 @@ const sendMessage = (text) => {
if (speechIndex.value !== index) {
// 延迟TTS等待内容更完整
// 只有在内容长度超过50个字符或者包含岗位信息时才开始朗读
const hasJobInfo = isJobCardMessage(message) ||
const hasJobInfo = message.displayText.includes('```job-json') ||
message.displayText.includes('岗位') ||
message.displayText.includes('公司') ||
message.displayText.includes('薪资');
if (hasJobInfo) {
setActiveTab('job');
}
if (message.displayText.length > 50 || hasJobInfo) {
console.log('🎵 Starting streaming TTS for message index:', index);
@@ -591,9 +573,6 @@ const sendMessage = (text) => {
const lastMessageIndex = messages.value.length - 1;
if (lastMessageIndex >= 0) {
const lastMessage = messages.value[lastMessageIndex];
if (isJobCardMessage(lastMessage)) {
setActiveTab('job');
}
if (!lastMessage.self && lastMessage.displayText && lastMessage.displayText.trim()) {
console.log('🎵 Final TTS for complete message');
console.log('📝 Final text length:', lastMessage.displayText.length);
@@ -1378,22 +1357,6 @@ function closeFile() {
showfile.value = false;
}
function handleInputClick() {
inputFocused.value = false;
nextTick(() => {
inputFocused.value = true;
});
console.log('[键盘] 点击输入框,尝试唤起键盘');
}
function handleInputFocus() {
console.log('[键盘] 输入框已获得焦点,键盘应已弹出');
$api.msg('输入框已激活');
nextTick(() => {
scrollToBottom();
});
}
function copyMarkdown(value) {
$api.copyText(value);
}
@@ -1518,18 +1481,7 @@ function getRandomJobQueries(queries, count = 2) {
// 切换tab
function switchTab(tab) {
setActiveTab(tab);
}
function isJobCardMessage(msg) {
const content = msg?.displayText || '';
return (
/```\s*job-json/.test(content) ||
content.includes('岗位推荐') ||
content.includes('推荐岗位') ||
content.includes('岗位信息') ||
(content.includes('```') && content.includes('公司') && content.includes('薪资'))
);
activeTab.value = tab;
}
// 检查消息是否应该显示在当前tab
@@ -1538,10 +1490,26 @@ function shouldShowMessage(msg) {
return true; // 用户自己的消息总是显示
}
const isJobCard = isJobCardMessage(msg);
if (activeTab.value === 'policy') {
// 政策查询tab显示除了岗位卡片以外的所有内容
// 岗位卡片通常包含特定的标记,如```job-json或岗位推荐等关键词
const isJobCard = msg.displayText && (
msg.displayText.includes('```job-json') ||
msg.displayText.includes('岗位推荐') ||
msg.displayText.includes('推荐岗位') ||
msg.displayText.includes('岗位信息') ||
(msg.displayText.includes('```') && msg.displayText.includes('公司') && msg.displayText.includes('薪资'))
);
return !isJobCard;
} else {
// 岗位推荐tab只显示岗位卡片内容
const isJobCard = msg.displayText && (
msg.displayText.includes('```job-json') ||
msg.displayText.includes('岗位推荐') ||
msg.displayText.includes('推荐岗位') ||
msg.displayText.includes('岗位信息') ||
(msg.displayText.includes('```') && msg.displayText.includes('公司') && msg.displayText.includes('薪资'))
);
return isJobCard;
}
}

File diff suppressed because it is too large Load Diff

View File

@@ -1,16 +1,9 @@
<template>
<view class="container safe-area-top">
<!-- 自定义头部搜索框 -->
<!-- #ifdef H5 -->
<view class="custom-header" :style="{ paddingTop: statusBarHeight + 'px' }">
<!-- #endif -->
<!-- #ifndef H5 -->
<view class="custom-header">
<!-- #endif -->
<view class="top">
<!-- #ifdef H5 -->
<image class="btnback button-click" src="@/static/icon/back.png" @click="navBack"></image>
<!-- #endif -->
<view class="search-box">
<uni-icons
class="iconsearch"
@@ -62,11 +55,6 @@ import { storeToRefs } from 'pinia';
import { useColumnCount } from '@/hook/useColumnCount';
import img from '@/static/icon/filter.png';
const { longitudeVal, latitudeVal } = storeToRefs(useLocationStore());
const statusBarHeight = ref(0);
// #ifdef H5
const sysInfo = uni.getSystemInfoSync();
statusBarHeight.value = sysInfo.statusBarHeight || 0;
// #endif
const searchValue = ref('');
const historyList = ref([]);
const searchParams = ref({});
@@ -92,14 +80,11 @@ onLoad((query) => {
historyList.value = uni.getStorageSync('searchList');
}
const {job, area, regionCode} = query;
// 从首页筛选条件传入的地区和区域编码
console.log('[search-page] onLoad query:', JSON.stringify(query));
if (area) {
pageState.search.area = String(area);
console.log('[search-page] set area:', pageState.search.area);
pageState.search.area = area;
}
if (regionCode) {
pageState.search.regionCode = String(regionCode);
pageState.search.regionCode = regionCode;
}
if (job) {
searchValue.value = job;
@@ -182,7 +167,6 @@ function getJobList(type = 'add') {
...pageState.search,
jobTitle: searchValue.value,
};
console.log('[search-page] getJobList params:', JSON.stringify(params));
$api.createRequest('/app/job/list', params, 'GET', true).then((resData) => {
const { rows, total } = resData;