-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Set up database + projects for real form testing #175
Comments
Hi @dave-mills, I would like to ask some questions for clarification first. Just to confirm:
Are we going to get our local environment to use the existing "real form" projects in ODK central staging env? Um... Do you have a PR that includes all those changes for easy reference? |
I assume you are familiar with how the seeders and commands work for setting up a local environment to use the shared "test form" projects on ODK Central. You can look at #172 for my description, and #173 for the PR. In the PR, focus on:
All the changes in app/Filament, app/Imports, app/Livewire and app/Models are just namespacing changes (moving the Xlsform and XlsformTemplate models back into the package). To summarise the current flow:
Those seeders were created using the
We could use the existing "real form" projects in ODK Central, assuming those forms are the correct + up to date versions, but it might be cleaner to make new ones, so that we know we don't have older submissions in the wrong format etc.
You can
I wouldn't make a copy of all those seeder files; they were created using the iseed, and the quickest way would be to get your database setup the way it's needed and then run the |
Thank you @dave-mills . I have a better understanding now. Um... What is the URL for ODK Central projects that have the real forms? Or... where can I find the real forms? |
Hi @dave-mills , some progress update... Thank you for your email. I have downloaded two real forms. Before working on seeder files, I would like to test if I can create new xlsform templates for two real forms in local env first. I deleted all tables in backend database, then run below commands to setup my local env:
Now my local env can retrieve submissions from ODK central "mini forms". In admin panel, I created new xlsform templates for mini fieldwork form and mini household form. This is to ensure new xlsform template can be created successfully. After that, I create new xlsform templates for real fieldwork form and real household form. I also tried to create new forms with real forms in ODK central staging env directly. Project folder: Real fieldwork form can be created with warnings, while real household form cannot be created with errors. Screen shots: Real Fieldwork Form
Real Household Form
ODK central staging env, Real Fieldwork Form ODK central staging env, Real Household Form |
Similar to the setup where we can run a database seeder and a pair of commands to get our local environment to use the existing "test form" projects, we need a way to share ODK Central projects that have the real forms:
Steps:
Make sure the platform project ID is unset, then refresh the database with the default seeders to create 4 new ODK Central projects - one linked to the 'platform' and 3 linked to the 3 new teams.
Add the 2 real forms as XlsformTemplates. (make sure to run the queue for the import). There should be Xlsform entries created for each team automatically.
Manually add the 'default' english Locale to each team so that their forms aren't missing labels and hints.
Publish the 2 forms for each team
at this point, can you share the ODK Central projects with @alex-thomson222 to make a couple of manual entries?
To make it so we can recreate the environment:
CopyMediaForTestOdkStuff
).The text was updated successfully, but these errors were encountered: