mirror of
https://github.com/bwssytems/ha-bridge.git
synced 2025-12-19 00:20:26 +00:00
Updated issues with edit and update device
This commit is contained in:
@@ -2148,6 +2148,7 @@ app.controller('EditController', function ($scope, $location, $http, bridgeServi
|
||||
$scope.newDimItem = {};
|
||||
$scope.newOffItem = {};
|
||||
$scope.device = bridgeService.state.device;
|
||||
$scope.mapTypeSelected = null;
|
||||
};
|
||||
|
||||
$scope.editDevice = function (copy) {
|
||||
@@ -2161,7 +2162,10 @@ app.controller('EditController', function ($scope, $location, $http, bridgeServi
|
||||
}
|
||||
if (copy)
|
||||
$scope.device.id = null;
|
||||
$scope.device.mapType = $scope.mapTypeSelected[0];
|
||||
if($scope.mapTypeSelected !== undefined && $scope.mapTypeSelected !== null)
|
||||
$scope.device.mapType = $scope.mapTypeSelected[0];
|
||||
else
|
||||
$scope.device.mapType = null;
|
||||
if ($scope.onDevices !== null)
|
||||
$scope.device.onUrl = angular.toJson(bridgeService.updateCallObjectsType($scope.onDevices));
|
||||
if ($scope.dimDevices !== null)
|
||||
|
||||
Reference in New Issue
Block a user