mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-11-01 19:47:11 +00:00
Made big headway in preference management, accounts, importing stuff, etc. etc.
This commit is contained in:
53
app/views/accounts/index.blade.php
Normal file
53
app/views/accounts/index.blade.php
Normal file
@@ -0,0 +1,53 @@
|
||||
@extends('layouts.default')
|
||||
@section('content')
|
||||
<div class="row">
|
||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||
<h1>Firefly
|
||||
<small>Accounts</small>
|
||||
</h1>
|
||||
<h2>Index</h2>
|
||||
<p style="width:50%;" class="text-info">
|
||||
In a double-entry bookkeeping system almost <em>everything</em> is an account. Your own personal
|
||||
bank accounts are representated as accounts (naturally), but the stores you buy stuff at are also
|
||||
represented as accounts. Likewise, if you have a job, your salary is drawn from their account.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||
<h3>Your accounts</h3>
|
||||
<p style="width:50%;" class="text-info">
|
||||
These are your personal accounts.
|
||||
</p>
|
||||
|
||||
@include('accounts.list',['accounts' => $accounts['personal']])
|
||||
|
||||
<h3>Beneficiaries</h3>
|
||||
<p style="width:50%;" class="text-info">
|
||||
These are beneficiaries; places where you spend money or people who pay you.
|
||||
</p>
|
||||
|
||||
@include('accounts.list',['accounts' => $accounts['beneficiaries']])
|
||||
|
||||
<h3>Initial balances</h3>
|
||||
<p style="width:50%;" class="text-info">
|
||||
These are system accounts; created to add balance to the books when you add a personal account
|
||||
which already has money in it. That money has to come from somewhere.
|
||||
</p>
|
||||
@include('accounts.list',['accounts' => $accounts['initial']])
|
||||
|
||||
<h3>Cash</h3>
|
||||
<p style="width:50%;" class="text-info">
|
||||
This is a system account. When you don't specify a beneficiary or draw many from an ATM (or put cash in your
|
||||
personal accounts) it gets added or drawn from this account.
|
||||
</p>
|
||||
@include('accounts.list',['accounts' => $accounts['cash']])
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@stop
|
||||
@section('scripts')
|
||||
<script src="https://www.google.com/jsapi"></script>
|
||||
<!-- <script src="assets/javascript/charts.js"></script>-->
|
||||
<!-- <script src="assets/javascript/index.js"></script>-->
|
||||
@stop
|
||||
19
app/views/accounts/list.blade.php
Normal file
19
app/views/accounts/list.blade.php
Normal file
@@ -0,0 +1,19 @@
|
||||
<table class="table table-bordered table-striped">
|
||||
<tr>
|
||||
<th style="width:25px;"> </th>
|
||||
<th style="width:30%;">Name</th>
|
||||
<th>Current balance</th>
|
||||
</tr>
|
||||
@foreach($accounts as $account)
|
||||
<tr>
|
||||
<td>
|
||||
@if($account->active == 0)
|
||||
<span title="This account is inactive." class="glyphicon glyphicon-ban-circle"></span>
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{route('accounts.show',$account->id)}}" title="Overview for account {{{$account->name}}}">{{{$account->name}}}</a></td>
|
||||
<td>{{mf($account->balance())}}</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</table>
|
||||
@@ -4,7 +4,6 @@
|
||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||
<h1>Firefly
|
||||
@if($count > 0)
|
||||
<br/>
|
||||
<small>What's playing?</small>
|
||||
@endif
|
||||
</h1>
|
||||
@@ -33,10 +32,27 @@
|
||||
</p>
|
||||
</div>
|
||||
@else
|
||||
<div class="row" style="border-top:1px #eee solid;">
|
||||
@foreach($accounts as $index => $account)
|
||||
<div class="col-lg-6">
|
||||
<div id="chart_{{{$account->id}}}" data-id="{{{$account->id}}}" class="homeChart" data-title="{{{$account->name}}}"></div>
|
||||
<p>
|
||||
Go to <a href="#" title="Overview for {{{$account->name}}}">{{{$account->name}}}</a>
|
||||
</p>
|
||||
|
||||
</div>
|
||||
@if($index % 2 == 1)
|
||||
</div><div class="row" style="border-top:1px #eee solid;">
|
||||
@endif
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
|
||||
@endif
|
||||
|
||||
@stop
|
||||
@section('scripts')
|
||||
<script src="https://www.google.com/jsapi"></script>
|
||||
<script src="assets/javascript/charts.js"></script>
|
||||
<script src="assets/javascript/index.js"></script>
|
||||
@stop
|
||||
@@ -19,7 +19,7 @@
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
@include('partials.menu')
|
||||
@include('partials.menu.'.$menu)
|
||||
@include('partials.flashes')
|
||||
@yield('content')
|
||||
</div>
|
||||
|
||||
27
app/views/partials/menu/accounts.blade.php
Normal file
27
app/views/partials/menu/accounts.blade.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
$r = Route::current()->getName();
|
||||
?>
|
||||
<nav class="navbar navbar-default" role="navigation">
|
||||
<div class="container-fluid">
|
||||
<!-- Brand and toggle get grouped for better mobile display -->
|
||||
<div class="navbar-header">
|
||||
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
|
||||
<span class="sr-only">Toggle navigation</span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
<span class="icon-bar"></span>
|
||||
</button>
|
||||
<a class="navbar-brand" href="{{route('index')}}">Firefly III</a>
|
||||
</div>
|
||||
|
||||
<!-- Collect the nav links, forms, and other content for toggling -->
|
||||
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
|
||||
<ul class="nav navbar-nav">
|
||||
<li @if($r=='index')class="active"@endif><a href="{{route('index')}}">Home</a></li>
|
||||
<li @if($r=='accounts.index')class="active"@endif><a href="{{route('accounts.index')}}">Accounts</a></li>
|
||||
<li @if($r=='accounts.create')class="active"@endif><a href="{{route('accounts.create')}}"><span class="glyphicon glyphicon-plus"></span> Create</a></li>
|
||||
</ul>
|
||||
@include('partials.menu.shared')
|
||||
</div><!-- /.navbar-collapse -->
|
||||
</div><!-- /.container-fluid -->
|
||||
</nav>
|
||||
@@ -1,3 +1,6 @@
|
||||
<?php
|
||||
$r = Route::current()->getName();
|
||||
?>
|
||||
<nav class="navbar navbar-default" role="navigation">
|
||||
<div class="container-fluid">
|
||||
<!-- Brand and toggle get grouped for better mobile display -->
|
||||
@@ -14,12 +17,11 @@
|
||||
<!-- Collect the nav links, forms, and other content for toggling -->
|
||||
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
|
||||
<ul class="nav navbar-nav">
|
||||
<li class="active"><a href="#">Link</a></li>
|
||||
<li><a href="#">Link</a></li>
|
||||
<li @if($r=='index')class="active"@endif><a href="{{route('index')}}">Home</a></li>
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <span class="caret"></span></a>
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Go to...<span class="caret"></span></a>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li><a href="#">Action</a></li>
|
||||
<li><a href="{{route('accounts.index')}}">Accounts</a></li>
|
||||
<li><a href="#">Another action</a></li>
|
||||
<li><a href="#">Something else here</a></li>
|
||||
<li class="divider"></li>
|
||||
@@ -29,23 +31,7 @@
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<form class="navbar-form navbar-left" role="search">
|
||||
<div class="form-group">
|
||||
<input type="text" class="form-control" placeholder="Search">
|
||||
</div>
|
||||
<button type="submit" class="btn btn-default">Submit</button>
|
||||
</form>
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li><a href="#">Link</a></li>
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">{{{Auth::user()->email}}} <span class="caret"></span></a>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li><a href="{{route('profile')}}"><span class="glyphicon glyphicon-user"></span> Profile</a></li>
|
||||
<li class="divider"></li>
|
||||
<li><a href="{{route('logout')}}"><span class="glyphicon glyphicon-arrow-right"></span> Logout</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
@include('partials.menu.shared')
|
||||
</div><!-- /.navbar-collapse -->
|
||||
</div><!-- /.container-fluid -->
|
||||
</nav>
|
||||
11
app/views/partials/menu/shared.blade.php
Normal file
11
app/views/partials/menu/shared.blade.php
Normal file
@@ -0,0 +1,11 @@
|
||||
<ul class="nav navbar-nav navbar-right">
|
||||
<li @if($r=='settings')class="active"@endif><a href="{{route('preferences')}}"><span class="glyphicon glyphicon-cog"></span> Preferences</a></li>
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown">{{{Auth::user()->email}}} <span class="caret"></span></a>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li><a href="{{route('profile')}}"><span class="glyphicon glyphicon-user"></span> Profile</a></li>
|
||||
<li class="divider"></li>
|
||||
<li><a href="{{route('logout')}}"><span class="glyphicon glyphicon-arrow-right"></span> Logout</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
45
app/views/preferences/index.blade.php
Normal file
45
app/views/preferences/index.blade.php
Normal file
@@ -0,0 +1,45 @@
|
||||
@extends('layouts.default')
|
||||
@section('content')
|
||||
<div class="row">
|
||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||
<h1>Firefly
|
||||
<small>Preferences</small>
|
||||
</h1>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- home screen accounts -->
|
||||
<div class="row">
|
||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||
<h3>Home screen accounts</h3>
|
||||
<p class="text-info">Which accounts should be displayed on the home page?</p>
|
||||
<!-- form -->
|
||||
{{Form::open(['class' => 'form-horizontal'])}}
|
||||
@foreach($accounts as $account)
|
||||
<div class="form-group">
|
||||
<div class="col-sm-10">
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
@if(in_array($account->id,$frontpageAccounts->data) || count($frontpageAccounts->data) == 0)
|
||||
<input type="checkbox" name="frontpageAccounts[]" value="{{$account->id}}" checked> {{{$account->name}}}
|
||||
@else
|
||||
<input type="checkbox" name="frontpageAccounts[]" value="{{$account->id}}"> {{{$account->name}}}
|
||||
@endif
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
<div class="form-group">
|
||||
<div class="col-sm-12">
|
||||
<button type="submit" class="btn btn-default">Save accounts</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@stop
|
||||
@section('scripts')
|
||||
@stop
|
||||
Reference in New Issue
Block a user