You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2021/09/27 12:39:22 UTC

[GitHub] [superset] michael-s-molina edited a comment on pull request #16851: fix(dashboard): Fill form with the latest values when undo in native filters

michael-s-molina edited a comment on pull request #16851:
URL: https://github.com/apache/superset/pull/16851#issuecomment-927832001


   > @michael-s-molina as stated above, I confirm that the form is wiped out as soon as the form rerenders after the remove action. Any data you already have about the filter (such as the one in the `filterConfigMap` ) might be outdated as it does not contain the most recent state of the form. Thus, the only solution that seems to solve both scenarios is to store the current state of the form. I am happy to consider a different solution but it does not appear to be obvious at the moment. Let me know if anything different comes to your mind. Thank you!
   
   I was reviewing and found this:
   
   <img width="699" alt="Screen Shot 2021-09-27 at 9 34 12 AM" src="https://user-images.githubusercontent.com/70410625/134909339-540c806c-d633-4faa-9cde-9fbacbae6f2b.png">
   
   This is the code that is clearing the form. `preserve={false}` is forcing the values to be cleared. The default value of Ant Design is `true`. If we change it to `true`, the values are preserved after restoring. The only thing is that I don’t know why this was set to `false`.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org