As a Table Action I want to remove a row from my table right away, however if that row has ever been saved to the database, I also want to (on eventual save) delete that row from the database. If it hasn’t ever been saved to the database, then I don’t care I just want to remove the row.
If initiating a Row Action, Is there a way that I can check if a row has unsaved changes, or has ever been saved to the database? Some way in Javascript perhaps? I’ve been searching through the Arguments object when running a snippet from a row action and I can’t seem to find anything indicating if the row has ever been saved to the database or has unsaved changes or anything like that.
I could perhaps check if the row has an Id like “sk-%” which would indicate that this is a row with a temporary SKUID ID and hasn’t been saved yet, but I’m not sure if this is the best strategy. This also doesn’t help me if I want to check if a row that has previously been saved has unsaved changes. Any other thoughts?
Thanks!
Question
Table Action with Row Context -- check if row has unsaved changes / was ever saved to the database?

This topic has been closed for comments
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.