mirror of
https://koodu.h-i.works/projects/thebadspace
synced 2025-06-25 16:04:37 -05:00
Source creation and editing
A UI has been added for entering new sources and editing pre-existing ones. No more having to edit the DB directly when wanting to add or remove a source.
This commit is contained in:
42
resources/views/back/sources.blade.php
Normal file
42
resources/views/back/sources.blade.php
Normal file
@ -0,0 +1,42 @@
|
||||
@extends('frame')
|
||||
|
||||
@section('title', 'Den | Sources Admin')
|
||||
|
||||
@php
|
||||
switch($mode)
|
||||
{
|
||||
case 'source-create':
|
||||
$action_url = '/den/source/create';
|
||||
break;
|
||||
case 'source-edit':
|
||||
$action_url = '/den/source/edit';
|
||||
break;
|
||||
}
|
||||
@endphp
|
||||
@section('main-content')
|
||||
<section>
|
||||
<article>
|
||||
@switch($mode)
|
||||
@case('source-edit')
|
||||
<h2>Edit Info for {{$source->url}}</h2>
|
||||
@include('forms.source-edit')
|
||||
<br />
|
||||
@break
|
||||
|
||||
@case('source-create')
|
||||
<h2>New Source Info</h2>
|
||||
@include('forms.source-edit')
|
||||
<br />
|
||||
@break
|
||||
|
||||
@default
|
||||
<h2>Current Sources </h2>
|
||||
@foreach($sources as $source)
|
||||
<a href="/den/source/{{$source->id}}">{{$source->url}}</a><br />
|
||||
@endforeach
|
||||
<h2>Add Source </h2>
|
||||
<a href="/den/source/edit/create">Add a new Source</a><br />
|
||||
@endswitch
|
||||
</article>
|
||||
</section>
|
||||
@endsection
|
Reference in New Issue
Block a user