Updated pages

This commit is contained in:
Patrick Alvin Alcala 2026-01-27 17:52:51 +08:00
parent 794edf902a
commit 809cf7aa5f
3 changed files with 17 additions and 11 deletions

View file

@ -7,6 +7,7 @@ import 'package:ocbo_esign_mobile/functions/get_api.dart';
import 'package:ocbo_esign_mobile/widgets/box_widget.dart';
import 'package:ocbo_esign_mobile/widgets/input_widget.dart';
import 'package:ocbo_esign_mobile/widgets/text_widget.dart';
import 'package:intl/intl.dart';
class ValidateDetailPage extends StatefulWidget {
const ValidateDetailPage({super.key});
@ -17,18 +18,21 @@ class ValidateDetailPage extends StatefulWidget {
class _ValidateDetailPageState extends State<ValidateDetailPage> {
final _searchController = TextEditingController();
late double _total = 0;
late int _total = 0;
final NumberFormat formatter = NumberFormat('#,###.##');
void _getTotalSigned() async {
final name = await blocGetQr(context);
final response = await getApi('get-transactions-count', name, null);
log(name.toString());
log(response.toString());
final total = response['result'];
final responseCount = await getApi('get-transactions-count', name, null);
final total = responseCount['result'];
setState(() {
_total = double.parse(total);
_total = double.parse(total).toInt();
});
final response = await getApi('get-transactions', name, null);
final applicationNoList = response['result'];
final dateList = response['result2'];
}
@override
@ -72,7 +76,7 @@ class _ValidateDetailPageState extends State<ValidateDetailPage> {
children: [
Column(
children: [
TextWidget(text: _total.toString(), size: 64, bold: true),
TextWidget(text: formatter.format(_total), size: 64, bold: true),
TextWidget(text: 'Total Signed Applications', size: 16),
],
),