| 04:43 | * | farmBOT has joined |
| 16:06 | * | < matrix.org/_matrix/media/r0/download/mat > |
| 16:07 | * | uploaded an image: (33KiB) < matrix.org/_matrix/media/r0/download/mat > |
| 16:08 | symbioquine[m] | I have the equivalent of [this code](github.com/farmOS/farmOS/blob/92f854b9be) in my view too... |
| 16:13 | paul121[m] | huh.. seems like you've got it integrated with `hook_farm_ui_entity_views` just fine |
| 16:14 | paul121[m] | my guess is an issue with the contextual filter |
| 16:14 | paul121[m] | can change the "display no results behavior" to show something? |
| 16:15 | paul121[m] | and/or for the contextual filter, if it doesn't exist or validate, make sure it still renders something? |
| 16:15 | symbioquine[m] | Yeah, I tried that, but still nothing is showing up under the header. |
| 16:15 | symbioquine[m] | It's like the view isn't even trying to render actually... |
| 16:15 | paul121[m] | right.. weird! |
| 16:16 | paul121[m] | and you can preview the view OK? by manually filling the contextual filter? |
| 16:18 | symbioquine[m] | Well, I don't have much experience with these contextual views so I wasn't sure what input to put there... |
| 16:18 | symbioquine[m] | some sort of query string? |
| 16:19 | paul121[m] | ah. yea, try just putting in an asset id |
| 16:19 | symbioquine[m] | as just the bare number? |
| 16:19 | paul121[m] | yes |
| 16:19 | symbioquine[m] | interesting |
| 16:19 | paul121[m] | if that doesn't work you might need to put in `asset/{id}` |
| 16:20 | paul121[m] | your contextual filter should probably be configured to grab the second path argument from the URL |
| 16:20 | paul121[m] | (wait... maybe the third. is the path `/farm/asest/{id}` ?) My brain is stuck in D9) |
| 16:21 | paul121[m] | oh... you're putting this on a term page! |
| 16:21 | symbioquine[m] | I'm testing this part first on the `farm_plantings` view |
| 16:22 | symbioquine[m] | Just to make sure I understand how to test it with a working view |
| 16:23 | symbioquine[m] | It does render when I set the path to `/farm/asset/2569` (a valid planting id), but it didn't seem to affect the results - which probably makes sense since there isn't a contextual filter for planting on the plantings view. |
| 16:23 | paul121[m] | right |
| 16:24 | paul121[m] | for your `farm_seeds` view I think the contextual filter would be `/farm/crop/{crop_name}` |
| 16:25 | paul121[m] | with a contextual filter that validates the taxonomy term name |
| 16:26 | symbioquine[m] | Just focusing on the `farm_plantings` view though (which we know works) - if I put in `/farm/crop/Wheat-Kyle` it doesn't appear to affect the results in the view preview. |
| 16:27 | * | uploaded an image: (86KiB) < matrix.org/_matrix/media/r0/download/mat > |
| 16:28 | symbioquine[m] | This is at `/admin/structure/views/view/farm_plantings/edit` |
| 16:28 | paul121[m] | maybe it does need the taxonomy term ID ? |
| 16:28 | symbioquine[m] | I also tried `/taxonomy/term/404` |
| 16:34 | paul121[m] | hmm |
| 16:35 | symbioquine[m] | I think I might need to trace through [this code](github.com/farmOS/farmOS/blob/92f854b9be) next... |
| 16:35 | symbioquine[m] | Might be somehow it's not finding my view or passing the args as expected. |
| 16:39 | paul121[m] | yeah |
| 16:39 | paul121[m] | I'm trying to find where `farm_plantings` is added to the term page? |
| 16:39 | paul121[m] | did you find that? |
| 16:39 | symbioquine[m] | yeah |
| 16:40 | symbioquine[m] | oh, wait |
| 16:40 | symbioquine[m] | No, I'm not sure about that |
| 16:41 | paul121[m] | I think the `farm_crops` view might be used there.. |
| 16:41 | symbioquine[m] | I was using these examples; [1](github.com/farmOS/farmOS/blob/92f854b9be), [2](github.com/farmOS/farmOS/blob/92f854b9be) |
| 16:41 | symbioquine[m] | but maybe they're not representative. |
| 16:42 | paul121[m] | [here](github.com/farmOS/farmOS/blob/92f854b9be) |
| 16:42 | symbioquine[m] | But that only has an effect if vocabulary_machine_name == `farm_crop_families` |
| 16:43 | symbioquine[m] | So, I think that's supposed to add the list of `farm_crops` to the `farm_crop_families` taxonomy page. |
| 16:43 | paul121[m] | ah ah yes. you're right |
| 16:44 | symbioquine[m] | Could it be this: github.com/farmOS/farmOS/blob/92f854b9be ? |
| 16:46 | paul121[m] | think so! |
| 16:48 | paul121[m] | well, only kinda |
| 16:48 | paul121[m] | I think specifying `farm_asset` must tell it to use the view configured for `planting` asset |
| 16:49 | paul121[m] | * I think specifying `farm_asset` must tell it to use the view configured for `planting` asset defined [here](github.com/farmOS/farmOS/blob/92f854b9be) |
| 16:50 | paul121[m] | * I think specifying `farm_asset = planting` must tell it to use the view configured for `planting` asset defined [here](github.com/farmOS/farmOS/blob/92f854b9be) |
| 16:51 | paul121[m] | based on the docs [here](github.com/farmOS/farmOS/blob/92f854b9be) |
| 16:57 | paul121[m] | You could also implement `hook_entity_view` and render the view yourself: github.com/farmOS/farmOS/blob/92f854b9be |
| 17:03 | symbioquine[m] | Cool, I'll play around with those this evening... Thanks for looking into it! |
| 18:14 | * | twiclo has quit (Ping timeout: 258 seconds) |