Problem

Filtering nodes by 'Status' in Views gives the opposite results to what it should.

Modules installed

  • Search API RC1
  • Entity API RC1
  • Views RC3

Steps to reproduce

  1. Enable default index
  2. Add 'Status' to index as Boolean
  3. (Re)index content
  4. Run cron*
  5. Clear all caches*
  6. Wait 5 minutes*

*Probably not necessary, but just to make sure...

Add a filter for published nodes and only unpublished nodes are shown. Changing the filter to unpublished nodes and only published nodes are shown.

Comments

Could be related to this issue: #1263214: Indexing with „Index items immediately“ indexes old entity state - However, 'Index immediately' is not checked.

It's not a big issue because I just select the opposite of what I want in Views...

CommentFileSizeAuthor
#1 1344056--node-status-1.patch465 bytesdrunken monkey

Comments

drunken monkey’s picture

Title: Strange behaviour when filtering by 'Status' in Views » Options list for node status is the wrong way round
Project: Search API » Entity API
Component: Views integration » Core integration
Status: Active » Needs review
StatusFileSize
new465 bytes

That seems to stem from the Entity API returning the false labels for that field. The attached patch should not only fix this, but also uses the shiny node constants.

tnightingale’s picture

Works for me, thanks!

fago’s picture

Status: Needs review » Fixed

ouch. Thanks, committed.

Status: Fixed » Closed (fixed)

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

fenda’s picture

Status: Closed (fixed) » Active

Is it me or is this still broken?

achton’s picture

@drupaljoe: The patch in #1 was definitely commited. Do you still think this is broken?

fenda’s picture

Status: Active » Closed (fixed)

@achton My apologies, its over a year since my last commit and I have completely forgotten where I was experiencing broken functionality. If it comes back to me or I experience it again, i'll comment back.