=> {
if (!isRegistered) {
@@ -352,7 +352,9 @@ function EventListCardModals({
};
const openEventDashboard = (): void => {
- navigate(`/event/${orgId}/${eventListCardProps.id}`);
+ const userPath = eventListCardProps.userRole === Role.USER ? 'user/' : '';
+ console.log(`/${userPath}event/${orgId}/${eventListCardProps.id}`);
+ navigate(`/${userPath}event/${orgId}/${eventListCardProps.id}`);
};
const popover = (
diff --git a/src/components/LeftDrawerOrg/LeftDrawerOrg.tsx b/src/components/LeftDrawerOrg/LeftDrawerOrg.tsx
index 115b2cf7bc..02f44a55d7 100644
--- a/src/components/LeftDrawerOrg/LeftDrawerOrg.tsx
+++ b/src/components/LeftDrawerOrg/LeftDrawerOrg.tsx
@@ -141,7 +141,7 @@ const leftDrawerOrg = ({
>
{
);
await wait();
- expect(screen.getByText(/No Request Found/i)).toBeTruthy();
+ expect(screen.getByText(/No Membership Requests Found/i)).toBeTruthy();
});
test('Should render warning alert when there are no organizations', async () => {
diff --git a/src/state/reducers/routesReducer.test.ts b/src/state/reducers/routesReducer.test.ts
index 36b630094e..0a474df0c3 100644
--- a/src/state/reducers/routesReducer.test.ts
+++ b/src/state/reducers/routesReducer.test.ts
@@ -23,7 +23,7 @@ describe('Testing Routes reducer', () => {
},
{ name: 'Advertisement', url: '/orgads/undefined' },
{ name: 'Funds', url: '/orgfunds/undefined' },
- { name: 'Requests', url: '/requests/undefined' },
+ { name: 'Membership Requests', url: '/requests/undefined' },
{
name: 'Plugins',
subTargets: [
@@ -76,7 +76,7 @@ describe('Testing Routes reducer', () => {
component: 'OrganizationFunds',
},
{
- name: 'Requests',
+ name: 'Membership Requests',
comp_id: 'requests',
component: 'Requests',
},
@@ -117,7 +117,7 @@ describe('Testing Routes reducer', () => {
{ name: 'Block/Unblock', url: '/blockuser/orgId' },
{ name: 'Advertisement', url: '/orgads/orgId' },
{ name: 'Funds', url: '/orgfunds/orgId' },
- { name: 'Requests', url: '/requests/orgId' },
+ { name: 'Membership Requests', url: '/requests/orgId' },
{
name: 'Plugins',
subTargets: [
@@ -166,7 +166,7 @@ describe('Testing Routes reducer', () => {
},
{ name: 'Funds', comp_id: 'orgfunds', component: 'OrganizationFunds' },
{
- name: 'Requests',
+ name: 'Membership Requests',
comp_id: 'requests',
component: 'Requests',
},
@@ -210,7 +210,7 @@ describe('Testing Routes reducer', () => {
},
{ name: 'Advertisement', url: '/orgads/undefined' },
{ name: 'Funds', url: '/orgfunds/undefined' },
- { name: 'Requests', url: '/requests/undefined' },
+ { name: 'Membership Requests', url: '/requests/undefined' },
{ name: 'Settings', url: '/orgsetting/undefined' },
{
comp_id: null,
@@ -266,7 +266,7 @@ describe('Testing Routes reducer', () => {
component: 'OrganizationFunds',
},
{
- name: 'Requests',
+ name: 'Membership Requests',
comp_id: 'requests',
component: 'Requests',
},
diff --git a/src/state/reducers/routesReducer.ts b/src/state/reducers/routesReducer.ts
index e223b0754e..34cfdbbcca 100644
--- a/src/state/reducers/routesReducer.ts
+++ b/src/state/reducers/routesReducer.ts
@@ -80,7 +80,7 @@ const components: ComponentType[] = [
{ name: 'Block/Unblock', comp_id: 'blockuser', component: 'BlockUser' },
{ name: 'Advertisement', comp_id: 'orgads', component: 'Advertisements' },
{ name: 'Funds', comp_id: 'orgfunds', component: 'OrganizationFunds' },
- { name: 'Requests', comp_id: 'requests', component: 'Requests' },
+ { name: 'Membership Requests', comp_id: 'requests', component: 'Requests' },
{
name: 'Plugins',
comp_id: null,