Implmeneted signalR in today's attendance
This commit is contained in:
parent
8217308db9
commit
b24edba8f7
@ -2,7 +2,7 @@ import React, { useEffect } from "react";
|
||||
import { Outlet } from "react-router-dom";
|
||||
import Header from "../components/Layout/Header";
|
||||
import Sidebar from "../components/Layout/Sidebar";
|
||||
import { startSignalR, stopSignalR } from "../services/signalRService";
|
||||
import { startSignalR, stopSignalR } from "../services/SignalRService";
|
||||
import Footer from "../components/Layout/Footer";
|
||||
import FloatingMenu from "../components/common/FloatingMenu";
|
||||
import { FabProvider } from "../Context/FabContext";
|
||||
|
@ -79,6 +79,16 @@ const AttendancePage = () => {
|
||||
[selectedProject, attrecall]
|
||||
);
|
||||
|
||||
const handler = useCallback(
|
||||
(msg) => {
|
||||
console.log("Equal:", selectedProject == msg.projectId);
|
||||
if (selectedProject == msg.projectId) {
|
||||
attrecall();
|
||||
}
|
||||
},
|
||||
[selectedProject, attrecall]
|
||||
);
|
||||
|
||||
const getRole = (roleId) => {
|
||||
if (!empRoles) return "Unassigned";
|
||||
if (!roleId) return "Unassigned";
|
||||
|
Loading…
x
Reference in New Issue
Block a user