stats4sd / holpa-platform

Data Platform for the HOLPA tool
0 stars 0 forks source link

Team Management Part 2 #21

Closed dan-tang-ssd closed 1 week ago

dan-tang-ssd commented 1 week ago

This PR is submitted to fix #1

It contains some features listed in #1. Considering the project milestones, some less important features will be developed in later stage.


This PR contains below changes:

  1. Update seeder file, add description to the team record to remind user to create a new team for xlsform related testing. Because the team created by seeder file does not have a ODK project ID.
  2. admin panel, Team resource and Program resource, add warning message when delete team or delete program, no matter if there is actual survey data collected
  3. app panel, add Team resource for editing team details; add users, invites, xlsforms relation manager for read-only purpose

Less important features to be developed in later stage:

  1. admin panel > User resource > Send a password reset link to a specific user
  2. admin panel > User resource > Suspend or delete a user
  3. program admin panel > use Program model for multi-tenancy
  4. program admin panel > Users resource, only show teams under selected program in mutli-tenancy
dan-tang-ssd commented 1 week ago

This PR is now ready for review.

Most features are implemented for issue #1.


There are some minor features that we can implement later:

User resource:

Team resource:

Program resource:

dan-tang-ssd commented 1 week ago

Oh... forget to mention that this PR also fix #19

dan-tang-ssd commented 1 week ago

Staging env deployment is completed. Considering we have new role and new permissions, I have run all migration files and seeder files to refresh staging db.

I tried to create xlsform template for HOLPA Fieldwork and HOLPA Household forms. Error occurred when creating new xlsform template, it maybe due to same xlsform template name has been used. To have a brand new platform for testing, I have removed the ODK_PLATFORM_ID in .env file and refresh database with seeder files.

After that, xlsform template can be created successfully. I have also created a new Team, xlsform for testing. Submission can be created and submitted in ODK Collection. Application can pull submissions successfully.

dan-tang-ssd commented 1 week ago

By the way, I got a 30 seconds timeout issue when creating xlsform template for HOLPA Household ODK Form (159 KB). Maybe it is a long ODK form so it takes more time to process, then lead to timeout.

I cannot create xlsform template for HOLPA Household ODK Form in local env successfully. But I can do so in staging env without timeout issue.

dave-mills commented 1 week ago

I cannot create xlsform template for HOLPA Household ODK Form in local env successfully. But I can do so in staging env without timeout issue.

The fact that the same form works on the staging env suggests that it's not due to the size of the form. Which means it's probably something about the local environment setup. The main thing for now is that the staging site is working for us to use the demo forms.