versão 1.0.13+14 state do salvar alterações de cadastro do cidadaos, e edicao do atendimento_domiciliar_tela.dart

This commit is contained in:
Reginaldo
2024-08-27 21:36:28 -03:00
parent 48a5a779bf
commit ce2a1cf4d1
9 changed files with 411 additions and 75 deletions

View File

@@ -359,14 +359,20 @@ class _RegisterCitizenScreenState extends State<RegisterCitizenScreen> {
checkCNS = 'ok';
}
if((selectClassification!='OUTRO MUNICIPIO' && selectCountry == 'BRASIL' && selectStreet == null) ||
(selectStreet!=null && (cepController.text.isEmpty || cepController.text.length!=10)) ||
(selectStreet!=null && numberController.text.isEmpty) ||
(selectClassification!='OUTRO MUNICIPIO' && selectStreet!=null && (cepController.text.isEmpty || cepController.text.length!=10)) ||
(selectClassification!='OUTRO MUNICIPIO' && selectStreet!=null && numberController.text.isEmpty) ||
(selectTypeStreet == null && selectClassification!='OUTRO MUNICIPIO') ||
(selectVillage == null && (selectCountry == 'BRASIL' && selectClassification!='OUTRO MUNICIPIO')) ||
(cityController.text.isEmpty && selectCountry!='OUTRO') ||
selectCountry == null
){
checkClassification = true;
print('selectClassification: $selectClassification');
print('selectCountry: $selectCountry');
print('selectStreet: $selectStreet');
print('cepController: ${cepController.text}');
print('selectVillage: $selectVillage');
print('cityController: ${cityController.text}');
print('erro no end');
}
@@ -380,7 +386,6 @@ class _RegisterCitizenScreenState extends State<RegisterCitizenScreen> {
selectClassification==null ||
selectCountry==null ||
date == 'Data de Nascimento'||
date == 'Data de Nascimento'||
cityBirthController.text.isEmpty ||
mobileDDDController.text.isEmpty ||
mobileController.text.isEmpty ||
@@ -487,7 +492,7 @@ class _RegisterCitizenScreenState extends State<RegisterCitizenScreen> {
'DT_OBITO' : dateDeathDB,
'DECLARACAO_OBITO' : '',
'BLOQUEIO' : enableBlocked?1:0,
'ORIGEM' : 'A',
'ORIGEM' : editing?'A':'C',
'DT_HORA_CADASTRO' : DateTime.now().toString(),
'SINCRONIZADO' : 'N',
};
@@ -516,6 +521,7 @@ class _RegisterCitizenScreenState extends State<RegisterCitizenScreen> {
'OK'
);
setState(() {
edit = true;
showTab = true;
});
// print(value);
@@ -814,7 +820,7 @@ class _RegisterCitizenScreenState extends State<RegisterCitizenScreen> {
margin: EdgeInsets.all(10),
child: Column(
children: [
TitleContainers(title: 'Indentificação'),
TitleContainers(title: 'Identificação'),
Row(
children: [
Container(
@@ -1400,7 +1406,7 @@ class _RegisterCitizenScreenState extends State<RegisterCitizenScreen> {
'OUTRO',
]
),
selectCountry==null&& mandatory?ErrorDefault():Container(),
selectPaisResidencia==null&& mandatory?ErrorDefault():Container(),
GestureDetector(
onTap: selectClassification!='OUTRO MUNICIPIO'|| cityController.text == 'MUNICIPIO IGNORADO'?null: (){
searchCityController.text = '';
@@ -1537,7 +1543,7 @@ class _RegisterCitizenScreenState extends State<RegisterCitizenScreen> {
},
list: typeStreetDB
),
selectTypeStreet!='OUTRO MUNICIPIO' && selectTypeStreet == null && selectCountry == null&& mandatory?ErrorDefault():Container(),
selectClassification!='OUTRO MUNICIPIO' && selectTypeStreet == null && selectCountry == null && mandatory?ErrorDefault():Container(),
DropdownWithSubtitle(
subtitle: 'Nome do Logradouro',
select: selectStreet,