Forums | Mahara Community

Developers /
Modification of "Edit profile view"


anonymous profile picture
Deleted user
Posts: 34

15 September 2009, 10:55 PM

I have made some fields static on the users profile page.  I was wondering if somebody could tell me how to remove these (now) static fields from the tabbed area within "Edit profile view" so the user can longer add them.
The fields I want to take away from the tabbed area are the following:

  • Feedback
  • My Labs
  • My Groups 

 

anonymous profile picture
Deleted user
Posts: 1643

16 September 2009, 7:40 PM

What is "Feedback" and "My Labs" ? They're not part of Mahara, have you changed some language strings?

There is a contract method called "allowed_in_view", that takes a View object and returns whether a blocktype is allowed in a view. For example, here's the one for the blog blocktype (artefact/blog/blocktype/blog/lib.php):

     /**
     * Blog blocktype is only allowed in personal views, because currently 
     * there's no such thing as group/site blogs
     */
    public static function allowed_in_view(View $view) {
        return $view->get('owner') != null;
    }

You could probably implement that for the blocktypes you want to ban.

2 results