|
@@ -2,7 +2,7 @@
|
|
|
<v-btn
|
|
|
color="pink"
|
|
|
class="callBtn"
|
|
|
- :class="{'showingAll': showCalleeDetails, 'active': call && call.time_limit > 0}"
|
|
|
+ :class="{'showingAll': showCalleeDetails, 'active': (callWidget.active && callWidget.callInfo && (callWidget.callInfo.time_limit > 0 || callWidget.callInfo.time_limit == null))}"
|
|
|
dark
|
|
|
absolute
|
|
|
bottom
|
|
@@ -10,28 +10,28 @@
|
|
|
ripple
|
|
|
@click="shiftForm"
|
|
|
>
|
|
|
- <div v-if="call">
|
|
|
+ <div v-if="callWidget.active">
|
|
|
<div class="d-flex flex-row align-items-center btnHeader">
|
|
|
<v-icon>mdi-video</v-icon>
|
|
|
- <div class="ml-2 incomingCallMsg">Incoming Call {{!showCalleeDetails ? `(${call.time_limit})` : ''}}</div>
|
|
|
+ <div class="ml-2 incomingCallMsg">Incoming Call {{!showCalleeDetails && callWidget.callInfo.time_limit !== null ? `(${callWidget.callInfo.time_limit})` : ''}}</div>
|
|
|
</div>
|
|
|
<div class="fullDetails mt-3">
|
|
|
<div class="d-flex flex-row justify-content-between">
|
|
|
<span>Callee:</span>
|
|
|
- <span>{{call.user_type}}</span>
|
|
|
+ <span>{{callWidget.callInfo.user_type}}</span>
|
|
|
</div>
|
|
|
|
|
|
<div class="d-flex flex-row justify-content-between">
|
|
|
<span>Lobby:</span>
|
|
|
- <span>{{call.lobby || 'None'}}</span>
|
|
|
+ <span>{{callWidget.callInfo.lobby || 'None'}}</span>
|
|
|
</div>
|
|
|
|
|
|
- <div class="d-flex flex-row justify-content-between mt-2">
|
|
|
- <span>{{call.name || 'Unknown'}}</span>
|
|
|
+ <div class="d-flex flex-row justify-content-center mt-2">
|
|
|
+ <span>{{callWidget.callInfo.name || 'Unknown'}}</span>
|
|
|
</div>
|
|
|
|
|
|
<div class="d-flex flex-row justify-content-center mt-5">
|
|
|
- <h2>{{call.time_limit}}</h2>
|
|
|
+ <h2 v-if="callWidget.callInfo.time_limit">{{callWidget.callInfo.time_limit}}</h2>
|
|
|
</div>
|
|
|
|
|
|
<div class="d-flex flex-row justify-content-between mt-5 ctrlBtns">
|
|
@@ -63,7 +63,7 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
|
- ...mapState(["settings"]),
|
|
|
+ ...mapState(["lobbies","settings", "callWidget"]),
|
|
|
},
|
|
|
watch: {
|
|
|
call: {
|
|
@@ -82,9 +82,27 @@ export default {
|
|
|
methods: {
|
|
|
handleCall(acceptCall) {
|
|
|
if(acceptCall){
|
|
|
- console.log('Call accepted!')
|
|
|
+ let meeting = []
|
|
|
+
|
|
|
+ for(let lobby of this.lobbies){
|
|
|
+ meeting = lobby.meetings.filter((x) => x.uid == this.callWidget.callInfo.meeting_uid)
|
|
|
+
|
|
|
+ if(meeting.length){
|
|
|
+ break
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ if(!meeting.length){
|
|
|
+ return
|
|
|
+ } else {
|
|
|
+ let data = {
|
|
|
+ selected_meeting: meeting[0]
|
|
|
+ }
|
|
|
+
|
|
|
+ this.$eventBus.$emit('joinMeeting', data)
|
|
|
+ }
|
|
|
} else {
|
|
|
- console.log('Call Rejected!')
|
|
|
+ this.$store.commit('rejectCall')
|
|
|
}
|
|
|
},
|
|
|
shiftForm(){
|