mjda
Well-known member
I've been at this for a good two hours with no luck.
That is adding the alert into the database, and the notification bubble shows I have an alert, but when I click on it it still says "You have no new alerts.".
Also, when I click the page to add the transaction, I'm getting this error:
So, I assume there is no alert because I haven't specified a template, but I can't, for the life of me, figure out what the template is supposed to be called here, or how I can specify what it is.
PHP:
$alertRepo = \XF::app()->repository('XF:UserAlert');
$alert = $alertRepo->alertFromUser($alertUser, $visitor, 'transaction', $creator->transaction_id, 'create');
That is adding the alert into the database, and the notification bubble shows I have an alert, but when I click on it it still says "You have no new alerts.".
Also, when I click the page to add the transaction, I'm getting this error:
Code:
Error: Call to a member function getPushTemplateName() on null in src/XF/Service/Alert/Pusher.php at line 53
So, I assume there is no alert because I haven't specified a template, but I can't, for the life of me, figure out what the template is supposed to be called here, or how I can specify what it is.