enviando cadastro cidadão individual
This commit is contained in:
@@ -17,6 +17,7 @@ class ApiDataPost{
|
||||
print(response.statusCode);
|
||||
if(response.statusCode == 200) {
|
||||
await DBQuerys().updateCidadao();
|
||||
await DBQuerys().updateCadastroIndividuais();
|
||||
return json.decode(response.body);
|
||||
}else{
|
||||
return 'error';
|
||||
|
||||
@@ -459,4 +459,11 @@ class DBQuerys{
|
||||
Database db = await DbSqliteLoad().intialDB();
|
||||
await db.update('CIDADAOS', row,where: "SINCRONIZADO = 'N'");
|
||||
}
|
||||
Future updateCadastroIndividuais()async{
|
||||
Map<String, dynamic> row = {
|
||||
'SINCRONIZADO' : 'S',
|
||||
};
|
||||
Database db = await DbSqliteLoad().intialDB();
|
||||
await db.update('CADASTROS_INDIVIDUAIS', row,where: "SINCRONIZADO = 'N'");
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user