Closed VernitaJ closed 4 years ago
I will update backend first to include patch. As the current method is post, and overwrites the entire DB
There is a need to validate values before send it, to prevent an empty values
Fixed it! Thank you for the feedback. The way I've coded it is to enable the user to update only their name, surname, URL or update all three. The original array shouldn't be changed, only the specified data. For this reason the backend needs to be fixed so we write to the specific dataset.
I was checking the branch (feature10) in gitpod and I try to see your work (good interface), I notice if I click save profile button the info disappears. The second thing, it is possible to create a component for the form that you create for the edit?
I was checking the branch (feature10) in gitpod and I try to see your work (good interface), I notice if I click save profile button the info disappears. The second thing, it is possible to create a component for the form that you create for the edit?
@Btolara Thanks, I changed it so you can't send an empty array. But for it to work properly we need to change the backend, because it is replacing the entire array at the moment instead of the datasets within it.
Check console while entering data in fields
@marcopeg I am working on the styling in this PR now, to apply CORRECT BEM naming.
I think once we fix the update user as react hook, we are good to go
@marcopeg Chau says she will work on the react hook within this component, and Noor is going to better the value input so the original value is sent if nothing is typed, and submit is fired. We will merge this and create these issues for them to resolve.
Edit component completed. NEED TO CHANGE BACKEND for 'post' to work correctly. Pushes updated details to backend. Added 'home' link. Need to update the code to remove value when submit is triggered. I tried a few different options, but it doesn't seem to work. fixes #10