mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-01-29 21:17:17 +00:00
11 lines
340 B
Ruby
11 lines
340 B
Ruby
# frozen_string_literal: true
|
|
|
|
module Spree
|
|
class ShippingCategory < ApplicationRecord
|
|
validates :name, presence: true
|
|
has_many :products, dependent: :nullify
|
|
has_many :shipping_method_categories, inverse_of: :shipping_method, dependent: :destroy
|
|
has_many :shipping_methods, through: :shipping_method_categories
|
|
end
|
|
end
|