Files
fizzy/app/controllers/collections/entropies_controller.rb
T
David Heinemeier Hansson 7052d6ecec Fix style
2025-11-02 13:54:46 +01:00

18 lines
477 B
Ruby

class Collections::EntropiesController < ApplicationController
include CollectionScoped
def update
@collection.entropy.update!(entropy_params)
render turbo_stream: [
turbo_stream.replace([ @collection, :entropy ], partial: "collections/edit/auto_close", locals: { collection: @collection }),
turbo_stream_flash(notice: "Saved")
]
end
private
def entropy_params
params.expect(collection: [ :auto_postpone_period ])
end
end