-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.py
More file actions
36 lines (27 loc) · 940 Bytes
/
Copy pathtest.py
File metadata and controls
36 lines (27 loc) · 940 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# from models import Transactions, Users
# from connect import db
# from flask_login import current_user
# all_data = Transactions.query.all()
# all_data1 = Users.query.all()
# # for row in all_data:
# # print(f"{row.id}, {row.description}, {row.cashFlow}, {row.cat}, {row.date}, {row.amount}, {row.userId}")
# # for row in all_data1:
# # print(f"{row.profile_image}")
# from datetime import datetime
# uid = current_user.id
# print(uid)
# print(type(uid))
# today = datetime.today()
# datem = datetime(today.year, today.month, 1)
# # print(today)
# # print(datem)
# # monthlyTransactions = Transactions.query.filter_by(date < str(datem)).all()
# # print(monthlyTransactions)
# # print(monthlyTransactions.cat)
from datetime import datetime
# datetime object containing current date and time
now = datetime.now()
print("now =", now)
# dd/mm/YY H:M:S
dt_string = now.strftime("%H:%M:%S")
print("date and time =", dt_string)