xxx
parent
c9abe0742b
commit
e122227156
|
@ -8,6 +8,7 @@
|
|||
</button>
|
||||
</head>
|
||||
<field name="number"/>
|
||||
<field name="trt_number"/>
|
||||
<field name="type_id"/>
|
||||
<field name="name"/>
|
||||
<field name="hn"/>
|
||||
|
@ -89,7 +90,7 @@
|
|||
<group form_layout="stacked">
|
||||
<field name="active" span="2"/>
|
||||
<field name="rm_remain_visit" span="2" attrs='{"invisible":[["active","=","true"]]}'/>
|
||||
<field name="resign_date" span="2" readonly="1"/>
|
||||
<field name="resign_date" span="2"/>
|
||||
<newline/>
|
||||
<field name="note" nolabel="1"/>
|
||||
</group>
|
||||
|
|
|
@ -42,6 +42,7 @@ class Patient(Model):
|
|||
_fields={
|
||||
'type_id': fields.Many2One("clinic.patient.type","Type",search=True,required=True),
|
||||
"number": fields.Char("Number",required=True,search=True),
|
||||
"trt_number": fields.Char("TRT. NO",search=True),
|
||||
"hn": fields.Char("REF/HN",search=True),
|
||||
"hn_num": fields.Char("HN Numeric",function="_get_hn_num"),
|
||||
"name": fields.Char("Name",required=True,search=True),
|
||||
|
|
|
@ -8,7 +8,8 @@ class Schedule(Model):
|
|||
_name="clinic.schedule"
|
||||
_string="Schedule"
|
||||
_field_name="date"
|
||||
|
||||
_key=['name']
|
||||
|
||||
def _get_name(self,ids,context={}):
|
||||
res={}
|
||||
for obj in self.browse(ids):
|
||||
|
|
|
@ -73,19 +73,7 @@ class ClinicSetting(Model):
|
|||
amt=qty*price
|
||||
line['amount']=amt
|
||||
return data
|
||||
|
||||
def run_script(self,ids,context={}):
|
||||
return
|
||||
for inv in get_model("account.invoice").search_browse([]):
|
||||
amount_total=0
|
||||
for line in inv.lines:
|
||||
amount_total+=line.amount
|
||||
inv.write({
|
||||
'amount_total': amount_total,
|
||||
'amount_due': amount_total,
|
||||
})
|
||||
print("Done!")
|
||||
|
||||
|
||||
def schd_confirm(self,ids,context={}):
|
||||
obj=self.browse(ids)[0]
|
||||
if not obj.schd_from:
|
||||
|
@ -99,5 +87,12 @@ class ClinicSetting(Model):
|
|||
schd.confirm()
|
||||
return True
|
||||
|
||||
def run_script(self,ids,context={}):
|
||||
for inv in get_model("account.invoice").search_browse([]):
|
||||
inv.write({
|
||||
'due_date': '2%s'%(inv.due_date[1:]),
|
||||
'date': '2%s'%(inv.due_date[1:]),
|
||||
})
|
||||
print("Done")
|
||||
|
||||
ClinicSetting.register()
|
||||
|
|
|
@ -172,6 +172,11 @@ class Visit(Model):
|
|||
st=get_model("clinic.setting").browse(1)
|
||||
if st.find_dlz:
|
||||
dialyzer=self.get_dlz(obj.id)
|
||||
#XXX
|
||||
del dialyzer['state']
|
||||
del dialyzer['ultrafittration']
|
||||
del dialyzer['bid_flow_rate']
|
||||
del dialyzer['member_type']
|
||||
vals['dialyzers'].append(('create',dialyzer))
|
||||
|
||||
# use exist hd_case (in case set to draft)
|
||||
|
|
Loading…
Reference in New Issue