Fix handling of Decimal.Attributes.fraction_digits

The wrong value was used for setting the fraction_dicits at serialization time. Also the wrong type (int) was used instead of string.