-- 查询白名单迁移脚本（可选，与后台「导入历史硬编码」按钮等效）
-- 也可在管理后台 /admin/query-whitelist 点击「导入历史硬编码」完成导入
-- name = '*' 表示仅匹配身份证，不校验姓名（兼容历史硬编码逻辑）
-- api_codes 为原 processor 硬编码所在接口（司法 FLXG、特殊名单 JRZQ、企业司法 QYGL2S0W），非全部接口
-- 执行前请确认表已由 AutoMigrate 创建

INSERT INTO query_whitelist_entries (id, user_id, name, id_card_hash, id_card_masked, api_codes, status, remark, created_at, updated_at)
VALUES
  (gen_random_uuid()::text, '*', '*', '6db054d4cc4f4cadb3e08eaef45c09a9917ffb1c9baadfd9345a78744c4d5d23', '350681********0611', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', '4eaa05ddb07ff799b049d52f79a4f4d6453521e4c3bae8fa3dffb3172d241d01', '622301********0550', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', '4f930a44bf6246d6d358205d52e18b447e2ae83a808b8710416551dea6217b60', '320682********4998', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', '87d466b44e8bc33d25d1ef9654eefa7c2d50a34a5b7c25a221eab3fe6fe7e6a9', '640102********0925', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'c27b2f57a11b37831e799f0bd18526b141a5b90519ff6d790248698b2e527c09', '420624********4034', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'e9f421ce47c3934d6312d7275afa479d263fe788222163bd45981985dba8cdf8', '350104********4416', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', '5cbdcee2f32363fbbe6f7e4797285c3249355f6380b2af18c055bef97dd9c46d', '410521********8056', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'e1c8bf84aedd6ebbdeece59545bfe66cd4050373bde74fc161c0fd69034b76a6', '410482********9333', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', '43b8ee09dac65311e8a5e9f5701a36d34377eb508c04d1c3695e7ba1ddbe6016', '370982********7272', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', '4c041ff4bfcb75eb1fa6f2accefb3d68587f5e626f29536667d5997b3594b9b0', '431027********0730', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'e5220b9160cec7ce5f9d32bfee649e487f4ddc5e9a2b23c7b44dfc7c606bdb76', '362502********8017', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'f064061c4f7f6923bc96871bc7317131ea9c6dd1d8b6c547b6048a7fe7339dd5', '340826********0378', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', '84ed6390cb87b2142b1cf13317b252844e15237fb7317ce4dc927b33d8311e2d', '321027********2129', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'a082da9bc138c2ce91fed5d41c932dc9c5707f47cf3cca7d3169d25d971d3192', '420116********1413', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'a885a75377163280d23504fed43e7a7d3aded3c4deb94c3a83625af6a43092d2', '130323********263X', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'd9a6e6eabbc25f720f08322c82d9e0379143b093879999d2c01fa731ac97b4b9', '350681********3041', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW()),
  (gen_random_uuid()::text, '*', '*', 'ca36876c94d9ea535bc86bde90ac208a133908e3d9541bdd4dca0559c1109209', '330726********111X', '["FLXG0V4B","FLXG2E8F","FLXG3A9B","FLXG5A3B","FLXG7E8F","FLXG9C1D","FLXGCA3D","FLXGDEA8","FLXGDEA9","FLXGHB4F","FLXGK5D2","JRZQV7MD","JRZQ8A2D","QYGL2S0W"]', 'enabled', '自硬编码迁移-司法/特殊名单', NOW(), NOW())
ON CONFLICT DO NOTHING;
