5.1 MVC: Link to widget not opening window

This forum allows users to post and respond to "How Do I Do ....." questions. The information contained in this forum has not been validated by K-Rise Systems and, as such, K-Rise Systems cannot guarantee the accuracy of the information.
Post Reply
shalomsims
Posts: 38
Joined: March 16th, 2022, 1:04 pm
Contact:

5.1 MVC: Link to widget not opening window

Unread post by shalomsims »

So I have a hyperlink control on my webpage with an event to open another widget in a window.

My assignment is to copy from 5.1 classic over to 5.1 MVC and I just copied the exact controls over.

Originally we were using a hyperlink control on a list view. I thought that might be the issue when clicking on the link would not open the widget window. However, when I make any event controller that opens the DuplicateListWidget while passing in parameters from the list the window doesn't open. If I don't pass any parameters the widget window opens just fine.

There is also no change in the parameters in the url when the link is selected.

I believe that using a button to open widget is probably the preferred option, however, I think I am either doing something wrong with my parameters or there is another issue here. Neither the button or the hyperlink control open the widget when I pass parameters. There are no errors. It just does nothing at all when clicked. I tested this also outside of the list view and got the same result. I also created a second Widget and got the same results again while trying to pass those parameters.
I created a test button with the same call to the DuplicateListWidget. I get the same result.
I created a test button with the same call to the DuplicateListWidget. I get the same result.
Two parameters being passed to the widget. Window opens as long as I don't pass anything.
Two parameters being passed to the widget. Window opens as long as I don't pass anything.
Last edited by shalomsims on September 21st, 2022, 3:50 pm, edited 1 time in total. word count: 246

Tags:
shalomsims
Posts: 38
Joined: March 16th, 2022, 1:04 pm
Contact:

Re: 5.1 MVC: Link to widget not opening window

Unread post by shalomsims »

Found a fix for it thanks to Molly. She had a similar issue needing to pass ViewParameters dynamically.

In my case, I wrongfully assumed that since the link in the list was already in the row that the value was already dynamically referring to each corresponding row.

However, when I changed the event parameter to come from the model on the same value that was needed to be passed to the controller, it made the parameter pass dynamically and the page loads with the correct data.

Not sure if this is a bug or not. If I was a customer and I wanted to pass inputs to the widget I would assume that if I linked the parameter values through the field input that would pass the values correctly from the list view.

Image
Instead of using the field input I needed to use dynamic input from the model.
Instead of using the field input I needed to use dynamic input from the model.
Attachments
Should we pass in the values from the model when the values in the list are pulled from the model?
Should we pass in the values from the model when the values in the list are pulled from the model?
word count: 148
Post Reply