Reference Field not showing

I am trying to show a referenced value in the content list, but it is just showing as “1 References”

This is a 1:1 reference, however the only way I know so far to make a 1:1 reference is by setting the constraints for min and max items to both be 1. is there a better way? I suspect this may be the problem, and it’s inferring that this is a 1:M reference.

In the referenced schema, I have the ‘name’ string field set to be the ‘Reference Field’, but this does not change the display.

I expected to see the name value instead of “1 References”

This issue is related, but it’s flagged as implemented to I am opening a new issue:

I have…

  • [ x] Checked the logs and have provided the logs if I found something suspicious there

I’m submitting a…

  • [ ?] Regression (a behavior that stopped working in a new release)
  • [ x] Bug report
  • [ ] Performance issue
  • [ ] Documentation issue or request

Current behavior

I see “1 References”

Expected behavior

I expected to see the name value instead of “1 References”

Environment

  • [ x] Self hosted with docker
  • [ ] Self hosted with IIS
  • [ ] Self hosted with other version
  • [ ] Cloud version

Version: [VERSION] git SHA bb4f09f20be7bcfc6101f2641bb76701478799b6

Yes, MaxItems must be set to 1 so far.

ok so that’s what I have it set to. I guess what threw me off is that the data implies it’s still a 1:m reference because it’s a list of items not just one item. ex:

iv: [name] and not iv: name

In any case, that’s not the actual focus of the issue here, just a side tangent. I’m still unable to see the name value in the UI list when it’s being referenced.

Is there something I’m doing wrong, or is this a bug?

Here is how it works. I might show some new screens here, but it works with previous versions as well.

Lets assume we have two schemas:

  • Parent
  • Child field

We also decide which fields to show when this item is referenced by another schema:

The parent schema:

Here we decide which fields we want to show in our content list:

Furthermore we limit the reference to 1:

And we toggle the resolving on:

This will produce the following result then:

A little bit complicated, I know, but I was very keen abut performance when I developed that.

oh wow, thank you so much for taking the time to show the flow. You’re a real professional! :slight_smile:

These screens are slightly newer than mine, I will be sure to pull recent changes and try again.

My first guess is that I was missing the ‘resolve reference’ option in the ‘editing’ tab, but I will confirm after testing.

1 Like

I have now updated to the latest master:

When the reference is an asset, the editing tab shows resolve image and not resolve reference, but I don’t have an image. I would like to see the file or slug name be resolved instead.

When the reference is a 1:1 reference, This works as expected now. :slight_smile:

So far it is only designed for images, but it should be easy to generalize it and provide more options. Please create a feature request.