mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
Fixes for subs v4
This commit is contained in:
parent
526d86c5a3
commit
e563dea2b8
@ -51,9 +51,9 @@ class ClientRegisterService
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->company->settings->client_portal_terms || $this->company->settings->client_portal_privacy_policy) {
|
||||
$rules['terms'] = ['required'];
|
||||
}
|
||||
// if ($this->company->settings->client_portal_terms || $this->company->settings->client_portal_privacy_policy) {
|
||||
// $rules['terms'] = ['required'];
|
||||
// }
|
||||
|
||||
foreach ($this->additional as $field) {
|
||||
if ($field['visible'] ?? true) {
|
||||
|
@ -202,6 +202,10 @@ class RegisterOrLogin extends Component
|
||||
|
||||
$this->register_fields = [...collect($this->subscription->company->client_registration_fields ?? [])->toArray()];
|
||||
|
||||
// if ($this->subscription->company->settings->client_portal_terms || $this->subscription->company->settings->client_portal_privacy_policy) {
|
||||
// $this->register_fields[] = ['key' => 'terms', 'required' => true, 'visible' => 'true'];
|
||||
// }
|
||||
|
||||
$first_gateway = collect($this->subscription->company->company_gateways)
|
||||
->sortBy('sort_order')
|
||||
->first();
|
||||
|
@ -680,7 +680,7 @@ class StripePaymentDriver extends BaseDriver
|
||||
}
|
||||
|
||||
if ($request->type === 'payment_intent.processing') {
|
||||
PaymentIntentProcessingWebhook::dispatch($request->data, $request->company_key, $this->company_gateway->id)->delay(now()->addSeconds(2));
|
||||
PaymentIntentProcessingWebhook::dispatch($request->data, $request->company_key, $this->company_gateway->id)->delay(now()->addSeconds(rand(10,12)));
|
||||
return response()->json([], 200);
|
||||
}
|
||||
|
||||
@ -692,7 +692,7 @@ class StripePaymentDriver extends BaseDriver
|
||||
}
|
||||
|
||||
if ($request->type === 'payment_intent.partially_funded') {
|
||||
PaymentIntentPartiallyFundedWebhook::dispatch($request->data, $request->company_key, $this->company_gateway->id)->delay(now()->addSeconds(rand(5, 10)));
|
||||
PaymentIntentPartiallyFundedWebhook::dispatch($request->data, $request->company_key, $this->company_gateway->id)->delay(now()->addSeconds(rand(10, 15)));
|
||||
|
||||
return response()->json([], 200);
|
||||
}
|
||||
@ -715,7 +715,6 @@ class StripePaymentDriver extends BaseDriver
|
||||
->first();
|
||||
} else {
|
||||
$payment = Payment::query()
|
||||
// ->where('company_id', $request->getCompany()->id)
|
||||
->where('transaction_reference', $transaction['id'])
|
||||
->first();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user