Hello,
We just updated our crime mapping application to be fed near real time and so now we are looking to have our update our Web App Builder to provide a better user experience.
We are wanting the field values in the filter widgets to be dynamic as the data changes so that it, on load shows the dates as being between the Current Date - 30 Days and the Current Date. I tried following the instructions that Jake Skinner posted in his Document https://community.esri.com/docs/DOC-8191 and it worked for the Web Map but doesn't seem to work for the Value field of the filter in the attached image of the JSON code. We are only using ArcGIS Online and are looking to avoid putting the app hosted on our IIS because the whole reason we switched to ArcGIS Online was to take traffic away from our IIS.
Does anyone know if this is possible to do?
Solved! Go to Solution.
Greg,
Well that will not be possible with the AGOL version of WAB then.
Greg,
The filter widget offers a "in the last" option...
Hi rscheitlin
While this gets closer to what I am wanting, I want the users to be able to set a date range and then the default date range shows what is currently on the filter shown on the map.
We provide crime data for up to 1 year back and so I have built in an initial filter that is only showing crimes within the last 60 Days but I want them to on load see the date range as being 9/30/2017 - 11/29/2017 rather than just an arbitrary in the last 60 days
Greg,
Well that will not be possible with the AGOL version of WAB then.
Were you ever able to get a solution to this problem? If so, what did you end of doing? This functionality would be useful to make an existing static application much more dynamic and helpful for endusers.
Greg Mattis wrote:
We provide crime data for up to 1 year back and so I have built in an initial filter that is only showing crimes within the last 60 Days but I want them to on load see the date range as being 9/30/2017 - 11/29/2017 rather than just an arbitrary in the last 60 days
Hi Greg Mattis
I assume your data are all hosted on arcgis online, right?
If your data were stored in an enterprise database and shared in ArcGIS Enterprise (Server), I could've given a solution that I works for me.
Thanks.
Tanu
Tanu:
Can you please provide details about your potential solution?
Hi Michael Volz,
Here is what you can do:
select * from EARTHQUAKES_7DAYS_LIVE where ::r:TimeRangeNB: the string after ::r: can be anything e.g. ::r:XYZ
DATEADD(DAY, -1, CURRENT_TIMESTAMP)
CURRENT_TIMESTAMP
Notes:
Hope you will find this helpful and let me know if you have any question.
Thanks.
Tanu
Thanks.
I was wondering if you ever work with Oracle databases as the parameter link you provide is helpful but I still get a Underlying DBMS error [ORA-00936: missing expression] when I follow the instructions for the Default Value range
I think this would be going back 7 days from the Current date.
Michael,
I tried the following and it worked for me.
In Oracle, when you add/subtract a number from a date/time, that number represents days.