merge with master

This commit is contained in:
victorAnumudu
2024-03-22 07:46:17 +01:00
2 changed files with 9 additions and 4 deletions
@@ -56,13 +56,18 @@ export default function OthersInterestTable({othersInterestedList, className}) {
</thead> </thead>
<tbody className="h-full"> <tbody className="h-full">
{currentOthersInterestedList?.map((item, index) => { {currentOthersInterestedList?.map((item, index) => {
const image = localStorage.getItem("session_token")
? `${othersInterestedList.imageServer}${localStorage.getItem("session_token")}/job/${
item.job_uid
}`
: "";
return ( return (
<tr key={index} className="bg-white dark:bg-dark-white border-b dark:border-[#5356fb29] hover:bg-gray-50"> <tr key={index} className="bg-white dark:bg-dark-white border-b dark:border-[#5356fb29] hover:bg-gray-50">
<td className=" py-4"> <td className=" py-4">
<div className="flex space-x-2 items-center"> <div className="flex space-x-2 items-center">
<div className="min-w-[60px] min-h-[60px] rounded-full overflow-hidden flex justify-center items-center"> <div className="min-w-[60px] min-h-[60px] rounded-full overflow-hidden flex justify-center items-center">
<img <img
src={dataImage1} src={image}
alt="data" alt="data"
className="w-full h-full" className="w-full h-full"
/> />
+3 -3
View File
@@ -12,7 +12,7 @@ export default function MyReviewDueJobsPage() {
let { othersInterestedTable } = useSelector((state) => state.tableReload); // FOR OTHERS INTERESTED TABLE RELOAD let { othersInterestedTable } = useSelector((state) => state.tableReload); // FOR OTHERS INTERESTED TABLE RELOAD
const apiCall = new usersService(); const apiCall = new usersService();
const [othersInterestedList, setOthersInterestedList] = useState({loading: true, data: []}) const [othersInterestedList, setOthersInterestedList] = useState({loading: true, data: [], imageServer:''})
useEffect(() => { useEffect(() => {
if(!state){ if(!state){
@@ -26,9 +26,9 @@ export default function MyReviewDueJobsPage() {
}else{ }else{
newData = [] newData = []
} }
setOthersInterestedList({loading: false, data: newData}) setOthersInterestedList({loading: false, data: newData, imageServer:res.data.session_image_server})
}).catch(err => { }).catch(err => {
setOthersInterestedList({loading: false, data: []}) setOthersInterestedList({loading: false, data: [], imageServer:''})
console.log('Error: ', err) console.log('Error: ', err)
}) })
}, [othersInterestedTable]); }, [othersInterestedTable]);