@solidstarters/create-solid-app 1.2.13 → 1.2.14
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/package.json +1 -1
- package/templates/nest-template/package-lock.json +121 -8
- package/templates/nest-template/package.json +2 -2
- package/templates/next-template/app/admin/core/[moduleName]/[modelName]/form/[id]/page.tsx +4 -79
- package/templates/next-template/app/admin/core/[moduleName]/[modelName]/kanban/page.tsx +1 -6
- package/templates/next-template/app/admin/core/[moduleName]/[modelName]/list/page.tsx +1 -6
- package/templates/next-template/app/admin/layout.tsx +5 -54
- package/templates/next-template/app/admin/page.tsx +3 -4
- package/templates/next-template/app/admin/settings/app-settings/page.tsx +11 -0
- package/templates/next-template/app/admin/settings/authentication-settings/page.tsx +10 -0
- package/templates/next-template/app/admin/settings/misc-settings/page.tsx +10 -0
- package/templates/next-template/app/api/auth/[...nextauth]/route.ts +3 -219
- package/templates/next-template/app/auth/confirm-forgot-password/page.tsx +1 -6
- package/templates/next-template/app/auth/initiate-forgot-password-thank-you/page.tsx +2 -37
- package/templates/next-template/app/auth/initiate-google-oauth/page.tsx +9 -0
- package/templates/next-template/app/auth/initiate-login/page.tsx +13 -0
- package/templates/next-template/app/auth/initiate-register/page.tsx +14 -0
- package/templates/next-template/app/auth/layout.tsx +6 -125
- package/templates/next-template/app/globals.css +275 -41
- package/templates/next-template/app/layout.tsx +4 -5
- package/templates/next-template/app/solid-global.css +2 -0
- package/templates/next-template/next-env.d.ts +1 -1
- package/templates/next-template/package-lock.json +6 -6
- package/templates/next-template/package.json +3 -3
- package/templates/next-template/public/favicon.ico +0 -0
- package/templates/next-template/public/images/Navigation/settings.png +0 -0
- package/templates/next-template/public/styles/layout/_main.scss +23 -4
- package/templates/next-template/public/themes/solid-dark-purple/theme.css +13 -3
- package/templates/next-template/public/themes/solid-light-purple/theme.css +68 -15
- package/templates/next-template/redux/store.ts +5 -3
package/package.json
CHANGED
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"@nestjs/serve-static": "^4.0.2",
|
|
28
28
|
"@nestjs/swagger": "^7.2.0",
|
|
29
29
|
"@nestjs/typeorm": "^10.0.1",
|
|
30
|
-
"@solidstarters/solid-core": "^1.2.
|
|
30
|
+
"@solidstarters/solid-core": "^1.2.24",
|
|
31
31
|
"@types/luxon": "^3.4.2",
|
|
32
32
|
"amqplib": "^0.10.4",
|
|
33
33
|
"axios": "^1.7.0",
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"devDependencies": {
|
|
68
68
|
"@nestjs/cli": "^10.0.0",
|
|
69
69
|
"@nestjs/testing": "^10.0.0",
|
|
70
|
-
"@solidstarters/solid-code-builder": "^1.0.
|
|
70
|
+
"@solidstarters/solid-code-builder": "^1.0.13",
|
|
71
71
|
"@types/express": "^4.17.17",
|
|
72
72
|
"@types/hapi__joi": "^17.1.12",
|
|
73
73
|
"@types/jest": "^29.5.2",
|
|
@@ -4424,9 +4424,9 @@
|
|
|
4424
4424
|
}
|
|
4425
4425
|
},
|
|
4426
4426
|
"node_modules/@solidstarters/solid-code-builder": {
|
|
4427
|
-
"version": "1.0.
|
|
4428
|
-
"resolved": "https://registry.npmjs.org/@solidstarters/solid-code-builder/-/solid-code-builder-1.0.
|
|
4429
|
-
"integrity": "sha512-
|
|
4427
|
+
"version": "1.0.13",
|
|
4428
|
+
"resolved": "https://registry.npmjs.org/@solidstarters/solid-code-builder/-/solid-code-builder-1.0.13.tgz",
|
|
4429
|
+
"integrity": "sha512-JIF7IdugJyucIumAR/NB8SRC1umSSCzqeNK1yhcI6BePaA5T3RIqeZhJ1Ys5xNpfvcp7pMK5A1KdiMTvNOWSHA==",
|
|
4430
4430
|
"dev": true,
|
|
4431
4431
|
"license": "MIT",
|
|
4432
4432
|
"dependencies": {
|
|
@@ -4469,9 +4469,9 @@
|
|
|
4469
4469
|
}
|
|
4470
4470
|
},
|
|
4471
4471
|
"node_modules/@solidstarters/solid-core": {
|
|
4472
|
-
"version": "1.2.
|
|
4473
|
-
"resolved": "https://registry.npmjs.org/@solidstarters/solid-core/-/solid-core-1.2.
|
|
4474
|
-
"integrity": "sha512-
|
|
4472
|
+
"version": "1.2.24",
|
|
4473
|
+
"resolved": "https://registry.npmjs.org/@solidstarters/solid-core/-/solid-core-1.2.24.tgz",
|
|
4474
|
+
"integrity": "sha512-RBXssYLq68kHIh8YBabp6xK77SOJKVIjoR5ljMAfU+QhbMe1fY2pJJW+r/ZSjEcYPt4pdj3Z7y5920xFSLNHXA==",
|
|
4475
4475
|
"license": "ISC",
|
|
4476
4476
|
"dependencies": {
|
|
4477
4477
|
"@angular-devkit/core": "^18.0.3",
|
|
@@ -4492,6 +4492,7 @@
|
|
|
4492
4492
|
"luxon": "^3.4.4",
|
|
4493
4493
|
"mailgen": "^2.0.28",
|
|
4494
4494
|
"mongoose": "^8.7.0",
|
|
4495
|
+
"mysql2": "^3.13.0",
|
|
4495
4496
|
"nodemailer": "^6.9.13",
|
|
4496
4497
|
"passport": "^0.7.0",
|
|
4497
4498
|
"passport-google-oauth2": "^0.2.0",
|
|
@@ -5830,6 +5831,15 @@
|
|
|
5830
5831
|
"integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==",
|
|
5831
5832
|
"license": "MIT"
|
|
5832
5833
|
},
|
|
5834
|
+
"node_modules/aws-ssl-profiles": {
|
|
5835
|
+
"version": "1.1.2",
|
|
5836
|
+
"resolved": "https://registry.npmjs.org/aws-ssl-profiles/-/aws-ssl-profiles-1.1.2.tgz",
|
|
5837
|
+
"integrity": "sha512-NZKeq9AfyQvEeNlN0zSYAaWrmBffJh3IELMZfRpJVWgrpEbtEpnjvzqBPf+mxoI287JohRDoa+/nsfqqiZmF6g==",
|
|
5838
|
+
"license": "MIT",
|
|
5839
|
+
"engines": {
|
|
5840
|
+
"node": ">= 6.0.0"
|
|
5841
|
+
}
|
|
5842
|
+
},
|
|
5833
5843
|
"node_modules/axios": {
|
|
5834
5844
|
"version": "1.7.9",
|
|
5835
5845
|
"resolved": "https://registry.npmjs.org/axios/-/axios-1.7.9.tgz",
|
|
@@ -9011,6 +9021,15 @@
|
|
|
9011
9021
|
"node": ">=10"
|
|
9012
9022
|
}
|
|
9013
9023
|
},
|
|
9024
|
+
"node_modules/generate-function": {
|
|
9025
|
+
"version": "2.3.1",
|
|
9026
|
+
"resolved": "https://registry.npmjs.org/generate-function/-/generate-function-2.3.1.tgz",
|
|
9027
|
+
"integrity": "sha512-eeB5GfMNeevm/GRYq20ShmsaGcmI81kIX2K9XQx5miC8KdHaC6Jm0qQ8ZNeGOi7wYB8OsdxKs+Y2oVuTFuVwKQ==",
|
|
9028
|
+
"license": "MIT",
|
|
9029
|
+
"dependencies": {
|
|
9030
|
+
"is-property": "^1.0.2"
|
|
9031
|
+
}
|
|
9032
|
+
},
|
|
9014
9033
|
"node_modules/generic-pool": {
|
|
9015
9034
|
"version": "3.9.0",
|
|
9016
9035
|
"resolved": "https://registry.npmjs.org/generic-pool/-/generic-pool-3.9.0.tgz",
|
|
@@ -9745,6 +9764,12 @@
|
|
|
9745
9764
|
"node": ">=8"
|
|
9746
9765
|
}
|
|
9747
9766
|
},
|
|
9767
|
+
"node_modules/is-property": {
|
|
9768
|
+
"version": "1.0.2",
|
|
9769
|
+
"resolved": "https://registry.npmjs.org/is-property/-/is-property-1.0.2.tgz",
|
|
9770
|
+
"integrity": "sha512-Ks/IoX00TtClbGQr4TWXemAnktAQvYB7HzcCxDGqEZU6oCmb2INHuOoKxbtR+HFkmYWBKv/dOZtGRiAjDhj92g==",
|
|
9771
|
+
"license": "MIT"
|
|
9772
|
+
},
|
|
9748
9773
|
"node_modules/is-stream": {
|
|
9749
9774
|
"version": "2.0.1",
|
|
9750
9775
|
"resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz",
|
|
@@ -11064,6 +11089,12 @@
|
|
|
11064
11089
|
"node": ">=0.1.90"
|
|
11065
11090
|
}
|
|
11066
11091
|
},
|
|
11092
|
+
"node_modules/long": {
|
|
11093
|
+
"version": "5.3.1",
|
|
11094
|
+
"resolved": "https://registry.npmjs.org/long/-/long-5.3.1.tgz",
|
|
11095
|
+
"integrity": "sha512-ka87Jz3gcx/I7Hal94xaN2tZEOPoUOEVftkQqZx2EeQRN7LGdfLlI3FvZ+7WDplm+vK2Urx9ULrvSowtdCieng==",
|
|
11096
|
+
"license": "Apache-2.0"
|
|
11097
|
+
},
|
|
11067
11098
|
"node_modules/longest": {
|
|
11068
11099
|
"version": "1.0.1",
|
|
11069
11100
|
"resolved": "https://registry.npmjs.org/longest/-/longest-1.0.1.tgz",
|
|
@@ -11083,6 +11114,21 @@
|
|
|
11083
11114
|
"yallist": "^3.0.2"
|
|
11084
11115
|
}
|
|
11085
11116
|
},
|
|
11117
|
+
"node_modules/lru.min": {
|
|
11118
|
+
"version": "1.1.2",
|
|
11119
|
+
"resolved": "https://registry.npmjs.org/lru.min/-/lru.min-1.1.2.tgz",
|
|
11120
|
+
"integrity": "sha512-Nv9KddBcQSlQopmBHXSsZVY5xsdlZkdH/Iey0BlcBYggMd4two7cZnKOK9vmy3nY0O5RGH99z1PCeTpPqszUYg==",
|
|
11121
|
+
"license": "MIT",
|
|
11122
|
+
"engines": {
|
|
11123
|
+
"bun": ">=1.0.0",
|
|
11124
|
+
"deno": ">=1.30.0",
|
|
11125
|
+
"node": ">=8.0.0"
|
|
11126
|
+
},
|
|
11127
|
+
"funding": {
|
|
11128
|
+
"type": "github",
|
|
11129
|
+
"url": "https://github.com/sponsors/wellwelwel"
|
|
11130
|
+
}
|
|
11131
|
+
},
|
|
11086
11132
|
"node_modules/luxon": {
|
|
11087
11133
|
"version": "3.5.0",
|
|
11088
11134
|
"resolved": "https://registry.npmjs.org/luxon/-/luxon-3.5.0.tgz",
|
|
@@ -11614,6 +11660,38 @@
|
|
|
11614
11660
|
"integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==",
|
|
11615
11661
|
"license": "ISC"
|
|
11616
11662
|
},
|
|
11663
|
+
"node_modules/mysql2": {
|
|
11664
|
+
"version": "3.13.0",
|
|
11665
|
+
"resolved": "https://registry.npmjs.org/mysql2/-/mysql2-3.13.0.tgz",
|
|
11666
|
+
"integrity": "sha512-M6DIQjTqKeqXH5HLbLMxwcK5XfXHw30u5ap6EZmu7QVmcF/gnh2wS/EOiQ4MTbXz/vQeoXrmycPlVRM00WSslg==",
|
|
11667
|
+
"license": "MIT",
|
|
11668
|
+
"dependencies": {
|
|
11669
|
+
"aws-ssl-profiles": "^1.1.1",
|
|
11670
|
+
"denque": "^2.1.0",
|
|
11671
|
+
"generate-function": "^2.3.1",
|
|
11672
|
+
"iconv-lite": "^0.6.3",
|
|
11673
|
+
"long": "^5.2.1",
|
|
11674
|
+
"lru.min": "^1.0.0",
|
|
11675
|
+
"named-placeholders": "^1.1.3",
|
|
11676
|
+
"seq-queue": "^0.0.5",
|
|
11677
|
+
"sqlstring": "^2.3.2"
|
|
11678
|
+
},
|
|
11679
|
+
"engines": {
|
|
11680
|
+
"node": ">= 8.0"
|
|
11681
|
+
}
|
|
11682
|
+
},
|
|
11683
|
+
"node_modules/mysql2/node_modules/iconv-lite": {
|
|
11684
|
+
"version": "0.6.3",
|
|
11685
|
+
"resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz",
|
|
11686
|
+
"integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==",
|
|
11687
|
+
"license": "MIT",
|
|
11688
|
+
"dependencies": {
|
|
11689
|
+
"safer-buffer": ">= 2.1.2 < 3.0.0"
|
|
11690
|
+
},
|
|
11691
|
+
"engines": {
|
|
11692
|
+
"node": ">=0.10.0"
|
|
11693
|
+
}
|
|
11694
|
+
},
|
|
11617
11695
|
"node_modules/mz": {
|
|
11618
11696
|
"version": "2.7.0",
|
|
11619
11697
|
"resolved": "https://registry.npmjs.org/mz/-/mz-2.7.0.tgz",
|
|
@@ -11625,6 +11703,27 @@
|
|
|
11625
11703
|
"thenify-all": "^1.0.0"
|
|
11626
11704
|
}
|
|
11627
11705
|
},
|
|
11706
|
+
"node_modules/named-placeholders": {
|
|
11707
|
+
"version": "1.1.3",
|
|
11708
|
+
"resolved": "https://registry.npmjs.org/named-placeholders/-/named-placeholders-1.1.3.tgz",
|
|
11709
|
+
"integrity": "sha512-eLoBxg6wE/rZkJPhU/xRX1WTpkFEwDJEN96oxFrTsqBdbT5ec295Q+CoHrL9IT0DipqKhmGcaZmwOt8OON5x1w==",
|
|
11710
|
+
"license": "MIT",
|
|
11711
|
+
"dependencies": {
|
|
11712
|
+
"lru-cache": "^7.14.1"
|
|
11713
|
+
},
|
|
11714
|
+
"engines": {
|
|
11715
|
+
"node": ">=12.0.0"
|
|
11716
|
+
}
|
|
11717
|
+
},
|
|
11718
|
+
"node_modules/named-placeholders/node_modules/lru-cache": {
|
|
11719
|
+
"version": "7.18.3",
|
|
11720
|
+
"resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-7.18.3.tgz",
|
|
11721
|
+
"integrity": "sha512-jumlc0BIUrS3qJGgIkWZsyfAM7NCWiBcCDhnd+3NNM5KbBmLTgHVfWBcg6W+rLUsIpzpERPsvwUP7CckAQSOoA==",
|
|
11722
|
+
"license": "ISC",
|
|
11723
|
+
"engines": {
|
|
11724
|
+
"node": ">=12"
|
|
11725
|
+
}
|
|
11726
|
+
},
|
|
11628
11727
|
"node_modules/natural-compare": {
|
|
11629
11728
|
"version": "1.4.0",
|
|
11630
11729
|
"resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz",
|
|
@@ -13622,6 +13721,11 @@
|
|
|
13622
13721
|
"node": ">= 0.8"
|
|
13623
13722
|
}
|
|
13624
13723
|
},
|
|
13724
|
+
"node_modules/seq-queue": {
|
|
13725
|
+
"version": "0.0.5",
|
|
13726
|
+
"resolved": "https://registry.npmjs.org/seq-queue/-/seq-queue-0.0.5.tgz",
|
|
13727
|
+
"integrity": "sha512-hr3Wtp/GZIc/6DAGPDcV4/9WoZhjrkXsi5B/07QgX8tsdc6ilr7BFM6PM6rbdAX1kFSDYeZGLipIZZKyQP0O5Q=="
|
|
13728
|
+
},
|
|
13625
13729
|
"node_modules/serialize-javascript": {
|
|
13626
13730
|
"version": "6.0.2",
|
|
13627
13731
|
"resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.2.tgz",
|
|
@@ -13936,6 +14040,15 @@
|
|
|
13936
14040
|
"integrity": "sha512-Oo+0REFV59/rz3gfJNKQiBlwfHaSESl1pcGyABQsnnIfWOFt6JNj5gCog2U6MLZ//IGYD+nA8nI+mTShREReaA==",
|
|
13937
14041
|
"license": "BSD-3-Clause"
|
|
13938
14042
|
},
|
|
14043
|
+
"node_modules/sqlstring": {
|
|
14044
|
+
"version": "2.3.3",
|
|
14045
|
+
"resolved": "https://registry.npmjs.org/sqlstring/-/sqlstring-2.3.3.tgz",
|
|
14046
|
+
"integrity": "sha512-qC9iz2FlN7DQl3+wjwn3802RTyjCx7sDvfQEXchwa6CWOx07/WVfh91gBmQ9fahw8snwGEWU3xGzOt4tFyHLxg==",
|
|
14047
|
+
"license": "MIT",
|
|
14048
|
+
"engines": {
|
|
14049
|
+
"node": ">= 0.6"
|
|
14050
|
+
}
|
|
14051
|
+
},
|
|
13939
14052
|
"node_modules/ssf": {
|
|
13940
14053
|
"version": "0.11.2",
|
|
13941
14054
|
"resolved": "https://registry.npmjs.org/ssf/-/ssf-0.11.2.tgz",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"@nestjs/serve-static": "^4.0.2",
|
|
43
43
|
"@nestjs/swagger": "^7.2.0",
|
|
44
44
|
"@nestjs/typeorm": "^10.0.1",
|
|
45
|
-
"@solidstarters/solid-core": "^1.2.
|
|
45
|
+
"@solidstarters/solid-core": "^1.2.24",
|
|
46
46
|
"@types/luxon": "^3.4.2",
|
|
47
47
|
"amqplib": "^0.10.4",
|
|
48
48
|
"axios": "^1.7.0",
|
|
@@ -79,7 +79,7 @@
|
|
|
79
79
|
"devDependencies": {
|
|
80
80
|
"@nestjs/cli": "^10.0.0",
|
|
81
81
|
"@nestjs/testing": "^10.0.0",
|
|
82
|
-
"@solidstarters/solid-code-builder": "^1.0.
|
|
82
|
+
"@solidstarters/solid-code-builder": "^1.0.13",
|
|
83
83
|
"@types/express": "^4.17.17",
|
|
84
84
|
"@types/hapi__joi": "^17.1.12",
|
|
85
85
|
"@types/jest": "^29.5.2",
|
|
@@ -1,13 +1,5 @@
|
|
|
1
1
|
"use client"
|
|
2
|
-
import {
|
|
3
|
-
import { CreateModel } from "@solidstarters/solid-core-ui";
|
|
4
|
-
import { CreateModule } from "@solidstarters/solid-core-ui";
|
|
5
|
-
import { CreateUser } from "@solidstarters/solid-core-ui";
|
|
6
|
-
import { useGetmodelByIdQuery } from "@solidstarters/solid-core-ui";
|
|
7
|
-
import { useGetmoduleByIdQuery } from "@solidstarters/solid-core-ui";
|
|
8
|
-
import { useGetusersByIdQuery } from "@solidstarters/solid-core-ui";
|
|
9
|
-
import { camelCase, kebabCase } from "change-case";
|
|
10
|
-
import React, { useEffect } from "react";
|
|
2
|
+
import { SolidFormLayouts } from "@solidstarters/solid-core-ui";
|
|
11
3
|
|
|
12
4
|
type SolidViewParams = {
|
|
13
5
|
params: {
|
|
@@ -17,78 +9,11 @@ type SolidViewParams = {
|
|
|
17
9
|
};
|
|
18
10
|
};
|
|
19
11
|
|
|
20
|
-
const page = (
|
|
21
|
-
const { params } = props;
|
|
22
|
-
|
|
23
|
-
const {
|
|
24
|
-
data: modelData,
|
|
25
|
-
error,
|
|
26
|
-
isLoading,
|
|
27
|
-
isError,
|
|
28
|
-
refetch
|
|
29
|
-
} = useGetmodelByIdQuery(params.id);
|
|
30
|
-
useEffect(() => {
|
|
31
|
-
refetch();
|
|
32
|
-
}, [refetch]);
|
|
33
|
-
|
|
34
|
-
const {
|
|
35
|
-
data: moduleData,
|
|
36
|
-
error: moduleError,
|
|
37
|
-
isLoading: isModuleLoading,
|
|
38
|
-
isError: isModuleError,
|
|
39
|
-
refetch: refetchModule
|
|
40
|
-
} = useGetmoduleByIdQuery(params.id);
|
|
41
|
-
useEffect(() => {
|
|
42
|
-
refetchModule();
|
|
43
|
-
}, [refetchModule]);
|
|
44
|
-
|
|
45
|
-
const {
|
|
46
|
-
data: userData,
|
|
47
|
-
error: usererror,
|
|
48
|
-
isLoading: isuserLoading,
|
|
49
|
-
isError: isuserError,
|
|
50
|
-
refetch: refetchuser
|
|
51
|
-
} = useGetusersByIdQuery(params.id);
|
|
52
|
-
useEffect(() => {
|
|
53
|
-
refetchuser();
|
|
54
|
-
}, [refetchuser]);
|
|
12
|
+
const page = ({ params }: SolidViewParams) => {
|
|
55
13
|
|
|
56
14
|
return (
|
|
57
|
-
<
|
|
58
|
-
{params.modelName === "model-metadata" &&
|
|
59
|
-
// <SolidFormView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
60
|
-
(params.id === "new" ?
|
|
61
|
-
<CreateModel params={params}></CreateModel>
|
|
62
|
-
:
|
|
63
|
-
<CreateModel params={params} data={modelData?.data}></CreateModel>
|
|
64
|
-
)
|
|
65
|
-
}
|
|
66
|
-
{params.modelName === "module-metadata" &&
|
|
67
|
-
// <SolidFormView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
68
|
-
(params.id === "new" ?
|
|
69
|
-
<CreateModule params={params}></CreateModule>
|
|
70
|
-
:
|
|
71
|
-
<CreateModule params={params} data={moduleData?.data}></CreateModule>
|
|
72
|
-
)
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
{params.modelName === "user" &&
|
|
76
|
-
// <SolidFormView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
77
|
-
(params.id === "new" ?
|
|
78
|
-
<CreateUser params={params}></CreateUser>
|
|
79
|
-
:
|
|
80
|
-
<CreateUser params={params} data={userData?.data}></CreateUser>
|
|
81
|
-
)
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
{params.modelName === "field-metadata" &&
|
|
85
|
-
<SolidFormView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
86
|
-
}
|
|
87
|
-
{params.modelName !== "field-metadata" && params.modelName !== "model-metadata" && params.modelName !== "module-metadata" && params.modelName !== "user" &&
|
|
88
|
-
<SolidFormView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
89
|
-
}
|
|
90
|
-
</div>
|
|
15
|
+
<SolidFormLayouts params={params} />
|
|
91
16
|
);
|
|
92
17
|
};
|
|
93
18
|
|
|
94
|
-
export default page;
|
|
19
|
+
export default page;
|
|
@@ -10,13 +10,8 @@ type SolidViewParams = {
|
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
const page = ({ params }: SolidViewParams) => {
|
|
13
|
-
|
|
14
13
|
return (
|
|
15
|
-
|
|
16
|
-
<div className="page-parent-wrapper">
|
|
17
|
-
<SolidKanbanView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
18
|
-
</div>
|
|
19
|
-
</>
|
|
14
|
+
<SolidKanbanView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
20
15
|
);
|
|
21
16
|
};
|
|
22
17
|
|
|
@@ -10,13 +10,8 @@ type SolidViewParams = {
|
|
|
10
10
|
};
|
|
11
11
|
|
|
12
12
|
const page = ({ params }: SolidViewParams) => {
|
|
13
|
-
|
|
14
13
|
return (
|
|
15
|
-
|
|
16
|
-
<div className="page-parent-wrapper">
|
|
17
|
-
<SolidListView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
18
|
-
</div>
|
|
19
|
-
</>
|
|
14
|
+
<SolidListView {...params} embeded={false} modelName={camelCase(params.modelName)} />
|
|
20
15
|
);
|
|
21
16
|
};
|
|
22
17
|
|
|
@@ -1,62 +1,13 @@
|
|
|
1
1
|
"use client"; // This line ensures that the component is rendered on the client side
|
|
2
2
|
|
|
3
|
-
import {
|
|
4
|
-
|
|
5
|
-
import { usePathname, useRouter } from "next/navigation";
|
|
6
|
-
import React, { useEffect, useState } from "react";
|
|
7
|
-
import { Layout, SolidChangeForcePassword } from "@solidstarters/solid-core-ui";
|
|
8
|
-
import { Dialog } from "primereact/dialog";
|
|
9
|
-
import { Divider } from "primereact/divider";
|
|
10
|
-
const AdminLayout = ({ children }: { children: React.ReactNode }) => {
|
|
11
|
-
// const theme = useSelector((state: any) => state.theme.mode);
|
|
12
|
-
const { data: session, status } = useSession();
|
|
13
|
-
const [isForcePasswordChange, setIsForcePasswordChange] = useState(false)
|
|
14
|
-
useEffect(() => {
|
|
15
|
-
// @ts-expect-error: Handling potential case where 'data?.user?.user' might be undefined or null
|
|
16
|
-
if (session?.user?.user?.forcePasswordChange === true) {
|
|
17
|
-
setIsForcePasswordChange(true)
|
|
18
|
-
} else {
|
|
19
|
-
setIsForcePasswordChange(false)
|
|
20
|
-
}
|
|
21
|
-
}, [session])
|
|
22
|
-
const pathname = usePathname();
|
|
23
|
-
const router = useRouter();
|
|
24
|
-
useEffect(() => {
|
|
25
|
-
const handleRouteChange = async () => {
|
|
26
|
-
const session = await getSession(); // Force refetch session on navigation
|
|
27
|
-
if (session?.error === "RefreshAccessTokenError") {
|
|
28
|
-
handleError(["Session Expired. Please Login Again."])
|
|
29
|
-
signOut({ callbackUrl: "/auth/login" });
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
};
|
|
34
|
-
// Listen to routeChangeComplete event
|
|
35
|
-
handleRouteChange()
|
|
36
|
-
|
|
37
|
-
}, [pathname])
|
|
3
|
+
import { AdminLayout } from "@solidstarters/solid-core-ui";
|
|
4
|
+
const layout = ({ children }: { children: React.ReactNode }) => {
|
|
38
5
|
|
|
39
6
|
return (
|
|
40
|
-
<
|
|
41
|
-
{/* <div className={`${process.env.NEXT_PUBLIC_ENABLE_CUSTOM_HEADER_FOOTER == "true" && 'header-margin-top'}`} style={{ minHeight: `${process.env.NEXT_PUBLIC_ENABLE_CUSTOM_HEADER_FOOTER == "true" ? 'calc(100vh - 70px)' : 'calc(100vh)'}` }}> */}
|
|
42
|
-
|
|
43
|
-
{/* <div className="min-h-full max-h-full flex flex-column relative flex-auto overflow-x-auto"> */}
|
|
44
|
-
{/* <DashboardHeader /> */}
|
|
45
|
-
{/* <SolidListingHeader></SolidListingHeader> */}
|
|
46
|
-
{/* {pathname.includes('all') && <ListingHeader />} */}
|
|
47
|
-
{/* <div className="flex flex-column flex-auto" style={{ backgroundColor: '#f6f6f9', padding: '1.5rem 1.5rem 1.5rem', }}> */}
|
|
7
|
+
<AdminLayout>
|
|
48
8
|
{children}
|
|
49
|
-
|
|
50
|
-
{/* </div> */}
|
|
51
|
-
{/* </div> */}
|
|
52
|
-
{isForcePasswordChange &&
|
|
53
|
-
<Dialog header="Change Default Password" visible={isForcePasswordChange} closable={false} draggable={false} style={{ width: '25vw' }} onHide={() => setIsForcePasswordChange(false)}>
|
|
54
|
-
<Divider className="mt-0"/>
|
|
55
|
-
<SolidChangeForcePassword />
|
|
56
|
-
</Dialog>
|
|
57
|
-
}
|
|
58
|
-
</Layout>
|
|
9
|
+
</AdminLayout>
|
|
59
10
|
);
|
|
60
11
|
};
|
|
61
12
|
|
|
62
|
-
export default
|
|
13
|
+
export default layout;
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
"use client";
|
|
2
|
+
import { SolidAdmin } from "@solidstarters/solid-core-ui"
|
|
2
3
|
|
|
3
4
|
const page = () => {
|
|
4
5
|
return (
|
|
5
|
-
<
|
|
6
|
-
<div className="layoutPage">Solid Page</div>
|
|
7
|
-
</div>
|
|
6
|
+
<SolidAdmin />
|
|
8
7
|
);
|
|
9
8
|
};
|
|
10
9
|
|
|
11
|
-
export default page;
|
|
10
|
+
export default page;
|