|
@@ -41,15 +41,10 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
-
|
|
|
- <CtDialog :visible="show" title="同意面试邀请" :footer="true" widthType="2" @close="handleClose" @submit="handleSubmit">
|
|
|
- <TextInput v-model="query.phone" :item="textItem"></TextInput>
|
|
|
- </CtDialog>
|
|
|
</template>
|
|
|
|
|
|
<script setup>
|
|
|
defineOptions({ name: 'interview-item'})
|
|
|
-import { ref } from 'vue'
|
|
|
import { useI18n } from '@/hooks/web/useI18n'
|
|
|
import { timesTampChange } from '@/utils/date'
|
|
|
import { userInterviewInviteReject, userInterviewInviteConsent } from '@/api/recruit/personal/personalCenter'
|
|
@@ -64,16 +59,6 @@ const props = defineProps({
|
|
|
default: () => []
|
|
|
}
|
|
|
})
|
|
|
-const show = ref(false)
|
|
|
-const query = ref({
|
|
|
- id: null,
|
|
|
- phone: null
|
|
|
-})
|
|
|
-const textItem = ref({
|
|
|
- type: 'text',
|
|
|
- clearable: true,
|
|
|
- label: '联系号码 *'
|
|
|
-})
|
|
|
|
|
|
// 企业详情
|
|
|
const handleToEnterprise = (item) => {
|
|
@@ -85,29 +70,20 @@ const handleToEnterprise = (item) => {
|
|
|
// 同意
|
|
|
const handleAgree = (val) => {
|
|
|
if (!val.id) return
|
|
|
- query.value.id = val.id
|
|
|
+ const query = {
|
|
|
+ id: val.id
|
|
|
+ }
|
|
|
const baseInfo = localStorage.getItem('baseInfo')
|
|
|
if (baseInfo) {
|
|
|
const { phone } = JSON.parse(baseInfo)
|
|
|
- query.value.phone = phone
|
|
|
+ query.phone = phone
|
|
|
}
|
|
|
- show.value = true
|
|
|
-}
|
|
|
|
|
|
-const handleClose = () => {
|
|
|
- show.value = false
|
|
|
- query.value = {
|
|
|
- id: null,
|
|
|
- phone: null
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-const handleSubmit = async () => {
|
|
|
- if (!query.value.phone) return Snackbar.warning('请填写您的联系号码')
|
|
|
- await userInterviewInviteConsent(query.value)
|
|
|
- Snackbar.success(t('common.operationSuccessful'))
|
|
|
- handleClose()
|
|
|
- emits('refresh')
|
|
|
+ Confirm(t('common.confirmTitle'), '是否确定接收此面试邀请?').then(async () => {
|
|
|
+ await userInterviewInviteConsent(query)
|
|
|
+ Snackbar.success(t('common.operationSuccessful'))
|
|
|
+ emits('refresh')
|
|
|
+ })
|
|
|
}
|
|
|
|
|
|
// 拒绝
|