Associations adaptation to KirbyBase

CHANGES FORM ActiveRecord: All blocks passed to :finder_sql and :counter_sql might be called with multiple parameters:

  has_one and belongs_to: remote record
  has_many: remote record and this record
  has_and_belongs_to_many: join-table record and this record

Additionally HasAndBelongsToManyAssociation :delete_sql will be called with three parameters: join record, this record and remote record Make sure that all blocks passed adhere to this convention. See ar_base_tests_runner & ar_model_adaptation for examples.

Classes and Modules
Module ActiveRecord::Associations::ClassMethods
Class ActiveRecord::Associations::BelongsToAssociation
Class ActiveRecord::Associations::HasAndBelongsToManyAssociation
Class ActiveRecord::Associations::HasManyAssociation
Class ActiveRecord::Associations::HasOneAssociation