Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 126fa63

Browse files
committed
chore(calls): remove tick provider
1 parent 873f868 commit 126fa63

File tree

3 files changed

+1
-24
lines changed

3 files changed

+1
-24
lines changed

packages/plugin-calls-ui/src/components/TickProvider.tsx

Lines changed: 0 additions & 14 deletions
This file was deleted.

packages/plugin-calls-ui/src/components/switchboard/Detail.tsx

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import React, { useState, useEffect, useMemo } from 'react';
22
import styled, { keyframes, css } from 'styled-components';
3-
import { useTick } from '../TickProvider';
43

54
// Animations
65
const fadeIn = keyframes`
@@ -739,14 +738,12 @@ const EnhancedCallCenterDashboard: React.FC<DashboardProps> = ({
739738
}, 1000);
740739
return () => clearInterval(timer);
741740
}, []);
742-
const tick = useTick();
743741
return (
744742
<DashboardContainer>
745743
<Header>
746744
<HeaderTitle>
747745
<h1>Call Center Dashboard</h1>
748746
<p>Live monitoring and agent status</p>
749-
<div>tick: {tick}</div>
750747
</HeaderTitle>
751748
<LiveClock>
752749
<div className="time">{currentTime.toLocaleTimeString()}</div>
@@ -938,7 +935,6 @@ const EnhancedCallCenterDashboard: React.FC<DashboardProps> = ({
938935
const callerId = matchingCall
939936
? matchingCall.callerid
940937
: `External Call`;
941-
console.log(matchingCall, 'matchingCall');
942938
return (
943939
<CallItem
944940
key={`active-${agent.member_extension}`}

packages/plugin-calls-ui/src/containers/switchboard/Detail.tsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ import Detail from '../../components/switchboard/Detail';
66
import { queries, subscriptions } from '../../graphql';
77
import { Spinner } from '@erxes/ui/src/components';
88
import { useParams } from 'react-router-dom';
9-
import { TickProvider } from '../../components/TickProvider';
109

1110
function DetailContainer() {
1211
const { queue } = useParams();
@@ -68,11 +67,7 @@ function DetailContainer() {
6867
initialWaitingCall: inititalWaitingCall.callWaitingList,
6968
};
7069

71-
return (
72-
<TickProvider>
73-
<Detail {...updatedProps} />
74-
</TickProvider>
75-
);
70+
return <Detail {...updatedProps} />;
7671
}
7772

7873
export default DetailContainer;

0 commit comments

Comments
 (0)