Class: LesliSupport::CatalogWorkspacesController
- Inherits:
-
ApplicationController
- Object
- Lesli::ApplicationLesliController
- ApplicationController
- LesliSupport::CatalogWorkspacesController
- Defined in:
- app/controllers/lesli_support/catalog_workspaces_controller.rb
Instance Method Summary collapse
-
#create ⇒ Object
POST /catalog_workspaces.
-
#destroy ⇒ Object
DELETE /catalog_workspaces/1.
-
#edit ⇒ Object
GET /catalog_workspaces/1/edit.
-
#index ⇒ Object
GET /catalog_workspaces.
-
#new ⇒ Object
GET /catalog_workspaces/new.
-
#show ⇒ Object
GET /catalog_workspaces/1.
-
#update ⇒ Object
PATCH/PUT /catalog_workspaces/1.
Instance Method Details
#create ⇒ Object
POST /catalog_workspaces
24 25 26 27 28 29 30 31 32 |
# File 'app/controllers/lesli_support/catalog_workspaces_controller.rb', line 24 def create @catalog_workspace = CatalogWorkspace.new(catalog_workspace_params) if @catalog_workspace.save redirect_to @catalog_workspace, notice: "Catalog workspace was successfully created." else render :new, status: :unprocessable_entity end end |
#destroy ⇒ Object
DELETE /catalog_workspaces/1
44 45 46 47 |
# File 'app/controllers/lesli_support/catalog_workspaces_controller.rb', line 44 def destroy @catalog_workspace.destroy redirect_to catalog_workspaces_url, notice: "Catalog workspace was successfully destroyed.", status: :see_other end |
#edit ⇒ Object
GET /catalog_workspaces/1/edit
20 21 |
# File 'app/controllers/lesli_support/catalog_workspaces_controller.rb', line 20 def edit end |
#index ⇒ Object
GET /catalog_workspaces
6 7 8 |
# File 'app/controllers/lesli_support/catalog_workspaces_controller.rb', line 6 def index @catalog_workspaces = CatalogWorkspace.all end |
#new ⇒ Object
GET /catalog_workspaces/new
15 16 17 |
# File 'app/controllers/lesli_support/catalog_workspaces_controller.rb', line 15 def new @catalog_workspace = CatalogWorkspace.new end |
#show ⇒ Object
GET /catalog_workspaces/1
11 12 |
# File 'app/controllers/lesli_support/catalog_workspaces_controller.rb', line 11 def show end |
#update ⇒ Object
PATCH/PUT /catalog_workspaces/1
35 36 37 38 39 40 41 |
# File 'app/controllers/lesli_support/catalog_workspaces_controller.rb', line 35 def update if @catalog_workspace.update(catalog_workspace_params) redirect_to @catalog_workspace, notice: "Catalog workspace was successfully updated.", status: :see_other else render :edit, status: :unprocessable_entity end end |