Hi.
Thanks for this answer! I have been able to remove what I wanted from the top toolbar.
I would also like to remove some other buttons/options associated to a metadata record, like the option to assign/change privileges, the option to generate a child or the option to change the group and category of a metadata record.
[cid:image001.jpg@...1890...]
[cid:image002.jpg@...1890...]
I tried editing the following files using the same directives you mentioned on your email, but it didn´t work
\catalog\views\default\directives\partials\mdactionmenu.html
\catalog\components\search\resultsview\partials\viewtemplates\editor.html
\catalog\components\metadataactions\partials\metadatacategoryupdater.html
[cid:image003.jpg@...1890...]
At least we think those are the HTML we have to update in order to remove the options we don’t want, but we are not 100% sure.
Could you help us with this?
Thanks!
Best regards.
Óscar Diago Alonso
Desarrollador GIS / GIS Developer
Tel: +34 945131372 e-mail: mailto:oscar.diago@…1602…
Calle Pintor Clemente Arraiz, 3 Bajo 01008 Vitoria-Gasteiz
Geograma. Expertos en GeoInformación
[GEOGRAMA] [cid:image006.gif@...1890...] [cid:image005.png@...1891...] [cid:image007.png@...1891...]
www.geograma.com<http://www.geograma.com/>
Tratamos su dirección de correo electrónico y otros datos personales para mantener el contacto y comunicación con Ud. y, en su caso, remitirle información sobre nuestros productos y servicios. Si no desea recibir tal información envíe un e-mail en tal sentido a LOPD@...1834...<mailto:LOPD@…1834…>
Puede acceder, rectificar y suprimir los datos, así como otros derechos, como se detalla en la información adicional y completa a su disposición en nuestra política de privacidad en la página web https://www.geograma.com/politica-de-privacidad/
Este mensaje, y sus posibles archivos adjuntos, es privado y confidencial, si no es Ud. el destinatario y ha recibido este mensaje por error, rogamos nos lo comunique inmediatamente sin difundir, almacenar o copiar su contenido
De: Juan Luis Rodríguez Ponce <juanluisrp@...444...>
Enviado el: viernes, 22 de enero de 2021 9:42
Para: Oscar Diago Alonso <Oscar.Diago@...1602...>
CC: geonetwork-users@lists.sourceforge.net
Asunto: Re: [GeoNetwork-users] How to remove buttons for custom interface in GeoNetwork 4.0
Hi Óscar,
the way to do that is modifying the header HTML template [1]. There are some predefined Javascript functions you can use to check the user profile:
user.isAdministratorOrMore()
user.isUserAdminOrMore()
user.isReviewerOrMore()
user.isEditorOrMore()
user.isRegisteredUserOrMore()
In GeoNetwork these profiles are hierarchical from ResgisteredUser as the least privileged to Admin as the most privileged. These functions check if the user is at least the role described in the name. For example, isEditorOrMore will return true for Editor, Reviewer, UserAdmin and Administrator profiles.
[1] https://github.com/geonetwork/core-geonetwork/blob/master/web-ui/src/main/resources/catalog/templates/top-toolbar.html#L59-L102
[2] https://github.com/geonetwork/core-geonetwork/blob/master/web-ui/src/main/resources/catalog/templates/top-toolbar.html#L60
[3] https://github.com/geonetwork/core-geonetwork/blob/master/web-ui/src/main/resources/catalog/templates/top-toolbar.html#L96
Regards,
Juan Luis.
On Fri, Jan 22, 2021 at 8:40 AM Oscar Diago Alonso <Oscar.Diago@...1602...<mailto:Oscar.Diago@…1602…>> wrote:
Good morning.
I would like to remove some buttons from the "Contribute" menú depending ion the role of the user.
I've been checking the file "config-security-mapping.xml", but it seems that one is only to grant or deny access to an URL.
Is it possible to remove buttons from the user interface depending on the user role? I have found nothing about it in the documentaiton.
Thanks for any help provided.
Best regards.
Óscar Diago Alonso
Desarrollador GIS / GIS Developer
Tel: +34 945131372 e-mail: mailto:oscar.diago@…1602…
Calle Pintor Clemente Arraiz, 3 Bajo 01008 Vitoria-Gasteiz
Geograma. Expertos en GeoInformación
[cid:image002.png@...1603...]
www.geograma.com<http://www.geograma.com><http://www.geograma.com/>
Tratamos su dirección de correo electrónico y otros datos personales para mantener el contacto y comunicación con Ud. y, en su caso, remitirle información sobre nuestros productos y servicios. Si no desea recibir tal información envíe un e-mail en tal sentido a LOPD@...1834...<mailto:LOPD@…1834…><mailto:LOPD@…1834…>
Puede acceder, rectificar y suprimir los datos, así como otros derechos, como se detalla en la información adicional y completa a su disposición en nuestra política de privacidad en la página web https://www.geograma.com/politica-de-privacidad/
Este mensaje, y sus posibles archivos adjuntos, es privado y confidencial, si no es Ud. el destinatario y ha recibido este mensaje por error, rogamos nos lo comunique inmediatamente sin difundir, almacenar o copiar su contenido
Óscar Diago Alonso
Analista / Desarrollador GIS
oscar.diago@...1602...<mailto:oscar.diago@…1602…>
Tfno.: +34 945 13 13 72
C/ Pintor Clemente Arráiz, 3 BJ (01008) Vitoria-Gasteiz, Álava
[https://www.geograma.com/pie-de-mail/geogramatalks.png\]<https://bit.ly/geogramatalks>
Si no ves la imagen puedes acceder al boletín de Geograma desde aquí.<https://bit.ly/geogramatalks>
Tratamos su dirección de correo electrónico y otros datos personales para mantener el contacto y comunicación con Ud. y, en su caso, remitirle información sobre nuestros productos y servicios. Si no desea recibir tal información envíe un e-mail en tal sentido a dpd@...1602...<mailto:dpd@…1602…>. Puede acceder, rectificar y suprimir los datos, así como otros derechos, como se detalla en la información adicional y completa a su disposición en nuestra política de privacidad en la URL bit.ly/geo-privacidad<http://bit.ly/geo-privacidad>\. Este mensaje y los archivos adjuntos al mismo son privados y confidenciales, si no es Ud. el destinatario y ha recibido este mensaje por error, rogamos nos lo comunique inmediatamente sin difundir, almacenar o copiar su contenido.
[https://www.geograma.com/pie-de-mail/geo-linkedin.png\]<https://bit.ly/geo-linkedin> [https://www.geograma.com/pie-de-mail/geo-twitter.png\] <https://bit.ly/geo-tw>
_______________________________________________
GeoNetwork-users mailing list
GeoNetwork-users@lists.sourceforge.net<mailto:GeoNetwork-users@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/geonetwork-users
GeoNetwork OpenSource is maintained at http://sourceforge.net/projects/geonetwork
--
Vriendelijke groeten / Kind regards,
Juan Luis Rodríguez.
[https://www.geocat.net/wp-content/uploads/2015/07/GeoCat_small1.png\]<http://www.geocat.net/>
Veenderweg 13
6721 WD Bennekom
The Netherlands
T: +31 (0)318 416664<tel:+31318416664>
Please consider the environment before printing this email.
(attachments)






