public function actionAddHeadword($class, $word)
    {
        $extMgr = Yii::$app->rhoone->ext;
        /* @var $extMgr \rhoone\base\ExtensionManager */
        $model = $extMgr->getModel($class);
        if (!$model) {
            throw new Exception('`' . $class . '` does not exist.');
        }
        try {
            $result = $model->setHeadword($word, true);
            echo ($result ? "$word added." : "Failed to add.");
        } catch (\Exception $ex) {
            throw new Exception($ex->getMessage());
        }
        return 0;
    }