Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PropertyFieldViewPicker - Unable to load Views from another site #263

Closed
1 of 3 tasks
frankok opened this issue Jun 8, 2020 · 5 comments
Closed
1 of 3 tasks

PropertyFieldViewPicker - Unable to load Views from another site #263

frankok opened this issue Jun 8, 2020 · 5 comments
Labels
status:fixed-next-drop Issue will be fixed in upcoming release. type:bug
Milestone

Comments

@frankok
Copy link

frankok commented Jun 8, 2020

Category

  • Enhancement
  • Bug
  • Question

Version

Please specify what version of the library you are using: [ 1.18.0 ]

Expected / Desired Behavior / Question

I have a web part with Site Url, PropertyFieldListPicker and PropertyFieldViewPicker. When a Site Url is set, the List Picker displays the lists from that site (using the webAbsoluteUrl property).
Expected this also to be the case with the View Picker.

Observed Behavior

Even if webAbsoluteUrl is set (to another site other than the current site), it does not load the views for the selected list in the List Picker.

image

Error message from console:

  (anonymous) @ PropertyFieldViewPickerHost.js:62
  Promise.then (async)    
  sch4.PropertyFieldViewPickerHost.loadViews @ PropertyFieldViewPickerHost.js:60
  sch4.PropertyFieldViewPickerHost.componentDidMount @ PropertyFieldViewPickerHost.js:45
  Na @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Ma @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  (anonymous) @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  t.unstable_runWithPriority @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  To @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  xo @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  bo @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  mo @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Wa @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Co @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Po @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Do.render @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  (anonymous) @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Eo @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Uo @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  render @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  (anonymous) @ sp-property-pane_en-…7257c0677c6da0.js:1
  Promise.then (async)    
  e._loadPropertyPaneComponent @ sp-property-pane_en-…7257c0677c6da0.js:1
  e._buildAndLoadPropertyPane @ sp-property-pane_en-…7257c0677c6da0.js:1
  (anonymous) @ sp-property-pane_en-…7257c0677c6da0.js:1
  Promise.then (async)    
  e._renderPropertyPane @ sp-property-pane_en-…7257c0677c6da0.js:1
  e._executeAction @ sp-property-pane_en-…7257c0677c6da0.js:1
  e.requestAction @ sp-property-pane_en-…7257c0677c6da0.js:1
  e.requestPropertyPaneAction @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  n.handleConfigureButtonClicked @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  handleConfigureButtonClicked @ chunk.sp-canvas-edit…01ad640fa1e1b2.js:1
  onClick @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  u @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  m @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  (anonymous) @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  S @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  O @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  P @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  D @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  En @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  _o @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Le @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  On @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  (anonymous) @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  t.unstable_runWithPriority @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  So @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1
  Nn @ sp-webpart-workbench…d8c6b3cd80d4e2.js:1

Steps to Reproduce

Add the following controls to a web part:
Site Url - Text Field
List - PropertyFieldListPicker
View - PropertyFieldViewPicker

When Site Url is set to another site than the current site, views fail to load based on the selected List.

Submission Guidelines

@ghost
Copy link

ghost commented Jun 8, 2020

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

@ghost ghost added the Needs: Triage 🔍 label Jun 8, 2020
@frankok frankok changed the title PropertyFieldViewPicker PropertyFieldViewPicker - Unable to load Views from another site Jun 8, 2020
@frankok
Copy link
Author

frankok commented Jul 14, 2020

Hi, no feedback on this issue yet.
@hugoabernier, do you have any feedback on this?

@frankok
Copy link
Author

frankok commented Jul 27, 2020

Hi again,
I downloaded the source code, and added the ViewPicker to my project.
After debugging, I tested with adding the following:

webAbsoluteUrl: properties.webAbsoluteUrl,

I added it (on line 135) in the export function PropertyFieldViewPicker in PropertyFieldviewPicker.ts.
This seems to do the trick.

@hugoabernier
Copy link
Contributor

@frankok thanks for reporting this. Sorry, with the massive numbers of emails I get from GitHub, this one slipped through the cracks.

Working on a PR to include your fix. Thank you!

@AJIXuMuK
Copy link
Collaborator

Hi @frankok!
Thank you for reporting this one!
@hugoabernier made the fix and it'll be included in the next release.
In a meanwhile you can test it in beta version.

@AJIXuMuK AJIXuMuK added this to the 1.20.0 milestone Jul 29, 2020
@AJIXuMuK AJIXuMuK added the status:fixed-next-drop Issue will be fixed in upcoming release. label Jul 29, 2020
@estruyf estruyf closed this as completed in 3be2303 Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:fixed-next-drop Issue will be fixed in upcoming release. type:bug
Projects
None yet
Development

No branches or pull requests

3 participants