fix to prod
This commit is contained in:
@@ -10,12 +10,14 @@ class CardBindingResultScreen extends StatefulWidget {
|
||||
final CardBindingStatus status;
|
||||
final String title;
|
||||
final String cardImagePath;
|
||||
final String redirectPath; // ← новое поле
|
||||
|
||||
const CardBindingResultScreen({
|
||||
super.key,
|
||||
required this.status,
|
||||
required this.title,
|
||||
required this.cardImagePath,
|
||||
this.redirectPath = '/home/payment-methods', // сохраняем текущее поведение по умолчанию
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -32,7 +34,7 @@ class _CardBindingResultScreenState extends State<CardBindingResultScreen> {
|
||||
_autoPopTimer = Timer(const Duration(seconds: 5), () {
|
||||
if (mounted) {
|
||||
final timestamp = DateTime.now().millisecondsSinceEpoch;
|
||||
context.go("/home/payment-methods?refreshId=$timestamp");
|
||||
context.go("${widget.redirectPath}?refreshId=$timestamp");
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -128,7 +130,7 @@ class _CardBindingResultScreenState extends State<CardBindingResultScreen> {
|
||||
text: "Попробовать снова",
|
||||
onTap: () {
|
||||
final timestamp = DateTime.now().millisecondsSinceEpoch;
|
||||
context.go("/home/payment-methods?refreshId=$timestamp");
|
||||
context.go("${widget.redirectPath}?refreshId=$timestamp");
|
||||
},
|
||||
enabled: true,
|
||||
showArrows: true,
|
||||
@@ -142,7 +144,7 @@ class _CardBindingResultScreenState extends State<CardBindingResultScreen> {
|
||||
onPressed: ()
|
||||
{
|
||||
final timestamp = DateTime.now().millisecondsSinceEpoch;
|
||||
context.go("/home/payment-methods?refreshId=$timestamp");
|
||||
context.go("${widget.redirectPath}?refreshId=$timestamp");
|
||||
},
|
||||
style: TextButton.styleFrom(
|
||||
shape: RoundedRectangleBorder(
|
||||
|
||||
Reference in New Issue
Block a user