mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2026-01-06 14:12:15 +00:00
Updated test database.
This commit is contained in:
@@ -32,11 +32,6 @@ interface AttachmentRepositoryInterface
|
||||
*/
|
||||
public function destroy(Attachment $attachment): bool;
|
||||
|
||||
/**
|
||||
* @return Collection
|
||||
*/
|
||||
public function get(): Collection;
|
||||
|
||||
/**
|
||||
* @param Attachment $attachment
|
||||
*
|
||||
@@ -45,11 +40,9 @@ interface AttachmentRepositoryInterface
|
||||
public function exists(Attachment $attachment): bool;
|
||||
|
||||
/**
|
||||
* @param Attachment $attachment
|
||||
*
|
||||
* @return string
|
||||
* @return Collection
|
||||
*/
|
||||
public function getContent(Attachment $attachment): string;
|
||||
public function get(): Collection;
|
||||
|
||||
/**
|
||||
* @param Carbon $start
|
||||
@@ -59,6 +52,13 @@ interface AttachmentRepositoryInterface
|
||||
*/
|
||||
public function getBetween(Carbon $start, Carbon $end): Collection;
|
||||
|
||||
/**
|
||||
* @param Attachment $attachment
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getContent(Attachment $attachment): string;
|
||||
|
||||
/**
|
||||
* @param Attachment $attachment
|
||||
* @param array $attachmentData
|
||||
|
||||
@@ -83,6 +83,14 @@ interface BudgetRepositoryInterface
|
||||
*/
|
||||
public function getActiveBudgets(): Collection;
|
||||
|
||||
/**
|
||||
* @param Carbon $start
|
||||
* @param Carbon $end
|
||||
*
|
||||
* @return Collection
|
||||
*/
|
||||
public function getAllBudgetLimits(Carbon $start, Carbon $end): Collection;
|
||||
|
||||
/**
|
||||
* @param TransactionCurrency $currency
|
||||
* @param Carbon $start
|
||||
@@ -92,14 +100,6 @@ interface BudgetRepositoryInterface
|
||||
*/
|
||||
public function getAvailableBudget(TransactionCurrency $currency, Carbon $start, Carbon $end): string;
|
||||
|
||||
/**
|
||||
* @param Carbon $start
|
||||
* @param Carbon $end
|
||||
*
|
||||
* @return Collection
|
||||
*/
|
||||
public function getAllBudgetLimits(Carbon $start, Carbon $end): Collection;
|
||||
|
||||
/**
|
||||
* @param Budget $budget
|
||||
* @param Carbon $start
|
||||
|
||||
@@ -146,7 +146,6 @@ class CategoryRepository implements CategoryRepositoryInterface
|
||||
->orderBy('transaction_journals.date', 'ASC')->first(['transaction_journals.date']);
|
||||
|
||||
|
||||
|
||||
// both exist, the one that is earliest "wins".
|
||||
if (!is_null($firstTransaction) && !is_null($first) && Carbon::parse($firstTransaction->date)->lt($first)) {
|
||||
$first = $firstTransaction->date;
|
||||
|
||||
@@ -22,6 +22,14 @@ use FireflyIII\Models\ExportJob;
|
||||
*/
|
||||
interface ExportJobRepositoryInterface
|
||||
{
|
||||
/**
|
||||
* @param ExportJob $job
|
||||
* @param string $status
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function changeStatus(ExportJob $job, string $status): bool;
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
@@ -32,14 +40,6 @@ interface ExportJobRepositoryInterface
|
||||
*/
|
||||
public function create(): ExportJob;
|
||||
|
||||
/**
|
||||
* @param ExportJob $job
|
||||
* @param string $status
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function changeStatus(ExportJob $job, string $status): bool;
|
||||
|
||||
/**
|
||||
* @param ExportJob $job
|
||||
*
|
||||
|
||||
@@ -14,7 +14,6 @@ declare(strict_types = 1);
|
||||
namespace FireflyIII\Repositories\User;
|
||||
|
||||
|
||||
use FireflyConfig;
|
||||
use FireflyIII\Models\BudgetLimit;
|
||||
use FireflyIII\Models\Role;
|
||||
use FireflyIII\User;
|
||||
@@ -53,6 +52,20 @@ class UserRepository implements UserRepositoryInterface
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param User $user
|
||||
* @param string $password
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function changePassword(User $user, string $password): bool
|
||||
{
|
||||
$user->password = bcrypt($password);
|
||||
$user->save();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
@@ -134,17 +147,4 @@ class UserRepository implements UserRepositoryInterface
|
||||
|
||||
return $return;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param User $user
|
||||
* @param string $password
|
||||
*
|
||||
* @return bool
|
||||
*/
|
||||
public function changePassword(User $user, string $password): bool
|
||||
{
|
||||
$user->password = bcrypt($password);
|
||||
$user->save();
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user