Mercurial > hgweb > health
changeset 3399:74b4e7863e7b
HMIS server. Implement CJK name representation, task https://savannah.gnu.org/task/?15311
| author | Luis Falcon <falcon@gnuhealth.org> |
|---|---|
| date | Mon, 07 Oct 2019 13:06:35 +0100 |
| parents | 74ca22400b75 |
| children | d95563f72de1 |
| files | tryton/health/health.py |
| diffstat | 1 files changed, 8 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/tryton/health/health.py +++ b/tryton/health/health.py @@ -2,7 +2,7 @@ ############################################################################## # # GNU Health: The Free Health and Hospital Information System -# Copyright (C) 2008-2019 Luis Falcon <lfalcon@gnusolidario.org> +# Copyright (C) 2008-2019 Luis Falcon <falcon@gnuhealth.org> # Copyright (C) 2011-2019 GNU Solidario <health@gnusolidario.org> # Copyright (C) 2015 Cédric Krier # Copyright (C) 2014-2015 Chris Zimmerman <siv@riseup.net> @@ -376,7 +376,8 @@ ('pgfs', 'Prefix Given Family, Suffix'), ('gf', 'Given Family'), ('fg', 'Family, Given'), - ], 'Name Representation', + ('cjk', 'CJK: Family+Given'), + ], 'Name Representation', sort=False, states={'invisible': Not(Bool(Eval('is_person')))}) @@ -791,6 +792,11 @@ family = pname.family + ', ' res = family + given + if self.name_representation == 'cjk': + if pname.family: + family = pname.family + res = family + given + if not self.name_representation: # Default value if family:
