Settings.php
protected function dbUpdate($category, $key, $value)
    {
        $updated_by = \Yii::$app->user->getId();
        $this->getDb()->createCommand('
            UPDATE
                {{setting}}
            SET
                `value` = :value,
                `updated_at` = NOW(),
                `updated_by` = :updated_by
            WHERE
                category = :category
                AND `key` = :key
        ', compact('category', 'key', 'value', 'updated_by'))->execute();
    }
protected function dbUpdate($category, $key, $value)
    {
        $updated_by = \Yii::$app->user->getId();
        $this->getDb()->createCommand('
            UPDATE
                {{setting}}
            SET
                `value` = :value,
                `updated_at` = NOW(),
                `updated_by` = :updated_by
            WHERE
                category = :category
                AND `key` = :key
        ', compact('category', 'key', 'value', 'updated_by'))->execute();
    }
protected function dbUpdate ( $ category , $ key , $ value ) { $ updated_by = \ Yii :: $ app -> user -> getId ( ) ; $ this -> getDb ( ) -> createCommand ( '
            UPDATE
                {{setting}}
            SET
                `value` = :value,
                `updated_at` = NOW(),
                `updated_by` = :updated_by
            WHERE
                category = :category
                AND `key` = :key
        ' , compact ( 'category' , 'key' , 'value' , 'updated_by' ) ) -> execute ( ) ; }
Updates setting in database

@param string $category Category name
@param string $key Setting key
@param string $value Setting value
@throws \yii\db\Exception
Updates setting in database