This repository has been archived on 2021-11-24. You can view files and clone it, but cannot push or open issues or pull requests.
phone_app/app/models/s_brand.rb

6 lines
167 B
Ruby

class SBrand < ApplicationRecord
has_many :p_products
has_many :p_product_refs, through: :p_products
validates :name, :presence => true, :uniqueness => true
end