SharePoint / sp-dev-docs

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

Unable to open a custom SharePoint form in a SharePoint tab in the new Teams desktop client #9423

Open jusper-dk opened 6 months ago

jusper-dk commented 6 months ago

Target SharePoint environment

SharePoint Online

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

πŸ’₯ SharePoint Framework

Developer environment

None

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

Additional environment details

Describe the bug / error

While opening a custom form from a list view in a SharePoint tab in the new Teams desktop client, spserviceworker cuts off authentication cookies and finally redirects to login.microsoft.com:

  1. listform.aspx redirects to the right URL (a custom form)
  2. spserviceworker (https://res-1.cdn.office.net/files/odsp-web-prod_2023-12-01.001/spserviceworker.js) doesn't pass authentication cookies (SPOIDCRL)
  3. Redirects to /_layouts/15/Authenticate.aspx
  4. Redirects to /_forms/default.aspx
  5. Redirects to https://login.microsoftonline.com/

Network logs: image

Steps to reproduce

  1. Create a custom form for a SharePoint list or just add assign any page from the same site to ContentType.DisplayFormUrl https://learn.microsoft.com/en-us/previous-versions/office/sharepoint-csom/ee540653(v=office.15)
  2. Add a SharePoint tab in the New Teams desktop client and select the SharePoint list with customized form
  3. Open a form
  4. You'll get an empty page (login.microsoftonline.com)

Expected behavior

How it works in the old Teams desktop client:

image

ghost commented 6 months ago

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

xxyziggy commented 6 months ago

The custom SharePoint form created using the tutorial is not functioning in the new Microsoft Teams desktop version.

Environment:

Microsoft Teams Desktop Version: 23320.3027.2591.1505 Client Version: 49/23113028718

Steps to Reproduce:

  1. Create a custom form using the tutorial
  2. Create a SharePoint tab in Misrosoft Teams with a list view
  3. Try to open list item form

Expected Behavior:

List form opens normally

Actual Behavior:

Blank screen appears

Logs:

Refused to display 'https://login.microsoftonline.com/' in a frame because it set 'X-Frame-Options' to 'deny'.

Screenshots:

Number of redirects happen in MS Teams tab, but /_layouts/15/SPListForm.aspx never loads image This happens because /_layouts/15/listform.aspx does not pass auth cookie image

Normal behaviour in SharePoint

image

xxyziggy commented 4 days ago

Any updates on the issue?