diff --git a/app/controllers/api/templates_controller.rb b/app/controllers/api/templates_controller.rb index 2c165b34..7d385c2c 100644 --- a/app/controllers/api/templates_controller.rb +++ b/app/controllers/api/templates_controller.rb @@ -15,7 +15,8 @@ module Api def template_params params.require(:template).permit(:name, schema: [%i[attachment_uuid name]], - fields: [[:uuid, :name, :type, :required, + submitters: [%i[name uuid]], + fields: [[:uuid, :submitter_uuid, :name, :type, :required, { options: [], areas: [%i[x y w h attachment_uuid page]] }]]) end end diff --git a/app/javascript/application.js b/app/javascript/application.js index 5b03bb9e..94309267 100644 --- a/app/javascript/application.js +++ b/app/javascript/application.js @@ -48,6 +48,6 @@ window.customElements.define('template-builder', class extends HTMLElement { } }) -document.addEventListener('clipboard-copy', function(event) { +document.addEventListener('clipboard-copy', function (event) { console.log('Copied to clipboard') // TODO: Add a toast message }) diff --git a/app/javascript/template_builder/area.vue b/app/javascript/template_builder/area.vue index 92ad99c6..b6adb4c8 100644 --- a/app/javascript/template_builder/area.vue +++ b/app/javascript/template_builder/area.vue @@ -6,44 +6,32 @@ @mousedown.stop="startDrag" >
+
- -
diff --git a/app/javascript/template_builder/field_type.vue b/app/javascript/template_builder/field_type.vue index 7e3f0614..d95feea2 100644 --- a/app/javascript/template_builder/field_type.vue +++ b/app/javascript/template_builder/field_type.vue @@ -14,7 +14,7 @@