Skip to content

Commit

Permalink
Added new APIS
Browse files Browse the repository at this point in the history
  • Loading branch information
arati-tekdi committed Nov 21, 2024
1 parent 85904b6 commit 11248d5
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions src/common/middleware/apiConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,9 @@ export const apiList = {
'/user/v1/update/:userId': createRouteObject({
patch: {
PRIVILEGE_CHECK: privilegeGroup.users.update,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher.concat(
rolesGroup.student,
),
},
}),
'/user/v1/delete/:userId': createRouteObject({
Expand All @@ -186,7 +188,9 @@ export const apiList = {
'/user/v1/list': createRouteObject({
post: {
PRIVILEGE_CHECK: privilegeGroup.users.read,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher.concat(
rolesGroup.student,
),
},
}),
//need confirmation
Expand All @@ -212,9 +216,14 @@ export const apiList = {
'/user/v1/check': createRouteObject({
post: {
PRIVILEGE_CHECK: privilegeGroup.users.read,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher.concat(
rolesGroup.student,
),
},
}),
'/user/v1/auth/refresh': createRouteObject({
post: {},
}),
//cohort
'/user/v1/cohort/cohortHierarchy/:cohortId': createRouteObject({
get: {
Expand Down Expand Up @@ -1483,7 +1492,9 @@ export const apiList = {
'/api/v1/attendance/list': createRouteObject({
post: {
PRIVILEGE_CHECK: privilegeGroup.attendance.read,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher,
ROLE_CHECK: rolesGroup.admin_team_leader_teacher.concat(
rolesGroup.student,
),
},
}),
'/api/v1/attendance/bulkAttendance': createRouteObject({
Expand Down

0 comments on commit 11248d5

Please sign in to comment.