-- 2026-06-01
DELETE FROM `sys_role_menu`
WHERE `menu_id` IN (4023, 4024, 4025, 4026);

DELETE FROM `sys_menu`
WHERE `menu_id` IN (4023, 4024, 4025, 4026)
   OR `perms` = 'cc:xfttsconf:view'
   OR `perms` = 'aicall:xfvoiceclone:view'
   OR `perms` = 'aicall:xfvoiceclone:uploadAndTrain'
   OR `perms` = 'aicall:xfvoiceclone:ttsTest'
   OR `url` = '/cc/fsconf/xfttsconf'
   OR `url` = '/aicall/xfvoiceclone/voiceclone';

INSERT INTO `sys_menu` (`menu_id`, `menu_name`, `menu_code`, `parent_id`, `order_num`, `url`, `target`, `menu_type`, `visible`, `is_refresh`, `perms`, `icon`, `create_by`, `create_time`, `remark`)
VALUES (4023, '科大讯飞TTS配置', 'xfttsconf', 3019, 7, '/cc/fsconf/xfttsconf', 'menuItem', 'C', '0', '1', 'cc:xfttsconf:view', '#', 'admin', NOW(), '科大讯飞 TTS 参数配置菜单');

INSERT INTO `sys_menu` (`menu_id`, `menu_name`, `menu_code`, `parent_id`, `order_num`, `url`, `target`, `menu_type`, `visible`, `is_refresh`, `perms`, `icon`, `create_by`, `create_time`, `remark`)
VALUES (4024, '讯飞声音克隆', 'xfvoiceclone', 3019, 8, '/aicall/xfvoiceclone/voiceclone', 'menuItem', 'C', '0', '1', 'aicall:xfvoiceclone:view', 'fa fa-microphone', 'admin', NOW(), '讯飞一句话复刻工具');

INSERT INTO `sys_menu` (`menu_id`, `menu_name`, `menu_code`, `parent_id`, `order_num`, `url`, `target`, `menu_type`, `visible`, `is_refresh`, `perms`, `icon`, `create_by`, `create_time`, `remark`)
VALUES (4025, '讯飞声音克隆上传训练', 'xfvoicecloneUploadAndTrain', 4024, 1, '#', '', 'F', '0', '1', 'aicall:xfvoiceclone:uploadAndTrain', '#', 'admin', NOW(), '讯飞声音克隆上传训练权限');

INSERT INTO `sys_menu` (`menu_id`, `menu_name`, `menu_code`, `parent_id`, `order_num`, `url`, `target`, `menu_type`, `visible`, `is_refresh`, `perms`, `icon`, `create_by`, `create_time`, `remark`)
VALUES (4026, '讯飞声音克隆试听', 'xfvoicecloneTtsTest', 4024, 2, '#', '', 'F', '0', '1', 'aicall:xfvoiceclone:ttsTest', '#', 'admin', NOW(), '讯飞声音克隆试听权限');

INSERT INTO `sys_role_menu` (`role_id`, `menu_id`)
VALUES (2, 4023);

INSERT INTO `sys_role_menu` (`role_id`, `menu_id`)
VALUES (2, 4024),
       (2, 4025),
       (2, 4026);

 
