add the ability to clone a template

This commit is contained in:
Alex Turchyn
2023-06-18 16:26:51 +00:00
parent 02fee9f885
commit 866bf7291d
6 changed files with 77 additions and 5 deletions
+3
View File
@@ -1,5 +1,8 @@
<%= render 'shared/turbo_modal', title: 'New Template' do %>
<%= form_for @template, data: { turbo_frame: :_top } do |f| %>
<% if @base_template %>
<%= hidden_field_tag :base_template_id, @base_template.id %>
<% end %>
<div class="form-control my-6">
<%= f.text_field :name, required: true, placeholder: 'Template Name', class: 'base-input' %>
</div>