Sha256: 52ba85e741cf22cc3f133a7bbe5a4d3554b986bb5eee33fdeafa8f272590efe5
Contents?: true
Size: 457 Bytes
Versions: 8
Compression:
Stored size: 457 Bytes
Contents
# frozen_string_literal: true module Spree module NamedType extend ActiveSupport::Concern included do Spree.deprecator.warn "Spree::NamedType is deprecated. Please set scopes and validations locally instead.", caller scope :active, -> { where(active: true) } default_scope -> { order(arel_table[:name].lower) } validates :name, presence: true, uniqueness: { case_sensitive: false, allow_blank: true } end end end
Version data entries
8 entries across 8 versions & 1 rubygems