{"version":3,"sources":["webpack:///./src/models/nfse/Pessoa.js","webpack:///./src/views/TomadorCadastro.vue?c03c","webpack:///./src/services/acesso/localidade.service.js","webpack:///./src/views/TomadorCadastro.vue?d1a8","webpack:///./src/services/acesso/logradouro.service.js","webpack:///src/views/TomadorCadastro.vue","webpack:///./src/views/TomadorCadastro.vue?6d67","webpack:///./src/views/TomadorCadastro.vue?066a","webpack:///./src/conf/config.money.js","webpack:///./src/services/nfse/pessoa.service.js","webpack:///./src/services/tributario/contribuinte.cadastro.service.js","webpack:///./src/services/nfse/serpro.service.js","webpack:///./src/Utils/util.js","webpack:///./src/services/acesso/pais.service.js"],"names":["Pessoa","this","id","idCliente","idUsuario","tipo","documento","nome","nomeFantasia","tipoLogradouro","logradouro","numero","complemento","bairro","cep","municipioCodigoIbge","municipioNome","estadoCodigoIbge","estadoNome","estadoSigla","paisCodigoIbge","paisNome","inscEstadual","inscMunic","email","site","telefone","celular","rg","dataHora","version","dataVigenciaInicial","dataVigenciaFinal","idFichaRespostaPai","idFluxoInstanciaAtividade","detail","idContribuinte","idContribuintePai","API_URL","LocalidadeService","LoginService","currentUser","subscribe","data","headers","token","filtro","axios","get","then","response","elements","codigoIbge","render","_vm","_h","$createElement","_c","_self","staticClass","attrs","showCadastroTomador","on","$event","_v","_s","headerDialog","erros","mensagemEdicaoTomador","_e","tiposTomador","desabilitarEdicao","desabilitarEdicaoEconomico","limparDadosTomador","model","value","callback","$$v","selectedTipoTomador","expression","key","desabilitarPesquisaCpfCnpj","pessoaTomador","$set","searchContribuintePorCpfCnpj","loading","searchDadosSerpro","filteredPaises","searchPais","selectedPais","habilitarEdicaoEnderecoPetrolina","searchLocalidadePorCep","filteredLocalidades","setLocalidades","searchLocalidade","selectedMunicipio","nomeEstado","nomePais","salvar","showSelecaoContribuinte","staticStyle","contribuintes","scopedSlots","_u","fn","objeto","preencherDadosTomador","hideSelecaoContribuinte","showSelectLogra","logradouroList","preencherDadosLogradouro","staticRenderFns","LogradouroService","codigo","name","props","tipoEmissao","String","tipoCadastroContribuinte","utilizaPesquisaSerpro","telaDaps","tipoEmissaoInternal","watch","newValue","created","$root","$on","methods","onSubmit","$validate","success","processando","usuario","edicaoPrestador","numeroPais","setTimeout","replace","cepLogradouro","nomeBairro","nomeTipoLogra","nomeLogradouro","validarDocumento","preencherContrTomador","contribuinte","idPessoa","nomeGeral","inscricaoMunicipal","inscricaoEstadual","idLocalidadeMunicipio","idBairro","idLogradouro","numeroLogradouro","complementoLogradouro","idCepLocalidade","contatos","$emit","numeroDocumentoJuridico","length","event","novoTomador","novoTomadorDaps","editarTomador","$parent","selectedPessoaIntermediario","selectedPessoa","editarDadosPrestador","selectedPessoaPrestador","keyTipo","filter","show","validar","console","log","computed","tipoPessoa","estado","component","money","decimal","thousands","prefix","suffix","precision","masked","NfsPessoaService","tipoTomador","currentUserValue","pessoa","post","JSON","stringify","idTomadorDados","idTipoEconomico","configuracao","idContrTipoEconomico","idTipoEventual","idContrTipoEventual","PessoaService","idTipo","idConta","cpfCnpj","SessoaService","Util","re","test","validado","validarCNPJ","validarCPF","cnpj","tamanho","numeros","substring","digitos","soma","pos","i","charAt","resultado","strCPF","Soma","Resto","parseInt"],"mappings":"2JAAMA,EACJ,aAAc,uBACZC,KAAKC,GAAK,GACVD,KAAKE,UAAY,GACjBF,KAAKG,UAAY,GACjBH,KAAKI,KAAO,GACZJ,KAAKK,UAAY,GACjBL,KAAKM,KAAO,GACZN,KAAKO,aAAe,GACpBP,KAAKQ,eAAiB,GACtBR,KAAKS,WAAa,GAClBT,KAAKU,OAAS,GACdV,KAAKW,YAAc,GACnBX,KAAKY,OAAS,GACdZ,KAAKa,IAAM,GACXb,KAAKc,oBAAsB,GAC3Bd,KAAKe,cAAgB,GACrBf,KAAKgB,iBAAmB,GACxBhB,KAAKiB,WAAa,GAClBjB,KAAKkB,YAAc,GACnBlB,KAAKmB,eAAiB,GACtBnB,KAAKoB,SAAW,GAChBpB,KAAKqB,aAAe,GACpBrB,KAAKsB,U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gB,WAAaD,EAAOA,EAAKE,MAAM,Q,+DAK3CC,GAAQ,WACpB,OAAOC,IAAMC,IAAIV,EAAU,iBAAiBQ,EAAQ,CAACF,QAAS3C,KAAK2C,UAAUK,MAAK,SAAAC,GAAQ,OAAK,EAAKP,KAAOO,EAASP,KAAKQ,gB,KAKlH,WAAIZ","file":"js/consulta.nfse~emissao.daps~emissao.nfse.b19e2bb3.js","sourcesContent":["class Pessoa {\r\n constructor() {\r\n this.id = ''\r\n this.idCliente = ''\r\n this.idUsuario = ''\r\n this.tipo = ''\r\n this.documento = ''\r\n this.nome = ''\r\n this.nomeFantasia = ''\r\n this.tipoLogradouro = ''\r\n this.logradouro = ''\r\n this.numero = ''\r\n this.complemento = ''\r\n this.bairro = ''\r\n this.cep = ''\r\n this.municipioCodigoIbge = ''\r\n this.municipioNome = ''\r\n this.estadoCodigoIbge = ''\r\n this.estadoNome = ''\r\n this.estadoSigla = ''\r\n this.paisCodigoIbge = ''\r\n this.paisNome = ''\r\n this.inscEstadual = ''\r\n this.inscMunic = ''\r\n this.email = ''\r\n this.site = ''\r\n this.telefone = ''\r\n this.celular = ''\r\n this.rg = ''\r\n this.dataHora = ''\r\n this.version = ''\r\n this.dataVigenciaInicial = ''\r\n this.dataVigenciaFinal = ''\r\n this.idFichaRespostaPai = ''\r\n this.idFluxoInstanciaAtividade = ''\r\n\r\n this.detail = ''\r\n \r\n // Joins...\r\n this.idContribuinte = null\r\n this.idContribuintePai = null\r\n }\r\n}\r\n\r\nexport default Pessoa\r\n","import mod from \"-!../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../../node_modules/css-loader/index.js??ref--6-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TomadorCadastro.vue?vue&type=style&index=0&id=218dddd2&scoped=true&lang=css&\"; export default mod; export * from \"-!../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--6-oneOf-1-0!../../node_modules/css-loader/index.js??ref--6-oneOf-1-1!../../node_modules/vue-loader/lib/loaders/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--6-oneOf-1-2!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TomadorCadastro.vue?vue&type=style&index=0&id=218dddd2&scoped=true&lang=css&\"","import axios from 'axios';\r\nimport LoginService from '../acesso/login.service'\r\n\r\nconst API_URL = process.env.VUE_APP_BASE_URL + '/api/acesso/localidade/';\r\n\r\nclass LocalidadeService {\r\n constructor() {\r\n LoginService.currentUser.subscribe(data => {\r\n this.headers = {\r\n 'Content-Type': 'application/json',\r\n 'authorization': 'Bearer ' + (data ? data.token : '')\r\n };\r\n });\r\n }\r\n\r\n findAllByFiltro(filtro) {\r\n return axios.get(API_URL + 'filter?filtro=' + filtro, { headers: this.headers }).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n findAllByFiltroSemIbge(filtro, codigoIbge) {\r\n return axios.get(API_URL + 'filterSemIbge?filtro=' + filtro + '&codigoIbge=' + codigoIbge, { headers: this.headers }).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n findAllByFiltroIbge(filtro) {\r\n return axios.get(API_URL + 'filterComIbge?filtro=' + filtro, { headers: this.headers }).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n findAllByCep(cep) {\r\n return axios.get(API_URL + 'filter?cep=' + cep, { headers: this.headers }).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n findAllById(id) {\r\n return axios.get(API_URL + 'findById?id=' + id, { headers: this.headers });\r\n }\r\n}\r\n\r\nexport default new LocalidadeService();","var render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{staticClass:\"tomador-cadastro\"},[_c('Dialog',{staticClass:\"tomador-modal\",attrs:{\"visible\":_vm.showCadastroTomador,\"modal\":true,\"closable\":false},on:{\"update:visible\":function($event){_vm.showCadastroTomador=$event}}},[_c('h1',{staticClass:\"titulo-header\"},[_vm._v(\"\\n \"+_vm._s(_vm.headerDialog)+\"\\n \"),_c('Button',{staticClass:\"p-button-rounded p-button-text\",attrs:{\"id\":\"icon-close-modals\",\"icon\":\"pi pi-times\"},on:{\"click\":function($event){_vm.showCadastroTomador = false}}})],1),_c('div',{staticClass:\"scrolable-dialog\",attrs:{\"id\":\"topo\"}},[_c('error-list',{attrs:{\"erros\":_vm.erros}}),(_vm.desabilitarEdicaoEconomico)?_c('p',{staticClass:\"mensagem-edicao\"},[_c('span',[_vm._v(_vm._s(this.mensagemEdicaoTomador))])]):_vm._e(),_c('div',{staticClass:\"row\"},[_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Tipo: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('Dropdown',{attrs:{\"id\":\"tipoTomador\",\"options\":_vm.tiposTomador,\"optionLabel\":\"name\",\"placeholder\":\"Selecione um Tipo de Tomador\",\"disabled\":_vm.desabilitarEdicao || _vm.desabilitarEdicaoEconomico,\"optionDisabled\":_vm.desabilitarEdicao || _vm.desabilitarEdicaoEconomico},on:{\"change\":function($event){return _vm.limparDadosTomador()}},model:{value:(_vm.selectedTipoTomador),callback:function ($$v) {_vm.selectedTipoTomador=$$v},expression:\"selectedTipoTomador\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(_vm._s((_vm.selectedTipoTomador.key === \"X\"\n ? \"NIF:\"\n : _vm.selectedTipoTomador.key === \"F\"\n ? \"CPF:\"\n : \"CNPJ:\") + \" *\"))]),_c('span',{staticClass:\"p-fluid\"},[(_vm.selectedTipoTomador.key === 'X')?[_c('InputText',{key:\"X\",attrs:{\"id\":\"tipoTomador\",\"type\":\"text\",\"disabled\":_vm.desabilitarPesquisaCpfCnpj},model:{value:(_vm.pessoaTomador.documento),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"documento\", $$v)},expression:\"pessoaTomador.documento\"}})]:[_c('div',{staticClass:\"p-inputgroup\"},[(_vm.selectedTipoTomador.key === 'F')?[_c('InputMask',{key:\"F\",attrs:{\"id\":\"tipoTomador\",\"mask\":\"999.999.999-99\",\"placeholder\":\"Pesquisar\",\"disabled\":_vm.desabilitarPesquisaCpfCnpj},on:{\"blur\":function($event){return _vm.searchContribuintePorCpfCnpj()}},model:{value:(_vm.pessoaTomador.documento),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"documento\", $$v)},expression:\"pessoaTomador.documento\"}})]:[_c('InputMask',{key:\"J\",attrs:{\"id\":\"tipoTomador\",\"mask\":\"99.999.999/9999-99\",\"placeholder\":\"Pesquisar\",\"disabled\":_vm.desabilitarPesquisaCpfCnpj},on:{\"blur\":function($event){return _vm.searchContribuintePorCpfCnpj()}},model:{value:(_vm.pessoaTomador.documento),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"documento\", $$v)},expression:\"pessoaTomador.documento\"}})],_c('Button',{staticClass:\"p-button\",attrs:{\"type\":\"button\",\"icon\":\"pi pi-search\",\"title\":\"Pesquisar Contribuinte\",\"disabled\":_vm.desabilitarPesquisaCpfCnpj},on:{\"click\":function($event){return _vm.searchContribuintePorCpfCnpj()}}})],2)]],2)]),(this.utilizaPesquisaSerpro)?_c('div',{staticClass:\"col-md-4 mb-1\"},[_c('label',{attrs:{\"for\":\"tipopessoa\"}},[_vm._v(\"Pesquisar Dados Receita Federal:\")]),_c('br'),_c('span',{staticClass:\"p-fluid\"},[_c('Button',{staticClass:\"p-button\",attrs:{\"type\":\"button\",\"icon\":\"pi pi-id-card\",\"title\":\"Pesquisar Dados Receita Federal\",\"disabled\":_vm.loading || _vm.desabilitarEdicaoEconomico},on:{\"click\":function($event){return _vm.searchDadosSerpro()}}})],1)]):_vm._e(),_c('div',{staticClass:\"col-md-9 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Nome: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.nome),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"nome\", $$v)},expression:\"pessoaTomador.nome\"}})],1)])]),(_vm.selectedTipoTomador.key !== 'X')?_c('div',{staticClass:\"row\"},[(_vm.selectedTipoTomador.key === 'F')?_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"RG:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.rg),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"rg\", $$v)},expression:\"pessoaTomador.rg\"}})],1)]):_vm._e(),(_vm.selectedTipoTomador.key === 'J')?_c('div',{staticClass:\"col-md-6 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Nome Fantasia:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.nomeFantasia),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"nomeFantasia\", $$v)},expression:\"pessoaTomador.nomeFantasia\"}})],1)]):_vm._e(),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Inscrição Estadual:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.inscEstadual),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"inscEstadual\", $$v)},expression:\"pessoaTomador.inscEstadual\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Inscrição Municipal:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.inscMunic),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"inscMunic\", $$v)},expression:\"pessoaTomador.inscMunic\"}})],1)])]):_vm._e(),_c('hr'),(_vm.selectedTipoTomador.key === 'X')?[_c('div',{staticClass:\"row\"},[_c('div',{staticClass:\"col-md-4 mb-2\"},[_c('label',{attrs:{\"for\":\"munic\"}},[_vm._v(\"PaÃs: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('AutoComplete',{attrs:{\"id\":\"munic\",\"dropdown\":true,\"suggestions\":_vm.filteredPaises,\"field\":\"detail\",\"placeholder\":\"Pesquisar\"},on:{\"complete\":function($event){return _vm.searchPais($event)}},model:{value:(_vm.selectedPais),callback:function ($$v) {_vm.selectedPais=$$v},expression:\"selectedPais\"}})],1)]),_c('div',{staticClass:\"col-md-8 col-sm-2 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Endereço: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\"},model:{value:(_vm.pessoaTomador.logradouro),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"logradouro\", $$v)},expression:\"pessoaTomador.logradouro\"}})],1)])])]:[_c('div',{staticClass:\"row d-flex align-items-end\"},[_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"CEP: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('div',{staticClass:\"p-inputgroup\"},[_c('InputMask',{attrs:{\"mask\":\"99.999-999\",\"placeholder\":\"Pesquisar\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},on:{\"blur\":function($event){return _vm.searchLocalidadePorCep()}},model:{value:(_vm.pessoaTomador.cep),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"cep\", $$v)},expression:\"pessoaTomador.cep\"}}),_c('Button',{staticClass:\"p-button\",attrs:{\"type\":\"button\",\"icon\":\"pi pi-search\",\"title\":\"Pesquisar CEP\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},on:{\"click\":function($event){return _vm.searchLocalidadePorCep()}}})],1)])]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"munic\"}},[_vm._v(\"MunicÃpio: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('AutoComplete',{attrs:{\"id\":\"munic\",\"dropdown\":true,\"suggestions\":_vm.filteredLocalidades,\"field\":\"detail\",\"placeholder\":\"Pesquisar\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina,\"optionDisabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},on:{\"item-select\":function($event){return _vm.setLocalidades($event)},\"complete\":function($event){return _vm.searchLocalidade($event)}},model:{value:(_vm.selectedMunicipio),callback:function ($$v) {_vm.selectedMunicipio=$$v},expression:\"selectedMunicipio\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Estado:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":\"\"},model:{value:(_vm.nomeEstado),callback:function ($$v) {_vm.nomeEstado=$$v},expression:\"nomeEstado\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"PaÃs:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":\"\"},model:{value:(_vm.nomePais),callback:function ($$v) {_vm.nomePais=$$v},expression:\"nomePais\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Bairro: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},model:{value:(_vm.pessoaTomador.bairro),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"bairro\", $$v)},expression:\"pessoaTomador.bairro\"}})],1)]),_c('div',{staticClass:\"col-md-2 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Tipo Logradouro: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},model:{value:(_vm.pessoaTomador.tipoLogradouro),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"tipoLogradouro\", $$v)},expression:\"pessoaTomador.tipoLogradouro\"}})],1)]),_c('div',{staticClass:\"col-md-5 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Logradouro: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},model:{value:(_vm.pessoaTomador.logradouro),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"logradouro\", $$v)},expression:\"pessoaTomador.logradouro\"}})],1)]),_c('div',{staticClass:\"col-md-2 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Número: *\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},model:{value:(_vm.pessoaTomador.numero),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"numero\", $$v)},expression:\"pessoaTomador.numero\"}})],1)]),_c('div',{staticClass:\"col-md-6 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Complemento:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico && !_vm.habilitarEdicaoEnderecoPetrolina},model:{value:(_vm.pessoaTomador.complemento),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"complemento\", $$v)},expression:\"pessoaTomador.complemento\"}})],1)])])],_c('hr'),_c('div',{staticClass:\"row\"},[_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"E-mail:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.email),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"email\", $$v)},expression:\"pessoaTomador.email\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Site:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputText',{attrs:{\"type\":\"text\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.site),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"site\", $$v)},expression:\"pessoaTomador.site\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Telefone:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputMask',{attrs:{\"mask\":\"(99) 9999-9999\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.telefone),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"telefone\", $$v)},expression:\"pessoaTomador.telefone\"}})],1)]),_c('div',{staticClass:\"col-md-3 mb-2\"},[_c('label',{attrs:{\"for\":\"tipoTomador\"}},[_vm._v(\"Celular:\")]),_c('span',{staticClass:\"p-fluid\"},[_c('InputMask',{attrs:{\"mask\":\"(99) 99999-999?9\",\"disabled\":_vm.desabilitarEdicaoEconomico},model:{value:(_vm.pessoaTomador.celular),callback:function ($$v) {_vm.$set(_vm.pessoaTomador, \"celular\", $$v)},expression:\"pessoaTomador.celular\"}})],1)])])],2),_c('hr'),_c('div',{staticClass:\"botoes-avancar-voltar\"},[_c('Button',{staticClass:\"p-button-primary mr-2 p-button-success\",attrs:{\"href\":\"#topo\",\"type\":\"button\",\"label\":\"Gravar\",\"icon\":\"pi pi-check\",\"disabled\":_vm.loading},on:{\"click\":function($event){return _vm.salvar()}}}),_c('Button',{staticClass:\"p-button-primary mr-2 p-button-danger\",attrs:{\"type\":\"button\",\"label\":\"Fechar\",\"icon\":\"pi pi-times\"},on:{\"click\":function($event){_vm.showCadastroTomador = false}}})],1)]),_c('Dialog',{staticClass:\"tomador-modal\",attrs:{\"header\":\"Seleção de Contribuinte\",\"visible\":_vm.showSelecaoContribuinte,\"modal\":true,\"closable\":false},on:{\"update:visible\":function($event){_vm.showSelecaoContribuinte=$event}}},[_c('h1',{staticClass:\"titulo-header\"},[_vm._v(\"\\n Seleção de Contribuinte\\n \"),_c('Button',{staticClass:\"p-button-rounded p-button-text\",attrs:{\"id\":\"icon-close-modals\",\"icon\":\"pi pi-times\"},on:{\"click\":function($event){_vm.showSelecaoContribuinte = false}}})],1),_c('div',{staticClass:\"scrolable-dialog selecao-contribuinte\"},[_c('div',{staticClass:\"row\"},[_c('DataTable',{staticStyle:{\"min-width\":\"100%\"},attrs:{\"value\":_vm.contribuintes,\"paginator\":true,\"rows\":5}},[_c('Column',{attrs:{\"headerStyle\":\"width: 30%\",\"field\":\"idPessoa.nomeGeral\",\"header\":\"Nome:\"}}),_c('Column',{attrs:{\"headerStyle\":\"width: 20%\",\"field\":\"idPessoa.numeroDocumentoJuridico\",\"header\":\"CPF/CNPJ:\"}}),_c('Column',{attrs:{\"headerStyle\":\"width: 15%\",\"field\":\"inscricaoMunicipal\",\"header\":\"Inscrição Municipal:\"}}),_c('Column',{attrs:{\"headerStyle\":\"width: 25%\",\"field\":\"detailEndereco\",\"header\":\"Endereço:\"}}),_c('Column',{attrs:{\"headerStyle\":\"width: 58px\",\"bodyStyle\":\"text-align: center\"},scopedSlots:_vm._u([{key:\"body\",fn:function(objeto){return [_c('Button',{attrs:{\"type\":\"button\",\"icon\":\"pi pi-check\",\"title\":\"Selecionar Contribuinte\"},on:{\"click\":function($event){return _vm.preencherDadosTomador(objeto.data)}}})]}}])})],1)],1)]),_c('hr'),_c('div',{staticClass:\"container\"},[_c('div',{staticClass:\"row\"},[_c('div',[_c('Button',{staticClass:\"p-button-primary mr-2 p-button-danger\",attrs:{\"type\":\"button\",\"label\":\"Fechar\",\"icon\":\"pi pi-times\"},on:{\"click\":function($event){return _vm.hideSelecaoContribuinte()}}})],1)])])]),_c('Dialog',{attrs:{\"header\":\"Seleção Endereço\",\"visible\":_vm.showSelectLogra,\"modal\":true,\"closable\":false},on:{\"update:visible\":function($event){_vm.showSelectLogra=$event}}},[_c('h1',{staticClass:\"titulo-header\"},[_vm._v(\"\\n Seleção Endereço\\n \"),_c('Button',{staticClass:\"p-button-rounded p-button-text\",attrs:{\"id\":\"icon-close-modals\",\"icon\":\"pi pi-times\"},on:{\"click\":function($event){_vm.showSelectLogra = false}}})],1),_c('div',{staticClass:\"scrolable-dialog selecao-contribuinte\"},[_c('div',{staticClass:\"row\"},[_c('DataTable',{staticStyle:{\"min-width\":\"100%\"},attrs:{\"value\":_vm.logradouroList,\"paginator\":true,\"rows\":5}},[_c('Column',{attrs:{\"field\":\"detail\",\"header\":\"Endereço:\"}}),_c('Column',{attrs:{\"headerStyle\":\"width: 58px\",\"bodyStyle\":\"text-align: center\"},scopedSlots:_vm._u([{key:\"body\",fn:function(objeto){return [_c('Button',{attrs:{\"type\":\"button\",\"icon\":\"pi pi-check\",\"title\":\"Selecionar\"},on:{\"click\":function($event){return _vm.preencherDadosLogradouro(objeto.data)}}})]}}])})],1)],1)]),_c('hr'),_c('div',{staticClass:\"container\"},[_c('div',{staticClass:\"row\"},[_c('div',[_c('Button',{staticClass:\"p-button-primary mr-2 p-button-danger\",attrs:{\"type\":\"button\",\"label\":\"Fechar\",\"icon\":\"pi pi-times\"},on:{\"click\":function($event){_vm.showSelectLogra = false}}})],1)])])])],1)}\nvar staticRenderFns = []\n\nexport { render, staticRenderFns }","import axios from 'axios';\r\nimport LoginService from '../acesso/login.service'\r\n\r\nconst API_URL = process.env.VUE_APP_BASE_URL + '/api/acesso/logradouro/';\r\n\r\nclass LogradouroService {\r\n constructor() {\r\n LoginService.currentUser.subscribe(data => {\r\n this.headers = {\r\n 'Content-Type':'application/json',\r\n 'authorization':'Bearer ' + (data ? data.token:'')\r\n };\r\n });\r\n }\r\n\r\n \r\n findAllByCep(cep) {\r\n return axios.get(API_URL + 'findByCep?cep='+cep, {headers: this.headers});\r\n }\r\n \r\n findAllByCodigo(codigo) {\r\n return axios.get(API_URL + 'findByCodigo?codigo='+codigo, {headers: this.headers});\r\n }\r\n}\r\n\r\nexport default new LogradouroService();","<template>\r\n <div class=\"tomador-cadastro\">\r\n <Dialog class=\"tomador-modal\" :visible.sync=\"showCadastroTomador\" :modal=\"true\"\r\n :closable=\"false\">\r\n <h1 class=\"titulo-header\">\r\n {{ headerDialog }}\r\n <Button id=\"icon-close-modals\" icon=\"pi pi-times\" class=\"p-button-rounded p-button-text\" @click=\"showCadastroTomador = false\"/>\r\n </h1>\r\n <div id=\"topo\" class=\"scrolable-dialog\">\r\n <error-list :erros=\"erros\" />\r\n\r\n <p class=\"mensagem-edicao\" v-if=\"desabilitarEdicaoEconomico\">\r\n <span>{{ this.mensagemEdicaoTomador }}</span>\r\n </p>\r\n\r\n <div class=\"row\">\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Tipo: *</label>\r\n <span class=\"p-fluid\">\r\n <Dropdown id=\"tipoTomador\" v-model=\"selectedTipoTomador\" :options=\"tiposTomador\" optionLabel=\"name\"\r\n placeholder=\"Selecione um Tipo de Tomador\" @change=\"limparDadosTomador()\"\r\n :disabled=\"desabilitarEdicao || desabilitarEdicaoEconomico\" :optionDisabled=\"desabilitarEdicao || desabilitarEdicaoEconomico\r\n \" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">{{\r\n (selectedTipoTomador.key === \"X\"\r\n ? \"NIF:\"\r\n : selectedTipoTomador.key === \"F\"\r\n ? \"CPF:\"\r\n : \"CNPJ:\") + \" *\"\r\n }}</label>\r\n <span class=\"p-fluid\">\r\n <template v-if=\"selectedTipoTomador.key === 'X'\">\r\n <InputText v-model=\"pessoaTomador.documento\" key=\"X\" id=\"tipoTomador\" type=\"text\"\r\n :disabled=\"desabilitarPesquisaCpfCnpj\" />\r\n </template>\r\n\r\n <template v-else>\r\n <div class=\"p-inputgroup\">\r\n <template v-if=\"selectedTipoTomador.key === 'F'\">\r\n <InputMask @blur=\"searchContribuintePorCpfCnpj()\" v-model=\"pessoaTomador.documento\" key=\"F\"\r\n id=\"tipoTomador\" mask=\"999.999.999-99\" placeholder=\"Pesquisar\"\r\n :disabled=\"desabilitarPesquisaCpfCnpj\" />\r\n </template>\r\n <template v-else>\r\n <InputMask @blur=\"searchContribuintePorCpfCnpj()\" v-model=\"pessoaTomador.documento\" key=\"J\"\r\n id=\"tipoTomador\" mask=\"99.999.999/9999-99\" placeholder=\"Pesquisar\"\r\n :disabled=\"desabilitarPesquisaCpfCnpj\" />\r\n </template>\r\n <Button @click=\"searchContribuintePorCpfCnpj()\" type=\"button\" icon=\"pi pi-search\" class=\"p-button\"\r\n title=\"Pesquisar Contribuinte\" :disabled=\"desabilitarPesquisaCpfCnpj\" />\r\n </div>\r\n </template>\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-4 mb-1\" v-if=\"this.utilizaPesquisaSerpro\">\r\n <label for=\"tipopessoa\">Pesquisar Dados Receita Federal:</label>\r\n <br />\r\n <span class=\"p-fluid\">\r\n <Button @click=\"searchDadosSerpro()\" type=\"button\" icon=\"pi pi-id-card\" class=\"p-button\"\r\n title=\"Pesquisar Dados Receita Federal\" :disabled=\"loading || desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-9 mb-2\">\r\n <label for=\"tipoTomador\">Nome: *</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.nome\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n </div>\r\n\r\n <div class=\"row\" v-if=\"selectedTipoTomador.key !== 'X'\">\r\n <div class=\"col-md-3 mb-2\" v-if=\"selectedTipoTomador.key === 'F'\">\r\n <label for=\"tipoTomador\">RG:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.rg\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-6 mb-2\" v-if=\"selectedTipoTomador.key === 'J'\">\r\n <label for=\"tipoTomador\">Nome Fantasia:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.nomeFantasia\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Inscrição Estadual:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.inscEstadual\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Inscrição Municipal:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.inscMunic\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n </div>\r\n\r\n <hr />\r\n\r\n <template v-if=\"selectedTipoTomador.key === 'X'\">\r\n <div class=\"row\">\r\n <div class=\"col-md-4 mb-2\">\r\n <label for=\"munic\">PaÃs: *</label>\r\n <span class=\"p-fluid\">\r\n <AutoComplete id=\"munic\" v-model=\"selectedPais\" :dropdown=\"true\" :suggestions=\"filteredPaises\"\r\n @complete=\"searchPais($event)\" field=\"detail\" placeholder=\"Pesquisar\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-8 col-sm-2 mb-2\">\r\n <label for=\"tipoTomador\">Endereço: *</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.logradouro\" type=\"text\" />\r\n </span>\r\n </div>\r\n </div>\r\n </template>\r\n\r\n <template v-else>\r\n <div class=\"row d-flex align-items-end\">\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">CEP: *</label>\r\n <span class=\"p-fluid\">\r\n <div class=\"p-inputgroup\">\r\n <InputMask @blur=\"searchLocalidadePorCep()\" v-model=\"pessoaTomador.cep\" mask=\"99.999-999\"\r\n placeholder=\"Pesquisar\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n <Button @click=\"searchLocalidadePorCep()\" type=\"button\" icon=\"pi pi-search\" class=\"p-button\"\r\n title=\"Pesquisar CEP\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n </div>\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"munic\">MunicÃpio: *</label>\r\n <span class=\"p-fluid\">\r\n <AutoComplete id=\"munic\" v-model=\"selectedMunicipio\" :dropdown=\"true\" :suggestions=\"filteredLocalidades\"\r\n @item-select=\"setLocalidades($event)\" @complete=\"searchLocalidade($event)\" field=\"detail\"\r\n placeholder=\"Pesquisar\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\"\r\n :optionDisabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Estado:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"nomeEstado\" type=\"text\" disabled />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">PaÃs:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"nomePais\" type=\"text\" disabled />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Bairro: *</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.bairro\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-2 mb-2\">\r\n <label for=\"tipoTomador\">Tipo Logradouro: *</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.tipoLogradouro\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-5 mb-2\">\r\n <label for=\"tipoTomador\">Logradouro: *</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.logradouro\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-2 mb-2\">\r\n <label for=\"tipoTomador\">Número: *</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.numero\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-6 mb-2\">\r\n <label for=\"tipoTomador\">Complemento:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.complemento\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico && !habilitarEdicaoEnderecoPetrolina\" />\r\n </span>\r\n </div>\r\n </div>\r\n </template>\r\n\r\n <hr />\r\n\r\n <div class=\"row\">\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">E-mail:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.email\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Site:</label>\r\n <span class=\"p-fluid\">\r\n <InputText v-model=\"pessoaTomador.site\" type=\"text\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Telefone:</label>\r\n <span class=\"p-fluid\">\r\n <InputMask v-model=\"pessoaTomador.telefone\" mask=\"(99) 9999-9999\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n\r\n <div class=\"col-md-3 mb-2\">\r\n <label for=\"tipoTomador\">Celular:</label>\r\n <span class=\"p-fluid\">\r\n <InputMask v-model=\"pessoaTomador.celular\" mask=\"(99) 99999-999?9\" :disabled=\"desabilitarEdicaoEconomico\" />\r\n </span>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n <hr />\r\n\r\n <div class=\"botoes-avancar-voltar\">\r\n <Button @click=\"salvar()\" href=\"#topo\" type=\"button\" label=\"Gravar\" class=\"p-button-primary mr-2 p-button-success\" icon=\"pi pi-check\" :disabled=\"loading\" />\r\n <Button @click=\"showCadastroTomador = false\" type=\"button\" label=\"Fechar\" class=\"p-button-primary mr-2 p-button-danger\" icon=\"pi pi-times\" />\r\n </div>\r\n </Dialog>\r\n\r\n <Dialog class=\"tomador-modal\" header=\"Seleção de Contribuinte\" :visible.sync=\"showSelecaoContribuinte\" :modal=\"true\"\r\n :closable=\"false\">\r\n <h1 class=\"titulo-header\">\r\n Seleção de Contribuinte\r\n <Button id=\"icon-close-modals\" icon=\"pi pi-times\" class=\"p-button-rounded p-button-text\" @click=\"showSelecaoContribuinte = false\"/>\r\n </h1>\r\n <div class=\"scrolable-dialog selecao-contribuinte\">\r\n <div class=\"row\">\r\n <DataTable :value=\"contribuintes\" :paginator=\"true\" :rows=\"5\" style=\"min-width: 100%\">\r\n <Column headerStyle=\"width: 30%\" field=\"idPessoa.nomeGeral\" header=\"Nome:\"></Column>\r\n <Column headerStyle=\"width: 20%\" field=\"idPessoa.numeroDocumentoJuridico\" header=\"CPF/CNPJ:\"></Column>\r\n <Column headerStyle=\"width: 15%\" field=\"inscricaoMunicipal\" header=\"Inscrição Municipal:\"></Column>\r\n <Column headerStyle=\"width: 25%\" field=\"detailEndereco\" header=\"Endereço:\"></Column>\r\n <Column headerStyle=\"width: 58px\" bodyStyle=\"text-align: center\">\r\n <template #body=\"objeto\">\r\n <Button type=\"button\" icon=\"pi pi-check\" title=\"Selecionar Contribuinte\"\r\n @click=\"preencherDadosTomador(objeto.data)\"></Button>\r\n </template>\r\n </Column>\r\n </DataTable>\r\n </div>\r\n </div>\r\n\r\n <hr />\r\n\r\n <div class=\"container\">\r\n <div class=\"row\">\r\n <div>\r\n <Button @click=\"hideSelecaoContribuinte()\" type=\"button\" label=\"Fechar\"\r\n class=\"p-button-primary mr-2 p-button-danger\" icon=\"pi pi-times\" />\r\n </div>\r\n </div>\r\n </div>\r\n </Dialog>\r\n \r\n <Dialog header=\"Seleção Endereço\" :visible.sync=\"showSelectLogra\" :modal=\"true\" :closable=\"false\">\r\n <h1 class=\"titulo-header\">\r\n Seleção Endereço\r\n <Button id=\"icon-close-modals\" icon=\"pi pi-times\" class=\"p-button-rounded p-button-text\" @click=\"showSelectLogra = false\"/>\r\n </h1>\r\n <div class=\"scrolable-dialog selecao-contribuinte\">\r\n <div class=\"row\">\r\n <DataTable :value=\"logradouroList\" :paginator=\"true\" :rows=\"5\" style=\"min-width: 100%\">\r\n <Column field=\"detail\" header=\"Endereço:\"></Column>\r\n <Column headerStyle=\"width: 58px\" bodyStyle=\"text-align: center\">\r\n <template #body=\"objeto\">\r\n <Button type=\"button\" icon=\"pi pi-check\" title=\"Selecionar\"\r\n @click=\"preencherDadosLogradouro(objeto.data)\"></Button>\r\n </template>\r\n </Column>\r\n </DataTable>\r\n </div>\r\n </div>\r\n\r\n <hr />\r\n\r\n <div class=\"container\">\r\n <div class=\"row\">\r\n <div>\r\n <Button @click=\"showSelectLogra = false\" type=\"button\" label=\"Fechar\"\r\n class=\"p-button-primary mr-2 p-button-danger\" icon=\"pi pi-times\" />\r\n </div>\r\n </div>\r\n </div>\r\n </Dialog>\r\n </div>\r\n</template>\r\n\r\n<script>\r\nimport LocalidadeService from \"../services/acesso/localidade.service\";\r\nimport LogradouroService from \"../services/acesso/logradouro.service\";\r\nimport ContribuinteCadastro from \"../services/tributario/contribuinte.cadastro.service\";\r\nimport PaisService from \"../services/acesso/pais.service\";\r\nimport LoginService from \"../services/acesso/login.service\";\r\nimport NfsPessoaService from \"../services/nfse/pessoa.service\";\r\nimport SerproService from \"../services/nfse/serpro.service\";\r\nimport Pessoa from \"../models/nfse/Pessoa\";\r\nimport Util from \"../Utils/util\";\r\n\r\nexport default {\r\n name: \"TomadorCadastro\",\r\n\r\n props: {\r\n tipoEmissao: String,\r\n },\r\n\r\n data() {\r\n return {\r\n loading: false,\r\n erros: [],\r\n showCadastroTomador: false,\r\n showSelecaoContribuinte: false,\r\n currentUser: null,\r\n tipoCadastroContribuinte: null,\r\n pessoaTomador: new Pessoa(),\r\n contribuintes: [],\r\n tiposTomador: [\r\n { name: \"Pessoa FÃsica\", key: \"F\" },\r\n { name: \"Pessoa JurÃdica\", key: \"J\" },\r\n { name: \"Entidade\", key: \"E\" },\r\n { name: \"Exterior\", key: \"X\" },\r\n ],\r\n selectedTipoTomador: null,\r\n filteredLocalidades: null,\r\n filteredPaises: null,\r\n selectedMunicipio: null,\r\n\r\n selectedPais: null,\r\n utilizaPesquisaSerpro: false,\r\n logradouroList: [],\r\n showSelectLogra: false,\r\n telaDaps: false,\r\n tipoEmissaoInternal: this.tipoEmissao, // Add this line to track tipoEmissao internally\r\n };\r\n },\r\n\r\n watch: {\r\n // Add watcher to sync prop changes with internal data\r\n tipoEmissao(newValue) {\r\n this.tipoEmissaoInternal = newValue;\r\n }\r\n },\r\n\r\n created() {\r\n this.$root.$on(\"notaFiscal:novoTomador\", () => {\r\n this.novoTomador('P');\r\n });\r\n\r\n this.$root.$on(\"notaFiscal:novoIntermediario\", () => {\r\n this.novoTomador('I');\r\n });\r\n\r\n this.$root.$on(\"notaFiscal:novoTomadorDaps\", () => {\r\n this.novoTomadorDaps();\r\n });\r\n\r\n this.$root.$on(\"notaFiscal:editarTomador\", () => {\r\n this.editarTomador('P');\r\n });\r\n\r\n this.$root.$on(\"notaFiscal:editarIntermediario\", () => {\r\n this.editarTomador('I');\r\n });\r\n\r\n this.$root.$on(\"notaFiscal:editarPrestador\", () => {\r\n this.editarDadosPrestador();\r\n });\r\n\r\n this.currentUser = LoginService.currentUserValue;\r\n this.selectedTipoTomador = this.tiposTomador[0];\r\n this.limparDadosTomador();\r\n },\r\n\r\n methods: {\r\n // Deverá ser chamado para validação do formulário, antes de salvar\r\n onSubmit() {\r\n this.$validate().then((success) => {\r\n if (success) {\r\n this.salvar();\r\n }\r\n });\r\n },\r\n\r\n salvar() {\r\n this.processando(true);\r\n\r\n this.pessoaTomador.idCliente = this.currentUser.usuario.idCliente;\r\n this.pessoaTomador.idUsuario = this.currentUser.usuario.idUsuario;\r\n //this.pessoaTomador.idContribuinte = this.pessoaTomador.idContribuinte;\r\n\r\n this.pessoaTomador.edicaoPrestador = null;\r\n if(this.tipoEmissaoInternal === 'EP'){\r\n this.pessoaTomador.edicaoPrestador = 'S';\r\n }else{\r\n this.pessoaTomador.idContribuintePai =\r\n this.currentUser.contribuinte.idContribuinte;\r\n }\r\n\r\n\r\n\r\n // Apenas para teste (está gerando ID no lado Server)\r\n //this.pessoaTomador.id = new Date().getTime().toString();\r\n\r\n this.pessoaTomador.tipo = this.selectedTipoTomador.key;\r\n\r\n if (this.pessoaTomador.tipo === \"X\") {\r\n if (this.selectedPais) {\r\n this.pessoaTomador.paisCodigoIbge = this.selectedPais.numeroPais;\r\n this.pessoaTomador.paisNome = this.selectedPais.nomePais;\r\n }\r\n } else {\r\n if (this.selectedMunicipio) {\r\n this.pessoaTomador.municipioCodigoIbge =\r\n this.selectedMunicipio.codigoIbge;\r\n this.pessoaTomador.municipioNome =\r\n this.selectedMunicipio.nomeLocalidade;\r\n\r\n this.pessoaTomador.estadoCodigoIbge =\r\n this.selectedMunicipio.estado.codigoIbge;\r\n this.pessoaTomador.estadoNome =\r\n this.selectedMunicipio.estado.nomeEstado;\r\n this.pessoaTomador.estadoSigla =\r\n this.selectedMunicipio.estado.siglaEstado;\r\n\r\n this.pessoaTomador.paisCodigoIbge =\r\n this.selectedMunicipio.estado.pais.numeroPais;\r\n this.pessoaTomador.paisNome =\r\n this.selectedMunicipio.estado.pais.nomePais;\r\n }\r\n }\r\n\r\n this.erros = [];\r\n\r\n NfsPessoaService.save(this.pessoaTomador)\r\n .then(\r\n (data) => {\r\n console.log(data);\r\n this.limparDadosTomador();\r\n this.showCadastroTomador = false;\r\n\r\n if(this.tipoEmissaoInternal === 'I'){\r\n this.$parent.selectedPessoaIntermediario = data.data; \r\n this.$root.$emit(\"alert:success\", \"O Intermediário foi salvo!\");\r\n }else if(this.tipoEmissaoInternal === 'EP'){\r\n this.$parent.selectedPessoaPrestador = data.data; \r\n this.$root.$emit(\"alert:success\", \"O Prestador foi salvo!\");\r\n }else{\r\n this.$parent.selectedPessoa = data.data;\r\n this.$root.$emit(\"alert:success\", \"O Tomador foi salvo!\");\r\n }\r\n\r\n \r\n\r\n if (this.telaDaps) {\r\n this.$parent.atualizarDadosPessoaSelecionada();\r\n }\r\n },\r\n (error) => {\r\n const erros = error.response.data;\r\n this.erros.push(...erros);\r\n\r\n if (!this.erros.length) {\r\n this.$root.$emit(\r\n \"alert:error\",\r\n \"Houve um problema ao salvar o Tomador!\"\r\n );\r\n }\r\n }\r\n )\r\n .then(() => {\r\n this.processando(false);\r\n });\r\n },\r\n\r\n searchLocalidade(event) {\r\n setTimeout(async () => {\r\n this.filteredLocalidades = await LocalidadeService.findAllByFiltro(\r\n event.query\r\n );\r\n }, 250);\r\n },\r\n\r\n searchLocalidadePorCep() {\r\n if (this.pessoaTomador.cep !== \"\") {\r\n this.processando(true);\r\n let cep = this.pessoaTomador.cep;\r\n cep = cep.replace(\".\", \"\");\r\n cep = cep.replace(\"-\", \"\");\r\n LogradouroService.findAllByCep(cep)\r\n .then(\r\n (response) => {\r\n if (response.data.length && response.data.length > 1) {\r\n this.logradouroList = response.data;\r\n this.showSelectLogra = true;\r\n } else if (response.data.length > 0) {\r\n this.selectedLogradouro = response.data[0];\r\n this.preencherDadosLogradouro(this.selectedLogradouro);\r\n }\r\n },\r\n (error) => {\r\n let errorMessage = \"Houve um problema ao listar Logradouros!\";\r\n if (error.response) {\r\n errorMessage = error.response.data;\r\n }\r\n this.$toast.add({\r\n severity: \"error\",\r\n summary: errorMessage,\r\n });\r\n }\r\n )\r\n .then(() => {\r\n this.processando(false);\r\n });\r\n }\r\n },\r\n\r\n preencherDadosLogradouro(logradouro) {\r\n this.processando(true);\r\n this.pessoaTomador.cep = logradouro.cepLogradouro;\r\n this.pessoaTomador.bairro = logradouro.nomeBairro;\r\n this.pessoaTomador.tipoLogradouro = logradouro.nomeTipoLogra;\r\n this.pessoaTomador.logradouro = logradouro.nomeLogradouro;\r\n LocalidadeService.findAllById(logradouro.idCepLocalidade)\r\n .then((response) => {\r\n this.selectedMunicipio = response.data;\r\n })\r\n .then(() => {\r\n this.processando(false);\r\n this.showSelectLogra = false;\r\n });\r\n },\r\n\r\n searchPais(event) {\r\n setTimeout(async () => {\r\n this.filteredPaises = await PaisService.findAllByFiltro(event.query);\r\n }, 250);\r\n },\r\n\r\n searchContribuintePorCpfCnpj() {\r\n const documento = this.pessoaTomador.documento;\r\n this.utilizaPesquisaSerpro = false;\r\n if (documento !== \"\" && this.validarDocumento()) {\r\n this.processando(true);\r\n\r\n ContribuinteCadastro.findAllByTipoCpfCnpj(documento)\r\n .then((data) => {\r\n console.log(data);\r\n\r\n if (data.length) {\r\n this.contribuintes = data;\r\n\r\n // Se encontrar mais de um cadastro, exibe dialog para selecionar.\r\n // Se não, já preenche os dados com o contribuinte encontrado.\r\n if (data.length > 1) {\r\n this.showSelecaoContribuinte = true;\r\n } else {\r\n this.preencherDadosTomador(this.contribuintes[0]);\r\n }\r\n } else {\r\n if (this.pessoaTomador.idContribuinte) {\r\n this.limparDadosTomador();\r\n this.pessoaTomador.documento = documento;\r\n }\r\n if (this.currentUser.configuracao.integracaoSerpro == \"S\") {\r\n this.utilizaPesquisaSerpro = true;\r\n }\r\n }\r\n },\r\n (error) => {\r\n if (error.response.data) {\r\n this.pessoaTomador.documento = null;\r\n this.$root.$emit(\"alert:warn\", error.response.data);\r\n } else {\r\n this.$root.$emit(\"alert:warn\", \"não foi possÃvel consultar o cadastro!\");\r\n }\r\n })\r\n .then(() => {\r\n this.processando(false);\r\n });\r\n } else {\r\n if (this.pessoaTomador.idContribuinte) {\r\n this.limparDadosTomador();\r\n this.pessoaTomador.documento = documento;\r\n }\r\n }\r\n },\r\n\r\n preencherDadosTomador(contribuinte) {\r\n this.hideSelecaoContribuinte();\r\n\r\n this.tipoCadastroContribuinte =\r\n contribuinte.idContribuinteTipo && contribuinte.idContribuinteTipo.id\r\n ? contribuinte.idContribuinteTipo.id\r\n : \"\";\r\n\r\n this.pessoaTomador.id =\r\n contribuinte.idPessoa && contribuinte.idPessoa.id\r\n ? contribuinte.idPessoa.id\r\n : null;\r\n this.preencherContrTomador(contribuinte);\r\n this.pessoaTomador.documento =\r\n contribuinte.idPessoa.numeroDocumentoJuridico;\r\n this.pessoaTomador.nome = contribuinte.idPessoa.nomeGeral;\r\n this.pessoaTomador.nomeFantasia = contribuinte.nomeFantasia;\r\n this.pessoaTomador.inscMunic = contribuinte.inscricaoMunicipal;\r\n this.pessoaTomador.inscEstadual = contribuinte.inscricaoEstadual;\r\n this.pessoaTomador.cep = contribuinte.cep;\r\n this.selectedMunicipio = contribuinte.idLocalidadeMunicipio;\r\n this.pessoaTomador.bairro = contribuinte.idBairro\r\n ? contribuinte.idBairro.nomeBairro\r\n : \"\";\r\n this.pessoaTomador.tipoLogradouro =\r\n contribuinte.idLogradouro && contribuinte.idLogradouro.idCepTipoLogra\r\n ? contribuinte.idLogradouro.idCepTipoLogra.nomeTipoLogra\r\n : \"\";\r\n this.pessoaTomador.logradouro = contribuinte.idLogradouro\r\n ? contribuinte.idLogradouro.nomeLogradouro\r\n : \"\";\r\n this.pessoaTomador.numero = contribuinte.numeroLogradouro;\r\n this.pessoaTomador.complemento = contribuinte.complementoLogradouro;\r\n this.pessoaTomador.idCepLocalidade = (contribuinte.idLocalidadeMunicipio ? contribuinte.idLocalidadeMunicipio.id : null); \r\n\r\n this.pessoaTomador.email = contribuinte.contatos.email;\r\n this.pessoaTomador.site = contribuinte.contatos.site;\r\n this.pessoaTomador.telefone = contribuinte.contatos.telefone;\r\n this.pessoaTomador.celular = contribuinte.contatos.celular;\r\n\r\n if (\r\n this.pessoaTomador.idContribuinte &&\r\n contribuinte.idContribuinteTipo.id ==\r\n this.currentUser.configuracao.idContrTipoEconomico\r\n ) {\r\n this.$root.$emit(\r\n \"alert:warn\",\r\n this.mensagemEdicaoTomador\r\n );\r\n }\r\n },\r\n\r\n preencherContrTomador(contribuinte) {\r\n //pessoa fisica porto velho permite edição tomador\r\n if (this.currentUser.usuario.idCliente === '8051f762-e8f9-487c-b537-4b2ce582c5e9' && contribuinte.idPessoa && contribuinte.idPessoa.numeroDocumentoJuridico && contribuinte.idPessoa.numeroDocumentoJuridico.length <= 14) {\r\n return;\r\n } else if (\r\n contribuinte.idContribuinteTipo &&\r\n contribuinte.idContribuinteTipo.id ==\r\n this.currentUser.configuracao.idContrTipoEconomico\r\n ) {\r\n this.pessoaTomador.idContribuinte = contribuinte.id;\r\n }\r\n },\r\n\r\n setLocalidades(event) {\r\n this.selectedMunicipio = event.value;\r\n },\r\n\r\n novoTomador(tipoEmissao) {\r\n this.tipoEmissaoInternal = tipoEmissao; // Use internal data instead of prop\r\n this.limparDadosTomador();\r\n this.selectedTipoTomador = this.tiposTomador[0];\r\n this.showCadastroTomador = true;\r\n this.telaDaps = false;\r\n },\r\n\r\n novoTomadorDaps() {\r\n this.limparDadosTomador();\r\n this.selectedTipoTomador = this.tiposTomador[0];\r\n this.showCadastroTomador = true;\r\n this.telaDaps = true;\r\n },\r\n\r\n editarTomador(tipoEmissao) {\r\n this.tipoEmissaoInternal = tipoEmissao;\r\n this.limparDadosTomador();\r\n // Carrega o objeto pessoa da tela de Emissão de Nota\r\n if(this.tipoEmissaoInternal === 'I'){\r\n this.pessoaTomador = this.$parent.selectedPessoaIntermediario;\r\n }else{\r\n this.pessoaTomador = this.$parent.selectedPessoa;\r\n }\r\n \r\n this.processando(true);\r\n //Carrega o Tipo de Cadastro\r\n setTimeout(async () => {\r\n await ContribuinteCadastro.findTipoCadastroContribuinte(\r\n this.pessoaTomador.documento,\r\n this.pessoaTomador.inscMunic\r\n ).then((data) => {\r\n if (data) {\r\n this.tipoCadastroContribuinte = data.data.tipoCadastroContribuinte;\r\n var vigenteNfse = data.data.vigenteNfse;\r\n //pessoa fisica porto velho permite edição tomador\r\n if (this.currentUser.usuario.idCliente === '8051f762-e8f9-487c-b537-4b2ce582c5e9' && this.pessoaTomador.documento && this.pessoaTomador.documento.length <= 14) {\r\n this.pessoaTomador.idContribuinte = null;\r\n } else if (!vigenteNfse || vigenteNfse !== \"S\") {\r\n this.pessoaTomador.idContribuinte = null;\r\n }\r\n }\r\n }).then(() => {\r\n // Carrega o Tipo do Tomador\r\n var keyTipo = this.pessoaTomador.tipo;\r\n this.selectedTipoTomador = this.tiposTomador.filter(\r\n (tipo) => tipo.key == keyTipo\r\n )[0];\r\n\r\n if (keyTipo == \"X\") {\r\n // Carrega dados do endereço (exterior)\r\n PaisService.findAllByFiltro(this.pessoaTomador.paisCodigoIbge).then(\r\n (data) => {\r\n if (data.length) {\r\n this.selectedPais = data[0];\r\n }\r\n }\r\n );\r\n } else {\r\n // Carrega dados do endereço\r\n LocalidadeService.findAllByFiltro(\r\n this.pessoaTomador.municipioCodigoIbge\r\n ).then((data) => {\r\n if (data.length) {\r\n this.selectedMunicipio = data[0];\r\n }\r\n });\r\n }\r\n\r\n this.showCadastroTomador = true;\r\n this.processando(false);\r\n });\r\n }, 250);\r\n\r\n\r\n },\r\n\r\n editarDadosPrestador() {\r\n this.limparDadosTomador();\r\n this.tipoEmissaoInternal = 'EP';//edicao de prestador\r\n // Carrega o objeto pessoa da tela de Emissão de Nota\r\n this.pessoaTomador = this.$parent.selectedPessoaPrestador;\r\n this.processando(true);\r\n\r\n // Carrega o Tipo do Tomador\r\n var keyTipo = this.pessoaTomador.tipo;\r\n this.selectedTipoTomador = this.tiposTomador.filter(\r\n (tipo) => tipo.key == keyTipo\r\n )[0];\r\n\r\n if (keyTipo == \"X\") {\r\n // Carrega dados do endereço (exterior)\r\n PaisService.findAllByFiltro(this.pessoaTomador.paisCodigoIbge).then(\r\n (data) => {\r\n if (data.length) {\r\n this.selectedPais = data[0];\r\n }\r\n }\r\n );\r\n } else {\r\n // Carrega dados do endereço\r\n LocalidadeService.findAllByFiltro(\r\n this.pessoaTomador.municipioCodigoIbge\r\n ).then((data) => {\r\n if (data.length) {\r\n this.selectedMunicipio = data[0];\r\n }\r\n });\r\n }\r\n\r\n this.showCadastroTomador = true;\r\n this.processando(false);\r\n\r\n\r\n },\r\n\r\n searchDadosSerpro() {\r\n const documento = this.pessoaTomador.documento;\r\n if (documento !== \"\" && this.validarDocumento()) {\r\n this.processando(true);\r\n\r\n SerproService.findByDocumento(\r\n this.currentUser.usuario.idCliente,\r\n documento\r\n )\r\n .then(\r\n (response) => {\r\n console.log(response.data);\r\n this.pessoaTomador.nome = response.data.nome_empresarial\r\n ? response.data.nome_empresarial\r\n : response.data.nome;\r\n this.pessoaTomador.nomeFantasia = response.data.nome_fantasia\r\n ? response.data.nome_fantasia\r\n : \"\";\r\n this.pessoaTomador.nomeFantasia = response.data.nome_fantasia\r\n ? response.data.nome_fantasia\r\n : \"\";\r\n if (response.data.endereco) {\r\n if (response.data.endereco.cep) {\r\n this.pessoaTomador.cep = response.data.endereco.cep;\r\n this.searchLocalidadePorCep();\r\n }\r\n this.pessoaTomador.numero = response.data.endereco.numero\r\n ? response.data.endereco.numero\r\n : \"\";\r\n this.pessoaTomador.complemento = response.data.endereco\r\n .complemento\r\n ? response.data.endereco.complemento\r\n : \"\";\r\n if (response.data.endereco.logradouro) {\r\n let endereco = response.data.endereco.logradouro.split(\" \");\r\n this.pessoaTomador.tipoLogradouro = endereco[0];\r\n this.pessoaTomador.logradouro =\r\n response.data.endereco.logradouro.replace(endereco[0], \"\");\r\n }\r\n if (response.data.endereco.bairro) {\r\n this.pessoaTomador.bairro = response.data.endereco.bairro;\r\n }\r\n }\r\n },\r\n (error) => {\r\n console.log(error);\r\n this.$root.$emit(\"alert:warn\", error.response.data);\r\n }\r\n )\r\n .then(() => {\r\n this.processando(false);\r\n });\r\n }\r\n },\r\n\r\n hideSelecaoContribuinte() {\r\n this.limparDadosTomador();\r\n this.showSelecaoContribuinte = false;\r\n },\r\n\r\n limparDadosTomador() {\r\n this.pessoaTomador = new Pessoa();\r\n this.selectedMunicipio = null;\r\n this.selectedPais = null;\r\n this.tipoCadastroContribuinte = null;\r\n this.erros = [];\r\n },\r\n\r\n processando(show) {\r\n if (show) {\r\n this.loading = true;\r\n this.$root.$emit(\"loading:show\");\r\n } else {\r\n this.loading = false;\r\n this.$root.$emit(\"loading:hide\");\r\n }\r\n },\r\n\r\n validarDocumento() {\r\n var validar = false;\r\n validar = Util.validarCPFCNPJ(this.pessoaTomador.documento);\r\n\r\n if (!validar) {\r\n console.log(validar);\r\n this.$root.$emit(\"alert:error\", \"CPF/CNPJ \" + this.pessoaTomador.documento + \" inválido!\");\r\n this.pessoaTomador.documento = null;\r\n }\r\n return validar;\r\n },\r\n },\r\n\r\n computed: {\r\n desabilitarEdicaoEconomico() {\r\n if (this.pessoaTomador && this.pessoaTomador.id) {\r\n return this.pessoaTomador.idContribuinte &&\r\n this.tipoCadastroContribuinte &&\r\n this.tipoCadastroContribuinte ==\r\n this.currentUser.configuracao.idContrTipoEconomico\r\n ? true\r\n : false;\r\n } else {\r\n return this.pessoaTomador && this.pessoaTomador.idContribuinte\r\n ? true\r\n : false;\r\n }\r\n },\r\n\r\n desabilitarEdicao() {\r\n return !!(this.pessoaTomador && this.pessoaTomador.idContribuintePai);\r\n },\r\n\r\n desabilitarPesquisaCpfCnpj() {\r\n return !!(\r\n (this.desabilitarEdicao || this.desabilitarEdicaoEconomico || this.tipoEmissaoInternal === \"EP\") &&\r\n this.pessoaTomador &&\r\n this.pessoaTomador.id !== \"\"\r\n );\r\n },\r\n\r\n habilitarEdicaoEnderecoPetrolina() { \r\n //093560/2024 - Petrolina: Liberar edição de endereço quando for PF; OU for PJ do Cadastro Econômico de fora do municipio.\r\n if (this.currentUser.usuario.idCliente === '3d6adeff-3f83-4033-8b16-3f5d42fccd1a') {\r\n const cepLocalidadeTomador = this.pessoaTomador.idCepLocalidade;\r\n const cepLocalidadeCliente = this.currentUser.configuracao.idCepLocalidadeCliente;\r\n const tipoCadastroContribuinte = this.tipoCadastroContribuinte;\r\n const tipoCadastroEconomico = this.currentUser.configuracao.idContrTipoEconomico;\r\n const tipoPessoa = this.selectedTipoTomador.key;\r\n\r\n return tipoPessoa === 'F' || (tipoCadastroContribuinte === tipoCadastroEconomico && cepLocalidadeTomador !== cepLocalidadeCliente);\r\n }\r\n return false;\r\n },\r\n\r\n mensagemEdicaoTomador() { \r\n if (this.habilitarEdicaoEnderecoPetrolina){\r\n return \"O contribuinte informado é do Tipo Econômico. Os dados não podem ser alterados, com exceção do endereço.\";\r\n } else {\r\n return \"O contribuinte informado é do Tipo Econômico. Os dados não podem ser alterados.\";\r\n }\r\n },\r\n\r\n nomeEstado() {\r\n return this.selectedMunicipio && this.selectedMunicipio.estado\r\n ? this.selectedMunicipio.estado.detail\r\n : \"\";\r\n },\r\n\r\n nomePais() {\r\n return this.selectedMunicipio &&\r\n this.selectedMunicipio.estado &&\r\n this.selectedMunicipio.estado.pais\r\n ? this.selectedMunicipio.estado.pais.detail\r\n : \"\";\r\n },\r\n\r\n headerDialog() {\r\n return (\r\n (this.pessoaTomador && this.pessoaTomador.id\r\n ? \"Edição de \"\r\n : \"Cadastro de \") +\r\n ((this.tipoEmissaoInternal == \"I\" ? 'Intermediário' : (this.tipoEmissaoInternal == \"T\" || this.tipoEmissaoInternal == \"EP\") ? \"Prestador\" : \"Tomador\"))\r\n );\r\n },\r\n }\r\n};\r\n</script>\r\n\r\n<style scoped>\r\n.scrolable-dialog {\r\n padding-right: 25px;\r\n width: 90vw;\r\n max-height: 65vh;\r\n overflow-y: auto;\r\n overflow-x: hidden;\r\n}\r\n\r\n.selecao-contribuinte {\r\n width: 80vw;\r\n}\r\n\r\n.mensagem-edicao {\r\n color: red;\r\n font-weight: bold;\r\n}\r\n</style>","import mod from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TomadorCadastro.vue?vue&type=script&lang=js&\"; export default mod; export * from \"-!../../node_modules/cache-loader/dist/cjs.js??ref--12-0!../../node_modules/thread-loader/dist/cjs.js!../../node_modules/babel-loader/lib/index.js!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader/lib/index.js??vue-loader-options!./TomadorCadastro.vue?vue&type=script&lang=js&\"","import { render, staticRenderFns } from \"./TomadorCadastro.vue?vue&type=template&id=218dddd2&scoped=true&\"\nimport script from \"./TomadorCadastro.vue?vue&type=script&lang=js&\"\nexport * from \"./TomadorCadastro.vue?vue&type=script&lang=js&\"\nimport style0 from \"./TomadorCadastro.vue?vue&type=style&index=0&id=218dddd2&scoped=true&lang=css&\"\n\n\n/* normalize component */\nimport normalizer from \"!../../node_modules/vue-loader/lib/runtime/componentNormalizer.js\"\nvar component = normalizer(\n script,\n render,\n staticRenderFns,\n false,\n null,\n \"218dddd2\",\n null\n \n)\n\nexport default component.exports","const money = {\r\n decimal: \",\",\r\n thousands: \".\",\r\n prefix: \"R$ \",\r\n suffix: \"\",\r\n precision: 2,\r\n masked: false\r\n}\r\nexport default money","import axios from 'axios';\r\nimport LoginService from '../acesso/login.service'\r\n\r\nconst API_URL = process.env.VUE_APP_BASE_URL + '/api/nfse/pessoa/';\r\n\r\nclass NfsPessoaService {\r\n constructor() {\r\n this.idContribuinte = null;\r\n this.idCliente =null\r\n LoginService.currentUser.subscribe(data => {\r\n this.headers = {\r\n 'Content-Type':'application/json',\r\n 'authorization':'Bearer ' + (data ? data.token:'')\r\n };\r\n });\r\n }\r\n\r\n findAllByConttribuinteFiltro(filtro, tipoTomador) {\r\n this.idContribuinte = LoginService.currentUserValue.contribuinte.idContribuinte;\r\n return axios.get(API_URL + 'filter?idContribuinte='+this.idContribuinte+'&filtro='+filtro+'&tipoPesquisa='+tipoTomador, {headers: this.headers}).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n findAllByConttribuinteFiltroDaps(filtro, tipoTomador, tipoEmissao) {\r\n this.idCliente = LoginService.currentUserValue.usuario.idCliente;\r\n this.idContribuinte = LoginService.currentUserValue.contribuinte.idContribuinte;\r\n return axios.get(API_URL + 'filterDaps?idCliente='+this.idCliente+'&idContribuinte='+this.idContribuinte+'&filtro='+filtro+'&tipoPesquisa='+tipoTomador+'&tipoEmissao='+tipoEmissao, {headers: this.headers}).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n \r\n findAllByConttribuinte(idContribuinte, filtro, tipoTomador, tipoEmissao) {\r\n this.idCliente = LoginService.currentUserValue.usuario.idCliente;\r\n return axios.get(API_URL + 'filterDaps?idCliente='+this.idCliente+'&idContribuinte='+idContribuinte+'&filtro='+filtro+'&tipoPesquisa='+tipoTomador+'&tipoEmissao='+tipoEmissao, {headers: this.headers}).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n save(pessoa) {\r\n console.log(pessoa);\r\n return axios.post(API_URL+'create', JSON.stringify(pessoa),\r\n {headers: this.headers});\r\n }\r\n\r\n remove(idPessoa){\r\n return axios.get(API_URL + 'remove?idPessoa=' + idPessoa, {headers: this.headers});\r\n }\r\n\r\n findById(idTomadorDados){\r\n this.idContribuinte = LoginService.currentUserValue.contribuinte.idContribuinte;\r\n return axios.get(API_URL + idTomadorDados, {headers: this.headers});\r\n }\r\n \r\n atualizaDadosPessoa(idPessoa){\r\n this.idCliente = LoginService.currentUserValue.usuario.idCliente;\r\n return axios.get(API_URL + 'atualizaDadosPessoa?idCliente=' + this.idCliente\r\n + '&idPessoa=' + idPessoa, {headers: this.headers});\r\n }\r\n\r\n atualizaDadosPessoaValidacao(idPessoa){\r\n this.idCliente = LoginService.currentUserValue.usuario.idCliente;\r\n let idTipoEconomico = LoginService.currentUserValue.configuracao.idContrTipoEconomico;\r\n let idTipoEventual = LoginService.currentUserValue.configuracao.idContrTipoEventual;\r\n return axios.get(API_URL + 'atualizaDadosPessoaValidacao?idCliente=' + this.idCliente\r\n + '&idPessoa=' + idPessoa+ '&idTipoEconomico=' + idTipoEconomico+ '&idTipoEventual=' + idTipoEventual, {headers: this.headers});\r\n }\r\n\r\n \r\n}\r\n\r\nexport default new NfsPessoaService();","import axios from 'axios';\r\nimport LoginService from '../acesso/login.service'\r\n\r\nconst API_URL = process.env.VUE_APP_BASE_URL + '/api/tributario/contribuintecadastro/';\r\n\r\nclass PessoaService {\r\n constructor() {\r\n this.idTipo = null;\r\n this.idConta = null;\r\n LoginService.currentUser.subscribe(data => {\r\n this.headers = {\r\n 'Content-Type': 'application/json',\r\n 'authorization': 'Bearer ' + (data ? data.token : '')\r\n };\r\n });\r\n }\r\n\r\n findAllByTipoCpfCnpj(cpfCnpj) {\r\n this.idTipo = LoginService.currentUserValue.configuracao.idContrTipoEconomico;\r\n this.idTipoEventual = LoginService.currentUserValue.configuracao.idContrTipoEventual;\r\n this.idConta = LoginService.currentUserValue.usuario.idConta;\r\n this.idCliente = LoginService.currentUserValue.usuario.idCliente;\r\n return axios.get(API_URL + 'filter?idCliente=' + this.idCliente + '&idTipoContr=' + this.idTipo + '&idTipoEventual=' + this.idTipoEventual + '&idConta=' + this.idConta + '&cpfCnpj=' + cpfCnpj, { headers: this.headers }).then(response => (this.data = response.data.elements));\r\n }\r\n\r\n findContatosContribuinte(idPessoa) {\r\n return axios.get(API_URL + 'contatosContribuinte?idPessoa=' + idPessoa, { headers: this.headers });\r\n }\r\n\r\n findTipoCadastroContribuinte(documento, inscMunic) {\r\n this.idCliente = LoginService.currentUserValue.usuario.idCliente;\r\n return axios.get(API_URL + 'tipoCadastroContribuinte?idCliente=' + this.idCliente + '&documento=' + documento + '&inscMunic=' + inscMunic, { headers: this.headers });\r\n }\r\n\r\n comboByContribuinteFiltro(idCliente, idContribuinte, filtro) {\r\n return axios.get(API_URL + 'comboByContribuinteFiltro?idCliente=' + idCliente + '&idContribuinte=' + idContribuinte + '&filtro=' + filtro, { headers: this.headers }).then(response => (this.data = response.data.elements));\r\n }\r\n}\r\n\r\nexport default new PessoaService();","import axios from 'axios';\r\nimport LoginService from '../acesso/login.service'\r\n\r\nconst API_URL = process.env.VUE_APP_BASE_URL + '/api/nfse/elserpro/';\r\n\r\nclass SessoaService {\r\n constructor() {\r\n this.idContribuinte = null;\r\n this.idCliente =null\r\n LoginService.currentUser.subscribe(data => {\r\n this.headers = {\r\n 'Content-Type':'application/json',\r\n 'authorization':'Bearer ' + (data ? data.token:'')\r\n };\r\n });\r\n }\r\n\r\n findByDocumento(idCliente, documento) {\r\n return axios.get(API_URL + 'filterDocSerpro?idCliente='+idCliente+'&documento='+documento, {headers: this.headers});\r\n }\r\n}\r\n\r\nexport default new SessoaService();","class Util {\r\n constructor() {}\r\n\r\n //Validar se um email é válido\r\n validarEmail (email) {\r\n // eslint-disable-next-line\r\n var re = /^(([^<>()\\[\\]\\\\.,;:\\s@\"]+(\\.[^<>()\\[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,}))$/;\r\n return re.test(email);\r\n }\r\n\r\n // validar CPF ou CNPJ\r\n validarCPFCNPJ(cpfCnpj) {\r\n if (!cpfCnpj) return false;\r\n cpfCnpj = cpfCnpj.replace(/[^\\d]+/g, \"\");\r\n var validado = false;\r\n\r\n if (cpfCnpj.length == 14) {\r\n validado = this.validarCNPJ(cpfCnpj);\r\n }\r\n else if (cpfCnpj.length == 11) {\r\n validado = this.validarCPF(cpfCnpj);\r\n }\r\n\r\n return validado;\r\n }\r\n\r\n // Validação de CNPJ\r\n validarCNPJ(cnpj) {\r\n if (!cnpj) return false;\r\n cnpj = cnpj.replace(/[^\\d]+/g, \"\");\r\n \r\n if (cnpj == \"\") return false;\r\n\r\n if (cnpj.length != 14) return false;\r\n\r\n // Elimina CNPJs invalidos conhecidos\r\n if (\r\n cnpj == \"00000000000000\" ||\r\n cnpj == \"11111111111111\" ||\r\n cnpj == \"22222222222222\" ||\r\n cnpj == \"33333333333333\" ||\r\n cnpj == \"44444444444444\" ||\r\n cnpj == \"55555555555555\" ||\r\n cnpj == \"66666666666666\" ||\r\n cnpj == \"77777777777777\" ||\r\n cnpj == \"88888888888888\" ||\r\n cnpj == \"99999999999999\"\r\n )\r\n return false;\r\n\r\n // Valida DVs\r\n var tamanho = cnpj.length - 2;\r\n var numeros = cnpj.substring(0, tamanho);\r\n var digitos = cnpj.substring(tamanho);\r\n var soma = 0;\r\n var pos = tamanho - 7;\r\n for (var i = tamanho; i >= 1; i--) {\r\n soma += numeros.charAt(tamanho - i) * pos--;\r\n if (pos < 2) pos = 9;\r\n }\r\n var resultado = soma % 11 < 2 ? 0 : 11 - (soma % 11);\r\n if (resultado != digitos.charAt(0)) return false;\r\n\r\n tamanho = tamanho + 1;\r\n numeros = cnpj.substring(0, tamanho);\r\n soma = 0;\r\n pos = tamanho - 7;\r\n for (i = tamanho; i >= 1; i--) {\r\n soma += numeros.charAt(tamanho - i) * pos--;\r\n if (pos < 2) pos = 9;\r\n }\r\n resultado = soma % 11 < 2 ? 0 : 11 - (soma % 11);\r\n if (resultado != digitos.charAt(1)) return false;\r\n\r\n return true;\r\n }\r\n\r\n // Validar CPF\r\n validarCPF(strCPF) {\r\n if (!strCPF) return false;\r\n var Soma;\r\n var Resto;\r\n Soma = 0;\r\n if (strCPF == \"00000000000\") return false;\r\n\r\n for (var i = 1; i <= 9; i++)\r\n Soma = Soma + parseInt(strCPF.substring(i - 1, i)) * (11 - i);\r\n Resto = (Soma * 10) % 11;\r\n\r\n if (Resto == 10 || Resto == 11) Resto = 0;\r\n if (Resto != parseInt(strCPF.substring(9, 10))) return false;\r\n\r\n Soma = 0;\r\n for (i = 1; i <= 10; i++)\r\n Soma = Soma + parseInt(strCPF.substring(i - 1, i)) * (12 - i);\r\n Resto = (Soma * 10) % 11;\r\n\r\n if (Resto == 10 || Resto == 11) Resto = 0;\r\n if (Resto != parseInt(strCPF.substring(10, 11))) return false;\r\n return true;\r\n }\r\n\r\n}\r\n\r\nexport default new Util();\r\n","import axios from 'axios';\r\nimport LoginService from '../acesso/login.service'\r\n\r\nconst API_URL = process.env.VUE_APP_BASE_URL + '/api/acesso/pais/';\r\n\r\nclass LocalidadeService {\r\n constructor() {\r\n LoginService.currentUser.subscribe(data => {\r\n this.headers = {\r\n 'Content-Type':'application/json',\r\n 'authorization':'Bearer ' + (data ? data.token:'')\r\n };\r\n });\r\n }\r\n\r\n findAllByFiltro(filtro) {\r\n return axios.get(API_URL + 'filter?filtro='+filtro, {headers: this.headers}).then(response => (this.data = response.data.elements));\r\n }\r\n \r\n}\r\n\r\nexport default new LocalidadeService();"],"sourceRoot":""}