[FIX] report_hd_case_detail:time in topic2 get data not work
parent
9de345409c
commit
21ad40d97d
|
@ -165,8 +165,8 @@ class ReportHDCaseDetail(Model):
|
||||||
title=titles.get(report_type,'no title')
|
title=titles.get(report_type,'no title')
|
||||||
title+=' '+prev_month_str
|
title+=' '+prev_month_str
|
||||||
prev_weekday, prev_total_day=monthrange(prev_year, prev_month)
|
prev_weekday, prev_total_day=monthrange(prev_year, prev_month)
|
||||||
reg_date='%s-%s-%s'%(prev_year,str(prev_month).zfill(2),str(prev_total_day).zfill(2))
|
reg_date='%s-%s-%s 23:59:59'%(prev_year,str(prev_month).zfill(2),str(prev_total_day).zfill(2))
|
||||||
print('topic2 ', reg_date)
|
#print('topic2 ', reg_date)
|
||||||
dom=[]
|
dom=[]
|
||||||
dom.append(['walkin','=',"no"])
|
dom.append(['walkin','=',"no"])
|
||||||
if branch_id:
|
if branch_id:
|
||||||
|
@ -252,7 +252,7 @@ class ReportHDCaseDetail(Model):
|
||||||
total+=1
|
total+=1
|
||||||
# all patient who are in hospital on select month
|
# all patient who are in hospital on select month
|
||||||
elif report_type=='topic5':
|
elif report_type=='topic5':
|
||||||
print('topic5 ', time_stop)
|
#print('topic5 ', time_stop)
|
||||||
title=titles.get(report_type,'no title')
|
title=titles.get(report_type,'no title')
|
||||||
title+=' '+next_month_str
|
title+=' '+next_month_str
|
||||||
dom=[]
|
dom=[]
|
||||||
|
@ -292,7 +292,7 @@ class ReportHDCaseDetail(Model):
|
||||||
total+=1
|
total+=1
|
||||||
# find patient movement
|
# find patient movement
|
||||||
elif report_type=='topic6':
|
elif report_type=='topic6':
|
||||||
print('topic6')
|
#print('topic6')
|
||||||
ptype=None
|
ptype=None
|
||||||
if patient_type_id:
|
if patient_type_id:
|
||||||
ptype=get_model('clinic.patient.type').browse(patient_type_id)
|
ptype=get_model('clinic.patient.type').browse(patient_type_id)
|
||||||
|
@ -449,7 +449,7 @@ class ReportHDCaseDetail(Model):
|
||||||
title+=' '+prev_month_str
|
title+=' '+prev_month_str
|
||||||
prev_weekday, prev_total_day=monthrange(prev_year, prev_month)
|
prev_weekday, prev_total_day=monthrange(prev_year, prev_month)
|
||||||
reg_date='%s-%s-%s'%(prev_year,str(prev_month).zfill(2),str(prev_total_day).zfill(2))
|
reg_date='%s-%s-%s'%(prev_year,str(prev_month).zfill(2),str(prev_total_day).zfill(2))
|
||||||
print('topic2 ', reg_date)
|
#print('topic2 ', reg_date)
|
||||||
dom=[]
|
dom=[]
|
||||||
dom.append(['reg_date','<=',reg_date])
|
dom.append(['reg_date','<=',reg_date])
|
||||||
dom.append(['walkin','=',"no"])
|
dom.append(['walkin','=',"no"])
|
||||||
|
@ -531,7 +531,7 @@ class ReportHDCaseDetail(Model):
|
||||||
total+=1
|
total+=1
|
||||||
# all patient who are in hospital on select month
|
# all patient who are in hospital on select month
|
||||||
elif report_type=='topic5':
|
elif report_type=='topic5':
|
||||||
print('topic5 ', time_stop)
|
#print('topic5 ', time_stop)
|
||||||
title=titles.get(report_type,'no title')
|
title=titles.get(report_type,'no title')
|
||||||
title+=' '+next_month_str
|
title+=' '+next_month_str
|
||||||
dom=[]
|
dom=[]
|
||||||
|
@ -566,7 +566,7 @@ class ReportHDCaseDetail(Model):
|
||||||
total+=1
|
total+=1
|
||||||
# find patient movement
|
# find patient movement
|
||||||
elif report_type=='topic6':
|
elif report_type=='topic6':
|
||||||
print('topic6')
|
#print('topic6')
|
||||||
ptype=None
|
ptype=None
|
||||||
if patient_type_id:
|
if patient_type_id:
|
||||||
ptype=get_model('clinic.patient.type').browse(patient_type_id)
|
ptype=get_model('clinic.patient.type').browse(patient_type_id)
|
||||||
|
|
Loading…
Reference in New Issue