flit-models 3.2.15 → 3.2.16

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.
@@ -0,0 +1,25 @@
1
+ import { EnumStatusHistoricoRelatorioPontoApp, HistoricoRelatorioPontoApp, HistoricoRelatorioPontoAppBase } from '.';
2
+ export declare class HistoricoRelatorioPontoAppElasticData implements HistoricoRelatorioPontoAppBase {
3
+ i_id: string;
4
+ i_path: string;
5
+ arquivo: {
6
+ assinado_path: string | null;
7
+ original_path: string;
8
+ original_hash_sha_256: string;
9
+ };
10
+ data_alteracao: any;
11
+ data_criacao: any;
12
+ data_referencia: any;
13
+ excluido: boolean;
14
+ filtro: {
15
+ data_final: any;
16
+ data_inicial: any;
17
+ modelo_relatorio_ref: any;
18
+ };
19
+ gestor_ref: any;
20
+ status: EnumStatusHistoricoRelatorioPontoApp;
21
+ usuario_ref: any;
22
+ }
23
+ export declare abstract class HistoricoRelatorioPontoAppElasticConvert {
24
+ static fromElastic({ i_id, i_path, usuario_ref, gestor_ref, arquivo, data_alteracao, data_criacao, data_referencia, excluido, filtro, status, }: HistoricoRelatorioPontoAppElasticData): HistoricoRelatorioPontoApp;
25
+ }
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+ var __assign = (this && this.__assign) || function () {
3
+ __assign = Object.assign || function(t) {
4
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
5
+ s = arguments[i];
6
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
7
+ t[p] = s[p];
8
+ }
9
+ return t;
10
+ };
11
+ return __assign.apply(this, arguments);
12
+ };
13
+ Object.defineProperty(exports, "__esModule", { value: true });
14
+ exports.HistoricoRelatorioPontoAppElasticConvert = exports.HistoricoRelatorioPontoAppElasticData = void 0;
15
+ var _1 = require(".");
16
+ var HistoricoRelatorioPontoAppElasticData = /** @class */ (function () {
17
+ function HistoricoRelatorioPontoAppElasticData() {
18
+ }
19
+ return HistoricoRelatorioPontoAppElasticData;
20
+ }());
21
+ exports.HistoricoRelatorioPontoAppElasticData = HistoricoRelatorioPontoAppElasticData;
22
+ var HistoricoRelatorioPontoAppElasticConvert = /** @class */ (function () {
23
+ function HistoricoRelatorioPontoAppElasticConvert() {
24
+ }
25
+ HistoricoRelatorioPontoAppElasticConvert.fromElastic = function (_a) {
26
+ var i_id = _a.i_id, i_path = _a.i_path, usuario_ref = _a.usuario_ref, gestor_ref = _a.gestor_ref, arquivo = _a.arquivo, data_alteracao = _a.data_alteracao, data_criacao = _a.data_criacao, data_referencia = _a.data_referencia, excluido = _a.excluido, filtro = _a.filtro, status = _a.status;
27
+ return new _1.HistoricoRelatorioPontoApp({
28
+ _id: i_id,
29
+ _path: i_path,
30
+ _usuario: __assign({}, usuario_ref),
31
+ _gestor: __assign({}, gestor_ref),
32
+ arquivo: arquivo,
33
+ data_alteracao: data_alteracao,
34
+ data_criacao: data_criacao,
35
+ data_referencia: data_referencia,
36
+ excluido: excluido,
37
+ filtro: filtro,
38
+ gestor_ref: gestor_ref.i_path,
39
+ status: status,
40
+ usuario_ref: usuario_ref.i_path,
41
+ });
42
+ };
43
+ return HistoricoRelatorioPontoAppElasticConvert;
44
+ }());
45
+ exports.HistoricoRelatorioPontoAppElasticConvert = HistoricoRelatorioPontoAppElasticConvert;
@@ -1,18 +1,16 @@
1
1
  import { EnumStatusHistoricoRelatorioPontoApp } from '..';
