public function getPrice()
    {
        if (\Yii::$app->user->isGuest) {
            $params = [
                'combination_id' => $this->id,
                'user_group_id' => UserGroup::USER_GROUP_ALL_USERS
            ];
        } else {
            $params = [
                'combination_id' => $this->id,
                'user_group_id' => \Yii::$app->user->identity->user_group_id
            ];
        }
        $combinationPrice = CombinationPrice::find()->where($params)->one();
        return $combinationPrice->price;
    }
public function getPrice()
    {
        if (\Yii::$app->user->isGuest) {
            $params = [
                'combination_id' => $this->id,
                'user_group_id' => UserGroup::USER_GROUP_ALL_USERS
            ];
        } else {
            $params = [
                'combination_id' => $this->id,
                'user_group_id' => \Yii::$app->user->identity->user_group_id
            ];
        }
        $combinationPrice = CombinationPrice::find()->where($params)->one();
        return $combinationPrice->price;
    }
public function getPrice ( ) { if ( \ Yii :: $ app -> user -> isGuest ) { $ params = [ 'combination_id' => $ this -> id , 'user_group_id' => UserGroup :: USER_GROUP_ALL_USERS ] ; } else { $ params = [ 'combination_id' => $ this -> id , 'user_group_id' => \ Yii :: $ app -> user -> identity -> user_group_id ] ; } $ combinationPrice = CombinationPrice :: find ( ) -> where ( $ params ) -> one ( ) ; return $ combinationPrice -> price ; }
Gets price for user group
@return array|null|ActiveRecord|Price
Gets price for user group