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

[IMP] Survey: Hide retry button on printable view #32618

Conversation

Projects
None yet
5 participants
@hdh-odoo
Copy link
Contributor

commented Apr 11, 2019

Description of the issue/feature this PR addresses:

Description
-Previously, the Retry button was unnecessarily visible on the printable view of the survey.
-This commit fixes this by removing template call to retake_survey_button from printable view.

--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

@robodoo robodoo added the CI 🤖 label Apr 11, 2019

@C3POdoo C3POdoo added the RD label Apr 11, 2019

@hdh-odoo hdh-odoo force-pushed the odoo-dev:master-survey-hide-retry-button-on-print-view-hdh branch from 196c58f to 3abdc32 Apr 12, 2019

@robodoo robodoo removed the CI 🤖 label Apr 12, 2019

@dbeguin
Copy link
Contributor

left a comment

I would instead take the issue from another point of view. Calling print and adding a 'print' parameter is quite confusing (and could look useless). I would instead add a 'review' parameter that is false by default and set to True in the review answers case. So that we explicitly know that we are in review mode or not.

@robodoo robodoo added the CI 🤖 label Apr 12, 2019

@hdh-odoo hdh-odoo force-pushed the odoo-dev:master-survey-hide-retry-button-on-print-view-hdh branch from 3abdc32 to a1acb80 Apr 12, 2019

@robodoo robodoo added CI 🤖 and removed CI 🤖 labels Apr 12, 2019

@hdh-odoo hdh-odoo force-pushed the odoo-dev:master-survey-hide-retry-button-on-print-view-hdh branch from a1acb80 to 2244396 Apr 12, 2019

@robodoo robodoo removed the CI 🤖 label Apr 12, 2019

@hdh-odoo hdh-odoo force-pushed the odoo-dev:master-survey-hide-retry-button-on-print-view-hdh branch from 3069b6f to 95ca751 Apr 12, 2019

@robodoo robodoo added the CI 🤖 label Apr 12, 2019

@hdh-odoo hdh-odoo force-pushed the odoo-dev:master-survey-hide-retry-button-on-print-view-hdh branch from 95ca751 to f0587e4 Apr 15, 2019

@robodoo robodoo added CI 🤖 and removed CI 🤖 labels Apr 15, 2019

@hdh-odoo hdh-odoo force-pushed the odoo-dev:master-survey-hide-retry-button-on-print-view-hdh branch from f0587e4 to 9e89616 Apr 22, 2019

@robodoo robodoo added CI 🤖 and removed CI 🤖 labels Apr 22, 2019

@@ -426,7 +426,7 @@ def survey_submit(self, survey_token, answer_token, **post):
return json.dumps(ret)

@http.route('/survey/print/<string:survey_token>', type='http', auth='public', website=True)
def survey_print(self, survey_token, answer_token=None, **post):
def survey_print(self, survey_token, review=None, answer_token=None, **post):

This comment has been minimized.

Copy link
@dbeguin

dbeguin Apr 24, 2019

Contributor

as review is used as a Boolean, set default value to False.

This comment has been minimized.

Copy link
@hdh-odoo

hdh-odoo Apr 25, 2019

Author Contributor

It's done. Thanks

[IMP] survey: hide retry button on print view
	-Previously, The Retry button was visible on printable view of the
survey as well as on answers.
	-This commit fixes the issue by passing an extra parameter to
determine whether user is in printable view or simply in answer review.

Task: 1967500

@hdh-odoo hdh-odoo force-pushed the odoo-dev:master-survey-hide-retry-button-on-print-view-hdh branch from 9e89616 to f46bc97 Apr 25, 2019

@robodoo robodoo added CI 🤖 and removed CI 🤖 labels Apr 25, 2019

@tde-banana-odoo

This comment has been minimized.

Copy link
Contributor

commented May 3, 2019

@robodoo robodoo added the r+ 👌 label May 3, 2019

robodoo pushed a commit that referenced this pull request May 3, 2019

[IMP] survey: hide retry button on print view
	-Previously, The Retry button was visible on printable view of the
survey as well as on answers.
	-This commit fixes the issue by passing an extra parameter to
determine whether user is in printable view or simply in answer review.

Task: 1967500

closes #32618

Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
@robodoo

This comment has been minimized.

Copy link
Contributor

commented May 3, 2019

Merged, thanks!

@robodoo robodoo closed this May 3, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.