DELETE FROM sys_api_permission
WHERE api_id IN (SELECT id FROM sys_apis WHERE group_name = '文章管理');

DELETE FROM sys_permissions
WHERE id IN (
    SELECT permission_id FROM sys_api_permission
    WHERE api_id IN (SELECT id FROM sys_apis WHERE group_name = '文章管理')
);

DELETE FROM sys_apis WHERE group_name = '文章管理';

DELETE FROM sys_menu_permission
WHERE menu_id IN (SELECT id FROM sys_menus WHERE path = '/post');

DELETE FROM sys_permissions WHERE code = 'post' AND type = 1;

DELETE FROM sys_menus WHERE path = '/post';

DROP TABLE IF EXISTS posts;