uwblueprint / somo

Text messaging survey app for Somo
http://www.thesomoproject.org
5 stars 1 forks source link

Added SurveyExecutionState Model #46

Closed chrisjluc closed 7 years ago

chrisjluc commented 7 years ago

Survey Execution State model references respondent and the current question that they're on.

Issue: https://github.com/uwblueprint/somo/issues/10

dinahshi commented 7 years ago

Why should this be a separate table instead of a column on the respondent table? Are there plans for what we might put in this model in the future? SurveyExecutionState seems a little misleading if the only reference is to current question.

chrisjluc commented 7 years ago

I think they should be separate because the idea of survey state and respondent are conceptually different.

The respondent should contain all information about the respondent, similar to account information, such as location, age, company.

The survey execution state contains everything to do with running the survey, like start_time, time_since_last_response, etc. It doesn't make sense to have these fields in respondents because it has no meaning, unless it's associated with a survey state.

You're correct that for now all we need is question reference - this allows us to have flexibility and modularity in the future and be clear where new fields should go instead of putting everything in respondent.