Revision 54722
Added by Myrto Koukouli about 5 years ago
datasource-create-form.component.ts | ||
---|---|---|
37 | 37 |
|
38 | 38 |
formSubmitted = false; |
39 | 39 |
group: FormGroup; |
40 |
|
|
41 |
// old issn regex |
|
42 |
// issn : ['', [Validators.pattern('^\\d\\d\\d\\d[-]\\d\\d\\d\\d$')] ], |
|
40 | 43 |
readonly groupDefinition = { |
41 | 44 |
softwarePlatform : ['', Validators.required], |
42 | 45 |
officialName : ['', Validators.required], |
43 |
issn : ['', [Validators.pattern('^\\d\\d\\d\\d[-]\\d\\d\\d\\d$')] ],
|
|
44 |
eissn : ['', Validators.pattern('^\\d\\d\\d\\d[-]\\d\\d\\d\\d$') ],
|
|
45 |
lissn : ['', Validators.pattern('^\\d\\d\\d\\d[-]\\d\\d\\d\\d$') ],
|
|
46 |
issn : ['', [Validators.pattern('^\\d{4}-\\d{3}[\\dxX]$')] ],
|
|
47 |
eissn : ['', Validators.pattern('^\\d{4}-\\d{3}[\\dxX]$') ],
|
|
48 |
lissn : ['', Validators.pattern('^\\d{4}-\\d{3}[\\dxX]$') ],
|
|
46 | 49 |
repoDescription : ['', Validators.required], |
47 | 50 |
country : ['', Validators.required], |
48 | 51 |
longtitude : ['', [Validators.required, Validators.min(-180), Validators.max(180)] ], |
... | ... | |
91 | 94 |
} |
92 | 95 |
this.group = this.fb.group(this.groupDefinition); |
93 | 96 |
if (this.mode === 'journal') { |
94 |
this.group.get('issn').setValidators([Validators.required, Validators.pattern('^\\d\\d\\d\\d[-]\\d\\d\\d\\d$')]);
|
|
97 |
this.group.get('issn').setValidators([Validators.required, Validators.pattern('^\\d{4}-\\d{3}[\\dxX]$')]);
|
|
95 | 98 |
} |
96 | 99 |
this.getTypologies(); |
97 | 100 |
this.getTimezones(); |
Also available in: Unified diff
probably fixed piwik-matomo analytics script