mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-06-02 19:04:33 -04:00
Fixes for translations
This commit is contained in:
parent
e35a99d454
commit
1b5bbb43da
@ -53,7 +53,7 @@ class QuoteFilters extends QueryFilters
|
|||||||
* - paused
|
* - paused
|
||||||
* - completed
|
* - completed
|
||||||
*
|
*
|
||||||
* @param string client_status The invoice status as seen by the client
|
* @param string $value The invoice status as seen by the client
|
||||||
* @return Builder
|
* @return Builder
|
||||||
*/
|
*/
|
||||||
public function client_status(string $value = ''): Builder
|
public function client_status(string $value = ''): Builder
|
||||||
|
@ -144,6 +144,8 @@ class EmailController extends BaseController
|
|||||||
|
|
||||||
private function resolveClass(string $entity): string
|
private function resolveClass(string $entity): string
|
||||||
{
|
{
|
||||||
|
$class = '';
|
||||||
|
|
||||||
match ($entity) {
|
match ($entity) {
|
||||||
'invoice' => $class = Invoice::class,
|
'invoice' => $class = Invoice::class,
|
||||||
'App\Models\Invoice' => $class = Invoice::class,
|
'App\Models\Invoice' => $class = Invoice::class,
|
||||||
|
@ -24,21 +24,8 @@ class ProfitAndLoss implements ShouldQueue
|
|||||||
{
|
{
|
||||||
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
|
use Dispatchable, InteractsWithQueue, Queueable, SerializesModels;
|
||||||
|
|
||||||
protected Company $company;
|
public function __construct(protected Company $company, protected array $payload)
|
||||||
|
|
||||||
protected array $payload;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Create a new job instance.
|
|
||||||
*
|
|
||||||
* @param RecurringInvoice $recurring_invoice
|
|
||||||
* @param string $db
|
|
||||||
*/
|
|
||||||
public function __construct(Company $company, array $payload)
|
|
||||||
{
|
{
|
||||||
$this->company = $company;
|
|
||||||
|
|
||||||
$this->payload = $payload;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -75,6 +75,6 @@ class ApplePayDomain implements ShouldQueue
|
|||||||
|
|
||||||
$parsed_url = parse_url($domain);
|
$parsed_url = parse_url($domain);
|
||||||
|
|
||||||
return $parsed_url['host'];
|
return $parsed_url['host'] ?? '';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -252,42 +252,42 @@ class Invoice extends BaseModel
|
|||||||
return $this->dateMutator($value);
|
return $this->dateMutator($value);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function company()
|
public function company(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(Company::class);
|
return $this->belongsTo(Company::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function project()
|
public function project(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(Project::class);
|
return $this->belongsTo(Project::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function vendor()
|
public function vendor(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(Vendor::class);
|
return $this->belongsTo(Vendor::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function design()
|
public function design(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(Design::class);
|
return $this->belongsTo(Design::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function user()
|
public function user(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(User::class)->withTrashed();
|
return $this->belongsTo(User::class)->withTrashed();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function recurring_invoice()
|
public function recurring_invoice(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(RecurringInvoice::class, 'recurring_id', 'id')->withTrashed();
|
return $this->belongsTo(RecurringInvoice::class, 'recurring_id', 'id')->withTrashed();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function assigned_user()
|
public function assigned_user(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(User::class, 'assigned_user_id', 'id')->withTrashed();
|
return $this->belongsTo(User::class, 'assigned_user_id', 'id')->withTrashed();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function invitations()
|
public function invitations(): \Illuminate\Database\Eloquent\Relations\HasMany
|
||||||
{
|
{
|
||||||
return $this->hasMany(InvoiceInvitation::class);
|
return $this->hasMany(InvoiceInvitation::class);
|
||||||
}
|
}
|
||||||
@ -297,22 +297,22 @@ class Invoice extends BaseModel
|
|||||||
return $this->belongsTo(Client::class)->withTrashed();
|
return $this->belongsTo(Client::class)->withTrashed();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function subscription()
|
public function subscription(): \Illuminate\Database\Eloquent\Relations\BelongsTo
|
||||||
{
|
{
|
||||||
return $this->belongsTo(Subscription::class)->withTrashed();
|
return $this->belongsTo(Subscription::class)->withTrashed();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function documents()
|
public function documents(): \Illuminate\Database\Eloquent\Relations\MorphMany
|
||||||
{
|
{
|
||||||
return $this->morphMany(Document::class, 'documentable');
|
return $this->morphMany(Document::class, 'documentable');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function payments()
|
public function payments(): \Illuminate\Database\Eloquent\Relations\MorphToMany
|
||||||
{
|
{
|
||||||
return $this->morphToMany(Payment::class, 'paymentable')->withTrashed()->withPivot('amount', 'refunded')->withTimestamps();
|
return $this->morphToMany(Payment::class, 'paymentable')->withTrashed()->withPivot('amount', 'refunded')->withTimestamps();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function company_ledger()
|
public function company_ledger(): \Illuminate\Database\Eloquent\Relations\MorphMany
|
||||||
{
|
{
|
||||||
return $this->morphMany(CompanyLedger::class, 'company_ledgerable');
|
return $this->morphMany(CompanyLedger::class, 'company_ledgerable');
|
||||||
}
|
}
|
||||||
|
@ -77,7 +77,6 @@ use Illuminate\Database\Eloquent\SoftDeletes;
|
|||||||
* @property-read \App\Models\PaymentType|null $type
|
* @property-read \App\Models\PaymentType|null $type
|
||||||
* @property-read \App\Models\User|null $user
|
* @property-read \App\Models\User|null $user
|
||||||
* @property-read \App\Models\Vendor|null $vendor
|
* @property-read \App\Models\Vendor|null $vendor
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder company()
|
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder exclude($columns)
|
* @method static \Illuminate\Database\Eloquent\Builder exclude($columns)
|
||||||
* @method static \Database\Factories\PaymentFactory factory($count = null, $state = [])
|
* @method static \Database\Factories\PaymentFactory factory($count = null, $state = [])
|
||||||
* @method static \Illuminate\Database\Eloquent\Builder|Payment filter(\App\Filters\QueryFilters $filters)
|
* @method static \Illuminate\Database\Eloquent\Builder|Payment filter(\App\Filters\QueryFilters $filters)
|
||||||
@ -228,7 +227,7 @@ class Payment extends BaseModel
|
|||||||
return $this->morphedByMany(Credit::class, 'paymentable')->withTrashed()->withPivot('amount', 'refunded')->withTimestamps();
|
return $this->morphedByMany(Credit::class, 'paymentable')->withTrashed()->withPivot('amount', 'refunded')->withTimestamps();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function company_ledger()
|
public function company_ledger(): \Illuminate\Database\Eloquent\Relations\MorphMany
|
||||||
{
|
{
|
||||||
return $this->morphMany(CompanyLedger::class, 'company_ledgerable');
|
return $this->morphMany(CompanyLedger::class, 'company_ledgerable');
|
||||||
}
|
}
|
||||||
|
@ -463,7 +463,7 @@ class FacturaEInvoice extends AbstractService
|
|||||||
$company = $this->invoice->company;
|
$company = $this->invoice->company;
|
||||||
|
|
||||||
$seller = new FacturaeParty([
|
$seller = new FacturaeParty([
|
||||||
"isLegalEntity" => true, // Se asume true si se omite
|
"isLegalEntity" => $company->custom_value1, // Se asume true si se omite
|
||||||
"taxNumber" => $company->settings->vat_number,
|
"taxNumber" => $company->settings->vat_number,
|
||||||
"name" => substr($company->present()->name(), 0, 40),
|
"name" => substr($company->present()->name(), 0, 40),
|
||||||
"address" => substr($company->settings->address1, 0, 80),
|
"address" => substr($company->settings->address1, 0, 80),
|
||||||
|
@ -105,7 +105,7 @@ class RefundPayment
|
|||||||
/**
|
/**
|
||||||
* Create the payment activity.
|
* Create the payment activity.
|
||||||
*
|
*
|
||||||
* @param json $notes gateway_transaction
|
* @param string $notes
|
||||||
* @return $this
|
* @return $this
|
||||||
*/
|
*/
|
||||||
private function createActivity($notes)
|
private function createActivity($notes)
|
||||||
|
@ -12,5 +12,7 @@ parameters:
|
|||||||
universalObjectCratesClasses:
|
universalObjectCratesClasses:
|
||||||
- App\DataMapper\Tax\RuleInterface
|
- App\DataMapper\Tax\RuleInterface
|
||||||
- App\DataMapper\FeesAndLimits
|
- App\DataMapper\FeesAndLimits
|
||||||
|
reportUnmatchedIgnoredErrors: false
|
||||||
ignoreErrors:
|
ignoreErrors:
|
||||||
- '#Call to an undefined method Illuminate\Database\Database\Eloquent\Builder::company()#'
|
- '#Call to an undefined method [a-zA-Z0-9\\_]+::company\(\)#'
|
||||||
|
- '#Call to an undefined method [a-zA-Z0-9\\_]+::entityFilter\(\)#'
|
Loading…
x
Reference in New Issue
Block a user