2023-10-15 12:00:30 -07:00
< form [ formGroup ] = " objectForm " ( ngSubmit ) = " save ( ) " autocomplete = "off" >
2022-11-08 11:11:35 -08:00
< div class = "modal-header" >
< h4 class = "modal-title" id = "modal-basic-title" > {{getTitle()}}< / h4 >
< button type = "button" [ disabled ] = " ! closeEnabled " class = "btn-close" aria-label = "Close" ( click ) = " cancel ( ) " >
< / button >
< / div >
< div class = "modal-body" >
< div class = "row" >
< div class = "col" >
2023-09-14 14:03:28 -07:00
< pngx-input-text i18n-title title = "Name" formControlName = "name" [ error ] = " error ? . name " > < / pngx-input-text >
< pngx-input-text i18n-title title = "IMAP Server" formControlName = "imap_server" [ error ] = " error ? . imap_server " > < / pngx-input-text >
< pngx-input-text i18n-title title = "IMAP Port" formControlName = "imap_port" [ error ] = " error ? . imap_port " > < / pngx-input-text >
< pngx-input-select i18n-title title = "IMAP Security" [ items ] = " imapSecurityOptions " formControlName = "imap_security" > < / pngx-input-select >
2022-11-08 11:11:35 -08:00
< / div >
< div class = "col" >
2023-09-14 14:03:28 -07:00
< pngx-input-text i18n-title title = "Username" formControlName = "username" [ error ] = " error ? . username " > < / pngx-input-text >
< pngx-input-password i18n-title title = "Password" formControlName = "password" [ error ] = " error ? . password " > < / pngx-input-password >
< pngx-input-check i18n-title title = "Password is token" i18n-hint hint = "Check if the password above is a token used for authentication" formControlName = "is_token" [ error ] = " error ? . is_token " > < / pngx-input-check >
< pngx-input-text i18n-title title = "Character Set" formControlName = "character_set" [ error ] = " error ? . character_set " > < / pngx-input-text >
2022-11-08 11:11:35 -08:00
< / div >
< / div >
< / div >
< div class = "modal-footer" >
2023-03-24 01:17:20 -07:00
< div class = "m-0 me-2" >
2023-12-19 15:02:05 -08:00
@if (testResult) {
< ngb-alert # testResultAlert [ type ] = " testResult " class = "mb-0 py-2" ( closed ) = " testResult = null" > {{testResultMessage}}< / ngb-alert >
}
2023-03-24 01:17:20 -07:00
< / div >
< button type = "button" class = "btn btn-outline-primary" ( click ) = " test ( ) " [ disabled ] = " networkActive | | testActive " >
2023-12-19 15:02:05 -08:00
@if (testActive) {
2023-03-24 01:17:20 -07:00
< div class = "spinner-border spinner-border-sm me-2" role = "status" > < / div >
< span class = "visually-hidden mr-1" i18n > Loading...< / span >
2023-12-19 15:02:05 -08:00
}
2023-03-24 01:17:20 -07:00
< ng-container i18n > Test< / ng-container >
< / button >
2022-11-08 11:11:35 -08:00
< button type = "button" class = "btn btn-outline-secondary" ( click ) = " cancel ( ) " i18n [ disabled ] = " networkActive " > Cancel< / button >
< button type = "submit" class = "btn btn-primary" i18n [ disabled ] = " networkActive " > Save< / button >
< / div >
< / form >