contenta_jsonapi icon indicating copy to clipboard operation
contenta_jsonapi copied to clipboard

Local tasks missing on node types apart from page.

Open BrianGilbert opened this issue 6 years ago • 2 comments

I've tracked this down to the following https://github.com/contentacms/contenta_jsonapi/blob/8.x-3.x/modules/contenta_enhancements/contenta_enhancements.module#L368

If I change 'page' to one of the affected node types, then that node type displays local tasks correctly

BrianGilbert avatar Oct 15 '19 22:10 BrianGilbert

Changing line 368 to the following resolves the issue for me, but I am unsure what the if statement was doing and if this will cause other issues?

  if ($entity->entityTypeId != 'node') {

BrianGilbert avatar Oct 15 '19 23:10 BrianGilbert

Thank you for reporting the issue and for the pull request. However, this fix provided now directly bypasses the contenta_enhancements_node_view_alter function completely. And the jsonapi output on the node is not displayed at all, which doesn't seem right. I might have mistaken otherwise. Please correct me if that is the case.

ajitdev avatar Dec 13 '19 14:12 ajitdev