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

Reduce duplication in form controllers with disabled actions #55

Closed
irisfaraway opened this issue Jul 29, 2019 · 1 comment
Closed

Reduce duplication in form controllers with disabled actions #55

irisfaraway opened this issue Jul 29, 2019 · 1 comment
Assignees
Labels
engine Relates to an engine or the engines housekeeping Refactoring, tidying up or other work which supports the project waste-carriers Relates to the waste carriers service waste-exemptions Relates to the waste exemptions service

Comments

@irisfaraway
Copy link
Member

This came out of discussion here: https://github.com/DEFRA/waste-exemptions-engine/pull/241#discussion_r308131294

We have a lot of forms controllers that have disabled actions like this:

    # Overwrite create and go_back as you shouldn't be able to submit or go back
    def create; end

    def go_back; end

We should see if there is any way to reduce the duplication, potentially by creating a concern (eg CannotSubmit or CannotGoBack).

@irisfaraway irisfaraway added housekeeping Refactoring, tidying up or other work which supports the project engine Relates to an engine or the engines waste-exemptions Relates to the waste exemptions service waste-carriers Relates to the waste carriers service labels Jul 29, 2019
@cintamani cintamani self-assigned this Aug 15, 2019
cintamani added a commit to DEFRA/waste-carriers-engine that referenced this issue May 12, 2020
irisfaraway pushed a commit to DEFRA/waste-carriers-engine that referenced this issue May 12, 2020
@cintamani
Copy link

This is all fixed now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
engine Relates to an engine or the engines housekeeping Refactoring, tidying up or other work which supports the project waste-carriers Relates to the waste carriers service waste-exemptions Relates to the waste exemptions service
Projects
None yet
Development

No branches or pull requests

2 participants