[Evergreen-general] Conditional Statement in Receipt Template
Brett French
bfrench at cwmars.org
Wed Nov 20 15:39:23 EST 2024
Hey Chauncey,
We put something together for this at CW MARS.
<span ng-if="patron.pref_family_name">{{patron.pref_family_name}},</span>
<span ng-if="!patron.pref_family_name">{{patron.family_name}},</span>
<span
ng-if="patron.pref_first_given_name">{{patron.pref_first_given_name}}</span>
<span
ng-if="!patron.pref_first_given_name">{{patron.first_given_name}}</span>
Hope this helps!
Brett
On Wed, Nov 20, 2024 at 3:28 PM Chauncey Montgomery via Evergreen-general <
evergreen-general at list.evergreen-ils.org> wrote:
> We are trying to create a conditional statement within the receipt
> templates that will display a user's preferred name, if that condition is
> true; otherwise, the given name will be displayed on the receipt.
>
> How would I go about creating a conditional statement that checks if there
> is a value in the patron.pref_first_given_name field?
>
> Many thanks.
> CM
> --
> Chauncey Montgomery
> Community Library
> 44 Burrer Dr | Sunbury, OH 43074
> 740-965-3901 | https://www.yourcl.org
> _______________________________________________
> Evergreen-general mailing list
> Evergreen-general at list.evergreen-ils.org
> http://list.evergreen-ils.org/cgi-bin/mailman/listinfo/evergreen-general
>
--
Brett French (they/them)
Library Applications Associate II, C/W MARS, Inc.
------------------------------
[image: icon] *bfrench at cwmars.org <bfrench at cwmars.org>* | [image: icon]
www.cwmars.org
[image: icon] 508-755-3323 x 1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://list.evergreen-ils.org/pipermail/evergreen-general/attachments/20241120/b7cbec27/attachment.htm>
More information about the Evergreen-general
mailing list