fixed service list show in Dialy Task
This commit is contained in:
parent
a2067e150d
commit
860779d096
@ -142,7 +142,7 @@ const OrganizationsList = ({searchText}) => {
|
||||
colSpan={organizationsColumns.length + 1}
|
||||
className="text-center"
|
||||
>
|
||||
<p className="fw-semibold">Not Found</p>
|
||||
<p className="fw-semibold">{isLoading ? "Loading....":"Not Found Organization"}</p>
|
||||
</td>
|
||||
</tr>
|
||||
)}
|
||||
|
@ -8,6 +8,8 @@ import ReportTask from "../../components/Activities/ReportTask";
|
||||
import TaskReportFilterPanel from "../../components/DailyProgressRport/TaskReportFilterPanel";
|
||||
import { useFab } from "../../Context/FabContext";
|
||||
import SubTask from "../../components/Activities/SubTask";
|
||||
import { useProjectAssignedServices } from "../../hooks/useProjects";
|
||||
import { useSelectedProject } from "../../slices/apiDataManager";
|
||||
|
||||
const DailyProgrssContext = createContext();
|
||||
export const useDailyProgrssContext = () => {
|
||||
@ -21,10 +23,11 @@ export const useDailyProgrssContext = () => {
|
||||
};
|
||||
|
||||
const DailyProgrssReport = () => {
|
||||
const selectedProject = useSelectedProject()
|
||||
const [service, setService] = useState("");
|
||||
const [filter,setFilter] = useState('')
|
||||
const { setOffcanvasContent, setShowTrigger } = useFab();
|
||||
const { data, isLoading, isError, error } = useServices();
|
||||
const { data, isLoading, isError, error } = useProjectAssignedServices(selectedProject);
|
||||
|
||||
const [modal, setModal] = useState({ type: null, data: null });
|
||||
|
||||
@ -86,7 +89,7 @@ const DailyProgrssReport = () => {
|
||||
/>
|
||||
|
||||
<div className="card card-fullscreen p-5">
|
||||
{data?.data?.length > 0 && (<div className="col-sm-4 col-md-3 col-12">
|
||||
{data?.length > 0 && (<div className="col-sm-4 col-md-3 col-12">
|
||||
<select
|
||||
className="form-select form-select-sm"
|
||||
value={service ?? ""}
|
||||
@ -99,7 +102,7 @@ const DailyProgrssReport = () => {
|
||||
<option value="">
|
||||
All Services
|
||||
</option>
|
||||
{data?.data?.map((service) => (
|
||||
{data?.map((service) => (
|
||||
<option key={service.id} value={service.id}>
|
||||
{service.name}
|
||||
</option>
|
||||
|
Loading…
x
Reference in New Issue
Block a user