44 var
$fields = array (
"survey_question_id" => Number,
45 "question_type_id" => Number,
47 "question_name" => String,
50 "char_limit" => Number,
52 "context_help" => Text
65 $answer = Query::create(
SurveyAnswer,
"WHERE response_id=:response_id AND survey_question_id=:survey_question_id")
66 ->bind(
":response_id",
$response_id,
":survey_question_id", $this->survey_question_id)
84 if($this->survey_question_id)
85 return querySingle(
SurveyQuestionXref,
"WHERE survey_question_id = {$this->survey_question_id} AND survey_id = $survey_id");
90 if(!$this->survey_question_id)
93 $count = queryValue(
SurveyAnswer,
"COUNT(1)",
"WHERE survey_question_id={$this->survey_question_id}");
107 if(!$this->survey_question_id)
120 $this->table =
"survey_question";
121 $this->primary_key =
"survey_question_id";
123 $this->DataItem(func_get_args());
Defines the relations and functions required of a Question class that uses Questionnaire form and res...
static using()
Import the datamodels, views and manifest for the specified component(s).
isEditable()
Returns true if the question can be edited and false if it cannot.
SurveyQuestionXref($survey_id)