diff --git a/app/Console/Commands/CalculatePayouts.php b/app/Console/Commands/CalculatePayouts.php index fbad2bf58769..ef03c374ae4b 100644 --- a/app/Console/Commands/CalculatePayouts.php +++ b/app/Console/Commands/CalculatePayouts.php @@ -83,14 +83,17 @@ class CalculatePayouts extends Command foreach ($companies as $company) { $user = $userMap[$company->referral_code]; $payment = $company->payment; - $client = $payment->client; - $this->info("User: $user"); - $this->info("Client: " . $client->getDisplayName()); + if ($payment) { + $client = $payment->client; - foreach ($client->payments as $payment) { - $amount = $payment->getCompletedAmount(); - $this->info("Date: $payment->payment_date, Amount: $amount, Reference: $payment->transaction_reference"); + $this->info("User: $user"); + $this->info("Client: " . $client->getDisplayName()); + + foreach ($client->payments as $payment) { + $amount = $payment->getCompletedAmount(); + $this->info("Date: $payment->payment_date, Amount: $amount, Reference: $payment->transaction_reference"); + } } } } diff --git a/resources/lang/en/texts.php b/resources/lang/en/texts.php index 5331403c94e2..046989e7374f 100644 --- a/resources/lang/en/texts.php +++ b/resources/lang/en/texts.php @@ -2849,6 +2849,7 @@ $LANG = array( 'all_invoices' => 'All Invoices', 'my_invoices' => 'My Invoices', 'mobile_refresh_warning' => 'If you\'re using the mobile app you may need to do a full refresh.', + 'enable_proposals_for_background' => 'To upload a background image :link to enable the proposals module.', ); diff --git a/resources/views/accounts/client_portal.blade.php b/resources/views/accounts/client_portal.blade.php index c93d1f277e4e..c805e71f3968 100644 --- a/resources/views/accounts/client_portal.blade.php +++ b/resources/views/accounts/client_portal.blade.php @@ -513,7 +513,8 @@ iframe.src = '{{ rtrim(SITE_URL ,'/') }}/' + parts[1] + '/' + parts[0].substring $('#domainHelp, #iframeModalHelp, #domainModalHelp').hide(); $('#is_custom_domain').val(0); - var val = $('input[name=custom_link]:checked').val() + var val = $('input[name=custom_link]:checked').val() || 'iframe'; + if (val == 'subdomain') { $('.subdomain').show(); } else if (val == 'iframe') { diff --git a/resources/views/accounts/invoice_design.blade.php b/resources/views/accounts/invoice_design.blade.php index 4c2dc59a76d7..de446e9d20cf 100644 --- a/resources/views/accounts/invoice_design.blade.php +++ b/resources/views/accounts/invoice_design.blade.php @@ -298,7 +298,11 @@ ->label('background_image') ->addOption('', '') ->fromQuery(\App\Models\Document::scope()->proposalImages()->get(), function($model) { return $model->name . ' - ' . Utils::formatNumber($model->size / 1000, null, 1) . ' KB'; }, 'public_id') - ->help(trans('texts.background_image_help', ['link' => link_to('/proposals/create?show_assets=true', trans('texts.proposal_editor'), ['target' => '_blank'])])) !!} + ->help($account->isModuleEnabled(ENTITY_PROPOSAL) + ? trans('texts.background_image_help', ['link' => link_to('/proposals/create?show_assets=true', trans('texts.proposal_editor'), ['target' => '_blank'])]) + //: trans('texts.enable_proposals_for_background', ['link' => link_to('/settings/account_management', trans('texts.click_here'), ['target' => '_blank'])]) + : 'To upload a background image click here to enable the proposals module.' + ) !!} @endif {!! Former::checkbox('hide_paid_to_date')->text(trans('texts.hide_paid_to_date_help'))->value(1) !!}