On 2018-03-19 18:07, Khurram Shahzad wrote:
> I have a 'AdmiittedPatient' class with following two fields:
> 
> patient = fields.One2Many('party.party','Patient')
> bed_transfers = fields.One2Many('gnuhealth.bed.transfer', 'name',
>         'Transfer History', readonly=True)
> 
> where  gnuhealth.bed.transfer ('BedTransfers') class has:
>     bed_from = fields.Many2One('gnuhealth.hospital.bed', 'From',)
>     bed_to = fields.Many2One('gnuhealth.hospital.bed', 'To',)
> 
> Now, I am trying to write a domain rule which will display those patients
> who were transferred to a Bed with id 15.

What are you calling a "domain rule"?

> (Eval('15'), 'in', [Eval('bed_transfers',{}).get('bed_from', -1)])

Eval('15') can never work. If you want the number 15, you must type: 15


-- 
Cédric Krier - B2CK SPRL
Email/Jabber: cedric.kr...@b2ck.com
Tel: +32 472 54 46 59
Website: http://www.b2ck.com/

-- 
You received this message because you are subscribed to the Google Groups 
"tryton" group.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tryton/20180320162158.GW3935%40kei.

Reply via email to