@punks/cli 0.1.9 → 0.1.11
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/src/commands/entity-add/__test__/dotnet/__snapshots__/render.configuration.spec.ts.snap +2 -2
- package/src/commands/entity-add/__test__/dotnet/__snapshots__/render.firestore-mapper.spec.ts.snap +2 -2
- package/src/commands/entity-add/__test__/dotnet/__snapshots__/render.model-list-item-dto.spec.ts.snap +1 -3
- package/src/commands/entity-add/__test__/dotnet/__snapshots__/render.search-parameters.spec.ts.snap +1 -1
- package/templates/dotnet/NewEntity/Configuration/<PluralizedEntity>Configuration.cs.template +1 -1
- package/templates/dotnet/NewEntity/Mappers/<PluralizedEntity>FirestoreMapper.cs.template +2 -2
- package/templates/dotnet/NewEntity/Models/<Entity>ListItemDto.cs.template +0 -2
- package/templates/dotnet/NewEntity/Search/<PluralizedEntity>SearchParameters.cs.template +1 -1
package/package.json
CHANGED
package/src/commands/entity-add/__test__/dotnet/__snapshots__/render.configuration.spec.ts.snap
CHANGED
|
@@ -18,7 +18,7 @@ namespace namespace.AppUsers.Configuration;
|
|
|
18
18
|
|
|
19
19
|
public static class AppUserConfiguration
|
|
20
20
|
{
|
|
21
|
-
public static IServiceCollection
|
|
21
|
+
public static IServiceCollection AddAppUsers(this IServiceCollection services)
|
|
22
22
|
{
|
|
23
23
|
services
|
|
24
24
|
.AddEntityManager()
|
|
@@ -41,7 +41,7 @@ public static class AppUserConfiguration
|
|
|
41
41
|
app.UseEntityApi<AppUser, Guid, AppUserDto, AppUserListItemDto, AppUserCreateInput, AppUserUpdateInput,
|
|
42
42
|
AppUserSearchParameters, AppUserSortBy, int, AppUserSearchResultFacets>(new EntityApiOptions
|
|
43
43
|
{
|
|
44
|
-
Path = "app-
|
|
44
|
+
Path = "app-users",
|
|
45
45
|
});
|
|
46
46
|
}
|
|
47
47
|
}
|
package/src/commands/entity-add/__test__/dotnet/__snapshots__/render.firestore-mapper.spec.ts.snap
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
3
|
exports[`it should render firestore mapper should render model firestore mapper 1`] = `
|
|
4
|
-
"using
|
|
4
|
+
"using WebPunks.Package.EntityManager.Abstractions;
|
|
5
5
|
using Testing.App.Firestore;
|
|
6
6
|
|
|
7
7
|
namespace namespace.AppUsers.Mappers;
|
|
@@ -11,7 +11,7 @@ public class AppUserFirebaseMapper : IEntityMapper<AppUser, AppUserFirestoreDocu
|
|
|
11
11
|
private readonly DefaultMapper _mapper;
|
|
12
12
|
private readonly CoreDbContext _context;
|
|
13
13
|
|
|
14
|
-
public
|
|
14
|
+
public AppUserFirebaseMapper(DefaultMapper mapper, CoreDbContext context)
|
|
15
15
|
{
|
|
16
16
|
_mapper = mapper;
|
|
17
17
|
_context = context;
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
3
|
exports[`it should render model list item dto should render model list item dto 1`] = `
|
|
4
|
-
"
|
|
5
|
-
|
|
6
|
-
namespace namespace.AppUsers.Models;
|
|
4
|
+
"namespace namespace.AppUsers.Models;
|
|
7
5
|
|
|
8
6
|
public class AppUserListItemDto
|
|
9
7
|
{
|
package/templates/dotnet/NewEntity/Configuration/<PluralizedEntity>Configuration.cs.template
CHANGED
|
@@ -17,7 +17,7 @@ namespace {{ namespace }}.Configuration;
|
|
|
17
17
|
|
|
18
18
|
public static class {{ entityName }}Configuration
|
|
19
19
|
{
|
|
20
|
-
public static IServiceCollection Add{{
|
|
20
|
+
public static IServiceCollection Add{{ pluralizedEntityName }}(this IServiceCollection services)
|
|
21
21
|
{
|
|
22
22
|
services
|
|
23
23
|
.AddEntityManager()
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
using
|
|
1
|
+
using WebPunks.Package.EntityManager.Abstractions;
|
|
2
2
|
using {{ firestoreDocumentNamespace }};
|
|
3
3
|
|
|
4
4
|
namespace {{ namespace }}.Mappers;
|
|
@@ -8,7 +8,7 @@ public class {{ entityName }}FirebaseMapper : IEntityMapper<{{ entityName }}, {{
|
|
|
8
8
|
private readonly DefaultMapper _mapper;
|
|
9
9
|
private readonly CoreDbContext _context;
|
|
10
10
|
|
|
11
|
-
public
|
|
11
|
+
public {{ entityName }}FirebaseMapper(DefaultMapper mapper, CoreDbContext context)
|
|
12
12
|
{
|
|
13
13
|
_mapper = mapper;
|
|
14
14
|
_context = context;
|