SMS numbers, Fax Phone Numbers and a little Pedantry
1. SMS
All our mobile phone numbers (and I guess the same goes for many other vets) have been set up with
Area code field: 04nn (eg 0411)
Number field: nnn-nnn or nnn nnn (eg 123-456)
When trying to get a number for SMS, openVPMS v1.5+ currently uses only the number field which means that I get an SMS number of 61123456 instead of 61411123456.
If the openVPMS code getting the phone number is altered to grab both area code and number, remove leading zero, add "61", then check and remove any non-numeric character (this would take care of spaces, hyphens, dots, and any comments after the phone number (eg "ask for Jane" etc), the SMS number using the example above would be 0411 123-456 -> 61411123456.
2. Phone Numbers
User fields for Work, home, mobile numbers are all returned as
"(" + string(area.code) + ") " + string(number)
to give a number such as
(03) 1234-1234
However, the user field for fax number omits the space after the closing bracket
ie "(" + string(area.code) + ")" + string(number)
to give a number such as
(03)1234-1234.
When designing a form with phone numbers, the fax number therefore doesn't line up with numbers above and below.
eg
(03) 1234-5678 (Work)
(03)1234-5678 (Fax)
(03) 1234-5678 (home)
3. General Pedantry
customer.entity.name currently returns
string(last.name) + "," + string(first.name)
to give
Smith,John
could it be altered to return
string(last.name) + ", " + string(first.name)
as
Smith, John
(ie a space after the comma - it looks neater).
Yuri.
Re: SMS numbers, Fax Phone Numbers and a little Pedantry
Taking your points in order:
1. I've raised the area code issue as https://openvpms.atlassian.net/browse/OVPMS-1112
I don't really like the use of telephoneNumber including comments (e.g. "ask for Jane")
A better approach would be to include a short comment field for this purpose.
2. Raised as https://openvpms.atlassian.net/browse/ARCH-54
3. Raised as https://openvpms.atlassian.net/browse/ARCH-55
You can change this youself by editing the party.customerperson archetype and changing the "name" node.
i.e, change:
to:
-Tim
Re: SMS numbers, Fax Phone Numbers and a little Pedantry
G'day Tim
1. >I don't really like the use of telephoneNumber including comments (e.g. "ask for Jane")
Nor do I - I was just trying to "cover all bases" as I thought through the issue. Hyphens and/or spaces, though, are probably common in phone numbers.
2. Thanks.
3. Great, thanks for the prompt reply and fix - worked a charm, but I got a few error messages about Patient names along the way (through which I skipped). I noted that existing appointments displayed "Henr" instead of "Henry" for first name, but the display had corrected itself by the time I'd billed the visit.
Cheers
Yuri.
Re: SMS numbers, Fax Phone Numbers and a little Pedantry
I've had a complaint that the change to name format breaks existing installations. Practices with a lot of data without the space are used to querying customers by name without spaces and are getting tripped up by this change. As a result, I'm going to revert it.
You can apply the change to your local installation - you'll just have to re-apply it when you reload archetypes.
-Tim