@khester/create-dynamics-app 3.4.2 → 3.4.3
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 +2 -2
- package/templates/grid-starter/src/core/services/MockApiService.ts +13 -3
- package/templates/host-swap/src/core/services/MockApiService.ts +13 -3
- package/templates/power-pages-island/src/core/services/MockApiService.ts +13 -3
- package/templates/react-custom-page/src/core/services/MockApiService.ts +13 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@khester/create-dynamics-app",
|
|
3
|
-
"version": "3.4.
|
|
3
|
+
"version": "3.4.3",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Unified CLI to scaffold Dynamics 365 / Power Platform artifacts",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"check:published-templates": "node scripts/check-published-template-drift.mjs"
|
|
28
28
|
},
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@dataverse-kit/export-engine": "^1.34.
|
|
30
|
+
"@dataverse-kit/export-engine": "^1.34.5",
|
|
31
31
|
"@khester/dynamics-ui-components": "^1.0.0",
|
|
32
32
|
"chalk": "^5.3.0",
|
|
33
33
|
"commander": "^11.1.0",
|
|
@@ -25,9 +25,19 @@ export class MockApiService implements IApiService {
|
|
|
25
25
|
retrieveMultipleRecords(entity: string): Promise<{ entities: any[] }> {
|
|
26
26
|
return logCrud(
|
|
27
27
|
{ op: "READ", entity, resultCount: (r) => r?.entities?.length },
|
|
28
|
-
async () =>
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
async () => {
|
|
29
|
+
// ★ An unseeded entity returns [] — which is INDISTINGUISHABLE from a query that
|
|
30
|
+
// succeeded and found nothing. That silence is the whole problem: the feature renders
|
|
31
|
+
// an empty list and reads as broken code rather than as a missing seed. Say so, once,
|
|
32
|
+
// naming the file to edit. (Seeding every table is not the answer; this is.)
|
|
33
|
+
if (entity !== "accounts") {
|
|
34
|
+
console.warn(
|
|
35
|
+
`[MockApiService] No seed for entity set "${entity}" — returning []. ` +
|
|
36
|
+
`Add one in src/core/services/MockApiService.ts, or run against a real org.`,
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
return { entities: entity === "accounts" ? Object.values(this.accounts) : [] };
|
|
40
|
+
},
|
|
31
41
|
);
|
|
32
42
|
}
|
|
33
43
|
|
|
@@ -20,9 +20,19 @@ export class MockApiService implements IApiService {
|
|
|
20
20
|
retrieveMultipleRecords(entity: string): Promise<{ entities: any[] }> {
|
|
21
21
|
return logCrud(
|
|
22
22
|
{ op: "READ", entity, resultCount: (r) => r?.entities?.length },
|
|
23
|
-
async () =>
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
async () => {
|
|
24
|
+
// ★ An unseeded entity returns [] — which is INDISTINGUISHABLE from a query that
|
|
25
|
+
// succeeded and found nothing. That silence is the whole problem: the feature renders
|
|
26
|
+
// an empty list and reads as broken code rather than as a missing seed. Say so, once,
|
|
27
|
+
// naming the file to edit. (Seeding every table is not the answer; this is.)
|
|
28
|
+
if (entity !== "accounts") {
|
|
29
|
+
console.warn(
|
|
30
|
+
`[MockApiService] No seed for entity set "${entity}" — returning []. ` +
|
|
31
|
+
`Add one in src/core/services/MockApiService.ts, or run against a real org.`,
|
|
32
|
+
);
|
|
33
|
+
}
|
|
34
|
+
return { entities: entity === "accounts" ? Object.values(this.accounts) : [] };
|
|
35
|
+
},
|
|
26
36
|
);
|
|
27
37
|
}
|
|
28
38
|
|
|
@@ -20,9 +20,19 @@ export class MockApiService implements IApiService {
|
|
|
20
20
|
retrieveMultipleRecords(entity: string): Promise<{ entities: any[] }> {
|
|
21
21
|
return logCrud(
|
|
22
22
|
{ op: "READ", entity, resultCount: (r) => r?.entities?.length },
|
|
23
|
-
async () =>
|
|
24
|
-
|
|
25
|
-
|
|
23
|
+
async () => {
|
|
24
|
+
// ★ An unseeded entity returns [] — which is INDISTINGUISHABLE from a query that
|
|
25
|
+
// succeeded and found nothing. That silence is the whole problem: the feature renders
|
|
26
|
+
// an empty list and reads as broken code rather than as a missing seed. Say so, once,
|
|
27
|
+
// naming the file to edit. (Seeding every table is not the answer; this is.)
|
|
28
|
+
if (entity !== "accounts") {
|
|
29
|
+
console.warn(
|
|
30
|
+
`[MockApiService] No seed for entity set "${entity}" — returning []. ` +
|
|
31
|
+
`Add one in src/core/services/MockApiService.ts, or run against a real org.`,
|
|
32
|
+
);
|
|
33
|
+
}
|
|
34
|
+
return { entities: entity === "accounts" ? Object.values(this.accounts) : [] };
|
|
35
|
+
},
|
|
26
36
|
);
|
|
27
37
|
}
|
|
28
38
|
|
|
@@ -26,9 +26,19 @@ export class MockApiService implements IApiService {
|
|
|
26
26
|
retrieveMultipleRecords(entity: string): Promise<{ entities: any[] }> {
|
|
27
27
|
return logCrud(
|
|
28
28
|
{ op: "READ", entity, resultCount: (r) => r?.entities?.length },
|
|
29
|
-
async () =>
|
|
30
|
-
|
|
31
|
-
|
|
29
|
+
async () => {
|
|
30
|
+
// ★ An unseeded entity returns [] — which is INDISTINGUISHABLE from a query that
|
|
31
|
+
// succeeded and found nothing. That silence is the whole problem: the feature renders
|
|
32
|
+
// an empty list and reads as broken code rather than as a missing seed. Say so, once,
|
|
33
|
+
// naming the file to edit. (Seeding every table is not the answer; this is.)
|
|
34
|
+
if (entity !== "accounts") {
|
|
35
|
+
console.warn(
|
|
36
|
+
`[MockApiService] No seed for entity set "${entity}" — returning []. ` +
|
|
37
|
+
`Add one in src/core/services/MockApiService.ts, or run against a real org.`,
|
|
38
|
+
);
|
|
39
|
+
}
|
|
40
|
+
return { entities: entity === "accounts" ? Object.values(this.accounts) : [] };
|
|
41
|
+
},
|
|
32
42
|
);
|
|
33
43
|
}
|
|
34
44
|
|