thyseus / yii-user-management

a user management module collection for the yii framework
186 stars 122 forks source link

CException Property "YumProfile.show_friends" is not defined. #128

Closed nagarajpg closed 11 years ago

nagarajpg commented 11 years ago

Why YUM is throwing this error? there is no property as show_friends in property table. and it is pointing to the file: friednship/views/friendship/friend.php

<?php 02 if(!$profile = @$model->profile) 03 return false; 04 05 if($profile->show_friends == 2) { // IN THIS LINE 06 echo '

'; 07 if(isset($model->friends)) { 08 echo '' . Yum::t('Friends of {username}', array( 09 '{username}' => $model->username)) . ''; 10 foreach($model->friends as $friend) { please provide me the hints to resolve this

rypwalters commented 11 years ago

Looks like the re-write of the Profile Privacy Settings moved settings into the profile table.

You'll need: ALTER TABLE profile ADD COLUMN show_friends SMALLINT NOT NULL DEFAULT 2 AFTER about , ADD COLUMN allow_comments TINYINT(1) NOT NULL DEFAULT 1 AFTER show_friends ;

Be sure to put in your database/profile table name.

nagarajpg commented 11 years ago

Thanks :) It worked :+1: