node_embed_views_pre_render() checks on View name to suppress the admin menu. If you use Features, you can't use the standard View, because you can't featurize that, so you have to make your own View, which means another name, which means the admin menu isn't suppressed.

If you wouldn't check on View name, but View tags, that wouldn't be a problem. You can also check on the current path (that's even better, because that's how you get to the (custom) view).

It's not really a bug, but it is a design flaw IMO.

I haven't made a patch, because it's too simple and literally one minute of work if you have repo write access:

  1. Change $view->name to $view->tag in node_embed_views_pre_render().
  2. Change $view->tag = ''; to $view->tag = 'ckeditor_node_embed'; in ckeditor_node_embed.view.inc.

Grazi!

Comments

rudiedirkx’s picture

Wow. Nothing?

rudiedirkx’s picture

I changed

if ($view->name == 'ckeditor_node_embed' && $view->current_display == 'page_1') {

to

  if (is_int(strpos($view->name, 'ckeditor_node_embed')) && $view->current_display == 'page_1') {

and that works for me, because my override view has 'ckeditor_node_embed' in its name.

tessa bakker’s picture

Issue summary: View changes
Status: Active » Needs review
tessa bakker’s picture

Version: 7.x-1.1 » 7.x-1.x-dev
StatusFileSize
new586 bytes

Small patch with a nice hidden feature for pro's.

mrharolda’s picture

Priority: Normal » Major
StatusFileSize
new547 bytes

How about this?

rudiedirkx’s picture

Status: Needs review » Reviewed & tested by the community

I concur. Excellent work, young man!

  • MrHaroldA committed c1d536c on 7.x-1.x
    Issue #1729854 by rudiedirkx: check on path instead of view name/display...
mrharolda’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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