exodus-framework 2.0.769 → 2.0.771

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.
@@ -1 +1 @@
1
- {"version":3,"file":"access.d.ts","sourceRoot":"","sources":["../../src/middlewares/access.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAEzC,OAAO,cAAc,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAM5C,cAAM,gBAAiB,SAAQ,cAAc;IAC3C,WAAW,UAAW,YAAY,EAAE,KAAG,cAAc,CAWnD;IAEF,SAAS,EAAE,cAAc,CAqEvB;CACH;AAED,eAAe,gBAAgB,CAAC"}
1
+ {"version":3,"file":"access.d.ts","sourceRoot":"","sources":["../../src/middlewares/access.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAEzC,OAAO,cAAc,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAM5C,cAAM,gBAAiB,SAAQ,cAAc;IAC3C,WAAW,UAAW,YAAY,EAAE,KAAG,cAAc,CAWnD;IAEF,SAAS,EAAE,cAAc,CAwEvB;CACH;AAED,eAAe,gBAAgB,CAAC"}
@@ -27,6 +27,7 @@ class AccessMiddleware extends _controller.default {
27
27
  const account = req.auth?.account;
28
28
  const tenantId = req.header('X-Exodus-Tenant-ID');
29
29
  const applicationId = req.header('X-Exodus-Application-ID');
30
+ let isApplication = false;
30
31
  const requestor = {
31
32
  database: '',
32
33
  id: account?.uuid,
@@ -38,6 +39,7 @@ class AccessMiddleware extends _controller.default {
38
39
 
39
40
  /* Aplicações */
40
41
  if (applicationId) {
42
+ isApplication = true;
41
43
  const application = await _models.Application.findOne({
42
44
  where: {
43
45
  token: applicationId
@@ -85,6 +87,7 @@ class AccessMiddleware extends _controller.default {
85
87
  id: envUuid || _app.Core.settings.getDatabase().service.database
86
88
  };
87
89
  req.requestor = requestor;
90
+ req.isApplication = isApplication;
88
91
  next();
89
92
  };
90
93
  }
@@ -7,6 +7,7 @@ export declare class Log extends Model<InferAttributes<Log>, InferCreationAttrib
7
7
  action: string;
8
8
  comments: string;
9
9
  data: CreationOptional<Record<string, any>>;
10
+ params: CreationOptional<Record<string, any>>;
10
11
  static initialize(connection: Sequelize): import("sequelize").ModelCtor<Log>;
11
12
  }
12
13
  //# sourceMappingURL=Log.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Log.d.ts","sourceRoot":"","sources":["../../src/models/Log.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,gBAAgB,EAEhB,eAAe,EACf,uBAAuB,EAEvB,KAAK,EAGL,SAAS,EACV,MAAM,WAAW,CAAC;AAInB,qBAAa,GAAI,SAAQ,KAAK,CAAC,eAAe,CAAC,GAAG,CAAC,EAAE,uBAAuB,CAAC,GAAG,CAAC,CAAC;IACxE,IAAI,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAC/B,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,gBAAgB,CAAC,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,CAAC;IAEpD,MAAM,CAAC,UAAU,CAAC,UAAU,EAAE,SAAS;CAGxC"}
1
+ {"version":3,"file":"Log.d.ts","sourceRoot":"","sources":["../../src/models/Log.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,gBAAgB,EAEhB,eAAe,EACf,uBAAuB,EAEvB,KAAK,EAGL,SAAS,EACV,MAAM,WAAW,CAAC;AAInB,qBAAa,GAAI,SAAQ,KAAK,CAAC,eAAe,CAAC,GAAG,CAAC,EAAE,uBAAuB,CAAC,GAAG,CAAC,CAAC;IACxE,IAAI,EAAE,gBAAgB,CAAC,MAAM,CAAC,CAAC;IAC/B,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;IACf,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,gBAAgB,CAAC,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,CAAC;IAC5C,MAAM,EAAE,gBAAgB,CAAC,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC,CAAC;IAEtD,MAAM,CAAC,UAAU,CAAC,UAAU,EAAE,SAAS;CAGxC"}
package/lib/models/Log.js CHANGED
@@ -44,6 +44,11 @@ const LogParams = {
44
44
  type: _sequelize.DataTypes.JSON,
45
45
  defaultValue: {},
46
46
  allowNull: true
47
+ },
48
+ params: {
49
+ type: _sequelize.DataTypes.JSON,
50
+ defaultValue: {},
51
+ allowNull: true
47
52
  }
48
53
  };
49
54
  const LogConnParams = {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "exodus-framework",
3
- "version": "2.0.769",
3
+ "version": "2.0.771",
4
4
  "description": "Exodus Framework",
5
5
  "author": "jhownpaixao",
6
6
  "license": "ISC",