revert 21e6b10ad11210a999d9ab82c5b110e408563ac7

Revert updated Application role key in cache when creating new role, as mistakenly, from Pramo,d the changes are pushed directly to the Feature_Task_Management
This commit is contained in:
vaibhav.surve 2025-04-18 07:14:37 +00:00
parent 564b1d52c2
commit e0500d1e76
2 changed files with 6 additions and 4 deletions

View File

@ -58,7 +58,7 @@ const onSubmit = (values) => {
MasterRespository.createRole(result).then((resp)=>{
setIsLoading(false)
const cachedData = getCachedData( "Application Role" );
const cachedData = getCachedData( "Role" );
const updatedData = [...cachedData, resp.data];
cacheData("Application Role", updatedData);
@ -66,10 +66,9 @@ const onSubmit = (values) => {
onClose()
} ).catch( ( err ) =>
{
showToast(err?.response?.data?.message, "error");
setIsLoading( false )
onClose()
showToast(err?.response?.data?.message, "error");
setIsLoading(false)
})

View File

@ -12,6 +12,9 @@ import showToast from "../../services/toastService";
const updateSchema = z.object({
role: z.string().min(1, { message: "Role is required" }),
description: z.string().min(1, { message: "Description is required" })