mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-12 22:22:32 +01:00
Bank Transactions matching default category ID
This commit is contained in:
parent
18859b237c
commit
02080cc3b7
@ -34,7 +34,7 @@ class UpdateBankTransactionRequest extends Request
|
|||||||
$rules = [
|
$rules = [
|
||||||
'date' => 'bail|required|date',
|
'date' => 'bail|required|date',
|
||||||
'description' => 'bail|sometimes|string',
|
'description' => 'bail|sometimes|string',
|
||||||
'amount' => 'numeric|sometimes',
|
'amount' => 'numeric|required',
|
||||||
];
|
];
|
||||||
|
|
||||||
if (isset($this->currency_id))
|
if (isset($this->currency_id))
|
||||||
|
@ -295,7 +295,7 @@ class MatchBankTransactions implements ShouldQueue
|
|||||||
|
|
||||||
private function resolveCategory() :?int
|
private function resolveCategory() :?int
|
||||||
{
|
{
|
||||||
if(array_key_exists('ninja_category_id', $this->input)){
|
if(array_key_exists('ninja_category_id', $this->input) && strlen($this->input['ninja_category_id']) >=1){
|
||||||
$this->bt->ninja_category_id = $this->input['ninja_category_id'];
|
$this->bt->ninja_category_id = $this->input['ninja_category_id'];
|
||||||
$this->bt->save();
|
$this->bt->save();
|
||||||
return (int)$this->input['ninja_category_id'];
|
return (int)$this->input['ninja_category_id'];
|
||||||
|
Loading…
Reference in New Issue
Block a user