-
Notifications
You must be signed in to change notification settings - Fork 10
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
Add feedback button #527
Add feedback button #527
Conversation
First working version, of course still a lot to improve from here.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dev #527 +/- ##
======================================
Coverage ? 66.52%
======================================
Files ? 312
Lines ? 9425
Branches ? 0
======================================
Hits ? 6270
Misses ? 3155
Partials ? 0 ☔ View full report in Codecov by Sentry. |
A new column was added to the Feedbacks schema. Note that we did not create a new migration as this is a PR which should only contain one migration, namely the one for the creation of the whol Feedback table.
Right now just for ourselves, so that we get a plaintext mail with the feedback of a user. Env variables were adjusted accordingly, but need to be set manually in the production environment!
Hey @Frodo161, this PR is now ready for your review ;) Please see the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Problems:
- "Bitte verwenden Sie zumindest 10 Zeichen" is in German even if the language is set to English.
- If one uses "@feedback_sucess = false" as described in the PR, nothing happens (only the modal won't close on save). Especially, there is no error message (should there be one?). The mail arrives in the mail catcher as expected.
- More generally, I didn't get to see any of the error messages that are written down in the locale files.
Code:
- Maybe, instead of writing authorize_resource except: [:create] in the FeedbacksController, you can add an ability file for feedback.
Command used: `yarn run eslint --fix .` Still 47 problems (27 errors, 20 warnings) after this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me. Before merging into production: Has this
- Set FEEDBACK_EMAIL env variable in production! -> won't be reflected in this PR, manual in production environment
been done yet?
* Reapply first fix for Reader/Media See discussion on #574 for further details. Previous PR for this was #576, closed in favor of this one as this directly branches off the new "dev" branch. * Correctly show latest post (might be current_user's comment) * Fix update of unread comments logic in comments controller * Fix update icon logic and latest post comment * Simplify latest comment logic * Improve code comments * Further improve comments * Fix wording in comment * Fix construction of media array & use `.blank?` instead of `.empty?`
* Add dummy migration * Implement migration for unread comment flag * Remove unnecessary comment * Declare migration as not idempotent * Use array.length instead of counting * Throw error to prevent revert of migration * Fix severe flaws in unread comments migration * Simplify Reader retrieval * Use the more explicit `.nil?` method * Update migration date * Fix annoying bug: don't use `.select!` but `.select` * Polish migration e.g. update comment, more suitable name for the method etc. * Rename method according to #585
Will merge without approval as Denis is on vacation. |
New feedback button for users to give feedback regarding MaMpf. Closes #466
⚠ Merge #537 beforehand, then bring in mampf-next into this branch.TODOs
FEEDBACK_EMAIL
env variable in production! -> won't be reflected in this PR, manual in production environmentPreview
For reviewers
Mailcatcher
if email arrivedapp/controllers/FeedbacksController
inside thecreate
method, add:@feedback_success = false
right beforerespond_to(&:js)
to simulate unsuccessful saving of message to database, simulate bad internet connection, other error paths?Reply-to
of mail (only if checkbox is ticked should we be able to contact the user by replying to the mail, otherwiseReply-to
field should be empty)...
(specify)