@@ -9,6 +9,7 @@ import { SubRegiao } from "../models/sub-regiao";
99import { Regiao } from "../models/regiao" ;
1010import { Classificacao } from "../models/classificacao" ;
1111import { MapperBase } from "database-builder" ;
12+ import { PrimaryKeyType } from "database-builder/src/core/enums/primary-key-type" ;
1213
1314@Injectable ( )
1415export class TableMapper extends MapperBase {
@@ -23,13 +24,13 @@ export class TableMapper extends MapperBase {
2324 }
2425 ) ;
2526
26- this . add ( TestClazzRef , x => x . id , true ) ;
27- this . add ( TestClazz , x => x . id , true ) ;
28- this . add ( Regiao , x => x . codeImport , true ) ;
29- this . add ( SubRegiao , x => x . codeImport , true ) ;
30- this . add ( Uf , x => x . codeImport , true ) ;
31- this . add ( Cidade , x => x . codeImport , true ) ;
32- this . add ( Classificacao , x => x . codeImport , true ) ;
33- this . add ( Cliente , x => x . internalKey , true ) ;
27+ this . autoMapper ( TestClazzRef , x => x . id , PrimaryKeyType . AutoIncrement ) ;
28+ this . autoMapper ( TestClazz , x => x . id , PrimaryKeyType . AutoIncrement ) ;
29+ this . autoMapper ( Regiao , x => x . codeImport , PrimaryKeyType . AutoIncrement ) ;
30+ this . autoMapper ( SubRegiao , x => x . codeImport , PrimaryKeyType . AutoIncrement ) ;
31+ this . autoMapper ( Uf , x => x . codeImport , PrimaryKeyType . AutoIncrement ) ;
32+ this . autoMapper ( Cidade , x => x . codeImport , PrimaryKeyType . AutoIncrement ) ;
33+ this . autoMapper ( Classificacao , x => x . codeImport , PrimaryKeyType . AutoIncrement ) ;
34+ this . autoMapper ( Cliente , x => x . internalKey , PrimaryKeyType . AutoIncrement ) ;
3435 }
3536}
0 commit comments