SharePoint / sp-dev-docs

SharePoint & Viva Connections Developer Documentation
https://docs.microsoft.com/en-us/sharepoint/dev/
Creative Commons Attribution 4.0 International
1.25k stars 1.01k forks source link

Failed to load lookup field source list in modern list view edit column pane when the lookup field "LookupList" property is lowercase #7899

Open yungfu opened 2 years ago

yungfu commented 2 years ago

Target SharePoint environment

SharePoint Online

What SharePoint development model, framework, SDK or API is this about?

πŸ’₯ SharePoint Framework

Developer environment

No response

What browser(s) / client(s) have you tested

Additional environment details

No response

Describe the bug / error

Create a lookup field by pnpjs sp.web.lists.getById().addLookup, the lookup field is added successfully, and it can be edit in classic experience field setting page. But when you try to edit field from modern list view header Column Setting -> Edit command item, the *Select a list as source in opened right pane is always the first one, not the correct value. If you try to add a lookup field with schema xml, when the LookupList attribute is lowercase, this issue disappeared, but if the property is uppercase, this issue can be reproduced. I think this is caused by the uppercase LookupList property.

Steps to reproduce

  1. Create a lookup field by schema with uppercase LookupList property
  2. Edit created field in classic experience field edit page, the source list is correct
  3. Edit created field in modern list view page right pane, by click Field Setting -> Edit command in list view header, the source list property is incorrect
  4. Create a lookup field by schema xml with lowercase LookupList property, this issue disappeared.

Expected behavior

Created lookup field can display the correct source list in modern list view page column edit pane no matter the LookupList property is lowercase or uppercase.

ghost commented 2 years ago

Thank you for reporting this issue. We will be triaging your incoming issue as soon as possible.