Added geonode custom permissions definition for ResourceBase and Layer
Now we manage custom perissions from the user interface
An user without the download_resourcebase permission cannot download a layer, map or document
Display correct options in edit window (edit metadata, styles...) given the permissions the user has for the layer
Returning a 401 if user want to modify metadata but has not a change_resourcebase_metadata permission
Returning a 401 if user want to view a layer but has not a view_resourcebase  permission. Using ugettext messages
Enable edit in gxp if user has change_layer_data permission on the layer
Merge branch 'custom-permissions' of github.com:capooti/geonode into custom-permissions