2
2
  export interface HistoricoRelatorioPontoAppLogBase {
3
3
  data: any;
4
- hash_arquivo: string;
4
+ app_info: any;
5
5
  ip_externo: string;
6
6
  tipo: Omit<EnumStatusHistoricoRelatorioPontoApp, 'PROCESSANDO' | 'ERRO'>;
7
- usuario_ref: any;
8
7
  }
9
8
  export declare class HistoricoRelatorioPontoAppLog implements HistoricoRelatorioPontoAppLogBase {
10
9
  _id: string;
11
10
  _path: string;
11
+ app_info: any;
12
12
  data: Date;
13
- hash_arquivo: string;
14
13
  ip_externo: string;
15
14
  tipo: Omit<EnumStatusHistoricoRelatorioPontoApp, 'PROCESSANDO' | 'ERRO'>;
16
- usuario_ref: string;
17
- constructor({ _id, _path, data, hash_arquivo, ip_externo, tipo, usuario_ref, }: HistoricoRelatorioPontoAppLog);
15
+ constructor({ _id, _path, data, ip_externo, tipo, }: HistoricoRelatorioPontoAppLog);
18
16
  }
@@ -3,14 +3,16 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.HistoricoRelatorioPontoAppLog = void 0;
4
4
  var HistoricoRelatorioPontoAppLog = /** @class */ (function () {
5
5
  function HistoricoRelatorioPontoAppLog(_a) {
6
- var _id = _a._id, _path = _a._path, data = _a.data, hash_arquivo = _a.hash_arquivo, ip_externo = _a.ip_externo, tipo = _a.tipo, usuario_ref = _a.usuario_ref;
6
+ var _id = _a._id, _path = _a._path, data = _a.data, ip_externo = _a.ip_externo, tipo = _a.tipo;
7
7
  this._id = _id !== null && _id !== void 0 ? _id : '';
8
8
  this._path = _path !== null && _path !== void 0 ? _path : '';
9
+ this.app_info = {
10
+ versao: '1.0.0',
11
+ plataforma: 'WEB',
12
+ };
9
13
  this.data = data !== null && data !== void 0 ? data : new Date();
10
- this.hash_arquivo = hash_arquivo !== null && hash_arquivo !== void 0 ? hash_arquivo : '';
11
14
  this.ip_externo = ip_externo !== null && ip_externo !== void 0 ? ip_externo : '';
12
15
  this.tipo = tipo !== null && tipo !== void 0 ? tipo : null;
13
- this.usuario_ref = usuario_ref !== null && usuario_ref !== void 0 ? usuario_ref : null;
14
16
  }
15
17
  return HistoricoRelatorioPontoAppLog;
16
18
  }());
@@ -10,6 +10,7 @@ export interface HistoricoRelatorioPontoAppBase {
10
10
  arquivo: {
11
11
  assinado_path: string | null;
12
12
  original_path: string;
13
+ original_hash_sha_256: string;
13
14
  };
14
15
  data_alteracao: any;
15
16
  data_criacao: any;
@@ -27,9 +28,12 @@ export interface HistoricoRelatorioPontoAppBase {
27
28
  export declare class HistoricoRelatorioPontoApp implements HistoricoRelatorioPontoAppBase {
28
29
  _id: string;
29
30
  _path: string;
31
+ _usuario?: any;
32
+ _gestor?: any;
30
33
  arquivo: {
31
34
  assinado_path: string | null;
32
35
  original_path: string;
36
+ original_hash_sha_256: string;
33
37
  };
34
38
  data_alteracao: Date;
35
39
  data_criacao: Date;
@@ -43,5 +47,5 @@ export declare class HistoricoRelatorioPontoApp implements HistoricoRelatorioPon
43
47
  gestor_ref: string;
44
48
  status: EnumStatusHistoricoRelatorioPontoApp;
45
49
  usuario_ref: string;
46
- constructor({ _id, _path, arquivo, data_alteracao, data_criacao, data_referencia, excluido, filtro, gestor_ref, status, usuario_ref, }: HistoricoRelatorioPontoApp);
50
+ constructor({ _id, _path, _usuario, _gestor, arquivo, data_alteracao, data_criacao, data_referencia, excluido, filtro, gestor_ref, status, usuario_ref, }: HistoricoRelatorioPontoApp);
47
51
  }
@@ -12,22 +12,25 @@ var EnumStatusHistoricoRelatorioPontoApp;
12
12
  })(EnumStatusHistoricoRelatorioPontoApp = exports.EnumStatusHistoricoRelatorioPontoApp || (exports.EnumStatusHistoricoRelatorioPontoApp = {}));
