| | |
| | | @click="reserveCommunication" |
| | | :class="actionBtnStyle" |
| | | >{{ actionBtnLabel }}</el-button> |
| | | <div |
| | | v-if="notScoreAppointmentYet" |
| | | class="text--primary mt-10 text--center text--underline cursor--pointer" |
| | | @click="reviewsBtn = true">給予滿意度評分</div> |
| | | <div class="updateTime mt-10"> |
| | | {{ displayTime | formatDate }} |
| | | {{ agentInfo.updateTime | formatDate }} |
| | | </div> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | } |
| | | } |
| | | |
| | | get displayTime(): string { |
| | | const isAppointment = !!this.agentInfo['appointmentStatus']; |
| | | let time: Date | string = ''; |
| | | if (isAppointment) { |
| | | time = this.agentInfo['appointmentDate']; |
| | | } else { |
| | | switch(this.agentInfo.contactStatus) { |
| | | case 'reserved': |
| | | time = this.agentInfo.updateTime; |
| | | break; |
| | | case 'picked': |
| | | time = this.agentInfo.updateTime; |
| | | break; |
| | | } |
| | | } |
| | | if (typeof time !== 'string') { |
| | | time.toString(); |
| | | } |
| | | return time as string; |
| | | } |
| | | |
| | | get avatarFileName() { |
| | | return this.agentInfo.img; |
| | | } |
| | |
| | | } |
| | | |
| | | userReviewsConsultants() { |
| | | const isAppointment = !!this.agentInfo['appointmentStatus']; |
| | | const appointmentId = isAppointment |
| | | ? this.agentInfo['appointmentId'] |
| | | : this.latestReservedAppointment.id; |
| | | |
| | | const reviewParams: UserReviewsConsultantsParams = { |
| | | appointmentId: this.appointmentDetail.id, |
| | | appointmentId: appointmentId, |
| | | score: this.inputScore, |
| | | } |
| | | this.appointmentDetail.satisfactionScore = this.inputScore; |