[ckan-dev] R: R: how I can disable edit right to visitor and logged_in
Salvatore Altiero
salvatore.altiero at linksmt.it
Thu Jan 31 17:44:36 UTC 2013
Hi Seam,
I've looked my log file and I've seen this stack trace error:
[Thu Jan 31 14:36:23 2013] [error] 2013-01-31 14:36:23,143 ERROR [ckan.model.modification]
[Thu Jan 31 14:36:23 2013] [error] Traceback (most recent call last):
[Thu Jan 31 14:36:23 2013] [error] File "/home/opendata/pyenv/src/ckan/ckan/model/modification.py", line 76, in notify
[Thu Jan 31 14:36:23 2013] [error] observer.notify(entity, operation)
[Thu Jan 31 14:36:23 2013] [error] File "/home/opendata/pyenv/src/ckanext-datastorer/ckanext/datastorer/plugin.py", line 30, in notify
[Thu Jan 31 14:36:23 2013] [error] self._create_datastorer_task(entity)
[Thu Jan 31 14:36:23 2013] [error] File "/home/opendata/pyenv/src/ckanext-datastorer/ckanext/datastorer/plugin.py", line 63, in _create_datastorer_task
[Thu Jan 31 14:36:23 2013] [error] datastorer_task_status)
[Thu Jan 31 14:36:23 2013] [error] File "/home/opendata/pyenv/src/ckan/ckan/logic/action/update.py", line 456, in task_status_update
[Thu Jan 31 14:36:23 2013] [error] check_access('task_status_update', context, data_dict)
[Thu Jan 31 14:36:23 2013] [error] File "/home/opendata/pyenv/src/ckan/ckan/logic/__init__.py", line 157, in check_access
[Thu Jan 31 14:36:23 2013] [error] raise NotAuthorized(msg)
[Thu Jan 31 14:36:23 2013] [error] NotAuthorized
Can you help me to debug this blocked problem in my ckan platform ?
I remaind you that I've executed only this commands:
paster rights remove visitor anon_editor package:all
paster rights remove logged_in editor package:all
paster rights remove visitor anon_editor system
paster rights remove logged_in editor system
Is possible that I've broken everythings ?
-----Messaggio originale-----
Da: ckan-dev-bounces at lists.okfn.org [mailto:ckan-dev-bounces at lists.okfn.org] Per conto di Salvatore Altiero
Inviato: mercoledì 30 gennaio 2013 18:58
A: 'CKAN Development Discussions'
Oggetto: [ckan-dev] R: how I can disable edit right to visitor and logged_in
Hi Seam,
many thanks for your answer. I've removed public's rights with commands paster rights remove visitor anon_editor package:all paster rights remove logged_in editor package:all paster rights remove visitor anon_editor system paster rights remove logged_in editor system
But I've not resolved my problem. I've resolved my problem (with the suggestion of Luca De Santis) by fixing recline.js.
I've disabled the events onEdit in recline.js and removed the html that display the edit button.
Only with this fix I've disabled editing rights in the preview page of resources.
But now I've another problem, I cannot add resources to every datasource.
When I add a resource file and save it, I've this error message:
"Non autorizzato a leggere il pacchetto <built-in function id>"
(Not authorized to read the package <built-in function id>)
Can you help me ?
-----Messaggio originale-----
Da: ckan-dev-bounces at lists.okfn.org [mailto:ckan-dev-bounces at lists.okfn.org] Per conto di Sean Hammond
Inviato: giovedì 24 gennaio 2013 10:14
A: ckan-dev at lists.okfn.org
Oggetto: Re: [ckan-dev] how I can disable edit right to visitor and logged_in
> how I can disable edit right to visitor and logged_in to all resources
> of all datasets in my ckan 1.7 server ?
>
>
>
> In my opnedata server, every visitors can edit datas in every resourse
> by data preview edit button.
>
>
>
> Can someone help me ?
You can either change the ckan.default_roles.* settings in your config file or, if you already have registered users, you can use the `paster rights` and `paster roles` commands. The docs are here:
http://docs.ckan.org/en/ckan-1.7/authorization.html
Let me know if you have any further questions.
_______________________________________________
ckan-dev mailing list
ckan-dev at lists.okfn.org
http://lists.okfn.org/mailman/listinfo/ckan-dev
Unsubscribe: http://lists.okfn.org/mailman/options/ckan-dev
--
This email was Virus checked by Astaro Security Gateway. http://www.astaro.com
_______________________________________________
ckan-dev mailing list
ckan-dev at lists.okfn.org
http://lists.okfn.org/mailman/listinfo/ckan-dev
Unsubscribe: http://lists.okfn.org/mailman/options/ckan-dev
--
This email was Virus checked by Astaro Security Gateway. http://www.astaro.com
More information about the ckan-dev
mailing list