[WIP] add settings sidebar entry and placeholder page
This commit is contained in:
parent
24875eaeac
commit
24b3bfb038
5 changed files with 29 additions and 6 deletions
|
|
@ -24,6 +24,7 @@
|
|||
<.sidebar_item icon="hero-home" text="Home" href={~p"/"} />
|
||||
<.sidebar_item icon="hero-tv" text="Sources" href={~p"/sources"} />
|
||||
<.sidebar_item icon="hero-adjustments-vertical" text="Media Profiles" href={~p"/media_profiles"} />
|
||||
<.sidebar_item icon="hero-cog-6-tooth" text="Settings" href={~p"/settings"} />
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
|
|
@ -38,12 +39,7 @@
|
|||
target="_blank"
|
||||
href="https://github.com/kieraneglin/pinchflat/wiki"
|
||||
/>
|
||||
<.sidebar_item
|
||||
icon="hero-code-bracket"
|
||||
text="Github"
|
||||
target="_blank"
|
||||
href="https://github.com/kieraneglin/pinchflat"
|
||||
/>
|
||||
<.sidebar_item icon="hero-cog" text="Github" target="_blank" href="https://github.com/kieraneglin/pinchflat" />
|
||||
<li>
|
||||
<span
|
||||
class={[
|
||||
|
|
|
|||
11
lib/pinchflat_web/controllers/settings/setting_controller.ex
Normal file
11
lib/pinchflat_web/controllers/settings/setting_controller.ex
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
defmodule PinchflatWeb.Settings.SettingController do
|
||||
use PinchflatWeb, :controller
|
||||
|
||||
import Ecto.Query, warn: false
|
||||
|
||||
alias Pinchflat.Repo
|
||||
|
||||
def edit(conn, _params) do
|
||||
render(conn, "edit.html")
|
||||
end
|
||||
end
|
||||
13
lib/pinchflat_web/controllers/settings/setting_html.ex
Normal file
13
lib/pinchflat_web/controllers/settings/setting_html.ex
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
defmodule PinchflatWeb.Settings.SettingHTML do
|
||||
use PinchflatWeb, :html
|
||||
|
||||
embed_templates "setting_html/*"
|
||||
|
||||
# @doc """
|
||||
# Renders a setting form.
|
||||
# """
|
||||
# attr :changeset, Ecto.Changeset, required: true
|
||||
# attr :action, :string, required: true
|
||||
|
||||
# def setting_form(assigns)
|
||||
end
|
||||
|
|
@ -0,0 +1 @@
|
|||
<h1>TEST</h1>
|
||||
|
|
@ -27,6 +27,8 @@ defmodule PinchflatWeb.Router do
|
|||
pipe_through :browser
|
||||
|
||||
get "/", Pages.PageController, :home
|
||||
get "/settings", Settings.SettingController, :edit
|
||||
resources "/settings", Settings.SettingController, only: [:update], singleton: true
|
||||
|
||||
resources "/media_profiles", MediaProfiles.MediaProfileController
|
||||
resources "/search", Searches.SearchController, only: [:show], singleton: true
|
||||
|
|
|
|||
Loading…
Reference in a new issue