-- 直播间活动表添加 commitment 字段
-- 用于生成可验证的抽奖凭证

ALTER TABLE `livestream_activities` 
    ADD COLUMN `commitment_algo` VARCHAR(32) DEFAULT 'commit-v1' COMMENT '承诺算法版本' AFTER `status`,
    ADD COLUMN `commitment_seed_master` BLOB COMMENT '主种子(32字节)' AFTER `commitment_algo`,
    ADD COLUMN `commitment_seed_hash` BLOB COMMENT '种子SHA256哈希' AFTER `commitment_seed_master`,
    ADD COLUMN `commitment_state_version` INT DEFAULT 0 COMMENT '状态版本' AFTER `commitment_seed_hash`;
