|
|
@ -38,12 +38,15 @@ export class ClientsPageComponent extends AppComponentBase implements OnInit { |
|
|
this.formBuilder.group({ |
|
|
this.formBuilder.group({ |
|
|
name: ['', |
|
|
name: ['', |
|
|
[ |
|
|
[ |
|
|
Validators.required, |
|
|
|
|
|
Validators.maxLength(40), |
|
|
Validators.maxLength(40), |
|
|
ValidatorsEx.pattern('[a-z0-9]+(\-[a-z0-9]+)*', 'Name can contain lower case letters (a-z), numbers and dashes (not at the end).') |
|
|
ValidatorsEx.pattern('[a-z0-9]+(\-[a-z0-9]+)*', 'Name can contain lower case letters (a-z), numbers and dashes (not at the end).') |
|
|
]] |
|
|
]] |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
public get hasName() { |
|
|
|
|
|
return this.addClientForm.controls['name'].value && this.addClientForm.controls['name'].value.length > 0; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
constructor(apps: AppsStoreService, notifications: NotificationService, users: UsersProviderService, |
|
|
constructor(apps: AppsStoreService, notifications: NotificationService, users: UsersProviderService, |
|
|
private readonly appClientsService: AppClientsService, |
|
|
private readonly appClientsService: AppClientsService, |
|
|
private readonly messageBus: MessageBus, |
|
|
private readonly messageBus: MessageBus, |
|
|
|