chyz 2.0.1-rc.3 → 2.0.1-rc.37
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/{BaseChyz.d.ts.map → dist/BaseChyz.d.ts.map} +1 -1
- package/{BaseChyz.js → dist/BaseChyz.js} +77 -60
- package/{README.md → dist/README.md} +518 -518
- package/{base → dist/base}/ActionFilter.d.ts +0 -1
- package/dist/base/ActionFilter.d.ts.map +1 -0
- package/{base → dist/base}/ActionFilter.js +2 -2
- package/{base → dist/base}/CEvents.js +1 -1
- package/{base → dist/base}/Model.js +6 -6
- package/{base → dist/base}/RestClient.js +2 -2
- package/{decorator → dist/decorator}/Middleware.js +1 -2
- package/{decorator → dist/decorator}/controller.d.ts.map +1 -1
- package/{decorator → dist/decorator}/delete.d.ts.map +1 -1
- package/{decorator → dist/decorator}/enums/ControllerDecoratorParams.js +1 -1
- package/{decorator → dist/decorator}/get.d.ts.map +1 -1
- package/{decorator → dist/decorator}/post.d.ts.map +1 -1
- package/{decorator → dist/decorator}/put.d.ts.map +1 -1
- package/{filters → dist/filters}/AccessControl.d.ts +0 -1
- package/dist/filters/AccessControl.d.ts.map +1 -0
- package/{filters → dist/filters}/AccessControl.js +1 -1
- package/{filters → dist/filters}/auth/AuthMethod.js +1 -1
- package/{filters → dist/filters}/auth/HttpBasicAuth.js +3 -2
- package/{filters → dist/filters}/auth/JwtHttpBearerAuth.js +3 -2
- package/{index.d.ts.map → dist/index.d.ts.map} +1 -1
- package/{index.js → dist/index.js} +1 -0
- package/{log → dist/log}/config/log4js.json +55 -55
- package/dist/log/log/config/log4js.json +55 -0
- package/dist/package.json +63 -0
- package/{rbac → dist/rbac}/AuthManager.js +3 -3
- package/{web → dist/web}/WebUser.js +4 -4
- package/package.json +23 -61
- package/base/ActionFilter.d.ts.map +0 -1
- package/filters/AccessControl.d.ts.map +0 -1
- package/{BaseChyz.d.ts → dist/BaseChyz.d.ts} +0 -0
- package/{base → dist/base}/BadRequestHttpException.d.ts +0 -0
- package/{base → dist/base}/BadRequestHttpException.d.ts.map +0 -0
- package/{base → dist/base}/BadRequestHttpException.js +0 -0
- package/{base → dist/base}/BaseError.d.ts +0 -0
- package/{base → dist/base}/BaseError.d.ts.map +0 -0
- package/{base → dist/base}/BaseError.js +0 -0
- package/{base → dist/base}/Behavior.d.ts +0 -0
- package/{base → dist/base}/Behavior.d.ts.map +0 -0
- package/{base → dist/base}/Behavior.js +0 -0
- package/{base → dist/base}/CBaseObject.d.ts +0 -0
- package/{base → dist/base}/CBaseObject.d.ts.map +0 -0
- package/{base → dist/base}/CBaseObject.js +0 -0
- package/{base → dist/base}/CEvents.d.ts +0 -0
- package/{base → dist/base}/CEvents.d.ts.map +0 -0
- package/{base → dist/base}/CRequest.d.ts +0 -0
- package/{base → dist/base}/CRequest.d.ts.map +0 -0
- package/{base → dist/base}/CRequest.js +0 -0
- package/{base → dist/base}/CWebController.d.ts +0 -0
- package/{base → dist/base}/CWebController.d.ts.map +0 -0
- package/{base → dist/base}/CWebController.js +0 -0
- package/{base → dist/base}/Component.d.ts +0 -0
- package/{base → dist/base}/Component.d.ts.map +0 -0
- package/{base → dist/base}/Component.js +0 -0
- package/{base → dist/base}/Configurable.d.ts +0 -0
- package/{base → dist/base}/Configurable.d.ts.map +0 -0
- package/{base → dist/base}/Configurable.js +0 -0
- package/{base → dist/base}/DataErrorDbException.d.ts +0 -0
- package/{base → dist/base}/DataErrorDbException.d.ts.map +0 -0
- package/{base → dist/base}/DataErrorDbException.js +0 -0
- package/{base → dist/base}/DbConnection.d.ts +0 -0
- package/{base → dist/base}/DbConnection.d.ts.map +0 -0
- package/{base → dist/base}/DbConnection.js +0 -0
- package/{base → dist/base}/ForbiddenHttpException.d.ts +0 -0
- package/{base → dist/base}/ForbiddenHttpException.d.ts.map +0 -0
- package/{base → dist/base}/ForbiddenHttpException.js +0 -0
- package/{base → dist/base}/InvalidArgumentException.d.ts +0 -0
- package/{base → dist/base}/InvalidArgumentException.d.ts.map +0 -0
- package/{base → dist/base}/InvalidArgumentException.js +0 -0
- package/{base → dist/base}/InvalidConfigException.d.ts +0 -0
- package/{base → dist/base}/InvalidConfigException.d.ts.map +0 -0
- package/{base → dist/base}/InvalidConfigException.js +0 -0
- package/{base → dist/base}/Logs.d.ts +0 -0
- package/{base → dist/base}/Logs.d.ts.map +0 -0
- package/{base → dist/base}/Logs.js +0 -0
- package/{base → dist/base}/Model.d.ts +0 -0
- package/{base → dist/base}/Model.d.ts.map +0 -0
- package/{base → dist/base}/ModelManager.d.ts +0 -0
- package/{base → dist/base}/ModelManager.d.ts.map +0 -0
- package/{base → dist/base}/ModelManager.js +0 -0
- package/{base → dist/base}/NotFoundHttpException.d.ts +0 -0
- package/{base → dist/base}/NotFoundHttpException.d.ts.map +0 -0
- package/{base → dist/base}/NotFoundHttpException.js +0 -0
- package/{base → dist/base}/RestClient.d.ts +0 -0
- package/{base → dist/base}/RestClient.d.ts.map +0 -0
- package/{base → dist/base}/UnauthorizedHttpException.d.ts +0 -0
- package/{base → dist/base}/UnauthorizedHttpException.d.ts.map +0 -0
- package/{base → dist/base}/UnauthorizedHttpException.js +0 -0
- package/{base → dist/base}/ValidationHttpException.d.ts +0 -0
- package/{base → dist/base}/ValidationHttpException.d.ts.map +0 -0
- package/{base → dist/base}/ValidationHttpException.js +0 -0
- package/{base → dist/base}/db/Exception.d.ts +0 -0
- package/{base → dist/base}/db/Exception.d.ts.map +0 -0
- package/{base → dist/base}/db/Exception.js +0 -0
- package/{base → dist/base}/index.d.ts +0 -0
- package/{base → dist/base}/index.d.ts.map +0 -0
- package/{base → dist/base}/index.js +0 -0
- package/{decorator → dist/decorator}/Middleware.d.ts +0 -0
- package/{decorator → dist/decorator}/Middleware.d.ts.map +0 -0
- package/{decorator → dist/decorator}/controller.d.ts +0 -0
- package/{decorator → dist/decorator}/controller.js +0 -0
- package/{decorator → dist/decorator}/delete.d.ts +0 -0
- package/{decorator → dist/decorator}/delete.js +0 -0
- package/{decorator → dist/decorator}/enums/ControllerDecoratorParams.d.ts +0 -0
- package/{decorator → dist/decorator}/enums/ControllerDecoratorParams.d.ts.map +0 -0
- package/{decorator → dist/decorator}/get.d.ts +0 -0
- package/{decorator → dist/decorator}/get.js +0 -0
- package/{decorator → dist/decorator}/index.d.ts +0 -0
- package/{decorator → dist/decorator}/index.d.ts.map +0 -0
- package/{decorator → dist/decorator}/index.js +0 -0
- package/{decorator → dist/decorator}/post.d.ts +0 -0
- package/{decorator → dist/decorator}/post.js +0 -0
- package/{decorator → dist/decorator}/put.d.ts +0 -0
- package/{decorator → dist/decorator}/put.js +0 -0
- package/{filters → dist/filters}/AccessRule.d.ts +0 -0
- package/{filters → dist/filters}/AccessRule.d.ts.map +0 -0
- package/{filters → dist/filters}/AccessRule.js +0 -0
- package/{filters → dist/filters}/auth/AuthInterface.d.ts +0 -0
- package/{filters → dist/filters}/auth/AuthInterface.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/AuthInterface.js +0 -0
- package/{filters → dist/filters}/auth/AuthMethod.d.ts +0 -0
- package/{filters → dist/filters}/auth/AuthMethod.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/HttpBasicAuth.d.ts +0 -0
- package/{filters → dist/filters}/auth/HttpBasicAuth.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/HttpBearerAuth.d.ts +0 -0
- package/{filters → dist/filters}/auth/HttpBearerAuth.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/HttpBearerAuth.js +0 -0
- package/{filters → dist/filters}/auth/HttpHeaderAuth.d.ts +0 -0
- package/{filters → dist/filters}/auth/HttpHeaderAuth.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/HttpHeaderAuth.js +0 -0
- package/{filters → dist/filters}/auth/JwtHttpBearerAuth.d.ts +0 -0
- package/{filters → dist/filters}/auth/JwtHttpBearerAuth.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/KeyCloakHttpBearerAuth.d.ts +0 -0
- package/{filters → dist/filters}/auth/KeyCloakHttpBearerAuth.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/KeyCloakHttpBearerAuth.js +0 -0
- package/{filters → dist/filters}/auth/index.d.ts +0 -0
- package/{filters → dist/filters}/auth/index.d.ts.map +0 -0
- package/{filters → dist/filters}/auth/index.js +0 -0
- package/{filters → dist/filters}/index.d.ts +0 -0
- package/{filters → dist/filters}/index.d.ts.map +0 -0
- package/{filters → dist/filters}/index.js +0 -0
- package/{index.d.ts → dist/index.d.ts} +0 -0
- package/{model → dist/model}/RouteDefinition.d.ts +0 -0
- package/{model → dist/model}/RouteDefinition.d.ts.map +0 -0
- package/{model → dist/model}/RouteDefinition.js +0 -0
- package/{rbac → dist/rbac}/AuthAssignment.d.ts +0 -0
- package/{rbac → dist/rbac}/AuthAssignment.d.ts.map +0 -0
- package/{rbac → dist/rbac}/AuthAssignment.js +0 -0
- package/{rbac → dist/rbac}/AuthItem.d.ts +0 -0
- package/{rbac → dist/rbac}/AuthItem.d.ts.map +0 -0
- package/{rbac → dist/rbac}/AuthItem.js +0 -0
- package/{rbac → dist/rbac}/AuthItemChild.d.ts +0 -0
- package/{rbac → dist/rbac}/AuthItemChild.d.ts.map +0 -0
- package/{rbac → dist/rbac}/AuthItemChild.js +0 -0
- package/{rbac → dist/rbac}/AuthManager.d.ts +0 -0
- package/{rbac → dist/rbac}/AuthManager.d.ts.map +0 -0
- package/{rbac → dist/rbac}/index.d.ts +0 -0
- package/{rbac → dist/rbac}/index.d.ts.map +0 -0
- package/{rbac → dist/rbac}/index.js +0 -0
- package/{requiments → dist/requiments}/Glob.d.ts +0 -0
- package/{requiments → dist/requiments}/Glob.d.ts.map +0 -0
- package/{requiments → dist/requiments}/Glob.js +0 -0
- package/{requiments → dist/requiments}/ReflectUtil.d.ts +0 -0
- package/{requiments → dist/requiments}/ReflectUtil.d.ts.map +0 -0
- package/{requiments → dist/requiments}/ReflectUtil.js +0 -0
- package/{requiments → dist/requiments}/Utils.d.ts +0 -0
- package/{requiments → dist/requiments}/Utils.d.ts.map +0 -0
- package/{requiments → dist/requiments}/Utils.js +0 -0
- package/{validators → dist/validators}/BooleanValidator.d.ts +0 -0
- package/{validators → dist/validators}/BooleanValidator.d.ts.map +0 -0
- package/{validators → dist/validators}/BooleanValidator.js +0 -0
- package/{validators → dist/validators}/CompareValidator.d.ts +0 -0
- package/{validators → dist/validators}/CompareValidator.d.ts.map +0 -0
- package/{validators → dist/validators}/CompareValidator.js +0 -0
- package/{validators → dist/validators}/DateValidator.d.ts +0 -0
- package/{validators → dist/validators}/DateValidator.d.ts.map +0 -0
- package/{validators → dist/validators}/DateValidator.js +0 -0
- package/{validators → dist/validators}/EmailValidator.d.ts +0 -0
- package/{validators → dist/validators}/EmailValidator.d.ts.map +0 -0
- package/{validators → dist/validators}/EmailValidator.js +0 -0
- package/{validators → dist/validators}/Validator.d.ts +0 -0
- package/{validators → dist/validators}/Validator.d.ts.map +0 -0
- package/{validators → dist/validators}/Validator.js +1 -1
- /package/{web → dist/web}/IdentityInterface.d.ts +0 -0
- /package/{web → dist/web}/IdentityInterface.d.ts.map +0 -0
- /package/{web → dist/web}/IdentityInterface.js +0 -0
- /package/{web → dist/web}/WebUser.d.ts +0 -0
- /package/{web → dist/web}/WebUser.d.ts.map +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionFilter.d.ts","sourceRoot":"","sources":["../../src/base/ActionFilter.ts"],"names":[],"mappings":"AAMA,OAAO,EAAC,OAAO,EAAE,QAAQ,EAAC,MAAM,UAAU,CAAC;AAE3C,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAA;AAGzC,qBAAa,YAAa,SAAQ,WAAW;IAElC,IAAI,EAAE,GAAG,CAAC;IAEjB;;;OAGG;IACI,MAAM,UAAM;IAGZ,IAAI;IAIX;;;;;OAKG;IACU,YAAY,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ;IAUjE;;;;;OAKG;IACU,YAAY,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ;IAIjE;;;;OAIG;IACH,SAAS,CAAC,QAAQ,CAAC,MAAM,EAAE,GAAG;CA8BjC"}
|
|
@@ -35,7 +35,7 @@ class ActionFilter extends CBaseObject_1.CBaseObject {
|
|
|
35
35
|
*/
|
|
36
36
|
beforeFilter(route, req, res) {
|
|
37
37
|
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
-
BaseChyz_1.default.debug("Controller->beforeFilter ", route);
|
|
38
|
+
BaseChyz_1.default.debug("Controller->ActionFilter->beforeFilter ", JSON.stringify(route));
|
|
39
39
|
if (!this.isActive(route)) {
|
|
40
40
|
return;
|
|
41
41
|
}
|
|
@@ -79,7 +79,7 @@ class ActionFilter extends CBaseObject_1.CBaseObject {
|
|
|
79
79
|
let reg = new RegExp(`${pattern}$`, "g");
|
|
80
80
|
let match = id.match(reg);
|
|
81
81
|
// let match = id.startsWith(pattern);
|
|
82
|
-
|
|
82
|
+
BaseChyz_1.default.debug("Controller->ActionFilter->isActive ", "id:", id, "patern:", pattern, "match:", match, JSON.stringify(this.except));
|
|
83
83
|
if (match && match.length > 0) {
|
|
84
84
|
exceptMatch = true;
|
|
85
85
|
}
|
|
@@ -21,4 +21,4 @@ var CEvents;
|
|
|
21
21
|
CEvents["ON_AFTER_ACTION"] = "onafteraction";
|
|
22
22
|
CEvents["ON_DB_CONNECTION"] = "ondbconnection";
|
|
23
23
|
CEvents["ON_DB_DISCONNECT"] = "ondbdisconnect";
|
|
24
|
-
})(CEvents
|
|
24
|
+
})(CEvents || (exports.CEvents = CEvents = {}));
|
|
@@ -217,8 +217,8 @@ class Model extends Component_1.Component {
|
|
|
217
217
|
model() {
|
|
218
218
|
return this._model;
|
|
219
219
|
}
|
|
220
|
-
save(
|
|
221
|
-
return __awaiter(this,
|
|
220
|
+
save() {
|
|
221
|
+
return __awaiter(this, arguments, void 0, function* (params = {}, options = {}) {
|
|
222
222
|
this.errors = {};
|
|
223
223
|
// now instantiate an object
|
|
224
224
|
let p = Object.assign(params, this._attributes);
|
|
@@ -251,8 +251,8 @@ class Model extends Component_1.Component {
|
|
|
251
251
|
return result;
|
|
252
252
|
});
|
|
253
253
|
}
|
|
254
|
-
bulkCreate(
|
|
255
|
-
return __awaiter(this,
|
|
254
|
+
bulkCreate() {
|
|
255
|
+
return __awaiter(this, arguments, void 0, function* (params = {}, options = {}) {
|
|
256
256
|
this.errors = {};
|
|
257
257
|
// now instantiate an object
|
|
258
258
|
let p = Object.assign(params, this._attributes);
|
|
@@ -459,8 +459,8 @@ class Model extends Component_1.Component {
|
|
|
459
459
|
* @param query
|
|
460
460
|
* @param options
|
|
461
461
|
*/
|
|
462
|
-
rawQuery(
|
|
463
|
-
return __awaiter(this,
|
|
462
|
+
rawQuery(query_1) {
|
|
463
|
+
return __awaiter(this, arguments, void 0, function* (query, options = { type: sequelize_1.QueryTypes.SELECT, nest: true }) {
|
|
464
464
|
this.errors = {};
|
|
465
465
|
return yield this.model().query(query, options);
|
|
466
466
|
});
|
|
@@ -13,10 +13,10 @@ const Component_1 = require("./Component");
|
|
|
13
13
|
const axios = require('axios');
|
|
14
14
|
class RestClient extends Component_1.Component {
|
|
15
15
|
post(url, args, headers) {
|
|
16
|
-
return axios.post(url, args, headers);
|
|
16
|
+
return axios.post(url, Object.assign(Object.assign({}, args), { headers: headers }));
|
|
17
17
|
}
|
|
18
18
|
get(url, args, headers) {
|
|
19
|
-
return axios.get(url, args, headers);
|
|
19
|
+
return axios.get(url, Object.assign(Object.assign({}, args), { headers: headers }));
|
|
20
20
|
}
|
|
21
21
|
Rest(params) {
|
|
22
22
|
return axios(params);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Middleware =
|
|
3
|
+
exports.Middleware = Middleware;
|
|
4
4
|
require("reflect-metadata");
|
|
5
5
|
const ControllerDecoratorParams_1 = require("./enums/ControllerDecoratorParams");
|
|
6
6
|
function Middleware(middlewares) {
|
|
@@ -8,4 +8,3 @@ function Middleware(middlewares) {
|
|
|
8
8
|
Reflect.defineMetadata(ControllerDecoratorParams_1.ControllerDecoratorParams.Middleware, middlewares, target, propertyKey);
|
|
9
9
|
};
|
|
10
10
|
}
|
|
11
|
-
exports.Middleware = Middleware;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"controller.d.ts","sourceRoot":"","sources":["../../src/decorator/controller.ts"],"names":[],"mappings":"AAQA,OAAQ,kBAAkB,CAAC;AAC3B,eAAO,MAAM,UAAU,
|
|
1
|
+
{"version":3,"file":"controller.d.ts","sourceRoot":"","sources":["../../src/decorator/controller.ts"],"names":[],"mappings":"AAQA,OAAQ,kBAAkB,CAAC;AAC3B,eAAO,MAAM,UAAU,GAAI,SAAQ,MAAW,KAAG,cAYhD,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"delete.d.ts","sourceRoot":"","sources":["../../src/decorator/delete.ts"],"names":[],"mappings":"AAOA,OAAQ,kBAAkB,CAAC;AAG3B,eAAO,MAAM,GAAG,
|
|
1
|
+
{"version":3,"file":"delete.d.ts","sourceRoot":"","sources":["../../src/decorator/delete.ts"],"names":[],"mappings":"AAOA,OAAQ,kBAAkB,CAAC;AAG3B,eAAO,MAAM,GAAG,GAAI,MAAM,MAAM,KAAG,eAyBlC,CAAC"}
|
|
@@ -6,4 +6,4 @@ var ControllerDecoratorParams;
|
|
|
6
6
|
ControllerDecoratorParams["Path"] = "path";
|
|
7
7
|
ControllerDecoratorParams["Method"] = "method";
|
|
8
8
|
ControllerDecoratorParams["Middleware"] = "middleware";
|
|
9
|
-
})(ControllerDecoratorParams
|
|
9
|
+
})(ControllerDecoratorParams || (exports.ControllerDecoratorParams = ControllerDecoratorParams = {}));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../src/decorator/get.ts"],"names":[],"mappings":"AAOA,OAAO,kBAAkB,CAAC;AAG1B,eAAO,MAAM,GAAG,
|
|
1
|
+
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../src/decorator/get.ts"],"names":[],"mappings":"AAOA,OAAO,kBAAkB,CAAC;AAG1B,eAAO,MAAM,GAAG,GAAI,MAAM,MAAM,KAAG,eA0BlC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"post.d.ts","sourceRoot":"","sources":["../../src/decorator/post.ts"],"names":[],"mappings":"AAOA,OAAQ,kBAAkB,CAAC;AAG3B,eAAO,MAAM,IAAI,
|
|
1
|
+
{"version":3,"file":"post.d.ts","sourceRoot":"","sources":["../../src/decorator/post.ts"],"names":[],"mappings":"AAOA,OAAQ,kBAAkB,CAAC;AAG3B,eAAO,MAAM,IAAI,GAAI,MAAM,MAAM,KAAG,eAyBnC,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"put.d.ts","sourceRoot":"","sources":["../../src/decorator/put.ts"],"names":[],"mappings":"AAOA,OAAQ,kBAAkB,CAAC;AAG3B,eAAO,MAAM,GAAG,
|
|
1
|
+
{"version":3,"file":"put.d.ts","sourceRoot":"","sources":["../../src/decorator/put.ts"],"names":[],"mappings":"AAOA,OAAQ,kBAAkB,CAAC;AAG3B,eAAO,MAAM,GAAG,GAAI,MAAM,MAAM,KAAG,eAyBlC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AccessControl.d.ts","sourceRoot":"","sources":["../../src/filters/AccessControl.ts"],"names":[],"mappings":"AAMA,OAAO,EAAC,OAAO,EAAC,QAAQ,EAAU,MAAM,UAAU,CAAC;AAEnD,OAAO,EAAC,YAAY,EAAC,MAAM,SAAS,CAAC;AAErC,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AAIvC,qBAAa,aAAc,SAAQ,YAAY;IAEpC,IAAI,EAAE,GAAG,CAAQ;IACjB,KAAK,EAAE,GAAG,CAAC;IACX,YAAY,EAAE,GAAG,CAAQ;IAEzB,IAAI;IAgBE,YAAY,CAAC,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,OAAO,EAAC,GAAG,EAAC,QAAQ;IA+B7D,UAAU,CAAC,IAAI,EAAE,OAAO;CAMlC"}
|
|
@@ -41,8 +41,8 @@ class AccessControl extends base_2.ActionFilter {
|
|
|
41
41
|
});
|
|
42
42
|
}
|
|
43
43
|
beforeAction(action, request, res) {
|
|
44
|
-
var _a, _b;
|
|
45
44
|
return __awaiter(this, void 0, void 0, function* () {
|
|
45
|
+
var _a, _b;
|
|
46
46
|
let allow;
|
|
47
47
|
// @ts-ignore
|
|
48
48
|
let user = (_a = request.user) !== null && _a !== void 0 ? _a : this.user;
|
|
@@ -31,8 +31,8 @@ class AuthMethod extends base_1.ActionFilter {
|
|
|
31
31
|
* @param response
|
|
32
32
|
*/
|
|
33
33
|
beforeAction(action, request, response) {
|
|
34
|
-
var _a;
|
|
35
34
|
return __awaiter(this, void 0, void 0, function* () {
|
|
35
|
+
var _a;
|
|
36
36
|
let identity = yield this.authenticate((_a = this.user) !== null && _a !== void 0 ? _a : new WebUser_1.WebUser(), request, response);
|
|
37
37
|
// @ts-ignore
|
|
38
38
|
request.identity = identity;
|
|
@@ -47,7 +47,8 @@ class HttpBasicAuth extends AuthMethod_1.AuthMethod {
|
|
|
47
47
|
this.user = (_a = BaseChyz_1.default.getComponent("user")) !== null && _a !== void 0 ? _a : null;
|
|
48
48
|
}
|
|
49
49
|
authenticate(user, request, response) {
|
|
50
|
-
|
|
50
|
+
var arguments_1 = arguments;
|
|
51
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
51
52
|
let autHeader = this.getHeaderByKey(request.headers, this.header);
|
|
52
53
|
if (autHeader == null || (autHeader = this.patternCheck(autHeader, this.pattern)) == null) {
|
|
53
54
|
return this.fail(response);
|
|
@@ -57,7 +58,7 @@ class HttpBasicAuth extends AuthMethod_1.AuthMethod {
|
|
|
57
58
|
let buff = new Buffer(autHeader[1], "base64");
|
|
58
59
|
let basicauth = buff.toString().split(":");
|
|
59
60
|
if (this.auth != null) {
|
|
60
|
-
identity = yield this.auth(autHeader[1], ...
|
|
61
|
+
identity = yield this.auth(autHeader[1], ...arguments_1, basicauth);
|
|
61
62
|
}
|
|
62
63
|
else {
|
|
63
64
|
identity = yield user.loginByAccessToken(basicauth, "HttpBasicAuth");
|
|
@@ -45,7 +45,8 @@ class JwtHttpBearerAuth extends HttpBearerAuth_1.HttpBearerAuth {
|
|
|
45
45
|
this.user = (_a = BaseChyz_1.default.getComponent("user")) !== null && _a !== void 0 ? _a : null;
|
|
46
46
|
}
|
|
47
47
|
authenticate(user, request, response) {
|
|
48
|
-
|
|
48
|
+
var arguments_1 = arguments;
|
|
49
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
49
50
|
let autHeader = this.getHeaderByKey(request.headers, this.header);
|
|
50
51
|
if (autHeader == null || (autHeader = this.patternCheck(autHeader, this.pattern)) == null) {
|
|
51
52
|
return null;
|
|
@@ -65,7 +66,7 @@ class JwtHttpBearerAuth extends HttpBearerAuth_1.HttpBearerAuth {
|
|
|
65
66
|
}
|
|
66
67
|
if (token !== null) {
|
|
67
68
|
if (this.auth != null) {
|
|
68
|
-
identity = yield this.auth(autHeader[1], ...
|
|
69
|
+
identity = yield this.auth(autHeader[1], ...arguments_1);
|
|
69
70
|
}
|
|
70
71
|
else {
|
|
71
72
|
identity = yield user.loginByAccessToken(autHeader[1], "JwtHttpBearerAuth");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AASA,OAAO,CAAC,MAAM,CAAC;IACX,UAAU,MAAM;QACZ,YAAY,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,CAAC;KAClC;CACJ;AAQD,OAAO,QAAQ,MAAM,YAAY,CAAC;AAClC,OAAO,EAAC,UAAU,EAAC,MAAM,QAAQ,CAAC;AAGlC,OAAO,QAAQ,2BAA2B,CAAC;IACvC,UAAU,OAAO;QACb,QAAQ,EAAE,GAAG,CAAC;KACjB;CACJ;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AASA,OAAO,CAAC,MAAM,CAAC;IACX,UAAU,MAAM;QACZ,YAAY,CAAC,GAAG,EAAE,GAAG,GAAG,MAAM,CAAC;KAClC;CACJ;AAQD,OAAO,QAAQ,MAAM,YAAY,CAAC;AAClC,OAAO,EAAC,UAAU,EAAC,MAAM,QAAQ,CAAC;AAGlC,OAAO,QAAQ,2BAA2B,CAAC;IACvC,UAAU,OAAO;QACb,QAAQ,EAAE,GAAG,CAAC;KACjB;CACJ;AAkBD,eAAO,MAAM,YAAY,KAAgB,CAAC;AAG1C,QAAA,MAAM,IAAI,UAAiB,CAAC;AAC5B,OAAO,EAAC,OAAO,EAAE,QAAQ,EAAE,YAAY,EAAC,MAAM,iBAAiB,CAAC;AAChE,OAAO,EAAC,eAAe,EAAC,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAC,OAAO,EAAC,MAAM,eAAe,CAAC;AACtC,OAAO,EAAC,QAAQ,EAAE,UAAU,EAAC,CAAA;AAC7B,OAAO,EACH,IAAI,EACJ,YAAY,EACZ,SAAS,EACT,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,cAAc,EACd,YAAY,EACZ,sBAAsB,EACtB,sBAAsB,EACtB,wBAAwB,EACxB,qBAAqB,EACrB,yBAAyB,EACzB,oBAAoB,EACpB,uBAAuB,EACvB,KAAK,EACL,YAAY,EACZ,OAAO,EACV,MAAM,QAAQ,CAAC;AAChB,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,SAAS,CAAC;AAExB,cAAc,aAAa,CAAC;AAC5B,cAAc,oBAAoB,CAAC;AAEnC,eAAe,IAAI,CAAC"}
|
|
@@ -43,6 +43,7 @@ String.prototype.tokenReplace = function (obj) {
|
|
|
43
43
|
*/
|
|
44
44
|
const pjson = require('./package.json');
|
|
45
45
|
exports.Chyz_Version = pjson.version;
|
|
46
|
+
console.log(`BaseChyz Framework Version ${exports.Chyz_Version}`);
|
|
46
47
|
const Chyz = new BaseChyz_1.default();
|
|
47
48
|
var WebUser_1 = require("./web/WebUser");
|
|
48
49
|
Object.defineProperty(exports, "WebUser", { enumerable: true, get: function () { return WebUser_1.WebUser; } });
|
|
@@ -1,55 +1,55 @@
|
|
|
1
|
-
{
|
|
2
|
-
"appenders": {
|
|
3
|
-
"access": {
|
|
4
|
-
"type": "dateFile",
|
|
5
|
-
"filename": "log/access.log",
|
|
6
|
-
"pattern": "-yyyy-MM-dd",
|
|
7
|
-
"category": "http",
|
|
8
|
-
"layout": {
|
|
9
|
-
"type": "pattern",
|
|
10
|
-
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
11
|
-
}
|
|
12
|
-
},
|
|
13
|
-
"app": {
|
|
14
|
-
"type": "file",
|
|
15
|
-
"filename": "log/app.log",
|
|
16
|
-
"maxLogSize": 10485760,
|
|
17
|
-
"numBackups": 3,
|
|
18
|
-
"layout": {
|
|
19
|
-
"type": "pattern",
|
|
20
|
-
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
21
|
-
}
|
|
22
|
-
},
|
|
23
|
-
"errorFile": {
|
|
24
|
-
"type": "file",
|
|
25
|
-
"filename": "log/errors.log",
|
|
26
|
-
"layout": {
|
|
27
|
-
"type": "pattern",
|
|
28
|
-
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
29
|
-
}
|
|
30
|
-
},
|
|
31
|
-
"errors": {
|
|
32
|
-
"type": "logLevelFilter",
|
|
33
|
-
"level": "ERROR",
|
|
34
|
-
"appender": "errorFile",
|
|
35
|
-
"layout": {
|
|
36
|
-
"type": "pattern",
|
|
37
|
-
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
"console": {
|
|
41
|
-
"type": "stdout"
|
|
42
|
-
}
|
|
43
|
-
},
|
|
44
|
-
"categories": {
|
|
45
|
-
"default": {
|
|
46
|
-
"appenders": ["console","app" ,"errors" ],
|
|
47
|
-
"level": "INFO",
|
|
48
|
-
"enableCallStack": true
|
|
49
|
-
},
|
|
50
|
-
"http": {
|
|
51
|
-
"level": "INFO",
|
|
52
|
-
"appenders": [ "access" ]
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"appenders": {
|
|
3
|
+
"access": {
|
|
4
|
+
"type": "dateFile",
|
|
5
|
+
"filename": "log/access.log",
|
|
6
|
+
"pattern": "-yyyy-MM-dd",
|
|
7
|
+
"category": "http",
|
|
8
|
+
"layout": {
|
|
9
|
+
"type": "pattern",
|
|
10
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
"app": {
|
|
14
|
+
"type": "file",
|
|
15
|
+
"filename": "log/app.log",
|
|
16
|
+
"maxLogSize": 10485760,
|
|
17
|
+
"numBackups": 3,
|
|
18
|
+
"layout": {
|
|
19
|
+
"type": "pattern",
|
|
20
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"errorFile": {
|
|
24
|
+
"type": "file",
|
|
25
|
+
"filename": "log/errors.log",
|
|
26
|
+
"layout": {
|
|
27
|
+
"type": "pattern",
|
|
28
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"errors": {
|
|
32
|
+
"type": "logLevelFilter",
|
|
33
|
+
"level": "ERROR",
|
|
34
|
+
"appender": "errorFile",
|
|
35
|
+
"layout": {
|
|
36
|
+
"type": "pattern",
|
|
37
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"console": {
|
|
41
|
+
"type": "stdout"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"categories": {
|
|
45
|
+
"default": {
|
|
46
|
+
"appenders": ["console","app" ,"errors" ],
|
|
47
|
+
"level": "INFO",
|
|
48
|
+
"enableCallStack": true
|
|
49
|
+
},
|
|
50
|
+
"http": {
|
|
51
|
+
"level": "INFO",
|
|
52
|
+
"appenders": [ "access" ]
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
{
|
|
2
|
+
"appenders": {
|
|
3
|
+
"access": {
|
|
4
|
+
"type": "dateFile",
|
|
5
|
+
"filename": "log/access.log",
|
|
6
|
+
"pattern": "-yyyy-MM-dd",
|
|
7
|
+
"category": "http",
|
|
8
|
+
"layout": {
|
|
9
|
+
"type": "pattern",
|
|
10
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
"app": {
|
|
14
|
+
"type": "file",
|
|
15
|
+
"filename": "log/app.log",
|
|
16
|
+
"maxLogSize": 10485760,
|
|
17
|
+
"numBackups": 3,
|
|
18
|
+
"layout": {
|
|
19
|
+
"type": "pattern",
|
|
20
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"errorFile": {
|
|
24
|
+
"type": "file",
|
|
25
|
+
"filename": "log/errors.log",
|
|
26
|
+
"layout": {
|
|
27
|
+
"type": "pattern",
|
|
28
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"errors": {
|
|
32
|
+
"type": "logLevelFilter",
|
|
33
|
+
"level": "ERROR",
|
|
34
|
+
"appender": "errorFile",
|
|
35
|
+
"layout": {
|
|
36
|
+
"type": "pattern",
|
|
37
|
+
"pattern": "[%d{yyyy-MM-ddThh.mm.ss.SSS}] [%p] %c [%l] [%f] - %m"
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
"console": {
|
|
41
|
+
"type": "stdout"
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
"categories": {
|
|
45
|
+
"default": {
|
|
46
|
+
"appenders": ["console","app" ,"errors" ],
|
|
47
|
+
"level": "INFO",
|
|
48
|
+
"enableCallStack": true
|
|
49
|
+
},
|
|
50
|
+
"http": {
|
|
51
|
+
"level": "INFO",
|
|
52
|
+
"appenders": [ "access" ]
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "chyz",
|
|
3
|
+
"version": "2.0.1-rc.36",
|
|
4
|
+
"description": "Nodejs Micro service Framework",
|
|
5
|
+
"scripts": {
|
|
6
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
7
|
+
"postversion": "git push && git push --tags"
|
|
8
|
+
},
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "git+https://github.com/cihan53/Chy-Nodejs-Framework.git"
|
|
12
|
+
},
|
|
13
|
+
"author": "Cihan Ozturk",
|
|
14
|
+
"license": "MIT",
|
|
15
|
+
"bugs": {
|
|
16
|
+
"url": "https://github.com/cihan53/Chy-Nodejs-Framework/issues"
|
|
17
|
+
},
|
|
18
|
+
"homepage": "https://github.com/cihan53/Chy-Nodejs-Framework#readme",
|
|
19
|
+
"dependencies": {
|
|
20
|
+
"@types/compression": "^1.7.5",
|
|
21
|
+
"axios": "^1.3.5",
|
|
22
|
+
"babel-plugin-transform-decorators-legacy": "^1.3.5",
|
|
23
|
+
"body-parser": "^1.20.2",
|
|
24
|
+
"compression": "^1.7.4",
|
|
25
|
+
"core-js": "^3.30.1",
|
|
26
|
+
"cors": "^2.8.5",
|
|
27
|
+
"dayjs": "^1.11.7",
|
|
28
|
+
"dotenv-flow": "^3.2.0",
|
|
29
|
+
"express": "^4.18.2",
|
|
30
|
+
"express-session": "^1.17.3",
|
|
31
|
+
"glob": "^10.0.0",
|
|
32
|
+
"ip": "^1.1.8",
|
|
33
|
+
"jsonwebtoken": "^9.0.0",
|
|
34
|
+
"lodash": "^4.17.21",
|
|
35
|
+
"lodash-uuid": "^0.0.3",
|
|
36
|
+
"log4js": "^6.9.1",
|
|
37
|
+
"method-override": "^3.0.0",
|
|
38
|
+
"passport": "^0.6.0",
|
|
39
|
+
"pg": "^8.10.0",
|
|
40
|
+
"pg-hstore": "^2.3.4",
|
|
41
|
+
"reflect-metadata": "^0.1.13",
|
|
42
|
+
"sequelize": "^6.31.0",
|
|
43
|
+
"sequelize-transparent-cache": "^2.3.0",
|
|
44
|
+
"tslib": "^2.5.0",
|
|
45
|
+
"validate.js": "^0.13.1"
|
|
46
|
+
},
|
|
47
|
+
"devDependencies": {
|
|
48
|
+
"@types/express": "^4.17.17",
|
|
49
|
+
"@types/node": "^18.15.11",
|
|
50
|
+
"@types/validator": "^13.7.15",
|
|
51
|
+
"nodemon": "^2.0.22",
|
|
52
|
+
"ts-node": "^10.9.1",
|
|
53
|
+
"typescript": "^5.0.4"
|
|
54
|
+
},
|
|
55
|
+
"keywords": [
|
|
56
|
+
"Framework",
|
|
57
|
+
"RespAPI",
|
|
58
|
+
"microservice",
|
|
59
|
+
"micro service",
|
|
60
|
+
"easy configuration",
|
|
61
|
+
"Rbac support"
|
|
62
|
+
]
|
|
63
|
+
}
|
|
@@ -25,8 +25,8 @@ class AuthManager extends base_1.Component {
|
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
28
|
-
checkAccess(
|
|
29
|
-
return __awaiter(this,
|
|
28
|
+
checkAccess(userId_1, permissionName_1) {
|
|
29
|
+
return __awaiter(this, arguments, void 0, function* (userId, permissionName, params = []) {
|
|
30
30
|
let assignments;
|
|
31
31
|
if (!userId)
|
|
32
32
|
return false;
|
|
@@ -351,6 +351,6 @@ class AuthManager extends base_1.Component {
|
|
|
351
351
|
return Utils_1.Utils.isEmpty(assignments) && Utils_1.Utils.isEmpty(this.defaultRoles);
|
|
352
352
|
}
|
|
353
353
|
}
|
|
354
|
+
exports.AuthManager = AuthManager;
|
|
354
355
|
AuthManager.TYPE_ROLE = 1;
|
|
355
356
|
AuthManager.TYPE_PERMISSION = 2;
|
|
356
|
-
exports.AuthManager = AuthManager;
|
|
@@ -69,8 +69,8 @@ class WebUser extends Component_1.Component {
|
|
|
69
69
|
* @param token
|
|
70
70
|
* @param type
|
|
71
71
|
*/
|
|
72
|
-
loginByAccessToken(
|
|
73
|
-
return __awaiter(this,
|
|
72
|
+
loginByAccessToken(token_1) {
|
|
73
|
+
return __awaiter(this, arguments, void 0, function* (token, type = null) {
|
|
74
74
|
let $class = this.identityClass;
|
|
75
75
|
if ($class.findIdentityByAccessToken) {
|
|
76
76
|
this.identity = yield $class.findIdentityByAccessToken(token, type);
|
|
@@ -130,8 +130,8 @@ class WebUser extends Component_1.Component {
|
|
|
130
130
|
//
|
|
131
131
|
// return $access;
|
|
132
132
|
// }
|
|
133
|
-
can(
|
|
134
|
-
return __awaiter(this,
|
|
133
|
+
can(permissionName_1) {
|
|
134
|
+
return __awaiter(this, arguments, void 0, function* (permissionName, params = [], allowCaching = true) {
|
|
135
135
|
let access;
|
|
136
136
|
let accessChecker;
|
|
137
137
|
if ((accessChecker = this.getAccessChecker()) == null)
|
package/package.json
CHANGED
|
@@ -1,61 +1,23 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
"
|
|
7
|
-
"
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
"
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
"core-js": "^3.30.1",
|
|
25
|
-
"cors": "^2.8.5",
|
|
26
|
-
"dayjs": "^1.11.7",
|
|
27
|
-
"dotenv-flow": "^3.2.0",
|
|
28
|
-
"express": "^4.18.2",
|
|
29
|
-
"express-session": "^1.17.3",
|
|
30
|
-
"glob": "^10.0.0",
|
|
31
|
-
"ip": "^1.1.8",
|
|
32
|
-
"jsonwebtoken": "^9.0.0",
|
|
33
|
-
"lodash": "^4.17.21",
|
|
34
|
-
"log4js": "^6.9.1",
|
|
35
|
-
"method-override": "^3.0.0",
|
|
36
|
-
"passport": "^0.6.0",
|
|
37
|
-
"pg": "^8.10.0",
|
|
38
|
-
"pg-hstore": "^2.3.4",
|
|
39
|
-
"reflect-metadata": "^0.1.13",
|
|
40
|
-
"sequelize": "^6.31.0",
|
|
41
|
-
"sequelize-transparent-cache": "^2.3.0",
|
|
42
|
-
"tslib": "^2.5.0",
|
|
43
|
-
"validate.js": "^0.13.1"
|
|
44
|
-
},
|
|
45
|
-
"devDependencies": {
|
|
46
|
-
"@types/express": "^4.17.17",
|
|
47
|
-
"@types/node": "^18.15.11",
|
|
48
|
-
"@types/validator": "^13.7.15",
|
|
49
|
-
"nodemon": "^2.0.22",
|
|
50
|
-
"ts-node": "^10.9.1",
|
|
51
|
-
"typescript": "^5.0.4"
|
|
52
|
-
} ,
|
|
53
|
-
"keywords": [
|
|
54
|
-
"Framework",
|
|
55
|
-
"RespAPI",
|
|
56
|
-
"microservice",
|
|
57
|
-
"micro service",
|
|
58
|
-
"easy configuration",
|
|
59
|
-
"Rbac support"
|
|
60
|
-
]
|
|
61
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"scripts": {
|
|
3
|
+
"debug": "ts-node src/index.ts",
|
|
4
|
+
"build2": "npx tsc -p tsconfig.json",
|
|
5
|
+
"build-win": "rmdir /S /Q .\\dist && npx tsc -p tsconfig.json && xcopy .\\src\\log .\\dist\\log /e /i /h /Y && copy .\\src\\package.json .\\dist\\package.json && copy .\\src\\README.md .\\dist\\README.md",
|
|
6
|
+
"build": "rm -rf .\\dist && npx tsc -p tsconfig.json && cp -r ./src/log ./dist/log && cp ./src/package.json ./dist/package.json && cp ./src/README.md ./dist/README.md",
|
|
7
|
+
"test": "echo \"Error: no test specified\" && exit 1",
|
|
8
|
+
"deprecate": "node ./deprecate.js",
|
|
9
|
+
"postversion": "git push && git push --tags"
|
|
10
|
+
},
|
|
11
|
+
"resolutions": {
|
|
12
|
+
"ts-node": "^10.2.0"
|
|
13
|
+
},
|
|
14
|
+
"name": "chyz",
|
|
15
|
+
"main": "dist/index.js",
|
|
16
|
+
"types": "dist/index.d.ts",
|
|
17
|
+
"files": [
|
|
18
|
+
"dist/**/*",
|
|
19
|
+
"README.md",
|
|
20
|
+
"package.json"
|
|
21
|
+
],
|
|
22
|
+
"version": "2.0.1-rc.37"
|
|
23
|
+
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ActionFilter.d.ts","sourceRoot":"","sources":["../../src/base/ActionFilter.ts"],"names":[],"mappings":";AAMA,OAAO,EAAC,OAAO,EAAE,QAAQ,EAAC,MAAM,UAAU,CAAC;AAE3C,OAAO,EAAC,WAAW,EAAC,MAAM,eAAe,CAAA;AAGzC,qBAAa,YAAa,SAAQ,WAAW;IAElC,IAAI,EAAE,GAAG,CAAC;IAEjB;;;OAGG;IACI,MAAM,UAAM;IAGZ,IAAI;IAIX;;;;;OAKG;IACU,YAAY,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ;IAUjE;;;;;OAKG;IACU,YAAY,CAAC,KAAK,EAAE,GAAG,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,QAAQ;IAIjE;;;;OAIG;IACH,SAAS,CAAC,QAAQ,CAAC,MAAM,EAAE,GAAG;CA8BjC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AccessControl.d.ts","sourceRoot":"","sources":["../../src/filters/AccessControl.ts"],"names":[],"mappings":";AAMA,OAAO,EAAC,OAAO,EAAC,QAAQ,EAAU,MAAM,UAAU,CAAC;AAEnD,OAAO,EAAC,YAAY,EAAC,MAAM,SAAS,CAAC;AAErC,OAAO,EAAC,OAAO,EAAC,MAAM,gBAAgB,CAAC;AAIvC,qBAAa,aAAc,SAAQ,YAAY;IAEpC,IAAI,EAAE,GAAG,CAAQ;IACjB,KAAK,EAAE,GAAG,CAAC;IACX,YAAY,EAAE,GAAG,CAAQ;IAEzB,IAAI;IAgBE,YAAY,CAAC,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,OAAO,EAAC,GAAG,EAAC,QAAQ;IAiC7D,UAAU,CAAC,IAAI,EAAE,OAAO;CAMlC"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|