Browse Source

Lwm2m front base64 tooltip

pull/5411/head
nickAS21 5 years ago
parent
commit
0d6a49aafc
  1. 7
      ui-ngx/src/app/modules/home/components/device/device-credentials-lwm2m-server.component.html
  2. 14
      ui-ngx/src/app/modules/home/components/device/device-credentials-lwm2m.component.html
  3. 7
      ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.html
  4. 4
      ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.html
  5. 1
      ui-ngx/src/assets/locale/locale.constant-cs_CZ.json
  6. 13
      ui-ngx/src/assets/locale/locale.constant-en_US.json
  7. 1
      ui-ngx/src/assets/locale/locale.constant-tr_TR.json

7
ui-ngx/src/app/modules/home/components/device/device-credentials-lwm2m-server.component.html

@ -32,6 +32,9 @@
cdkAutosizeMinRows="1"
cols="1"
formControlName="clientPublicKeyOrId"
matTooltip="{{ 'device.lwm2m-security-config.client-publicKey-or-id-tooltip' | translate:
{count: serverFormGroup.get('securityMode').value === securityConfigLwM2MType.PSK? 0 :
serverFormGroup.get('securityMode').value === securityConfigLwM2MType.RPK? 1 : 2} }}"
required>
</textarea>
<mat-error *ngIf="serverFormGroup.get('clientPublicKeyOrId').hasError('required')">
@ -45,6 +48,10 @@
cdkAutosizeMinRows="1"
cols="1"
formControlName="clientSecretKey"
matTooltip="{{ 'device.lwm2m-security-config.client-secret-key-tooltip' | translate:
{count: serverFormGroup.get('securityMode').value === securityConfigLwM2MType.PSK? 0 :
serverFormGroup.get('securityMode').value === securityConfigLwM2MType.RPK? 1 : 2} }}"
matTooltipPosition="below"
required>
</textarea>
<mat-error *ngIf="serverFormGroup.get('clientSecretKey').hasError('required')">

14
ui-ngx/src/app/modules/home/components/device/device-credentials-lwm2m.component.html

@ -34,9 +34,12 @@
</mat-option>
</mat-select>
</mat-form-field>
<mat-form-field class="mat-block" *ngIf="lwm2mConfigFormGroup.get('client.securityConfigClientMode').value === securityConfigLwM2MType.PSK">
<mat-form-field class="mat-block"
*ngIf="lwm2mConfigFormGroup.get('client.securityConfigClientMode').value === securityConfigLwM2MType.PSK">
<mat-label>{{ 'device.lwm2m-security-config.identity' | translate }}</mat-label>
<input matInput type="text" formControlName="identity" required>
<input matInput type="text" formControlName="identity" required
matTooltip="{{ 'device.lwm2m-security-config.identity-tooltip' | translate }}"
matTooltipPosition="below">
<mat-error *ngIf="lwm2mConfigFormGroup.get('client.identity').hasError('required')">
{{ 'device.lwm2m-security-config.identity-required' | translate }}
</mat-error>
@ -49,7 +52,10 @@
cdkAutosizeMinRows="1"
cols="1"
formControlName="key"
required>
required
matTooltip="{{ 'device.lwm2m-security-config.client-key-tooltip' | translate:{count:
lwm2mConfigFormGroup.get('client.securityConfigClientMode').value === securityConfigLwM2MType.PSK?0:1} }}"
matTooltipPosition="below">
</textarea>
<mat-error *ngIf="lwm2mConfigFormGroup.get('client.key').hasError('required')">
{{ 'device.lwm2m-security-config.client-key-required' | translate }}
@ -61,6 +67,8 @@
cdkTextareaAutosize
cdkAutosizeMinRows="1"
cols="1"
matTooltip="{{ 'device.lwm2m-security-config.client-public-key-tooltip' | translate: {count: lwm2mConfigFormGroup.get('client.cert').value?1:2} }}"
matTooltipPosition="below"
formControlName="cert">
</textarea>
<mat-hint translate>device.lwm2m-security-config.client-public-key-hint</mat-hint>

7
ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-config-server.component.html

@ -99,7 +99,12 @@
cdkAutosizeMinRows="1"
cols="1" required
formControlName="serverPublicKey"
></textarea>
matTooltip="{{ 'device.lwm2m-security-config.client-publicKey-or-id-tooltip' | translate:
{count: serverFormGroup.get('securityMode').value === securityConfigLwM2MType.RPK? 1 : 2} }}"
matTooltipPosition="below"
required>
</textarea>
<mat-error *ngIf="serverFormGroup.get('serverPublicKey').hasError('required')">
{{ 'device-profile.lwm2m.server-public-key-required' | translate }}
</mat-error>

4
ui-ngx/src/app/modules/home/components/profile/device/lwm2m/lwm2m-device-profile-transport-configuration.component.html

