Skip to content
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

Compatibility with store_multiplied #18

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

k41n
Copy link

@k41n k41n commented Jul 3, 2012

In case when field=() and field() methods are being redefined in versioned model, versioning does take it into consideration when reading and does not when writing into revision model. As result when working together with store_multiplied, acts_as_versioned reads integer value stored as micros in database as 900000 returned as 0.9 and stores it into integer field casting it to int as 0. When reverting we get 0 divided by million which equals 0. Better copy raw attributes IMHO.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant