finalizada a tela service_individual_screen.dart,
ajustada service_home_screen.dart
This commit is contained in:
@@ -1,8 +1,8 @@
|
||||
class ServiceHomeCheckConditionModel{
|
||||
class CheckModel{
|
||||
String subtitle;
|
||||
bool check;
|
||||
|
||||
ServiceHomeCheckConditionModel({
|
||||
CheckModel({
|
||||
required this.subtitle,
|
||||
required this.check
|
||||
});
|
||||
@@ -1,7 +1,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:intl/intl.dart';
|
||||
import 'package:line_icons/line_icons.dart';
|
||||
import 'package:rkm/models/service_home_check_condition_model.dart';
|
||||
import 'package:rkm/models/check_model.dart';
|
||||
import 'package:rkm/utils/color_palette.dart';
|
||||
import 'package:rkm/widgets/alert_dialog_default.dart';
|
||||
import 'package:rkm/widgets/appbar_default.dart';
|
||||
@@ -11,7 +11,6 @@ import '../../widgets/check_box_subtitle.dart';
|
||||
import '../../widgets/dropdown_with_subtitle.dart';
|
||||
import '../../widgets/input_with_subtitle.dart';
|
||||
import '../../widgets/onbackbutton.dart';
|
||||
import '../../widgets/switch_with_subtitle.dart';
|
||||
import '../../widgets/text_default.dart';
|
||||
import '../../widgets/title_containers.dart';
|
||||
|
||||
@@ -38,8 +37,8 @@ class _ServiceHomeScreenState extends State<ServiceHomeScreen> {
|
||||
String? selectCIAP;
|
||||
String? selectCID;
|
||||
String? selectConduct;
|
||||
List<ServiceHomeCheckConditionModel> serviceHomeModel = [];
|
||||
List<ServiceHomeCheckConditionModel> proceduresModel = [];
|
||||
List<CheckModel> serviceHomeModel = [];
|
||||
List<CheckModel> proceduresModel = [];
|
||||
|
||||
escolherprazoInicio(BuildContext context) async {
|
||||
var pickDate = await showDatePicker(
|
||||
@@ -254,7 +253,7 @@ class _ServiceHomeScreenState extends State<ServiceHomeScreen> {
|
||||
itemCount: ConstVariable().serviceHomeCheckConditionlist.length,
|
||||
itemBuilder: (context,index){
|
||||
serviceHomeModel.add(
|
||||
ServiceHomeCheckConditionModel(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().serviceHomeCheckConditionlist[index],
|
||||
check: false
|
||||
)
|
||||
@@ -352,7 +351,7 @@ class _ServiceHomeScreenState extends State<ServiceHomeScreen> {
|
||||
itemCount: ConstVariable().proceduresModel.length,
|
||||
itemBuilder: (context,index){
|
||||
proceduresModel.add(
|
||||
ServiceHomeCheckConditionModel(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().proceduresModel[index],
|
||||
check: false
|
||||
)
|
||||
|
||||
@@ -1,4 +1,20 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:intl/intl.dart';
|
||||
import 'package:line_icons/line_icons.dart';
|
||||
import 'package:rkm/widgets/input_text.dart';
|
||||
import '../../models/check_model.dart';
|
||||
import '../../utils/color_palette.dart';
|
||||
import '../../utils/const_variable.dart';
|
||||
import '../../widgets/alert_dialog_default.dart';
|
||||
import '../../widgets/appbar_default.dart';
|
||||
import '../../widgets/button_default.dart';
|
||||
import '../../widgets/check_box_subtitle.dart';
|
||||
import '../../widgets/dropdown_with_subtitle.dart';
|
||||
import '../../widgets/input_with_subtitle.dart';
|
||||
import '../../widgets/onbackbutton.dart';
|
||||
import '../../widgets/switch_with_subtitle.dart';
|
||||
import '../../widgets/text_default.dart';
|
||||
import '../../widgets/title_containers.dart';
|
||||
|
||||
class ServiceIndividualScreen extends StatefulWidget {
|
||||
const ServiceIndividualScreen({Key? key}) : super(key: key);
|
||||
@@ -8,8 +24,843 @@ class ServiceIndividualScreen extends StatefulWidget {
|
||||
}
|
||||
|
||||
class _ServiceIndividualScreenState extends State<ServiceIndividualScreen> {
|
||||
|
||||
var professionalController = TextEditingController(text: 'ADMINISTRADOR');
|
||||
var unitController = TextEditingController(text: 'USF PINHAL - EMILIA STEPHANI SIMIONATO');
|
||||
var controllerSearchCondition = TextEditingController();
|
||||
var controllerSearchCID = TextEditingController();
|
||||
var controllerComplement = TextEditingController();
|
||||
String date='Data Atendimento';
|
||||
String? selectCodTeam;
|
||||
String? selectRationalityHealth;
|
||||
String? selectModelService;
|
||||
String? selectServicePlace;
|
||||
String? selectTypeService;
|
||||
String? selectModality;
|
||||
String? selectRotation;
|
||||
String? selectCIAP1;
|
||||
String? selectCIAP2;
|
||||
String? selectCID;
|
||||
String? selectConduct;
|
||||
String? selectBreastfeeding;
|
||||
String? selectProfessionals;
|
||||
String? selectCBO;
|
||||
String add='';
|
||||
List examsList=[];
|
||||
List<CheckModel> serviceConditionModel = [];
|
||||
List<CheckModel> trackingModel = [];
|
||||
List<CheckModel> nasfPoloModelList = [];
|
||||
List<CheckModel> communicableDiseasesModel = [];
|
||||
List<CheckModel> proceduresModel = [];
|
||||
List<CheckModel> conductList = [];
|
||||
List<CheckModel> forwardingList = [];
|
||||
bool switchVaccineUpToDate = false;
|
||||
bool switchPregnancyPlane = false;
|
||||
bool switchResquestedTest = false;
|
||||
bool switchListenStart = false;
|
||||
bool switchAvalibleTest = false;
|
||||
bool switchUnderObservation = false;
|
||||
bool selectExamsRequested = false;
|
||||
bool selectExamsAvalible = false;
|
||||
var userResponsibleRegisterController = TextEditingController(text: 'ADMINISTRADOR');
|
||||
var userUnitController = TextEditingController(text: 'USF PINHAL - EMILIA STEPHANI SIMIONATO');
|
||||
var weigthController = TextEditingController();
|
||||
var heightController = TextEditingController();
|
||||
var cephalicPerimeterController = TextEditingController();
|
||||
var dumController = TextEditingController();
|
||||
var oldPregnancyController = TextEditingController();
|
||||
var childBirthsController = TextEditingController();
|
||||
|
||||
escolherprazoInicio(BuildContext context) async {
|
||||
var pickDate = await showDatePicker(
|
||||
context: context,
|
||||
initialDate: DateTime.now(),
|
||||
firstDate: DateTime(2022),
|
||||
lastDate: DateTime(2025));
|
||||
if (pickDate != null) {
|
||||
setState(() {
|
||||
date = formatData(year: pickDate.year, month: pickDate.month, day: pickDate.day);
|
||||
date = 'Data Atendimento $date';
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
String formatData({int? year, int? month, int? day}) {
|
||||
DateTime data = DateTime(year!, month!, day!);
|
||||
String formattedDate = DateFormat('dd/MM/yyyy').format(data);
|
||||
return formattedDate;
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Center(child: Text('Atendimento Individual'),);
|
||||
|
||||
double heigth = MediaQuery.of(context).size.height;
|
||||
double width = MediaQuery.of(context).size.width;
|
||||
|
||||
return WillPopScope(
|
||||
onWillPop: ()=> OnBackButton().onBackButton(context),
|
||||
child: Scaffold(
|
||||
appBar: AppBarDefault().appbar(context, 'RKM AB - Atendimento Individual'),
|
||||
body: Container(
|
||||
height: double.infinity,
|
||||
width: double.infinity,
|
||||
decoration: ConstVariable().backgroundGradient,
|
||||
child: ListView(
|
||||
children: [
|
||||
Card(
|
||||
margin: EdgeInsets.all(10),
|
||||
child: Column(
|
||||
children: [
|
||||
TitleContainers(title: 'Identificação do Atendimento'),
|
||||
Row(
|
||||
children: [
|
||||
Container(
|
||||
height: heigth*0.5,
|
||||
width: width*0.2,
|
||||
child: Icon(Icons.assignment_rounded,size: 80,),
|
||||
),
|
||||
Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
GestureDetector(
|
||||
onTap: ()=>escolherprazoInicio(context),
|
||||
child: Container(
|
||||
height: 50,
|
||||
margin: EdgeInsets.symmetric(horizontal: 10),
|
||||
padding: EdgeInsets.symmetric(horizontal: 8,vertical: 10),
|
||||
decoration: BoxDecoration(
|
||||
border: Border.all(color: ColorPalette.white),
|
||||
borderRadius: BorderRadius.all(
|
||||
Radius.circular(5.0) // <--- border radius here
|
||||
),
|
||||
),
|
||||
width: width*0.7,
|
||||
child: TextDefault(
|
||||
text: date,
|
||||
fontWeigth: FontWeight.bold,
|
||||
color: ColorPalette.black54,
|
||||
fontSize: 18,
|
||||
),
|
||||
),
|
||||
),
|
||||
DropdownWithSubtitle(
|
||||
list: ['MANHÃ','TARDE','NOITE'],
|
||||
widthSubtitle: width*0.7,
|
||||
subtitle: 'Turno',
|
||||
hintDropdown: 'Turno',
|
||||
select: selectRotation,
|
||||
widthDropdown: width*0.7,
|
||||
widthContainerDropdown: width*0.6,
|
||||
onChanged: (value){
|
||||
setState(() {
|
||||
selectRotation = value!;
|
||||
});
|
||||
},
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
DropdownWithSubtitle(
|
||||
list: ConstVariable().listServicePlace,
|
||||
widthSubtitle: width*0.2,
|
||||
subtitle: 'Local de Atendimento',
|
||||
hintDropdown: 'Local de Atendimento',
|
||||
select: selectServicePlace,
|
||||
widthDropdown: width*0.7,
|
||||
widthContainerDropdown: width*0.6,
|
||||
onChanged: (value)=>setState(()=>selectServicePlace = value!),
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
DropdownWithSubtitle(
|
||||
list: ConstVariable().typeService2,
|
||||
widthSubtitle: width*0.2,
|
||||
subtitle: 'Tipo de Atendimento',
|
||||
hintDropdown: 'Tipo de Atendimento',
|
||||
select: selectTypeService,
|
||||
widthDropdown: width*0.7,
|
||||
widthContainerDropdown: width*0.65,
|
||||
onChanged: (value){
|
||||
setState(() {
|
||||
selectTypeService = value!;
|
||||
});
|
||||
},
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
child: Row(
|
||||
children: [
|
||||
TextDefault(text: 'Outros Profissionais',fontSize: 15),
|
||||
Spacer(),
|
||||
IconButton(
|
||||
icon: Icon(Icons.people_alt_rounded),
|
||||
onPressed: ()=>AlertDialogDefault().outherProfessionals(
|
||||
context,
|
||||
'Outros Profissionais',
|
||||
'Adicionar Profissional',
|
||||
selectProfessionals,
|
||||
selectCBO,
|
||||
add
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
InputWithSubtitle(
|
||||
subtitle: 'Peso (em kg - 000,000)',
|
||||
hintInput: 'Peso (em kg - 000,000)',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'Peso (em kg - 000,000)',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: weigthController,
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
InputWithSubtitle(
|
||||
subtitle: 'Altura (em metros - 0,00)',
|
||||
hintInput: 'Altura (em metros - 0,00)',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'Altura (em metros - 0,00)',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: heightController,
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
InputWithSubtitle(
|
||||
subtitle: 'Perímetro cefálico (em centímetros - 000,00)',
|
||||
hintInput: 'Perímetro cefálico (em centímetros - 000,00)',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'Perímetro cefálico (em centímetros - 000,00)',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: cephalicPerimeterController,
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
SwitchWithSubtitle(
|
||||
width: width*0.7,
|
||||
title: 'Vacina em Dia',
|
||||
value: switchVaccineUpToDate,
|
||||
onChanged: (value)=>setState(()=>switchVaccineUpToDate=value)
|
||||
),
|
||||
DropdownWithSubtitle(
|
||||
list: ['EXCLUSIVO','PREDOMINANTE','COMPLEMENTADO','INEXISTENTE'],
|
||||
widthSubtitle: width*0.7,
|
||||
subtitle: 'Aleitamento Materno',
|
||||
hintDropdown: 'Aleitamento Materno',
|
||||
select: selectBreastfeeding,
|
||||
widthDropdown: width*0.7,
|
||||
widthContainerDropdown: width*0.6,
|
||||
onChanged: (value)=>setState(()=>selectBreastfeeding = value!),
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
],
|
||||
)
|
||||
],
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
margin: EdgeInsets.all(10),
|
||||
child: Column(
|
||||
children: [
|
||||
TitleContainers(title: 'Profissional'),
|
||||
Row(
|
||||
children: [
|
||||
Container(
|
||||
height: heigth*0.3,
|
||||
width: width*0.2,
|
||||
child: Icon(Icons.business_center,size: 80,),
|
||||
),
|
||||
Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
InputWithSubtitle(
|
||||
subtitle: 'Usuário responsável Pelo Cadastro',
|
||||
hintInput: 'Usuário responsável Pelo Cadastro',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'Usuário responsável Pelo Cadastro',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: userResponsibleRegisterController,
|
||||
colorBorder: ColorPalette.white,
|
||||
enable: false,
|
||||
),
|
||||
InputWithSubtitle(
|
||||
subtitle: 'Unidade do Profissional',
|
||||
hintInput:'Unidade do Profissional',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'Unidade do Profissional',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: userUnitController,
|
||||
colorBorder: ColorPalette.white,
|
||||
enable: false,
|
||||
),
|
||||
DropdownWithSubtitle(
|
||||
list: [],
|
||||
widthSubtitle: width*0.7,
|
||||
subtitle: 'CBO',
|
||||
hintDropdown: 'CBO',
|
||||
select: selectCBO,
|
||||
widthDropdown: width*0.7,
|
||||
widthContainerDropdown: width*0.6,
|
||||
onChanged: (value){
|
||||
setState(() {
|
||||
selectCBO = value!;
|
||||
});
|
||||
},
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
DropdownWithSubtitle(
|
||||
list: ['INE: 0001558536 / Área: 4 - Microárea:-'],
|
||||
widthSubtitle: width*0.2,
|
||||
subtitle: 'Código da Equipe',
|
||||
hintDropdown: 'Código da Equipe',
|
||||
select: selectCodTeam,
|
||||
widthDropdown: width*0.7,
|
||||
widthContainerDropdown: width*0.6,
|
||||
onChanged: (value)=>setState(()=>selectCodTeam = value!),
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
],
|
||||
)
|
||||
],
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
margin: EdgeInsets.all(10),
|
||||
child: Column(
|
||||
children: [
|
||||
TitleContainers(title: 'Gestante'),
|
||||
Row(
|
||||
children: [
|
||||
Container(
|
||||
height: heigth*0.3,
|
||||
width: width*0.2,
|
||||
child: Icon(Icons.business_center,size: 80,),
|
||||
),
|
||||
Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
InputWithSubtitle(
|
||||
subtitle: 'DUM',
|
||||
hintInput: 'DUM',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'DUM',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: dumController,
|
||||
colorBorder: ColorPalette.white,
|
||||
enable: false,
|
||||
),
|
||||
SwitchWithSubtitle(
|
||||
onChanged: (value){},
|
||||
value: switchPregnancyPlane,
|
||||
width: width*0.65,
|
||||
title: 'Gravidez Planejada'
|
||||
),
|
||||
InputWithSubtitle(
|
||||
subtitle: 'Idade Gestacional',
|
||||
hintInput:'Idade Gestacional',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'Idade Gestacional',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: oldPregnancyController,
|
||||
colorBorder: ColorPalette.white,
|
||||
enable: false,
|
||||
),
|
||||
InputWithSubtitle(
|
||||
subtitle: 'Partos',
|
||||
hintInput:'Partos',
|
||||
errorInput: 'Campo obrigatório',
|
||||
labelInput: 'Partos',
|
||||
widthSubtitle: width*0.7,
|
||||
widthInput: width*0.7,
|
||||
controller: childBirthsController,
|
||||
colorBorder: ColorPalette.white,
|
||||
enable: false,
|
||||
),
|
||||
],
|
||||
)
|
||||
],
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
margin: EdgeInsets.all(10),
|
||||
child: Column(
|
||||
children: [
|
||||
TitleContainers(title: 'Atendimento'),
|
||||
Row(
|
||||
children: [
|
||||
Container(
|
||||
height: heigth*0.4,
|
||||
width: width*0.2,
|
||||
child: Icon(LineIcons.edit,size: 80,),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 10.0),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
DropdownWithSubtitle(
|
||||
list: ['ATENÇÃO DOMICILIAR 1','ATENÇÃO DOMICILIAR 2','ATENÇÃO DOMICILIAR 3',],
|
||||
widthSubtitle: width*0.2,
|
||||
subtitle: 'Modalidade',
|
||||
hintDropdown:'Modalidade',
|
||||
select: selectModelService,
|
||||
widthDropdown: width*0.65,
|
||||
widthContainerDropdown: width*0.6,
|
||||
onChanged: (value)=>setState(()=>selectModelService = value!),
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
TitleContainers(title: 'Condição Avaliada',width: width * 0.73,textAling: TextAlign.start),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
height: heigth*0.5,
|
||||
child: GridView.builder(
|
||||
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
||||
mainAxisSpacing: 2,
|
||||
crossAxisSpacing: 2,
|
||||
crossAxisCount: 2,
|
||||
mainAxisExtent: 50
|
||||
),
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
itemCount: ConstVariable().serviceIndividualCheckBoxList.length,
|
||||
itemBuilder: (context,index){
|
||||
serviceConditionModel.add(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().serviceIndividualCheckBoxList[index],
|
||||
check: false
|
||||
)
|
||||
);
|
||||
return CheckBoxSubtitle(
|
||||
subtitle: serviceConditionModel[index].subtitle,
|
||||
checkbox:serviceConditionModel[index].check,
|
||||
width: width*0.25,
|
||||
fontSize: 12,
|
||||
onChanged: (value)=>setState(()=>serviceConditionModel[index].check=value),
|
||||
);
|
||||
}
|
||||
),
|
||||
),
|
||||
TitleContainers(title: 'Doenças Transmissíveis',width: width * 0.73,textAling: TextAlign.start),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
height: heigth*0.15,
|
||||
child: GridView.builder(
|
||||
gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
||||
mainAxisSpacing: 2,
|
||||
crossAxisSpacing: 2,
|
||||
crossAxisCount: 2,
|
||||
mainAxisExtent: 50
|
||||
),
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
itemCount: ConstVariable().communicableDiseasesList.length,
|
||||
itemBuilder: (context,index){
|
||||
communicableDiseasesModel.add(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().communicableDiseasesList[index],
|
||||
check: false
|
||||
)
|
||||
);
|
||||
return CheckBoxSubtitle(
|
||||
subtitle: communicableDiseasesModel[index].subtitle,
|
||||
checkbox:communicableDiseasesModel[index].check,
|
||||
width: width*0.25,
|
||||
fontSize: 12,
|
||||
onChanged: (value)=>setState(()=>communicableDiseasesModel[index].check=value),
|
||||
);
|
||||
}
|
||||
),
|
||||
),
|
||||
TitleContainers(title: 'Rastreamento',width: width * 0.73,textAling: TextAlign.start),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
height: heigth*0.15,
|
||||
child: ListView.builder(
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
itemCount: ConstVariable().trackingModelList.length,
|
||||
itemBuilder: (context,index){
|
||||
trackingModel.add(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().trackingModelList[index],
|
||||
check: false
|
||||
)
|
||||
);
|
||||
return CheckBoxSubtitle(
|
||||
subtitle: trackingModel[index].subtitle,
|
||||
checkbox:trackingModel[index].check,
|
||||
width: width*0.5,
|
||||
fontSize: 12,
|
||||
onChanged: (value)=>setState(()=>trackingModel[index].check=value),
|
||||
);
|
||||
}
|
||||
),
|
||||
),
|
||||
GestureDetector(
|
||||
onTap: ()=>AlertDialogDefault().alert_with_search(
|
||||
context,
|
||||
controllerSearchCondition,
|
||||
ListView.separated(
|
||||
itemCount: ConstVariable().CIAP.length,
|
||||
separatorBuilder: (context,index)=>Divider(color: ColorPalette.black54),
|
||||
itemBuilder: (context,index){
|
||||
return ListTile(
|
||||
onTap: ()=>setState(() {
|
||||
selectCIAP1 = ConstVariable().CIAP[index];
|
||||
Navigator.pop(context);
|
||||
}),
|
||||
title: TextDefault(text: ConstVariable().CIAP[index],maxLines: 2,)
|
||||
);
|
||||
},
|
||||
)
|
||||
),
|
||||
child: Container(
|
||||
padding: EdgeInsets.symmetric(vertical: 10),
|
||||
width: width*0.7,
|
||||
child: TextDefault(
|
||||
text: selectCIAP1!=null?'CIAP2-01 $selectCIAP1':'CIAP2-01',
|
||||
color: ColorPalette.black54,
|
||||
)
|
||||
)
|
||||
),
|
||||
GestureDetector(
|
||||
onTap: ()=>AlertDialogDefault().alert_with_search(
|
||||
context,
|
||||
controllerSearchCondition,
|
||||
ListView.separated(
|
||||
itemCount: ConstVariable().CIAP.length,
|
||||
separatorBuilder: (context,index)=>Divider(color: ColorPalette.black54),
|
||||
itemBuilder: (context,index){
|
||||
return ListTile(
|
||||
onTap: ()=>setState(() {
|
||||
selectCIAP2 = ConstVariable().CIAP[index];
|
||||
Navigator.pop(context);
|
||||
}),
|
||||
title: TextDefault(text: ConstVariable().CIAP[index],maxLines: 2,)
|
||||
);
|
||||
},
|
||||
)
|
||||
),
|
||||
child: Container(
|
||||
padding: EdgeInsets.symmetric(vertical: 10),
|
||||
width: width*0.7,
|
||||
child: TextDefault(
|
||||
text: selectCIAP2!=null?'CIAP2-01 $selectCIAP2':'CIAP2-01',
|
||||
color: ColorPalette.black54,
|
||||
)
|
||||
)
|
||||
),
|
||||
GestureDetector(
|
||||
onTap: ()=>AlertDialogDefault().alert_with_search(
|
||||
context,
|
||||
controllerSearchCID,
|
||||
ListView.separated(
|
||||
itemCount: ConstVariable().CID.length,
|
||||
separatorBuilder: (context,index)=>Divider(color: ColorPalette.black54),
|
||||
itemBuilder: (context,index){
|
||||
return ListTile(
|
||||
onTap: ()=>setState(() {
|
||||
selectCID = ConstVariable().CIAP[index];
|
||||
Navigator.pop(context);
|
||||
}),
|
||||
title: TextDefault(text: ConstVariable().CID[index],maxLines: 2,)
|
||||
);
|
||||
},
|
||||
)
|
||||
),
|
||||
child: Container(
|
||||
padding: EdgeInsets.symmetric(vertical: 10),
|
||||
width: width*0.7,
|
||||
child: TextDefault(
|
||||
text: selectCID!=null?'CID $selectCID':'CID',
|
||||
color: ColorPalette.black54,
|
||||
)
|
||||
)
|
||||
),
|
||||
GestureDetector(
|
||||
onTap: ()=>AlertDialogDefault().alert_with_search(
|
||||
context,
|
||||
controllerSearchCID,
|
||||
ListView.separated(
|
||||
itemCount: ConstVariable().CID.length,
|
||||
separatorBuilder: (context,index)=>Divider(color: ColorPalette.black54),
|
||||
itemBuilder: (context,index){
|
||||
return ListTile(
|
||||
onTap: ()=>setState(() {
|
||||
selectCID = ConstVariable().CIAP[index];
|
||||
Navigator.pop(context);
|
||||
}),
|
||||
title: TextDefault(text: ConstVariable().CID[index],maxLines: 2,)
|
||||
);
|
||||
},
|
||||
)
|
||||
),
|
||||
child: Container(
|
||||
padding: EdgeInsets.symmetric(vertical: 10),
|
||||
width: width*0.7,
|
||||
child: TextDefault(
|
||||
text: selectCID!=null?'CID $selectCID':'CID',
|
||||
color: ColorPalette.black54,
|
||||
)
|
||||
)
|
||||
),
|
||||
TitleContainers(title: 'Triagem Neonatal',width: width * 0.73,textAling: TextAlign.start),
|
||||
SwitchWithSubtitle(
|
||||
onChanged: (v)=>setState(()=>switchResquestedTest=v),
|
||||
value: switchResquestedTest,
|
||||
width: width*0.7,
|
||||
title: 'Exames Solicitados'
|
||||
),
|
||||
SwitchWithSubtitle(
|
||||
onChanged: (v)=>setState(()=>switchAvalibleTest=v),
|
||||
value: switchAvalibleTest,
|
||||
width: width*0.7,
|
||||
title: 'Exames Avaliados'
|
||||
),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
child: Row(
|
||||
children: [
|
||||
TextDefault(text: 'Outros Exames',fontSize: 20,color: ColorPalette.black54,),
|
||||
Spacer(),
|
||||
IconButton(
|
||||
icon: Icon(Icons.add_circle),
|
||||
onPressed: ()=>AlertDialogDefault().outherExams(
|
||||
context,
|
||||
'Outros Exames',
|
||||
'Adicionar Exames',
|
||||
selectProfessionals,
|
||||
selectCBO,
|
||||
add,
|
||||
examsList,
|
||||
selectExamsRequested,
|
||||
selectExamsAvalible
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
DropdownWithSubtitle(
|
||||
list: [
|
||||
'MEDICINA TRADICIONAL CHINESA',
|
||||
'ANTROPOSOFIA APLICA À SAÚDE',
|
||||
'HOMEOPATIA',
|
||||
'FITOTERATIA',
|
||||
'AYURVEDA',
|
||||
'OUTROS',
|
||||
],
|
||||
widthSubtitle: width*0.2,
|
||||
subtitle: 'Racionalidade em Saúde',
|
||||
hintDropdown: 'Racionalidade em Saúde',
|
||||
select: selectRationalityHealth,
|
||||
widthDropdown: width*0.65,
|
||||
widthContainerDropdown: width*0.6,
|
||||
onChanged: (value)=>setState(()=>selectRationalityHealth = value!),
|
||||
colorBorder: ColorPalette.white,
|
||||
),
|
||||
SwitchWithSubtitle(
|
||||
onChanged: (v)=>setState(()=>switchUnderObservation=v),
|
||||
width: width*0.7,
|
||||
value: switchUnderObservation,
|
||||
title: 'Ficou em Observação'
|
||||
),
|
||||
TitleContainers(title: 'NASF/Polo',width: width * 0.73,textAling: TextAlign.start),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
height: heigth*0.15,
|
||||
child: ListView.builder(
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
itemCount: ConstVariable().nasfPoloModelList.length,
|
||||
itemBuilder: (context,index){
|
||||
nasfPoloModelList.add(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().nasfPoloModelList[index],
|
||||
check: false
|
||||
)
|
||||
);
|
||||
return CheckBoxSubtitle(
|
||||
subtitle: nasfPoloModelList[index].subtitle,
|
||||
checkbox:nasfPoloModelList[index].check,
|
||||
width: width*0.5,
|
||||
fontSize: 12,
|
||||
onChanged: (value)=>setState(()=>nasfPoloModelList[index].check=value),
|
||||
);
|
||||
}
|
||||
),
|
||||
),
|
||||
TitleContainers(title: 'Conduta',width: width * 0.73,textAling: TextAlign.start),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
height: heigth*0.3,
|
||||
child: ListView.builder(
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
itemCount: ConstVariable().conductModelList.length,
|
||||
itemBuilder: (context,index){
|
||||
conductList.add(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().conductModelList[index],
|
||||
check: false
|
||||
)
|
||||
);
|
||||
return CheckBoxSubtitle(
|
||||
subtitle: conductList[index].subtitle,
|
||||
checkbox:conductList[index].check,
|
||||
width: width*0.5,
|
||||
fontSize: 12,
|
||||
onChanged: (value)=>setState(()=>conductList[index].check=value),
|
||||
);
|
||||
}
|
||||
),
|
||||
),
|
||||
TitleContainers(title: 'Encaminhamento',width: width * 0.73,textAling: TextAlign.start),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
height: heigth*0.35,
|
||||
child: ListView.builder(
|
||||
physics: const NeverScrollableScrollPhysics(),
|
||||
itemCount: ConstVariable().forwardingModelList.length,
|
||||
itemBuilder: (context,index){
|
||||
forwardingList.add(
|
||||
CheckModel(
|
||||
subtitle: ConstVariable().forwardingModelList[index],
|
||||
check: false
|
||||
)
|
||||
);
|
||||
return CheckBoxSubtitle(
|
||||
subtitle: forwardingList[index].subtitle,
|
||||
checkbox:forwardingList[index].check,
|
||||
width: width*0.5,
|
||||
fontSize: 12,
|
||||
onChanged: (value)=>setState(()=>forwardingList[index].check=value),
|
||||
);
|
||||
}
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
]
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
margin: EdgeInsets.all(10),
|
||||
child: Column(
|
||||
children: [
|
||||
TitleContainers(title: 'Procedimentos'),
|
||||
Row(
|
||||
children: [
|
||||
Container(
|
||||
height: heigth*0.15,
|
||||
width: width*0.2,
|
||||
child: Icon(LineIcons.infoCircle,size: 80,),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 10.0),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
SwitchWithSubtitle(
|
||||
onChanged: (v)=>setState(()=>switchListenStart=v),
|
||||
value: switchListenStart,
|
||||
width: width*0.7,
|
||||
title: 'Escuta Inicial/Orientação'
|
||||
),
|
||||
Container(
|
||||
width: width*0.7,
|
||||
child: Row(
|
||||
children: [
|
||||
TextDefault(text: 'Procedimentos',fontSize: 20,color: ColorPalette.black54,),
|
||||
Spacer(),
|
||||
IconButton(
|
||||
icon: Icon(Icons.add_circle),
|
||||
onPressed: (){}
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
margin: EdgeInsets.all(10),
|
||||
child: Column(
|
||||
children: [
|
||||
TitleContainers(title: 'Complemento'),
|
||||
Row(
|
||||
children: [
|
||||
Container(
|
||||
height: heigth*0.15,
|
||||
width: width*0.2,
|
||||
child: Icon(Icons.attach_file,size: 80,),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 10.0),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
InputText(
|
||||
controller: controllerComplement,
|
||||
width: width*0.7,
|
||||
maxLines: 4,
|
||||
colorBorder: ColorPalette.white,
|
||||
textInputType: TextInputType.multiline,
|
||||
)
|
||||
],
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
margin: EdgeInsets.all(10),
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(8.0),
|
||||
child: Column(
|
||||
children: [
|
||||
ButtonDefault(
|
||||
onPressed: (){},
|
||||
title: 'Salvar',
|
||||
borderColor: ColorPalette.appBar,
|
||||
background: ColorPalette.appBar,
|
||||
textColor: ColorPalette.white,
|
||||
width: double.infinity,
|
||||
),
|
||||
ButtonDefault(
|
||||
onPressed: ()=>Navigator.pop(context),
|
||||
title: 'Cancelar',
|
||||
borderColor: ColorPalette.blackButton,
|
||||
background: ColorPalette.blackButton,
|
||||
textColor: ColorPalette.white,
|
||||
width: double.infinity,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ class _SplashScreenState extends State<SplashScreen> {
|
||||
|
||||
timer()async{
|
||||
Future.delayed(Duration(seconds: 3),(){
|
||||
Navigator.pushReplacementNamed(context, '/home');
|
||||
Navigator.pushReplacementNamed(context, '/login');
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -57,6 +57,40 @@ class ConstVariable{
|
||||
'CUIDADOS COM TRAQUEOSTOMIA',
|
||||
];
|
||||
|
||||
List serviceIndividualCheckBoxList =[
|
||||
'ASMA',
|
||||
'PUERPÉRO (ATÉ 42 ...',
|
||||
'DESNUTRIÇÃO',
|
||||
'SAÚDE SEXUAL E RE...',
|
||||
'DIABETES',
|
||||
'TABAGISMO',
|
||||
'DPOC',
|
||||
'USUÁRIO DE ÁLCOOL',
|
||||
'HIPERTERSÃO ARTERIAL',
|
||||
'USUÁRIO DE OUTRA...',
|
||||
'OBESIDADE',
|
||||
'SAÚDE MENTAL',
|
||||
'PRÉ-NATAL',
|
||||
'REABILITAÇÃO',
|
||||
'PUERICULTURA',
|
||||
];
|
||||
|
||||
List<String> trackingModelList=['CÂNCER DE COLO DO ÚTERO','CÂNCER DE MAMA','RISCO CARDIOVASCULAR'];
|
||||
List<String> nasfPoloModelList=['AVALIAÇÃO/DIAGNÓSTICO','PROCEDIMENTOS CLÍNICOS/TERAPÊUTICO','PRESCRIÇÃO TERAPÊUTICA'];
|
||||
List<String> conductModelList=[
|
||||
'RETORNO PARA CONSULTA AGENDADA','RETORNO PARA CUIDADO CONTINUADO/PROGRAMADO',
|
||||
'AGENDAMENTO PARA GRUPOS','AGENDAMENTO PARA NASF','ALTA DO EPISÓDIO'];
|
||||
List<String> forwardingModelList=[
|
||||
'INTERNO DO DIA','SERVIÇO ESPECIALIZADO','CAPS','INTERNAÇÃO HOSPITALAR','URGÊNCIA'
|
||||
'SERVIÇO DE ATENÇÃO DOMICILIAR','INTERSETORIAL'];
|
||||
|
||||
List communicableDiseasesList = [
|
||||
'TUBERCULOSE',
|
||||
'DENGUE',
|
||||
'HANSENÍASE',
|
||||
'DST',
|
||||
];
|
||||
|
||||
List serviceHomeCheckConditionlist = [
|
||||
'ACAMADO',
|
||||
'DOMICILIADO',
|
||||
@@ -103,6 +137,13 @@ class ConstVariable{
|
||||
'ATENDIMENTO NÃO PROGRAMADO',
|
||||
'VISITA DOMICILIAR PÓS ÓBITO',
|
||||
];
|
||||
List<String> typeService2 = [
|
||||
'CONSULTA AGENDADA PROGRAMADA/CUIDADO CONTINUADO',
|
||||
'CONSULTA AGENDADA',
|
||||
'DEMANDA ESPONTÂNEA - ESCUTA INICIAL/ORIENTAÇÃO',
|
||||
'DEMANDA ESPONTÂNEA - CONSULTA NO DIA',
|
||||
'DEMANDA ESPONTÂNEA - ATENDIMENTO DE EMERGÊNCIA',
|
||||
];
|
||||
List<String> listBreed = [
|
||||
'AMARELA',
|
||||
'BRANCA',
|
||||
|
||||
@@ -3,7 +3,9 @@ import 'package:rkm/utils/color_palette.dart';
|
||||
import 'package:rkm/utils/const_variable.dart';
|
||||
import 'package:rkm/widgets/button_default.dart';
|
||||
import 'package:rkm/widgets/item_alert_settings.dart';
|
||||
import 'package:rkm/widgets/switch_with_subtitle.dart';
|
||||
import 'package:rkm/widgets/text_default.dart';
|
||||
import 'package:rkm/widgets/title_containers.dart';
|
||||
|
||||
import 'dropdown_button_default.dart';
|
||||
import 'input_search_text.dart';
|
||||
@@ -137,4 +139,271 @@ class AlertDialogDefault {
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
outherProfessionals(
|
||||
BuildContext context,String title,String subtitle,String? selectProfessionals,String? selectCBO,String add
|
||||
) {
|
||||
|
||||
double width = MediaQuery.of(context).size.width;
|
||||
double height = MediaQuery.of(context).size.height;
|
||||
bool addProfissionals = false;
|
||||
|
||||
return showDialog(
|
||||
context: context,
|
||||
builder: (context){
|
||||
return StatefulBuilder(
|
||||
builder:(context,setState)=> AlertDialog(
|
||||
titlePadding: EdgeInsets.all(0),
|
||||
contentPadding: EdgeInsets.all(0),
|
||||
title: Container(
|
||||
padding: EdgeInsets.all(10),
|
||||
color: ColorPalette.blackButton,
|
||||
child: TextDefault(
|
||||
text: title,
|
||||
color: ColorPalette.white,
|
||||
textAlign: TextAlign.center,
|
||||
fontWeigth: FontWeight.bold,
|
||||
),
|
||||
),
|
||||
content: Container(
|
||||
decoration: ConstVariable().backgroundGradient,
|
||||
child: Column(
|
||||
children: [
|
||||
Card(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
TitleContainers(title: subtitle),
|
||||
DropDownButtonDefault(
|
||||
onChanged: (value)=>setState((){
|
||||
selectProfessionals=value;
|
||||
addProfissionals = true;
|
||||
}),
|
||||
select: selectProfessionals,
|
||||
title: 'Profissional',
|
||||
list: [
|
||||
'ADMINISTRADOR',
|
||||
'ALEXANDRE NITTA',
|
||||
'ALINE SUELEM LEITE',
|
||||
'ARIANE FAVORATO ROSA',
|
||||
],
|
||||
width: width
|
||||
),
|
||||
DropDownButtonDefault(
|
||||
onChanged: (value)=>setState(()=>selectCBO=value),
|
||||
select: selectCBO,
|
||||
title: 'CBO',
|
||||
list: [],
|
||||
width: width
|
||||
),
|
||||
ButtonDefault(
|
||||
onPressed:addProfissionals?()=>setState((){
|
||||
add = selectProfessionals!;
|
||||
}):null,
|
||||
title: 'Adicionar',
|
||||
width: width*0.85,
|
||||
textColor: ColorPalette.white,
|
||||
borderColor:addProfissionals?ColorPalette.appBar:ColorPalette.buttonDisable,
|
||||
background: ColorPalette.appBar,
|
||||
disableColor: ColorPalette.buttonDisable,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
TitleContainers(title: 'Profissionais'),
|
||||
add!=''
|
||||
?Container(
|
||||
padding: EdgeInsets.all(10),
|
||||
child: Row(
|
||||
children: [
|
||||
TextDefault(text: add,color: ColorPalette.black54,),
|
||||
Spacer(),
|
||||
IconButton(
|
||||
icon: Icon(Icons.delete),
|
||||
onPressed: ()=>setState((){
|
||||
add='';
|
||||
addProfissionals = false;
|
||||
}),
|
||||
)
|
||||
],
|
||||
),
|
||||
)
|
||||
:Container()
|
||||
],
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
actionsAlignment: MainAxisAlignment.start,
|
||||
actions: [
|
||||
ButtonDefault(
|
||||
onPressed: ()=>Navigator.pop(context),
|
||||
title: 'Fechar',
|
||||
width: width*0.2,
|
||||
textColor: ColorPalette.black54,
|
||||
borderColor: ColorPalette.white,
|
||||
background: ColorPalette.white,
|
||||
)
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
outherExams(
|
||||
BuildContext context,
|
||||
String title,String subtitle,
|
||||
String? selectProfessionals,
|
||||
String? selectCBO,
|
||||
String add,
|
||||
List examsList,
|
||||
bool requested,
|
||||
bool avaliable
|
||||
) {
|
||||
|
||||
double width = MediaQuery.of(context).size.width;
|
||||
double height = MediaQuery.of(context).size.height;
|
||||
bool addProfissionals = false;
|
||||
|
||||
return showDialog(
|
||||
context: context,
|
||||
builder: (context){
|
||||
return StatefulBuilder(
|
||||
builder:(context,setState)=> AlertDialog(
|
||||
titlePadding: EdgeInsets.all(0),
|
||||
contentPadding: EdgeInsets.all(0),
|
||||
title: Container(
|
||||
padding: EdgeInsets.all(10),
|
||||
color: ColorPalette.blackButton,
|
||||
child: TextDefault(
|
||||
text: title,
|
||||
color: ColorPalette.white,
|
||||
textAlign: TextAlign.center,
|
||||
fontWeigth: FontWeight.bold,
|
||||
),
|
||||
),
|
||||
content: Container(
|
||||
decoration: ConstVariable().backgroundGradient,
|
||||
child: Column(
|
||||
children: [
|
||||
Card(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
TitleContainers(title: subtitle),
|
||||
DropDownButtonDefault(
|
||||
onChanged: (value)=>setState((){
|
||||
selectProfessionals=value;
|
||||
addProfissionals = true;
|
||||
}),
|
||||
select: selectProfessionals,
|
||||
title: 'Exame',
|
||||
list: [
|
||||
'0201010011 - AMNIOCENTESE',
|
||||
'0201010020 - BIOPSIA / PUNSAO DE TUMOR SUPERFICIAL DA PELE',
|
||||
'0201010046 - BIOPSIA DE ANUS E CANAL ANAL',
|
||||
'0201010062 - BIOSIA DE BEXIGA',
|
||||
],
|
||||
width: width
|
||||
),
|
||||
SwitchWithSubtitle(
|
||||
onChanged: (v)=>setState(()=>requested=v),
|
||||
value: requested,
|
||||
width: width*0.8,
|
||||
title: 'Solicitado'
|
||||
),
|
||||
SwitchWithSubtitle(
|
||||
onChanged: (v)=>setState(()=>avaliable=v),
|
||||
value: avaliable,
|
||||
width: width*0.8,
|
||||
title: 'Avaliado'
|
||||
),
|
||||
ButtonDefault(
|
||||
onPressed:addProfissionals || examsList.length == 4?()=>setState((){
|
||||
List list = selectProfessionals!.split(' - ');
|
||||
add = list[0] + '${requested?' - S':''}' + '${avaliable?' - A':''}'+' - ${list[1]}';
|
||||
if(examsList.length<=3){
|
||||
examsList.add(add);
|
||||
}else{
|
||||
addProfissionals = false;
|
||||
}
|
||||
selectProfessionals=null;
|
||||
avaliable = false;
|
||||
requested = false;
|
||||
}):null,
|
||||
title: 'Adicionar',
|
||||
width: width*0.85,
|
||||
textColor: ColorPalette.white,
|
||||
borderColor:addProfissionals?ColorPalette.appBar:ColorPalette.buttonDisable,
|
||||
background: ColorPalette.appBar,
|
||||
disableColor: ColorPalette.buttonDisable,
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
Card(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
TitleContainers(title: 'Exames'),
|
||||
examsList.length!=0
|
||||
?Container(
|
||||
width: width*0.8,
|
||||
height: height*0.4,
|
||||
child: ListView.builder(
|
||||
itemCount: examsList.length,
|
||||
itemBuilder: (context,index) {
|
||||
return Container(
|
||||
width: width * 0.8,
|
||||
padding: EdgeInsets.all(10),
|
||||
child: Row(
|
||||
children: [
|
||||
Container(
|
||||
width: width * 0.6,
|
||||
child: TextDefault(text: examsList[index],
|
||||
color: ColorPalette.black54,)
|
||||
),
|
||||
Spacer(),
|
||||
IconButton(
|
||||
icon: Icon(Icons.delete),
|
||||
onPressed: () =>
|
||||
setState(() {
|
||||
examsList.removeAt(index);
|
||||
}),
|
||||
)
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
),
|
||||
)
|
||||
:Container()
|
||||
],
|
||||
),
|
||||
)
|
||||
],
|
||||
),
|
||||
),
|
||||
actionsAlignment: MainAxisAlignment.start,
|
||||
actions: [
|
||||
ButtonDefault(
|
||||
onPressed: ()=>Navigator.pop(context),
|
||||
title: 'Fechar',
|
||||
width: width*0.2,
|
||||
textColor: ColorPalette.black54,
|
||||
borderColor: ColorPalette.white,
|
||||
background: ColorPalette.white,
|
||||
)
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,12 +8,14 @@ class CheckBoxSubtitle extends StatelessWidget {
|
||||
String subtitle;
|
||||
bool checkbox;
|
||||
var onChanged;
|
||||
double fontSize;
|
||||
|
||||
CheckBoxSubtitle({
|
||||
this.width = double.infinity,
|
||||
required this.checkbox,
|
||||
required this.subtitle,
|
||||
required this.onChanged,
|
||||
this.fontSize = 15
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -29,7 +31,7 @@ class CheckBoxSubtitle extends StatelessWidget {
|
||||
),
|
||||
Container(
|
||||
width: width,
|
||||
child: TextDefault(text: subtitle,fontSize: 15,color: ColorPalette.black54,)
|
||||
child: TextDefault(text: subtitle,fontSize: fontSize,color: ColorPalette.black54,)
|
||||
),
|
||||
],
|
||||
),
|
||||
|
||||
@@ -13,6 +13,7 @@ class InputText extends StatelessWidget {
|
||||
bool enable;
|
||||
TextInputType textInputType;
|
||||
int maxLines;
|
||||
Color colorBorder;
|
||||
|
||||
InputText({
|
||||
required this.controller,
|
||||
@@ -25,6 +26,7 @@ class InputText extends StatelessWidget {
|
||||
this.enable = true,
|
||||
this.textInputType = TextInputType.text,
|
||||
this.maxLines = 1,
|
||||
this.colorBorder = ColorPalette.black54
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -51,7 +53,21 @@ class InputText extends StatelessWidget {
|
||||
decoration: InputDecoration(
|
||||
fillColor: ColorPalette.appBar,
|
||||
labelText: label,
|
||||
border: OutlineInputBorder(),
|
||||
border: OutlineInputBorder(
|
||||
borderSide: BorderSide(width: 2,color: colorBorder)
|
||||
),
|
||||
focusedBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(width: 3, color: colorBorder),
|
||||
borderRadius: BorderRadius.circular(15),
|
||||
),
|
||||
enabledBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(width: 3, color: colorBorder),
|
||||
borderRadius: BorderRadius.circular(15),
|
||||
),
|
||||
disabledBorder: OutlineInputBorder(
|
||||
borderSide: BorderSide(width: 3, color: colorBorder),
|
||||
borderRadius: BorderRadius.circular(15),
|
||||
),
|
||||
hintText: this.hint,
|
||||
enabled: enable,
|
||||
hintStyle: TextStyle(
|
||||
|
||||
@@ -14,6 +14,7 @@ class InputWithSubtitle extends StatelessWidget {
|
||||
bool enable;
|
||||
TextInputType textInputType;
|
||||
int maxLines;
|
||||
Color colorBorder;
|
||||
|
||||
InputWithSubtitle({
|
||||
required this.subtitle,
|
||||
@@ -26,6 +27,7 @@ class InputWithSubtitle extends StatelessWidget {
|
||||
this.enable = true,
|
||||
this.textInputType = TextInputType.text,
|
||||
this.maxLines = 1,
|
||||
this.colorBorder = ColorPalette.black54
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -51,7 +53,8 @@ class InputWithSubtitle extends StatelessWidget {
|
||||
label: labelInput,
|
||||
enable: enable,
|
||||
textInputType: textInputType,
|
||||
maxLines:maxLines
|
||||
maxLines:maxLines,
|
||||
colorBorder: colorBorder,
|
||||
),
|
||||
Divider(color: ColorPalette.black54,height: 5,endIndent: 10,)
|
||||
],
|
||||
|
||||
@@ -33,7 +33,7 @@ class ItemCitizen extends StatelessWidget {
|
||||
title: TextDefault(text: name,fontWeigth: FontWeight.bold),
|
||||
subtitle: TextDefault(text: '$numberCNS - $numberMedicalRecord - $date - $mother',fontSize: 16),
|
||||
trailing: IconButton(
|
||||
icon: Icon(Icons.assignment_outlined),
|
||||
icon: Icon(Icons.assignment_rounded,size: 35,),
|
||||
onPressed: ()=>AlertDialogDefault().alertSelect(context),
|
||||
),
|
||||
onTap: onTap,
|
||||
|
||||
@@ -6,19 +6,21 @@ import 'package:rkm/widgets/text_default.dart';
|
||||
class TitleContainers extends StatelessWidget {
|
||||
String title;
|
||||
double width;
|
||||
TextAlign textAling;
|
||||
|
||||
TitleContainers({
|
||||
required this.title,
|
||||
this.width = double.infinity
|
||||
this.width = double.infinity,
|
||||
this.textAling = TextAlign.center
|
||||
});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Container(
|
||||
padding: ConstVariable().marginHightInput,
|
||||
padding: textAling!=TextAlign.center?EdgeInsets.all(10):ConstVariable().marginHightInput,
|
||||
width: width,
|
||||
color: ColorPalette.titleContainer,
|
||||
child: TextDefault(text: title,fontWeigth: FontWeight.bold,textAlign: TextAlign.center,color: ColorPalette.black54,),
|
||||
child: TextDefault(text: title,fontWeigth: FontWeight.bold,textAlign: textAling,color: ColorPalette.black54,),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user