-
-
Notifications
You must be signed in to change notification settings - Fork 338
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why there is not model id for Audit in Blameable behavior? #501
Comments
You can find information about changed data in "audit_detail" table. |
@endeveit But How do you know whether the changed data is belonged to "Product A" or "Product B"? |
You can use "field_name" field but I agree that current implementation of blameable behavior is poor and should be refactored. |
@endeveit If "Product A" have changed its "name" from "apple 1" to "apple", and "Product B" have changed its "name" from "pear 1" to "pear". Here is an example: audit table:
audit_detail table:
From these records, how do you know which row of audit_detail table is belong to "Product A"? |
@Wayne-Wen You can easily change this. Add two fields in your usr_id <- the user that did this Your table will then become
|
@niden Of course, I have added a |
When I'm looking into the code of "Blameable" behavior, I found:
Looks like it only stores the name of model. If I have two Products (Production A and Product B). And I have made changes on these two products. How can I know what are the changes of product A and what are the changes of product B. Because their model name are the same-----"Product", and there is not model id to distinguish them.
The text was updated successfully, but these errors were encountered: