Skip to content

Commit

Permalink
Merge roles and districts and allow multiple district assigning (#1124)
Browse files Browse the repository at this point in the history
* [rebase] Display default values to assign roles and districts on user select

* [rebase] Allow saving of both user role and districts at the same time and refresh role displayed

* Make edits for many to many relationship change for districts and users

* Remove zone select for read only
  • Loading branch information
gdalcengio authored Jun 4, 2024
1 parent 9913046 commit fa396b3
Show file tree
Hide file tree
Showing 5 changed files with 203 additions and 246 deletions.
4 changes: 2 additions & 2 deletions src/api/user.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ export const assignDistrict = async (userId, districtId) => {
)
}

export const assignDistricts = async (userId, districtIds) => {
export const assignDistricts = async (userId, districts) => {
return axios.post(
API.ASSIGN_DISTRICTS(userId),
{ districtIds: districtIds },
{ districts: districts },
getAuthHeaderConfig(),
)
}
Loading

0 comments on commit fa396b3

Please sign in to comment.