@slingr/cli 0.0.2 → 0.0.4
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/LICENSE.txt +202 -0
- package/README.md +490 -319
- package/bin/dev.cmd +2 -2
- package/bin/dev.js +5 -5
- package/bin/run.cmd +2 -2
- package/bin/run.js +4 -4
- package/bin/slingr +1 -0
- package/dist/commands/build.d.ts +20 -0
- package/dist/commands/build.d.ts.map +1 -0
- package/dist/commands/build.js +206 -0
- package/dist/commands/build.js.map +1 -0
- package/dist/commands/create-app.d.ts +0 -1
- package/dist/commands/create-app.d.ts.map +1 -1
- package/dist/commands/create-app.js +38 -57
- package/dist/commands/create-app.js.map +1 -1
- package/dist/commands/debug.d.ts +28 -0
- package/dist/commands/debug.d.ts.map +1 -0
- package/dist/commands/debug.js +474 -0
- package/dist/commands/debug.js.map +1 -0
- package/dist/commands/ds.d.ts +14 -1
- package/dist/commands/ds.d.ts.map +1 -1
- package/dist/commands/ds.js +450 -121
- package/dist/commands/ds.js.map +1 -1
- package/dist/commands/gql.d.ts +1 -1
- package/dist/commands/gql.d.ts.map +1 -1
- package/dist/commands/gql.js +190 -184
- package/dist/commands/gql.js.map +1 -1
- package/dist/commands/infra/down.d.ts.map +1 -1
- package/dist/commands/infra/down.js +8 -7
- package/dist/commands/infra/down.js.map +1 -1
- package/dist/commands/infra/up.d.ts.map +1 -1
- package/dist/commands/infra/up.js +8 -7
- package/dist/commands/infra/up.js.map +1 -1
- package/dist/commands/infra/update.d.ts +1 -0
- package/dist/commands/infra/update.d.ts.map +1 -1
- package/dist/commands/infra/update.js +33 -69
- package/dist/commands/infra/update.js.map +1 -1
- package/dist/commands/run.d.ts +29 -2
- package/dist/commands/run.d.ts.map +1 -1
- package/dist/commands/run.js +628 -130
- package/dist/commands/run.js.map +1 -1
- package/dist/commands/setup.d.ts +1 -1
- package/dist/commands/setup.d.ts.map +1 -1
- package/dist/commands/setup.js +34 -71
- package/dist/commands/setup.js.map +1 -1
- package/dist/commands/sync-metadata.d.ts +15 -0
- package/dist/commands/sync-metadata.d.ts.map +1 -0
- package/dist/commands/sync-metadata.js +225 -0
- package/dist/commands/sync-metadata.js.map +1 -0
- package/dist/commands/users.d.ts +30 -0
- package/dist/commands/users.d.ts.map +1 -0
- package/dist/commands/users.js +472 -0
- package/dist/commands/users.js.map +1 -0
- package/dist/commands/views.d.ts +11 -0
- package/dist/commands/views.d.ts.map +1 -0
- package/dist/commands/views.js +73 -0
- package/dist/commands/views.js.map +1 -0
- package/dist/projectStructure.d.ts +2 -2
- package/dist/projectStructure.d.ts.map +1 -1
- package/dist/projectStructure.js +281 -69
- package/dist/projectStructure.js.map +1 -1
- package/dist/scripts/generate-metadata.d.ts +13 -0
- package/dist/scripts/generate-metadata.d.ts.map +1 -0
- package/dist/scripts/generate-metadata.js +412 -0
- package/dist/scripts/generate-metadata.js.map +1 -0
- package/dist/scripts/generate-metadata.ts +498 -0
- package/dist/scripts/generate-schema.d.ts +1 -1
- package/dist/scripts/generate-schema.js +168 -74
- package/dist/scripts/generate-schema.js.map +1 -1
- package/dist/scripts/generate-schema.ts +258 -143
- package/dist/templates/.env.template +23 -0
- package/dist/templates/.firebaserc.template +5 -0
- package/dist/templates/.github/copilot-instructions.md.template +652 -17
- package/dist/templates/backend/Dockerfile.template +30 -0
- package/dist/templates/config/datasource.ts.template +12 -9
- package/dist/templates/config/jest.config.ts +30 -30
- package/dist/templates/config/jest.setup.ts +1 -1
- package/dist/templates/config/tsconfig.json.template +50 -29
- package/dist/templates/dataSources/mysql.ts.template +16 -13
- package/dist/templates/dataSources/postgres.ts.template +15 -13
- package/dist/templates/dataset-generator-script.ts.template +139 -139
- package/dist/templates/datasets/mysql-default/.slingr-schema.json.template +5 -0
- package/dist/templates/datasets/mysql-default/Address.jsonl.template +3 -3
- package/dist/templates/datasets/mysql-default/App.jsonl.template +4 -4
- package/dist/templates/datasets/mysql-default/Company.jsonl.template +3 -3
- package/dist/templates/datasets/mysql-default/Person.jsonl.template +2 -2
- package/dist/templates/datasets/mysql-default/User.jsonl.template +1 -0
- package/dist/templates/datasets/mysql-default/instructions.md.template +1 -0
- package/dist/templates/datasets/postgres-default/.slingr-schema.json.template +5 -0
- package/dist/templates/datasets/postgres-default/Address.jsonl.template +3 -3
- package/dist/templates/datasets/postgres-default/App.jsonl.template +4 -4
- package/dist/templates/datasets/postgres-default/Company.jsonl.template +3 -3
- package/dist/templates/datasets/postgres-default/Person.jsonl.template +2 -2
- package/dist/templates/datasets/postgres-default/User.jsonl.template +1 -0
- package/dist/templates/datasets/postgres-default/instructions.md.template +1 -0
- package/dist/templates/docker-compose.prod-test.yml.template +32 -0
- package/dist/templates/docker-compose.yml.template +24 -0
- package/dist/templates/docs/app-description.md.template +33 -33
- package/dist/templates/firebase.json.template +68 -0
- package/dist/templates/frontend/.umirc.ts.template +23 -0
- package/dist/templates/frontend/package.json.template +45 -0
- package/dist/templates/frontend/public/config.json +6 -0
- package/dist/templates/frontend/public/logo.svg +6 -0
- package/dist/templates/frontend/src/app.tsx.template +44 -0
- package/dist/templates/frontend/src/global.less.template +117 -0
- package/dist/templates/frontend/src/layouts/MainLayout.tsx.template +75 -0
- package/dist/templates/frontend/src/types/graphql-augmentation.d.ts.template +44 -0
- package/dist/templates/frontend/src/views/customViews/user/UserCreateView.tsx.template +18 -0
- package/dist/templates/frontend/src/views/customViews/user/UserEditView.tsx.template +29 -0
- package/dist/templates/frontend/src/views/customViews/user/UserReadView.tsx.template +24 -0
- package/dist/templates/frontend/src/views/customViews/user/UserTableView.tsx.template +38 -0
- package/dist/templates/frontend/src/views/customViews/welcome.tsx.template +34 -0
- package/dist/templates/frontend/tsconfig.json.template +50 -0
- package/dist/templates/gql/codegen.yml.template +25 -25
- package/dist/templates/gql/index.ts.template +17 -24
- package/dist/templates/gql/operations.graphql.template +30 -30
- package/dist/templates/ops/README.md.template +1045 -0
- package/dist/templates/ops/cloudbuild.yaml.template +161 -0
- package/dist/templates/ops/scripts/_utils.js.template +217 -0
- package/dist/templates/ops/scripts/deploy.js.template +145 -0
- package/dist/templates/ops/scripts/setup-gcp.js.template +330 -0
- package/dist/templates/ops/scripts/setup-secrets.js.template +76 -0
- package/dist/templates/ops/scripts/test-prod-local.js.template +49 -0
- package/dist/templates/package.json.template +50 -38
- package/dist/templates/pnpm-workspace.yaml.template +3 -0
- package/dist/templates/prompt-analysis.md.template +110 -110
- package/dist/templates/prompt-script-generation.md.template +258 -258
- package/dist/templates/src/Address.ts.template +28 -31
- package/dist/templates/src/App.ts.template +17 -61
- package/dist/templates/src/Company.ts.template +41 -47
- package/dist/templates/src/Models.test.ts.template +654 -654
- package/dist/templates/src/Person.test.ts.template +289 -289
- package/dist/templates/src/Person.ts.template +90 -105
- package/dist/templates/src/actions/index.ts.template +11 -11
- package/dist/templates/src/auth/permissions.ts.template +34 -0
- package/dist/templates/src/data/App.ts.template +48 -0
- package/dist/templates/src/data/User.ts.template +35 -0
- package/dist/templates/src/types/gql.d.ts.template +17 -17
- package/dist/templates/vscode/extensions.json +4 -3
- package/dist/templates/vscode/settings.json +17 -11
- package/dist/templates/workspace-package.json.template +21 -0
- package/dist/utils/buildCache.d.ts +12 -0
- package/dist/utils/buildCache.d.ts.map +1 -0
- package/dist/utils/buildCache.js +102 -0
- package/dist/utils/buildCache.js.map +1 -0
- package/dist/utils/checkFramework.d.ts +27 -0
- package/dist/utils/checkFramework.d.ts.map +1 -0
- package/dist/utils/checkFramework.js +104 -0
- package/dist/utils/checkFramework.js.map +1 -0
- package/dist/utils/datasourceParser.d.ts +11 -0
- package/dist/utils/datasourceParser.d.ts.map +1 -1
- package/dist/utils/datasourceParser.js +154 -56
- package/dist/utils/datasourceParser.js.map +1 -1
- package/dist/utils/dockerManager.d.ts +25 -0
- package/dist/utils/dockerManager.d.ts.map +1 -0
- package/dist/utils/dockerManager.js +281 -0
- package/dist/utils/dockerManager.js.map +1 -0
- package/dist/utils/infraFileParser.d.ts +26 -0
- package/dist/utils/infraFileParser.d.ts.map +1 -0
- package/dist/utils/infraFileParser.js +75 -0
- package/dist/utils/infraFileParser.js.map +1 -0
- package/dist/utils/jsonlLoader.d.ts +91 -12
- package/dist/utils/jsonlLoader.d.ts.map +1 -1
- package/dist/utils/jsonlLoader.js +674 -63
- package/dist/utils/jsonlLoader.js.map +1 -1
- package/dist/utils/model-analyzer.d.ts.map +1 -1
- package/dist/utils/model-analyzer.js +67 -13
- package/dist/utils/model-analyzer.js.map +1 -1
- package/dist/utils/userManagement.d.ts +57 -0
- package/dist/utils/userManagement.d.ts.map +1 -0
- package/dist/utils/userManagement.js +288 -0
- package/dist/utils/userManagement.js.map +1 -0
- package/dist/utils/viewsGenerator.d.ts +15 -0
- package/dist/utils/viewsGenerator.d.ts.map +1 -0
- package/dist/utils/viewsGenerator.js +311 -0
- package/dist/utils/viewsGenerator.js.map +1 -0
- package/oclif.manifest.json +445 -20
- package/package.json +29 -27
- package/src/templates/.env.template +23 -0
- package/src/templates/.firebaserc.template +5 -0
- package/src/templates/.github/copilot-instructions.md.template +652 -17
- package/src/templates/backend/Dockerfile.template +30 -0
- package/src/templates/config/datasource.ts.template +12 -9
- package/src/templates/config/jest.config.ts +30 -30
- package/src/templates/config/jest.setup.ts +1 -1
- package/src/templates/config/tsconfig.json.template +50 -29
- package/src/templates/dataSources/mysql.ts.template +16 -13
- package/src/templates/dataSources/postgres.ts.template +15 -13
- package/src/templates/dataset-generator-script.ts.template +139 -139
- package/src/templates/datasets/mysql-default/.slingr-schema.json.template +5 -0
- package/src/templates/datasets/mysql-default/Address.jsonl.template +3 -3
- package/src/templates/datasets/mysql-default/App.jsonl.template +4 -4
- package/src/templates/datasets/mysql-default/Company.jsonl.template +3 -3
- package/src/templates/datasets/mysql-default/Person.jsonl.template +2 -2
- package/src/templates/datasets/mysql-default/User.jsonl.template +1 -0
- package/src/templates/datasets/mysql-default/instructions.md.template +1 -0
- package/src/templates/datasets/postgres-default/.slingr-schema.json.template +5 -0
- package/src/templates/datasets/postgres-default/Address.jsonl.template +3 -3
- package/src/templates/datasets/postgres-default/App.jsonl.template +4 -4
- package/src/templates/datasets/postgres-default/Company.jsonl.template +3 -3
- package/src/templates/datasets/postgres-default/Person.jsonl.template +2 -2
- package/src/templates/datasets/postgres-default/User.jsonl.template +1 -0
- package/src/templates/datasets/postgres-default/instructions.md.template +1 -0
- package/src/templates/docker-compose.prod-test.yml.template +32 -0
- package/src/templates/docker-compose.yml.template +24 -0
- package/src/templates/docs/app-description.md.template +33 -33
- package/src/templates/firebase.json.template +68 -0
- package/src/templates/frontend/.umirc.ts.template +23 -0
- package/src/templates/frontend/package.json.template +45 -0
- package/src/templates/frontend/public/config.json +6 -0
- package/src/templates/frontend/public/logo.svg +6 -0
- package/src/templates/frontend/src/app.tsx.template +44 -0
- package/src/templates/frontend/src/global.less.template +117 -0
- package/src/templates/frontend/src/layouts/MainLayout.tsx.template +75 -0
- package/src/templates/frontend/src/types/graphql-augmentation.d.ts.template +44 -0
- package/src/templates/frontend/src/views/customViews/user/UserCreateView.tsx.template +18 -0
- package/src/templates/frontend/src/views/customViews/user/UserEditView.tsx.template +29 -0
- package/src/templates/frontend/src/views/customViews/user/UserReadView.tsx.template +24 -0
- package/src/templates/frontend/src/views/customViews/user/UserTableView.tsx.template +38 -0
- package/src/templates/frontend/src/views/customViews/welcome.tsx.template +34 -0
- package/src/templates/frontend/tsconfig.json.template +50 -0
- package/src/templates/gql/codegen.yml.template +25 -25
- package/src/templates/gql/index.ts.template +17 -24
- package/src/templates/gql/operations.graphql.template +30 -30
- package/src/templates/ops/README.md.template +1045 -0
- package/src/templates/ops/cloudbuild.yaml.template +161 -0
- package/src/templates/ops/scripts/_utils.js.template +217 -0
- package/src/templates/ops/scripts/deploy.js.template +145 -0
- package/src/templates/ops/scripts/setup-gcp.js.template +330 -0
- package/src/templates/ops/scripts/setup-secrets.js.template +76 -0
- package/src/templates/ops/scripts/test-prod-local.js.template +49 -0
- package/src/templates/package.json.template +50 -38
- package/src/templates/pnpm-workspace.yaml.template +3 -0
- package/src/templates/prompt-analysis.md.template +110 -110
- package/src/templates/prompt-script-generation.md.template +258 -258
- package/src/templates/src/Address.ts.template +28 -31
- package/src/templates/src/App.ts.template +17 -61
- package/src/templates/src/Company.ts.template +41 -47
- package/src/templates/src/Models.test.ts.template +654 -654
- package/src/templates/src/Person.test.ts.template +289 -289
- package/src/templates/src/Person.ts.template +90 -105
- package/src/templates/src/actions/index.ts.template +11 -11
- package/src/templates/src/auth/permissions.ts.template +34 -0
- package/src/templates/src/data/App.ts.template +48 -0
- package/src/templates/src/data/User.ts.template +35 -0
- package/src/templates/src/types/gql.d.ts.template +17 -17
- package/src/templates/vscode/extensions.json +4 -3
- package/src/templates/vscode/settings.json +17 -11
- package/src/templates/workspace-package.json.template +21 -0
- package/dist/templates/src/index.ts +0 -66
- package/src/templates/src/index.ts +0 -66
|
@@ -1,9 +1,12 @@
|
|
|
1
|
-
import { TypeOrmSqlDataSource } from 'slingr-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
import { DataSource, TypeOrmSqlDataSource, DependencyContainer } from '@slingr/framework-backend'
|
|
2
|
+
|
|
3
|
+
@DataSource()
|
|
4
|
+
export class MainDataSource extends TypeOrmSqlDataSource {
|
|
5
|
+
override type = '{{DB_TYPE}}' as const;
|
|
6
|
+
override managed = true;
|
|
7
|
+
override filename = ':memory:';
|
|
8
|
+
override logging = false;
|
|
9
|
+
override synchronize = true;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export const mainDataSource = DependencyContainer.resolve(MainDataSource);
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import type { Config } from 'jest';
|
|
2
|
-
|
|
3
|
-
const config: Config = {
|
|
4
|
-
coverageProvider: 'v8',
|
|
5
|
-
moduleDirectories: ['node_modules', '<rootDir>'],
|
|
6
|
-
moduleNameMapper: {
|
|
7
|
-
'#(.*)': '<rootDir>/node_modules/$1',
|
|
8
|
-
'slingr-
|
|
9
|
-
},
|
|
10
|
-
modulePaths: ['<rootDir>'],
|
|
11
|
-
preset: 'ts-jest',
|
|
12
|
-
setupFilesAfterEnv: ['<rootDir>/jest.setup.ts'],
|
|
13
|
-
testEnvironment: 'node',
|
|
14
|
-
testMatch: ['<rootDir>/src/**/*.test.ts'],
|
|
15
|
-
transform: {
|
|
16
|
-
'^.+\\.(ts|tsx|js|jsx)$': [
|
|
17
|
-
'ts-jest',
|
|
18
|
-
{
|
|
19
|
-
tsconfig: {
|
|
20
|
-
module: 'commonjs',
|
|
21
|
-
allowJs: true,
|
|
22
|
-
},
|
|
23
|
-
},
|
|
24
|
-
],
|
|
25
|
-
'^.+\\.[j]sx?$': 'babel-jest',
|
|
26
|
-
},
|
|
27
|
-
transformIgnorePatterns: ['/node_modules/(
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
module.exports = config;
|
|
1
|
+
import type { Config } from 'jest';
|
|
2
|
+
|
|
3
|
+
const config: Config = {
|
|
4
|
+
coverageProvider: 'v8',
|
|
5
|
+
moduleDirectories: ['node_modules', '<rootDir>'],
|
|
6
|
+
moduleNameMapper: {
|
|
7
|
+
'#(.*)': '<rootDir>/node_modules/$1',
|
|
8
|
+
'@slingr/framework-backend': '<rootDir>/node_modules/@slingr/framework-backend',
|
|
9
|
+
},
|
|
10
|
+
modulePaths: ['<rootDir>'],
|
|
11
|
+
preset: 'ts-jest',
|
|
12
|
+
setupFilesAfterEnv: ['<rootDir>/jest.setup.ts'],
|
|
13
|
+
testEnvironment: 'node',
|
|
14
|
+
testMatch: ['<rootDir>/src/**/*.test.ts'],
|
|
15
|
+
transform: {
|
|
16
|
+
'^.+\\.(ts|tsx|js|jsx)$': [
|
|
17
|
+
'ts-jest',
|
|
18
|
+
{
|
|
19
|
+
tsconfig: {
|
|
20
|
+
module: 'commonjs',
|
|
21
|
+
allowJs: true,
|
|
22
|
+
},
|
|
23
|
+
},
|
|
24
|
+
],
|
|
25
|
+
'^.+\\.[j]sx?$': 'babel-jest',
|
|
26
|
+
},
|
|
27
|
+
transformIgnorePatterns: ['/node_modules/(?!@slingr/framework-backend)'],
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
module.exports = config;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import 'reflect-metadata';
|
|
1
|
+
import 'reflect-metadata';
|
|
@@ -1,30 +1,51 @@
|
|
|
1
|
-
{
|
|
2
|
-
"
|
|
3
|
-
"
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
"
|
|
7
|
-
"
|
|
8
|
-
"
|
|
9
|
-
"
|
|
10
|
-
"
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
"
|
|
14
|
-
"
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
"
|
|
18
|
-
"
|
|
19
|
-
"
|
|
20
|
-
"
|
|
21
|
-
"
|
|
22
|
-
"
|
|
23
|
-
"
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
1
|
+
{
|
|
2
|
+
"ts-node": {
|
|
3
|
+
"require": ["tsconfig-paths/register", "./generated/views.ts"]
|
|
4
|
+
},
|
|
5
|
+
"compilerOptions": {
|
|
6
|
+
"module": "CommonJS",
|
|
7
|
+
"moduleResolution": "Node",
|
|
8
|
+
"target": "ES2022",
|
|
9
|
+
"types": ["node", "jest"],
|
|
10
|
+
"sourceMap": true,
|
|
11
|
+
"declaration": true,
|
|
12
|
+
"declarationMap": true,
|
|
13
|
+
"noUncheckedIndexedAccess": false,
|
|
14
|
+
"exactOptionalPropertyTypes": false,
|
|
15
|
+
"strict": true,
|
|
16
|
+
"jsx": "react-jsx",
|
|
17
|
+
"verbatimModuleSyntax": false,
|
|
18
|
+
"isolatedModules": true,
|
|
19
|
+
"noUncheckedSideEffectImports": true,
|
|
20
|
+
"moduleDetection": "force",
|
|
21
|
+
"skipLibCheck": true,
|
|
22
|
+
"skipDefaultLibCheck": true,
|
|
23
|
+
"experimentalDecorators": true,
|
|
24
|
+
"emitDecoratorMetadata": true,
|
|
25
|
+
"esModuleInterop": true,
|
|
26
|
+
"baseUrl": ".",
|
|
27
|
+
"outDir": "./dist",
|
|
28
|
+
"paths": {
|
|
29
|
+
"@/*": ["./src/*"],
|
|
30
|
+
"@gql": ["./generated/gql/index.ts"],
|
|
31
|
+
"@gql/*": ["./generated/gql/*"]
|
|
32
|
+
},
|
|
33
|
+
"noImplicitOverride": true,
|
|
34
|
+
},
|
|
35
|
+
"include": ["src/**/*", "test/**/*", "generated/**/*", "jest.config.js", "index.ts"],
|
|
36
|
+
"exclude": ["node_modules", "dist", "**/*.test.ts", "config", "logs"],
|
|
37
|
+
"watchOptions": {
|
|
38
|
+
"watchFile": "useFsEventsOnParentDirectory",
|
|
39
|
+
"watchDirectory": "useFsEvents",
|
|
40
|
+
"fallbackPolling": "dynamicpriority",
|
|
41
|
+
"synchronousWatchDirectory": false,
|
|
42
|
+
"excludeDirectories": [
|
|
43
|
+
"**/node_modules",
|
|
44
|
+
"**/.git",
|
|
45
|
+
"dist",
|
|
46
|
+
],
|
|
47
|
+
"excludeFiles": [
|
|
48
|
+
"**/node_modules/**/package.json",
|
|
49
|
+
]
|
|
50
|
+
}
|
|
30
51
|
}
|
|
@@ -1,13 +1,16 @@
|
|
|
1
|
-
import { TypeOrmSqlDataSource } from 'slingr-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import { DataSource, TypeOrmSqlDataSource } from '@slingr/framework-backend';
|
|
2
|
+
import type { SqlDataSourceType } from '@slingr/framework-backend';
|
|
3
|
+
|
|
4
|
+
@DataSource()
|
|
5
|
+
export class MainDs extends TypeOrmSqlDataSource {
|
|
6
|
+
override type: SqlDataSourceType = 'mysql';
|
|
7
|
+
override managed = true;
|
|
8
|
+
override host = process.env.DB_HOST ?? 'localhost';
|
|
9
|
+
override port = parseInt(process.env.DB_PORT ?? '3307', 10);
|
|
10
|
+
override username = process.env.DB_USER ?? 'root';
|
|
11
|
+
override password = process.env.DB_PASSWORD ?? 'root';
|
|
12
|
+
override database = process.env.DB_NAME ?? '{{APP_NAME}}';
|
|
13
|
+
override synchronize = process.env.DB_SYNCHRONIZE === 'true';
|
|
14
|
+
override logging = true;
|
|
15
|
+
}
|
|
16
|
+
|
|
@@ -1,13 +1,15 @@
|
|
|
1
|
-
import { TypeOrmSqlDataSource } from 'slingr-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
1
|
+
import { DataSource, TypeOrmSqlDataSource } from '@slingr/framework-backend';
|
|
2
|
+
import type { SqlDataSourceType } from '@slingr/framework-backend';
|
|
3
|
+
|
|
4
|
+
@DataSource()
|
|
5
|
+
export class MainDs extends TypeOrmSqlDataSource {
|
|
6
|
+
override type: SqlDataSourceType = 'postgres';
|
|
7
|
+
override managed = true;
|
|
8
|
+
override host = process.env.DB_HOST ?? 'localhost';
|
|
9
|
+
override port = parseInt(process.env.DB_PORT ?? '5433', 10);
|
|
10
|
+
override username = process.env.DB_USER ?? 'postgres';
|
|
11
|
+
override password = process.env.DB_PASSWORD ?? 'postgres';
|
|
12
|
+
override database = process.env.DB_NAME ?? '{{APP_NAME}}';
|
|
13
|
+
override synchronize = process.env.DB_SYNCHRONIZE === 'true';
|
|
14
|
+
override logging = true;
|
|
15
|
+
}
|
|
@@ -1,140 +1,140 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Dataset Generator Script for {{PROJECT_NAME}}
|
|
3
|
-
*
|
|
4
|
-
* This script generates synthetic data for the {{DATASOURCE}}-{{DATASET}} dataset.
|
|
5
|
-
* Generated by Slingr CLI at {{TIMESTAMP}}
|
|
6
|
-
*
|
|
7
|
-
* Usage:
|
|
8
|
-
*
|
|
9
|
-
* node dist/scripts/generate-{{DATASOURCE}}-{{DATASET}}.js
|
|
10
|
-
*
|
|
11
|
-
* Or via CLI:
|
|
12
|
-
* slingr ds {{DATASOURCE}} run-script {{DATASET}}
|
|
13
|
-
*/
|
|
14
|
-
|
|
15
|
-
import { faker } from '@faker-js/faker';
|
|
16
|
-
import fs from 'fs-extra';
|
|
17
|
-
import path from 'path';
|
|
18
|
-
|
|
19
|
-
// Import your models (adjust paths as needed)
|
|
20
|
-
{{MODEL_IMPORTS}}
|
|
21
|
-
|
|
22
|
-
interface GenerationConfig {
|
|
23
|
-
seed?: number;
|
|
24
|
-
locale?: string;
|
|
25
|
-
outputDir?: string;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
class {{DATASET_CLASS_NAME}}Generator {
|
|
29
|
-
private config: GenerationConfig;
|
|
30
|
-
|
|
31
|
-
constructor(config: GenerationConfig = {}) {
|
|
32
|
-
this.config = {
|
|
33
|
-
seed: config.seed || {{SEED}},
|
|
34
|
-
locale: config.locale || '{{LOCALE}}',
|
|
35
|
-
outputDir: config.outputDir || path.join(process.cwd(), 'src', 'datasets', '{{DATASOURCE}}-{{DATASET}}'),
|
|
36
|
-
};
|
|
37
|
-
|
|
38
|
-
// Set faker seed for reproducible results
|
|
39
|
-
faker.seed(this.config.seed);
|
|
40
|
-
if (this.config.locale !== 'en') {
|
|
41
|
-
faker.setLocale(this.config.locale);
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
/**
|
|
46
|
-
* Generate all datasets
|
|
47
|
-
*/
|
|
48
|
-
async generateAll(): Promise<void> {
|
|
49
|
-
console.log('🎯 Starting dataset generation...');
|
|
50
|
-
|
|
51
|
-
// Ensure output directory exists
|
|
52
|
-
await fs.ensureDir(this.config.outputDir!);
|
|
53
|
-
|
|
54
|
-
{{GENERATION_METHODS}}
|
|
55
|
-
|
|
56
|
-
console.log('🎉 Dataset generation completed!');
|
|
57
|
-
console.log(`📁 Output directory: ${this.config.outputDir}`);
|
|
58
|
-
console.log('\n💡 To load this dataset, run:');
|
|
59
|
-
console.log(` slingr ds {{DATASOURCE}} load {{DATASET}}`);
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
{{INDIVIDUAL_GENERATORS}}
|
|
63
|
-
|
|
64
|
-
/**
|
|
65
|
-
* Save records to JSONL file
|
|
66
|
-
*/
|
|
67
|
-
private async saveToFile<T>(records: T[], fileName: string): Promise<void> {
|
|
68
|
-
const filePath = path.join(this.config.outputDir!, `${fileName}.jsonl`);
|
|
69
|
-
const jsonlContent = records.map(record => JSON.stringify(record)).join('\n');
|
|
70
|
-
|
|
71
|
-
await fs.writeFile(filePath, jsonlContent, 'utf-8');
|
|
72
|
-
console.log(`💾 Saved ${records.length} records to ${fileName}.jsonl`);
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Utility method to generate realistic data based on field hints
|
|
77
|
-
*/
|
|
78
|
-
private generateByFieldName(fieldName: string, type: string): any {
|
|
79
|
-
const name = fieldName.toLowerCase();
|
|
80
|
-
|
|
81
|
-
switch (type.toLowerCase()) {
|
|
82
|
-
case 'email':
|
|
83
|
-
return faker.internet.email();
|
|
84
|
-
|
|
85
|
-
case 'text':
|
|
86
|
-
if (name.includes('name')) {
|
|
87
|
-
if (name.includes('first')) return faker.person.firstName();
|
|
88
|
-
if (name.includes('last')) return faker.person.lastName();
|
|
89
|
-
if (name.includes('company')) return faker.company.name();
|
|
90
|
-
return faker.person.fullName();
|
|
91
|
-
}
|
|
92
|
-
if (name.includes('phone')) return faker.phone.number();
|
|
93
|
-
if (name.includes('address')) return faker.location.streetAddress();
|
|
94
|
-
if (name.includes('city')) return faker.location.city();
|
|
95
|
-
if (name.includes('country')) return faker.location.country();
|
|
96
|
-
if (name.includes('description')) return faker.lorem.paragraph();
|
|
97
|
-
return faker.lorem.words(Math.floor(Math.random() * 3) + 1);
|
|
98
|
-
|
|
99
|
-
case 'integer':
|
|
100
|
-
if (name.includes('age')) return faker.number.int({ min: 1, max: 120 });
|
|
101
|
-
return faker.number.int({ min: 1, max: 1000 });
|
|
102
|
-
|
|
103
|
-
case 'float':
|
|
104
|
-
case 'decimal':
|
|
105
|
-
return faker.number.float({ min: 0, max: 1000, precision: 0.01 });
|
|
106
|
-
|
|
107
|
-
case 'boolean':
|
|
108
|
-
return faker.datatype.boolean();
|
|
109
|
-
|
|
110
|
-
case 'date':
|
|
111
|
-
return faker.date.past().toISOString();
|
|
112
|
-
|
|
113
|
-
case 'uuid':
|
|
114
|
-
return faker.string.uuid();
|
|
115
|
-
|
|
116
|
-
case 'html':
|
|
117
|
-
return `<p>${faker.lorem.sentence()}</p>`;
|
|
118
|
-
|
|
119
|
-
default:
|
|
120
|
-
return faker.lorem.word();
|
|
121
|
-
}
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
// Main execution
|
|
126
|
-
if (require.main === module) {
|
|
127
|
-
const generator = new {{DATASET_CLASS_NAME}}Generator();
|
|
128
|
-
|
|
129
|
-
generator.generateAll()
|
|
130
|
-
.then(() => {
|
|
131
|
-
console.log('✅ Script completed successfully');
|
|
132
|
-
process.exit(0);
|
|
133
|
-
})
|
|
134
|
-
.catch((error) => {
|
|
135
|
-
console.error('❌ Script failed:', error);
|
|
136
|
-
process.exit(1);
|
|
137
|
-
});
|
|
138
|
-
}
|
|
139
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Dataset Generator Script for {{PROJECT_NAME}}
|
|
3
|
+
*
|
|
4
|
+
* This script generates synthetic data for the {{DATASOURCE}}-{{DATASET}} dataset.
|
|
5
|
+
* Generated by Slingr CLI at {{TIMESTAMP}}
|
|
6
|
+
*
|
|
7
|
+
* Usage:
|
|
8
|
+
* pnpm run build
|
|
9
|
+
* node dist/scripts/generate-{{DATASOURCE}}-{{DATASET}}.js
|
|
10
|
+
*
|
|
11
|
+
* Or via CLI:
|
|
12
|
+
* slingr ds {{DATASOURCE}} run-script {{DATASET}}
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { faker } from '@faker-js/faker';
|
|
16
|
+
import fs from 'fs-extra';
|
|
17
|
+
import path from 'path';
|
|
18
|
+
|
|
19
|
+
// Import your models (adjust paths as needed)
|
|
20
|
+
{{MODEL_IMPORTS}}
|
|
21
|
+
|
|
22
|
+
interface GenerationConfig {
|
|
23
|
+
seed?: number;
|
|
24
|
+
locale?: string;
|
|
25
|
+
outputDir?: string;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
class {{DATASET_CLASS_NAME}}Generator {
|
|
29
|
+
private config: GenerationConfig;
|
|
30
|
+
|
|
31
|
+
constructor(config: GenerationConfig = {}) {
|
|
32
|
+
this.config = {
|
|
33
|
+
seed: config.seed || {{SEED}},
|
|
34
|
+
locale: config.locale || '{{LOCALE}}',
|
|
35
|
+
outputDir: config.outputDir || path.join(process.cwd(), 'src', 'datasets', '{{DATASOURCE}}-{{DATASET}}'),
|
|
36
|
+
};
|
|
37
|
+
|
|
38
|
+
// Set faker seed for reproducible results
|
|
39
|
+
faker.seed(this.config.seed);
|
|
40
|
+
if (this.config.locale !== 'en') {
|
|
41
|
+
faker.setLocale(this.config.locale);
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Generate all datasets
|
|
47
|
+
*/
|
|
48
|
+
async generateAll(): Promise<void> {
|
|
49
|
+
console.log('🎯 Starting dataset generation...');
|
|
50
|
+
|
|
51
|
+
// Ensure output directory exists
|
|
52
|
+
await fs.ensureDir(this.config.outputDir!);
|
|
53
|
+
|
|
54
|
+
{{GENERATION_METHODS}}
|
|
55
|
+
|
|
56
|
+
console.log('🎉 Dataset generation completed!');
|
|
57
|
+
console.log(`📁 Output directory: ${this.config.outputDir}`);
|
|
58
|
+
console.log('\n💡 To load this dataset, run:');
|
|
59
|
+
console.log(` slingr ds {{DATASOURCE}} load {{DATASET}}`);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
{{INDIVIDUAL_GENERATORS}}
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Save records to JSONL file
|
|
66
|
+
*/
|
|
67
|
+
private async saveToFile<T>(records: T[], fileName: string): Promise<void> {
|
|
68
|
+
const filePath = path.join(this.config.outputDir!, `${fileName}.jsonl`);
|
|
69
|
+
const jsonlContent = records.map(record => JSON.stringify(record)).join('\n');
|
|
70
|
+
|
|
71
|
+
await fs.writeFile(filePath, jsonlContent, 'utf-8');
|
|
72
|
+
console.log(`💾 Saved ${records.length} records to ${fileName}.jsonl`);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* Utility method to generate realistic data based on field hints
|
|
77
|
+
*/
|
|
78
|
+
private generateByFieldName(fieldName: string, type: string): any {
|
|
79
|
+
const name = fieldName.toLowerCase();
|
|
80
|
+
|
|
81
|
+
switch (type.toLowerCase()) {
|
|
82
|
+
case 'email':
|
|
83
|
+
return faker.internet.email();
|
|
84
|
+
|
|
85
|
+
case 'text':
|
|
86
|
+
if (name.includes('name')) {
|
|
87
|
+
if (name.includes('first')) return faker.person.firstName();
|
|
88
|
+
if (name.includes('last')) return faker.person.lastName();
|
|
89
|
+
if (name.includes('company')) return faker.company.name();
|
|
90
|
+
return faker.person.fullName();
|
|
91
|
+
}
|
|
92
|
+
if (name.includes('phone')) return faker.phone.number();
|
|
93
|
+
if (name.includes('address')) return faker.location.streetAddress();
|
|
94
|
+
if (name.includes('city')) return faker.location.city();
|
|
95
|
+
if (name.includes('country')) return faker.location.country();
|
|
96
|
+
if (name.includes('description')) return faker.lorem.paragraph();
|
|
97
|
+
return faker.lorem.words(Math.floor(Math.random() * 3) + 1);
|
|
98
|
+
|
|
99
|
+
case 'integer':
|
|
100
|
+
if (name.includes('age')) return faker.number.int({ min: 1, max: 120 });
|
|
101
|
+
return faker.number.int({ min: 1, max: 1000 });
|
|
102
|
+
|
|
103
|
+
case 'float':
|
|
104
|
+
case 'decimal':
|
|
105
|
+
return faker.number.float({ min: 0, max: 1000, precision: 0.01 });
|
|
106
|
+
|
|
107
|
+
case 'boolean':
|
|
108
|
+
return faker.datatype.boolean();
|
|
109
|
+
|
|
110
|
+
case 'date':
|
|
111
|
+
return faker.date.past().toISOString();
|
|
112
|
+
|
|
113
|
+
case 'uuid':
|
|
114
|
+
return faker.string.uuid();
|
|
115
|
+
|
|
116
|
+
case 'html':
|
|
117
|
+
return `<p>${faker.lorem.sentence()}</p>`;
|
|
118
|
+
|
|
119
|
+
default:
|
|
120
|
+
return faker.lorem.word();
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
// Main execution
|
|
126
|
+
if (require.main === module) {
|
|
127
|
+
const generator = new {{DATASET_CLASS_NAME}}Generator();
|
|
128
|
+
|
|
129
|
+
generator.generateAll()
|
|
130
|
+
.then(() => {
|
|
131
|
+
console.log('✅ Script completed successfully');
|
|
132
|
+
process.exit(0);
|
|
133
|
+
})
|
|
134
|
+
.catch((error) => {
|
|
135
|
+
console.error('❌ Script failed:', error);
|
|
136
|
+
process.exit(1);
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
|
|
140
140
|
export { {{DATASET_CLASS_NAME}}Generator };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
{"id": "69bda24e-2893-4950-a4ef-190388878123", "street": "123 Main Street", "zipCode": "10001", "country": "United States"}
|
|
2
|
-
{"street": "456 Oak Avenue", "zipCode": "90210", "country": "Portugal"}
|
|
3
|
-
{"street": "789 Pine Boulevard", "zipCode": "60601", "country": "Norway"}
|
|
1
|
+
{"id": "69bda24e-2893-4950-a4ef-190388878123", "street": "123 Main Street", "zipCode": "10001", "country": "United States"}
|
|
2
|
+
{"street": "456 Oak Avenue", "zipCode": "90210", "country": "Portugal"}
|
|
3
|
+
{"street": "789 Pine Boulevard", "zipCode": "60601", "country": "Norway"}
|
|
4
4
|
{"street": "321 Elm Drive", "zipCode": "30309", "country": "Zimbabwe"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
{"name": "SlingrApp", "version": "01.00.01", "description": "A comprehensive application framework for building modern web applications", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
2
|
-
{"name": "TestApp.Beta", "version": "00.05.12", "description": "A testing application used for quality assurance and validation purposes", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878402"}}
|
|
3
|
-
{"name": "ProductionApp", "version": "02.15.03", "description": "The main production application serving thousands of users daily", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
4
|
-
{"name": "Analytics.Dashboard", "version": "01.08.07", "description": "A powerful analytics dashboard for monitoring application metrics and performance", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
1
|
+
{"name": "SlingrApp", "version": "01.00.01", "description": "A comprehensive application framework for building modern web applications", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
2
|
+
{"name": "TestApp.Beta", "version": "00.05.12", "description": "A testing application used for quality assurance and validation purposes", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878402"}}
|
|
3
|
+
{"name": "ProductionApp", "version": "02.15.03", "description": "The main production application serving thousands of users daily", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
4
|
+
{"name": "Analytics.Dashboard", "version": "01.08.07", "description": "A powerful analytics dashboard for monitoring application metrics and performance", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
5
5
|
{"name": "AdminPanel", "version": "03.02.11", "description": "Administrative panel for managing users, permissions, and system configurations", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878402"}}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
{"name": "AdminTech Systems", "ceo": {"firstName": "Sarah", "lastName": "Davis", "email": "sarah.davis@admintech.com", "age": 42, "phoneNumber": "+1222333444", "additionalInfo": "<p>CEO and Systems Administrator</p>", "isActive": true}}
|
|
2
|
-
{"id":"69bda24e-2893-4950-a4ef-190388878401", "name": "TechCorp Solutions", "ceo": {"firstName": "Robert", "lastName": "Johnson", "email": "robert.johnson@example.com", "age": 45, "phoneNumber": "+1987654321", "additionalInfo": "<p>CEO and Founder</p>", "isActive": true}}
|
|
3
|
-
{"id":"69bda24e-2893-4950-a4ef-190388878402", "name": "DataFlow Analytics", "ceo": {"firstName": "Michael", "lastName": "Chen", "email": "michael.chen@dataflow.com", "age": 38, "phoneNumber": "+1333444555", "additionalInfo": "<p>CEO and Data Architect</p>", "isActive": true}}
|
|
1
|
+
{"name": "AdminTech Systems", "ceo": {"firstName": "Sarah", "lastName": "Davis", "email": "sarah.davis@admintech.com", "age": 42, "phoneNumber": "+1222333444", "additionalInfo": "<p>CEO and Systems Administrator</p>", "isActive": true}}
|
|
2
|
+
{"id":"69bda24e-2893-4950-a4ef-190388878401", "name": "TechCorp Solutions", "ceo": {"firstName": "Robert", "lastName": "Johnson", "email": "robert.johnson@example.com", "age": 45, "phoneNumber": "+1987654321", "additionalInfo": "<p>CEO and Founder</p>", "isActive": true}}
|
|
3
|
+
{"id":"69bda24e-2893-4950-a4ef-190388878402", "name": "DataFlow Analytics", "ceo": {"firstName": "Michael", "lastName": "Chen", "email": "michael.chen@dataflow.com", "age": 38, "phoneNumber": "+1333444555", "additionalInfo": "<p>CEO and Data Architect</p>", "isActive": true}}
|
|
4
4
|
{"name": "MainStreet Enterprises", "ceo": {"firstName": "David", "lastName": "Wilson", "email": "david.wilson@mainstreet.com", "age": 48, "phoneNumber": "+1555987654", "additionalInfo": "<p>CEO and Founder of MainStreet Enterprises</p>", "isActive": true}, "address": {"street": "Calle Falsa 216", "zipCode": "28080", "country": "Spain"}}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
{"firstName": "John", "lastName": "Doe", "email": "john.doe@example.com", "age": 25, "phoneNumber": "+1234567890", "additionalInfo": "<p>Senior Developer</p>", "isActive": true}
|
|
2
|
-
{"firstName": "Jane", "lastName": "Smith", "email": "jane.smith@example.com", "age": 16, "parentEmail": "parent.smith@example.com", "additionalInfo": "<p>Student</p>", "isActive": true}
|
|
1
|
+
{"firstName": "John", "lastName": "Doe", "email": "john.doe@example.com", "age": 25, "phoneNumber": "+1234567890", "additionalInfo": "<p>Senior Developer</p>", "isActive": true}
|
|
2
|
+
{"firstName": "Jane", "lastName": "Smith", "email": "jane.smith@example.com", "age": 16, "parentEmail": "parent.smith@example.com", "additionalInfo": "<p>Student</p>", "isActive": true}
|
|
3
3
|
{"firstName": "Alice", "lastName": "Johnson", "email": "alice.johnson@mainstreet.com", "age": 32, "phoneNumber": "+1555123456", "additionalInfo": "<p>Business Owner and Entrepreneur</p>", "isActive": true, "address": {"street": "21 Mulberry Street", "zipCode": "10001", "country": "United States"}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"firstName":"System","lastName":"User","email":"sys@app.com","password":"$2b$10$thG1Wml1rjNDmxwPnlMxeOa.X6GyWUvdWBKB8uVSiHsIHOdoDu2oC","roles":["system"],"status":"active"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Generate realistic test data for all models with appropriate field values. For relationships, distribute references evenly across related records. Use realistic and professional data that respects all field constraints and validation rules.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
{"id": "69bda24e-2893-4950-a4ef-190388878123", "street": "123 Main Street", "zipCode": "10001", "country": "United States"}
|
|
2
|
-
{"street": "456 Oak Avenue", "zipCode": "90210", "country": "Portugal"}
|
|
3
|
-
{"street": "789 Pine Boulevard", "zipCode": "60601", "country": "Norway"}
|
|
1
|
+
{"id": "69bda24e-2893-4950-a4ef-190388878123", "street": "123 Main Street", "zipCode": "10001", "country": "United States"}
|
|
2
|
+
{"street": "456 Oak Avenue", "zipCode": "90210", "country": "Portugal"}
|
|
3
|
+
{"street": "789 Pine Boulevard", "zipCode": "60601", "country": "Norway"}
|
|
4
4
|
{"street": "321 Elm Drive", "zipCode": "30309", "country": "Zimbabwe"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
{"name": "SlingrApp", "version": "01.00.01", "description": "A comprehensive application framework for building modern web applications", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
2
|
-
{"name": "TestApp.Beta", "version": "00.05.12", "description": "A testing application used for quality assurance and validation purposes", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878402"}}
|
|
3
|
-
{"name": "ProductionApp", "version": "02.15.03", "description": "The main production application serving thousands of users daily", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
4
|
-
{"name": "Analytics.Dashboard", "version": "01.08.07", "description": "A powerful analytics dashboard for monitoring application metrics and performance", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
1
|
+
{"name": "SlingrApp", "version": "01.00.01", "description": "A comprehensive application framework for building modern web applications", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
2
|
+
{"name": "TestApp.Beta", "version": "00.05.12", "description": "A testing application used for quality assurance and validation purposes", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878402"}}
|
|
3
|
+
{"name": "ProductionApp", "version": "02.15.03", "description": "The main production application serving thousands of users daily", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
4
|
+
{"name": "Analytics.Dashboard", "version": "01.08.07", "description": "A powerful analytics dashboard for monitoring application metrics and performance", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878401"}}
|
|
5
5
|
{"name": "AdminPanel", "version": "03.02.11", "description": "Administrative panel for managing users, permissions, and system configurations", "ownerCompany": {"id":"69bda24e-2893-4950-a4ef-190388878402"}}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
{"name": "AdminTech Systems", "ceo": {"firstName": "Sarah", "lastName": "Davis", "email": "sarah.davis@admintech.com", "age": 42, "phoneNumber": "+1222333444", "additionalInfo": "<p>CEO and Systems Administrator</p>", "isActive": true}}
|
|
2
|
-
{"id":"69bda24e-2893-4950-a4ef-190388878401", "name": "TechCorp Solutions", "ceo": {"firstName": "Robert", "lastName": "Johnson", "email": "robert.johnson@example.com", "age": 45, "phoneNumber": "+1987654321", "additionalInfo": "<p>CEO and Founder</p>", "isActive": true}}
|
|
3
|
-
{"id":"69bda24e-2893-4950-a4ef-190388878402", "name": "DataFlow Analytics", "ceo": {"firstName": "Michael", "lastName": "Chen", "email": "michael.chen@dataflow.com", "age": 38, "phoneNumber": "+1333444555", "additionalInfo": "<p>CEO and Data Architect</p>", "isActive": true}}
|
|
1
|
+
{"name": "AdminTech Systems", "ceo": {"firstName": "Sarah", "lastName": "Davis", "email": "sarah.davis@admintech.com", "age": 42, "phoneNumber": "+1222333444", "additionalInfo": "<p>CEO and Systems Administrator</p>", "isActive": true}}
|
|
2
|
+
{"id":"69bda24e-2893-4950-a4ef-190388878401", "name": "TechCorp Solutions", "ceo": {"firstName": "Robert", "lastName": "Johnson", "email": "robert.johnson@example.com", "age": 45, "phoneNumber": "+1987654321", "additionalInfo": "<p>CEO and Founder</p>", "isActive": true}}
|
|
3
|
+
{"id":"69bda24e-2893-4950-a4ef-190388878402", "name": "DataFlow Analytics", "ceo": {"firstName": "Michael", "lastName": "Chen", "email": "michael.chen@dataflow.com", "age": 38, "phoneNumber": "+1333444555", "additionalInfo": "<p>CEO and Data Architect</p>", "isActive": true}}
|
|
4
4
|
{"name": "MainStreet Enterprises", "ceo": {"firstName": "David", "lastName": "Wilson", "email": "david.wilson@mainstreet.com", "age": 48, "phoneNumber": "+1555987654", "additionalInfo": "<p>CEO and Founder of MainStreet Enterprises</p>", "isActive": true}, "address": {"street": "Calle Falsa 216", "zipCode": "28080", "country": "Spain"}}
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
{"firstName": "John", "lastName": "Doe", "email": "john.doe@example.com", "age": 25, "phoneNumber": "+1234567890", "additionalInfo": "<p>Senior Developer</p>", "isActive": true}
|
|
2
|
-
{"firstName": "Jane", "lastName": "Smith", "email": "jane.smith@example.com", "age": 16, "parentEmail": "parent.smith@example.com", "additionalInfo": "<p>Student</p>", "isActive": true}
|
|
1
|
+
{"firstName": "John", "lastName": "Doe", "email": "john.doe@example.com", "age": 25, "phoneNumber": "+1234567890", "additionalInfo": "<p>Senior Developer</p>", "isActive": true}
|
|
2
|
+
{"firstName": "Jane", "lastName": "Smith", "email": "jane.smith@example.com", "age": 16, "parentEmail": "parent.smith@example.com", "additionalInfo": "<p>Student</p>", "isActive": true}
|
|
3
3
|
{"firstName": "Alice", "lastName": "Johnson", "email": "alice.johnson@mainstreet.com", "age": 32, "phoneNumber": "+1555123456", "additionalInfo": "<p>Business Owner and Entrepreneur</p>", "isActive": true, "address": {"street": "21 Mulberry Street", "zipCode": "10001", "country": "United States"}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"firstName":"System","lastName":"User","email":"sys@app.com","password":"$2b$10$thG1Wml1rjNDmxwPnlMxeOa.X6GyWUvdWBKB8uVSiHsIHOdoDu2oC","roles":["system"],"status":"active"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Generate realistic test data for all models with appropriate field values. For relationships, distribute references evenly across related records. Use realistic and professional data that respects all field constraints and validation rules.
|