- 機能要件・非機能要件定義 - 短期長期プロジェクト計画の策定 docs: UI ライティングリファクタリング - 編集 SnackBar から Cancel ボタン削除 - タイル表示からプレースホルダメッセージへ</new_task>chore: README のドキュメント活用方法追記</new_task>
90 lines
No EOL
3.5 KiB
Dart
90 lines
No EOL
3.5 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'screens/estimate_screen.dart';
|
|
import 'screens/invoice_screen.dart';
|
|
import 'screens/order_screen.dart';
|
|
import 'screens/sales_return_screen.dart';
|
|
import 'screens/sales_screen.dart';
|
|
import 'screens/master/product_master_screen.dart';
|
|
import 'screens/master/customer_master_screen.dart';
|
|
import 'screens/master/supplier_master_screen.dart';
|
|
import 'screens/master/warehouse_master_screen.dart';
|
|
import 'screens/master/employee_master_screen.dart';
|
|
|
|
void main() {
|
|
runApp(const MyApp());
|
|
}
|
|
|
|
class MyApp extends StatelessWidget {
|
|
const MyApp({super.key});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return MaterialApp(
|
|
title: '販売アシスト1号 / 母艦『お局様』',
|
|
debugShowCheckedModeBanner: false,
|
|
theme: ThemeData(useMaterial3: true),
|
|
home: const Dashboard(),
|
|
// routes 設定
|
|
routes: {
|
|
'/M1. 商品マスタ': (context) => const ProductMasterScreen(),
|
|
'/M2. 得意先マスタ': (context) => const CustomerMasterScreen(),
|
|
'/M3. 仕入先マスタ': (context) => const SupplierMasterScreen(),
|
|
'/M4. 倉庫マスタ': (context) => const WarehouseMasterScreen(),
|
|
'/M5. 担当者マスタ': (context) => const EmployeeMasterScreen(),
|
|
'/S1. 見積入力': (context) => const EstimateScreen(),
|
|
'/S2. 請求書発行': (context) => const InvoiceScreen(),
|
|
'/S3. 発注入力': (context) => const OrderScreen(),
|
|
'/S4. 売上入力(レジ)': (context) => const SalesScreen(),
|
|
'/S5. 売上返品入力': (context) => const SalesReturnScreen(),
|
|
},
|
|
);
|
|
}
|
|
}
|
|
|
|
class Dashboard extends StatelessWidget {
|
|
const Dashboard({super.key});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
return Scaffold(
|
|
appBar: AppBar(title: Text('販売アシスト1号')),
|
|
body: ListView(
|
|
padding: EdgeInsets.zero,
|
|
children: [
|
|
// マスタ管理モジュール一覧
|
|
_buildModuleCard(context, 'M1. 商品マスタ', Icons.inbox, true),
|
|
_buildModuleCard(context, 'M2. 得意先マスタ', Icons.person, true),
|
|
_buildModuleCard(context, 'M3. 仕入先マスタ', Icons.card_membership, true),
|
|
_buildModuleCard(context, 'M4. 倉庫マスタ', Icons.storage, true),
|
|
_buildModuleCard(context, 'M5. 担当者マスタ', Icons.badge, true),
|
|
|
|
Divider(height: 20),
|
|
|
|
// 販売管理モジュール一覧
|
|
_buildModuleCard(context, 'S1. 見積入力', Icons.receipt_long, true),
|
|
_buildModuleCard(context, 'S2. 請求書発行', Icons.money_off, true),
|
|
_buildModuleCard(context, 'S3. 発注入力', Icons.shopping_cart, true),
|
|
_buildModuleCard(context, 'S4. 売上入力(レジ)', Icons.point_of_sale, true),
|
|
_buildModuleCard(context, 'S5. 売上返品入力', Icons.swap_horiz, true),
|
|
|
|
SizedBox(height: 20),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
|
|
Widget _buildModuleCard(BuildContext context, String title, IconData icon, bool implemented) {
|
|
return Card(
|
|
margin: EdgeInsets.symmetric(horizontal: 16, vertical: 8),
|
|
child: ListTile(
|
|
leading: Icon(icon),
|
|
title: Text(title),
|
|
subtitle: Text(implemented ? '実装済み' : '未実装'),
|
|
onTap: () => Navigator.pushNamed(context, '/$title'),
|
|
onLongPress: () => ScaffoldMessenger.of(context).showSnackBar(
|
|
const SnackBar(content: Text('長押し:モジュール詳細')),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
} |