Skip to content
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

Accessing Submitted Form #1

Open
yuvi100 opened this issue Jan 29, 2021 · 5 comments
Open

Accessing Submitted Form #1

yuvi100 opened this issue Jan 29, 2021 · 5 comments

Comments

@yuvi100
Copy link

yuvi100 commented Jan 29, 2021

Hi there,

Thank you for sharing your code!

I'm new to using AWS Amplify and learning Vue JS.

I've successfully managed to deploy the app, however, i'm encountering a problem where a user who has submitted their survey can't access their submitted results after signing out and signing back in. The access link exists in the users "My Profile" panel, but clicking it just takes you to the start of the survey with none of the results saved (populated).

I have deployed the app here, if you want to create an account and test it out for yourself:
https://main.d1zzcir6moux6n.amplifyapp.com/

I'd love to also request a feature:

  • Saving unfinished survey progress

Any help would be appreciated!

@marekq
Copy link
Owner

marekq commented Jan 29, 2021

Hey @yuvi100,

Thanks so much for your comment and trying the project out! I've been using it to learn Vue and Amplify myself and happy to explain more or help to get some features added. I still need to do a better job at the readme to make the "workflow" clearer, but here is what I had in mind for the project;

  • Anyone can visit a URL and submit survey results to it without login. One of my ideas is to have a simple option where I can generate a survey about an event/workshop/talk and distribute the link for people to answer it. The idea is that the visitor answers the survey right after the event and doesn't necessarily come back to review/change results later on. This is kind of similar in spirit to some "commercial" survey services like Qualtrics. I'm not interested in paying for those solutions and having the data stored in someone else's database. I also couldn't find a decent, free solution either so figured I can try to build one myself that meets my "simple" requirements.
  • All survey responses are stored in DynamoDB where admin users can review all the results. For my use-case, only I would login after the people were able to answer and review/export the results from there. You can have other admins create surveys as well and either grant them access to all data or just surveys from a particular group.
  • I haven't thought of a way to let users edit their responses yet, but happy to think about it more or see if I can help to implement it. One of the practical objections from my side is the fact that I don't necessarily want users to create an account or have any extra steps to answer the survey. I've intended for "anonymous" access which hopefully leads to more people taking the effort to answer, I'm also trying to avoid storing any personal information or IP spaces as I don't really need/want to hold that information. But I'm happy to hear more about your usecase and show/discuss how it can be implemented, it would be quite straight forward based on how the project is set up.

With that being said, the access from the admin panel to surveys is controlled by Cognito User Groups right now. I still need to work on better modification of user permissions or default roles, but you could add your Cognito User to the group manually now.

If your user is part of the "admin" group you can see everything, there is also a "demo" and "test" group that I hard coded for testing purposes. It's definitely an area of improvement still and curious to hear your feedback here too.

Attached is a screenshot with how the Cognito User group permissions can be set and the view I see in the admin panel with the roles added.

Screenshot 2021-01-29 at 20 17 41

Screenshot 2021-01-29 at 20 17 09

Looking forward to your comments and thoughts!

@marekq
Copy link
Owner

marekq commented Jan 29, 2021

By the way, there are a few other things I'm curious to get your input on;

  • Do you expect to change the questions per survey or are they static? Are there other areas of the survey you would want to customize (like logo's, intro text, something else)? I don't have a good mechanism for changing questions per survey yet and need to think on whether the current library works well for it. You can see in the current source that the questions are hardcoded.
  • How would you see the modify response feature work, based on a user login / cookie / something else?
  • Any thoughts on admin functionality, what are you missing in it today?

@yuvi100
Copy link
Author

yuvi100 commented Jan 30, 2021

Hi Marek,

Thanks for taking the time to write such an in-depth response 🙂

My user-case is slightly different but I found some similarities in your project as well that I had wanted to implement.

I initially used the vue-form-flow repo to come up with an on-boarding experience for clients. Basically a questionnaire for clients to fill out before we get started on their project. The repo seemed a lot more interactive and engaging which is why I didn't opt for just a standard form.

In my use case there's currently only one form, but I would potentially have different forms for different services that the client might be interested in.

The problem I had was that the questions take some time to think about and answer, which is why I wanted to save the clients progress. Some answers can be a paragraph long and I don't want clients to lose their progress if their internet connection goes down, they accidentally close their browser tab etc... I also didn't want to rely on localStorage to save their progress and instead thought "why not have a login portal and save their responses to a database" which is how I came across your repo. Basically every time a user fills out an individual input field, the database updates and every time the user goes back to that field (after signing out or closing the tab) it pre-populates with the database response if it exists.

In my use case, the survey can only be filled out by an "approved user" (this is only because I want to save their progress) and the admin portal would only be used by me to review submitted answers to all surveys filled out by all users (and now that you've explained your user case - also be able to create more questionnaires). The user who filled in the form should also be able to review their submitted results only.

In regards to feature requests:
Styling / logos etc. would be my last priority although I've already created my own theme for the vue-form-flow repo that I had cloned.

What I'm really interested in is saving form progress, and being able to have multiple questions on one "slide". I currently have 3 basic questions at the beginning of every form which ask for the clients "Name", "Business", "Phone Number" and I would like for it all to be on the same slide. Currently this is a three step process and these steps can add up, especially if I'm also expecting a client to fill out long answers in the questions that follow. This is by the way, also a feature request on the vue-flow-form repo already.

I think other features that might benefit other devs (including myself), is the ability for a user to export their responses to a PDF (this might be a little more complicated due to everyone having their own preference in styling the PDF). Additionally the ability to send the user a summary of their responses via email and for the admin to be notified that a response has been submitted.

I'd be happy to chat more about this and try to help out via Zoom etc. which might be easier 👍

@marekq
Copy link
Owner

marekq commented Jan 30, 2021

Awesome, thanks for the thoughts! Maybe we should connect some time over Zoom and discuss. I'm in GMT+1, what timezone are you in?

I think we can change the survey for logged in customers only and see how we could load the previous submitted questions for them. Once someone is logged in, you can actually see and submit their login ID and use that for tracking responses per user. Instead of submitting the form with a random ID every time like is implemented now, we would update an (existing) record in DynamoDB.

We could also change the admin portal to view the customers responses only and let them modify responses as they wish later on. I can't think of any obvious show stoppers yet, but let me think on it a bit more. Also happy to connect sometime next week if we can make it work out time wise.

@yuvi100
Copy link
Author

yuvi100 commented Jan 31, 2021

That all sounds perfect to me - i'm in GMT+11, so a little difficult, but I don't mind staying up or getting up early to have a chat next week... I'll try do as much as possible before then. Shoot me a message a day before you want to have a chat and we can organise a time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants