Commit 84de9237 authored by Muhammadali's avatar Muhammadali

update-

parent 103f99ce
{ {
"name": "boxdialer", "name": "boxdialer",
"version": "3.9.0", "version": "3.9.1",
"description": "", "description": "",
"main": "src/boxDialer.js", "main": "src/boxDialer.js",
"scripts": { "scripts": {
......
...@@ -4,7 +4,7 @@ import React from 'react'; ...@@ -4,7 +4,7 @@ import React from 'react';
import Block from './style'; import Block from './style';
import { useTranslator } from '@eo-locale/react'; import { useTranslator } from '@eo-locale/react';
const InnerCaller = ({ hidden, modalState }) => { const InnerCaller = ({ hidden, type }) => {
const boxDialer = window.BoxDialer; const boxDialer = window.BoxDialer;
const translator = useTranslator(); const translator = useTranslator();
return ( return (
...@@ -16,16 +16,28 @@ const InnerCaller = ({ hidden, modalState }) => { ...@@ -16,16 +16,28 @@ const InnerCaller = ({ hidden, modalState }) => {
</p> </p>
</div> </div>
<div className='bottom'> <div className='bottom'>
<button {type == 'connected' || type == 'connecting' ? (
className='button light_blue nocopy' <>
onClick={() => boxDialer.answerButtonClick()}> <button
{translator.translate('ANSWER')} className='button red nocopy'
</button> onClick={() => boxDialer.hangupButtonClick()}>
<button {translator.translate('REJECT')}
className='button red nocopy' </button>
onClick={() => boxDialer.hangupButtonClick()}> </>
{translator.translate('REJECT')} ) : (
</button> <>
<button
className='button light_blue nocopy'
onClick={() => boxDialer.answerButtonClick()}>
{translator.translate('ANSWER')}
</button>
<button
className='button red nocopy'
onClick={() => boxDialer.hangupButtonClick()}>
{translator.translate('REJECT')}
</button>
</>
)}
</div> </div>
</Block> </Block>
); );
......
...@@ -88,7 +88,7 @@ export class BoxDialer { ...@@ -88,7 +88,7 @@ export class BoxDialer {
// window.innerCallBegin(true); // window.innerCallBegin(true);
this.onSipStateChange.innerCallerModal({ this.onSipStateChange.innerCallerModal({
bool: true, bool: true,
type: null, type: 'connecting',
}); });
this.setGuiPhoneState({ this.setGuiPhoneState({
funcName: 'modalState', funcName: 'modalState',
...@@ -326,7 +326,7 @@ export class BoxDialer { ...@@ -326,7 +326,7 @@ export class BoxDialer {
// innerCallerModal; // innerCallerModal;
this.onSipStateChange.innerCallerModal({ this.onSipStateChange.innerCallerModal({
bool: true, bool: true,
type: null, type: 'connecting',
}); });
if (this.callSession.direction === 'incoming') { if (this.callSession.direction === 'incoming') {
this.showNotification(() => { this.showNotification(() => {
......
...@@ -38,7 +38,7 @@ const Root = ({ wsphonedata, onSetDnd, setWsphonedata, callMethod }) => { ...@@ -38,7 +38,7 @@ const Root = ({ wsphonedata, onSetDnd, setWsphonedata, callMethod }) => {
const [secondLine, setSecondLine] = useState(false); const [secondLine, setSecondLine] = useState(false);
const [innerCallerModal, setInnerCallerModal] = useState({ const [innerCallerModal, setInnerCallerModal] = useState({
bool: false, bool: false,
type: null type: null,
}); });
const boxDialer = window.BoxDialer; const boxDialer = window.BoxDialer;
...@@ -154,7 +154,10 @@ const Root = ({ wsphonedata, onSetDnd, setWsphonedata, callMethod }) => { ...@@ -154,7 +154,10 @@ const Root = ({ wsphonedata, onSetDnd, setWsphonedata, callMethod }) => {
} }
/> />
<InnerCaller hidden={innerCallerModal.bool} modalState={modalState} /> <InnerCaller
hidden={innerCallerModal.bool}
type={innerCallerModal.type}
/>
<SecondNotifSip secondLine={secondLine} /> <SecondNotifSip secondLine={secondLine} />
</> </>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment