approve condition handle

This commit is contained in:
Pramod Mahajan 2025-06-17 12:12:27 +05:30
parent 1b4001fadf
commit b18e0e4dd7

View File

@ -100,8 +100,13 @@ const ReportTaskComments = ({
setComment((prevItems) => [...prevItems, resp.data]);
const taskList = getCachedData("taskList");
if (taskList && taskList.data) {
if ( actionAllow )
{
} else
{
if (taskList && taskList.data) {
const updatedTaskList = taskList.data.map((task) => {
if (task.id === resp.data.taskAllocationId) {
const existingComments = Array.isArray(task.comments)
@ -120,6 +125,7 @@ const ReportTaskComments = ({
projectId: taskList.projectId,
});
}
}
reset();
setloading(false);