Commit 84de9237 authored by Muhammadali's avatar Muhammadali

update-

parent 103f99ce
{
"name": "boxdialer",
"version": "3.9.0",
"version": "3.9.1",
"description": "",
"main": "src/boxDialer.js",
"scripts": {
......
......@@ -4,7 +4,7 @@ import React from 'react';
import Block from './style';
import { useTranslator } from '@eo-locale/react';
const InnerCaller = ({ hidden, modalState }) => {
const InnerCaller = ({ hidden, type }) => {
const boxDialer = window.BoxDialer;
const translator = useTranslator();
return (
......@@ -16,16 +16,28 @@ const InnerCaller = ({ hidden, modalState }) => {
</p>
</div>
<div className='bottom'>
<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>
{type == 'connected' || type == 'connecting' ? (
<>
<button
className='button red nocopy'
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>
</Block>
);
......
......@@ -88,7 +88,7 @@ export class BoxDialer {
// window.innerCallBegin(true);
this.onSipStateChange.innerCallerModal({
bool: true,
type: null,
type: 'connecting',
});
this.setGuiPhoneState({
funcName: 'modalState',
......@@ -326,7 +326,7 @@ export class BoxDialer {
// innerCallerModal;
this.onSipStateChange.innerCallerModal({
bool: true,
type: null,
type: 'connecting',
});
if (this.callSession.direction === 'incoming') {
this.showNotification(() => {
......
......@@ -38,7 +38,7 @@ const Root = ({ wsphonedata, onSetDnd, setWsphonedata, callMethod }) => {
const [secondLine, setSecondLine] = useState(false);
const [innerCallerModal, setInnerCallerModal] = useState({
bool: false,
type: null
type: null,
});
const boxDialer = window.BoxDialer;
......@@ -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} />
</>
......
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