mirror of
https://github.com/InvoiceShelf/InvoiceShelf.git
synced 2026-07-16 22:05:20 +00:00
refactor(services): Documents→Document + ExchangeRate→Integrations/ExchangeRate
Two follow-ups to the Services reorg that landed in 6d1816bd.
**Documents → Document** (singular). Documents/ was the only plural subdir in app/Services/ — every other bucket (Company, Mail, Module, Pdf, Storage, Update, ExchangeRate) was singular. Renaming to Document/ normalizes the whole tree.
**ExchangeRate → Integrations/ExchangeRate**. Introduces Integrations/ as an umbrella for external-service adapter subsystems. Exchange rate providers move in first; AI providers, payment gateways, and any other driver-pattern integrations land as sibling subdirs (Integrations/Ai/, Integrations/Payment/) without another reorg. Integrations/ was chosen over Providers/ to avoid conceptual collision with Laravel's app/Providers/ — 'check the providers' shouldn't be ambiguous.
17 files moved, 21 consumer files rewritten to point at the new namespaces via literal-string replacement (same approach as the previous reorg). 350 tests pass, Pint clean.
This commit is contained in:
@@ -4,8 +4,8 @@ use App\Http\Requests\EstimatesRequest;
|
||||
use App\Models\Estimate;
|
||||
use App\Models\EstimateItem;
|
||||
use App\Models\Tax;
|
||||
use App\Services\Documents\DocumentItemService;
|
||||
use App\Services\Documents\EstimateService;
|
||||
use App\Services\Document\DocumentItemService;
|
||||
use App\Services\Document\EstimateService;
|
||||
use Illuminate\Support\Facades\Artisan;
|
||||
|
||||
beforeEach(function () {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
<?php
|
||||
|
||||
use App\Services\ExchangeRate\CurrencyFreakDriver;
|
||||
use App\Services\ExchangeRate\ExchangeRateDriver;
|
||||
use App\Services\ExchangeRate\ExchangeRateDriverFactory;
|
||||
use App\Services\Integrations\ExchangeRate\CurrencyFreakDriver;
|
||||
use App\Services\Integrations\ExchangeRate\ExchangeRateDriver;
|
||||
use App\Services\Integrations\ExchangeRate\ExchangeRateDriverFactory;
|
||||
use InvoiceShelf\Modules\Registry;
|
||||
|
||||
test('make resolves built-in drivers from the factory map', function () {
|
||||
|
||||
@@ -4,8 +4,8 @@ use App\Http\Requests\InvoicesRequest;
|
||||
use App\Models\Invoice;
|
||||
use App\Models\InvoiceItem;
|
||||
use App\Models\Tax;
|
||||
use App\Services\Documents\DocumentItemService;
|
||||
use App\Services\Documents\InvoiceService;
|
||||
use App\Services\Document\DocumentItemService;
|
||||
use App\Services\Document\InvoiceService;
|
||||
use Illuminate\Support\Facades\Artisan;
|
||||
|
||||
beforeEach(function () {
|
||||
|
||||
Reference in New Issue
Block a user