Merge branch 'master' of github.com:akaunting/akaunting
This commit is contained in:
commit
f9687d9138
@ -1,6 +1,10 @@
|
||||
# Akaunting™
|
||||
|
||||
  [](https://crowdin.com/project/akaunting) 
|
||||
[](https://github.com/akaunting/akaunting/releases)
|
||||

|
||||
[](https://crowdin.com/project/akaunting)
|
||||
[](https://github.com/akaunting/akaunting/actions)
|
||||
[](LICENSE.txt)
|
||||
|
||||
Akaunting is a free, open source and online accounting software designed for small businesses and freelancers. It is built with modern technologies such as Laravel, VueJS, Bootstrap 4, RESTful API etc. Thanks to its modular structure, Akaunting provides an awesome App Store for users and developers.
|
||||
|
||||
|
@ -2,9 +2,9 @@
|
||||
|
||||
namespace App\Abstracts\Http;
|
||||
|
||||
use App\Events\Income\PaymentReceived;
|
||||
use App\Http\Requests\Portal\InvoicePayment as PaymentRequest;
|
||||
use App\Models\Income\Invoice;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Routing\Controller as BaseController;
|
||||
use Illuminate\Support\Facades\URL;
|
||||
use Monolog\Logger;
|
||||
@ -169,7 +169,7 @@ abstract class PaymentController extends BaseController
|
||||
$request['payment_method'] = $this->alias;
|
||||
$request['reference'] = $this->getReference($invoice);
|
||||
|
||||
event(new \App\Events\Income\PaymentReceived($invoice, $request));
|
||||
event(new PaymentReceived($invoice, $request));
|
||||
}
|
||||
|
||||
public function setReference($invoice, $reference)
|
||||
|
@ -2,18 +2,11 @@
|
||||
|
||||
namespace App\Traits;
|
||||
|
||||
use Omnipay\Omnipay as Library;
|
||||
|
||||
trait Omnipay
|
||||
{
|
||||
use Library;
|
||||
|
||||
public $gateway;
|
||||
|
||||
public function create($name)
|
||||
{
|
||||
$this->gateway = Library::create($name);
|
||||
}
|
||||
public $factory;
|
||||
|
||||
public function authorize($invoice, $request, $extra_options = [])
|
||||
{
|
||||
@ -156,4 +149,42 @@ trait Omnipay
|
||||
'data' => false,
|
||||
]);
|
||||
}
|
||||
|
||||
public function all()
|
||||
{
|
||||
return $this->callFactory('all');
|
||||
}
|
||||
|
||||
public function replace($gateways)
|
||||
{
|
||||
return $this->callFactory('replace', [$gateways]);
|
||||
}
|
||||
|
||||
public function register($class_name)
|
||||
{
|
||||
return $this->callFactory('register', [$class_name]);
|
||||
}
|
||||
|
||||
public function create($class, $http_client = null, $http_request = null)
|
||||
{
|
||||
$this->gateway = $this->callFactory('create', [$class, $http_client, $http_request]);
|
||||
|
||||
return $this->gateway;
|
||||
}
|
||||
|
||||
public function callFactory($method, $parameters = [])
|
||||
{
|
||||
$factory = $this->getFactory();
|
||||
|
||||
return call_user_func_array(array($factory, $method), (array) $parameters);
|
||||
}
|
||||
|
||||
public function getFactory()
|
||||
{
|
||||
if (is_null($this->factory)) {
|
||||
$this->factory = new \Omnipay\Common\GatewayFactory();
|
||||
}
|
||||
|
||||
return $this->factory;
|
||||
}
|
||||
}
|
||||
|
@ -1,26 +1,28 @@
|
||||
<div class="d-none">
|
||||
@if (!empty($setting['name']))
|
||||
<h2>{{ $setting['name'] }}</h2>
|
||||
@endif
|
||||
<div>
|
||||
<div class="d-none">
|
||||
@if (!empty($setting['name']))
|
||||
<h2>{{ $setting['name'] }}</h2>
|
||||
@endif
|
||||
|
||||
@if (!empty($setting['description']))
|
||||
<div class="well well-sm">{{ $setting['description'] }}</div>
|
||||
@endif
|
||||
</div>
|
||||
<br>
|
||||
@if (!empty($setting['description']))
|
||||
<div class="well well-sm">{{ $setting['description'] }}</div>
|
||||
@endif
|
||||
</div>
|
||||
<br>
|
||||
|
||||
<div class="buttons">
|
||||
<div class="pull-right">
|
||||
{!! Form::open([
|
||||
'url' => $confirm_url,
|
||||
'id' => 'redirect-form',
|
||||
'role' => 'form',
|
||||
'autocomplete' => "off",
|
||||
'novalidate' => 'true'
|
||||
]) !!}
|
||||
<button @click="onRedirectConfirm" type="button" id="button-confirm" class="btn btn-success">
|
||||
{{ trans('general.confirm') }}
|
||||
</button>
|
||||
{!! Form::close() !!}
|
||||
<div class="buttons">
|
||||
<div class="pull-right">
|
||||
{!! Form::open([
|
||||
'url' => $confirm_url,
|
||||
'id' => 'redirect-form',
|
||||
'role' => 'form',
|
||||
'autocomplete' => "off",
|
||||
'novalidate' => 'true'
|
||||
]) !!}
|
||||
<button @click="onRedirectConfirm" type="button" id="button-confirm" class="btn btn-success">
|
||||
{{ trans('general.confirm') }}
|
||||
</button>
|
||||
{!! Form::close() !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -1,3 +1,4 @@
|
||||
<div>
|
||||
<div class="d-none">
|
||||
@if (!empty($setting['name']))
|
||||
<h2>{{ $setting['name'] }}</h2>
|
||||
@ -24,4 +25,4 @@
|
||||
{!! Form::close() !!}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
Loading…
x
Reference in New Issue
Block a user