Module: Bizside::Warning

Extended by:
ActiveSupport::Concern
Defined in:
lib/bizside/warning.rb

Instance Method Summary collapse

Instance Method Details

#check_warningsObject



15
16
17
# File 'lib/bizside/warning.rb', line 15

def check_warnings
  raise Bizside::RecordHasWarnings.new if warnings.present?
end

#warningsObject



11
12
13
# File 'lib/bizside/warning.rb', line 11

def warnings
  @warnings ||= []
end

#warnings_confirmed?Boolean

Returns:

  • (Boolean)


19
20
21
# File 'lib/bizside/warning.rb', line 19

def warnings_confirmed?
  self.warnings_confirmed == '1' or self.warnings_confirmed == true
end