Skip to content

Commit

Permalink
add a duplicate action to crud
Browse files Browse the repository at this point in the history
changes as suggested
Fix spacing in en.yml
  • Loading branch information
anitagraham committed Aug 28, 2019
1 parent df894ff commit 6958ce5
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions core/lib/refinery/crud.rb
Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,8 @@ def edit
end
def duplicate
original = @#{singular_name}
@#{singular_name} = original.dup
@#{singular_name}.title += ' Copy'
@#{singular_name} = @#{singular_name}.dup
@#{singular_name}.title << ' Copy'
render 'edit'
end
Expand Down

0 comments on commit 6958ce5

Please sign in to comment.