Merge branch 'master' of http://120.26.58.240:8888/r/flexJobMiniApp
| | |
| | | "useSwitchTab": true, |
| | | "useTaskList": true, |
| | | "useUser": true, |
| | | "useUserResume": true |
| | | "useUserResume": true, |
| | | "useUpdateResume": true |
| | | } |
| | | } |
| | |
| | | const useSlots: typeof import('vue')['useSlots'] |
| | | const useSwitchTab: typeof import('./src/hooks/router')['useSwitchTab'] |
| | | const useTemplateRef: typeof import('vue')['useTemplateRef'] |
| | | const useUpdateResume: typeof import('./src/hooks/user')['useUpdateResume'] |
| | | const useUser: typeof import('./src/hooks/user')['useUser'] |
| | | const useUserResume: typeof import('./src/hooks/user')['useUserResume'] |
| | | const watch: typeof import('vue')['watch'] |
| | |
| | | readonly useSlots: UnwrapRef<typeof import('vue')['useSlots']> |
| | | readonly useSwitchTab: UnwrapRef<typeof import('./src/hooks/router')['useSwitchTab']> |
| | | readonly useTemplateRef: UnwrapRef<typeof import('vue')['useTemplateRef']> |
| | | readonly useUpdateResume: UnwrapRef<typeof import('./src/hooks/user')['useUpdateResume']> |
| | | readonly useUser: UnwrapRef<typeof import('./src/hooks/user')['useUser']> |
| | | readonly useUserResume: UnwrapRef<typeof import('./src/hooks/user')['useUserResume']> |
| | | readonly watch: UnwrapRef<typeof import('vue')['watch']> |
| | |
| | | "query": "", |
| | | "launchMode": "default", |
| | | "scene": null |
| | | }, |
| | | { |
| | | "name": "", |
| | | "pathName": "subpackages/mine/mineCollectTask/mineCollectTask", |
| | | "query": "", |
| | | "launchMode": "default", |
| | | "scene": null |
| | | } |
| | | ] |
| | | } |
| | |
| | | import Taro from '@tarojs/taro'; |
| | | import { object2query, LocationUtils } from '@12333/utils'; |
| | | import { ParkOrHRStatus, UserCertificationFrontStatus } from '@12333/constants'; |
| | | import { useQuery } from '@tanstack/vue-query'; |
| | | import { useQuery, useQueryClient } from '@tanstack/vue-query'; |
| | | import { MaybeRef } from 'vue'; |
| | | import { useRefeshDidShow } from '@12333/hooks/infiniteLoading'; |
| | | import * as userResumeServices from '@12333/services/apiV2/userResume'; |
| | |
| | | refetch, |
| | | }; |
| | | } |
| | | |
| | | export function useUpdateResume() { |
| | | const queryClient = useQueryClient(); |
| | | |
| | | const updateUserResumeCredentials = () => { |
| | | return queryClient.invalidateQueries({ |
| | | queryKey: ['userResumeServices/getUserResumeCredentials'], |
| | | }); |
| | | }; |
| | | |
| | | const updateUserResume = () => { |
| | | return queryClient.invalidateQueries({ |
| | | queryKey: ['userResumeServices/getUserResume'], |
| | | }); |
| | | }; |
| | | |
| | | return { |
| | | updateUserResumeCredentials, |
| | | updateUserResume, |
| | | }; |
| | | } |
| | |
| | | :key="queryState.orderType" |
| | | > |
| | | <template #renderItem="{ item }"> |
| | | <TaskCard @click="goTaskDetail(item)" v-bind="item" @apply="goTaskApply(item)" /> |
| | | <TaskCard @click="goTaskDetail(item)" v-bind="item" /> |
| | | </template> |
| | | </InfiniteLoading> |
| | | </PageLayoutWithBg> |
| | |
| | | |
| | | <script setup lang="ts"> |
| | | import { useUser } from '@/hooks'; |
| | | import { useUserStore } from '@/stores/modules/user'; |
| | | import { RectDown, Location2 } from '@nutui/icons-vue-taro'; |
| | | import Taro from '@tarojs/taro'; |
| | | import { setLocationCity } from '@/utils'; |
| | | import _ from 'lodash'; |
| | |
| | | name: 'InnerPage', |
| | | }); |
| | | |
| | | const { updateUserResume } = useUpdateResume(); |
| | | |
| | | const eventChannel = useEventChannel(); |
| | | |
| | | const { dictionaryDataList: identityList } = useDictionaryDataSelect({ |
| | |
| | | Message.success('保存成功', { |
| | | onClosed() { |
| | | goBack(); |
| | | eventChannel.emit('updateResume', { content: true }); |
| | | updateUserResume(); |
| | | }, |
| | | }); |
| | | } |
| | |
| | | import { RouterPath } from '@/constants'; |
| | | import * as userResumeServices from '@12333/services/apiV2/userResume'; |
| | | import { useQuery } from '@tanstack/vue-query'; |
| | | import { useEvent } from 'senin-mini/hooks'; |
| | | |
| | | defineOptions({ |
| | | name: 'InnerPage', |
| | | }); |
| | | |
| | | useEvent('updateResume', function (data: { content: boolean }) { |
| | | if (data.content) { |
| | | refetch({ |
| | | type: 'inactive', |
| | | }); |
| | | } |
| | | }); |
| | | |
| | | const { |
| | |
| | | const router = Taro.useRouter(); |
| | | const id = router.params?.id as string; |
| | | const isEdit = computed(() => !!id); |
| | | const queryClient = useQueryClient(); |
| | | const { updateUserResumeCredentials } = useUpdateResume(); |
| | | |
| | | const { dictionaryDataList: certificateTypeList } = useDictionaryDataSelect({ |
| | | categoryCode: CategoryCode.CertificateType, |
| | |
| | | Message.success(isEdit.value ? '编辑成功' : '添加成功', { |
| | | onClosed() { |
| | | goBack(); |
| | | queryClient.invalidateQueries(['userResumeServices/getUserResumeCredentials']); |
| | | updateUserResumeCredentials(); |
| | | }, |
| | | }); |
| | | } |
| | |
| | | import IconPhone from '@/assets/mine/icon-phone.png'; |
| | | import Taro from '@tarojs/taro'; |
| | | import { setOSSLink } from '@12333/utils'; |
| | | import { useEvent } from 'senin-mini/hooks'; |
| | | |
| | | defineOptions({ |
| | | name: 'InnerPage', |
| | |
| | | function goPage(routeName: string) { |
| | | Taro.navigateTo({ |
| | | url: routeName, |
| | | events: { |
| | | updateResume(data: { content: boolean }) { |
| | | console.log('content: ', data.content); |
| | | if (data.content) { |
| | | refetch({ |
| | | type: 'inactive', |
| | | }); |
| | | } |
| | | }, |
| | | }, |
| | | // events: { |
| | | // updateResume(data: { content: boolean }) { |
| | | // if (data.content) { |
| | | // refetch({ |
| | | // type: 'inactive', |
| | | // }); |
| | | // } |
| | | // }, |
| | | // }, |
| | | }); |
| | | } |
| | | function goEditMineInfo() { |
| | |
| | | name: 'InnerPage', |
| | | }); |
| | | |
| | | const { refetch: userResumeRefetch } = useUserResume(); |
| | | const { updateUserResume } = useUpdateResume(); |
| | | |
| | | const { |
| | | isLoading, |
| | |
| | | Message.success('保存成功', { |
| | | onClosed() { |
| | | goBack(); |
| | | userResumeRefetch({ type: 'inactive' }); |
| | | updateUserResume(); |
| | | }, |
| | | }); |
| | | } |
| | |
| | | import { Message } from '@12333/utils'; |
| | | import { useQuery } from '@tanstack/vue-query'; |
| | | import { goBack } from '@/utils'; |
| | | import { useEventChannel } from 'senin-mini/hooks'; |
| | | |
| | | defineOptions({ |
| | | name: 'InnerPage', |
| | | }); |
| | | |
| | | const eventChannel = useEventChannel(); |
| | | const { updateUserResume } = useUpdateResume(); |
| | | |
| | | const { dictionaryDataList: positionList } = useDictionaryDataSelect({ |
| | | categoryCode: CategoryCode.Position, |
| | |
| | | Message.success('保存成功', { |
| | | onClosed() { |
| | | goBack(); |
| | | eventChannel.emit('updateResume', { content: true }); |
| | | updateUserResume(); |
| | | }, |
| | | }); |
| | | } |
| | |
| | | name: 'InnerPage', |
| | | }); |
| | | |
| | | const { refetch: userResumeRefetch } = useUserResume(); |
| | | const { updateUserResume } = useUpdateResume(); |
| | | |
| | | const form = reactive({ |
| | | workSeniority: '', |
| | |
| | | Message.success('保存成功', { |
| | | onClosed() { |
| | | goBack(); |
| | | userResumeRefetch({ type: 'inactive' }); |
| | | updateUserResume(); |
| | | }, |
| | | }); |
| | | } |
| | |
| | | <template> |
| | | <div class="my-collect-task"> |
| | | <div class="my-collect-task-title">收藏任务列表</div> |
| | | <div class="my-collect-task-btn">清空已失效任务</div> |
| | | <div class="my-collect-task-btn" @click="clearExpiredTask">清空已失效任务</div> |
| | | </div> |
| | | <InfiniteLoading |
| | | scrollViewClassName="common-infinite-scroll-list home-list" |
| | | v-bind="infiniteLoadingProps" |
| | | > |
| | | <template #renderItem="{ item }"> |
| | | <TaskCard> </TaskCard> |
| | | <TaskCard |
| | | :name="item.name" |
| | | :address-name="item.addressName" |
| | | :begin-time="item.beginTime" |
| | | :end-time="item.endTime" |
| | | :gender-limit="item.genderLimit" |
| | | :service-fee="item.serviceFee" |
| | | :billing-method="item.billingMethod" |
| | | :settlement-cycle="item.settlementCycle" |
| | | :benefits="item.benefits" |
| | | > |
| | | <template #actions> |
| | | <nut-button @click="goTaskDetail(item)" type="primary">报名</nut-button> |
| | | </template> |
| | | </TaskCard> |
| | | </template> |
| | | </InfiniteLoading> |
| | | </template> |
| | |
| | | <script setup lang="ts"> |
| | | import { TaskCard } from '@12333/components'; |
| | | import { useUserStore } from '@/stores/modules/user'; |
| | | import { useInfiniteLoading } from '@12333/hooks'; |
| | | import { OrderInputType } from '@12333/constants'; |
| | | import * as flexWorkerServices from '@12333/services/api/FlexWorker'; |
| | | import { useTaskList } from '@12333/hooks'; |
| | | import Taro from '@tarojs/taro'; |
| | | |
| | | defineOptions({ |
| | | name: 'InnerPage', |
| | | }); |
| | | |
| | | const userStore = useUserStore(); |
| | | |
| | | const { infiniteLoadingProps } = useInfiniteLoading( |
| | | ({ pageParam }) => { |
| | | let params: API.GetFlexTaskListInput = { |
| | | pageModel: { |
| | | rows: 20, |
| | | page: pageParam, |
| | | orderInput: [{ property: 'creationTime', order: OrderInputType.Desc }], |
| | | }, |
| | | }; |
| | | |
| | | return flexWorkerServices.getFlexTaskByArrange(params, { |
| | | showLoading: false, |
| | | const { infiniteLoadingProps } = useTaskList({ |
| | | defaultQueryMenuState: {}, |
| | | }); |
| | | }, |
| | | { |
| | | queryKey: ['flexWorkerServices/getFlexTaskByArrange'], |
| | | |
| | | function goTaskDetail(item: API.GetTaskInfosQueryResultItem) { |
| | | Taro.navigateTo({ |
| | | url: `${RouterPath.taskCheckDetail}?id=${item.id}`, |
| | | }); |
| | | } |
| | | ); |
| | | |
| | | function clearExpiredTask() {} |
| | | </script> |
| | | |
| | | <style lang="scss"> |
| | |
| | | <img |
| | | :src="detail.isCollected ? IconAttentioActive : IconAttention" |
| | | class="taskDetail-attention-icon" |
| | | @click="handleAttention" |
| | | /> |
| | | </template> |
| | | <div class="taskDetail-time"> |
| | |
| | | :isFlex="false" |
| | | openType="share" |
| | | ></PageFooterAction> |
| | | <PageFooterAction :icon="IconPhone" text="手机" :isFlex="false"></PageFooterAction> |
| | | <PageFooterBtn v-if="detail.releaseStatus === EnumTaskReleaseStatus.InProcess" type="primary" |
| | | >报名({{ detail.applyCount }}人已报名)</PageFooterBtn |
| | | <PageFooterAction |
| | | :icon="IconPhone" |
| | | text="手机" |
| | | :isFlex="false" |
| | | @click="handleCall" |
| | | ></PageFooterAction> |
| | | <PageFooterBtn |
| | | v-if="detail.releaseStatus === EnumTaskReleaseStatus.InProcess" |
| | | type="primary" |
| | | @click="handleApply" |
| | | >{{ `报名(${detail?.applyCount ?? 0}人已报名)` }}</PageFooterBtn |
| | | > |
| | | <PageFooterBtn v-if="detail.releaseStatus === EnumTaskReleaseStatus.Stopped" color="#999999" |
| | | >已停止</PageFooterBtn |
| | |
| | | import Taro from '@tarojs/taro'; |
| | | import { useQuery } from '@tanstack/vue-query'; |
| | | import * as taskServices from '@12333/services/apiV2/task'; |
| | | import * as taskUserServices from '@12333/services/apiV2/taskUser'; |
| | | import { useToggle } from 'senin-mini/hooks'; |
| | | import { TaskPrice, TaskDetailWelfareItem } from '@12333/components'; |
| | | import IconAttention from '@/assets/task/icon-attention.png'; |
| | |
| | | import './taskDetail.scss'; |
| | | import CompanyDesc from '../components/CompanyDesc.vue'; |
| | | import dayjs from 'dayjs'; |
| | | import { TaskUtils, toThousand, setOSSLink } from '@12333/utils'; |
| | | import { TaskUtils, toThousand, setOSSLink, Message } from '@12333/utils'; |
| | | import { |
| | | EnumSettlementCycleText, |
| | | BillingMethodEnumUnit, |
| | |
| | | }); |
| | | } |
| | | }); |
| | | |
| | | const handleApply = useAccessLogin(async () => { |
| | | try { |
| | | let params: API.ApplyTaskCommand = { |
| | | ids: [taskId], |
| | | }; |
| | | let res = await taskUserServices.applyTask(params); |
| | | if (res) { |
| | | Message.success('报名成功', { |
| | | onClosed() { |
| | | refetch({ type: 'inactive' }); |
| | | }, |
| | | }); |
| | | } |
| | | } catch (error) {} |
| | | }); |
| | | |
| | | const handleAttention = useAccessLogin(async () => { |
| | | try { |
| | | await Message.confirm({ |
| | | message: `确定${detail.value?.isCollected ? '取消收藏' : '收藏'}吗?`, |
| | | }); |
| | | let params: API.CollectTaskCommand = { |
| | | ids: [taskId], |
| | | isCollect: !detail.value?.isCollected, |
| | | }; |
| | | let res = await taskUserServices.collectTask(params); |
| | | if (res) { |
| | | Message.success('操作成功', { |
| | | onClosed() { |
| | | refetch({ type: 'inactive' }); |
| | | }, |
| | | }); |
| | | } |
| | | } catch (error) {} |
| | | }); |
| | | |
| | | const handleCall = useAccessLogin(() => { |
| | | if (detail.value.contactPhoneNumber) { |
| | | Taro.makePhoneCall({ |
| | | phoneNumber: detail.value.contactPhoneNumber, |
| | | }); |
| | | } |
| | | }); |
| | | </script> |
| | |
| | | </div> |
| | | <div class="task-card-actions" v-if="showActions"> |
| | | <slot name="actions"> |
| | | <nut-button |
| | | v-if="releaseStatus === EnumTaskReleaseStatus.InProcess" |
| | | type="primary" |
| | | @click.stop="emit('apply', id)" |
| | | <nut-button v-if="releaseStatus === EnumTaskReleaseStatus.InProcess" type="primary" |
| | | >报名</nut-button |
| | | > |
| | | </slot> |
| | |
| | | UserResume = 8, |
| | | /**企业信息 */ |
| | | Enterprise = 9, |
| | | /**灵工信息 */ |
| | | EnterpriseEmployee = 10, |
| | | } |
| | | |
| | | /** 资源请求方式 */ |
| | |
| | | /** 任务安排状态 */ |
| | | export enum EnumTaskStatus { |
| | | /**待安排 */ |
| | | Wait = 10, |
| | | /**已安排 */ |
| | | Complete = 20, |
| | | } |
| | | |
| | | /** 任务用户安排状态 */ |
| | | export enum EnumTaskUserArrangeStatus { |
| | | /**未安排 */ |
| | | Wait = 10, |
| | | /**已安排 */ |
| | | Complete = 20, |
New file |
| | |
| | | /* eslint-disable */ |
| | | // @ts-ignore |
| | | import { request } from '@/utils/request'; |
| | | |
| | | /** 查询灵工分页列表数据 POST /api/user/enterpriseEmployee/getEnterpriseEmployees */ |
| | | export async function getEnterpriseEmployees( |
| | | body: API.GetEnterpriseEmployeesQuery, |
| | | options?: API.RequestConfig |
| | | ) { |
| | | return request<API.GetEnterpriseEmployeesQueryResult>( |
| | | '/api/user/enterpriseEmployee/getEnterpriseEmployees', |
| | | { |
| | | method: 'POST', |
| | | headers: { |
| | | 'Content-Type': 'application/json-patch+json', |
| | | }, |
| | | data: body, |
| | | ...(options || {}), |
| | | } |
| | | ); |
| | | } |
| | |
| | | // API 唯一标识: |
| | | import * as userResume from './userResume'; |
| | | import * as resource from './resource'; |
| | | import * as enterpriseEmployee from './enterpriseEmployee'; |
| | | import * as user from './user'; |
| | | import * as dictionary from './dictionary'; |
| | | import * as auth from './auth'; |
| | |
| | | export default { |
| | | userResume, |
| | | resource, |
| | | enterpriseEmployee, |
| | | user, |
| | | dictionary, |
| | | auth, |
| | |
| | | UserResume = 8, |
| | | /**企业信息 */ |
| | | Enterprise = 9, |
| | | /**灵工信息 */ |
| | | EnterpriseEmployee = 10, |
| | | } |
| | | |
| | | enum EnumResourceMethod { |
| | |
| | | |
| | | enum EnumTaskStatus { |
| | | /**待安排 */ |
| | | Wait = 10, |
| | | /**已安排 */ |
| | | Complete = 20, |
| | | } |
| | | |
| | | enum EnumTaskUserArrangeStatus { |
| | | /**未安排 */ |
| | | Wait = 10, |
| | | /**已安排 */ |
| | | Complete = 20, |
| | |
| | | /** 错误码 */ |
| | | errorCode?: string; |
| | | data?: GetEnterpriseElectronSignSettingQueryResult; |
| | | /** 执行成功 */ |
| | | success?: boolean; |
| | | /** 错误信息 */ |
| | | msg?: any; |
| | | /** 附加数据 */ |
| | | extras?: any; |
| | | /** 时间戳 */ |
| | | timestamp?: number; |
| | | } |
| | | |
| | | interface FriendlyResultGetEnterpriseEmployeesQueryResult { |
| | | /** 跟踪Id */ |
| | | traceId?: string; |
| | | /** 状态码 */ |
| | | code?: number; |
| | | /** 错误码 */ |
| | | errorCode?: string; |
| | | data?: GetEnterpriseEmployeesQueryResult; |
| | | /** 执行成功 */ |
| | | success?: boolean; |
| | | /** 错误信息 */ |
| | |
| | | mergeSignCost?: number; |
| | | } |
| | | |
| | | interface GetEnterpriseEmployeesQuery { |
| | | /** 关键字(姓名/手机/身份证号) */ |
| | | keywords?: string; |
| | | /** 登记时间-最早时间 */ |
| | | createdTimeStart?: string; |
| | | /** 登记时间-最晚时间 */ |
| | | createdTimeEnd?: string; |
| | | /** 签约时间-最早时间 */ |
| | | signContractTimeStart?: string; |
| | | /** 签约时间-最晚时间 */ |
| | | signContractTimeEnd?: string; |
| | | hireStatus?: EnumTaskUserHireStatus; |
| | | /** 是否实名 */ |
| | | isReal?: boolean; |
| | | userSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | enterpriseSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | pageModel?: PagedListQueryPageModel; |
| | | } |
| | | |
| | | interface GetEnterpriseEmployeesQueryResult { |
| | | pageModel?: PagedListQueryResultPageModel; |
| | | /** 数据 */ |
| | | data?: GetEnterpriseEmployeesQueryResultItem[]; |
| | | } |
| | | |
| | | interface GetEnterpriseEmployeesQueryResultItem { |
| | | /** 灵工Id */ |
| | | id?: string; |
| | | /** 姓名 */ |
| | | name?: string; |
| | | /** 身份证号 */ |
| | | identity?: string; |
| | | gender?: EnumUserGender; |
| | | /** 年龄 */ |
| | | age?: number; |
| | | /** 手机号 */ |
| | | phoneNumber?: string; |
| | | hireStatus?: EnumTaskUserHireStatus; |
| | | /** 实名状态 */ |
| | | userIsReal?: boolean; |
| | | userSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | /** 录用时间 */ |
| | | hireTime?: string; |
| | | /** 实名时间 */ |
| | | userRealTime?: string; |
| | | /** 签约时间 */ |
| | | userSignContractTime?: string; |
| | | enterpriseSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | /** 企业签约时间 */ |
| | | enterpriseSignContractTime?: string; |
| | | } |
| | | |
| | | interface GetEnterpriseQueryResult { |
| | | /** Id */ |
| | | id?: string; |
| | |
| | | photos?: string[]; |
| | | /** 经历 */ |
| | | taskInfoUsers?: GetUserResumeQueryResultExperience[]; |
| | | /** 报名时间 */ |
| | | createdTime?: string; |
| | | hireStatus?: EnumTaskUserHireStatus; |
| | | /** 录用时间 */ |
| | | hireTime?: string; |
| | | arrangeStatus?: EnumTaskUserArrangeStatus; |
| | | /** 安排状态 */ |
| | | arrangeTime?: string; |
| | | userSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | /** 灵工签约时间 */ |
| | | userSignContractTime?: string; |
| | | enterpriseSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | /** 企业签约时间 */ |
| | | enterpriseSignContractTime?: string; |
| | | /** 电子合同 */ |
| | | contractUrl?: string; |
| | | } |
| | | |
| | | interface GetUserResumeQueryResultCredential { |
| | |
| | | workSeniority?: string; |
| | | /** 工作经验 */ |
| | | workExperience?: string; |
| | | hireStatus?: EnumTaskUserHireStatus; |
| | | /** 录用时间 */ |
| | | hireTime?: string; |
| | | arrangeStatus?: EnumTaskUserArrangeStatus; |
| | | /** 安排状态 */ |
| | | arrangeTime?: string; |
| | | userSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | /** 灵工签约时间 */ |
| | | userSignContractTime?: string; |
| | | enterpriseSignContractStatus?: EnumTaskUserSignContractStatus; |
| | | /** 企业签约时间 */ |
| | | enterpriseSignContractTime?: string; |
| | | } |
| | | |
| | | type GetUserResumeWorkExperienceQuery = Record<string, any>; |