@simitgroup/simpleapp-generator 1.6.7-e-alpha → 1.6.7-f-alpha
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/ReleaseNote.md +4 -0
- package/dist/framework.d.ts +1 -0
- package/dist/framework.d.ts.map +1 -1
- package/dist/framework.js +7 -1
- package/dist/framework.js.map +1 -1
- package/dist/generate.d.ts.map +1 -1
- package/dist/generate.js +85 -9
- package/dist/generate.js.map +1 -1
- package/dist/index.js +9 -0
- package/dist/index.js.map +1 -1
- package/dist/type.d.ts +6 -0
- package/dist/type.d.ts.map +1 -1
- package/dist/type.js.map +1 -1
- package/package.json +1 -1
- package/reset-install.sh +2 -2
- package/src/framework.ts +7 -0
- package/src/generate.ts +118 -2
- package/src/index.ts +10 -0
- package/src/type.ts +6 -0
- package/templates/basic/miniApi/resource.controller.ts.eta +139 -0
- package/templates/basic/miniApi/resource.module.ts.eta +16 -0
- package/templates/basic/miniApi/resource.service.ts.eta +109 -0
- package/templates/basic/miniAppJsSdk/resource-bridge.service.ts.eta +3 -6
- package/templates/basic/miniAppStreamlitSdk/resource-bridge.service.ts.eta +0 -4
- package/templates/basic/nuxt/resource-bridge.editable.service.ts.eta +0 -8
- package/templates/basic/nuxt/resource-bridge.service.ts.eta +5 -5
- package/templates/miniApi/src/modules/public/constants/api-scopes.ts.eta +76 -0
- package/templates/miniApi/src/modules/public/resources/resource.module.ts.eta +46 -0
- package/templates/miniAppJsSdk/src/services/bridge-resource-accessor.service.ts.eta +1 -9
- package/templates/miniAppStreamlitSdk/simtrain_eco_mini_app_streamlit_sdk/sdk.py.eta +0 -8
- package/templates/nuxt/simpleapp/generate/features/miniApp/bridge/constants/resource.constant.ts.eta +0 -8
- package/templates/nuxt/simpleapp/generate/features/miniApp/bridge/services/bridge-resource-accessor.service.ts.eta +0 -8
- package/templates/nuxt/simpleapp/generate/features/miniApp/bridge/types/bridge.type.ts.eta +20 -0
- package/templates/nuxt/simpleapp/generate/features/miniApp/bridge/types/resource-mapper.type.ts.eta +0 -8
|
@@ -6,15 +6,7 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
<%
|
|
9
|
-
|
|
10
|
-
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
const camelToKebab = (value) => {
|
|
14
|
-
return value.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase();
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
const getMiniAppInfo = (module) => {
|
|
9
|
+
const getMiniAppInfo = (module) => {
|
|
18
10
|
const config = module.schema['x-simpleapp-config'];
|
|
19
11
|
const resourceName = config?.resourceName ?? config.documentName;
|
|
20
12
|
|
|
@@ -1,12 +1,4 @@
|
|
|
1
1
|
<%
|
|
2
|
-
const upperFirstCase = (value) => {
|
|
3
|
-
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
const camelToKebab = (value) => {
|
|
7
|
-
return value.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase();
|
|
8
|
-
}
|
|
9
|
-
|
|
10
2
|
const camelToSnake = (value) => {
|
|
11
3
|
return value.replace(/([a-z])([A-Z])/g, "$1_$2").toLowerCase();
|
|
12
4
|
}
|
package/templates/nuxt/simpleapp/generate/features/miniApp/bridge/constants/resource.constant.ts.eta
CHANGED
|
@@ -6,14 +6,6 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
<%
|
|
9
|
-
const upperFirstCase = (value) => {
|
|
10
|
-
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
const camelToKebab = (value) => {
|
|
14
|
-
return value.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase();
|
|
15
|
-
}
|
|
16
|
-
|
|
17
9
|
const getMiniAppInfo = (module) => {
|
|
18
10
|
const config = module.schema['x-simpleapp-config'];
|
|
19
11
|
const resourceName = config?.resourceName ?? config.documentName;
|
|
@@ -6,14 +6,6 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
<%
|
|
9
|
-
const upperFirstCase = (value) => {
|
|
10
|
-
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
const camelToKebab = (value) => {
|
|
14
|
-
return value.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase();
|
|
15
|
-
}
|
|
16
|
-
|
|
17
9
|
const getMiniAppInfo = (module) => {
|
|
18
10
|
const config = module.schema['x-simpleapp-config'];
|
|
19
11
|
const resourceName = config?.resourceName ?? config.documentName;
|
|
@@ -79,3 +79,23 @@ export type MiniAppBridgeMessageApiResponse<TData> = {
|
|
|
79
79
|
export type MiniAppBridgeMessageInitResponse = {
|
|
80
80
|
type: typeof MINI_APP_BRIDGE_MESSAGES.INIT_RESPONSE;
|
|
81
81
|
};
|
|
82
|
+
|
|
83
|
+
export type MiniAppApiListParam = {
|
|
84
|
+
fields?: string[];
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* Same as Mongo DB filter
|
|
88
|
+
*/
|
|
89
|
+
filters?: {
|
|
90
|
+
[key: string]: any;
|
|
91
|
+
};
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Same as Mongo DB sort
|
|
95
|
+
*/
|
|
96
|
+
sorts?:
|
|
97
|
+
| {
|
|
98
|
+
[key: string]: any;
|
|
99
|
+
}
|
|
100
|
+
| string[][];
|
|
101
|
+
};
|
package/templates/nuxt/simpleapp/generate/features/miniApp/bridge/types/resource-mapper.type.ts.eta
CHANGED
|
@@ -6,14 +6,6 @@
|
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
8
|
<%
|
|
9
|
-
const upperFirstCase = (value) => {
|
|
10
|
-
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
const camelToKebab = (value) => {
|
|
14
|
-
return value.replace(/([a-z])([A-Z])/g, "$1-$2").toLowerCase();
|
|
15
|
-
}
|
|
16
|
-
|
|
17
9
|
const getMiniAppInfo = (module) => {
|
|
18
10
|
const config = module.schema['x-simpleapp-config'];
|
|
19
11
|
const resourceName = config?.resourceName ?? config.documentName;
|