- from flask_sqlalchemy import SQLAlchemy
- from flask import Flask
- app = Flask(__name__)
- app.config['SQLALCHEMY_DATABASE_URI'] = 'sqlite:///management.db'
- db = SQLAlchemy(app)
- class Task(db.Model):
- id = db.Column(db.Integer, primary_key=True)
- title = db.Column(db.String(100), nullable=False)
- complete = db.Column(db.Boolean, default=False)
- def __repr__(self):
- return f'<Task {self.id}: {self.title}, Complete: {self.complete}>'
[text] task managment task
Viewer
*** This page was generated with the meta tag "noindex, nofollow". This happened because you selected this option before saving or the system detected it as spam. This means that this page will never get into the search engines and the search bot will not crawl it. There is nothing to worry about, you can still share it with anyone.
Editor
You can edit this paste and save as new:
File Description
- task managment task
- Paste Code
- 17 Apr-2024
- 467 Bytes
You can Share it:
Latest Code Pastes