Onsite Patient Portal self- registration broken in 6.0?

I don’t have any screenshots to show a silent fail…
It works well enough in my 5.0.2(2) install, in that I can go through the self registration routine and since I don’t have any email sending function set up, I get the ‘cannot create credential’ error at the end, but it does create the new pt record in the EMR.
In a 6.0 system I’m working on, with the globals all the same as my demo, it goes through the routine and gives the email error. And does not create the record.
I don’t know if it’s related, but when I surf to the portal site, it does show the ‘oops’ popup:
image
Ideas?
TIA- HT

@htuck
I may have fixed this to not create a patient if email fails. Sounds like something i’d do because I consider that a bug.

To double check, you’re saying that the self- register routine is intended to silently fail if the ‘Send Request’ button is clicked and the clinic has not set up an email delivery system?
Where in the code could a mod be made to bring back the notification that it’s failing?

I just wrote some user docs for the wiki on the self reg bit based on OEMR 5.0.2(2), and I wanna update it for 6 before I publish it.
Thanks- HT

It shouldn’t be silent. It should give an error that the registration has not completed with a dialog that says something like Here’s what we know then email error.
I’ll have to look but I just tested this not long ago.

I get


@htuck Is this not what you get?

That looks like the error message that was in the server error log.

[Tue Jan 19 17:17:17.961269 2021] [php7:notice] [pid 1172217] [client 204.195.110.44:35794] Portal Registration error: EMAIL ERROR: You must provide at lea
st one recipient email address.<br /><br />We were unable to create an account.<br />Please try again or contact the providers office for
 further assistance., referer: https://some-url.mi-squared.com/openemr/portal/account/register.php

@sjpadgett Does the patient portal email use the same email credentials as in Globals > Notifications? We can try putting a webmail SMTP server in there… I don’t like using sendmail.

Yes, I always used SMTP and I don’t recall ever testing with sendmail. The message I give is a little misleading because the error is really referring to the SMTP recipient and not patient email.
Still patient should never get a silent return.

OK cool! Do you have a recommendation for service you’ve used and that you know works? I’ve had issues with Earthlink and SendGrid. Or do you just do your own SMTP server?

I just use my gmail account and normally recm user to use their clinics setup. I don’t know what others have used but i’m sure not all use gmail.
In the end I believe this is client we use
library/classes/postmaster.php

Thank you, we will try gmail!

Sorry guys but I think register is broken again in v6.
I don’t understand yet why but i’m looking into.
I don’t understand as I tested this before v6 was released. Hope didn’t cause too much inconvenience and i’m still not sure it’s broken or my environment!

@htuck Found a bug(not really a bug but, an oversight) in security so that’s why not working.
I’ll publish a fix soon or email me and i’ll get you a fix so you can continue documenting/testing.
I do still create a patient if email can’t be sent and give this message:


or the screen I showed previously when either new patient or email can’t complete.
Completed

I think this still might be an issue, I assume any smtp service can be used here correct?

I’m currently using mailgun but I still get this error when trying to register a patient via the portal.

Console errors in case they are useful:

jQuery.Deferred exception: exclude is not defined ReferenceError: exclude is not defined
    at HTMLDocument.<anonymous> (https://devapi.ersight.com/portal/patient/scripts/app/patientdata.js?v=61:197:17)
    at e (https://devapi.ersight.com/public/assets/jquery/dist/jquery.min.js:2:30005)
    at t (https://devapi.ersight.com/public/assets/jquery/dist/jquery.min.js:2:30307) undefined

jquery.min.js:2 Uncaught ReferenceError: exclude is not defined
    at HTMLDocument.<anonymous> (patientdata.js?v=61:197)
    at e (jquery.min.js:2)
    at t (jquery.min.js:2)

jquery.min.js:2 POST https://myurl.com/portal/patient/api/patient 401

Uncaught ReferenceError: signerAlertMsg is not defined
    at Object.appendAlert (app.js?v=61:25)
    at error (patientdata.js?v=61:504)
    at G.e.error (backbone.js:2090)
    at Object.r.error (backbone.js:1607)
    at c (jquery.min.js:2)
    at Object.fireWith [as rejectWith] (jquery.min.js:2)
    at l (jquery.min.js:2)
    at XMLHttpRequest.<anonymous> (jquery.min.js:2)

utility.js?v=61:5 Needed to load:[undefined/public/assets/interactjs/dist/interact.js] For: [https://myurl.com/portal/account/register.php]

utility.js?v=61:5 GET https://myurl.com/portal/account/undefined/public/assets/interactjs/dist/interact.js net::ERR_ABORTED 40

utility.js?v=61:5 Uncaught (in promise) Error: Script load error for undefined/public/assets/interactjs/dist/interact.js
    at HTMLScriptElement.newScriptElement.onerror (utility.js?v=61:5)

And apache error log:

[Thu Jan 28 18:43:06.663350 2021] [php7:notice] [pid 1534] [client 162.158.123.252:31302] Portal Registration error: EMAIL ERROR: You must provide at least one recipient email address.&lt;br /&gt;&lt;br /&gt;We were unable to create an account.&lt;br /&gt;Please try again or contact the providers office for further assistance., referer: https://myurl.com/portal/account/register.php

Thanks.

In this case it’s not email that’s the problem but, either you don’t have the changes from my PR or you need to clear your browser cache.
Read the PR git thread to see if that helps!

1 Like

Will do and post back my findings, thanks.

How would I go about getting these changes into my docker container? Is this included on the latest docker image? Do I just docker-compose down then up to rebuild the container? Thanks

I don’t use docker so maybe @stephenwaite can answer. This fix is in dev master.

1 Like

Yeah, I think this has not been merged to master or it has not made its way into the docker image yet.

I did docker-compose down and deleted both the container and the image and docker-compose up and I still get the same issue.

Thanks.