conv_bal
watcha.h 2015-03-23 13:58:30 +07:00
parent 6b2e3b3da2
commit 01be234519
2 changed files with 6 additions and 1 deletions

View File

@ -1412,6 +1412,11 @@ class HDCase(Model):
'state': 'not_available',
})
set_active_user(user_id)
if 'lines' in vals.keys():
if not vals['lines']:
print("lines is empty will update it now...")
patient_id=obj.patient_id.id
vals=self.get_staff_line(vals,patient_id)
self.function_store(ids)
super().write(ids,vals,**kw)
obj=self.browse(ids)[0]

View File

@ -186,7 +186,7 @@ class Visit(Model):
}
st=get_model("clinic.setting").browse(1)
if st.find_dlz:
if st.find_dlz and not obj.hd_cases: # force to remove
dialyzer=self.get_dlz(obj.id)
if dialyzer:
vals['dialyzers'].append(('create',dialyzer))