auto fill up require field from previos data
parent
2cc4aff3a2
commit
22f8dbda52
|
@ -42,10 +42,14 @@ class HDCasePopupDlz(Model):
|
|||
data=context['data']
|
||||
product_id=data['product_id']
|
||||
data['membrane_type']=None
|
||||
data['dialyzer_type']=None
|
||||
#data['max_use_time']=None
|
||||
for dlz in get_model("clinic.dialyzer").search_browse([]):
|
||||
prod=dlz.product_id
|
||||
if prod.id==product_id:
|
||||
data['membrane_type']=dlz.membrane_type
|
||||
data['dialyzer_type']=dlz.dialyzer_type or "low"
|
||||
data['max_use_time']=dlz.max_use_time or 0
|
||||
break
|
||||
return data
|
||||
|
||||
|
|
Loading…
Reference in New Issue