chore: release v1.0.24
Deploy / build-linux-web (push) Successful in 59s
Deploy / build-windows (push) Successful in 1m50s
Deploy / build-macos (push) Successful in 1m22s
Deploy / build-android (push) Successful in 1m26s
Deploy / build-ios (push) Successful in 7s
Deploy / release-deploy (push) Successful in 1m39s
Deploy / build-linux-web (push) Successful in 59s
Deploy / build-windows (push) Successful in 1m50s
Deploy / build-macos (push) Successful in 1m22s
Deploy / build-android (push) Successful in 1m26s
Deploy / build-ios (push) Successful in 7s
Deploy / release-deploy (push) Successful in 1m39s
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -14,6 +14,7 @@ import '../../screens/finance/finance_screen.dart';
|
||||
import '../../screens/products/products_screen.dart';
|
||||
import '../../screens/products/product_detail_screen.dart';
|
||||
import '../../screens/public/public_product_screen.dart';
|
||||
import '../../screens/public/public_shop_products_screen.dart';
|
||||
import '../../screens/settings/settings_screen.dart';
|
||||
import '../../screens/about/about_screen.dart';
|
||||
import '../auth/auth_state.dart';
|
||||
@@ -40,7 +41,8 @@ class _RouterNotifier extends ChangeNotifier {
|
||||
final isLoggedIn = authState.isLoggedIn;
|
||||
final loc = state.matchedLocation;
|
||||
final isPublicRoute = loc == '/login' ||
|
||||
loc.startsWith('/product/');
|
||||
loc.startsWith('/product/') ||
|
||||
loc.startsWith('/shop/');
|
||||
final result = !authState.initialized
|
||||
? null
|
||||
: (!isLoggedIn && !isPublicRoute)
|
||||
@@ -79,6 +81,14 @@ final appRouterProvider = Provider<GoRouter>((ref) {
|
||||
builder: (context, state) =>
|
||||
PublicProductScreen(publicId: state.pathParameters['public_id']!),
|
||||
),
|
||||
// Public shop product list — no auth, no shell nav bar
|
||||
GoRoute(
|
||||
path: '/shop/:shop_code',
|
||||
builder: (context, state) => PublicShopProductsScreen(
|
||||
shopCode: state.pathParameters['shop_code']!,
|
||||
shopName: state.uri.queryParameters['shopName'] ?? '',
|
||||
),
|
||||
),
|
||||
GoRoute(
|
||||
path: '/login',
|
||||
builder: (context, state) => const LoginScreen(),
|
||||
|
||||
Reference in New Issue
Block a user