| | |
| | | } |
| | | } |
| | | |
| | | // TODO: 調整程式碼 [Tomas, 2022/1/14 12:02] |
| | | private redirectAppointmentStatus() { |
| | | const currentAppointmentIndex = this.myAppointmentList |
| | | .findIndex(item => item.id === +this.currentAppointmentIdFromMsg); |
| | | if (currentAppointmentIndex > -1) { |
| | | const communicateStatus = this.myAppointmentList[currentAppointmentIndex].communicateStatus; |
| | | const pathName = communicateStatus === 'reserved' ? 'appointmentList' : 'closedList'; |
| | | let pathName = 'closedList' |
| | | if (communicateStatus === this.contactStatus.RESERVED || communicateStatus === this.contactStatus.PICKED) { |
| | | pathName = 'contactedList'; |
| | | } |
| | | if (communicateStatus === this.contactStatus.CONTACTED) { |
| | | pathName = 'contactedList'; |
| | | } |
| | | this.$router.push( |
| | | { |
| | | path: '/myAppointmentList/' + pathName, |