投递简历的时候验证登录

This commit is contained in:
francis_fh
2026-01-14 23:07:09 +08:00
parent 637d50c811
commit a299608fca
2 changed files with 6 additions and 12 deletions

View File

@@ -289,7 +289,6 @@ onShow(() => {
}
// #endif
});
function initLoad(option) {
const jobId = decodeURIComponent(option.jobId);
if (jobId !== jobIdRef.value) {
@@ -413,6 +412,11 @@ function getCompetivetuveness(jobId) {
// 申请岗位
function jobApply() {
const tokenValue = uni.getStorageSync('token') || '';
if (!tokenValue) {
$api.msg('请您先登录');
return;
}
const jobId = jobInfo.value.jobId;
$api.createRequest(`/app/job/apply/${jobId}`, {}, 'GET').then((resData) => {
getDetail(jobId);

View File

@@ -84,7 +84,6 @@
</view>
<!-- #endif -->
<view style="margin-top: 20rpx;padding:0 20px">token:{{myToken}}</view>
<!-- 服务功能网格 -->
<!-- #ifndef H5 -->
<view class="service-grid" v-if="shouldShowJobSeekerContent">
@@ -747,7 +746,6 @@ const handleLoginSuccess = () => {
//四级联动单点及权限
getIsFourLevelLinkagePurview()
};
const myToken = ref('');
// H5环境下从URL获取token并自动登录
onLoad((options) => {
// #ifdef H5
@@ -890,15 +888,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) {