Skip to main content
12 events
when toggle format what by license comment
Jun 15, 2020 at 9:13 history edited CommunityBot
Commonmark migration
May 22, 2019 at 20:08 vote accept usernameabc
May 8, 2019 at 16:34 answer added usernameabc timeline score: 1
May 5, 2019 at 14:16 comment added berramou the second code works for me, but i think the is ; in it shouldn't be after ->condition('status', 1); try with ` $node_storage = \Drupal::entityTypeManager()->getStorage('node'); $query = $node_storage->getQuery() ->condition('type', 'article') ->condition('status', 1) ->condition('field_document', $linked_document_id, '='); $results = $query->execute();`
May 4, 2019 at 7:05 comment added Jaypan Again though, are you sure $linked_document_id contains the value you think it does? Have you done kint() on that variable?
May 3, 2019 at 15:47 history edited usernameabc
edited tags
May 3, 2019 at 15:01 comment added usernameabc @Jaypan field_document is required and will always have a value. I tried using a bunch of kint statements as well. for some reason the ->condition('field_document', $linked_document_id, '='); just returns zero results
May 2, 2019 at 23:38 comment added Jaypan Have you checked that $linked_document_id contains the value you think it should?
May 2, 2019 at 23:37 comment added usernameabc @Jaypan We only used the andConditionGroup() to see if we got separate results, but that did not happen.
May 2, 2019 at 23:37 history edited usernameabc CC BY-SA 4.0
added 596 characters in body
May 2, 2019 at 23:27 comment added Jaypan Although I don't think it would affect your result, is there a reason why you are creating an andConditionGroup() instead of just appending your condition onto the other conditions? Conditions by default are 'AND', and since your group only has as single condition, it doesn't appear to be grouping anything.
May 2, 2019 at 22:57 history asked usernameabc CC BY-SA 4.0