@ -31,13 +31,13 @@
</section>
</ng-template>
</mat-tab>
<mat-tab label="{{ 'device-profile.lwm2m.servers' | translate }}">
<mat-tab label="{{ 'device-profile.lwm2m.bootstrap-tab' | translate }}">
<section [formGroup]="lwm2mDeviceProfileFormGroup">
<section formGroupName="bootstrap" style="padding: 4px 2px">
<mat-accordion multi="true">
<mat-expansion-panel>
<mat-expansion-panel-header>
<mat-panel-title>{{ 'device-profile.lwm2m.servers' | translate }}</mat-panel-title>
<mat-panel-title>{{ 'device-profile.lwm2m.security' | translate }}</mat-panel-title>
</mat-expansion-panel-header>
<ng-template matExpansionPanelContent formGroupName="servers">
<div fxLayout="row" fxLayout.xs="column" fxLayoutGap="8px" fxLayoutGap.xs="0px">

1
ui-ngx/src/assets/locale/locale.constant-cs_CZ.json

@ -1258,7 +1258,6 @@
"view-attribute": "Zobrazit atribut",
"remove-attribute": "Odebrat atribut",
"mode": "Režim konfigurace bezpečnosti",
"servers": "Servery",
"short-id": "Krátké ID",
"short-id-required": "Krátké ID je povinné.",
"short-id-range": "Krátké ID by mělo být v rozsahu od 1 do 65534.",

13
ui-ngx/src/assets/locale/locale.constant-en_US.json

@ -963,10 +963,15 @@
"lwm2m-security-config": {
"identity": "Client Identity",
"identity-required": "Client Identity is required.",
"identity-tooltip": "PSK identity is arbitrary PSK Identities of up to 128 bytes, as mandated in [RFC7925]. \n PSK identity MUST be first converted to a character string, and then encoded to octets using UTF-8 [UTF8].",
"client-key": "Client Key",
"client-key-required": "Client Key is required.",
"client-key-tooltip": "{ count, plural, 1 {RPK public key or id should be in RFC7250 standard and encoded to Base64 format!} other {PSK key should be in RFC4279 standard and HexDec format: 32, 64, 128 characters!.} }",
"endpoint": "Endpoint Client Name",
"endpoint-required": "Endpoint Client Name is required.",
"client-public-key": "Client public key",
"client-public-key-hint": "If client public key is empty, the trusted certificate will be used",
"client-public-key-tooltip": "{ count, plural, 1 {X509 public key should be in DER-encoded X509v3 format and support only EC algorithm and encoded to Base64 format!} other {} }",
"mode": "Security config mode",
"client-tab": "Client Security Config",
"client-certificate": "Client certificate",
@ -975,10 +980,10 @@
"lwm2m-server": "LwM2M Server",
"client-publicKey-or-id": "Client Public Key or Id",
"client-publicKey-or-id-required": "Client Public Key or Id is required.",
"client-publicKey-or-id-tooltip": "{ count, plural, 0 {PSK identity is arbitrary PSK Identities of up to 128 bytes, as mandated in [RFC7925]. \n PSK identity MUST be first converted to a character string, and then encoded to octets using UTF-8 [UTF8].} 1 {RPK public key or id should be in RFC7250 standard and encoded to Base64 format!} other {X509 public key should be in DER-encoded X509v3 format and support only EC algorithm and encoded to Base64 format!} }",
"client-secret-key": "Client Secret Key",
"client-secret-key-required": "Client Secret Key is required.",
"client-public-key": "Client public key",
"client-public-key-hint": "If client public key is empty, the trusted certificate will be used"
"client-secret-key-tooltip": "{ count, plural, 0 {PSK key should be in RFC4279 standard and HexDec format: 32, 64, 128 characters!.} 1 {RPK secret key should be in PKCS_8 format (DER encoding, RFC5958 standard) and encoded to Base64 format!} other {X509 secret key should be in PKCS_8 format (DER encoding, RFC5958 standard) and encoded to Base64 format!} }"
},
"client-id": "Client ID",
"client-id-pattern": "Contains invalid character.",
@ -1272,7 +1277,8 @@
"view-attribute": "View attribute",
"remove-attribute": "Remove attribute",
"mode": "Security config mode",
"servers": "Servers",
"security": "Securities",
"bootstrap-tab": "Bootstrap",
"short-id": "Short ID",
"short-id-required": "Short ID is required.",
"short-id-range": "Short ID should be in a range from 1 to 65534.",
@ -1297,7 +1303,6 @@
"s": "S: SMS connection in standard mode",
"sq": "SQ: SMS connection in queue mode"
},
"bootstrap-tab": "Bootstrap",
"bootstrap-server": "Bootstrap Server",
"lwm2m-server": "LwM2M Server",
"server-host": "Host",

1
ui-ngx/src/assets/locale/locale.constant-tr_TR.json

@ -1271,7 +1271,6 @@
"view-attribute": "Öznitelik görüntüle",
"remove-attribute": "Öznitelik kaldır",
"mode": "Güvenlik yapılandırma modu",
"servers": "Sunucular",
"short-id": "Kısa ID",
"short-id-required": "Kısa ID gerekli.",
"short-id-range": "Kısa ID 1 ile 65534 aralığında olmalıdır.",

Loading…
Cancel
Save