gitlab-org--gitlab-foss/app/models/list_user_preference.rb
Felipe Artur 8f6a433c41 Save board lists collapsed setting
Persists if a board list is collapsed for each user.
2019-08-28 20:18:40 +00:00

10 lines
299 B
Ruby

# frozen_string_literal: true
class ListUserPreference < ApplicationRecord
belongs_to :user
belongs_to :list
validates :user, presence: true
validates :list, presence: true
validates :user_id, uniqueness: { scope: :list_id, message: "should have only one list preference per user" }
end