0.6.2
This is an intermediate release before the breaking 0.7.0
.
Changelog
General
- add
:nodoc:
to all internal constants and generated methods (implementing standard ORM methods) from the macros
QueryBuilder
Query
isn't extended byIfrit
- add
OrderItem
to describe order direction - add
Criteria#order
,Criteria#asc
andCriteria#desc
to createOrderItem
- add
Condition#eql?
to compare with other condition orSQLNode
(returnsfalse
) - add
Criteria#eql?
,Grouping#eql?
,LogicOperator#eql?
- add
Query#order
andQuery#reorder
with acceptingOrderItem
- now
Query#order
with block to expect aOrderItem
- remove
CriteriaContainer
QueryObject
now is an abstract class- changed wording for the
ArgumentError
in#max
,#min
,#sum
,#avg
methods ofAggregation
to "Cannot be used with grouping" - change
Query#from(_from : String | Query)
signature toQuery#from(from : String | Query)
Model
#save
and#update
will returntrue
when is called on an object with no changed fields (all before callbacks are invoked)- next
Base
methods become abstract:.primary_auto_incrementable?
,.build_params
,#destroy
,#arguments_to_save
,#arguments_to_insert
Base#_extract_attributes
andBase#_sti_extract_attributes
become private- all callback invocation methods become protected
- next
Resource
methods become abstract:.primary
,.field_count
,.field_names
,.columns_tuple
,#to_h
,#to_str_h
Resource
isn't extended byIfrit
- regenerate
.build_params
for STI models Scoping.scope(Symbol,QueryObject)
now checks in runtime whetherT
ofJennifer::QueryBuilder::ModelQuery(T)
responds to method named after the scope
View
Base#_after_initialize_callback
becomes protectedBase#_extract_attributes
becomes private
Adapter
- fix custom port not used when accessing the Postgres database
Migration
TableBuilder::Base
isn't extended byIfrit
- rename
TableBuilder::ChangeTable#new_table_rename
getter to#new_table_name
- fix misuse of local variable in
TableBuilder::ChangeTable#rename_table
TableBuilder::ChangeTable#change_column
has next changes:old_name
argument renamed toname
new_name
argument is replaced with option inoptions
arguemnt hash- raise
ArgumentError
if bothtype
andoptions[:sql_type]
arenil
TableBuilder::ChangeTable#change_column
raisesArgumentError
if bothtype
andoptions[:sql_type]
arenil
TableBuilder::CreateTable#field
data_type
argument renamed totype
TableBuilder::CreateTable#timestamps
creates fields withnull: false
by defaultTableBuilder::CreateTable#add_index
is removed in favour of#index
.pending_versions
,.assert_outdated_pending_migrations
and.default_adapter
methods ofRunner
become privateRunner.config
is removed