-- 规则引擎默认数据：插入「注册」规则，供登录后完善头像引导
-- 执行：mysql -u user -p db < soul-api/scripts/add-user-rules-default.sql
-- 幂等：若已存在 trigger='注册' 则跳过

INSERT INTO user_rules (title, description, `trigger`, sort, enabled, created_at, updated_at)
SELECT '完善个人信息', '设置头像和昵称，让其他创业者更容易认识你', '注册', 1, 1, NOW(), NOW()
FROM DUAL
WHERE NOT EXISTS (SELECT 1 FROM user_rules WHERE `trigger` = '注册' LIMIT 1);
