mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-23 04:06:21 +00:00
feat: botón de guardar en el pie
This commit is contained in:
parent
1e13fc4621
commit
d5d31a6d94
4 changed files with 5 additions and 6 deletions
|
@ -7,6 +7,7 @@
|
||||||
@param :dir [Symbol, String]
|
@param :dir [Symbol, String]
|
||||||
:ruby
|
:ruby
|
||||||
options = {
|
options = {
|
||||||
|
id: base,
|
||||||
multipart: true,
|
multipart: true,
|
||||||
class: 'form post ',
|
class: 'form post ',
|
||||||
'hx-swap': params.require(:swap),
|
'hx-swap': params.require(:swap),
|
||||||
|
@ -29,13 +30,7 @@
|
||||||
%input{ type: 'hidden', name: 'name', value: params.require(:name) }
|
%input{ type: 'hidden', name: 'name', value: params.require(:name) }
|
||||||
%input{ type: 'hidden', name: 'base', value: params.require(:base) }
|
%input{ type: 'hidden', name: 'base', value: params.require(:base) }
|
||||||
|
|
||||||
-# Botones de guardado
|
|
||||||
= render 'posts/submit', site: site, post: post
|
|
||||||
|
|
||||||
= hidden_field_tag "#{base}[layout]", post.layout.name
|
= hidden_field_tag "#{base}[layout]", post.layout.name
|
||||||
|
|
||||||
-# Dibuja cada atributo
|
-# Dibuja cada atributo
|
||||||
= render 'posts/attributes', site: site, post: post, dir: dir, base: base, locale: locale
|
= render 'posts/attributes', site: site, post: post, dir: dir, base: base, locale: locale
|
||||||
|
|
||||||
-# Botones de guardado
|
|
||||||
= render 'posts/submit', site: site, post: post
|
|
||||||
|
|
|
@ -90,3 +90,5 @@
|
||||||
= render 'bootstrap/modal', id: post_id, modal_content_attributes: { class: 'h-100' } do
|
= render 'bootstrap/modal', id: post_id, modal_content_attributes: { class: 'h-100' } do
|
||||||
- content_for :"#{post_id}_body" do
|
- content_for :"#{post_id}_body" do
|
||||||
%div{ id: post_form_loaded_id }
|
%div{ id: post_form_loaded_id }
|
||||||
|
- content_for :"#{post_id}_footer" do
|
||||||
|
= render 'bootstrap/btn', form: id, content: t('.save'), type: 'submit'
|
||||||
|
|
|
@ -944,3 +944,4 @@ en:
|
||||||
cancel: "Cancel"
|
cancel: "Cancel"
|
||||||
edit: "Edit"
|
edit: "Edit"
|
||||||
filter: "Start typing to filter..."
|
filter: "Start typing to filter..."
|
||||||
|
save: "Save"
|
||||||
|
|
|
@ -952,3 +952,4 @@ es:
|
||||||
cancel: "Cancelar"
|
cancel: "Cancelar"
|
||||||
edit: "Editar"
|
edit: "Editar"
|
||||||
filter: "Empezá a escribir para filtrar..."
|
filter: "Empezá a escribir para filtrar..."
|
||||||
|
save: "Guardar"
|
||||||
|
|
Loading…
Reference in a new issue