保誠-保戶業務員媒合平台
update#132068: 嚴選配對篩選後,進行預約,想要詢問的問題等沒有自動帶入
修改4個檔案
114 ■■■■■ 已變更過的檔案
PAMapp/assets/ts/api/consultant.ts 32 ●●●● 修補檔 | 檢視 | 原始 | 究查 | 歷程
PAMapp/pages/agentInfo/_agentNo.vue 33 ●●●● 修補檔 | 檢視 | 原始 | 究查 | 歷程
PAMapp/pages/questionnaire/_agentNo.vue 45 ●●●●● 修補檔 | 檢視 | 原始 | 究查 | 歷程
PAMapp/pages/recommendConsultant/index.vue 4 ●●●● 修補檔 | 檢視 | 原始 | 究查 | 歷程
PAMapp/assets/ts/api/consultant.ts
@@ -167,26 +167,26 @@
    agentNo        : string
}
export interface StrictQueryParams{
    gender:           string;
    avgScore:         number;
    status:           string; //phase 1 disable
    area:             string;
    requirements:     string[];
    gender          : string;
    avgScore        : number;
    status          : string;    //phase 1 disable
    area            : string;
    requirements    : string[];
    otherRequirement: string;
    seniority:        string;
    popularTags:      string[];
    seniority       : string;
    popularTags     : string[];
    otherPopularTags: string;
}
export interface AgentOfStrictQuery {
    agentNo:       string;
    name:          string;
    img:           string;
    expertise:     string[];
    avgScore:      number;
    agentNo      : string;
    name         : string;
    img          : string;
    expertise    : string[];
    avgScore     : number;
    contactStatus: null;
    updateTime:    null;
    seniority:     string;
    new:           boolean;
    updateTime   : null;
    seniority    : string;
    new          : boolean;
}
export interface RequestOfLoginSuccess{
  id_token: string;
@@ -230,4 +230,4 @@
export interface UserReviewsConsultantsParams{
    appointmentId:number,
    score:number,
}
}
PAMapp/pages/agentInfo/_agentNo.vue
@@ -218,7 +218,6 @@
  alertFieldInfo(field: string): void {
    this.isAlertFieldInfo = true;
    console.log(field);
    switch(field) {
      case 'suitability':
        this.fieldInfoTitle = '匹配度';
@@ -233,23 +232,23 @@
}
interface AgentInfo {
  name: string;
  agentNo:string;
  role: string;
  image: string;
  avgScore: number;
  title: string;
  phoneNumber: string;
  serveArea: string;
  companyAddress: string;
  name            : string;
  agentNo         : string;
  role            : string;
  image           : string;
  avgScore        : number;
  title           : string;
  phoneNumber     : string;
  serveArea       : string;
  companyAddress  : string;
  lastestLoginTime: Date | null;
  seniority: string;
  suitability: number;
  evaluation: number;
  expertises: string[];
  concept: string;
  experiences: string[];
  awards: string;
  seniority       : string;
  suitability     : number;
  evaluation      : number;
  expertises      : string[];
  concept         : string;
  experiences     : string[];
  awards          : string;
}
</script>
PAMapp/pages/questionnaire/_agentNo.vue
@@ -128,13 +128,13 @@
</template>
<script lang="ts">
  import { Vue, Component, namespace } from 'nuxt-property-decorator';
  import { Vue, Component } from 'nuxt-property-decorator';
  import { addFavoriteConsultant, appointmentDemand, AppointmentParams, AppointmentRequests ,RegisterInfo } from '~/assets/ts/api/consultant';
  import { getRequestsFromStorage, setRequestsToStorage } from '~/assets/ts/storageRequests';
  import { getRequestsFromStorage, setRequestsToStorage, getRequestQuestionFromStorage, removeRequestQuestionFromStorage  } from '~/assets/ts/storageRequests';
  import { Gender } from '~/assets/ts/models/enum/Gender';
  import { ContactType } from '~/assets/ts/models/enum/ContactType';
  import _ from 'lodash';
import { isLogin } from '~/assets/ts/auth';
  import { isLogin } from '~/assets/ts/auth';
  @Component
  export default class Questionnaire extends Vue {
@@ -171,8 +171,8 @@
        label:'保單健檢/規劃',
      },
      {
        title:'分紅保單相關',
        label:'分紅保單相關',
        title:'分紅保單',
        label:'分紅保單',
      },
    ];
@@ -239,15 +239,15 @@
    ];
    myRequest: AppointmentRequests = {
      phone: this.userInfo?.phone ? this.userInfo.phone :'',
      email: this.userInfo?.email ? this.userInfo.email :'',
      contactType: _.isEqual(this.userInfo?.contactType,ContactType.SMS) ? ContactType.PHONE : ContactType.EMAIL  ,
      gender: '',
      age: '',
      job: '',
      requirement: [],
      phone          : this.userInfo?.phone ? this.userInfo.phone                               : '',
      email          : this.userInfo?.email ? this.userInfo.email                               : '',
      contactType    : _.isEqual(this.userInfo?.contactType,ContactType.SMS) ? ContactType.PHONE: ContactType.EMAIL,
      gender         : '',
      age            : '',
      job            : '',
      requirement    : [],
      hopeContactTime: [{
        selectWeekOptions: [],
        selectWeekOptions : [],
        selectTimesOptions: [],
      }],
      agentNo: '',
@@ -256,7 +256,7 @@
    showDrawer= false;
    sendReserve = false;
    beforeRouteEnter (to, from, next) {
    beforeRouteEnter(to: any, from: any, next: any) {
      next(vm => {
        if (from.name === 'login' && !isLogin()) {
          vm.$router.go(-1);
@@ -268,8 +268,15 @@
        }
      })
    }
    mounted() {
    mounted(): void {
      this.setMyRequest();
    }
    private setMyRequest(): void {
      const storageMyRequest = getRequestsFromStorage();
      const storageMyQuestion = getRequestQuestionFromStorage();
      if (storageMyRequest) {
        this.myRequest = {
          ...storageMyRequest,
@@ -281,6 +288,14 @@
                              }],
        };
      }
      if (storageMyQuestion) {
        this.myRequest = {
          ...this.myRequest,
          requirement: storageMyQuestion
        }
        removeRequestQuestionFromStorage();
      }
    }
    get phoneValid(): boolean {
PAMapp/pages/recommendConsultant/index.vue
@@ -82,6 +82,7 @@
    </PopUpFrame>
  </div>
</template>
<script lang="ts">
  import {
    Vue,
@@ -93,6 +94,7 @@
  } from 'nuxt-property-decorator';
  import * as _ from 'lodash';
  import { Seniority } from '~/assets/ts/models/enum/seniority';
  import { setRequestQuestionToStorage } from '~/assets/ts/storageRequests';
  const localStorage = namespace('localStorage');
@@ -238,6 +240,8 @@
    }
    async makePair() {
      await this.storeStrictQueryList(this.strictQueryDto).then(dataLength => {
        const questions = this.strictQueryDto.requirements.length ? this.strictQueryDto.requirements : [];
        setRequestQuestionToStorage(questions);
        if (dataLength === 0) {
          this.isVisiblePopUp = true;
          return;