Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion app/controllers/boards/columns_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def update

respond_to do |format|
format.turbo_stream
format.json { head :no_content }
format.json { render :show }
end
end

Expand Down
2 changes: 1 addition & 1 deletion docs/api/sections/columns.md
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ __Request:__

__Response:__

Returns `204 No Content` on success.
Returns `200 OK` with the updated column in the same shape as `GET /:account_slug/boards/:board_id/columns/:column_id`.

## `DELETE /:account_slug/boards/:board_id/columns/:column_id`

Expand Down
4 changes: 3 additions & 1 deletion test/controllers/api/flat_json_params_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,10 @@ class FlatJsonParamsTest < ActionDispatch::IntegrationTest

put board_column_path(column.board, column), params: { name: "Flat Updated" }, as: :json

assert_response :no_content
assert_response :success
assert_equal "Flat Updated", column.reload.name
assert_equal column.id, @response.parsed_body["id"]
assert_equal "Flat Updated", @response.parsed_body["name"]
end

test "create step with flat JSON" do
Expand Down
6 changes: 5 additions & 1 deletion test/controllers/boards/columns_controller_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,12 @@ class Boards::ColumnsControllerTest < ActionDispatch::IntegrationTest

put board_column_path(column.board, column), params: { column: { name: "Updated Name" } }, as: :json

assert_response :no_content
assert_response :success
assert_equal "Updated Name", column.reload.name

json = @response.parsed_body
assert_equal column.id, json["id"]
assert_equal "Updated Name", json["name"]
end

test "destroy as JSON" do
Expand Down