Skip to content

Commit bbb3069

Browse files
committed
PC-54: Add descriptions to Item view page
1 parent 53788ba commit bbb3069

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

app/admin/items.rb

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,9 @@
119119
attributes_table do
120120
row :id
121121
row :name
122+
row "Description" do |item|
123+
item.description.presence || "No description"
124+
end
122125
row "Category" do |item|
123126
link_to item.category.name, admin_category_path(item.category) if item.category
124127
end
@@ -220,7 +223,7 @@ def apply_tmp_params(item, tmp)
220223
actions :all, except: [:destroy]
221224

222225
action_item :back, only: :show do
223-
link_to "Back", admin_items_path
226+
link_to "Back to Items", admin_items_path
224227
end
225228

226229
action_item :toggle, only: :show do

0 commit comments

Comments
 (0)