import 'package:fikoyt_finans/apps/mesaici/base_page_mesaici_view.dart'; import 'package:fikoyt_finans/apps/mesaici/model/ayarlar/model_ayarlar.dart'; import 'package:fikoyt_finans/apps/mesaici/pages/ayarlar/maas_parametreleri/ek_odemeler_widget.dart'; import 'package:fikoyt_finans/apps/mesaici/pages/ayarlar/maas_parametreleri/kesintiler_widget.dart'; import 'package:fikoyt_finans/apps/mesaici/pages/ayarlar/maas_parametreleri/vergiler_widget.dart'; import 'package:fikoyt_finans/core/fikoyt.service.dart'; import 'package:fikoyt_finans/core/widgets/fiko_ui/fiko_button/fiko_button.dart'; import 'package:fikoyt_finans/core/widgets/yazi_kutulari/yazi_kutulari.dart'; import 'package:flutter/material.dart'; import 'package:get/get.dart'; class AyAyarlari extends StatelessWidget { AyAyarlari({super.key, required this.maasObs}); BasePageMesaiciLogic basePageMesaiciLogic = Get.put(BasePageMesaiciLogic()); // final FikoYTMesaiciService FikoYTService.servisMesaici = Get.put(FikoYTMesaiciService()); final FikoYTService servisFikoYT = FikoYTService(); Rx maasObs; @override Widget build(BuildContext context) { return Column( key: UniqueKey(), children: [ AnimatedSwitcher( duration: const Duration(milliseconds: 1000), transitionBuilder: (Widget child, Animation animation) { return FadeTransition(opacity: animation, child: child); }, child: FikoButton1( key: ValueKey(maasObs.value.ismi), textColor: Colors.amber, textStrokeColor: Colors.blue, textSize: 22, text: '${maasObs.value.ismi} Ayı Ayarları', ), ), ListTile( leading: const SizedBox( // height: double.infinity, child: Text( "💸", style: TextStyle( fontSize: 36, ), ), ), title: const Text( 'Asgari Ücret', style: TextStyle( fontWeight: FontWeight.w600, ), ), dense: false, subtitle: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ const Text( 'Hükümetin Belirlediği Ödenmesi Gereken En Düşük Ücret', style: TextStyle( fontWeight: FontWeight.w300, ), ), FikoYaziKutusu( baslik: "Asgari Ücret", simgeSol: const Text( "💸", style: TextStyle(fontSize: 16), ), sonEk: const Text("₺"), radius: 5.0, klavyeTipi: TextInputType.number, degeri: "${maasObs.value.asgariUcret}", degisti: (value) { maasObs.value.asgariUcret = double.parse(value.replaceAll("₺", "").replaceAll(",", "")); FikoYTService.servisMesaici.ayarlarModel!.refresh(); }, ), ], ), isThreeLine: true, splashColor: Colors.grey.shade300, ), ListTile( leading: const SizedBox( // height: double.infinity, child: Text( "💸", style: TextStyle( fontSize: 36, ), ), ), title: const Text( 'Brüt Maaşınız', style: TextStyle( fontWeight: FontWeight.w600, ), ), dense: false, subtitle: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ const Text( 'Aylık Mesaisiz Giydirilmemiş Net Maaşınız', style: TextStyle( fontWeight: FontWeight.w300, ), ), FikoYaziKutusu( baslik: "Brüt Maaşınız", simgeSol: const Text( "💸", style: TextStyle(fontSize: 16), ), sonEk: const Text("₺"), radius: 5.0, klavyeTipi: TextInputType.number, degeri: "${maasObs.value.brutMaas}", degisti: (value) { maasObs.value.brutMaas = double.parse(value.replaceAll("₺", "").replaceAll(",", "")); // maasObs.refresh(); FikoYTService.servisMesaici.ayarlarModel!.refresh(); }, // degeri: "0.00₺", ), ], ), // trailing: const Icon(Icons.chevron_right_sharp), isThreeLine: true, splashColor: Colors.grey.shade300, ), ListTile( leading: const SizedBox( // height: double.infinity, child: Text( "💸", style: TextStyle( fontSize: 36, ), ), ), title: const Text( 'Net Maaşınız', style: TextStyle( fontWeight: FontWeight.w600, ), ), dense: false, subtitle: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ const Text( 'Aylık Mesaisiz Giydirilmemiş Net Maaşınız', style: TextStyle( fontWeight: FontWeight.w300, ), ), FikoYaziKutusu( baslik: "Net Maaşınız", simgeSol: const Text( "💸", style: TextStyle(fontSize: 16), ), sonEk: const Text("₺"), radius: 5.0, klavyeTipi: TextInputType.number, degeri: "${maasObs.value.netMaas}", degisti: (value) { maasObs.value.netMaas = double.parse(value.replaceAll("₺", "").replaceAll(",", "")); FikoYTService.servisMesaici.ayarlarModel!.refresh(); }, ), ], ), isThreeLine: true, splashColor: Colors.grey.shade300, ), /** */ EkOdemelerWidget(kayit: maasObs), /** */ KesintilerWidget(kayit: maasObs), /** */ VergilerWidget(kayit: maasObs), ], ); } }