- Fixed an issue where searching with
v: falsewas treated asnildue tofalse || nillogic
- Disabled fields name format validation
- Added scope functionality: Active Field can now be limited to a specific context, allowing different sets of fields per group within the same Customizable model.
- Added Appraisal to run tests across multiple Rails versions.
- Fixed search with
niloperator
- Drop support for Rails < 7.1
- Drop support for Ruby < 3.1 (EOL)
- Added search functionality
- Added registry to store relationships between Customizable types and Active Field types
- Added notes about the necessity of disabling reloading for custom model classes and custom Active Field type models to prevent STI (Single Table Inheritance) issues
Breaking changes:
-
Maximum datetime precision reduced to 6 for all Ruby/Rails versions.
While Ruby allows up to 9 fractional seconds, most databases, including PostgreSQL, support only 6. To ensure compatibility and prevent potential issues, we are standardizing the precision to the minimum supported across our technology stack.
-
Maximum datetime precision constant relocated.
The maximum precision value has been moved from
ActiveFields::Casters::DateTimeCaster::MAX_PRECISIONtoActiveFields::MAX_DATETIME_PRECISION. -
Maximum decimal precision set to 16383 (2**14 - 1).
While Ruby's
BigDecimalclass allows extremely high precision, PostgreSQL supports a maximum of 16383 digits after the decimal point. To ensure compatibility, we are capping the precision at this value. The maximum precision value is now accessible viaActiveFields::MAX_DECIMAL_PRECISION.
- Added scaffold generator
- Disabled models reloading to prevent STI issues
- Precision configuration for decimal fields
- Added array field types mix-in
ActiveFields::FieldArrayConcern - Fixed enum types behavior for blank values
- Dummy app
- Enhanced values storage format
- Do not implicitly create Active Values when saving an Active Field or Customizable
- Utilize ActiveRecord's nested attributes feature in Customizable models to manage associated Active Values
- Serialize decimals as strings as ActiveRecord does for JSON columns
- Added datetime and datetime array field types
- Added fields configuration DSL
- Introduced new Customizable setter for Active Values (
active_fields_attributes=) with a more convenient syntax to replace the default setter (active_values_attributes=) from Rails nested attributes feature
- Rewritten as a Rails plugin!
- Custom field types support
- Global configuration options for changing field and value classes
- Per-model configuration option for enabling specific field types only
- Initial release