I have a query grid which has popup to select different date ranges. Once selected I put those date ranges in LoggedInSystemUser. Now the problem is although grid refreshes the header of the grid and below script does not show new data unless whole page is refreshed which takes user to home screen.
How do I refresh grid header or something on top of query once pop up selects date range?
previously I used VP trick to have 2 panels one with date range and then query in second panel below but that is just workaround for refresh issue. This time I have multiple queries with date selection.
below does not work even if db has new data for dates.
widget.bind("dataBound", function(e) {
$('#daterange').text('<<LoggedInSystemUser.ReportStartDate>> -- <<LoggedInSystemUser.ReportEndDate>>');
console.log('ami');
});
how to refresh current screen after popup dates
-
- Posts: 370
- Joined: Sat Apr 28, 2018 3:33 am
- Location: India
- Contact:
Re: how to refresh current screen after popup dates
Try using a process to refresh it (auto refresh option).swiftinitpvtltd wrote:I have a query grid which has popup to select different date ranges. Once selected I put those date ranges in LoggedInSystemUser. Now the problem is although grid refreshes the header of the grid and below script does not show new data unless whole page is refreshed which takes user to home screen.
How do I refresh grid header or something on top of query once pop up selects date range?
previously I used VP trick to have 2 panels one with date range and then query in second panel below but that is just workaround for refresh issue. This time I have multiple queries with date selection.
below does not work even if db has new data for dates.
widget.bind("dataBound", function(e) {
$('#daterange').text('<<LoggedInSystemUser.ReportStartDate>> -- <<LoggedInSystemUser.ReportEndDate>>');
console.log('ami');
});
Henrik (V8 Developer Ed. - Windows)
-
- Posts: 370
- Joined: Sat Apr 28, 2018 3:33 am
- Location: India
- Contact:
Re: how to refresh current screen after popup dates
Thanks! I have it but it only refreshes grid items and not the grid header or loggedinSystemuser.
Previously I used VP trick to have 2 panels but here I need data in header or something above grid query to get updated with new selected dates selected in popup form(datesBO form)
So basically user sees reportitems query, then he selects "select date range type" button on query header ops and popup opens with different types of date options, once he selects popup closes but now now those new date range values need to some how come on top of query for user to see what he selected in pop up that is the pain point not working. I can use workaround of VP but as I have many queries like this I do not want to do workaround...
Previously I used VP trick to have 2 panels but here I need data in header or something above grid query to get updated with new selected dates selected in popup form(datesBO form)
So basically user sees reportitems query, then he selects "select date range type" button on query header ops and popup opens with different types of date options, once he selects popup closes but now now those new date range values need to some how come on top of query for user to see what he selected in pop up that is the pain point not working. I can use workaround of VP but as I have many queries like this I do not want to do workaround...
Re: how to refresh current screen after popup dates
This is the EXACT same scenario I had i.e I had a query with a header with data I needed to update with refresh (and the "normal" refresh didn´t update it). "Normal" refresh only refresh data/rows in the query but a process refresh, redisplays the entire query i.e this should work and does for me. To be clear, I have a content panel with a query and in that query I have autorefresh via process enabled and the process just does a "DISPLAY NameOfQuery" and that´s it, the entire query is redisplayed and header and data/row are refreshed. Try it again or if it doesn´t work, your scenario is maybe different from mine in terms of how you have configured your VP/content panels etc..swiftinitpvtltd wrote:Thanks! I have it but it only refreshes grid items and not the grid header or loggedinSystemuser.
Previously I used VP trick to have 2 panels but here I need data in header or something above grid query to get updated with new selected dates selected in popup form(datesBO form)
So basically user sees reportitems query, then he selects "select date range type" button on query header ops and popup opens with different types of date options, once he selects popup closes but now now those new date range values need to some how come on top of query for user to see what he selected in pop up that is the pain point not working. I can use workaround of VP but as I have many queries like this I do not want to do workaround...
Henrik (V8 Developer Ed. - Windows)
-
- Posts: 297
- Joined: Wed Apr 22, 2015 11:44 pm
Re: how to refresh current screen after popup dates
I had a similar question, but found that doing the refresh based on a process fixed it.
But, I found something else that is driving me crazy...
In my case I am incrementing, or decrementing, a beginning and ending date, and showing records that fall between those dates. I click the 'Increment' button and it adds a week to the Beginning Date and a Week to the Ending Date and then refreshes the query. I show the current Beginning and Ending Dates and they refresh just fine.
The issue is that if I put the Buttons to execute the Increment, Decrement, and Reset in the Panel Toolbar the buttons disappear after clicking on them once.
If I put them on the Top Panel Toolbar or the Right Panel Toolbar they work just fine and stay available all the time.
The problem with putting them in the Top Panel Toolbar is that is creates a separate row for them and takes up some precious screen real estate. The Right Panel Toolbar works too, I just don't like putting things there.
Has anyone run into anything like this?
Thanks,
Jim
But, I found something else that is driving me crazy...
In my case I am incrementing, or decrementing, a beginning and ending date, and showing records that fall between those dates. I click the 'Increment' button and it adds a week to the Beginning Date and a Week to the Ending Date and then refreshes the query. I show the current Beginning and Ending Dates and they refresh just fine.
The issue is that if I put the Buttons to execute the Increment, Decrement, and Reset in the Panel Toolbar the buttons disappear after clicking on them once.
If I put them on the Top Panel Toolbar or the Right Panel Toolbar they work just fine and stay available all the time.
The problem with putting them in the Top Panel Toolbar is that is creates a separate row for them and takes up some precious screen real estate. The Right Panel Toolbar works too, I just don't like putting things there.
Has anyone run into anything like this?
Thanks,
Jim
Re: how to refresh current screen after popup dates
can u post a pic of these buttons & fields?Jhstephenson wrote: The issue is that if I put the Buttons to execute the Increment, Decrement, and Reset in the Panel Toolbar the buttons disappear after clicking on them once.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: how to refresh current screen after popup dates
Sounds strange and if I understand the problem correctly, I can´t see why this would happen. Yes, some screenshots would help.Jhstephenson wrote:I had a similar question, but found that doing the refresh based on a process fixed it.
But, I found something else that is driving me crazy...
In my case I am incrementing, or decrementing, a beginning and ending date, and showing records that fall between those dates. I click the 'Increment' button and it adds a week to the Beginning Date and a Week to the Ending Date and then refreshes the query. I show the current Beginning and Ending Dates and they refresh just fine.
The issue is that if I put the Buttons to execute the Increment, Decrement, and Reset in the Panel Toolbar the buttons disappear after clicking on them once.
If I put them on the Top Panel Toolbar or the Right Panel Toolbar they work just fine and stay available all the time.
The problem with putting them in the Top Panel Toolbar is that is creates a separate row for them and takes up some precious screen real estate. The Right Panel Toolbar works too, I just don't like putting things there.
Has anyone run into anything like this?
Thanks,
Jim
Henrik (V8 Developer Ed. - Windows)
-
- Posts: 370
- Joined: Sat Apr 28, 2018 3:33 am
- Location: India
- Contact:
Re: how to refresh current screen after popup dates
Thank you! The way I fixed it is using getObjectData method from userguide in conjunction with refresh as you suggested(for me refresh only steps work if I have VP with 2 panels-in this case its just display query via process-no VP involved). getObjectData always goes back to DB and gets you latest n greatest data for requested object. So in query grid(with refresh) databound I call getObjectData ad put that data in grid header.hpl123 wrote:This is the EXACT same scenario I had i.e I had a query with a header with data I needed to update with refresh (and the "normal" refresh didn´t update it). "Normal" refresh only refresh data/rows in the query but a process refresh, redisplays the entire query i.e this should work and does for me. To be clear, I have a content panel with a query and in that query I have autorefresh via process enabled and the process just does a "DISPLAY NameOfQuery" and that´s it, the entire query is redisplayed and header and data/row are refreshed. Try it again or if it doesn´t work, your scenario is maybe different from mine in terms of how you have configured your VP/content panels etc..swiftinitpvtltd wrote:Thanks! I have it but it only refreshes grid items and not the grid header or loggedinSystemuser.
Previously I used VP trick to have 2 panels but here I need data in header or something above grid query to get updated with new selected dates selected in popup form(datesBO form)
So basically user sees reportitems query, then he selects "select date range type" button on query header ops and popup opens with different types of date options, once he selects popup closes but now now those new date range values need to some how come on top of query for user to see what he selected in pop up that is the pain point not working. I can use workaround of VP but as I have many queries like this I do not want to do workaround...
-
- Posts: 297
- Joined: Wed Apr 22, 2015 11:44 pm
Re: how to refresh current screen after popup dates
Here is what the panel looks like when it originally comes up. There are three buttons on the Panel Tool Box: Left Arrow (Go to Previous Week), Right Arrow (Go to Next Week), Curly arrow thing (Reset to Current Week):
Here is what it looks like after I click on the Right Arrow.
Here is what it looks like after I click on the Right Arrow.
Re: how to refresh current screen after popup dates
never had that problem - but any button I've put up there (other than std. Aware default buttons) has been an Add, which does something and then comes back to this screen.
even these 2 buttons dont so the same thing you do, so I have no ideas.
even these 2 buttons dont so the same thing you do, so I have no ideas.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: how to refresh current screen after popup dates
I haven´t experienced this problem either and is a strange one. I use a very similar scenario where it doesn´t happen i.e the entire header is the same after refresh. I mostly use custom headers these days (saw you other post/question to Jaymer) and is a good approach and you get a lot more control and design options. Jaymer will most likely give you some pointers on how this works (and maybe some code) but in essence it´s just plan HTML with custom buttons where you can do whatever you want really. All my headers are "baked" into my apps and based on custom admin templates i.e not something I can share/export unfortunately.Jhstephenson wrote:Here is what the panel looks like when it originally comes up. There are three buttons on the Panel Tool Box: Left Arrow (Go to Previous Week), Right Arrow (Go to Next Week), Curly arrow thing (Reset to Current Week):
Here is what it looks like after I click on the Right Arrow.
Henrik (V8 Developer Ed. - Windows)