保誠-保戶業務員媒合平台
Mila
2022-01-21 1592d266eb7cea3a096c17d4ae3c0d01c679da7b
update: TODO#134585 串接 顧問主動發送滿意度 API
修改3個檔案
19 ■■■■ 已變更過的檔案
PAMapp/components/Client/ClientCard.vue 6 ●●●● 修補檔 | 檢視 | 原始 | 究查 | 歷程
PAMapp/pages/appointment/_appointmentId/index.vue 9 ●●●● 修補檔 | 檢視 | 原始 | 究查 | 歷程
PAMapp/shared/services/reviews.service.ts 4 ●●●● 修補檔 | 檢視 | 原始 | 究查 | 歷程
PAMapp/components/Client/ClientCard.vue
@@ -179,6 +179,7 @@
import { ElRow } from 'element-ui/types/row';
import { Appointment, AppointmentMemoInfo } from '~/shared/models/appointment.model';
import { ContactStatus } from '~/shared/models/enum/contact-status';
import reviewsService from '~/shared/services/reviews.service';
const appointmentStore = namespace('appointment.store');
const localStorage     = namespace('localStorage');
@@ -271,7 +272,10 @@
    }
    inviteReview(): void {
      this.isShowInviteReviewDialog = true ;
        reviewsService.sendSatisfactionToClient(this.client.id).then(res => {
            this.isShowInviteReviewDialog = true ;
        })
    }
    openDetail() {
PAMapp/pages/appointment/_appointmentId/index.vue
@@ -51,7 +51,7 @@
      </div>
      <div class="client-detail-action" v-if="showWhenAppointmentHasClosed">
        <el-button >發送滿意度</el-button>
        <el-button @click="inviteReview">發送滿意度</el-button>
      </div>
      <div class="client-detail-action" v-else>
@@ -88,6 +88,9 @@
import { Appointment } from '~/shared/models/appointment.model';
import { ContactStatus } from '~/shared/models/enum/contact-status';
import reviewsService from '~/shared/services/reviews.service';
const appointmentStore = namespace('appointment.store');
@@ -133,6 +136,10 @@
    const result = hopeContactTimeString.replace("'", '').split('、');
    return result;
  }
  inviteReview(): void {
    reviewsService.sendSatisfactionToClient(this.appointmentDetail.id).then(res => res);
  }
}
</script>
PAMapp/shared/services/reviews.service.ts
@@ -16,8 +16,8 @@
  }
  // 顧問主動發送滿意度通知
  sendSatisfactionToClient(appointmentId: number): void {
    http.post('/consultant/sendSatisfactionToClient/').then((res) => res);
  sendSatisfactionToClient(appointmentId: number) {
    return http.post(`/consultant/sendSatisfactionToClient/${appointmentId}`).then((res) => res);
  }
}