ki-backend/ki/commands.py

10 lines
206 B
Python

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()