Estes dados serao recebidos de uma API,
preciso que crie um modelo Master Detail para estes dados e faca os insert update delete, em Delphi XE
{
"id": "a4ea2658-536a-4885-af66-08ea126887e7",
"idPessoaTipo": 2,
"razaoSocialNome": "EMPRESA X",
"fantasia": "nome da empresa x",
"datadecadastro": "2018-01-01t00:00:00",
"ativo": true,
"pessoatipo": {
"id": 2,
"descricao": "juridica",
"datadecadastro": "0001-01-01t00:00:00",
"ativo": false
},
"cliente": {
"id": "a4ea2658-536a-4885-af66-08ea126887e7",
"emitenotafiscalservicotransporte": false,
"datadecadastro": "2018-01-16t08:26:52",
"ativo": true
},
"pessoajuridica": {
"id": "a4ea2658-536a-4885-af66-08ea126887e7",
"cnpj": "47.406.105\/0001-98",
"inscricaoEstadual": "635814545115",
"inscricaoMunicipal": "5374768",
"dataDeCadastro": "2018-01-01T00:00:00",
"ativo": true
},
"transportador": {
"id": "a4ea2658-536a-4885-af66-08ea126887e7",
"inicioContrato": "2018-01-01T00:00:00",
"terminoContrato": "2020-12-31T00:00:00",
"dataDeCadastro": "0001-01-01T00:00:00",
"idTipoRntrc": 0,
"rntrc": "02098799",
"validade": "2021-06-15T15:13:59.803",
"dataDeCadastroEFrete": "2019-08-15T11:28:05.26",
"anttLiberado": true,
"tacOuEquiparado": false,
"ativo": true
},
"pessoasEnderecos": [
{
"id": "d662b8d2-7055-4709-ae34-b06d4fd46df4",
"chaveDeAlteracao": "TRANSFERENCIA",
"idEndereco": "20ba5fcd-be1f-47a3-98ae-58745d3665da",
"idPessoa": "a4ea2658-536a-4885-af66-08ea126887e7",
"idPessoaTipoEndereco": 1,
"endereco": {
"id": "20ba5fcd-be1f-47a3-98ae-58745d3665da",
"idCidade": 9640,
"idEstado": 26,
"Idbairro": 115175,
"tipo": "avenida",
"logradouro": "av paulista",
"numero": "1500",
"complemento": "",
"cep": "09751000",
"chavedealteracao": "transferencia",
"ultimaalteracao": "2017-10-06t15:22:56.947",
"dataDeCadastro": "2018-01-02T00:00:00",
"ativo": true,
"cidade": {
"id": 9640,
"Idestado": 26,
"uf": "sp",
"nome": "sao bernardo do campo",
"datadecadastro": "0001-01-01t00:00:00",
"ativo": false
},
"bairro": {
"id": 115175,
"idcidade": 0,
"nome": "baeta neves",
"datadecadastro": "0001-01-01t00:00:00",
"ativo": false
}
},
"pessoatipoendereco": {
"descricao": "faturamento",
"datadecadastro": "0001-01-01t00:00:00",
"ativo": false
}
}
],
"pessoascontatos": [
{
"id": "00000000-0000-0000-0000-000000000000",
"idpessoa": "00000000-0000-0000-0000-000000000000",
"idtipocontato": 0,
"descricao": "
contasareceber@empresax.com.br",
"tipoContato": {
"descricao": "EMAIL DE COBRANCA",
"dataDeCadastro": "0001-01-01T00:00:00",
"ativo": false
}
}
]
}
Delivery term: May 18, 2020