grantcallendar/app/models/setting.rb

31 lines
926 B
Ruby

# frozen_string_literal: true
# Settings
class Setting < ApplicationRecord
# == Constants ============================================================
# == Attributes ===========================================================
# == Extensions ===========================================================
# == Relationships ========================================================
# == Validations ==========================================================
# == Scopes ===============================================================
# == Callbacks ============================================================
# == Class Methods ========================================================
# == Instance Methods =====================================================
def updated
user = User.where('id = ?', updated_by).first
if user.blank?
'Brak'
else
user.email
end
end
end