A carregar, por favor aguarde ....
Nome: ' + this.formInscricao.value.nome + '
' + 'Email: ' + this.formInscricao.value.email + '
' + 'Telefone: ' + this.formInscricao.value.telefone + '
' + '' + this.formInscricao.value.mensagem + '
';\n modelo.mensagem = '' + this.formInscricao.value.mensagem + '
';\n this.comService.gravarMsgContacto(modelo).subscribe(res => {\n if (res.statusCode === 201){\n const msg = 'A sua mensagem foi enviada com sucesso!';\n this.notificarCliente(msg, 3000);\n this.resetState(msg, true);\n }\n\n this.estaProcessar = false;\n }, (error) => {\n this.notificarCliente('Falha ao enviar a mensagem, por favor tente mais tarde!', 3000);\n });\n }\n\n limparCampos(formulario: FormGroup): void {\n formulario.clearValidators();\n formulario.clearAsyncValidators();\n formulario.markAsUntouched({onlySelf: true});\n formulario.updateValueAndValidity({onlySelf: true});\n formulario.get('nome').reset();\n formulario.get('email').reset();\n formulario.get('telefone').reset();\n formulario.get('assunto').reset();\n formulario.get('mensagem').reset();\n }\n validarCampos(control, formulario: FormGroup): boolean {\n if (control !== 'email') {\n formulario.get(control).setValidators([Validators.required]);\n formulario.get(control).updateValueAndValidity();\n formulario.get(control).markAsTouched({onlySelf: true});\n }\n return;\n }\n\n fecharModal(): void {\n this.fechar.emit(false);\n }\n\n notificarCliente(msg: string, duracao?: number): any {\n this.btnTexto = msg;\n setTimeout(() => {\n this.btnTexto = 'Inscrever-se';\n this.spinner = false;\n }, duracao);\n }\n\n resetState(msg: any, sucesso: boolean): void {\n // this.statusMessage = msg;\n // this.loading = false;\n this.estaProcessar = false;\n setTimeout(() => {\n // this.statusMessage = null;\n if (sucesso) {this.limparCampos(this.formInscricao); }\n }, 3000);\n }\n\n}\n","© {{thisYear}}. Federação Angolana de Natação
\nDesenvolvido por \n KiamiSoft\n \n
\n