Skip to content

Commit

Permalink
feat: route for publishing view
Browse files Browse the repository at this point in the history
  • Loading branch information
AhsanRns committed May 16, 2024
1 parent d3bca2a commit f1b8c1f
Show file tree
Hide file tree
Showing 3 changed files with 35 additions and 2 deletions.
2 changes: 1 addition & 1 deletion evently/lib/services/datasources/local_datasource.dart
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class LocalDataSourceImpl extends LocalDataSource {
/// returns cookbookId
@override
Future<String> autoGenerateCookbookId() async {
final String cookbookId = "Easel_CookBook_auto_cookbook_${getFullDateTime()}";
final String cookbookId = "Evently_CookBook_auto_cookbook_${getFullDateTime()}";
await sharedPreferences.setString(kCookbookId, cookbookId);
return cookbookId;
}
Expand Down
24 changes: 24 additions & 0 deletions wallet/lib/pages/events/events_screen.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import 'package:flutter/material.dart';

import '../../model/event.dart';

class EventPassViewScreen extends StatefulWidget {
const EventPassViewScreen({super.key, required this.events});

final Events events;

@override
State<EventPassViewScreen> createState() => _EventPassViewScreenState();
}

class _EventPassViewScreenState extends State<EventPassViewScreen> {
@override
Widget build(BuildContext context) {
return const Scaffold(
backgroundColor: Colors.black,
body: Column(
children: [],
),
);
}
}
11 changes: 10 additions & 1 deletion wallet/lib/utils/route_util.dart
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
// ignore_for_file: cast_nullable_to_non_nullable

import 'package:flutter/material.dart';
import 'package:pylons_wallet/pages/events/events_screen.dart';
import 'package:pylons_wallet/pages/settings/screens/general_screen/general_screen.dart';
import 'package:pylons_wallet/pages/settings/screens/recovery_screen/recovery_screen.dart';

import '../model/event.dart';
import '../model/nft.dart';
import '../model/transaction_failure_model.dart';
import '../pages/detailed_asset_view/owner_view.dart';
Expand Down Expand Up @@ -112,7 +114,14 @@ class RouteUtil {
case Routes.transactionHistory:
return createRoute(const TransactionHistoryScreen());
case Routes.eventView:
return createRoute(const Placeholder());
if (settings.arguments != null && settings.arguments is NFT) {
return createRoute(EventPassViewScreen(
key: ValueKey(settings.arguments),
events: settings.arguments as Events,
));
}

return createRoute(const SizedBox());
}

return null;
Expand Down

0 comments on commit f1b8c1f

Please sign in to comment.