beeeeg update
Some checks failed
Test and deploy staging / staging (push) Has been cancelled

This commit is contained in:
2026-09-23 04:15:10 +00:00
parent 487eff5bb2
commit d0c7b6548b
135 changed files with 9531 additions and 1777 deletions

View File

@@ -0,0 +1,22 @@
import { pgEnum, pgTable, text, unique } from 'drizzle-orm/pg-core';
import { id, timestamps } from './helpers';
export const blogArticleStatus = pgEnum('blog_article_status', ['draft', 'published']);
export const blogArticles = pgTable(
'blog_articles',
{
id: id(),
title: text('title').notNull(),
slug: text('slug').notNull(),
content: text('content').notNull().default(''),
tags: text('tags').array().notNull().default([]),
status: blogArticleStatus('status').notNull().default('draft'),
...timestamps
},
(table) => [unique().on(table.slug)]
);
export type BlogArticle = typeof blogArticles.$inferSelect;
export type NewBlogArticle = typeof blogArticles.$inferInsert;
export type BlogArticleStatus = (typeof blogArticleStatus.enumValues)[number];