保誠-保戶業務員媒合平台
Tomas
2022-01-21 caae1271160c08f2e4af596325b9d7616dc13946
PAMapp/components/Client/ClientCard.vue
@@ -210,7 +210,7 @@
    updateMyAppointmentList!: (data: Appointment) => void;
    @appointmentStore.Action
    setAppointmentDetail!: (appointmentId: number) => Promise<Appointment>;
    getAppointmentDetail!: (appointmentId: number) => Promise<Appointment>;
    @appointmentStore.Getter
    appointmentProgress!: ContactStatus;
@@ -256,7 +256,8 @@
    //////////////////////////////////////////////////////////////////////
    viewAppointmentDetail(): void {
      this.setAppointmentDetail(this.client.id).then((_) => {
      this.getAppointmentDetail(this.client.id).then((_) => {
        this.readAppointment();
        this.$router.push(`/appointment/${this.client.id}`);
      });
    }
@@ -289,7 +290,13 @@
    }
    closeInformDialog(): void {
      const unread = !this.client.consultantReadTime;
        this.readAppointment();
        this.isEdit = false;
        this.clearAppointmentIdFromMsg();
    }
    private readAppointment(): void {
        const unread = !this.client.consultantReadTime;
        if (unread) {
            appointmentService.recordRead(this.client.id).then((_) => {
                const updatedClient = {...this.client};
@@ -297,8 +304,6 @@
                this.updateMyAppointmentList(updatedClient);
            });
        };
        this.isEdit = false;
        this.clearAppointmentIdFromMsg();
    }
    private clearAppointmentIdFromMsg() {