13
13
  var HistoricoRelatorioPontoApp = /** @class */ (function () {
14
14
  function HistoricoRelatorioPontoApp(_a) {
15
- var _id = _a._id, _path = _a._path, arquivo = _a.arquivo, data_alteracao = _a.data_alteracao, data_criacao = _a.data_criacao, data_referencia = _a.data_referencia, excluido = _a.excluido, filtro = _a.filtro, gestor_ref = _a.gestor_ref, status = _a.status, usuario_ref = _a.usuario_ref;
16
- var _b, _c, _d, _e, _f;
15
+ var _id = _a._id, _path = _a._path, _usuario = _a._usuario, _gestor = _a._gestor, arquivo = _a.arquivo, data_alteracao = _a.data_alteracao, data_criacao = _a.data_criacao, data_referencia = _a.data_referencia, excluido = _a.excluido, filtro = _a.filtro, gestor_ref = _a.gestor_ref, status = _a.status, usuario_ref = _a.usuario_ref;
16
+ var _b, _c, _d, _e, _f, _g;
17
17
  this._id = _id !== null && _id !== void 0 ? _id : '';
18
18
  this._path = _path !== null && _path !== void 0 ? _path : '';
19
+ this._usuario = _usuario !== null && _usuario !== void 0 ? _usuario : null;
20
+ this._gestor = _gestor !== null && _gestor !== void 0 ? _gestor : null;
19
21
  this.arquivo = {
20
22
  assinado_path: (_b = arquivo.assinado_path) !== null && _b !== void 0 ? _b : null,
21
23
  original_path: (_c = arquivo.original_path) !== null && _c !== void 0 ? _c : '',
24
+ original_hash_sha_256: (_d = arquivo.original_hash_sha_256) !== null && _d !== void 0 ? _d : '',
22
25
  };
23
26
  this.data_alteracao = data_alteracao !== null && data_alteracao !== void 0 ? data_alteracao : new Date();
24
27
  this.data_criacao = data_criacao !== null && data_criacao !== void 0 ? data_criacao : new Date();
25
28
  this.data_referencia = data_referencia !== null && data_referencia !== void 0 ? data_referencia : null;
26
29
  this.excluido = excluido !== null && excluido !== void 0 ? excluido : false;
27
30
  this.filtro = {
28
- data_final: (_d = filtro.data_final) !== null && _d !== void 0 ? _d : new Date(),
29
- data_inicial: (_e = filtro.data_inicial) !== null && _e !== void 0 ? _e : new Date(),
30
- modelo_relatorio_ref: (_f = filtro.modelo_relatorio_ref) !== null && _f !== void 0 ? _f : null,
31
+ data_final: (_e = filtro.data_final) !== null && _e !== void 0 ? _e : new Date(),
32
+ data_inicial: (_f = filtro.data_inicial) !== null && _f !== void 0 ? _f : new Date(),
33
+ modelo_relatorio_ref: (_g = filtro.modelo_relatorio_ref) !== null && _g !== void 0 ? _g : null,
31
34
  };
32
35
  this.gestor_ref = gestor_ref !== null && gestor_ref !== void 0 ? gestor_ref : null;
33
36
  this.status = status !== null && status !== void 0 ? status : null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flit-models",
3
- "version": "3.2.15",
3
+ "version": "3.2.16",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",