feat: add temp storage shelf (B prefix) UI support

Recognize B-prefix location codes as temp storage shelves. Add purple
color scheme, conflict detection for temp_stored status, and updated
submit/dialog logic for temp storage target handling.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Misaka
2026-05-25 22:48:29 +08:00
parent f6bfd8cb10
commit 99ed3bb9ec
9 changed files with 125 additions and 15 deletions

View File

@@ -97,6 +97,7 @@ extension _RegistrationDialogsPart on _RegistrationPageState {
void _showLocationConflictDialog({
required List<PaichaOverviewItem> onShelfItems,
required List<PaichaOverviewItem> transferredItems,
List<PaichaOverviewItem> tempStoredItems = const [],
}) {
final contentParts = <Widget>[];
@@ -142,6 +143,29 @@ extension _RegistrationDialogsPart on _RegistrationPageState {
}
}
if (tempStoredItems.isNotEmpty) {
if (onShelfItems.isNotEmpty || transferredItems.isNotEmpty) {
contentParts.add(const Divider());
contentParts.add(const SizedBox(height: 4));
}
contentParts.add(
Text(
'暂存中',
style: TextStyle(
fontWeight: FontWeight.bold,
color: const Color(0xFF7B1FA2),
),
),
);
for (final item in tempStoredItems) {
contentParts.addAll([
Text('总排号:${item.zongpaiNo}'),
Text('暂存货位:${item.locationCode ?? "未知"}'),
const SizedBox(height: 6),
]);
}
}
contentParts.add(const SizedBox(height: 4));
contentParts.add(
const Text(