Save deleted_by user when deleting products

This commit is contained in:
David Cook
2024-05-02 12:05:40 +10:00
parent 20b1a40fca
commit a38f22fbee
6 changed files with 20 additions and 2 deletions

View File

@@ -81,6 +81,7 @@ describe Api::V0::ProductsController, type: :controller do
expect(response.status).to eq(204)
expect { product.reload }.not_to raise_error
expect(product.deleted_at).not_to be_nil
expect(product.deleted_by).to eq current_api_user
end
it "is denied access to deleting another enterprises' product" do