feat(glossary): added pass key for glossary

This commit is contained in:
misha
2025-09-29 09:13:45 +03:00
parent 68ea8da6e3
commit c88b010cc5
11 changed files with 137 additions and 76 deletions

View File

@@ -3,8 +3,8 @@ import 'package:flutter/material.dart';
import 'package:webview_flutter/webview_flutter.dart';
class GlossaryScreen extends StatefulWidget {
const GlossaryScreen({super.key});
const GlossaryScreen({super.key, required this.passKey});
final String passKey;
@override
State<GlossaryScreen> createState() => _GlossaryScreenState();
}
@@ -18,15 +18,13 @@ class _GlossaryScreenState extends State<GlossaryScreen> {
_controller = WebViewController()
..setJavaScriptMode(JavaScriptMode.unrestricted)
..loadRequest(Uri.parse('$baseUrl/product_nutritional_value'));
..loadRequest(Uri.parse('$baseUrl/login_with_pass_key?id=${widget.passKey}'));
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: const Text('Глоссарий'),
),
appBar: AppBar(title: const Text('Глоссарий')),
body: WebViewWidget(controller: _controller),
);
}