add day
This commit is contained in:
parent
13f95077d3
commit
2d772826fb
@ -16,6 +16,7 @@ def on_message(client, userdata, msg):
|
||||
seconds = (now - midnight).seconds
|
||||
j['metadata']['timestamp'] = datetime.datetime.now()
|
||||
j['metadata']['seconds'] = seconds
|
||||
j['metadata']['day'] = midnight
|
||||
print(j)
|
||||
mongoClient = pymongo.MongoClient('localhost')
|
||||
db = mongoClient.iot
|
||||
|
Loading…
x
Reference in New Issue
Block a user