Fix Sign Up Forms
madvas opened this issue · comments
Matus Lestan commented
Currently, when sending the form, the graphQL returns following error:
{"errors":[{"message":"Error: error: null value in column \"user_slash_name\" violates not-null constraint","locations":
The error indicated some problem with sent data.
Hints:
Code that sends the data:
ethlance/src/ethlance/ui/page/sign_up/events.cljs
Lines 143 to 180 in cb8782e
Code that receives data on server side:
ethlance/src/ethlance/server/graphql/resolvers.cljs
Lines 465 to 475 in cb8782e
Additional things to implement
- Field validation using spec on server side
- Indication in UI that the request is being processed. Can be done as: Create button gets disabled and changes button text to "Creating..." and then switches back after receiving the response.
- Submitting should work for all 3 user types: Candidate, Employer, Arbiter.
Bonus points:
You can give it a try, maybe you'll need some help doing those:
- User profile page correctly displays submitted data.
- When user is using form again, it prefills forms with his existing data.