- 添加批量更新API: POST /prison/question/batch-update - 修复savePartitions循环调用API问题 (50题只需1次请求) - 修复onPartitionDragEnd拖拽排序性能问题 - 修复onQuestionDragEnd问题拖拽排序性能问题 - 添加自动填充来源字典支持 (35个选项) 修改文件: backend: - QuestionBatchUpdateReqVO.java (新增) - PrisonQuestionController.java - QuestionService.java - QuestionServiceImpl.java frontend: - api/prison/question/index.ts - views/prison/questionnaire/components/QuestionList.vue - utils/dict.ts - views/prison/question/QuestionForm.vue Refs: xlcp-frontend#1, xlcp-backend#1
87 lines
3.4 KiB
Markdown
87 lines
3.4 KiB
Markdown
# Implementation Plan - 2026-01-12
|
|
|
|
## Source Analysis
|
|
|
|
**Source Type**: Local codegen zip files
|
|
**Location**: `/Volumes/Dpan/github/xlcp/codegen/`
|
|
|
|
**Modules to integrate (8 total)**:
|
|
| Module | Chinese Name | Backend Path | Frontend Path |
|
|
|--------|-------------|--------------|---------------|
|
|
| Area | 监区管理 | `controller/admin/area/` | `views/prison/area/` |
|
|
| Cell | 监室管理 | `controller/admin/cell/` | `views/prison/cell/` |
|
|
| Consumption | 消费记录 | `controller/admin/consumption/` | `views/prison/consumption/` |
|
|
| Question | 问卷问题 | `controller/admin/question/` | `views/prison/question/` |
|
|
| Questionnaire | 问卷模板 | `controller/admin/questionnaire/` | `views/prison/questionnaire/` |
|
|
| QuestionnaireRecord | 问卷答题记录 | `controller/admin/questionnairerecord/` | `views/prison/questionnairerecord/` |
|
|
| RiskAssessment | 危险评估 | `controller/admin/riskassessment/` | `views/prison/riskassessment/` |
|
|
| Score | 计分考核 | `controller/admin/score/` | `views/prison/score/` |
|
|
|
|
**Core Features per Module**:
|
|
- CRUD operations (Controller, Service, ServiceImpl)
|
|
- DO (Data Object with table mapping)
|
|
- Mapper (MyBatis-Plus)
|
|
- VO (PageReqVO, RespVO, SaveReqVO)
|
|
- Frontend (index.vue, Form.vue, API index.ts)
|
|
- Menu SQL scripts
|
|
|
|
## Target Integration
|
|
|
|
**Backend Target**: `yudao-module-prison/`
|
|
**Frontend Target**: `frontend/src/`
|
|
|
|
**Affected Files**:
|
|
- Backend: New packages for each module
|
|
- Frontend: New directories under views/prison/ and api/prison/
|
|
- ErrorCodeConstants: Merge new error codes
|
|
|
|
## Implementation Tasks
|
|
|
|
### Backend Integration
|
|
- [ ] 1. Integrate Area module (监区管理)
|
|
- [ ] 2. Integrate Cell module (监室管理)
|
|
- [ ] 3. Integrate Consumption module (消费记录)
|
|
- [ ] 4. Integrate Question module (问卷问题)
|
|
- [ ] 5. Integrate Questionnaire module (问卷模板)
|
|
- [ ] 6. Integrate QuestionnaireRecord module (问卷答题记录)
|
|
- [ ] 7. Integrate RiskAssessment module (危险评估)
|
|
- [ ] 8. Integrate Score module (计分考核)
|
|
- [ ] 9. Update ErrorCodeConstants with new error codes
|
|
- [ ] 10. Update module pom.xml if needed
|
|
|
|
### Frontend Integration
|
|
- [ ] 11. Integrate Area frontend
|
|
- [ ] 12. Integrate Cell frontend
|
|
- [ ] 13. Integrate Consumption frontend
|
|
- [ ] 14. Integrate Question frontend
|
|
- [ ] 15. Integrate Questionnaire frontend
|
|
- [ ] 16. Integrate QuestionnaireRecord frontend
|
|
- [ ] 17. Integrate RiskAssessment frontend
|
|
- [ ] 18. Integrate Score frontend
|
|
- [ ] 19. Update dict.ts with new enum types
|
|
- [ ] 20. Update constants.ts if needed
|
|
|
|
### Database Integration
|
|
- [ ] 21. Create consolidated SQL script
|
|
- [ ] 22. Run SQL to create tables
|
|
- [ ] 23. Run SQL to insert menu permissions
|
|
|
|
## Validation Checklist
|
|
- [x] All 8 modules integrated
|
|
- [ ] Backend compiles successfully (TODO: verify)
|
|
- [ ] Frontend builds successfully (TODO: verify)
|
|
- [ ] No duplicate class definitions
|
|
- [ ] Error codes properly merged
|
|
- [x] Menu SQL ready for execution
|
|
|
|
## Completed: 2026-01-12
|
|
All 8 modules have been integrated:
|
|
- Backend files copied to yudao-module-prison
|
|
- Frontend files copied to frontend/src/
|
|
- SQL script created at yudao-module-prison/src/main/resources/sql/prison_module.sql
|
|
|
|
## Risk Mitigation
|
|
- **Encoding issue**: Some files have garbled Chinese characters - will regenerate or manually fix
|
|
- **Duplicate ErrorCodeConstants**: Need to merge with existing file instead of overwriting
|
|
- **Frontend path mismatch**: Generated files use `yudao-ui-admin-vue3/` prefix - need to strip
|