fix: i forgot lol
This commit is contained in:
parent
f1a7f5f7b0
commit
ca1eeafd8f
2 changed files with 43 additions and 3 deletions
11
lib/domain/models/return_owner.dart
Normal file
11
lib/domain/models/return_owner.dart
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
import 'package:seshat/domain/models/book_instance.dart';
|
||||
import 'package:seshat/domain/models/owner.dart';
|
||||
|
||||
class ReturnOwner {
|
||||
ReturnOwner(this.owner, this.owned, this.ownedMoney);
|
||||
Owner owner;
|
||||
List<BookInstance> owned;
|
||||
double ownedMoney;
|
||||
|
||||
// factory ReturnOwner.fromJSON(Map<String, dynamic>) {}
|
||||
}
|
||||
|
|
@ -2,17 +2,46 @@ import 'package:flutter/material.dart';
|
|||
import 'package:seshat/ui/bal_page/view_model/bal_view_model.dart';
|
||||
import 'package:seshat/ui/core/ui/navigation_bar.dart';
|
||||
|
||||
class BalEndedScreen extends StatelessWidget {
|
||||
class BalEndedScreen extends StatefulWidget {
|
||||
const BalEndedScreen({super.key, required this.viewModel});
|
||||
|
||||
final BalViewModel viewModel;
|
||||
|
||||
@override
|
||||
State<BalEndedScreen> createState() => _BalEndedScreenState();
|
||||
}
|
||||
|
||||
class _BalEndedScreenState extends State<BalEndedScreen>
|
||||
with TickerProviderStateMixin {
|
||||
late final TabController tabController;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
tabController = TabController(length: 2, vsync: this);
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
bottomNavigationBar: AppNavigationBar(startIndex: 0),
|
||||
appBar: AppBar(title: Text(viewModel.bal!.name)),
|
||||
body: Center(child: Text("Coming Soon.")),
|
||||
appBar: AppBar(
|
||||
title: Text(widget.viewModel.bal!.name),
|
||||
bottom: TabBar(
|
||||
controller: tabController,
|
||||
tabs: [
|
||||
Tab(text: "Statistiques"),
|
||||
Tab(text: "Livres à rendre"),
|
||||
],
|
||||
),
|
||||
),
|
||||
body: TabBarView(
|
||||
controller: tabController,
|
||||
children: [
|
||||
Center(child: Text("Coming soon")),
|
||||
Center(child: Text("Coming soon.")),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Reference in a new issue