添加迁移脚本以支持数据库版本管理,配置 pnpm workspace 仅构建 supabase 依赖 新增用户登录字段和任务帮助请求功能,禁用 tasks 和 task_steps 表的 RLS 更新环境变量示例以支持自托管 Supabase 实例
16 lines
394 B
SQL
16 lines
394 B
SQL
alter table public.users
|
|
add column if not exists username text null,
|
|
add column if not exists password_hash text null;
|
|
|
|
do $$
|
|
begin
|
|
if not exists (
|
|
select 1
|
|
from pg_indexes
|
|
where schemaname = 'public'
|
|
and indexname = 'users_username_unique'
|
|
) then
|
|
create unique index users_username_unique on public.users (username) where username is not null;
|
|
end if;
|
|
end $$;
|