(()=>{function e(e,s){t.$inject=["$routeParams","c8yDevices","c8yBase"],n.$inject=["$routeParams","$location","c8yDevices","c8yBase","c8yActility","c8yInventory","c8yAlert"];var i="device/:deviceId",c={name:"LoRa",icon:"hdd-o",templateUrl:":::PLUGIN_PATH:::/actilityDeviceCard.html",controllerAs:"vm",controller:n,showIf:t};function n(e,i,c,n,t,o,d){var r=this;function v(e){c.detail(e).then(n.getResData).then(a)}function a(e){r.device=e}_.assign(r,{deprovisionDevice:function(){return t.deprovisionDevice(r.device,{cascade:r.deviceChildren.deprovision}).then(function(){d.success(s("Device deprovisioned.")),v(r.device.id)})},deleteDevice:function(){return o.remove(r.device,{cascade:r.deviceChildren.del}).then(function(){d.success(s("Device deleted.")),i.path("/device")})},id:e.deviceId,deviceChildren:{deprovision:!0,del:!0}}),v(r.id)}function t(e,i,c){e=e.deviceId;return i.detail(e).then(c.getResData).then(function(e){return e.c8y_LpwanDevice})}function o(){e.when("/".concat(i),c)}return{$get:_.constant({}),configBlock:function(){o()},hookViews:o}}e.$inject=["c8yViewsProvider","gettext"],angular.module("c8y.deviceActility").provider("c8yActilityUI",e)})();