mirror of
https://github.com/ferdzo/iotDashboard.git
synced 2026-04-05 01:06:24 +00:00
Update small
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -4,3 +4,4 @@ db.sqlite3
|
|||||||
demo.db
|
demo.db
|
||||||
demo.db-shm
|
demo.db-shm
|
||||||
demo.db-wal
|
demo.db-wal
|
||||||
|
__pycache__/
|
||||||
|
|||||||
@@ -105,7 +105,7 @@ def insert_data(data, sensor_type):
|
|||||||
except Exception as e:
|
except Exception as e:
|
||||||
print(f"Failed to insert data: {e}")
|
print(f"Failed to insert data: {e}")
|
||||||
|
|
||||||
@periodic_task(crontab(minute='*/1'))
|
@periodi c_task(crontab(minute='*/1'))
|
||||||
def fetch_data_from_all_devices():
|
def fetch_data_from_all_devices():
|
||||||
"""Fetch and insert data for all devices based on their protocol."""
|
"""Fetch and insert data for all devices based on their protocol."""
|
||||||
devices = Device.objects.all()
|
devices = Device.objects.all()
|
||||||
|
|||||||
Reference in New Issue
Block a user