mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-12 15:35:15 +00:00
This should complete the account handler.
This commit is contained in:
33
resources/views/accounts/delete.blade.php
Normal file
33
resources/views/accounts/delete.blade.php
Normal file
@@ -0,0 +1,33 @@
|
||||
@extends('layouts.default')
|
||||
@section('content')
|
||||
{{-- Breadcrumbs::renderIfExists(Route::getCurrentRoute()->getName(), $account) --}}
|
||||
{!! Form::open(['class' => 'form-horizontal','id' => 'destroy','url' => route('accounts.destroy',$account->id)]) !!}
|
||||
<div class="row">
|
||||
<div class="col-lg-6 col-md-12 col-sm-12">
|
||||
<div class="panel panel-red">
|
||||
<div class="panel-heading">
|
||||
Delete account "{{{$account->name}}}"
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
<p>
|
||||
Are you sure?
|
||||
</p>
|
||||
|
||||
@if($account->transactions()->count() > 0)
|
||||
<p class="text-info">
|
||||
Account "{{{$account->name}}}" still has {{$account->transactions()->count()}} transaction(s) associated to it.
|
||||
These will be deleted as well.
|
||||
</p>
|
||||
@endif
|
||||
|
||||
<p>
|
||||
<button type="submit" class="btn btn-default btn-danger">Delete permanently</button>
|
||||
<a href="{{URL::previous()}}" class="btn-default btn">Cancel</a >
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{!! Form::close() !!}
|
||||
@stop
|
51
resources/views/accounts/edit.blade.php
Normal file
51
resources/views/accounts/edit.blade.php
Normal file
@@ -0,0 +1,51 @@
|
||||
@extends('layouts.default')
|
||||
@section('content')
|
||||
{{-- Breadcrumbs::renderIfExists(Route::getCurrentRoute()->getName(), $account) --}}
|
||||
{!! Form::model($account, ['class' => 'form-horizontal','id' => 'update','url' => route('accounts.update',$account->id)]) !!}
|
||||
<div class="row">
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="panel panel-primary">
|
||||
<div class="panel-heading">
|
||||
<i class="fa {{{$subTitleIcon}}}"></i> Mandatory fields
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
{!! ExpandedForm::text('name') !!}
|
||||
</div>
|
||||
</div>
|
||||
<p>
|
||||
<button type="submit" class="btn btn-lg btn-success">
|
||||
Update account
|
||||
</button>
|
||||
</p>
|
||||
</div>
|
||||
<div class="col-lg-6 col-md-6 col-sm-12">
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<i class="fa fa-smile-o"></i> Optional fields
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
@if($account->accounttype->type == 'Default account' || $account->accounttype->type == 'Asset account')
|
||||
{!! ExpandedForm::balance('openingBalance',null, ['currency' => $openingBalance ? $openingBalance->transactionCurrency : null]) !!}
|
||||
{!! ExpandedForm::date('openingBalanceDate') !!}
|
||||
{!! ExpandedForm::select('accountRole',Config::get('firefly.accountRoles')) !!}
|
||||
{!! Form::hidden('id',$account->id) !!}
|
||||
@endif
|
||||
{!! ExpandedForm::checkbox('active','1') !!}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- panel for options -->
|
||||
<div class="panel panel-default">
|
||||
<div class="panel-heading">
|
||||
<i class="fa fa-bolt"></i> Options
|
||||
</div>
|
||||
<div class="panel-body">
|
||||
{!! ExpandedForm::optionsList('update','account') !!}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{!! Form::close() !!}
|
||||
@stop
|
Reference in New Issue
Block a user