import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:rasadyar_core/core.dart';
import 'package:rasadyar_livestock/presentation/routes/app_pages.dart';

import 'logic.dart';

class RequestTaggingPage extends GetView<RequestTaggingLogic> {
  const RequestTaggingPage({super.key});

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      backgroundColor: Colors.white,
      appBar: RAppBar(
        title: 'درخواست پلاک کوبی',
        leadingWidth: 40,
        leading: Assets.vec.messageAddSvg.svg(width: 12, height: 12),
      ),
      body: Padding(
        padding: const EdgeInsets.symmetric(vertical: 20, horizontal: 15),
        child: Column(
          children: [
            RTextField(
              controller: controller.phoneController,
              label: 'تلفن دامدار',
            ),

            SizedBox(
              width: Get.width,
              height: 356,
              child: Card(
                color: Colors.white,
                child: Padding(
                  padding: const EdgeInsets.all(16.0),
                  child: Column(
                    children: [
                      Expanded(
                        child: Container(
                          width: Get.width,

                          decoration: BoxDecoration(
                            color: AppColor.lightGreyNormal,
                            borderRadius: BorderRadius.circular(8),
                          ),
                          child: Center(
                            child: Assets.images.placeHolder.image(
                              height: 150,
                              width: 200,
                            ),
                          ),
                        ),
                      ),
                      SizedBox(height: 15),
                      Container(
                        width: Get.width,
                        height: 40,
                        clipBehavior: Clip.antiAlias,
                        decoration: ShapeDecoration(
                          color: AppColor.blueNormal,
                          shape: RoundedRectangleBorder(
                            borderRadius: BorderRadius.circular(8),
                          ),
                        ),
                        child: Padding(
                          padding: const EdgeInsets.all(10.0),
                          child: Row(
                            mainAxisAlignment: MainAxisAlignment.spaceBetween,
                            children: [
                              Text(
                                ' تصویر گله',
                                style: AppFonts.yekan14.copyWith(
                                  color: Colors.white,
                                ),
                              ),
                              Icon(
                                CupertinoIcons.arrow_up_doc,
                                color: Colors.white,
                              ),
                            ],
                          ),
                        ),
                      ),
                    ],
                  ),
                ),
              ),
            ),

            Spacer(),



            RElevated(
              text: 'ارسال تصویر گله',
              onPressed: () {
                Get.toNamed(LiveStockRoutes.tagging);
              },
              height: 40,
              isFullWidth: true,
              backgroundColor: AppColor.greenNormal,
              textStyle: AppFonts.yekan16.copyWith(color: Colors.white),
            ),
          ],
        ),
      ),
    );
  }
}
