Sha256: 75bdb406470b8686545450abe68fcd7a9ad5d34083b15d3490fd47464ec7d514

Contents?: true

Size: 503 Bytes

Versions: 18

Compression:

Stored size: 503 Bytes

Contents

class Kaui::AuditLog

  def self.description(log)
    if log.changed_by.present?
      changed_str = "#{log.change_type} by #{log.changed_by.strip}"
      if log.reason_code.blank? && log.comments.blank?
        changed_str
      elsif log.reason_code.blank?
        "#{changed_str}: #{log.comments.strip}"
      elsif log.comments.blank?
        "#{changed_str}: #{log.reason_code.strip}"
      else
        "#{changed_str} (#{log.reason_code.strip} #{log.comments.strip})"
      end
    end
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
kaui-2.1.0 app/models/kaui/audit_log.rb
kaui-2.0.4 app/models/kaui/audit_log.rb
kaui-2.0.3 app/models/kaui/audit_log.rb
kaui-2.0.2 app/models/kaui/audit_log.rb
kaui-2.0.1 app/models/kaui/audit_log.rb
kaui-2.0.0 app/models/kaui/audit_log.rb
kaui-1.4.1 app/models/kaui/audit_log.rb
kaui-1.4.0 app/models/kaui/audit_log.rb
kaui-1.3.0 app/models/kaui/audit_log.rb
kaui-1.2.0 app/models/kaui/audit_log.rb
kaui-1.1.0 app/models/kaui/audit_log.rb
kaui-1.0.0 app/models/kaui/audit_log.rb
kaui-0.16.2 app/models/kaui/audit_log.rb
kaui-0.16.1 app/models/kaui/audit_log.rb
kaui-0.16.0 app/models/kaui/audit_log.rb
kaui-0.15.5 app/models/kaui/audit_log.rb
kaui-0.15.4 app/models/kaui/audit_log.rb
kaui-0.15.3 app/models/kaui/audit_log.rb