[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnumed-devel] new placeholder(s)
From: |
Karsten Hilbert |
Subject: |
Re: [Gnumed-devel] new placeholder(s) |
Date: |
Mon, 2 Feb 2015 20:52:05 +0100 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On Mon, Jan 26, 2015 at 01:37:02PM +0000, Jim Busser wrote:
> >>> The new placeholders
> >>>
> >>> u'gen_adr_street': u"args: %s-style formatting template, cached",
> >>> u'gen_adr_number': u"args: %s-style formatting template, cached",
> >>> u'gen_adr_subunit': u"args: %s-style formatting template, cached",
> >>> u'gen_adr_location': u"args: %s-style formatting template, cached",
> >>> u'gen_adr_suburb': u"args: %s-style formatting template, cached",
> >>> u'gen_adr_postcode': u"args: %s-style formatting template, cached",
> >>> u'gen_adr_region': u"args: %s-style formatting template, cached",
> >>> u'gen_adr_country': u"args: %s-style formatting template, cached",
> >>>
> >>> allow for generic ("gen") selection of an
> >>> arbitrary address which in turn allows for
> >>> sending addressed letters to third parties
> >>> about a patient, such as consultation reports
> >>> and referral letters.
> >>
> >> Does 'allow for selection" mean "prompts" or how is the selection to be
> >> achieved and communicated to the engine?
> >
> > Have you tried ?
>
> The question was an invitation to offer more than "yes/
> no", because a little more direction than "try" can help to
> avoid one's blind experimentation in putting together a
> document template.
I was thinking you were asking about another new placeholder
(namely receiver_*) of which conception I was foolishly fond
or shall I say proud.
> … I assume that any set of one or more gen_adr_…
> placeholders will prompt for only a single instance of "which
> address to use"
That's right. They needn't even be adjacent. And they can
occur multiple times in order to refer to parts of the same
address multiple times.
> however in the case where one would wish to
> send communication
>
> To: Clinician A
> Cc: Clinician B, Clinician C
>
> can one do this by way of 3 instances of the placeholder,
Not at the moment. That's currently a limitation which I will
get rid of. The definition is now:
u"""part of a generic address, cached, selected from database:
args: optional template//optional selection message//optional
cache ID
template: %s-style formatting template
message: text message shown in address selection list
cache ID: used to differentiate separate cached invocations of
this placeholder
""",
IOW, if you want to "start" a new "instance" of the
placeholder just use a new cache ID. Note, however, that once
you start using any cache ID you'll have to use that ID for
_all_ parts of the same instance:
instance 1, first occurrence, this will show selection and cache:
<$gen_adr_street::the street=%s//Please select an address !//inst1$>
instance 1, 2nd occurrence, will just use the cached part:
<$gen_adr_location::location=%s////inst1$>
(note that you don't have to - but can - repeat the message)
instance 2, cached seperately, again selected from list:
<$gen_adr_country::country=%s//Please select an address !//inst2$>
Karsten
--
GPG key ID E4071346 @ eu.pool.sks-keyservers.net
E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346
- Re: [Gnumed-devel] new placeholder(s),
Karsten Hilbert <=