Skip to content

Choose an answer feature#78

Merged
steveklabnik merged 1 commit intohacketyhack:rails3from
abhirao:rails3
Sep 6, 2011
Merged

Choose an answer feature#78
steveklabnik merged 1 commit intohacketyhack:rails3from
abhirao:rails3

Conversation

@abhirao
Copy link
Copy Markdown
Contributor

@abhirao abhirao commented Sep 6, 2011

I was unsure abt a couple items. I mapped the chosen answer within Question as solution_id. I also added
one :answer, :in => :solution_id
in addition to the existing
many :answers

Is the one declaration needed for referential integrity? If not pls take it out. It worked without issue.

For now I assumed that if user can update the question they can select an answer for it. Fair enough?

Changes backed up by Scenario: Select an answer in answers.feature.

Question now stores a solution_id that could point to one of it's answers.
Backed up by answers.feature
steveklabnik added a commit that referenced this pull request Sep 6, 2011
Choose an answer feature
@steveklabnik steveklabnik merged commit 41a220a into hacketyhack:rails3 Sep 6, 2011
@steveklabnik
Copy link
Copy Markdown
Member

w00t! Thank you so much!

Honestly, Im not 100% sure. Probably, answers should actually be embedded within questions, though I'm not 100% sure. I'm currently taking the approach of 'let's build it, and then improve' rather than trying to get it 100% right from the beginning, so I've merged this in anyway. :)

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.

2 participants