Hello,

I would like to enable plain users to export / import their nodes.

Export works fine, yet to import, you need to be an admin.

Could we have a lightweight import tab in addition to the import link?

Comments

danielb’s picture

Category: feature » support
Status: Active » Fixed

You can add your own menu link to admin/content/import, or give them permission to access administration pages, without giving all the permissions that comes with being an admin.

giorgio79’s picture

Any tips on adding it next to the Export tab on node pages? :)

I think that would require custom coding.

danielb’s picture

Yes it would require your own hook_menu implementation, but it doesn't make sense there because those are meant to be options for that particular node.

I guess you will also need the 'administer nodes' permission to see the list of nodes after import - but that's the game you're playing with this module, they should be someone who can do that anyway.

giorgio79’s picture

It will be only their nodes they created. So the uid will be the current user, so no administer nodes permission :)

I think there is a viable use case though for non admins importing / expoting only their own nodes.

I see there is permission for exporting own nodes though :)

danielb’s picture

I will reconsider the permissions and where you get redirected after import for the next version, but I still don't think the tab is a good idea.

giorgio79’s picture

Yep, instead of the tab perhaps a separate menu item in the navigation would do it too. :)

It could even be a separate, toned done page (perhaps at /content/import) without the link to the Node Export settings for plain users.

As I understand, any page with /admin requires admin permissions, which wont be granted for plain authenticated users.

danielb’s picture

Category: support » feature
Status: Fixed » Active

Good points, I will open this to remind me to think about that. I don't think you do need admin permissions to go to a path starting with admin/ but, it does seem like that may not be the best place for it.

Perhaps under node/add (create content) ??

giorgio79’s picture

Yes, that sounds good, sg like /node/add/import, or simply /node/import.

PS
Although /node/add/import might conflict with CCK if someone has a content type named Import

danielb’s picture

Status: Active » Fixed

I've made these changes in the 3.x branch.

giorgio79’s picture

Fantastic, thanks. Look forward to the release :)

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.