You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@eglitise I looked into it yesterday but not used to React and antd.
So finding duplicate name and throw Error in async saveSession is pretty easy, but Modal is still closed. Any suggestions on how to report this error, inside form, live disabling OK button, or onOK click but with error dialog and not closing the Modal, ... ?
@ath0mas thank you for trying to help out 🙏
I would go for the approach that shows an error message inside the modal, by modifying the onOk handler (onSaveAsOk in CapabilityEditor). My suggestion would be to grab the savedSessions value from props, compare the saved names against saveAsText, and then save the result boolean in some local variable. Finally add an antd Alert whose visibility then depends on this boolean (you can check how this is used in e.g. the Session component file with isAttaching).
Although, this would only cover the new saved session case, but not the renaming of an existing session... not sure about that one yet.
Current Behavior
Currently when saving caps set with same name no message is shown
Suggested Solution
I believe we should avoid having the same capability set names
Additional Information
No response
The text was updated successfully, but these errors were encountered: