mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-10-16 09:22:33 +00:00
Change signature of importstorage.
This commit is contained in:
@@ -88,9 +88,8 @@ class ImportProcedure
|
||||
$cleaned = $validator->clean();
|
||||
|
||||
// then import collection:
|
||||
$storage = new ImportStorage($cleaned);
|
||||
$storage = new ImportStorage($job->user, $cleaned);
|
||||
$storage->setJob($job);
|
||||
$storage->setUser($job->user);
|
||||
|
||||
// and run store routine:
|
||||
$result = $storage->store();
|
||||
|
@@ -40,14 +40,20 @@ class ImportStorage
|
||||
/** @var User */
|
||||
public $user;
|
||||
|
||||
/** @var Collection */
|
||||
private $rules;
|
||||
|
||||
/**
|
||||
* ImportStorage constructor.
|
||||
*
|
||||
* @param User $user
|
||||
* @param Collection $entries
|
||||
*/
|
||||
public function __construct(Collection $entries)
|
||||
public function __construct(User $user, Collection $entries)
|
||||
{
|
||||
$this->entries = $entries;
|
||||
$this->user = $user;
|
||||
$this->rules = $this->getUserRules();
|
||||
|
||||
}
|
||||
|
||||
@@ -124,6 +130,13 @@ class ImportStorage
|
||||
return $tag;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Collection
|
||||
*/
|
||||
private function getUserRules(): Collection
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* @param float $amount
|
||||
*
|
||||
|
Reference in New Issue
Block a user