Esri / data-assistant

ArcGIS Pro Add-in that assists in emergency management, local government and state government data aggregation workflows.
Apache License 2.0
22 stars 8 forks source link

Warn user on not applying changes #210

Open pLeBlanc93 opened 7 years ago

pLeBlanc93 commented 7 years ago

We've seen on multiple occasions that users forget to apply after making field mapping changes. Can we warn on the following:

@MikeMillerGIS @previnWong @JRosenfeldIntern

JRosenfeldIntern commented 7 years ago

Not a terrible idea, though it might be a bit of an involved thing code-wise (just because you'd have to make that check in so many separate places).

How would you warn the user? One idea I was thinking of is maybe while you have changed some information in that respective method (or a new method) the apply button color can change like so. (I'd probably go for a darker yellow but this is just a concept). image

chris-fox commented 7 years ago

I always wondered why we even have an apply, it is annoying to me that I have to click it for every field I change the method for. Why not just remove it and have every change persisted?

JRosenfeldIntern commented 7 years ago

Good question @chris-fox. I could try implementing that just to see how it would act. Theoretically all of the functions are already written, it's just changing the associated business logic functions to the corresponding UI elements.

MikeMillerGIS commented 7 years ago

A global apply would make more sense. After you change X number of fields. I am fine with an auto save too as there is a revert on the previous page

JRosenfeldIntern commented 7 years ago

If it makes any difference from a implementation point of view, automatically saving will be much easier with the current code compared to a global apply button

@MikeMillerGIS. From a design point of view, what's the incentive to have the apply button over auto save?

ChrisBuscaglia commented 7 years ago

By saying "every change" are we saying that it will auto-change only for method changes, or would it update for any change? For example - concatenate and substring have a few things going on, and would keep flashing with updates when you haven't even got to set what you intended to.

MikeMillerGIS commented 7 years ago

The auto Dave has one down side. I just did a complex value map, I accidentally change the drop down, how do I go back

MikeMillerGIS commented 7 years ago

Is there an way to expose as a setting, to enable auto save, which hides the button or changes the button text to preview

Sent from my Verizon Wireless 4G LTE DROID

chris-fox commented 7 years ago

@ChrisBuscaglia, I am saying every change. I am not sure why it would be flashing with each change, it is not doing much so there shouldn't be a UI lag.

@MikeMillerGIS, IMO simplifying the UI and not exposing another setting outweighs the I might accidentally lose some changes if I make a mistake.

pLeBlanc93 commented 7 years ago

It can be quite a lot of changes actually. Mapping a few dozen domains by subtypes is not something I'd want to repeat if I misclick.

Can we auto save and use git to version it? :cheeky:

JRosenfeldIntern commented 7 years ago

autosave

Here's sort of what I was thinking the auto save would look like. The preview reflects the XML.

ChrisBuscaglia commented 7 years ago

It's my understanding that the apply isn't actually committing the changes to the XML, it's automatically doing that now (apply only updates the preview?)...but that could have changed over the 15 or so iterations of the apply in the past. The button used to be called "Preview"

MikeMillerGIS commented 7 years ago

That looks pretty nice @JRosenfeldIntern I also thoguht the preview needed a column to show the original value, so you can actually see what was and what will be.

JRosenfeldIntern commented 7 years ago

@MikeMillerGIS I've always used it where it only shows you what it will be. I didn't actually change any preview code here, this is basically "clicking" the apply button on any of the textbox changes.

ChrisBuscaglia commented 7 years ago

autosave @pLeBlanc93 @JRosenfeldIntern Just confirmed that changing a field mapping automatically saves the field mappings without hitting apply as I noted, maybe this was just missed with domain map? This is actually a "auto-preview" enhancement?

JRosenfeldIntern commented 7 years ago

@ChrisBuscaglia I think that's just inconsistent coding. The field will automatically save, but in the current form of Data Assistant that's it. The method and actual mappings for any field require the Apply button. For instance, if you swapped that "Copy" for "None" it wouldn't automatically be reflected in the XML. Can't confirm for sure at the moment since I'm halfway into configuring auto apply, but I'm pretty sure that is the behavior in the current release version.

ChrisBuscaglia commented 7 years ago

@JRosenfeldIntern switching back to none is automatically saved, but seeing some inconsistencies.

I was wondering how someone would have run into the bug that Paul initially added for this issue - changing fields...just making sure we're not missing a bug that we should fix for the current version.

JRosenfeldIntern commented 7 years ago

@ChrisBuscaglia I have a pull request out that should fix these inconsistencies. I removed the apply button, so any changes made in the mapper are automatically written. That way all behavior is consistent.