Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: ✨ Ajustando parametro Columns do Config #307

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion dist/models/Config.js
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,9 @@ class Config {
!this._insertTime ||
!this._version ||
!this._analyticsTools ||
!this._validationRules
!this._validationRules ||
!this._columnData ||
!this._columnIndex
);
}
_buildDependenciesConfig(dependenciesConfig) {
Expand Down
6 changes: 5 additions & 1 deletion src/ts/models/Config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ export class Config {
private _mediaTaxonomy: { [key: string]: any };
private _validationRules: { [key: string]: string[] };
private _columnNames: string[];
private _columnData: { [key: string]: string[] };
private _columnIndex: { [key: string]: number };
private _dependenciesConfig: DependencyConfig[];

constructor(jsonConfig: { [key: string]: any }) {
Expand Down Expand Up @@ -61,7 +63,9 @@ export class Config {
!this._insertTime ||
!this._version ||
!this._analyticsTools ||
!this._validationRules
!this._validationRules ||
!this._columnData ||
!this._columnIndex
);
}

Expand Down
20 changes: 10 additions & 10 deletions test/models/Adobe.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: [],
Veículo: [],
},
Expand Down Expand Up @@ -45,7 +45,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: ['/meuProdut[ai]/'],
Veículo: ['/.*/'],
},
Expand Down Expand Up @@ -76,7 +76,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: ['/meu\\ ?Produto/'],
Veículo: [],
},
Expand Down Expand Up @@ -107,7 +107,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: ['/meu\\ ?Produto/'],
Veículo: [],
},
Expand Down Expand Up @@ -138,7 +138,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: ['/meu\\ ?Produto/'],
Veículo: [],
},
Expand Down Expand Up @@ -169,7 +169,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: ['/meu\\ ?Produto/'],
Veículo: [],
},
Expand Down Expand Up @@ -201,7 +201,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Dispositivo: [],
Veículo: [],
},
Expand Down Expand Up @@ -241,7 +241,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: [],
Dispositivo: [],
Veículo: [],
Expand Down Expand Up @@ -289,7 +289,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: [],
Dispositivo: [],
Veículo: [],
Expand Down Expand Up @@ -337,7 +337,7 @@ describe('Adobe', () => {
separator: ':',
spaceSeparator: '_',
columns: {
'Tipo de Compra': ['cpa', 'cpc'],
'Tipo de Compra': {"data":['cpa', 'cpc'], "index": 0},
Bandeira: ['/meu\\ ?Produto/'],
Veículo: [],
},
Expand Down
Loading