|
@@ -146,7 +146,7 @@ class LiveAccountReport:
|
|
on user.dept_id=dep.dept_id
|
|
on user.dept_id=dep.dept_id
|
|
) acc_info
|
|
) acc_info
|
|
on report.account_id = acc_info.account_id
|
|
on report.account_id = acc_info.account_id
|
|
- where report.report_date = {start_date} and report.report_date<={end_date}
|
|
|
|
|
|
+ where report.report_date >= {start_date} and report.report_date<={end_date}
|
|
and report.account_id = {account_id};
|
|
and report.account_id = {account_id};
|
|
""".format(start_date=start_date, end_date=end_date, account_id=account_id)
|
|
""".format(start_date=start_date, end_date=end_date, account_id=account_id)
|
|
print(sql)
|
|
print(sql)
|
|
@@ -293,7 +293,7 @@ class LiveAccountReport:
|
|
on user.dept_id=dep.dept_id
|
|
on user.dept_id=dep.dept_id
|
|
) acc_info
|
|
) acc_info
|
|
on report.account_id = acc_info.account_id
|
|
on report.account_id = acc_info.account_id
|
|
- where report.report_date = {start_date} and report.report_date<={end_date}
|
|
|
|
|
|
+ where report.report_date >= {start_date} and report.report_date<={end_date}
|
|
and report.account_id = {account_id};
|
|
and report.account_id = {account_id};
|
|
""".format(start_date=start_date, end_date=end_date, account_id=account_id)
|
|
""".format(start_date=start_date, end_date=end_date, account_id=account_id)
|
|
print(sql)
|
|
print(sql)
|
|
@@ -313,3 +313,7 @@ class LiveAccountReport:
|
|
self.daily_account(account_id, start_date, end_date)
|
|
self.daily_account(account_id, start_date, end_date)
|
|
else:
|
|
else:
|
|
self.account_hourly(account_id, start_date, end_date)
|
|
self.account_hourly(account_id, start_date, end_date)
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+if __name__ == '__main__':
|
|
|
|
+ LiveAccountReport().handler('hourly', 14670026, 20230321, 20230321)
|