<commit_before>module Glysellin
  class Address < ActiveRecord::Base
    self.table_name = 'glysellin_addresses'
    has_many :orders
    # Additional fields can be added through Glysellin.config.additional_address_fields in the custom initializer
    store :additional_fields, :accessors => Glysellin.additional_address_fields
  end
end<commit_msg>functionnal order <-> address relation for rails admin<commit_after>module Glysellin
  class Address < ActiveRecord::Base
    self.table_name = 'glysellin_addresses'
    
    has_many :billed_orders, :class_name => 'Glysellin::Order', :foreign_key => 'billing_address_id'
    has_many :shipped_orders, :class_name => 'Glysellin::Order', :foreign_key => 'shipping_address_id'
    
    # Additional fields can be added through Glysellin.config.additional_address_fields in the custom initializer
    store :additional_fields, :accessors => Glysellin.additional_address_fields
  end
end
{'fraction_non_alphanumeric': 0.07725321888412018, 'fraction_numerical': 0.0, 'mean_word_length': 5.524475524475524, 'pattern_counts': {'":': 0, '<': 6, '<?xml version=': 0, '>': 10, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5085211', 'n_tokens_mistral': 296, 'n_tokens_neox': 270, 'n_words': 67}