shannah / xataface

Framework for building data-driven web applications in PHP and MySQL
http://xataface.com
GNU General Public License v2.0
136 stars 58 forks source link

Deleted record shown in table_quicklinks, POTENTIAL DATA LOSS #21

Open malaire opened 10 years ago

malaire commented 10 years ago

After deleting a record from table, its linked record title is still shown in table_quicklinks (in left, below "All TABLENAME" link, number "1" in attached image).

If that record title is clicked, it will go to record delete confirmation page BUT since that record is already deleted it will ask for confirmation to delete next record in that table (see image). If user mistakenly clicks Delete-button then that next record is deleted.

Tested with latest github version.

Steps to reproduce:

  1. Have a table where you can add records.
  2. Add record titled "Record which has been deleted"
  3. Add record titled "Completely unrelated record"
  4. Go to record "Record which has been deleted", delete it, confirm deletion
  5. Now you still see "Record which has been deleted" link on left, click it
  6. Now you have situation pictured in attached image. If you again confirm deletion, instead of trying to delete same record again, xataface will delete next record which is "Completely unrelated record" in this example.

delete-again

malaire commented 7 years ago

I think this is related to the other deletion-bug I found (#83) since in both cases, when pressing 'Delete' button on delete-confirmation-page, the record to be deleted is not identified by the -recordid of the URL, but by some other means.