Files
opsxsql/frontend
logan 8161bcf5b5 feat: 权限组简化 + 工单撤销按钮
后端:
- InstanceGroup 新增 access_type (readonly/datachange/ddl) 和 allowed_databases 字段
- 创建 role_permissions.py 角色权限服务 (admin/dba/auditor/developer)
- SQLite ALTER TABLE 迁移脚本

前端:
- InstanceGroupPage 全面重写: 3种权限类型卡片(只读/数据变更/DDL)替代20+开关
- 新增/编辑弹窗: 权限类型选择 + 限定数据库输入
- 左侧列表显示权限类型标签
- 菜单标签: '权限管理' → '权限组'
- 工单列表 + 工单详情: 新增撤销按钮 (pending/reviewing 状态可撤销)
- API 类型定义: 新增 access_type/allowed_databases
2026-05-24 19:02:39 +08:00
..

React + TypeScript + Vite

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.

Currently, two official plugins are available:

React Compiler

The React Compiler is not enabled on this template because of its impact on dev & build performances. To add it, see this documentation.

Expanding the ESLint configuration

If you are developing a production application, we recommend updating the configuration to enable type-aware lint rules:

export default defineConfig([
  globalIgnores(['dist']),
  {
    files: ['**/*.{ts,tsx}'],
    extends: [
      // Other configs...

      // Remove tseslint.configs.recommended and replace with this
      tseslint.configs.recommendedTypeChecked,
      // Alternatively, use this for stricter rules
      tseslint.configs.strictTypeChecked,
      // Optionally, add this for stylistic rules
      tseslint.configs.stylisticTypeChecked,

      // Other configs...
    ],
    languageOptions: {
      parserOptions: {
        project: ['./tsconfig.node.json', './tsconfig.app.json'],
        tsconfigRootDir: import.meta.dirname,
      },
      // other options...
    },
  },
])

You can also install eslint-plugin-react-x and eslint-plugin-react-dom for React-specific lint rules:

// eslint.config.js
import reactX from 'eslint-plugin-react-x'
import reactDom from 'eslint-plugin-react-dom'

export default defineConfig([
  globalIgnores(['dist']),
  {
    files: ['**/*.{ts,tsx}'],
    extends: [
      // Other configs...
      // Enable lint rules for React
      reactX.configs['recommended-typescript'],
      // Enable lint rules for React DOM
      reactDom.configs.recommended,
    ],
    languageOptions: {
      parserOptions: {
        project: ['./tsconfig.node.json', './tsconfig.app.json'],
        tsconfigRootDir: import.meta.dirname,
      },
      // other options...
    },
  },
])