7vsdk-pessoas 1.0.25 → 1.0.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "7vsdk-pessoas",
3
- "version": "1.0.25",
3
+ "version": "1.0.26",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -6,6 +6,7 @@ import { EnderecoCidadeClient } from "../enderecos/EnderecoCidadeClient";
6
6
  export class EmpresaSdk extends CrudClientBase<EmpresaRequest, EmpresaResponse>
7
7
  {
8
8
  private pessoaUrl: string = "";
9
+ private token: string = "";
9
10
 
10
11
  private pessoaSdk: PessoaClient;
11
12
  private enderecoSdk: EnderecoCidadeClient
@@ -14,14 +15,19 @@ export class EmpresaSdk extends CrudClientBase<EmpresaRequest, EmpresaResponse>
14
15
  constructor(Url: string, tokenJwt: string)
15
16
  {
16
17
  super(Url, "portal-contador/empresa", tokenJwt);
17
- this.pessoaCnpj = new PessoaCnpjClient(this.pessoaUrl, tokenJwt);
18
- this.enderecoSdk = new EnderecoCidadeClient(this.pessoaUrl, tokenJwt);
19
- this.pessoaSdk = new PessoaClient(this.pessoaUrl, tokenJwt);
18
+ this.token = tokenJwt;
19
+ this.pessoaCnpj = new PessoaCnpjClient(this.pessoaUrl, this.token);
20
+ this.enderecoSdk = new EnderecoCidadeClient(this.pessoaUrl, this.token);
21
+ this.pessoaSdk = new PessoaClient(this.pessoaUrl, this.token);
20
22
  }
21
23
 
22
24
  setPessoaUrl(urlPessoa: string)
23
25
  {
24
26
  this.pessoaUrl = urlPessoa;
27
+
28
+ this.pessoaCnpj = new PessoaCnpjClient(this.pessoaUrl, this.token)
29
+ this.enderecoSdk = new EnderecoCidadeClient(this.pessoaUrl, this.token);
30
+ this.pessoaSdk = new PessoaClient(this.pessoaUrl, this.token);
25
31
  }
26
32
 
27
33
  async criarEmpresaRoot(cnpj: string, ie: string, regimeTributario: number, razaoSocial: string, lucroReal: boolean, industria: boolean): Promise<void>