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

fix(channel-web): display feedback actions on all q&a answers #5662

Conversation

billsomen
Copy link
Contributor

@billsomen billsomen commented Nov 3, 2021

Description

  • Remove the condition of only displaying feedback on lastMessages
  • Save feedback on the events table to prevent displaying feedbacks on every QnA answers (see image below)

Screen Shot 2021-11-03 at 8 24 53 AM

Media (how it feels like now)

Screen.Recording.2021-11-03.at.8.16.51.AM.mov

Fixes # botpress/v12#1160

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Chore change (refactoring and / or test changes)

How has this been tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Manual test, by savings feedbacks and checking values on db
  • Manual test, by reloading the page and validation that answers with feedbacks (from event db) does not render feedback component anymore

Test configuration:

  • BP version: 12.26.6
  • Node version: 12.14.0
  • OS: MacOS
  • Browser: Chrome
  • Binary or source ?: source

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented on my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • Any dependent changes have been merged and published in downstream modules
  • I've included some media (picture/gif/video) if applicable to show the old and new behavior

@linear
Copy link

linear bot commented Nov 3, 2021

DEV-1162 [BUG] QnA Thumbs Up & Down (botpress/botpress botpress/v12#1160)

Is your feature request related to a problem? Please describe.
In some cases we have the QnA redirect to a flow, and in this flow there are multiple follow up messages. In this case the thumbs up and down disappear, and it is no longer possible to collect the users feedback.

Describe the solution you'd like
To be able to keep the thumbs up and down whether or not the QnA response is the last message in the transcript.

Describe alternatives you've considered
Configurable

Additional context
N/A

@billsomen billsomen changed the base branch from master to x_party-parrots November 3, 2021 12:34
Copy link
Contributor

@laurentlp laurentlp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you make sure that your PR description follows the conventional commit nomenclature!

Otherwise, I have small minor comments but overall I tested it and it looks fine to me. Nice work!

@billsomen billsomen changed the title Bill dev 1162 bug qna thumbs up down botpressbotpress feat(channel-web): display feedback actions on all q&a answers Nov 7, 2021
@billsomen billsomen changed the title feat(channel-web): display feedback actions on all q&a answers fix(channel-web): display feedback actions on all q&a answers Nov 8, 2021
Copy link
Contributor

@laurentlp laurentlp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@billsomen billsomen merged commit 7d342f9 into x_party-parrots Nov 8, 2021
@laurentlp laurentlp deleted the bill-dev-1162-bug-qna-thumbs-up-down-botpressbotpress branch November 8, 2021 17:30
@crochcunill
Copy link

Successfully tested using commit 6642d74
Tue Nov 23 15:47:12 2021 -0500

Test Steps

  • Create a new bot using the Welcome template (it already includes Q&A)
  • start a conversation with the bot.
  • Ask several question
  • Provide feedback to some of the answers by clicking the thumbs up or thumb down icons
  • Verify, that once the feedback has been provided, the icon disappear and do not reappear as the conversation proceeds
  • Verify the answers where feedback was not provided still keep the icons

This was referenced Dec 2, 2021
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

Successfully merging this pull request may close these issues.

None yet

3 participants