Class: Specify::Model::ViewSetObject

Inherits:
Object
  • Object
show all
Includes:
Createable, Updateable
Defined in:
lib/specify/models/view_set_object.rb

Overview

ViewSetObjects represent Specify user forms (views). The actual views are .views.xml files that are stored as blobs in the database.

Instance Method Summary collapse

Methods included from Updateable

#before_update

Methods included from Createable

#before_create

Instance Method Details

#import(file) ⇒ Object

Persists file (a .views.xml file) as a blob in the database.



25
26
27
28
29
# File 'lib/specify/models/view_set_object.rb', line 25

def import(file)
  app_resource_data.import file
  app_resource_dir.save
  save
end