@zenorm/generate 2.5.0 → 2.5.1

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.
Files changed (2) hide show
  1. package/dist/generate.js +1 -1
  2. package/package.json +1 -1
package/dist/generate.js CHANGED
@@ -151,7 +151,7 @@ async function generate(tables, cfg) {
151
151
  repositories.push(...[
152
152
  'master',
153
153
  'slave',
154
- ].map(i => ` static ${i} = ${className}.repository.${i};`));
154
+ ].map(i => ` static get ${i}(): typeof ${className}.repository.${i} { return ${className}.repository.${i}; }`));
155
155
  }
156
156
  // 实例方法
157
157
  if (config.instanceMethods) {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@zenorm/generate",
3
3
  "description": "Easy ORM, easy query. easy typing! Auto generate typescript declaration.",
4
- "version": "2.5.0",
4
+ "version": "2.5.1",
5
5
  "exports": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",
7
7
  "homepage": "https://zenorm.node.ltd",