mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Import routine cleanup.
This commit is contained in:
parent
445dbf8779
commit
e525e673a8
@ -17,8 +17,8 @@ use FireflyIII\Http\Requests\ImportUploadRequest;
|
|||||||
use FireflyIII\Import\Configurator\ConfiguratorInterface;
|
use FireflyIII\Import\Configurator\ConfiguratorInterface;
|
||||||
use FireflyIII\Import\Routine\ImportRoutine;
|
use FireflyIII\Import\Routine\ImportRoutine;
|
||||||
use FireflyIII\Models\ImportJob;
|
use FireflyIII\Models\ImportJob;
|
||||||
use FireflyIII\Models\Tag;
|
|
||||||
use FireflyIII\Repositories\ImportJob\ImportJobRepositoryInterface;
|
use FireflyIII\Repositories\ImportJob\ImportJobRepositoryInterface;
|
||||||
|
use FireflyIII\Repositories\Tag\TagRepositoryInterface;
|
||||||
use Illuminate\Http\Request;
|
use Illuminate\Http\Request;
|
||||||
use Illuminate\Http\Response as LaravelResponse;
|
use Illuminate\Http\Response as LaravelResponse;
|
||||||
use Log;
|
use Log;
|
||||||
@ -45,7 +45,7 @@ class ImportController extends Controller
|
|||||||
$this->middleware(
|
$this->middleware(
|
||||||
function ($request, $next) {
|
function ($request, $next) {
|
||||||
View::share('mainTitleIcon', 'fa-archive');
|
View::share('mainTitleIcon', 'fa-archive');
|
||||||
View::share('title', trans('firefly.import_data_full'));
|
View::share('title', trans('firefly.import_index_title'));
|
||||||
$this->repository = app(ImportJobRepositoryInterface::class);
|
$this->repository = app(ImportJobRepositoryInterface::class);
|
||||||
|
|
||||||
return $next($request);
|
return $next($request);
|
||||||
@ -74,7 +74,7 @@ class ImportController extends Controller
|
|||||||
}
|
}
|
||||||
$view = $configurator->getNextView();
|
$view = $configurator->getNextView();
|
||||||
$data = $configurator->getNextData();
|
$data = $configurator->getNextData();
|
||||||
$subTitle = trans('firefly.configure_import');
|
$subTitle = trans('firefly.import_config_bread_crumb');
|
||||||
$subTitleIcon = 'fa-wrench';
|
$subTitleIcon = 'fa-wrench';
|
||||||
|
|
||||||
return view($view, compact('data', 'job', 'subTitle', 'subTitleIcon'));
|
return view($view, compact('data', 'job', 'subTitle', 'subTitleIcon'));
|
||||||
@ -124,7 +124,7 @@ class ImportController extends Controller
|
|||||||
*/
|
*/
|
||||||
public function index()
|
public function index()
|
||||||
{
|
{
|
||||||
$subTitle = trans('firefly.import_data_index');
|
$subTitle = trans('firefly.import_index_sub_title');
|
||||||
$subTitleIcon = 'fa-home';
|
$subTitleIcon = 'fa-home';
|
||||||
$importFileTypes = [];
|
$importFileTypes = [];
|
||||||
$defaultImportType = config('firefly.default_import_format');
|
$defaultImportType = config('firefly.default_import_format');
|
||||||
@ -176,30 +176,31 @@ class ImportController extends Controller
|
|||||||
public function json(ImportJob $job)
|
public function json(ImportJob $job)
|
||||||
{
|
{
|
||||||
$result = [
|
$result = [
|
||||||
'started' => false,
|
'started' => false,
|
||||||
'finished' => false,
|
'finished' => false,
|
||||||
'running' => false,
|
'running' => false,
|
||||||
'errors' => array_values($job->extended_status['errors']),
|
'errors' => array_values($job->extended_status['errors']),
|
||||||
'percentage' => 0,
|
'percentage' => 0,
|
||||||
'steps' => $job->extended_status['steps'],
|
'show_percentage' => false,
|
||||||
'done' => $job->extended_status['done'],
|
'steps' => $job->extended_status['steps'],
|
||||||
'statusText' => trans('firefly.import_status_' . $job->status),
|
'done' => $job->extended_status['done'],
|
||||||
'status' => $job->status,
|
'statusText' => trans('firefly.import_status_job_' . $job->status),
|
||||||
'finishedText' => '',
|
'status' => $job->status,
|
||||||
|
'finishedText' => '',
|
||||||
];
|
];
|
||||||
|
|
||||||
if ($job->extended_status['steps'] !== 0) {
|
if ($job->extended_status['steps'] !== 0) {
|
||||||
$result['percentage'] = round(($job->extended_status['done'] / $job->extended_status['steps']) * 100, 0);
|
$result['percentage'] = round(($job->extended_status['done'] / $job->extended_status['steps']) * 100, 0);
|
||||||
|
$result['show_percentage'] = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($job->status === 'finished') {
|
if ($job->status === 'finished') {
|
||||||
// $tagId = $job->extended_status['importTag'];
|
$tagId = $job->extended_status['tag'];
|
||||||
// /** @var TagRepositoryInterface $repository */
|
/** @var TagRepositoryInterface $repository */
|
||||||
// $repository = app(TagRepositoryInterface::class);
|
$repository = app(TagRepositoryInterface::class);
|
||||||
// $tag = $repository->find($tagId);
|
$tag = $repository->find($tagId);
|
||||||
$tag = new Tag;
|
|
||||||
$result['finished'] = true;
|
$result['finished'] = true;
|
||||||
$result['finishedText'] = trans('firefly.import_finished_link', ['link' => route('tags.show', [$tag->id]), 'tag' => $tag->tag]);
|
$result['finishedText'] = trans('firefly.import_status_finished_job', ['link' => route('tags.show', [$tag->id, 'all']), 'tag' => $tag->tag]);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($job->status === 'running') {
|
if ($job->status === 'running') {
|
||||||
@ -262,7 +263,7 @@ class ImportController extends Controller
|
|||||||
if (!in_array($job->status, $statuses)) {
|
if (!in_array($job->status, $statuses)) {
|
||||||
return redirect(route('import.configure', [$job->key]));
|
return redirect(route('import.configure', [$job->key]));
|
||||||
}
|
}
|
||||||
$subTitle = trans('firefly.import_status');
|
$subTitle = trans('firefly.import_status_sub_title');
|
||||||
$subTitleIcon = 'fa-star';
|
$subTitleIcon = 'fa-star';
|
||||||
|
|
||||||
return view('import.status', compact('job', 'subTitle', 'subTitleIcon'));
|
return view('import.status', compact('job', 'subTitle', 'subTitleIcon'));
|
||||||
|
@ -469,26 +469,20 @@ Breadcrumbs::register(
|
|||||||
$breadcrumbs->push(trans('firefly.import'), route('import.index'));
|
$breadcrumbs->push(trans('firefly.import'), route('import.index'));
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
Breadcrumbs::register(
|
|
||||||
'import.complete', function (BreadCrumbGenerator $breadcrumbs, ImportJob $job) {
|
|
||||||
$breadcrumbs->parent('import.index');
|
|
||||||
$breadcrumbs->push(trans('firefly.bread_crumb_import_complete', ['key' => $job->key]), route('import.complete', [$job->key]));
|
|
||||||
}
|
|
||||||
);
|
|
||||||
Breadcrumbs::register(
|
Breadcrumbs::register(
|
||||||
'import.configure', function (BreadCrumbGenerator $breadcrumbs, ImportJob $job) {
|
'import.configure', function (BreadCrumbGenerator $breadcrumbs, ImportJob $job) {
|
||||||
$breadcrumbs->parent('import.index');
|
$breadcrumbs->parent('import.index');
|
||||||
$breadcrumbs->push(trans('firefly.bread_crumb_configure_import', ['key' => $job->key]), route('import.configure', [$job->key]));
|
$breadcrumbs->push(trans('firefly.import_config_sub_title', ['key' => $job->key]), route('import.configure', [$job->key]));
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
Breadcrumbs::register(
|
Breadcrumbs::register(
|
||||||
'import.finished', function (BreadCrumbGenerator $breadcrumbs, ImportJob $job) {
|
'import.status', function (BreadCrumbGenerator $breadcrumbs, ImportJob $job) {
|
||||||
$breadcrumbs->parent('import.index');
|
$breadcrumbs->parent('import.index');
|
||||||
$breadcrumbs->push(trans('firefly.bread_crumb_import_finished', ['key' => $job->key]), route('import.finished', [$job->key]));
|
$breadcrumbs->push(trans('firefly.import_status_bread_crumb', ['key' => $job->key]), route('import.status', [$job->key]));
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* PREFERENCES
|
* PREFERENCES
|
||||||
*/
|
*/
|
||||||
|
@ -18,7 +18,7 @@ namespace FireflyIII\Import\Converter;
|
|||||||
*
|
*
|
||||||
* @package FireflyIII\Import\Converter
|
* @package FireflyIII\Import\Converter
|
||||||
*/
|
*/
|
||||||
class Amount extends BasicConverter implements ConverterInterface
|
class Amount implements ConverterInterface
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -28,9 +28,9 @@ class Amount extends BasicConverter implements ConverterInterface
|
|||||||
*
|
*
|
||||||
* @param $value
|
* @param $value
|
||||||
*
|
*
|
||||||
* @return float
|
* @return string
|
||||||
*/
|
*/
|
||||||
public function convert($value): float
|
public function convert($value): string
|
||||||
{
|
{
|
||||||
$len = strlen($value);
|
$len = strlen($value);
|
||||||
$decimalPosition = $len - 3;
|
$decimalPosition = $len - 3;
|
||||||
@ -59,10 +59,7 @@ class Amount extends BasicConverter implements ConverterInterface
|
|||||||
$value = str_replace($search, '', $value);
|
$value = str_replace($search, '', $value);
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->setCertainty(90);
|
return strval(round(floatval($value), 12));
|
||||||
|
|
||||||
|
|
||||||
return round(floatval($value), 12);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,85 +0,0 @@
|
|||||||
<?php
|
|
||||||
/**
|
|
||||||
* BasicConverter.php
|
|
||||||
* Copyright (C) 2016 thegrumpydictator@gmail.com
|
|
||||||
*
|
|
||||||
* This software may be modified and distributed under the terms of the
|
|
||||||
* Creative Commons Attribution-ShareAlike 4.0 International License.
|
|
||||||
*
|
|
||||||
* See the LICENSE file for details.
|
|
||||||
*/
|
|
||||||
|
|
||||||
declare(strict_types=1);
|
|
||||||
|
|
||||||
namespace FireflyIII\Import\Converter;
|
|
||||||
|
|
||||||
use FireflyIII\User;
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Class BasicConverter
|
|
||||||
*
|
|
||||||
* @package FireflyIII\Import\Converter
|
|
||||||
*/
|
|
||||||
class BasicConverter
|
|
||||||
{
|
|
||||||
/** @var int */
|
|
||||||
public $certainty = 50;
|
|
||||||
/** @var array */
|
|
||||||
public $config;
|
|
||||||
/** @var bool */
|
|
||||||
public $doMap;
|
|
||||||
/** @var array */
|
|
||||||
public $mapping = [];
|
|
||||||
/** @var User */
|
|
||||||
public $user;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @return int
|
|
||||||
*/
|
|
||||||
public function getCertainty(): int
|
|
||||||
{
|
|
||||||
return $this->certainty;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param int $certainty
|
|
||||||
*/
|
|
||||||
protected function setCertainty(int $certainty)
|
|
||||||
{
|
|
||||||
$this->certainty = $certainty;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param array $config
|
|
||||||
*/
|
|
||||||
public function setConfig(array $config)
|
|
||||||
{
|
|
||||||
$this->config = $config;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param mixed $doMap
|
|
||||||
*/
|
|
||||||
public function setDoMap(bool $doMap)
|
|
||||||
{
|
|
||||||
$this->doMap = $doMap;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param array $mapping
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
public function setMapping(array $mapping)
|
|
||||||
{
|
|
||||||
$this->mapping = $mapping;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param User $user
|
|
||||||
*/
|
|
||||||
public function setUser(User $user)
|
|
||||||
{
|
|
||||||
$this->user = $user;
|
|
||||||
}
|
|
||||||
}
|
|
@ -13,8 +13,6 @@ declare(strict_types=1);
|
|||||||
|
|
||||||
namespace FireflyIII\Import\Converter;
|
namespace FireflyIII\Import\Converter;
|
||||||
|
|
||||||
use FireflyIII\User;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Interface ConverterInterface
|
* Interface ConverterInterface
|
||||||
*
|
*
|
||||||
@ -27,30 +25,4 @@ interface ConverterInterface
|
|||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
public function convert($value);
|
public function convert($value);
|
||||||
|
|
||||||
/**
|
|
||||||
* @return int
|
|
||||||
*/
|
|
||||||
public function getCertainty(): int;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param array $config
|
|
||||||
*/
|
|
||||||
public function setConfig(array $config);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param bool $doMap
|
|
||||||
*/
|
|
||||||
public function setDoMap(bool $doMap);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param array $mapping
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
public function setMapping(array $mapping);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param User $user
|
|
||||||
*/
|
|
||||||
public function setUser(User $user);
|
|
||||||
}
|
}
|
||||||
|
@ -20,7 +20,7 @@ use Log;
|
|||||||
*
|
*
|
||||||
* @package FireflyIII\Import\Converter
|
* @package FireflyIII\Import\Converter
|
||||||
*/
|
*/
|
||||||
class INGDebetCredit extends BasicConverter implements ConverterInterface
|
class INGDebetCredit implements ConverterInterface
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -34,12 +34,10 @@ class INGDebetCredit extends BasicConverter implements ConverterInterface
|
|||||||
|
|
||||||
if ($value === 'Af') {
|
if ($value === 'Af') {
|
||||||
Log::debug('Return -1');
|
Log::debug('Return -1');
|
||||||
$this->setCertainty(100);
|
|
||||||
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
$this->setCertainty(100);
|
|
||||||
Log::debug('Return 1');
|
Log::debug('Return 1');
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
|
@ -20,7 +20,7 @@ use Log;
|
|||||||
*
|
*
|
||||||
* @package FireflyIII\Import\Converter
|
* @package FireflyIII\Import\Converter
|
||||||
*/
|
*/
|
||||||
class RabobankDebetCredit extends BasicConverter implements ConverterInterface
|
class RabobankDebetCredit implements ConverterInterface
|
||||||
{
|
{
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -34,13 +34,11 @@ class RabobankDebetCredit extends BasicConverter implements ConverterInterface
|
|||||||
|
|
||||||
if ($value === 'D') {
|
if ($value === 'D') {
|
||||||
Log::debug('Return -1');
|
Log::debug('Return -1');
|
||||||
$this->setCertainty(100);
|
|
||||||
|
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
Log::debug('Return 1');
|
Log::debug('Return 1');
|
||||||
$this->setCertainty(100);
|
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
@ -1,86 +0,0 @@
|
|||||||
<?php
|
|
||||||
/**
|
|
||||||
* TagSplit.php
|
|
||||||
* Copyright (C) 2016 thegrumpydictator@gmail.com
|
|
||||||
*
|
|
||||||
* This software may be modified and distributed under the terms of the
|
|
||||||
* Creative Commons Attribution-ShareAlike 4.0 International License.
|
|
||||||
*
|
|
||||||
* See the LICENSE file for details.
|
|
||||||
*/
|
|
||||||
|
|
||||||
declare(strict_types=1);
|
|
||||||
|
|
||||||
namespace FireflyIII\Import\Converter;
|
|
||||||
|
|
||||||
use FireflyIII\Repositories\Tag\TagRepositoryInterface;
|
|
||||||
use FireflyIII\User;
|
|
||||||
use Illuminate\Support\Collection;
|
|
||||||
use Log;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Class TagSplit
|
|
||||||
*
|
|
||||||
* @package FireflyIII\Import\Converter
|
|
||||||
*/
|
|
||||||
class TagSplit
|
|
||||||
{
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param User $user
|
|
||||||
* @param array $mapping
|
|
||||||
* @param array $parts
|
|
||||||
*
|
|
||||||
* @return Collection
|
|
||||||
*/
|
|
||||||
public static function createSetFromSplits(User $user, array $mapping, array $parts): Collection
|
|
||||||
{
|
|
||||||
$set = new Collection;
|
|
||||||
Log::debug('Exploded parts.', $parts);
|
|
||||||
|
|
||||||
/** @var TagRepositoryInterface $repository */
|
|
||||||
$repository = app(TagRepositoryInterface::class);
|
|
||||||
$repository->setUser($user);
|
|
||||||
|
|
||||||
|
|
||||||
/** @var string $part */
|
|
||||||
foreach ($parts as $part) {
|
|
||||||
if (isset($mapping[$part])) {
|
|
||||||
Log::debug('Found tag in mapping. Should exist.', ['value' => $part, 'map' => $mapping[$part]]);
|
|
||||||
$tag = $repository->find(intval($mapping[$part]));
|
|
||||||
if (!is_null($tag->id)) {
|
|
||||||
Log::debug('Found tag by ID', ['id' => $tag->id]);
|
|
||||||
|
|
||||||
$set->push($tag);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// not mapped? Still try to find it first:
|
|
||||||
$tag = $repository->findByTag($part);
|
|
||||||
if (!is_null($tag->id)) {
|
|
||||||
Log::debug('Found tag by name ', ['id' => $tag->id]);
|
|
||||||
|
|
||||||
$set->push($tag);
|
|
||||||
}
|
|
||||||
if (is_null($tag->id)) {
|
|
||||||
// create new tag
|
|
||||||
$tag = $repository->store(
|
|
||||||
[
|
|
||||||
'tag' => $part,
|
|
||||||
'date' => null,
|
|
||||||
'description' => $part,
|
|
||||||
'latitude' => null,
|
|
||||||
'longitude' => null,
|
|
||||||
'zoomLevel' => null,
|
|
||||||
'tagMode' => 'nothing',
|
|
||||||
]
|
|
||||||
);
|
|
||||||
Log::debug('Created new tag', ['name' => $part, 'id' => $tag->id]);
|
|
||||||
$set->push($tag);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return $set;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
@ -1,48 +0,0 @@
|
|||||||
<?php
|
|
||||||
/**
|
|
||||||
* TagsComma.php
|
|
||||||
* Copyright (C) 2016 thegrumpydictator@gmail.com
|
|
||||||
*
|
|
||||||
* This software may be modified and distributed under the terms of the
|
|
||||||
* Creative Commons Attribution-ShareAlike 4.0 International License.
|
|
||||||
*
|
|
||||||
* See the LICENSE file for details.
|
|
||||||
*/
|
|
||||||
|
|
||||||
declare(strict_types=1);
|
|
||||||
|
|
||||||
namespace FireflyIII\Import\Converter;
|
|
||||||
|
|
||||||
use Illuminate\Support\Collection;
|
|
||||||
use Log;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Class TagsComma
|
|
||||||
*
|
|
||||||
* @package FireflyIII\Import\Converter
|
|
||||||
*/
|
|
||||||
class TagsComma extends BasicConverter implements ConverterInterface
|
|
||||||
{
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param $value
|
|
||||||
*
|
|
||||||
* @return Collection
|
|
||||||
*/
|
|
||||||
public function convert($value)
|
|
||||||
{
|
|
||||||
$value = trim($value);
|
|
||||||
Log::debug('Going to convert using TagsComma', ['value' => $value]);
|
|
||||||
|
|
||||||
if (strlen($value) === 0) {
|
|
||||||
$this->setCertainty(0);
|
|
||||||
|
|
||||||
return new Collection;
|
|
||||||
}
|
|
||||||
$parts = array_unique(explode(',', $value));
|
|
||||||
$set = TagSplit::createSetFromSplits($this->user, $this->mapping, $parts);
|
|
||||||
$this->setCertainty(100);
|
|
||||||
|
|
||||||
return $set;
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,49 +0,0 @@
|
|||||||
<?php
|
|
||||||
/**
|
|
||||||
* TagsSpace.php
|
|
||||||
* Copyright (C) 2016 thegrumpydictator@gmail.com
|
|
||||||
*
|
|
||||||
* This software may be modified and distributed under the terms of the
|
|
||||||
* Creative Commons Attribution-ShareAlike 4.0 International License.
|
|
||||||
*
|
|
||||||
* See the LICENSE file for details.
|
|
||||||
*/
|
|
||||||
|
|
||||||
declare(strict_types=1);
|
|
||||||
|
|
||||||
namespace FireflyIII\Import\Converter;
|
|
||||||
|
|
||||||
use Illuminate\Support\Collection;
|
|
||||||
use Log;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Class TagsSpace
|
|
||||||
*
|
|
||||||
* @package FireflyIII\Import\Converter
|
|
||||||
*/
|
|
||||||
class TagsSpace extends BasicConverter implements ConverterInterface
|
|
||||||
{
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param $value
|
|
||||||
*
|
|
||||||
* @return Collection
|
|
||||||
*/
|
|
||||||
public function convert($value)
|
|
||||||
{
|
|
||||||
$value = trim($value);
|
|
||||||
Log::debug('Going to convert using TagsSpace', ['value' => $value]);
|
|
||||||
|
|
||||||
if (strlen($value) === 0) {
|
|
||||||
$this->setCertainty(0);
|
|
||||||
|
|
||||||
return new Collection;
|
|
||||||
}
|
|
||||||
$parts = array_unique(explode(' ', $value));
|
|
||||||
$set = TagSplit::createSetFromSplits($this->user, $this->mapping, $parts);
|
|
||||||
$this->setCertainty(100);
|
|
||||||
|
|
||||||
return $set;
|
|
||||||
|
|
||||||
}
|
|
||||||
}
|
|
@ -70,6 +70,7 @@ class CsvProcessor implements FileProcessorInterface
|
|||||||
$index = 0;
|
$index = 0;
|
||||||
Log::notice('Building importable objects from CSV file.');
|
Log::notice('Building importable objects from CSV file.');
|
||||||
foreach ($entries as $index => $row) {
|
foreach ($entries as $index => $row) {
|
||||||
|
sleep(1);
|
||||||
// verify if not exists already:
|
// verify if not exists already:
|
||||||
if ($this->rowAlreadyImported($row)) {
|
if ($this->rowAlreadyImported($row)) {
|
||||||
$message = sprintf('Row #%d has already been imported.', $index);
|
$message = sprintf('Row #%d has already been imported.', $index);
|
||||||
|
@ -50,7 +50,7 @@ class AssetAccountIbans implements MapperInterface
|
|||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = $topList + $list;
|
$list = $topList + $list;
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
|
||||||
|
@ -47,7 +47,7 @@ class AssetAccounts implements MapperInterface
|
|||||||
|
|
||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
|
||||||
|
@ -40,7 +40,7 @@ class Bills implements MapperInterface
|
|||||||
}
|
}
|
||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ class Budgets implements MapperInterface
|
|||||||
}
|
}
|
||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ class Categories implements MapperInterface
|
|||||||
}
|
}
|
||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
|
||||||
|
@ -56,7 +56,7 @@ class OpposingAccountIbans implements MapperInterface
|
|||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = $topList + $list;
|
$list = $topList + $list;
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
@ -53,7 +53,7 @@ class OpposingAccounts implements MapperInterface
|
|||||||
|
|
||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
}
|
}
|
||||||
|
@ -40,7 +40,7 @@ class Tags implements MapperInterface
|
|||||||
}
|
}
|
||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
|
||||||
|
@ -36,7 +36,7 @@ class TransactionCurrencies implements MapperInterface
|
|||||||
|
|
||||||
asort($list);
|
asort($list);
|
||||||
|
|
||||||
$list = [0 => trans('csv.do_not_map')] + $list;
|
$list = [0 => trans('csv.map_do_not_map')] + $list;
|
||||||
|
|
||||||
return $list;
|
return $list;
|
||||||
|
|
||||||
|
@ -104,7 +104,7 @@ class ImportJournal
|
|||||||
|
|
||||||
/** @var ConverterInterface $amountConverter */
|
/** @var ConverterInterface $amountConverter */
|
||||||
$amountConverter = app(Amount::class);
|
$amountConverter = app(Amount::class);
|
||||||
$this->amount = strval($amountConverter->convert($this->amount));
|
$this->amount = $amountConverter->convert($this->amount);
|
||||||
// modify
|
// modify
|
||||||
foreach ($this->modifiers as $modifier) {
|
foreach ($this->modifiers as $modifier) {
|
||||||
$class = sprintf('FireflyIII\Import\Converter\%s', config(sprintf('csv.import_roles.%s.converter', $modifier['role'])));
|
$class = sprintf('FireflyIII\Import\Converter\%s', config(sprintf('csv.import_roles.%s.converter', $modifier['role'])));
|
||||||
|
@ -12,9 +12,13 @@ declare(strict_types=1);
|
|||||||
namespace FireflyIII\Import\Routine;
|
namespace FireflyIII\Import\Routine;
|
||||||
|
|
||||||
|
|
||||||
|
use Carbon\Carbon;
|
||||||
use FireflyIII\Import\FileProcessor\FileProcessorInterface;
|
use FireflyIII\Import\FileProcessor\FileProcessorInterface;
|
||||||
use FireflyIII\Import\Storage\ImportStorage;
|
use FireflyIII\Import\Storage\ImportStorage;
|
||||||
use FireflyIII\Models\ImportJob;
|
use FireflyIII\Models\ImportJob;
|
||||||
|
use FireflyIII\Models\Tag;
|
||||||
|
use FireflyIII\Models\TransactionJournal;
|
||||||
|
use FireflyIII\Repositories\Tag\TagRepositoryInterface;
|
||||||
use Illuminate\Support\Collection;
|
use Illuminate\Support\Collection;
|
||||||
use Log;
|
use Log;
|
||||||
|
|
||||||
@ -53,8 +57,37 @@ class ImportRoutine
|
|||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
set_time_limit(0);
|
||||||
Log::debug(sprintf('Start with import job %s', $this->job->key));
|
Log::debug(sprintf('Start with import job %s', $this->job->key));
|
||||||
|
|
||||||
|
$importObjects = $this->getImportObjects();
|
||||||
|
$this->lines = $importObjects->count();
|
||||||
|
|
||||||
|
// once done, use storage thing to actually store them:
|
||||||
|
Log::debug(sprintf('Returned %d valid objects from file processor', $this->lines));
|
||||||
|
|
||||||
|
$storage = $this->storeObjects($importObjects);
|
||||||
|
|
||||||
|
// update job:
|
||||||
|
$this->job->status = 'finished';
|
||||||
|
$this->job->save();
|
||||||
|
|
||||||
|
$this->journals = $storage->journals;
|
||||||
|
$this->errors = $storage->errors;
|
||||||
|
|
||||||
|
// create tag, link tag to all journals:
|
||||||
|
$this->createImportTag();
|
||||||
|
|
||||||
|
Log::debug(sprintf('Done with import job %s', $this->job->key));
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return Collection
|
||||||
|
*/
|
||||||
|
protected function getImportObjects(): Collection
|
||||||
|
{
|
||||||
$objects = new Collection;
|
$objects = new Collection;
|
||||||
$type = $this->job->file_type;
|
$type = $this->job->file_type;
|
||||||
$class = config(sprintf('firefly.import_processors.%s', $type));
|
$class = config(sprintf('firefly.import_processors.%s', $type));
|
||||||
@ -62,7 +95,6 @@ class ImportRoutine
|
|||||||
$processor = app($class);
|
$processor = app($class);
|
||||||
$processor->setJob($this->job);
|
$processor->setJob($this->job);
|
||||||
|
|
||||||
set_time_limit(0);
|
|
||||||
if ($this->job->status == 'configured') {
|
if ($this->job->status == 'configured') {
|
||||||
|
|
||||||
// set job as "running"...
|
// set job as "running"...
|
||||||
@ -73,28 +105,56 @@ class ImportRoutine
|
|||||||
$processor->run();
|
$processor->run();
|
||||||
$objects = $processor->getObjects();
|
$objects = $processor->getObjects();
|
||||||
}
|
}
|
||||||
$this->lines = $objects->count();
|
|
||||||
// once done, use storage thing to actually store them:
|
|
||||||
Log::debug(sprintf('Returned %d valid objects from file processor', $this->lines));
|
|
||||||
|
|
||||||
|
return $objects;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
private function createImportTag(): Tag
|
||||||
|
{
|
||||||
|
/** @var TagRepositoryInterface $repository */
|
||||||
|
$repository = app(TagRepositoryInterface::class);
|
||||||
|
$repository->setUser($this->job->user);
|
||||||
|
$data = [
|
||||||
|
'tag' => trans('firefly.import_with_key', ['key' => $this->job->key]),
|
||||||
|
'date' => new Carbon,
|
||||||
|
'description' => null,
|
||||||
|
'latitude' => null,
|
||||||
|
'longitude' => null,
|
||||||
|
'zoomLevel' => null,
|
||||||
|
'tagMode' => 'nothing',
|
||||||
|
];
|
||||||
|
$tag = $repository->store($data);
|
||||||
|
$extended = $this->job->extended_status;
|
||||||
|
$extended['tag'] = $tag->id;
|
||||||
|
$this->job->extended_status = $extended;
|
||||||
|
$this->job->save();
|
||||||
|
|
||||||
|
$this->journals->each(
|
||||||
|
function (TransactionJournal $journal) use ($tag) {
|
||||||
|
$journal->tags()->save($tag);
|
||||||
|
}
|
||||||
|
);
|
||||||
|
|
||||||
|
return $tag;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param Collection $objects
|
||||||
|
*
|
||||||
|
* @return ImportStorage
|
||||||
|
*/
|
||||||
|
private function storeObjects(Collection $objects): ImportStorage
|
||||||
|
{
|
||||||
$storage = new ImportStorage;
|
$storage = new ImportStorage;
|
||||||
$storage->setJob($this->job);
|
$storage->setJob($this->job);
|
||||||
$storage->setDateFormat($this->job->configuration['date-format']);
|
$storage->setDateFormat($this->job->configuration['date-format']);
|
||||||
$storage->setObjects($objects);
|
$storage->setObjects($objects);
|
||||||
$storage->store();
|
$storage->store();
|
||||||
|
|
||||||
// update job:
|
return $storage;
|
||||||
$this->job->status = 'finished';
|
|
||||||
$this->job->save();
|
|
||||||
|
|
||||||
$this->journals = $storage->journals;
|
|
||||||
$this->errors = $storage->errors;
|
|
||||||
|
|
||||||
// run rules:
|
|
||||||
|
|
||||||
|
|
||||||
Log::debug(sprintf('Done with import job %s', $this->job->key));
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -99,7 +99,7 @@ class ImportStorage
|
|||||||
* @var ImportJournal $object
|
* @var ImportJournal $object
|
||||||
*/
|
*/
|
||||||
foreach ($this->objects as $index => $object) {
|
foreach ($this->objects as $index => $object) {
|
||||||
sleep(4);
|
sleep(1);
|
||||||
Log::debug(sprintf('Going to store object #%d with description "%s"', $index, $object->description));
|
Log::debug(sprintf('Going to store object #%d with description "%s"', $index, $object->description));
|
||||||
|
|
||||||
$errors = new MessageBag;
|
$errors = new MessageBag;
|
||||||
|
@ -60,10 +60,10 @@ class ImportJobRepository implements ImportJobRepositoryInterface
|
|||||||
$importJob->status = 'new';
|
$importJob->status = 'new';
|
||||||
$importJob->configuration = [];
|
$importJob->configuration = [];
|
||||||
$importJob->extended_status = [
|
$importJob->extended_status = [
|
||||||
'steps' => 0,
|
'steps' => 0,
|
||||||
'done' => 0,
|
'done' => 0,
|
||||||
'importTag' => 0,
|
'tag' => 0,
|
||||||
'errors' => [],
|
'errors' => [],
|
||||||
];
|
];
|
||||||
$importJob->save();
|
$importJob->save();
|
||||||
|
|
||||||
|
@ -50,10 +50,10 @@ function failedJobImport(jqxhr, textStatus, error) {
|
|||||||
// fill in some details:
|
// fill in some details:
|
||||||
var errorMessage = textStatus + " " + error;
|
var errorMessage = textStatus + " " + error;
|
||||||
|
|
||||||
$('.import_error_txt').text(errorMessage);
|
$('.fatal_error_txt').text(errorMessage);
|
||||||
|
|
||||||
// show the error box:
|
// show the fatal error box:
|
||||||
$('.errorbox').show();
|
$('.fatal_error').show();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -98,6 +98,7 @@ function reportOnJobImport(data) {
|
|||||||
$('.statusbox').hide();
|
$('.statusbox').hide();
|
||||||
$('.status_finished').show();
|
$('.status_finished').show();
|
||||||
// show text:
|
// show text:
|
||||||
|
$('#import-status-more-info').html(data.finishedText);
|
||||||
|
|
||||||
|
|
||||||
break;
|
break;
|
||||||
@ -105,12 +106,12 @@ function reportOnJobImport(data) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Shows an error when the job seems to be stalled.
|
* Shows a fatal error when the job seems to be stalled.
|
||||||
*/
|
*/
|
||||||
function showStalledBox() {
|
function showStalledBox() {
|
||||||
$('.statusbox').hide();
|
$('.statusbox').hide();
|
||||||
$('.errorbox').show();
|
$('.fatal_error').show();
|
||||||
$('.import_error_txt').text(langImportTimeOutError);
|
$('.fatal_error_txt').text(langImportTimeOutError);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -156,12 +157,12 @@ function reportOnSubmitError() {
|
|||||||
$('.statusbox').hide();
|
$('.statusbox').hide();
|
||||||
|
|
||||||
// fill in some details:
|
// fill in some details:
|
||||||
var errorMessage = "Time out.";
|
var errorMessage = "Time out while waiting for job to finish.";
|
||||||
|
|
||||||
$('.import_error_txt').text(errorMessage);
|
$('.fatal_error_txt').text(errorMessage);
|
||||||
|
|
||||||
// show the error box:
|
// show the fatal error box:
|
||||||
$('.errorbox').show();
|
$('.fatal_error').show();
|
||||||
jobFailed = true;
|
jobFailed = true;
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -172,7 +173,7 @@ function reportOnSubmitError() {
|
|||||||
function updateBar(data) {
|
function updateBar(data) {
|
||||||
console.log('updateBar()');
|
console.log('updateBar()');
|
||||||
var bar = $('#import-status-bar');
|
var bar = $('#import-status-bar');
|
||||||
if (data.percentage > 0) {
|
if (data.show_percentage) {
|
||||||
console.log('Going to update bar with percentage.');
|
console.log('Going to update bar with percentage.');
|
||||||
bar.addClass('progress-bar-success').removeClass('progress-bar-info');
|
bar.addClass('progress-bar-success').removeClass('progress-bar-info');
|
||||||
bar.attr('aria-valuenow', data.percentage);
|
bar.attr('aria-valuenow', data.percentage);
|
||||||
|
@ -14,39 +14,36 @@ declare(strict_types=1);
|
|||||||
return [
|
return [
|
||||||
|
|
||||||
// initial config
|
// initial config
|
||||||
'initial_config_title' => 'Import configuration (1/3)',
|
'initial_title' => 'Import setup (1/3) - Basic CSV import setup',
|
||||||
'initial_config_text' => 'To be able to import your file correctly, please validate the options below.',
|
'initial_text' => 'To be able to import your file correctly, please validate the options below.',
|
||||||
'initial_config_box' => 'Basic CSV import configuration',
|
'initial_box' => 'Basic CSV import setup',
|
||||||
'initial_header_help' => 'Check this box if the first row of your CSV file are the column titles.',
|
'initial_header_help' => 'Check this box if the first row of your CSV file are the column titles.',
|
||||||
'initial_date_help' => 'Date time format in your CSV. Follow the format like <a href="https://secure.php.net/manual/en/datetime.createfromformat.php#refsect1-datetime.createfromformat-parameters">this page</a> indicates. The default value will parse dates that look like this: :dateExample.',
|
'initial_date_help' => 'Date time format in your CSV. Follow the format like <a href="https://secure.php.net/manual/en/datetime.createfromformat.php#refsect1-datetime.createfromformat-parameters">this page</a> indicates. The default value will parse dates that look like this: :dateExample.',
|
||||||
'initial_delimiter_help' => 'Choose the field delimiter that is used in your input file. If not sure, comma is the safest option.',
|
'initial_delimiter_help' => 'Choose the field delimiter that is used in your input file. If not sure, comma is the safest option.',
|
||||||
'initial_import_account_help' => 'If your CSV file does NOT contain information about your asset account(s), use this dropdown to select to which account the transactions in the CSV belong to.',
|
'initial_import_account_help' => 'If your CSV file does NOT contain information about your asset account(s), use this dropdown to select to which account the transactions in the CSV belong to.',
|
||||||
|
'initial_submit' => 'Continue with step 2/3',
|
||||||
|
|
||||||
// roles config
|
// roles config
|
||||||
'roles_title' => 'Define each column\'s role',
|
'roles_title' => 'Import setup (2/3) - Define each column\'s role',
|
||||||
'roles_text' => 'Each column in your CSV file contains certain data. Please indicate what kind of data the importer should expect. The option to "map" data means that you will link each entry found in the column to a value in your database. An often mapped column is the column that contains the IBAN of the opposing account. That can be easily matched to IBAN\'s present in your database already.',
|
'roles_text' => 'Each column in your CSV file contains certain data. Please indicate what kind of data the importer should expect. The option to "map" data means that you will link each entry found in the column to a value in your database. An often mapped column is the column that contains the IBAN of the opposing account. That can be easily matched to IBAN\'s present in your database already.',
|
||||||
'roles_table' => 'Table',
|
'roles_table' => 'Table',
|
||||||
'roles_column_name' => 'Name of column',
|
'roles_column_name' => 'Name of column',
|
||||||
'roles_column_example' => 'Column example data',
|
'roles_column_example' => 'Column example data',
|
||||||
'roles_column_role' => 'Column data meaning',
|
'roles_column_role' => 'Column data meaning',
|
||||||
'roles_do_map_value' => 'Map these values',
|
'roles_do_map_value' => 'Map these values',
|
||||||
'roles_column' => 'Column',
|
'roles_column' => 'Column',
|
||||||
'roles_no_example_data' => 'No example data available',
|
'roles_no_example_data' => 'No example data available',
|
||||||
|
'roles_submit' => 'Continue with step 3/3',
|
||||||
'roles_store' => 'Continue import',
|
|
||||||
'roles_do_not_map' => '(do not map)',
|
|
||||||
|
|
||||||
// map data
|
// map data
|
||||||
'map_title' => 'Connect import data to Firefly III data',
|
'map_title' => 'Import setup (3/3) - Connect import data to Firefly III data',
|
||||||
'map_text' => 'In the following tables, the left value shows you information found in your uploaded CSV file. It is your task to map this value, if possible, to a value already present in your database. Firefly will stick to this mapping. If there is no value to map to, or you do not wish to map the specific value, select nothing.',
|
'map_text' => 'In the following tables, the left value shows you information found in your uploaded CSV file. It is your task to map this value, if possible, to a value already present in your database. Firefly will stick to this mapping. If there is no value to map to, or you do not wish to map the specific value, select nothing.',
|
||||||
|
'map_field_value' => 'Field value',
|
||||||
'field_value' => 'Field value',
|
'map_field_mapped_to' => 'Mapped to',
|
||||||
'field_mapped_to' => 'Mapped to',
|
'map_do_not_map' => '(do not map)',
|
||||||
'store_column_mapping' => 'Store mapping',
|
'map_submit' => 'Start the import',
|
||||||
|
|
||||||
// map things.
|
// map things.
|
||||||
|
|
||||||
|
|
||||||
'column__ignore' => '(ignore this column)',
|
'column__ignore' => '(ignore this column)',
|
||||||
'column_account-iban' => 'Asset account (IBAN)',
|
'column_account-iban' => 'Asset account (IBAN)',
|
||||||
'column_account-id' => 'Asset account ID (matching Firefly)',
|
'column_account-id' => 'Asset account ID (matching Firefly)',
|
||||||
|
@ -966,53 +966,51 @@ return [
|
|||||||
'cannot_edit_opening_balance' => 'You cannot edit the opening balance of an account.',
|
'cannot_edit_opening_balance' => 'You cannot edit the opening balance of an account.',
|
||||||
'no_edit_multiple_left' => 'You have selected no valid transactions to edit.',
|
'no_edit_multiple_left' => 'You have selected no valid transactions to edit.',
|
||||||
|
|
||||||
// import
|
// import bread crumbs and titles:
|
||||||
'configuration_file_help' => 'If you have previously imported data into Firefly III, you may have a configuration file, which will pre-set configuration values for you. For some banks, other users have kindly provided their <a href="https://github.com/firefly-iii/import-configurations/wiki">configuration file</a>.',
|
|
||||||
'import_data_index' => 'Index',
|
|
||||||
'import_file_type_csv' => 'CSV (comma separated values)',
|
|
||||||
'import_file_type_help' => 'Select the type of file you will upload',
|
|
||||||
'import_start' => 'Start the import',
|
|
||||||
'configure_import' => 'Further configure your import',
|
|
||||||
'import_finish_configuration' => 'Finish configuration',
|
|
||||||
'settings_for_import' => 'Settings',
|
|
||||||
'import_status' => 'Import status',
|
|
||||||
'import_status_text' => 'The import is currently running, or will start momentarily.',
|
|
||||||
'import_complete' => 'Import configuration complete!',
|
|
||||||
'import_complete_text' => 'The import is ready to start. All the configuration you needed to do has been done. Please download the configuration file. It will help you with the import should it not go as planned. To actually run the import, you can either execute the following command in your console, or run the web-based import. Depending on your configuration, the console import will give you more feedback.',
|
|
||||||
'import_download_config' => 'Download configuration',
|
|
||||||
'import_start_import' => 'Start import',
|
|
||||||
'import_data' => 'Import data',
|
|
||||||
'import_data_full' => 'Import data into Firefly III',
|
|
||||||
'import' => 'Import',
|
'import' => 'Import',
|
||||||
'import_file_help' => 'Select your file',
|
'import_data' => 'Import data',
|
||||||
'import_status_settings_complete' => 'The import is ready to start.',
|
|
||||||
'import_status_import_complete' => 'The import has completed.',
|
// import index page:
|
||||||
'import_status_running' => 'The import is currently running. Please be patient.',
|
'import_index_title' => 'Import data into Firefly III',
|
||||||
'import_status_header' => 'Import status and progress',
|
'import_index_sub_title' => 'Index',
|
||||||
'import_status_errors' => 'Import errors',
|
'import_index_intro' => 'Welcome to Firefly\'s import routine. These pages can help you import data from your bank into Firefly III. Please check out the help pages in the top right corner.',
|
||||||
'import_status_report' => 'Import report',
|
'import_index_file' => 'Select your file',
|
||||||
'import_finished' => 'Import has finished',
|
'import_index_config' => 'If you have previously imported data into Firefly III, you may have a configuration file, which will pre-set configuration values for you. For some banks, other users have kindly provided their <a href="https://github.com/firefly-iii/import-configurations/wiki">configuration file</a>.',
|
||||||
'import_error_single' => 'An error has occured during the import.',
|
'import_index_type' => 'Select the type of file you will upload',
|
||||||
'import_error_multi' => 'Some errors occured during the import.',
|
'import_index_start' => 'Start importing',
|
||||||
'import_error_fatal' => 'There was an error during the import routine. Please check the log files. The error seems to be:',
|
|
||||||
'import_error_timeout' => 'The import seems to have timed out. If this error persists, please import your data using the console command.',
|
// supported file types:
|
||||||
'import_double' => 'Row #:row: This row has been imported before, and is stored in <a href=":link">:description</a>.',
|
'import_file_type_csv' => 'CSV (comma separated values)',
|
||||||
'import_finished_all' => 'The import has finished. Please check out the results below.',
|
|
||||||
|
// import configuration routine:
|
||||||
|
'import_config_sub_title' => 'Set up your import file',
|
||||||
|
'import_config_bread_crumb' => 'Set up your import file',
|
||||||
|
|
||||||
|
// import status page:
|
||||||
|
'import_status_bread_crumb' => 'Import status',
|
||||||
|
'import_status_sub_title' => 'Import status',
|
||||||
|
'import_status_wait_title' => 'Please hold...',
|
||||||
|
'import_status_wait_text' => 'This box will disappear in a moment.',
|
||||||
|
'import_status_ready_title' => 'Import is ready to start',
|
||||||
|
'import_status_ready_text' => 'The import is ready to start. All the configuration you needed to do has been done. Please download the configuration file. It will help you with the import should it not go as planned. To actually run the import, you can either execute the following command in your console, or run the web-based import. Depending on your configuration, the console import will give you more feedback.',
|
||||||
|
'import_status_ready_config' => 'Download configuration',
|
||||||
|
'import_status_ready_start' => 'Start the import',
|
||||||
|
'import_status_ready_share' => 'Please consider downloading your configuration and sharing it at the <strong><a href="https://github.com/firefly-iii/import-configurations/wiki">import configuration center</a></strong>. This will allow other users of Firefly III to import their files more easily.',
|
||||||
|
'import_status_running_title' => 'The import is running',
|
||||||
|
'import_status_running_placeholder' => 'Please hold for an update...',
|
||||||
|
'import_status_errors_title' => 'Errors during the import',
|
||||||
|
'import_status_errors_single' => 'An error has occured during the import. It does not appear to be fatal.',
|
||||||
|
'import_status_errors_multi' => 'Some errors occured during the import. These do not appear to be fatal.',
|
||||||
|
'import_status_fatal_title' => 'A fatal error occurred',
|
||||||
|
'import_status_fatal_text' => 'A fatal error occurred, which the import-routine cannot recover from. Please see the explanation in red below.',
|
||||||
|
'import_status_fatal_more' => 'If the error is a time-out, the import will have stopped half-way. For some server configurations, it is merely the server that stopped while the import keeps running in the background. To verify this, check out the log files. If the problem persists, consider importing over the command line instead.',
|
||||||
|
'import_status_finished_title' => 'Import routine finished',
|
||||||
|
'import_status_finished_text' => 'The import routine has imported your file.',
|
||||||
|
'import_status_finished_job' => 'The transactions imported can be found in tag <a href=":link" class="label label-success" style="font-size:100%;font-weight:normal;">:tag</a>.',
|
||||||
'import_with_key' => 'Import with key \':key\'',
|
'import_with_key' => 'Import with key \':key\'',
|
||||||
'import_share_configuration' => 'Please consider downloading your configuration and sharing it at the <strong><a href="https://github.com/firefly-iii/import-configurations/wiki">import configuration center</a></strong>. This will allow other users of Firefly III to import their files more easily.',
|
|
||||||
'import_finished_report' => 'The import has finished. Please note any errors in the block above this line. All transactions imported during this particular session have been tagged, and you can check them out below. ',
|
// different states:
|
||||||
'import_finished_link' => 'The transactions imported can be found in tag <a href=":link" class="label label-success" style="font-size:100%;font-weight:normal;">:tag</a>.',
|
'import_status_job_running' => 'The import is underway. Please be patient...',
|
||||||
'need_at_least_one_account' => 'You need at least one asset account to be able to create piggy banks',
|
|
||||||
'bread_crumb_import_complete' => 'Import ":key" complete',
|
|
||||||
'bread_crumb_configure_import' => 'Configure import ":key"',
|
|
||||||
'bread_crumb_import_finished' => 'Import ":key" finished',
|
|
||||||
'import_finished_intro' => 'The import has finished! You can now see the new transactions in Firefly.',
|
|
||||||
'import_finished_text_without_link' => 'It seems there is no tag that points to all your imported transactions. Please look for your imported data in the menu on the left, under "Transactions".',
|
|
||||||
'import_finished_text_with_link' => 'You can find a list of your imported transactions on the page of the <a href="tags/show/:tag">tag that was created for this import</a>.',
|
|
||||||
'please_wait_for_status' => 'Please wait for Firefly III to check on your import',
|
|
||||||
'box_will_refresh' => 'This box will auto-refresh...',
|
|
||||||
'import_job_status' => 'Import routine status..',
|
|
||||||
'see_help_top_right' => 'Welcome to Firefly\'s import routine. Please check out the help pages in the top right corner.',
|
|
||||||
|
|
||||||
// sandstorm.io errors and messages:
|
// sandstorm.io errors and messages:
|
||||||
'sandstorm_not_available' => 'This function is not available when you are using Firefly III within a Sandstorm.io environment.',
|
'sandstorm_not_available' => 'This function is not available when you are using Firefly III within a Sandstorm.io environment.',
|
||||||
|
@ -1,44 +0,0 @@
|
|||||||
{% extends "./layout/default" %}
|
|
||||||
|
|
||||||
{% block breadcrumbs %}
|
|
||||||
{{ Breadcrumbs.renderIfExists }}
|
|
||||||
{% endblock %}
|
|
||||||
{% block content %}
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
|
||||||
<div class="box box-default">
|
|
||||||
<div class="box-header with-border">
|
|
||||||
<h3 class="box-title">{{ 'import_complete'|_ }}</h3>
|
|
||||||
</div>
|
|
||||||
<div class="box-body">
|
|
||||||
<p>
|
|
||||||
{{ 'import_complete_text'|_ }}
|
|
||||||
</p>
|
|
||||||
<p>
|
|
||||||
<code>php artisan firefly:start-import {{ job.key }}</code>
|
|
||||||
</p>
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-lg-4">
|
|
||||||
<a href="{{ route('import.download', [job.key]) }}" class="btn btn-default"><i
|
|
||||||
class="fa fa-fw fa-download"></i> {{ 'import_download_config'|_ }}</a>
|
|
||||||
</div>
|
|
||||||
<div class="col-lg-4">
|
|
||||||
<a href="{{ route('import.status', [job.key]) }}" class="btn btn-success"><i
|
|
||||||
class="fa fa-fw fa-gears"></i> {{ 'import_start_import'|_ }}</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<p>
|
|
||||||
|
|
||||||
</p>
|
|
||||||
<p class="text-info">
|
|
||||||
{{ 'import_share_configuration'|_ }}
|
|
||||||
</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{% endblock %}
|
|
||||||
{% block scripts %}
|
|
||||||
{% endblock %}
|
|
||||||
{% block styles %}
|
|
||||||
{% endblock %}
|
|
@ -10,11 +10,11 @@
|
|||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="box">
|
<div class="box">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ trans('csv.initial_config_title') }}</h3>
|
<h3 class="box-title">{{ trans('csv.initial_title') }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<p>
|
<p>
|
||||||
{{ trans('csv.initial_config_text') }}
|
{{ trans('csv.initial_text') }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -29,7 +29,7 @@
|
|||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="box">
|
<div class="box">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ trans('csv.initial_config_box') }}</h3>
|
<h3 class="box-title">{{ trans('csv.initial_box_title') }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@ -67,7 +67,7 @@
|
|||||||
<div class="box">
|
<div class="box">
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<button type="submit" class="pull-right btn btn-success">
|
<button type="submit" class="pull-right btn btn-success">
|
||||||
{{ 'import_finish_configuration'|_ }}
|
{{ trans('csv.initial_submit') }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -36,8 +36,8 @@
|
|||||||
<table class="table table-hover">
|
<table class="table table-hover">
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th style="width:50%;">{{ trans('csv.field_value') }}</th>
|
<th style="width:50%;">{{ trans('csv.map_field_value') }}</th>
|
||||||
<th>{{ trans('csv.field_mapped_to') }}</th>
|
<th>{{ trans('csv.map_field_mapped_to') }}</th>
|
||||||
</tr>
|
</tr>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
@ -62,53 +62,12 @@
|
|||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
|
||||||
|
|
||||||
{#
|
|
||||||
|
|
||||||
{% for index,columnName in map %}
|
|
||||||
|
|
||||||
<div class="row">
|
|
||||||
<div class="col-lg-12">
|
|
||||||
<div class="box">
|
|
||||||
<div class="box-header with-border">
|
|
||||||
<h3 class="box-title">{{ Config.get('csv.roles.'~columnName~'.name') }}</h3>
|
|
||||||
</div>
|
|
||||||
<div class="box-body no-padding">
|
|
||||||
<table class="table table-hover">
|
|
||||||
<thead>
|
|
||||||
<tr>
|
|
||||||
<th style="width:50%;">{{ 'csv_field_value'|_ }}</th>
|
|
||||||
<th>{{ 'csv_field_mapped_to'|_ }}</th>
|
|
||||||
</tr>
|
|
||||||
</thead>
|
|
||||||
<tbody>
|
|
||||||
{% for value in values[index] %}
|
|
||||||
<tr>
|
|
||||||
<td><code>{{ value }}</code></td>
|
|
||||||
<td>
|
|
||||||
{{ Form.select('mapping['~index~']['~value~']',options[index], mapped[index][value], {class: 'form-control'}) }}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
{% endfor %}
|
|
||||||
|
|
||||||
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{% endfor %}
|
|
||||||
#}
|
|
||||||
|
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-12">
|
<div class="col-lg-12">
|
||||||
<div class="box">
|
<div class="box">
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<button type="submit" class="btn btn-success pull-right">
|
<button type="submit" class="btn btn-success pull-right">
|
||||||
{{ trans('csv.store_column_mapping') }} <i class="fa fa-arrow-right"></i>
|
{{ trans('csv.map_submit') }} <i class="fa fa-arrow-right"></i>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -91,7 +91,7 @@
|
|||||||
<div class="box">
|
<div class="box">
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<button type="submit" class="btn btn-success pull-right">
|
<button type="submit" class="btn btn-success pull-right">
|
||||||
{{ trans('csv.roles_store') }} <i class="fa fa-arrow-right"></i>
|
{{ trans('csv.roles_submit') }} <i class="fa fa-arrow-right"></i>
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -8,16 +8,13 @@
|
|||||||
<div class="col-lg-12 col-md-12 col-sm-12">
|
<div class="col-lg-12 col-md-12 col-sm-12">
|
||||||
<div class="box box-default">
|
<div class="box box-default">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ 'import'|_ }}</h3>
|
<h3 class="box-title">{{ 'import_index_title'|_ }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-8">
|
<div class="col-lg-8">
|
||||||
<h4>
|
|
||||||
{{ 'import_data_full'|_ }}
|
|
||||||
</h4>
|
|
||||||
<p>
|
<p>
|
||||||
{{ 'see_help_top_right'|_ }}
|
{{ 'import_index_intro'|_ }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -30,15 +27,15 @@
|
|||||||
|
|
||||||
<div class="col-lg-8 col-md-8 col-sm-12 col-xs-12">
|
<div class="col-lg-8 col-md-8 col-sm-12 col-xs-12">
|
||||||
|
|
||||||
{{ ExpandedForm.file('import_file', {helpText: 'import_file_help'|_}) }}
|
{{ ExpandedForm.file('import_file', {helpText: 'import_index_file'|_}) }}
|
||||||
{{ ExpandedForm.file('configuration_file', {helpText: 'configuration_file_help'|_|raw}) }}
|
{{ ExpandedForm.file('configuration_file', {helpText: 'import_index_config'|_|raw}) }}
|
||||||
{{ ExpandedForm.select('import_file_type', importFileTypes, defaultImportType, {'helpText' : 'import_file_type_help'|_}) }}
|
{{ ExpandedForm.select('import_file_type', importFileTypes, defaultImportType, {'helpText' : 'import_index_type'|_}) }}
|
||||||
|
|
||||||
<div class="form-group" id="import_file_holder">
|
<div class="form-group" id="import_file_holder">
|
||||||
<label for="ffInput_submit" class="col-sm-4 control-label"> </label>
|
<label for="ffInput_submit" class="col-sm-4 control-label"> </label>
|
||||||
<div class="col-sm-8">
|
<div class="col-sm-8">
|
||||||
<button type="submit" class="btn pull-right btn-success">
|
<button type="submit" class="btn pull-right btn-success">
|
||||||
{{ ('import_start')|_ }}
|
{{ ('import_index_start')|_ }}
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -11,33 +11,33 @@
|
|||||||
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
||||||
<div class="box box-primary">
|
<div class="box box-primary">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ 'please_wait_for_status'|_ }}</h3>
|
<h3 class="box-title">{{ 'import_status_wait_title'|_ }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<p>
|
<p>
|
||||||
{{ 'box_will_refresh'|_ }}
|
{{ 'import_status_wait_text'|_ }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{# Error display. Will be shown (duh) when something goes horribly wrong. #}
|
{# Fatal error display. Will be shown (duh) when something goes horribly wrong. #}
|
||||||
<div class="row errorbox" style="display:none;">
|
<div class="row fatal_error" style="display:none;">
|
||||||
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
||||||
<div class="box box-danger">
|
<div class="box box-danger">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ 'import_error_occurred'|_ }}</h3>
|
<h3 class="box-title">{{ 'import_status_fatal_title'|_ }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<p>
|
<p>
|
||||||
{{ 'import_error'|_ }}
|
{{ 'import_status_fatal_text'|_ }}
|
||||||
</p>
|
</p>
|
||||||
<p class="text-danger import_error_txt">
|
<p class="text-danger fatal_error_txt">
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
{{ 'import_error_further_instructions'|_ }}
|
{{ 'import_status_fatal_more'|_ }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -49,11 +49,11 @@
|
|||||||
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
||||||
<div class="box box-primary">
|
<div class="box box-primary">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ 'import_complete'|_ }}</h3>
|
<h3 class="box-title">{{ 'import_status_ready_title'|_ }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<p>
|
<p>
|
||||||
{{ 'import_complete_text'|_ }}
|
{{ 'import_status_ready_text'|_ }}
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
<code>php artisan firefly:start-import {{ job.key }}</code>
|
<code>php artisan firefly:start-import {{ job.key }}</code>
|
||||||
@ -61,17 +61,17 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-4">
|
<div class="col-lg-4">
|
||||||
<a href="{{ route('import.download', [job.key]) }}" class="btn btn-default"><i
|
<a href="{{ route('import.download', [job.key]) }}" class="btn btn-default"><i
|
||||||
class="fa fa-fw fa-download"></i> {{ 'import_download_config'|_ }}</a>
|
class="fa fa-fw fa-download"></i> {{ 'import_status_ready_config'|_ }}</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-lg-4">
|
<div class="col-lg-4">
|
||||||
<button class="btn btn-success start-job"><i class="fa fa-fw fa-gears"></i> {{ 'import_start_import'|_ }}</button>
|
<button class="btn btn-success start-job"><i class="fa fa-fw fa-gears"></i> {{ 'import_status_ready_start'|_ }}</button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<p>
|
<p>
|
||||||
|
|
||||||
</p>
|
</p>
|
||||||
<p class="text-info">
|
<p class="text-info">
|
||||||
{{ 'import_share_configuration'|_ }}
|
{{ 'import_status_ready_share'|_ }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -83,7 +83,7 @@
|
|||||||
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
||||||
<div class="box box-primary">
|
<div class="box box-primary">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title" id="import-status-title">{{ 'import_job_status'|_ }}</h3>
|
<h3 class="box-title" id="import-status-title">{{ 'import_status_running_title'|_ }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<div id="import-status-holder">
|
<div id="import-status-holder">
|
||||||
@ -93,22 +93,23 @@
|
|||||||
aria-valuemax="100" style="width: 100%;min-width:40px;">
|
aria-valuemax="100" style="width: 100%;min-width:40px;">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<p id="import-status-txt">{{ 'import_status_ready_to_start'|_ }}</p>
|
<p id="import-status-txt">{{ 'import_status_running_placeholder'|_ }}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
{# displays the finished status of the import. #}
|
||||||
<div class="row status_finished statusbox" style="display:none;">
|
<div class="row status_finished statusbox" style="display:none;">
|
||||||
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
||||||
<div class="box box-default">
|
<div class="box box-default">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ 'import_status_report'|_ }}</h3>
|
<h3 class="box-title">{{ 'import_status_finished_title'|_ }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<p id="import-status-intro">
|
<p id="import-status-intro">
|
||||||
{{ 'import_finished_report'|_ }}
|
{{ 'import_status_finished_text'|_ }}
|
||||||
</p>
|
</p>
|
||||||
<p id="import-status-more-info"></p>
|
<p id="import-status-more-info"></p>
|
||||||
</div>
|
</div>
|
||||||
@ -121,11 +122,10 @@
|
|||||||
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
<div class="col-lg-8 col-lg-offset-2 col-md-12 col-sm-12">
|
||||||
<div class="box box-danger">
|
<div class="box box-danger">
|
||||||
<div class="box-header with-border">
|
<div class="box-header with-border">
|
||||||
<h3 class="box-title">{{ 'import_status_errors'|_ }}</h3>
|
<h3 class="box-title">{{ 'import_status_errors_title'|_ }}</h3>
|
||||||
</div>
|
</div>
|
||||||
<div class="box-body">
|
<div class="box-body">
|
||||||
<p id="import-status-error-intro">
|
<p id="import-status-error-intro">
|
||||||
No errors detected.
|
|
||||||
</p>
|
</p>
|
||||||
<div id="import-status-error-list"></div>
|
<div id="import-status-error-list"></div>
|
||||||
</div>
|
</div>
|
||||||
@ -229,11 +229,12 @@
|
|||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
|
|
||||||
// some useful translations.
|
// some useful translations.
|
||||||
var langImportSingleError = '{{ 'import_error_single'|_|escape }}';
|
var langImportSingleError = '{{ 'import_status_errors_single'|_|escape }}';
|
||||||
var langImportMultiError = '{{ 'import_error_multi'|_|escape }}';
|
var langImportMultiError = '{{ 'import_status_errors_multi'|_|escape }}';
|
||||||
var langImportFatalError = '{{ 'import_error_fatal'|_|escape }}';
|
|
||||||
var langImportTimeOutError = '{{ 'import_error_timeout'|_|escape }}';
|
//var langImportFatalError = '{{ 'import_error_fatal'|_|escape }}';
|
||||||
var langImportFinished = '{{ 'import_finished_all'|_|escape }}';
|
//var langImportTimeOutError = '{{ 'import_error_timeout'|_|escape }}';
|
||||||
|
//var langImportFinished = '{{ 'import_finished_all'|_|escape }}';
|
||||||
|
|
||||||
|
|
||||||
var jobKey = '{{ job.key }}';
|
var jobKey = '{{ job.key }}';
|
||||||
|
Loading…
Reference in New Issue
Block a user