update action
This commit is contained in:
@@ -132,12 +132,12 @@ const Approved = () => {
|
||||
display={"flex"}
|
||||
alignItems={"center"}
|
||||
>
|
||||
<Avatar
|
||||
{/* <Avatar
|
||||
mr={2}
|
||||
size="sm"
|
||||
name={item.creator?.firstName}
|
||||
src={item.creator?.profilePhoto}
|
||||
/>
|
||||
/> */}
|
||||
{item?.creator?.firstName}
|
||||
</Text>
|
||||
),
|
||||
|
||||
@@ -104,7 +104,8 @@ const Pending = () => {
|
||||
"Comments",
|
||||
"Update by",
|
||||
"Update On",
|
||||
...(localStorage?.getItem('role')!=="Maker" ? ["Status"] : []),
|
||||
// ...(localStorage?.getItem('role')!=="Maker" ? ["Status"] : []),
|
||||
"Status"
|
||||
];
|
||||
|
||||
const extractedArray = filteredData?.map((item, index) => ({
|
||||
@@ -149,12 +150,12 @@ const Pending = () => {
|
||||
display={"flex"}
|
||||
alignItems={"center"}
|
||||
>
|
||||
<Avatar
|
||||
{/* <Avatar
|
||||
mr={2}
|
||||
size="sm"
|
||||
name={item?.creator?.firstName}
|
||||
src={item?.creator?.profilePhoto}
|
||||
/>
|
||||
/> */}
|
||||
{item?.creator?.firstName}
|
||||
</Text>
|
||||
),
|
||||
@@ -164,7 +165,9 @@ const Pending = () => {
|
||||
</Text>
|
||||
),
|
||||
Status: (
|
||||
<Box display={"flex"} justifyContent={"center"} gap={2}>
|
||||
<Box display={"flex"} justifyContent={"center"}>
|
||||
{localStorage?.getItem("role") !== "Maker" ? <Box>
|
||||
<Box display={"flex"} justifyContent={"center"} gap={2}>
|
||||
<Tooltip
|
||||
rounded={"sm"}
|
||||
fontSize={"xs"}
|
||||
@@ -219,6 +222,20 @@ const Pending = () => {
|
||||
<CloseIcon fontSize={"10px"} />
|
||||
</Button>
|
||||
</Tooltip>
|
||||
</Box>
|
||||
</Box> : <Button
|
||||
colorScheme="green"
|
||||
rounded={"sm"}
|
||||
size={"xs"}
|
||||
px={2}
|
||||
py={1}
|
||||
fontWeight={500}
|
||||
onClick={() => {
|
||||
setActionId(item.id);
|
||||
}}
|
||||
>
|
||||
<ViewIcon me={"4px"} /> View
|
||||
</Button>}
|
||||
</Box>
|
||||
),
|
||||
}));
|
||||
|
||||
@@ -144,12 +144,12 @@ import AddCaseDetails from "./AddCaseDetails";
|
||||
display={"flex"}
|
||||
alignItems={"center"}
|
||||
>
|
||||
<Avatar
|
||||
{/* <Avatar
|
||||
mr={2}
|
||||
size="sm"
|
||||
name={item.creator?.firstName}
|
||||
src={item.creator?.profilePhoto}
|
||||
/>
|
||||
/> */}
|
||||
{item?.creator?.firstName}
|
||||
</Text>
|
||||
),
|
||||
|
||||
@@ -140,8 +140,8 @@ const RequestApproveModal = ({ isOpen, onClose, firstField ,id}) => {
|
||||
</Text>
|
||||
)}
|
||||
<FormHelperText fontSize="xs" color="gray.500">
|
||||
Maximum length should be 200 characters. You have entered
|
||||
{watch("checkerComment")?.length || 0} characters.
|
||||
<Box as="span" me={1}>Maximum length should be 200 characters. You have entered </Box>
|
||||
{watch("checkerComment")?.length || 0} characters.
|
||||
</FormHelperText>
|
||||
</FormControl>
|
||||
</ModalBody>
|
||||
|
||||
@@ -147,12 +147,12 @@ const Approved = () => {
|
||||
display={"flex"}
|
||||
alignItems={"center"}
|
||||
>
|
||||
<Avatar
|
||||
{/* <Avatar
|
||||
mr={2}
|
||||
size="sm"
|
||||
name={item.creator?.firstName}
|
||||
src={item.creator?.profilePhoto}
|
||||
/>
|
||||
/> */}
|
||||
{item?.creator?.firstName}
|
||||
</Text>
|
||||
),
|
||||
|
||||
@@ -152,17 +152,19 @@ const Pending = () => {
|
||||
display={"flex"}
|
||||
alignItems={"center"}
|
||||
>
|
||||
<Avatar
|
||||
{/* <Avatar
|
||||
mr={2}
|
||||
size="sm"
|
||||
name={item.creator?.firstName}
|
||||
src={item.creator?.profilePhoto}
|
||||
/>
|
||||
/> */}
|
||||
{item?.creator?.firstName}
|
||||
</Text>
|
||||
),
|
||||
Status: (
|
||||
<Box display={"flex"} justifyContent={"center"} gap={2}>
|
||||
<Box display={"flex"} justifyContent={"center"}>
|
||||
{localStorage?.getItem("role") !== "Maker" ? <Box>
|
||||
<Box display={"flex"} justifyContent={"center"} gap={2}>
|
||||
<Tooltip
|
||||
rounded={"sm"}
|
||||
fontSize={"xs"}
|
||||
@@ -217,6 +219,20 @@ const Pending = () => {
|
||||
<CloseIcon fontSize={"10px"} />
|
||||
</Button>
|
||||
</Tooltip>
|
||||
</Box>
|
||||
</Box> : <Button
|
||||
colorScheme="green"
|
||||
rounded={"sm"}
|
||||
size={"xs"}
|
||||
px={2}
|
||||
py={1}
|
||||
fontWeight={500}
|
||||
onClick={() => {
|
||||
setActionId(item.id);
|
||||
}}
|
||||
>
|
||||
<ViewIcon me={"4px"} /> View
|
||||
</Button>}
|
||||
</Box>
|
||||
),
|
||||
}));
|
||||
|
||||
@@ -161,12 +161,12 @@ import AddNavDetails from "./AddNavDetails";
|
||||
display={"flex"}
|
||||
alignItems={"center"}
|
||||
>
|
||||
<Avatar
|
||||
{/* <Avatar
|
||||
mr={2}
|
||||
size="sm"
|
||||
name={item.creator?.firstName}
|
||||
src={item.creator?.profilePhoto}
|
||||
/>
|
||||
/> */}
|
||||
{item?.creator?.firstName}
|
||||
</Text>
|
||||
),
|
||||
|
||||
@@ -140,7 +140,7 @@ const RequestApproveModal = ({ isOpen, onClose, firstField ,id}) => {
|
||||
</Text>
|
||||
)}
|
||||
<FormHelperText fontSize="xs" color="gray.500">
|
||||
Maximum length should be 200 characters. You have entered
|
||||
<Box as="span" me={1}>Maximum length should be 200 characters. You have entered</Box>
|
||||
{watch("checkerComment")?.length || 0} characters.
|
||||
</FormHelperText>
|
||||
</FormControl>
|
||||
|
||||
@@ -153,7 +153,7 @@ import {
|
||||
color={"gray.800"}
|
||||
fontWeight={"500"}
|
||||
>
|
||||
{item?.modifier ? formatDate(item?.updatedAt) : "---" }
|
||||
{item?.modifier?.firstName}
|
||||
</Text>
|
||||
{/* <Text
|
||||
w={"100px"}
|
||||
|
||||
@@ -163,7 +163,7 @@ const Pending = () => {
|
||||
),
|
||||
"Approved By": (
|
||||
<Text w={"100px"} as={"span"} color={"gray.800"} fontWeight={"500"}>
|
||||
{item?.modifier ? item?.modifier : "---"}
|
||||
{item?.modifier?.firstName}
|
||||
</Text>
|
||||
),
|
||||
"Approved On": (
|
||||
@@ -193,7 +193,7 @@ const Pending = () => {
|
||||
}
|
||||
}}
|
||||
>
|
||||
<ViewIcon me={"4px"} /> View
|
||||
{localStorage?.getItem("role") === "Maker" ? <ViewIcon me={"4px"} /> : null} {localStorage?.getItem("role") === "Maker" ? "View" : "Approve / reject"}
|
||||
</Button>
|
||||
</Box>
|
||||
),
|
||||
|
||||
@@ -141,7 +141,7 @@ import {
|
||||
color={"gray.800"}
|
||||
fontWeight={"500"}
|
||||
>
|
||||
{item?.modifier ? formatDate(item?.updatedAt) : "---" }
|
||||
{item?.modifier?.firstName}
|
||||
</Text>
|
||||
),
|
||||
"Approved On": (
|
||||
|
||||
@@ -139,7 +139,7 @@ const RequestApproveModal = ({ isOpen, onClose, firstField ,id}) => {
|
||||
</Text>
|
||||
)}
|
||||
<FormHelperText fontSize="xs" color="gray.500">
|
||||
Maximum length should be 200 characters. You have entered
|
||||
<Box as="span" me={1}>Maximum length should be 200 characters. You have entered</Box>
|
||||
{watch("checkerComment")?.length || 0} characters.
|
||||
</FormHelperText>
|
||||
</FormControl>
|
||||
|
||||
@@ -139,7 +139,7 @@ import {
|
||||
</Text>
|
||||
)}
|
||||
<FormHelperText fontSize="xs" color="gray.500">
|
||||
Maximum length should be 200 characters. You have entered
|
||||
<Box as="span" me={1}>Maximum length should be 200 characters. You have entered</Box>
|
||||
{watch("checkerComment")?.length || 0} characters.
|
||||
</FormHelperText>
|
||||
</FormControl>
|
||||
|
||||
Reference in New Issue
Block a user