opt: check coin

Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
bggRGjQaUbCoE
2025-04-11 21:49:43 +08:00
parent 3bc20ce1d4
commit 03e3b897cf

View File

@@ -349,7 +349,9 @@ class VideoIntroController extends GetxController
return; return;
} }
if (_coinNum.value >= 2) { int copyright =
(queryVideoIntroData.value['data'] as VideoDetailData?)?.copyright ?? 1;
if ((copyright != 1 && _coinNum.value >= 1) || _coinNum.value >= 2) {
SmartDialog.showToast('达到投币上限啦~'); SmartDialog.showToast('达到投币上限啦~');
return; return;
} }
@@ -361,9 +363,7 @@ class VideoIntroController extends GetxController
PayCoinsPage.toPayCoinsPage( PayCoinsPage.toPayCoinsPage(
onPayCoin: coinVideo, onPayCoin: coinVideo,
copyright: copyright: copyright,
(queryVideoIntroData.value['data'] as VideoDetailData?)?.copyright ??
1,
hasCoin: _coinNum.value == 1, hasCoin: _coinNum.value == 1,
); );
} }