tons of fun

This commit is contained in:
2025-06-04 01:40:12 -05:00
parent e8acd6bb20
commit c885ede8af
18 changed files with 206 additions and 209 deletions

View File

@ -1,6 +1,6 @@
from app import db
from datetime import datetime
from plugins.plant.models import Plant
class Media(db.Model):
__tablename__ = 'media'
@ -10,7 +10,7 @@ class Media(db.Model):
file_url = db.Column(db.String(256), nullable=False)
uploaded_at = db.Column(db.DateTime, default=datetime.utcnow)
plant_id = db.Column(db.Integer, db.ForeignKey('plants.id'), nullable=True)
plant_id = db.Column(db.Integer, db.ForeignKey('plant.id'), nullable=True)
growlog_id = db.Column(db.Integer, db.ForeignKey('grow_logs.id'), nullable=True)
update_id = db.Column(db.Integer, db.ForeignKey('plant_updates.id'), nullable=True)