protected function addConfig()
    {
        try {
            $this->db->createCommand()->batchInsert(
                    PodiumConfig::tableName(),
                    ['name', 'value'],
                    [
                        ['activation_token_expire', PodiumConfig::SECONDS_ACTIVATION_TOKEN_EXPIRE],
                        ['allow_polls', PodiumConfig::FLAG_ALLOW_POLLS],
                        ['email_token_expire', PodiumConfig::SECONDS_EMAIL_TOKEN_EXPIRE],
                        ['from_email', PodiumConfig::DEFAULT_FROM_EMAIL],
                        ['from_name', PodiumConfig::DEFAULT_FROM_NAME],
                        ['hot_minimum', PodiumConfig::HOT_MINIMUM],
                        ['maintenance_mode', PodiumConfig::MAINTENANCE_MODE],
                        ['max_attempts', PodiumConfig::MAX_SEND_ATTEMPTS],
                        ['members_visible', PodiumConfig::FLAG_MEMBERS_VISIBLE],
                        ['merge_posts', PodiumConfig::FLAG_MERGE_POSTS],
                        ['meta_description', PodiumConfig::META_DESCRIPTION],
                        ['meta_keywords', PodiumConfig::META_KEYWORDS],
                        ['name', PodiumConfig::PODIUM_NAME],
                        ['password_reset_token_expire', PodiumConfig::SECONDS_PASSWORD_RESET_TOKEN_EXPIRE],
                        ['recaptcha_secretkey', ''],
                        ['recaptcha_sitekey', ''],
                        ['registration_off', PodiumConfig::REGISTRATION_OFF],
                        ['use_captcha', PodiumConfig::FLAG_USE_CAPTCHA],
                        ['use_wysiwyg', PodiumConfig::FLAG_USE_WYSIWYG],
                        ['version', Podium::getInstance()->version],
                    ]
                )->execute();
            return $this->returnSuccess(Yii::t('podium/flash', 'Default Config settings have been added.'));
        } catch (Exception $e) {
            return $this->returnError($e->getMessage(), __METHOD__,
                Yii::t('podium/flash', 'Error during settings adding')
            );
        }
    }
protected function addConfig()
    {
        try {
            $this->db->createCommand()->batchInsert(
                    PodiumConfig::tableName(),
                    ['name', 'value'],
                    [
                        ['activation_token_expire', PodiumConfig::SECONDS_ACTIVATION_TOKEN_EXPIRE],
                        ['allow_polls', PodiumConfig::FLAG_ALLOW_POLLS],
                        ['email_token_expire', PodiumConfig::SECONDS_EMAIL_TOKEN_EXPIRE],
                        ['from_email', PodiumConfig::DEFAULT_FROM_EMAIL],
                        ['from_name', PodiumConfig::DEFAULT_FROM_NAME],
                        ['hot_minimum', PodiumConfig::HOT_MINIMUM],
                        ['maintenance_mode', PodiumConfig::MAINTENANCE_MODE],
                        ['max_attempts', PodiumConfig::MAX_SEND_ATTEMPTS],
                        ['members_visible', PodiumConfig::FLAG_MEMBERS_VISIBLE],
                        ['merge_posts', PodiumConfig::FLAG_MERGE_POSTS],
                        ['meta_description', PodiumConfig::META_DESCRIPTION],
                        ['meta_keywords', PodiumConfig::META_KEYWORDS],
                        ['name', PodiumConfig::PODIUM_NAME],
                        ['password_reset_token_expire', PodiumConfig::SECONDS_PASSWORD_RESET_TOKEN_EXPIRE],
                        ['recaptcha_secretkey', ''],
                        ['recaptcha_sitekey', ''],
                        ['registration_off', PodiumConfig::REGISTRATION_OFF],
                        ['use_captcha', PodiumConfig::FLAG_USE_CAPTCHA],
                        ['use_wysiwyg', PodiumConfig::FLAG_USE_WYSIWYG],
                        ['version', Podium::getInstance()->version],
                    ]
                )->execute();
            return $this->returnSuccess(Yii::t('podium/flash', 'Default Config settings have been added.'));
        } catch (Exception $e) {
            return $this->returnError($e->getMessage(), __METHOD__,
                Yii::t('podium/flash', 'Error during settings adding')
            );
        }
    }
protected function addConfig ( ) { try { $ this -> db -> createCommand ( ) -> batchInsert ( PodiumConfig :: tableName ( ) , [ 'name' , 'value' ] , [ [ 'activation_token_expire' , PodiumConfig :: SECONDS_ACTIVATION_TOKEN_EXPIRE ] , [ 'allow_polls' , PodiumConfig :: FLAG_ALLOW_POLLS ] , [ 'email_token_expire' , PodiumConfig :: SECONDS_EMAIL_TOKEN_EXPIRE ] , [ 'from_email' , PodiumConfig :: DEFAULT_FROM_EMAIL ] , [ 'from_name' , PodiumConfig :: DEFAULT_FROM_NAME ] , [ 'hot_minimum' , PodiumConfig :: HOT_MINIMUM ] , [ 'maintenance_mode' , PodiumConfig :: MAINTENANCE_MODE ] , [ 'max_attempts' , PodiumConfig :: MAX_SEND_ATTEMPTS ] , [ 'members_visible' , PodiumConfig :: FLAG_MEMBERS_VISIBLE ] , [ 'merge_posts' , PodiumConfig :: FLAG_MERGE_POSTS ] , [ 'meta_description' , PodiumConfig :: META_DESCRIPTION ] , [ 'meta_keywords' , PodiumConfig :: META_KEYWORDS ] , [ 'name' , PodiumConfig :: PODIUM_NAME ] , [ 'password_reset_token_expire' , PodiumConfig :: SECONDS_PASSWORD_RESET_TOKEN_EXPIRE ] , [ 'recaptcha_secretkey' , '' ] , [ 'recaptcha_sitekey' , '' ] , [ 'registration_off' , PodiumConfig :: REGISTRATION_OFF ] , [ 'use_captcha' , PodiumConfig :: FLAG_USE_CAPTCHA ] , [ 'use_wysiwyg' , PodiumConfig :: FLAG_USE_WYSIWYG ] , [ 'version' , Podium :: getInstance ( ) -> version ] , ] ) -> execute ( ) ; return $ this -> returnSuccess ( Yii :: t ( 'podium/flash' , 'Default Config settings have been added.' ) ) ; } catch ( Exception $ e ) { return $ this -> returnError ( $ e -> getMessage ( ) , __METHOD__ , Yii :: t ( 'podium/flash' , 'Error during settings adding' ) ) ; } }
Adds config default settings.
@return string result message.
Adds config default settings .