jarvis-arch-hexagonal-gen 1.0.10 → 1.0.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/dist/plugins/dto/templates/create.ejs +9 -7
- package/dist/plugins/dto/templates/update.ejs +9 -7
- package/dist/plugins/usecases/templates/delete.ejs +1 -1
- package/dist/plugins/usecases/templates/find-all.ejs +1 -1
- package/dist/plugins/usecases/templates/find-by-id.ejs +1 -1
- package/dist/plugins/usecases/templates/update.ejs +1 -1
- package/package.json +1 -1
- package/scripts/copy-plugins.js +1 -3
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
export class Create<%= entityName %>Dto {
|
|
2
|
-
|
|
3
|
-
<%
|
|
4
|
-
|
|
5
|
-
.
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
constructor(
|
|
3
|
+
<%
|
|
4
|
+
columns
|
|
5
|
+
.filter(c => !c.generated)
|
|
6
|
+
.forEach((column, index, array) => {
|
|
7
|
+
%> readonly <%= column.name %>: <%= column.type %><%= (index < array.length - 1) ? ',' : '' %>
|
|
8
|
+
<%
|
|
9
|
+
});
|
|
10
|
+
%> ) {}
|
|
9
11
|
}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
export class Update<%= entityName %>Dto {
|
|
2
|
-
|
|
3
|
-
<%
|
|
4
|
-
|
|
5
|
-
.
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
constructor(
|
|
3
|
+
<%
|
|
4
|
+
columns
|
|
5
|
+
.filter(c => !c.generated)
|
|
6
|
+
.forEach((column, index, array) => {
|
|
7
|
+
%> readonly <%= column.name %>?: <%= column.type %><%= (index < array.length - 1) ? ',' : '' %>
|
|
8
|
+
<%
|
|
9
|
+
});
|
|
10
|
+
%> ) {}
|
|
9
11
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { I<%= entity %>Repository } from '
|
|
1
|
+
import { I<%= entity %>Repository } from '../../ports/outbound/repositories/i<%= entityLower %>.repository';
|
|
2
2
|
|
|
3
3
|
export class Delete<%= entity %>UseCase {
|
|
4
4
|
constructor(private readonly repository: I<%= entity %>Repository) {}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { <%= entity %> } from '../entities/<%= entityLower %>.entity';
|
|
2
|
-
import { I<%= entity %>Repository } from '
|
|
2
|
+
import { I<%= entity %>Repository } from '../../ports/outbound/repositories/i<%= entityLower %>.repository';
|
|
3
3
|
|
|
4
4
|
export class FindAll<%= plural %>UseCase {
|
|
5
5
|
constructor(private readonly repository: I<%= entity %>Repository) {}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { <%= entity %> } from '../entities/<%= entityLower %>.entity';
|
|
2
|
-
import { I<%= entity %>Repository } from '
|
|
2
|
+
import { I<%= entity %>Repository } from '../../ports/outbound/repositories/i<%= entityLower %>.repository';
|
|
3
3
|
|
|
4
4
|
export class Find<%= entity %>ByIdUseCase {
|
|
5
5
|
constructor(private readonly repository: I<%= entity %>Repository) {}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { <%= entity %> } from '../entities/<%= entityLower %>.entity';
|
|
2
|
-
import { I<%= entity %>Repository } from '
|
|
2
|
+
import { I<%= entity %>Repository } from '../../ports/outbound/repositories/i<%= entityLower %>.repository';
|
|
3
3
|
|
|
4
4
|
export class Update<%= entity %>UseCase {
|
|
5
5
|
constructor(private readonly repository: I<%= entity %>Repository) {}
|
package/package.json
CHANGED
package/scripts/copy-plugins.js
CHANGED