Skip to content

feat: 文件格式导入支持扩展 - 前端#810

Open
actiontech-bot wants to merge 9 commits intomainfrom
sqle/feat-3228
Open

feat: 文件格式导入支持扩展 - 前端#810
actiontech-bot wants to merge 9 commits intomainfrom
sqle/feat-3228

Conversation

@actiontech-bot
Copy link
Copy Markdown
Member

Summary

  • 更新 i18n 文本,新增 .txt/.java 格式说明,压缩包 Tab 重命名为"上传压缩包"
  • 新增 XLSX i18n key (xlsxTemplateTips, downloadTemplate, noSqlColumnFound)
  • 更新 accept 属性:SQL 文件 Tab 增加 .xlsx,压缩包 Tab 增加 .rar/.7z
  • 新增 XLSX 模板下载 UI 和模板文件 (xlsx_template.xlsx)
  • 部署模板到 base/public/static 确保 Vite 构建包含

Test plan

  • 验证文件选择器 accept 属性正确
  • 验证 i18n 中英文文本
  • 验证 XLSX 模板下载功能
  • 运行组件测试

Update Chinese and English i18n texts in execWorkflow.ts and sqlAudit.ts:
- sqlFileTips: mention .sql, .txt, .java formats
- zipFile/zipFileTips: rename from "zip文件"/"Zip file" to "压缩包"/"Compressed file",
  mention .zip, .rar, .7z formats and supported inner file types
- uploadZipFile tab label: align with new naming
Verify that execWorkflow and sqlAudit i18n keys are complete and
symmetric between zh-CN and en-US, and that file upload tip texts
mention all required formats (.sql/.txt/.java and .zip/.rar/.7z).
- Add xlsxTemplateTips, downloadTemplate, noSqlColumnFound keys to
  execWorkflow and sqlAudit locale files (zh-CN and en-US)
- Update sqlFileTips to include .xlsx in format list
- Both execWorkflow and sqlAudit i18n files updated symmetrically
- Add xlsxTemplateTips, downloadTemplate, noSqlColumnFound to required keys
  for both execWorkflow and sqlAudit (zh-CN and en-US)
- Update sqlFileTips content checks to verify .xlsx format inclusion
Extend SQL upload accept from .sql to .sql,.txt,.java and ZIP upload
accept from .zip to .zip,.rar,.7z on both the workflow creation page
(SqlUploadContent.tsx) and the quick audit page (SqlUploadCont/index.tsx).
…pt attributes

Verify that SQL file upload accepts .sql,.txt,.java and ZIP file upload
accepts .zip,.rar,.7z on both workflow create page and quick audit page.
Also verify that i18n tip texts mention the correct supported formats.
- Update SQL file upload accept to .sql,.txt,.java,.xlsx in both
  SqlUploadContent.tsx and SqlUploadCont/index.tsx
- Add XLSX template download tip and link below SQL file upload area
- Add standard XLSX template file (序号/SQL/备注) as static asset
- Add new i18n keys: xlsxTemplateTips, downloadTemplate, noSqlColumnFound
- Update sqlFileTips to include .xlsx format in both pages
- Sync dms-ui-ee locale copies with latest i18n text changes
…ring fixes

- Update SQL upload accept validation from .sql,.txt,.java to .sql,.txt,.java,.xlsx
- Add tests for XLSX template tips text (xlsxTemplateTips) rendering
- Add tests for template download link href and download attribute
- Fix rendering by using sqleSuperRender for theme context (uiToken)
- Fix SqlUploadCont Form.useWatch by using TestWrapper with hidden Form.Item
- Fix negative tests to avoid CustomMonacoEditor Redux dependency
The xlsx_template.xlsx was placed in packages/sqle/public/static/ but
the Vite build entry point is the base package. Only files in
packages/base/public/ are copied to dist/ during build. This caused
the template to be missing from the deployed static directory, making
the "Download template" link return SPA index.html instead of the
actual XLSX file (BUG-004).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants