import 'package:flutter/material.dart';

import 'package:get/get.dart';


import '../../../core/constants/translation_keys.dart';
import '../../../custom_widgets/custom_app_bar.dart';
import '../../../res/app_colors.dart';
import '../controllers/cheque_status_history_controller.dart';

class ChequeStatusHistoryView extends GetView<ChequeStatusHistoryController> {
  const ChequeStatusHistoryView({Key? key}) : super(key: key);
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: DashBoardAppBar(
        title: TranslationKeys.makeTranslation(
            TranslationKeys.textChequeStatusHistory),
        onBackButtonPressed: () {
          Get.back();
        },
      ),
      body: Padding(
        padding: EdgeInsets.symmetric(horizontal: 20, vertical: 20),
        child: Column(
          crossAxisAlignment: CrossAxisAlignment.start,
          children: [
            Text(
                TranslationKeys.makeTranslation(
                    TranslationKeys.textChequeStatusHistoryContent),
                style: Theme.of(context).textTheme.bodySmall),
            SizedBox(height: 20),
            Card(
              surfaceTintColor: Colors.white,
              elevation: 2,
              child: Container(
                decoration: BoxDecoration(
                  borderRadius: BorderRadius.circular(10),
                  border: Border(
                    left: BorderSide(
                      color: AppColors.colorPrimary,
                      width: 5.0,
                    ),
                  ),
                ),
                child: Card(
                  surfaceTintColor: Colors.white,
                  elevation: 0,
                  child: Row(
                    mainAxisAlignment: MainAxisAlignment.spaceBetween,
                    crossAxisAlignment: CrossAxisAlignment.start,
                    children: [
                      Padding(
                        padding:
                        EdgeInsets.symmetric(horizontal: 10, vertical: 10),
                        child: Column(
                          crossAxisAlignment: CrossAxisAlignment.start,
                          children: [
                            Text(
                                TranslationKeys.makeTranslation(
                                    TranslationKeys.textBillDetailCustomerName),
                                style: Theme.of(context).textTheme.titleSmall),
                            SizedBox(height: 5),
                            Text(
                                TranslationKeys.makeTranslation(TranslationKeys
                                    .textChequeStatusCheckNumber),
                                style: Theme.of(context).textTheme.bodySmall),
                            SizedBox(height: 5),
                            Text(
                                TranslationKeys.makeTranslation(TranslationKeys
                                    .textChequeStatusHistoryRefNo),
                                style: Theme.of(context).textTheme.bodySmall),
                          ],
                        ),
                      ),
                      Column(
                        mainAxisAlignment: MainAxisAlignment.center,
                        // crossAxisAlignment: CrossAxisAlignment.end,
                        children: [
                          Padding(
                            padding: EdgeInsets.symmetric(
                                vertical: 8.0, horizontal: 8.0),
                            child: Row(
                              // mainAxisAlignment: MainAxisAlignment.center,
                              children: [
                                Icon(Icons.check,
                                    color: AppColors.colorPrimary, size: 16),
                                SizedBox(width: 5),
                                Text(
                                    TranslationKeys.makeTranslation(
                                        TranslationKeys
                                            .textChequeStatusHistorySuccess),
                                    style:
                                    Theme.of(context).textTheme.bodySmall),
                              ],
                            ),
                          )
                        ],
                      ),
                    ],
                  ),
                ),
              ),
            ),
            SizedBox(height: 10),
            Card(
              surfaceTintColor: Colors.white,
              elevation: 2,
              child: Container(
                decoration: BoxDecoration(
                  borderRadius: BorderRadius.circular(10),
                  border: Border(
                    left: BorderSide(
                      color: AppColors.colorPrimary,
                      width: 5.0, // specify the width of the border
                    ),
                  ),
                ),
                child: Card(
                  surfaceTintColor: Colors.white,
                  elevation: 0,
                  child: Row(
                    mainAxisAlignment: MainAxisAlignment.spaceBetween,
                    crossAxisAlignment: CrossAxisAlignment.start,
                    children: [
                      Padding(
                        padding:
                        EdgeInsets.symmetric(horizontal: 10, vertical: 10),
                        child: Column(
                          crossAxisAlignment: CrossAxisAlignment.start,
                          children: [
                            Text(
                                TranslationKeys.makeTranslation(
                                    TranslationKeys.textBillDetailCustomerName),
                                style: Theme.of(context).textTheme.titleSmall),
                            SizedBox(height: 5),
                            Text(
                                TranslationKeys.makeTranslation(TranslationKeys
                                    .textChequeStatusCheckNumber),
                                style: Theme.of(context).textTheme.bodySmall),
                            SizedBox(height: 5),
                            Text(
                                TranslationKeys.makeTranslation(TranslationKeys
                                    .textChequeStatusHistoryRefNo),
                                style: Theme.of(context).textTheme.bodySmall),
                          ],
                        ),
                      ),
                      Column(
                        mainAxisAlignment: MainAxisAlignment.center,
                        // crossAxisAlignment: CrossAxisAlignment.end,
                        children: [
                          Padding(
                            padding: EdgeInsets.symmetric(
                                vertical: 8.0, horizontal: 8.0),
                            child: Row(
                              // mainAxisAlignment: MainAxisAlignment.center,
                              children: [
                                Icon(Icons.close,
                                    color: AppColors.colorPrimary, size: 16),
                                SizedBox(width: 5),
                                Text(
                                    TranslationKeys.makeTranslation(
                                        TranslationKeys
                                            .textChequeStatusHistoryCancel),
                                    style:
                                    Theme.of(context).textTheme.bodySmall),
                              ],
                            ),
                          )
                        ],
                      ),
                    ],
                  ),
                ),
              ),
            )
          ],
        ),
      ),
    );
  }
}
