Esri / solution.js

TypeScript wrappers running in Node.js and modern browsers for transferring ArcGIS Online items from one organization to another.
https://esri.github.io/solution.js/
Apache License 2.0
38 stars 12 forks source link

Hub Site Application loses its title when put into a Solution #687

Open MikeTschudi opened 3 years ago

MikeTschudi commented 3 years ago

HSA 809404b50ccb423b8557f3d9c7cadcbc has the title "Emergency Response", but when it is put into a Solution, its item.title and data.title properties have the value "{{solution.title}}".

The title returns when the Solution is deployed.

This problem exists as far back as v0.16.9 with this item.

chris-fox commented 3 years ago

I believe this intended behavior as the Hub app supports renaming the solution when activated. So they want to use the variable so that the site gets the new name when activated. In most of our solutions we just go in and change it from this variable to the name we want to pass when deployed.

shoe913 commented 1 year ago

@chris-fox @MikeTschudi

Is this worth revisiting with the new hub.js updates we're putting in?

We manually hardcode the name after creating the solution item. This adds an extra step which could be done incorrectly. It may be worth our time to add this in.

chris-fox commented 1 year ago

Yes, we should discuss with the Hub team.

@dbouwman, what do you think? We always have to go in an remove the {{solution.title}} variable and replace with the hardcoded name for the site. Anyway we could support our different use cases between solutions and Hub?

MikeTschudi commented 1 year ago

If Hub uses convertSiteToTemplate from @esri/hub-sites to templatize a Hub site rather than convertItemToTemplate from @esri/solution-hub-types, then we can solve this with some post-processing in the latter.