Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Callbacks now dial automatically #12

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/components/call/CscCall.vue
Original file line number Diff line number Diff line change
Expand Up @@ -561,10 +561,14 @@ export default {
this.fetchLocalMediaWrapperWidth()
this.fetchRemoteMediaWrapperWidth()
}
const startCall = (media) => {
this.startCall(media)
}
fetchMediaWrapperWidth()
this.$root.$on('window-resized', fetchMediaWrapperWidth)
this.$root.$on('content-resized', fetchMediaWrapperWidth)
this.$root.$on('orientation-changed', fetchMediaWrapperWidth)
this.$root.$on('start-call', startCall)
},
methods: {
fetchLocalMediaWrapperWidth () {
Expand Down
3 changes: 2 additions & 1 deletion src/helpers/validation.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@

const userInfoRegExp = new RegExp(/^[-_.!~*'&=+$,;?/%a-zA-Z0-9]+$/)
const macAddressRegExp = new RegExp(/^(?:[0-9A-Fa-f]{2}(?=([-:]|))(?:\1[0-9A-Fa-f]{2}){5})$/)
const phoneNumberRegExp = new RegExp(/^\+[0-9]?()[0-9](\s|\S)(\d[0-9]{9})$/)

export function userInfo (value) {
return userInfoRegExp.test(value)
Expand All @@ -18,7 +19,7 @@ export function customMacAddress (value) {
}

export function isPhone (value) {
return /^\+[0-9]?()[0-9](\s|\S)(\d[0-9]{9})$/.test(value)
return phoneNumberRegExp.test(value)
}

export function inRange (value, min, max, between) {
Expand Down
4 changes: 3 additions & 1 deletion src/pages/CscPageConversations.vue
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
:default="tab.value === selectedTab"
:disable="listLoading"
@click="selectTab(tab.value)"
/>
/>

</template>
<template
v-slot:toolbar
Expand Down Expand Up @@ -274,6 +275,7 @@ export default {
},
startCall (number) {
this.$store.commit('call/numberInputChanged', number)
this.$root.$emit('start-call', 'audioOnly')
this.$router.push('home')
},
downloadFax (fax) {
Expand Down