mix format

This commit is contained in:
2022-07-25 22:05:54 -04:00
parent c6e6154689
commit 6858df2ae2
25 changed files with 860 additions and 88 deletions

View File

@ -7,22 +7,24 @@
id="pipeline-form"
phx-target={@myself}
phx-change="validate"
phx-submit="save">
<%= label f, :title %>
<%= text_input f, :title %>
<%= error_tag f, :title %>
<%= label f, :description %>
<%= textarea f, :description %>
<%= error_tag f, :description %>
<%= label f, :visibility %>
<%= select f, :visibility, Ecto.Enum.values(Memex.Pipelines.Pipeline, :visibility), prompt: "Choose a value" %>
<%= error_tag f, :visibility %>
phx-submit="save"
>
<%= label(f, :title) %>
<%= text_input(f, :title) %>
<%= error_tag(f, :title) %>
<%= label(f, :description) %>
<%= textarea(f, :description) %>
<%= error_tag(f, :description) %>
<%= label(f, :visibility) %>
<%= select(f, :visibility, Ecto.Enum.values(Memex.Pipelines.Pipeline, :visibility),
prompt: "Choose a value"
) %>
<%= error_tag(f, :visibility) %>
<div>
<%= submit "Save", phx_disable_with: "Saving..." %>
<%= submit("Save", phx_disable_with: "Saving...") %>
</div>
</.form>
</div>

View File

@ -31,13 +31,24 @@
<td><%= pipeline.visibility %></td>
<td>
<span><%= live_redirect "Show", to: Routes.pipeline_show_path(@socket, :show, pipeline) %></span>
<span><%= live_patch "Edit", to: Routes.pipeline_index_path(@socket, :edit, pipeline) %></span>
<span><%= link "Delete", to: "#", phx_click: "delete", phx_value_id: pipeline.id, data: [confirm: "Are you sure?"] %></span>
<span>
<%= live_redirect("Show", to: Routes.pipeline_show_path(@socket, :show, pipeline)) %>
</span>
<span>
<%= live_patch("Edit", to: Routes.pipeline_index_path(@socket, :edit, pipeline)) %>
</span>
<span>
<%= link("Delete",
to: "#",
phx_click: "delete",
phx_value_id: pipeline.id,
data: [confirm: "Are you sure?"]
) %>
</span>
</td>
</tr>
<% end %>
</tbody>
</table>
<span><%= live_patch "New Pipeline", to: Routes.pipeline_index_path(@socket, :new) %></span>
<span><%= live_patch("New Pipeline", to: Routes.pipeline_index_path(@socket, :new)) %></span>

View File

@ -14,7 +14,6 @@
<% end %>
<ul>
<li>
<strong>Title:</strong>
<%= @pipeline.title %>
@ -29,8 +28,9 @@
<strong>Visibility:</strong>
<%= @pipeline.visibility %>
</li>
</ul>
<span><%= live_patch "Edit", to: Routes.pipeline_show_path(@socket, :edit, @pipeline), class: "button" %></span> |
<span><%= live_redirect "Back", to: Routes.pipeline_index_path(@socket, :index) %></span>
<span>
<%= live_patch("Edit", to: Routes.pipeline_show_path(@socket, :edit, @pipeline), class: "button") %>
</span> |
<span><%= live_redirect("Back", to: Routes.pipeline_index_path(@socket, :index)) %></span>