Class: Decidim::Templates::Template

Inherits:
ApplicationRecord show all
Defined in:
app/models/decidim/templates/template.rb

Instance Method Summary collapse

Instance Method Details

#destroy_templatableObject



28
29
30
# File 'app/models/decidim/templates/template.rb', line 28

def destroy_templatable
  templatable.destroy
end

#resource_nameObject



24
25
26
# File 'app/models/decidim/templates/template.rb', line 24

def resource_name
  [templatable_type.demodulize.tableize.singularize, "templates"].join("_")
end