chore(inventory): 리스트 수정 단추를 세부 액션으로 한정

- 입고·출고·대여 페이지 상단의 "선택 항목 수정" 버튼을 제거하고 상세 패널 내 수정 흐름만 노출\n- 제품 상세 다이얼로그에서 준비 중인 히스토리 섹션과 상수 정의를 제거해 UI를 단순화\n- 관련 위젯 테스트에서 히스토리 탭 검증을 삭제하고 문구를 최신 설명으로 갱신
This commit is contained in:
JiWoong Sul
2025-11-11 18:05:58 +09:00
parent d603fd5c17
commit eaac3c23ae
5 changed files with 1 additions and 68 deletions

View File

@@ -336,17 +336,6 @@ class _InboundPageState extends State<InboundPage> {
child: const Text('입고 등록'),
),
),
PermissionGate(
resource: PermissionResources.stockTransactions,
action: PermissionAction.edit,
child: ShadButton.outline(
leading: const Icon(lucide.LucideIcons.pencil, size: 16),
onPressed: _selectedRecord == null
? null
: () => _handleEdit(_selectedRecord!),
child: const Text('선택 항목 수정'),
),
),
],
toolbar: FilterBar(
actionConfig: FilterBarActionConfig(

View File

@@ -423,17 +423,6 @@ class _OutboundPageState extends State<OutboundPage> {
child: const Text('출고 등록'),
),
),
PermissionGate(
resource: PermissionResources.stockTransactions,
action: PermissionAction.edit,
child: ShadButton.outline(
leading: const Icon(lucide.LucideIcons.pencil, size: 16),
onPressed: _selectedRecord == null
? null
: () => _handleEdit(_selectedRecord!),
child: const Text('선택 항목 수정'),
),
),
],
toolbar: FilterBar(
actionConfig: FilterBarActionConfig(

View File

@@ -369,17 +369,6 @@ class _RentalPageState extends State<RentalPage> {
child: const Text('대여 등록'),
),
),
PermissionGate(
resource: PermissionResources.stockTransactions,
action: PermissionAction.edit,
child: ShadButton.outline(
leading: const Icon(lucide.LucideIcons.pencil, size: 16),
onPressed: _selectedRecord == null
? null
: () => _handleEdit(_selectedRecord!),
child: const Text('선택 항목 수정'),
),
),
],
toolbar: FilterBar(
actionConfig: FilterBarActionConfig(

View File

@@ -108,13 +108,6 @@ Future<ProductDetailDialogResult?> showProductDetailDialog({
icon: LucideIcons.link,
builder: (_) => _ProductRelationsSection(product: product),
),
if (product != null)
SuperportDetailDialogSection(
id: _ProductDetailSections.history,
label: '히스토리',
icon: LucideIcons.clock3,
builder: (_) => const _ProductHistorySection(),
),
_ProductFormSection(
id: product == null
? _ProductDetailSections.create
@@ -218,7 +211,6 @@ Future<ProductDetailDialogResult?> showProductDetailDialog({
/// 제품 상세 다이얼로그 섹션 정의 모음이다.
class _ProductDetailSections {
static const relations = 'relations';
static const history = 'history';
static const edit = 'edit';
static const delete = 'delete';
static const restore = 'restore';
@@ -265,29 +257,6 @@ class _ProductRelationsSection extends StatelessWidget {
}
}
/// 제품 변경 이력을 안내하는 섹션이다.
class _ProductHistorySection extends StatelessWidget {
const _ProductHistorySection();
@override
Widget build(BuildContext context) {
final theme = ShadTheme.of(context);
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text('현재 제품 변경 이력 데이터는 준비 중입니다.', style: theme.textTheme.small),
const SizedBox(height: 12),
Text(
'재고 입출고 추적 기능이 추가되면 히스토리를 통해 상태 변화를 확인할 수 있습니다.',
style: theme.textTheme.small.copyWith(
color: theme.colorScheme.mutedForeground,
),
),
],
);
}
}
/// 제품 등록/수정 폼을 제공하는 섹션이다.
class _ProductFormSection extends SuperportDetailDialogSection {
_ProductFormSection({

View File

@@ -48,7 +48,7 @@ void main() {
expect(find.text('등록'), findsWidgets);
});
testWidgets('showProductDetailDialog 상세 모드는 기본/연결/히스토리 정보를 제공한다', (
testWidgets('showProductDetailDialog 상세 모드는 기본/연결 정보를 제공한다', (
tester,
) async {
await tester.binding.setSurfaceSize(const Size(1280, 800));
@@ -95,8 +95,5 @@ void main() {
await tester.pumpAndSettle();
expect(find.textContaining('슈퍼벤더'), findsWidgets);
await tester.tap(find.text('히스토리'));
await tester.pumpAndSettle();
expect(find.textContaining('변경 이력 데이터는 준비 중입니다.'), findsOneWidget);
});
}