|
@@ -3,7 +3,7 @@
|
|
<ion-header>
|
|
<ion-header>
|
|
<ion-toolbar>
|
|
<ion-toolbar>
|
|
<ion-buttons slot="start">
|
|
<ion-buttons slot="start">
|
|
- <ion-icon :icon="arrowBackOutline" @click="onCancel" style="padding-left:10px;width:24px;height:24px;"></ion-icon>
|
|
|
|
|
|
+ <ion-icon :icon="arrowBackOutline" @click="onBack" style="padding-left:10px;width:24px;height:24px;"></ion-icon>
|
|
</ion-buttons>
|
|
</ion-buttons>
|
|
<ion-title>求职信息录入</ion-title>
|
|
<ion-title>求职信息录入</ion-title>
|
|
</ion-toolbar>
|
|
</ion-toolbar>
|
|
@@ -207,7 +207,7 @@
|
|
<ion-item v-for="(record,key) in educationList" :key="key" >
|
|
<ion-item v-for="(record,key) in educationList" :key="key" >
|
|
<ion-label>
|
|
<ion-label>
|
|
<h3>{{record.schoolName}}</h3>
|
|
<h3>{{record.schoolName}}</h3>
|
|
- <p>{{record.schoolTime}}至{{record.overTime}}</p>
|
|
|
|
|
|
+ <p>{{record.schoolTimeStr}}至{{record.overTimeStr}}</p>
|
|
</ion-label>
|
|
</ion-label>
|
|
<img alt="" src="@/assets/icon/forward.png" style="width:32px;height:32px;"
|
|
<img alt="" src="@/assets/icon/forward.png" style="width:32px;height:32px;"
|
|
@click="onPathForward('./educationEdit',record.educationID,null,2)" />
|
|
@click="onPathForward('./educationEdit',record.educationID,null,2)" />
|
|
@@ -232,9 +232,8 @@
|
|
@click="onPathForward( './jobHuntEdit',null,record.jobHuntID,3)" />
|
|
@click="onPathForward( './jobHuntEdit',null,record.jobHuntID,3)" />
|
|
</ion-item>
|
|
</ion-item>
|
|
</ion-list>
|
|
</ion-list>
|
|
-
|
|
|
|
<ion-button class="next-btn" type="submit" v-if="curStepData.statusVal!=3">下一步</ion-button>
|
|
<ion-button class="next-btn" type="submit" v-if="curStepData.statusVal!=3">下一步</ion-button>
|
|
- <ion-button class="next-btn" @click="onCancel" v-if="curStepData.statusVal==3">完 成</ion-button>
|
|
|
|
|
|
+ <ion-button class="next-btn" @click="onFinish" v-if="curStepData.statusVal==3">完 成</ion-button>
|
|
</form>
|
|
</form>
|
|
</ion-content>
|
|
</ion-content>
|
|
</ion-page>
|
|
</ion-page>
|
|
@@ -245,18 +244,26 @@ import {reactive,defineComponent, computed,watch,ref,toRefs} from "vue";
|
|
import {useRoute, useRouter} from "vue-router";
|
|
import {useRoute, useRouter} from "vue-router";
|
|
import {required} from "@vuelidate/validators";
|
|
import {required} from "@vuelidate/validators";
|
|
import {useVuelidate} from "@vuelidate/core";
|
|
import {useVuelidate} from "@vuelidate/core";
|
|
-import {getDataById, baseInfoSave, getEducationList} from "@/api/jobUserInfo";
|
|
|
|
|
|
+import {getRegionCodeList,getStreetCodeList} from "@/api/system/area";
|
|
|
|
+import {getDataById,baseInfoSave} from "@/api/jobUserInfo";
|
|
import {getEducationListByJobUserID} from "@/api/education";
|
|
import {getEducationListByJobUserID} from "@/api/education";
|
|
-import {getRegionCodeList, getStreetCodeList} from "@/api/system/area";
|
|
|
|
|
|
+import {getJobHuntListByJobUserID} from "@/api/jobHuntInfo";
|
|
import {getSiteDataList} from "@/api/siteInfo";
|
|
import {getSiteDataList} from "@/api/siteInfo";
|
|
-import {getJobHuntListByJobUserID,jobHuntSave} from "@/api/jobHuntInfo";
|
|
|
|
import {getSysDictionaryList} from '@/api/system/dictionary';
|
|
import {getSysDictionaryList} from '@/api/system/dictionary';
|
|
-import {alertController} from "@ionic/vue";
|
|
|
|
|
|
+import {alertController, onIonViewDidEnter} from "@ionic/vue";
|
|
|
|
+import dayjs from "dayjs";
|
|
|
|
|
|
interface SelectProps {
|
|
interface SelectProps {
|
|
name: string,
|
|
name: string,
|
|
value: string
|
|
value: string
|
|
}
|
|
}
|
|
|
|
+interface educationModel{
|
|
|
|
+ schoolName:string,
|
|
|
|
+ schoolTimeStr:string,
|
|
|
|
+ schoolTime:Date,
|
|
|
|
+ overTimeStr:string
|
|
|
|
+ overTime:Date
|
|
|
|
+}
|
|
interface StepParams{
|
|
interface StepParams{
|
|
name: string,
|
|
name: string,
|
|
statusVal: number
|
|
statusVal: number
|
|
@@ -289,11 +296,11 @@ export default defineComponent({
|
|
const regionList = ref<SelectProps[]>([]);
|
|
const regionList = ref<SelectProps[]>([]);
|
|
const streetList = ref<SelectProps[]>([]);
|
|
const streetList = ref<SelectProps[]>([]);
|
|
|
|
|
|
- const educationList = ref<SelectProps[]>([]);
|
|
|
|
|
|
+
|
|
|
|
+ const educationList = ref<educationModel[]>([]);
|
|
const jobHuntList = ref<SelectProps[]>([]);
|
|
const jobHuntList = ref<SelectProps[]>([]);
|
|
|
|
|
|
const baseInfoData = reactive({baseData:{
|
|
const baseInfoData = reactive({baseData:{
|
|
-
|
|
|
|
jobUserID:null,
|
|
jobUserID:null,
|
|
name:null,
|
|
name:null,
|
|
identityNumber: null,
|
|
identityNumber: null,
|
|
@@ -352,7 +359,6 @@ export default defineComponent({
|
|
|
|
|
|
await alert.present();
|
|
await alert.present();
|
|
}
|
|
}
|
|
-
|
|
|
|
const onSave = async function (){
|
|
const onSave = async function (){
|
|
if (curStepData.value.statusVal==1){
|
|
if (curStepData.value.statusVal==1){
|
|
const isFormCorrect = await baseDataValid.value.$validate();
|
|
const isFormCorrect = await baseDataValid.value.$validate();
|
|
@@ -362,23 +368,34 @@ export default defineComponent({
|
|
}
|
|
}
|
|
baseInfoSave(baseInfoData.baseData).then(result => {
|
|
baseInfoSave(baseInfoData.baseData).then(result => {
|
|
if (result) {
|
|
if (result) {
|
|
- router.push({path: './edit', query: {jobUserID: baseInfoData.baseData.jobUserID,status:2}});
|
|
|
|
|
|
+ router.push({path: './edit', query: {reload:1,jobUserID: baseInfoData.baseData.jobUserID,status:2}});
|
|
}
|
|
}
|
|
});
|
|
});
|
|
}
|
|
}
|
|
- else if(curStepData.value.statusVal==2){
|
|
|
|
- router.push({path: './edit', query: {jobUserID: baseInfoData.baseData.jobUserID,status:3}});
|
|
|
|
|
|
+ else{
|
|
|
|
+ await router.push({path: './edit', query: {reload:1,jobUserID: baseInfoData.baseData.jobUserID,status:3}});
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
const onPathForward = (pathValue:string,educationIDValue:any,jobHuntIDValue:any,statusValue:any)=>{
|
|
const onPathForward = (pathValue:string,educationIDValue:any,jobHuntIDValue:any,statusValue:any)=>{
|
|
- router.push({path: pathValue, query: {educationID:educationIDValue,jobHuntID:jobHuntIDValue,jobUserID: baseInfoData.baseData.jobUserID,status:statusValue}});
|
|
|
|
|
|
+ router.push({path: pathValue, query: {reload:1,educationID:educationIDValue,jobHuntID:jobHuntIDValue,jobUserID: baseInfoData.baseData.jobUserID,status:statusValue}});
|
|
}
|
|
}
|
|
|
|
|
|
-
|
|
|
|
- const onCancel = () => {
|
|
|
|
|
|
+ const onFinish = () => {
|
|
router.push("./list");
|
|
router.push("./list");
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ const onBack = () => {
|
|
|
|
+ const toStepValue :number = curStepData.value.statusVal-1;
|
|
|
|
+ console.log("toStepValue",toStepValue);
|
|
|
|
+ console.log("jobUserID",baseInfoData.baseData.jobUserID);
|
|
|
|
+ if(toStepValue > 0){
|
|
|
|
+ router.push({path: './edit', query: {reload:1,jobUserID: baseInfoData.baseData.jobUserID,toStepValue}});
|
|
|
|
+ }else{
|
|
|
|
+ router.push("./list");
|
|
|
|
+ }
|
|
|
|
+ }
|
|
|
|
+
|
|
const getSiteInfoList = async function(){
|
|
const getSiteInfoList = async function(){
|
|
const siteInfoResult :any = await getSiteDataList();
|
|
const siteInfoResult :any = await getSiteDataList();
|
|
siteInfoList.value = siteInfoResult;
|
|
siteInfoList.value = siteInfoResult;
|
|
@@ -431,21 +448,11 @@ export default defineComponent({
|
|
await regionChange();
|
|
await regionChange();
|
|
}
|
|
}
|
|
|
|
|
|
-
|
|
|
|
const loadData = async (jobUserID: any,status:any) => {
|
|
const loadData = async (jobUserID: any,status:any) => {
|
|
pageParams.jobUserID = jobUserID;
|
|
pageParams.jobUserID = jobUserID;
|
|
|
|
+ baseInfoData.baseData.jobUserID = jobUserID;
|
|
curStepData.value.statusVal = status;
|
|
curStepData.value.statusVal = status;
|
|
if(curStepData.value.statusVal==1){
|
|
if(curStepData.value.statusVal==1){
|
|
- await getSiteInfoList();
|
|
|
|
- await getGenderList();
|
|
|
|
- await getJobUserStatusList();
|
|
|
|
- await getKeyPersonTypeList();
|
|
|
|
- await getCultureRankList();
|
|
|
|
- await getHealthTypeList();
|
|
|
|
- await getBloodTypeList();
|
|
|
|
- await getMaritalStatusList();
|
|
|
|
- await getRegionList();
|
|
|
|
- await getStreetList();
|
|
|
|
const reqData = await getDataById(jobUserID);
|
|
const reqData = await getDataById(jobUserID);
|
|
baseInfoData.baseData = reqData;
|
|
baseInfoData.baseData = reqData;
|
|
console.log('baseData',baseInfoData.baseData);
|
|
console.log('baseData',baseInfoData.baseData);
|
|
@@ -453,6 +460,11 @@ export default defineComponent({
|
|
else if(curStepData.value.statusVal==2){
|
|
else if(curStepData.value.statusVal==2){
|
|
const data :any = await getEducationListByJobUserID(pageParams);
|
|
const data :any = await getEducationListByJobUserID(pageParams);
|
|
educationList.value = data.list;
|
|
educationList.value = data.list;
|
|
|
|
+ educationList.value.map(item=>{
|
|
|
|
+ item.schoolTimeStr = dayjs(item.schoolTime).format('YYYY-MM-DD');
|
|
|
|
+ item.overTimeStr = dayjs(item.overTime).format('YYYY-MM-DD');
|
|
|
|
+ })
|
|
|
|
+ console.log('educationList',educationList.value);
|
|
}
|
|
}
|
|
else if(curStepData.value.statusVal==3){
|
|
else if(curStepData.value.statusVal==3){
|
|
const reqData = await getJobHuntListByJobUserID(pageParams);
|
|
const reqData = await getJobHuntListByJobUserID(pageParams);
|
|
@@ -461,11 +473,20 @@ export default defineComponent({
|
|
};
|
|
};
|
|
|
|
|
|
watch(() => route.query, () => {
|
|
watch(() => route.query, () => {
|
|
- if (route.query) {
|
|
|
|
- loadData(route.query.id,route.query.status);
|
|
|
|
|
|
+ if (route.query.reload) {
|
|
|
|
+ loadData(route.query.jobUserID,route.query.status);
|
|
}
|
|
}
|
|
});
|
|
});
|
|
|
|
|
|
|
|
+ const reload = (jobUserID:any,status:any) => {
|
|
|
|
+ loadData(jobUserID,status);
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ onIonViewDidEnter(() => {
|
|
|
|
+ if (route.query.reload)
|
|
|
|
+ reload(route.query.jobUserID,route.query.status);
|
|
|
|
+ });
|
|
|
|
+
|
|
return {
|
|
return {
|
|
...toRefs(baseInfoData),
|
|
...toRefs(baseInfoData),
|
|
arrowBackOutline,
|
|
arrowBackOutline,
|
|
@@ -492,15 +513,37 @@ export default defineComponent({
|
|
provinceChange,
|
|
provinceChange,
|
|
regionChange,
|
|
regionChange,
|
|
onSave,
|
|
onSave,
|
|
- onCancel,
|
|
|
|
|
|
+ onBack,
|
|
|
|
+ onFinish,
|
|
onPathForward,
|
|
onPathForward,
|
|
loadData,
|
|
loadData,
|
|
|
|
+ reload,
|
|
route,
|
|
route,
|
|
router,
|
|
router,
|
|
baseDataValid,
|
|
baseDataValid,
|
|
|
|
+ getSiteInfoList,
|
|
|
|
+ getGenderList,
|
|
|
|
+ getJobUserStatusList,
|
|
|
|
+ getKeyPersonTypeList,
|
|
|
|
+ getCultureRankList,
|
|
|
|
+ getHealthTypeList,
|
|
|
|
+ getBloodTypeList,
|
|
|
|
+ getMaritalStatusList,
|
|
|
|
+ getRegionList,
|
|
|
|
+ getStreetList
|
|
}
|
|
}
|
|
},
|
|
},
|
|
mounted(){
|
|
mounted(){
|
|
|
|
+ this.getSiteInfoList();
|
|
|
|
+ this.getGenderList();
|
|
|
|
+ this.getJobUserStatusList();
|
|
|
|
+ this.getKeyPersonTypeList();
|
|
|
|
+ this.getCultureRankList();
|
|
|
|
+ this.getHealthTypeList();
|
|
|
|
+ this.getBloodTypeList();
|
|
|
|
+ this.getMaritalStatusList();
|
|
|
|
+ this.getRegionList();
|
|
|
|
+ this.getStreetList();
|
|
const jobUserID = this.route.query.jobUserID;
|
|
const jobUserID = this.route.query.jobUserID;
|
|
const status = this.route.query.status;
|
|
const status = this.route.query.status;
|
|
this.loadData(jobUserID,status);
|
|
this.loadData(jobUserID,status);
|