Preferred Phone Number Archetype

Hi,

I presume this is all done in archetypes, but just want to check this will work before I go editing in there.

I would like to make an almost identical copy of the archetype contact.phoneNumber.1.0, but have it slightly different. I would like the display name of the new one to be Preferred Phone Number. The preferred would obviously be true().   *When a new customer is added I would like this to be on view in the contacts section (currently it is Location & Phone Number)

I would like to keep the Phone Number archetype, but have this as preferred being false().    *I would like this to not be in view in the contacts section when you add a new client. (but still available if you press ADD)

 

I would also like the email address to be automatically in view when you add a new customer, so it prompts reception to add the email address. I don't want the minimum cardinality to change, as some people don't have email addresses. I would just like it that when you add a new customer and go to the Contacts tab, the three viewed options (before you press add) are: Location, Preferred Phone Number, Email Address.

 

I hope that all makes sense,

Greta

 

 

 

 

 

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Re: Preferred Phone Number Archetype

Creating a copied phone archetype wont work it will not get used programmatically.

ie when you use things like 

party:getPhoneNumber(.) etc

Is there a reason the preferred checkbox doesnt work for you and your staff?

 

Regarding defauly email address's see here

http://www.openvpms.org/forum/default-customer-email-contact

Not possible at the moment...

Regards
 
Ben 
OpenVPMS Installer and Helper 
Ph: +61423044823 
Email: info[at]charltonit.com[dot]au

Re: Preferred Phone Number Archetype

Greta - I interpreted your phone number bit differently to Ben - I assumed that you were asking could you modify the contact.phone archetype slightly.  The answer to this is Yes. I adjusted to:

and got:

The (01) 1234 5678 is the one I added first, the (02) one second. Note that a) when I added the 2nd the 1st one lost its preferred status; b) when the 2nd was added we now have 2 with the same name and the 1st really should be modified because it is no longer the preferred one.  Hence I am not sure whether it is best to default the name to 'Preferred ..." - but your choice.

Regards, Tim G

Re: Preferred Phone Number Archetype

Thanks Ben and Tim,

I can understand how creating a new archetype will affect other documents etc, but can I just edit the current archetype to say preferred as Tim explained, and create a new arhetype for other phone numbers that aren't going to be used in documents etc? Often the second phone number we get are for emergency only and we don't need to populate this anywhere.

The reason the preferred tick box doesn't work for us is because of the way clients are added into our system.

When adding a new client, the receptionist follows our new client form which has their 'phone number' after address.

Then the next line is 'secondary phone number'. When this is added, the preferred number is ticked on the secondary phone number and the receptionist has to go back and tick the first one again.

I thought about editing our new client form, but it wouldn't make sense for clients to write their 'other' phone numbers before writing their 'preferred number'.

If we don't have 'preferred' as automatically ticked (as explained in a different post) then none of them are preferred and our staff forget to tick any of them.

So, I guess what I'm really after is a way that the first phone number that is entered has the preferred ticked. Any numbers added after that, are not preferred, unless manually edited.

I'm sorry if this has been discussed in a different thread.

Greta

 

 

Re: Preferred Phone Number Archetype

Just change the archetype so that the defaultValue of preferred is false()

Tick it on the first one and leave it for the others.  This really comes down to making sure that form really highlights the word preferred so staff enter it correctly 

You could create that second archetype if you want BUT think about a year or 2 down and you think I want to do SMS reminders but the preferred number is a landline...suddenly the whole system isnt going to work...because SMS  looks for the original archetype with the property SMS as true not necessarily the preferred...having a copied and renamed archetype breaks it.

Regards
 
Ben 
OpenVPMS Installer and Helper 
Ph: +61423044823 
Email: info[at]charltonit.com[dot]au

Re: Preferred Phone Number Archetype

A trivial code change can be made that would prevent new contacts being marked preferred if there is an existing preferred contact of the same type.

If this is what you are after, it can go in to 1.8.

Re: Preferred Phone Number Archetype

Good point Ben. Hopefully we will be changing to electronic sign in someday, which will make all this unecessary anyway.

If you can change the code Tim, that would be exactly what we want. 

Would we keep the preferred true() so the first one is automatically ticked? Then any additional contacts of the same type would be prevented from being preferred? If so, yes, that'd be great for 1.8

Thanks,

Greta

Re: Preferred Phone Number Archetype

Hi Tim A,

Just wondering if the code was changed so it was possible to default the first contact.phoneNumber to preferred, but any subsequent contact.phoneNumbers to not preferred?

Re: Preferred Phone Number Archetype

That's the way it works in 1.8.1. Its regressed in the 1.9 snapshots.

I've fixed it in revision 7112.

Syndicate content