| | |
| | | @click.stop="handleUnsign(item)" |
| | | >解约</nut-button |
| | | > |
| | | <nut-button type="primary" @click.stop="checkContract">查看合约</nut-button> |
| | | <nut-button type="primary" @click.stop="checkContract(item)">查看合约</nut-button> |
| | | </template> |
| | | <nut-button |
| | | v-else-if=" |
| | |
| | | } from '@12333/constants'; |
| | | import * as enterpriseEmployeeServices from '@12333/services/apiV2/enterpriseEmployee'; |
| | | import Taro from '@tarojs/taro'; |
| | | import { Message } from '@12333/utils'; |
| | | import { Message, setOSSLink } from '@12333/utils'; |
| | | |
| | | defineOptions({ |
| | | name: 'InnerPage', |
| | |
| | | userSignContractStatus: EnumTaskUserSignContractStatus.Pass, |
| | | }); |
| | | |
| | | const { infiniteLoadingProps } = useInfiniteLoading( |
| | | const { infiniteLoadingProps, invalidateQueries } = useInfiniteLoading( |
| | | ({ pageParam }) => { |
| | | let params: API.GetEnterpriseEmployeesQuery = { |
| | | pageModel: { |
| | |
| | | } |
| | | ); |
| | | |
| | | function checkContract() {} |
| | | function checkContract(item: API.GetEnterpriseEmployeesQueryResultItem) { |
| | | const encodedUrl = encodeURIComponent(setOSSLink(item.contractUrl)); |
| | | Taro.navigateTo({ |
| | | url: `${RouterPath.flexJobManageExtraPage}?url=${encodedUrl}`, |
| | | }); |
| | | } |
| | | |
| | | function goDetail(item: API.GetEnterpriseEmployeesQueryResultItem) { |
| | | Taro.navigateTo({ |
| | |
| | | async function handleUnsign(item: API.GetEnterpriseEmployeesQueryResultItem) { |
| | | try { |
| | | await Message.confirm({ message: '确定要解约吗?' }); |
| | | let params: API.StopElectronSignCommand = { |
| | | ids: [item.id], |
| | | }; |
| | | let res = await enterpriseEmployeeServices.stopElectronSign(params); |
| | | if (res) { |
| | | Message.success('解约成功'); |
| | | invalidateQueries(); |
| | | } |
| | | } catch (error) {} |
| | | } |
| | | function goFlexJobSign(item: API.GetEnterpriseEmployeesQueryResultItem) { |