Commit 0dcc9fc3 by Aeolus

update

parent 6245dc0a
......@@ -510,15 +510,15 @@ def run_apply_draw():
LEFT JOIN business ON business.id = rent.business_id
WHERE
0 = 0
AND rent.created_at < '2022-02-24 00:00:00'
AND admin_business.user_id = '2'
AND rent.created_at < '{}'
AND admin_business.user_id = '{}'
AND admin_business.status = 1
AND admin_business.rate > 0
GROUP BY DATE_FORMAT(rent.created_at, '%Y-%m-%d') , rent.business_id) AS tab1
WHERE
real_total > '0'
and bill_date = '{}'
""".format(bill_date)
""".format(datetime.datetime.now().date().strftime("%Y-%m-%d %H:%M:%S"), g.user.id, bill_date)
result = db.session.execute(sql).fetchone()
if result:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment