# frozen_string_literal: true module Jobshop class Customer::Category < ApplicationRecord belongs_to :organization, -> { readonly }, inverse_of: :customer_categories has_many :customers, inverse_of: :category validates :name, uniqueness: { case_insensitive: true, scope: :organization_id } end end