Skip to content

Commit 1c42084

Browse files
committed
FIX: Export Dialog is not regenerated
Fixes #30 Signed-off-by: Pavel Shalamkov <[email protected]>
1 parent 7c1668f commit 1c42084

File tree

2 files changed

+2
-20
lines changed
  • src/ng-generate/components
    • card/generators/components/export-dialog
    • table/generators/components/export-dialog

2 files changed

+2
-20
lines changed

src/ng-generate/components/card/generators/components/export-dialog/index.ts

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,11 @@
1111
* SPDX-License-Identifier: MPL-2.0
1212
*/
1313

14-
import {apply, applyTemplates, MergeStrategy, mergeWith, move, noop, Rule, SchematicContext, Tree, url} from '@angular-devkit/schematics';
14+
import {apply, applyTemplates, MergeStrategy, mergeWith, move, Rule, SchematicContext, Tree, url} from '@angular-devkit/schematics';
1515
import {strings} from '@angular-devkit/core';
1616

1717
export function generateExportCardDialog(options: any): Rule {
1818
return (tree: Tree, _context: SchematicContext) => {
19-
const filePath = 'src/app/shared/components/export-confirmation-dialog/export-card-dialog.component';
20-
const htmlPath = `${filePath}.html`;
21-
const scssPath = `${filePath}.scss`;
22-
const tsPath = `${filePath}.ts`;
23-
24-
if (tree.exists(htmlPath) && tree.exists(scssPath) && tree.exists(tsPath)) {
25-
return noop();
26-
}
27-
2819
return mergeWith(
2920
apply(url('./generators/components/export-dialog/files'), [
3021
applyTemplates({

src/ng-generate/components/table/generators/components/export-dialog/index.ts

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,11 @@
1111
* SPDX-License-Identifier: MPL-2.0
1212
*/
1313

14-
import {apply, applyTemplates, MergeStrategy, mergeWith, move, noop, Rule, SchematicContext, Tree, url} from '@angular-devkit/schematics';
14+
import {apply, applyTemplates, MergeStrategy, mergeWith, move, Rule, SchematicContext, Tree, url} from '@angular-devkit/schematics';
1515
import {strings} from '@angular-devkit/core';
1616

1717
export function generateExportTableDialog(options: any): Rule {
1818
return (tree: Tree, _context: SchematicContext) => {
19-
const filePath = 'src/app/shared/components/export-confirmation-dialog/export-table-dialog.component';
20-
const htmlPath = `${filePath}.html`;
21-
const scssPath = `${filePath}.scss`;
22-
const tsPath = `${filePath}.ts`;
23-
24-
if (tree.exists(htmlPath) && tree.exists(scssPath) && tree.exists(tsPath)) {
25-
return noop();
26-
}
27-
2819
return mergeWith(
2920
apply(url('./generators/components/export-dialog/files'), [
3021
applyTemplates({

0 commit comments

Comments
 (0)