feat: implement boxing module with three modes (one2one, one2many, many2one)

- Add BoxInfoResult/BoxSaveResult data classes and API methods to ApiService
- Create BoxingPage with mode switching, auto-fill rules, duplicate detection
- Create BoxingDetailPage for read-only box detail view
- Activate boxing module in HomePage navigation

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Misaka_Company
2026-05-11 17:38:16 +08:00
parent cdc64bf82f
commit 5bae60cc82
5 changed files with 1649 additions and 7 deletions

View File

@@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
import 'package:pad_scanner/services/app_config_service.dart';
import 'package:pad_scanner/pages/settings_page.dart';
import 'package:pad_scanner/pages/registration_page.dart';
import 'package:pad_scanner/pages/boxing_page.dart';
import 'package:pad_scanner/services/api_service.dart';
/// Module type enum for each available feature card
@@ -60,8 +61,8 @@ class _HomePageState extends State<HomePage> {
icon: Icons.view_list_outlined,
title: '装箱编号',
description: '查询箱号、录入装箱明细',
status: ModuleStatus.developing,
version: null,
status: ModuleStatus.online,
version: 'v1.0',
route: '/boxing',
),
FeatureCard(
@@ -127,11 +128,7 @@ class _HomePageState extends State<HomePage> {
targetPage = const RegistrationPage();
break;
case ModuleType.boxing:
//TODO: Implement boxing page
targetPage = Scaffold(
appBar: AppBar(title: const Text('装箱编号')),
body: const Center(child: Text('开发中')),
);
targetPage = const BoxingPage();
break;
case ModuleType.shelfQuery:
return; // 规划中,不导航