ki-backend/ki/commands.py

10 lines
206 B
Python
Raw Normal View History

2021-06-07 17:52:14 +02:00
from ki.models import Skill
from app import app, db
@app.cli.command("seed")
def seed():
db.session.add(Skill(id=1, name="PHP"))
db.session.add(Skill(id=2, name="Vue.js"))
db.session.commit()