Class: PufferPages::OriginsBase
- Inherits:
-
Puffer::Base
- Object
- Puffer::Base
- PufferPages::OriginsBase
- Defined in:
- lib/puffer_pages/backends/controllers/origins_base.rb
Direct Known Subclasses
Instance Method Summary collapse
Instance Method Details
#export ⇒ Object
18 19 20 21 22 23 24 |
# File 'lib/puffer_pages/backends/controllers/origins_base.rb', line 18 def export if params[:token] == PufferPages.access_token render json: resource.model.export_json else render nothing: true, status: 401 end end |
#import ⇒ Object
12 13 14 15 16 |
# File 'lib/puffer_pages/backends/controllers/origins_base.rb', line 12 def import @record = resource.member @record.import! redirect_to admin_origins_path end |