Browse Source

Edge import finished

pull/3693/head
Artem Babak 6 years ago
parent
commit
e23d2c7465
  1. 12
      ui/src/app/api/entity.service.js
  2. 14
      ui/src/app/import-export/table-columns-assignment.directive.js
  3. 6
      ui/src/app/locale/locale.constant-en_US.json

12
ui/src/app/api/entity.service.js

@ -1278,10 +1278,14 @@ function EntityService($http, $q, $filter, $translate, $log, userService, device
} }
if (entityType === types.entityType.edge) { if (entityType === types.entityType.edge) {
newEntity.edgeLicenseKey = entityParameters.edgeLicenseKey; Object.assign(newEntity,
newEntity.cloudEndpoint = entityParameters.cloudEndpoint; {
newEntity.routingKey = entityParameters.routingKey; edgeLicenseKey: entityParameters.edgeLicenseKey,
newEntity.secret = entityParameters.secret; cloudEndpoint: entityParameters.cloudEndpoint,
routingKey: entityParameters.routingKey,
secret: entityParameters.secret
}
);
} }
let saveEntityPromise = getEntitySavePromise(entityType, newEntity, config); let saveEntityPromise = getEntitySavePromise(entityType, newEntity, config);

14
ui/src/app/import-export/table-columns-assignment.directive.js

@ -133,15 +133,19 @@ function TableColumnsAssignmentController($scope, types, $timeout) {
vm.columnTypes.name.disable = isSelectName; vm.columnTypes.name.disable = isSelectName;
vm.columnTypes.type.disable = isSelectType; vm.columnTypes.type.disable = isSelectType;
vm.columnTypes.label.disable = isSelectLabel; vm.columnTypes.label.disable = isSelectLabel;
vm.columnTypes.gateway.disable = isSelectGateway; if (angular.isDefined(vm.columnTypes.gateway)) {
vm.columnTypes.gateway.disable = isSelectGateway;
}
vm.columnTypes.description.disable = isSelectDescription; vm.columnTypes.description.disable = isSelectDescription;
if (angular.isDefined(vm.columnTypes.accessToken)) { if (angular.isDefined(vm.columnTypes.accessToken)) {
vm.columnTypes.accessToken.disable = isSelectCredentials; vm.columnTypes.accessToken.disable = isSelectCredentials;
} }
vm.columnTypes.edgeLicenseKey.disable = isSelectEdgeLicenseKey; if (vm.entityType === types.entityType.edge) {
vm.columnTypes.cloudEndpoint.disable = isSelectCloudEndpoint; vm.columnTypes.edgeLicenseKey.disable = isSelectEdgeLicenseKey;
vm.columnTypes.routingKey.disable = isSelectRoutingKey; vm.columnTypes.cloudEndpoint.disable = isSelectCloudEndpoint;
vm.columnTypes.secret.disable = isSelectSecret; vm.columnTypes.routingKey.disable = isSelectRoutingKey;
vm.columnTypes.secret.disable = isSelectSecret;
}
}); });
} }
}, true); }, true);

6
ui/src/app/locale/locale.constant-en_US.json

@ -1405,9 +1405,9 @@
"access-token": "Access token", "access-token": "Access token",
"isgateway": "Is Gateway", "isgateway": "Is Gateway",
"description": "Description", "description": "Description",
"edgeLicenseKey": "Edge license key", "edgeLicenseKey": "License Key",
"cloudEndpoint": "Cloud endpoint", "cloudEndpoint": "Cloud Endpoint",
"routingKey": "Edge routing key", "routingKey": "Edge key",
"secret": "Edge secret" "secret": "Edge secret"
}, },
"stepper-text":{ "stepper-text":{

Loading…
Cancel
Save