mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Fix some spelling errors.
This commit is contained in:
parent
9ede6755c5
commit
e21e339cb0
@ -88,7 +88,7 @@ class ReportController extends Controller
|
||||
}
|
||||
|
||||
/**
|
||||
* Shows income and expense, debet/credit: operations.
|
||||
* Shows income and expense, debit/credit: operations.
|
||||
*
|
||||
* @param Collection $accounts
|
||||
* @param Carbon $start
|
||||
@ -143,7 +143,7 @@ class ReportController extends Controller
|
||||
}
|
||||
|
||||
/**
|
||||
* Shows sum income and expense, debet/credit: operations.
|
||||
* Shows sum income and expense, debit/credit: operations.
|
||||
*
|
||||
* @param Carbon $start
|
||||
* @param Carbon $end
|
||||
|
@ -102,7 +102,7 @@ class HomeController extends Controller
|
||||
*/
|
||||
public function displayDebug(Request $request)
|
||||
{
|
||||
$phpVersion = PHP_VERSION;
|
||||
$phpVersion = str_replace('~','\~',PHP_VERSION);
|
||||
$phpOs = php_uname();
|
||||
$interface = PHP_SAPI;
|
||||
$now = Carbon::create()->format('Y-m-d H:i:s e');
|
||||
|
@ -25,7 +25,7 @@ namespace FireflyIII\Import\Converter;
|
||||
use Log;
|
||||
|
||||
/**
|
||||
* Class RabobankDebetCredit.
|
||||
* Class Amount.
|
||||
*/
|
||||
class Amount implements ConverterInterface
|
||||
{
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/**
|
||||
* AmountDebet.php
|
||||
* AmountDebit.php
|
||||
* Copyright (c) 2017 thegrumpydictator@gmail.com
|
||||
*
|
||||
* This file is part of Firefly III.
|
||||
@ -23,9 +23,9 @@ declare(strict_types=1);
|
||||
namespace FireflyIII\Import\Converter;
|
||||
|
||||
/**
|
||||
* Class AmountDebet
|
||||
* Class AmountDebit
|
||||
*/
|
||||
class AmountDebet implements ConverterInterface
|
||||
class AmountDebit implements ConverterInterface
|
||||
{
|
||||
/**
|
||||
* @param $value
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/**
|
||||
* INGDebetCredit.php
|
||||
* INGDebitCredit.php
|
||||
* Copyright (c) 2017 thegrumpydictator@gmail.com
|
||||
*
|
||||
* This file is part of Firefly III.
|
||||
@ -25,9 +25,9 @@ namespace FireflyIII\Import\Converter;
|
||||
use Log;
|
||||
|
||||
/**
|
||||
* Class INGDebetCredit.
|
||||
* Class INGDebitCredit.
|
||||
*/
|
||||
class INGDebetCredit implements ConverterInterface
|
||||
class INGDebitCredit implements ConverterInterface
|
||||
{
|
||||
/**
|
||||
* @param $value
|
||||
@ -36,7 +36,7 @@ class INGDebetCredit implements ConverterInterface
|
||||
*/
|
||||
public function convert($value)
|
||||
{
|
||||
Log::debug('Going to convert ing debet credit', ['value' => $value]);
|
||||
Log::debug('Going to convert ing debit credit', ['value' => $value]);
|
||||
|
||||
if ('Af' === $value) {
|
||||
Log::debug('Return -1');
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/**
|
||||
* RabobankDebetCredit.php
|
||||
* RabobankDebitCredit.php
|
||||
* Copyright (c) 2017 thegrumpydictator@gmail.com
|
||||
*
|
||||
* This file is part of Firefly III.
|
||||
@ -25,9 +25,9 @@ namespace FireflyIII\Import\Converter;
|
||||
use Log;
|
||||
|
||||
/**
|
||||
* Class RabobankDebetCredit.
|
||||
* Class RabobankDebitCredit.
|
||||
*/
|
||||
class RabobankDebetCredit implements ConverterInterface
|
||||
class RabobankDebitCredit implements ConverterInterface
|
||||
{
|
||||
/**
|
||||
* @param $value
|
@ -63,7 +63,7 @@ class ImportJournal
|
||||
/** @var array */
|
||||
private $amountCredit;
|
||||
/** @var array */
|
||||
private $amountDebet;
|
||||
private $amountDebit;
|
||||
/** @var string */
|
||||
private $convertedAmount = null;
|
||||
/** @var string */
|
||||
@ -105,7 +105,7 @@ class ImportJournal
|
||||
{
|
||||
Log::debug('Now in getAmount()');
|
||||
Log::debug(sprintf('amount is %s', var_export($this->amount, true)));
|
||||
Log::debug(sprintf('debet amount is %s', var_export($this->amountDebet, true)));
|
||||
Log::debug(sprintf('debit amount is %s', var_export($this->amountDebit, true)));
|
||||
Log::debug(sprintf('credit amount is %s', var_export($this->amountCredit, true)));
|
||||
|
||||
if (null === $this->convertedAmount) {
|
||||
@ -188,8 +188,8 @@ class ImportJournal
|
||||
case 'amount':
|
||||
$this->amount = $array;
|
||||
break;
|
||||
case 'amount_debet':
|
||||
$this->amountDebet = $array;
|
||||
case 'amount_debit':
|
||||
$this->amountDebit = $array;
|
||||
break;
|
||||
case 'amount_credit':
|
||||
$this->amountCredit = $array;
|
||||
@ -250,8 +250,8 @@ class ImportJournal
|
||||
break;
|
||||
case '_ignore':
|
||||
break;
|
||||
case 'ing-debet-credit':
|
||||
case 'rabo-debet-credit':
|
||||
case 'ing-debit-credit':
|
||||
case 'rabo-debit-credit':
|
||||
$this->addToModifier($array);
|
||||
break;
|
||||
case 'opposing-iban':
|
||||
@ -284,7 +284,7 @@ class ImportJournal
|
||||
|
||||
/**
|
||||
* If convertedAmount is NULL, this method will try to calculate the correct amount.
|
||||
* It starts with amount, but can be overruled by debet and credit amounts.
|
||||
* It starts with amount, but can be overruled by debit and credit amounts.
|
||||
*
|
||||
* @throws FireflyException
|
||||
*/
|
||||
@ -332,13 +332,13 @@ class ImportJournal
|
||||
$converterClass = sprintf('FireflyIII\Import\Converter\%s', config(sprintf('csv.import_roles.%s.converter', $this->amount['role'])));
|
||||
$info = $this->amount;
|
||||
}
|
||||
if (!is_null($this->amountDebet)) {
|
||||
Log::debug('Amount DEBET value is not NULL, assume this is the correct value (overrules Amount).');
|
||||
$converterClass = sprintf('FireflyIII\Import\Converter\%s', config(sprintf('csv.import_roles.%s.converter', $this->amountDebet['role'])));
|
||||
$info = $this->amountDebet;
|
||||
if (!is_null($this->amountDebit)) {
|
||||
Log::debug('Amount DEBIT value is not NULL, assume this is the correct value (overrules Amount).');
|
||||
$converterClass = sprintf('FireflyIII\Import\Converter\%s', config(sprintf('csv.import_roles.%s.converter', $this->amountDebit['role'])));
|
||||
$info = $this->amountDebit;
|
||||
}
|
||||
if (!is_null($this->amountCredit)) {
|
||||
Log::debug('Amount CREDIT value is not NULL, assume this is the correct value (overrules Amount and AmountDebet).');
|
||||
Log::debug('Amount CREDIT value is not NULL, assume this is the correct value (overrules Amount and AmountDebit).');
|
||||
$converterClass = sprintf('FireflyIII\Import\Converter\%s', config(sprintf('csv.import_roles.%s.converter', $this->amountCredit['role'])));
|
||||
$info = $this->amountCredit;
|
||||
}
|
||||
|
@ -35,7 +35,7 @@ use Log;
|
||||
class Initial implements ConfigurationInterface
|
||||
{
|
||||
/**
|
||||
* @var
|
||||
* @var ImportJob
|
||||
*/
|
||||
private $job;
|
||||
|
||||
@ -53,6 +53,11 @@ class Initial implements ConfigurationInterface
|
||||
'tab' => trans('form.csv_tab'),
|
||||
];
|
||||
|
||||
// update job with default date format:
|
||||
$config = $this->job->configuration;
|
||||
$config['date-format'] = 'Ymd';
|
||||
$this->job->configuration = $config;
|
||||
$this->job->save();
|
||||
$specifics = [];
|
||||
|
||||
// collect specifics.
|
||||
@ -68,6 +73,7 @@ class Initial implements ConfigurationInterface
|
||||
'specifix' => [],
|
||||
'delimiters' => $delimiters,
|
||||
'specifics' => $specifics,
|
||||
|
||||
];
|
||||
|
||||
return $data;
|
||||
|
@ -55,7 +55,6 @@ class Roles implements ConfigurationInterface
|
||||
{
|
||||
$config = $this->job->configuration;
|
||||
$content = $this->job->uploadFileContents();
|
||||
$config['has-headers'] = true;
|
||||
$headers = [];
|
||||
$offset = 0;
|
||||
// create CSV reader.
|
||||
@ -272,7 +271,7 @@ class Roles implements ConfigurationInterface
|
||||
if ('_ignore' !== $role) {
|
||||
++$assigned;
|
||||
}
|
||||
if (in_array($role, ['amount', 'amount_credit', 'amount_debet'])) {
|
||||
if (in_array($role, ['amount', 'amount_credit', 'amount_debit'])) {
|
||||
$hasAmount = true;
|
||||
}
|
||||
}
|
||||
|
@ -175,16 +175,16 @@ return [
|
||||
'field' => 'budget',
|
||||
'mapper' => 'Budgets',
|
||||
],
|
||||
'rabo-debet-credit' => [
|
||||
'rabo-debit-credit' => [
|
||||
'mappable' => false,
|
||||
'pre-process-map' => false,
|
||||
'converter' => 'RabobankDebetCredit',
|
||||
'converter' => 'RabobankDebitCredit',
|
||||
'field' => 'amount-modifier',
|
||||
],
|
||||
'ing-debet-credit' => [
|
||||
'ing-debit-credit' => [
|
||||
'mappable' => false,
|
||||
'pre-process-map' => false,
|
||||
'converter' => 'INGDebetCredit',
|
||||
'converter' => 'INGDebitCredit',
|
||||
'field' => 'amount-modifier',
|
||||
],
|
||||
'category-id' => [
|
||||
@ -280,11 +280,11 @@ return [
|
||||
'converter' => 'Amount',
|
||||
'field' => 'amount',
|
||||
],
|
||||
'amount_debet' => [
|
||||
'amount_debit' => [
|
||||
'mappable' => false,
|
||||
'pre-process-map' => false,
|
||||
'converter' => 'AmountDebet',
|
||||
'field' => 'amount_debet',
|
||||
'converter' => 'AmountDebit',
|
||||
'field' => 'amount_debit',
|
||||
],
|
||||
'amount_credit' => [
|
||||
'mappable' => false,
|
||||
|
@ -106,7 +106,7 @@ return [
|
||||
'column_account-id' => 'Asset account ID (matching Firefly)',
|
||||
'column_account-name' => 'Asset account (name)',
|
||||
'column_amount' => 'Amount',
|
||||
'column_amount_debet' => 'Amount (debet column)',
|
||||
'column_amount_debit' => 'Amount (debit column)',
|
||||
'column_amount_credit' => 'Amount (credit column)',
|
||||
'column_amount-comma-separated' => 'Amount (comma as decimal separator)',
|
||||
'column_bill-id' => 'Bill ID (matching Firefly)',
|
||||
@ -128,11 +128,11 @@ return [
|
||||
'column_opposing-id' => 'Opposing account ID (matching Firefly)',
|
||||
'column_external-id' => 'External ID',
|
||||
'column_opposing-name' => 'Opposing account (name)',
|
||||
'column_rabo-debet-credit' => 'Rabobank specific debet/credit indicator',
|
||||
'column_ing-debet-credit' => 'ING specific debet/credit indicator',
|
||||
'column_rabo-debit-credit' => 'Rabobank specific debit/credit indicator',
|
||||
'column_ing-debit-credit' => 'ING specific debit/credit indicator',
|
||||
'column_sepa-ct-id' => 'SEPA Credit Transfer end-to-end ID',
|
||||
'column_sepa-ct-op' => 'SEPA Credit Transfer opposing account',
|
||||
'column_sepa-db' => 'SEPA Direct Debet',
|
||||
'column_sepa-db' => 'SEPA Direct Debit',
|
||||
'column_tags-comma' => 'Tags (comma separated)',
|
||||
'column_tags-space' => 'Tags (space separated)',
|
||||
'column_account-number' => 'Asset account (account number)',
|
||||
|
Loading…
Reference in New Issue
Block a user