public function add_answer_action($params)
{
$a = arr::extract($params, ['question_id', 'content', 'type']);
db::exec($this->db, "INSERT INTO i_answers (question_id, content, type) VALUES(:question_id, :content, :type)", [':question_id' => $a['question_id'], ':content' => $a['content'], ':type' => $a['type']]);
$curr_a = db::last_id($this->db);
$this->view->render('json', $curr_a);
}