保誠-保戶業務員媒合平台
Mila
2021-12-22 68e499e5eed17a2b1d2e47ee1790e16f001552f7
PAMapp/pages/questionnaire/_agentNo.vue
@@ -143,8 +143,9 @@
import { getRequestsFromStorage, removeRequestQuestionFromStorage, setRequestsToStorage } from '~/shared/storageRequests';
import _ from 'lodash';
import queryConsultantService from '~/shared/services/query-consultant.service';
import appointmentService from '~/shared/services/appointment.service';
import authService from '~/shared/services/auth.service';
import queryConsultantService from '~/shared/services/query-consultant.service';
import { Consultant } from '~/shared/models/consultant.model';
import { ContactType } from '~/shared/models/enum/ContactType';
import { Gender } from '~/shared/models/enum/Gender';
@@ -280,7 +281,7 @@
    beforeRouteEnter(to: any, from: any, next: any) {
      next(vm => {
        const isUserLogin = vm.$store.getters['localStorage/isUserLogin'];
        const isUserLogin = authService.isUserLogin();
        if (from.name === 'login' && !isUserLogin) {
          vm.$router.go(-1);
          return;
@@ -293,7 +294,7 @@
    }
    async fetch() {
      if (this.isUserLogin) {
      if (authService.isUserLogin()) {
        await this.storeConsultantList();
      };
    }
@@ -451,7 +452,7 @@
                  : appointmentInfo.appointmentDate;
    }
    @Watch('myConsultantList') onMyConsultantListChange() {
      if (this.isUserLogin && this.myConsultantList.length > 0) {
      if (authService.isUserLogin() && this.myConsultantList.length > 0) {
          const editAppointment = this.getLatestReserved(this.$route.params.agentNo);
          if (editAppointment && editAppointment.agentNo) {