Commit 59018f12847c1d3e5add639b15bff4ecc7cc6e45

Authored by deaflynx
1 parent a083719d

Set 'default' as default edge type, added hints to cloudEndpoint, licenseKey

... ... @@ -100,24 +100,17 @@
100 100 tb-required="true"
101 101 the-form="theForm"
102 102 ng-model="edge.type"
103   - entity-type="types.entityType.edge"
104   - ng-value="defaultType">
  103 + entity-type="types.entityType.edge">
105 104 </tb-entity-subtype-autocomplete>
106   - <div layout="row">
107   - <md-input-container class="md-block" flex>
  105 + <div translate class="tb-hint">edge.license-key-hint</div>
  106 + <md-input-container class="md-block">
108 107 <label translate>edge.edge-license-key</label>
109 108 <input required name="edgeLicenseKey" ng-model="edge.edgeLicenseKey">
110 109 <div ng-messages="theForm.edgeLicenseKey.$error">
111 110 <div translate ng-message="required">edge.edge-license-key-required</div>
112 111 </div>
113 112 </md-input-container>
114   - <md-button class="md-icon-button" style="margin-top: 14px;">
115   - <md-tooltip md-direction="left">
116   - {{ 'edge.license-key-tooltip' | translate }}
117   - </md-tooltip>
118   - <md-icon md-svg-icon="mdi:help"></md-icon>
119   - </md-button>
120   - </div>
  113 + <div translate class="tb-hint">edge.cloud-endpoint-hint</div>
121 114 <md-input-container class="md-block">
122 115 <label translate>edge.cloud-endpoint</label>
123 116 <input required name="cloudEndpoint" ng-model="edge.cloudEndpoint">
... ...
... ... @@ -29,7 +29,6 @@ export default function EdgeDirective($compile, $templateCache, $translate, $mdD
29 29 scope.isAssignedToCustomer = false;
30 30 scope.isPublic = false;
31 31 scope.assignedCustomer = null;
32   - scope.defaultType = 'default';
33 32
34 33 scope.$watch('edge', function(newVal) {
35 34 if (newVal) {
... ... @@ -37,6 +36,7 @@ export default function EdgeDirective($compile, $templateCache, $translate, $mdD
37 36 scope.edge.routingKey = utils.guid('');
38 37 scope.edge.secret = generateSecret(20);
39 38 scope.edge.cloudEndpoint = utils.baseUrl();
  39 + scope.edge.type = 'default';
40 40 }
41 41 if (scope.edge.customerId && scope.edge.customerId.id !== types.id.nullUid) {
42 42 scope.isAssignedToCustomer = true;
... ...
... ... @@ -853,7 +853,8 @@
853 853 "no-edge-types-matching": "No edge types matching '{{entitySubtype}}' were found.",
854 854 "edge-type-list-empty": "No edge types selected.",
855 855 "edge-types": "Edge types",
856   - "license-key-tooltip": "To get license key please visit www.thingsboard.io/edge"
  856 + "license-key-hint": "To obtain your license please navigate to the <a href='https://thingsboard.io/pricing/?active=thingsboard-edge' target='_blank'>pricing page</a> and select the best license option for your case.",
  857 + "cloud-endpoint-hint": "Edge requires HTTP(s) access to Cloud (ThingsBoard CE/PE) to verify the license key. Please specify Cloud URL that Edge is able to connect to."
857 858 },
858 859 "error": {
859 860 "unable-to-connect": "Unable to connect to the server! Please check your internet connection.",
... ...