rubyforgood / pet-rescue

Pet Rescue is an application making it easy to link adopters/fosters with pets. We work with grassroots pet rescue organizations to understand how we can make the most impact.
MIT License
57 stars 95 forks source link

CSV Upload: Add route, controller,policy, nav link, and UI for upload #868

Open kasugaijin opened 1 month ago

kasugaijin commented 1 month ago

This work is part of a feature that will enable staff to upload questionnaires from third party form services to the app so the adopter data is all in once place.

Scoping should be Organizations::Staff

Add a route external_form_submission Add controller ExternalFormSubmissionsController Add policy class with check for the index action. Add link to staff navbar External Form Upload When I click on the navbar link, I am redirected to a new page within the dashboard layout that has a file attachment input. You can use the index action.

Above the input is a section with the following information:

'If you use a third party form service, like Google Forms, to provide questionnaires to potential adopters, and receive their answers, you can upload the CSV of data here to import the questions and responses to this application. This means the questionnaire data will live in one place, and you will be able to view it for a given adoption application at any time. Note that the adopter must have an account in this application using the same email address they used in the third party form.'

Naraveni commented 1 month ago

hwy Can I work on this

kasugaijin commented 1 month ago

For sure @Naraveni let me know if you have any questions!

Naraveni commented 4 weeks ago

@kasugaijin could you please mention should I completely create new models or use existing models. If I have to use existing models, could you please mention what models I need to look at. Thank You

kasugaijin commented 4 weeks ago

@Naraveni I don't think we will need a new model for this. For now let's just focus on the new routes, controllers, policy, to get the UI working. Then in an issue later we can hook things up. This will use an import service that will persist to existing models.

kasugaijin commented 3 weeks ago

@Naraveni how's this going? let me know if you have questions

Naraveni commented 3 weeks ago

@kasugaijin Haven't started during the weekdays. I got some time during the weekend, I will try to complete it now