I have tediously configured a query widget for one app, and I'd like to port it over to another. I've tried copying the widget config and widget to the new app to no avail. Is there a procedure for this?
Regards,
Solved! Go to Solution.
Leo,
Add the query widget to the new app like you are starting from scratch. In the widget setting dialog make some change (no matter what as long as you get the save option enabled in the main WAB app). Save the app and then replace the json file in the apps configs/query/config_Query.json with the one you configured in your previous app.
Leo,
Add the query widget to the new app like you are starting from scratch. In the widget setting dialog make some change (no matter what as long as you get the save option enabled in the main WAB app). Save the app and then replace the json file in the apps configs/query/config_Query.json with the one you configured in your previous app.
Thanks Robert, this will save me a lot of time.
Could somebody be so kind as to walk me through the steps for this please? I got lost at "then replace the json file in the apps configs/query/config_Query.json with the one you configured in your previous app." Thanks in advance! Robert Scheitlin, GISP
M Torres,
Hmm.. Not sure what else to add. In your new app app (i.e. [install dir]\server\apps\[app#]) you overwrite the configs/query/config_Query.json (or it could be something like config__#.json) with the similar file in the old app.
Thank you for helping Robert Scheitlin, GISP. I'm using the web app builder and not sure where I would find that directory.
I am not sure if I can make it any simpler
[install dir]\server\apps\[app#]\configs\query\config__#.json
For example:
C:\WebAppBuilderForArcGIS\server\apps\2\configs\query\config__5.json
Hi Robert,
I'm attempting to do a similar workflow to Leo - I have configured a long list of queries for one query widget, and I want to reuse the same queries in a second app... but the second app references a new Server service (the new service contains the exact same fields as the original one).
Following your workflow above doesn't work (as expected) because the .json file reference a different service name. I've tried updating the .json file with the new service name but the app doesn't update the query widget - any ideas?
Carmel
Carmel,
Are you updating the json file in the apps folder or are you changing the one in the stemapp folder? You need to update the json that is specific to the app you are working on.
Hi Rob,
Thanks for getting back to me!
I was editing the the json for new app in the apps folder.
I managed to get it working by adding a little extra to your workflow:
Now when I open the query widget in the new app, all the queries appear
Carmel