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

Dependency Logic in Controller should not check if a dependent question has been answered #8

Closed
mgurley opened this issue Sep 23, 2009 · 2 comments

Comments

@mgurley
Copy link
Member

mgurley commented Sep 23, 2009

The dependents method of app/controllers/surveying_controller.rb checks to see if a question has met its dependency condition and been answered. This check for the second condition causes a dependent question to disappear after you answer it:

if dep.met?(response_set) and response_set.has_not_answered_question?(dep.question)

I removed the check for the second condition in my application.

@yoon
Copy link
Member

yoon commented Sep 28, 2009

This behavior should be put in the ResponseSet model and split - for pure html (js off) we want just the unanswered dependents for the top of each page. With js, we want to show all dependencies, even those that have been answered. Working on this now...

@yoon
Copy link
Member

yoon commented Sep 30, 2009

moving dependency logic to repsonse set, factories and specs to match. closed by 679c54c

This issue was closed.
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

No branches or pull requests

2 participants