Linh Fish Dev
Author ProfileClaim This Author Profile
Prove ownership by publishing #HashtagPLUS and this profile link on your author page or an article under your byline. A moderator or admin will review the request before it merges into your real HashtagPLUS username.
🌐 dev.toSource
CRUD — the four create, read, update, and delete operations — is something almost every API needs. The standard way to do it in FastAPI is to put the database logic in CRUD functions built on SQLAlchemy 2.0, get the session from a yield dependency named get_db, and declare a clea
🌐 dev.toSource
When a model has 10-15 fields, its Django admin edit page becomes one endless column. Use fieldsets to group fields into titled, collapsible sections, and prepopulated_fields to auto-generate slugs from the title.
🌐 dev.toSource
Django already ships with send_mail() — configure SMTP once in settings.py and send email with a single call. No extra library, no hand-rolled smtplib code.