Class: Dhatu::PromotionEnquiry

Inherits:
ApplicationRecord show all
Includes:
Featureable, Readable
Defined in:
app/models/dhatu/promotion_enquiry.rb

Instance Method Summary collapse

Instance Method Details

#can_be_deleted?Boolean

Returns:

  • (Boolean)


52
53
54
# File 'app/models/dhatu/promotion_enquiry.rb', line 52

def can_be_deleted?
  status?(:removed)
end

#can_be_edited?Boolean

Permission Methods


Returns:

  • (Boolean)


48
49
50
# File 'app/models/dhatu/promotion_enquiry.rb', line 48

def can_be_edited?
  false
end

#display_nameObject



41
42
43
# File 'app/models/dhatu/promotion_enquiry.rb', line 41

def display_name
  "#{name_was}"
end

#to_paramObject

Generic Methods




37
38
39
# File 'app/models/dhatu/promotion_enquiry.rb', line 37

def to_param
  "#{id}-#{name.parameterize[0..32]}"
end