| | |
| | | }; |
| | | return statusMap[this.callStatus]; |
| | | }, |
| | | countdownText() { |
| | | if (this.sipStatus !== "已注册") return ""; |
| | | |
| | | const { canCall, reason } = sipService.canMakeCall(); |
| | | if (!canCall && reason.includes("等待")) { |
| | | return reason; |
| | | } |
| | | return ""; |
| | | }, |
| | | callStatusClass() { |
| | | return `status-${this.callStatus}`; |
| | | }, |
| | |
| | | } |
| | | |
| | | try { |
| | | // 先检查是否可以呼叫 |
| | | const { canCall, reason } = sipService.canMakeCall(); |
| | | if (!canCall) { |
| | | this.$message.warning(reason); |
| | | return; |
| | | } |
| | | this.callStatus = "calling"; |
| | | this.isCalling = true; |
| | | console.log('开始呼叫:',sipService); |