From d8e982782ef4b1fd3a4cc3ce57481e7e9ef45d54 Mon Sep 17 00:00:00 2001 From: KKlochko Date: Thu, 24 Apr 2025 21:38:42 +0300 Subject: [PATCH] Fix the Book FormComponent to save publisher_id. --- .../live/book_live/form_component.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/decentralised_book_index_web/live/book_live/form_component.ex b/lib/decentralised_book_index_web/live/book_live/form_component.ex index 5fbfafa..e46fa13 100644 --- a/lib/decentralised_book_index_web/live/book_live/form_component.ex +++ b/lib/decentralised_book_index_web/live/book_live/form_component.ex @@ -36,7 +36,7 @@ defmodule DecentralisedBookIndexWeb.BookLive.FormComponent do /> <.input field={@form[:page_count]} type="number" label="Page count" />
- <.label>Publisher + <.input field={@form[:publisher_id]} type="text" label="Publisher" type="hidden" /> <.selected_publisher publisher_form={@form[:publisher_id]} notify_component={@myself} @@ -66,7 +66,7 @@ defmodule DecentralisedBookIndexWeb.BookLive.FormComponent do /> <.input field={@form[:page_count]} type="number" label="Page count" />
- <.label>Publisher + <.input field={@form[:publisher_id]} type="text" label="Publisher" type="hidden" /> <.selected_publisher publisher_form={@form[:publisher_id]} notify_component={@myself}