mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2025-07-09 03:14:30 -04:00
additional logging
This commit is contained in:
parent
ac3a7f00b9
commit
cbf8735d23
@ -494,7 +494,7 @@ class CompanyController extends BaseController
|
||||
$account->delete();
|
||||
|
||||
if (Ninja::isHosted()) {
|
||||
\Modules\Admin\Jobs\Account\NinjaDeletedAccount::dispatch($account_key, $request->all());
|
||||
\Modules\Admin\Jobs\Account\NinjaDeletedAccount::dispatch($account_key, $request->all(), auth()->user()->email);
|
||||
}
|
||||
|
||||
LightLogs::create(new AccountDeleted())
|
||||
|
@ -38,6 +38,8 @@ class AppStoreRenewSubscription implements ShouldQueue
|
||||
|
||||
$inapp_transaction_id = $event->getSubscriptionId(); //$subscription_id
|
||||
|
||||
nlog("inapp upgrade processing for = {$inapp_transaction_id}");
|
||||
|
||||
MultiDB::findAndSetDbByInappTransactionId($inapp_transaction_id);
|
||||
|
||||
$account = Account::where('inapp_transaction_id', $inapp_transaction_id)->first();
|
||||
|
@ -30,13 +30,7 @@ class ClientAccountNotFound extends Notification
|
||||
* @return void
|
||||
*/
|
||||
|
||||
|
||||
protected string $account_key;
|
||||
|
||||
public function __construct(string $account_key)
|
||||
{
|
||||
$this->account_key = $account_key;
|
||||
}
|
||||
public function __construct(protected string $account_key, protected string $email){}
|
||||
|
||||
/**
|
||||
* Get the notification's delivery channels.
|
||||
@ -77,6 +71,7 @@ class ClientAccountNotFound extends Notification
|
||||
|
||||
$content = "Client not found, unable to remove account\n";
|
||||
$content .= "Account: {$this->account_key }\n";
|
||||
$content .= "Email: {$this->email}\n";
|
||||
|
||||
return (new SlackMessage)
|
||||
->success()
|
||||
|
@ -39,10 +39,10 @@ class UserObserver
|
||||
public function updated(User $user)
|
||||
{
|
||||
|
||||
if (Ninja::isHosted() && $user->isDirty('email')) {
|
||||
if (Ninja::isHosted() && $user->isDirty('email') && $user->company_users()->where('is_owner', true)->exists()) {
|
||||
//ensure they are owner user and update email on file.
|
||||
if(class_exists(\Modules\Admin\Jobs\Account\UpdateOwnerUser::class))
|
||||
\Modules\Admin\Jobs\Account\UpdateOwnerUser::dispatch($user->account->account_key, $user, $user->getOriginal('email'));
|
||||
\Modules\Admin\Jobs\Account\UpdateOwnerUser::dispatch($user->account->key, $user, $user->getOriginal('email'));
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user