Commit 7f848b3242fff91b26f3ec8d0129237cd41ddfe5

Authored by Bohdan Smetaniuk
1 parent 23e0fc7f

fixes in controller

... ... @@ -72,7 +72,7 @@ public class WidgetTypeController extends BaseController {
72 72 checkEntity(widgetType.getId(), widgetType, Resource.WIDGET_TYPE);
73 73 WidgetType savedWidgetType = widgetTypeService.saveWidgetType(widgetType);
74 74
75   - sendNotificationMsgToEdgeService(savedWidgetType.getTenantId(), savedWidgetType.getId(), savedWidgetType.getId() == null ? ActionType.ADDED : ActionType.UPDATED);
  75 + sendNotificationMsgToEdgeService(getTenantId(), savedWidgetType.getId(), widgetType.getId() == null ? ActionType.ADDED : ActionType.UPDATED);
76 76
77 77 return checkNotNull(savedWidgetType);
78 78 } catch (Exception e) {
... ...
... ... @@ -71,7 +71,7 @@ public class WidgetsBundleController extends BaseController {
71 71 checkEntity(widgetsBundle.getId(), widgetsBundle, Resource.WIDGETS_BUNDLE);
72 72 WidgetsBundle savedWidgetsBundle = widgetsBundleService.saveWidgetsBundle(widgetsBundle);
73 73
74   - sendNotificationMsgToEdgeService(savedWidgetsBundle.getTenantId(), savedWidgetsBundle.getId(), savedWidgetsBundle.getId() == null ? ActionType.ADDED : ActionType.UPDATED);
  74 + sendNotificationMsgToEdgeService(getTenantId(), savedWidgetsBundle.getId(), widgetsBundle.getId() == null ? ActionType.ADDED : ActionType.UPDATED);
75 75
76 76 return checkNotNull(savedWidgetsBundle);
77 77 } catch (Exception e) {
... ...
... ... @@ -184,7 +184,7 @@ public class DefaultEdgeNotificationService implements EdgeNotificationService {
184 184 EntityId entityId = EntityIdFactory.getByEdgeEventTypeAndUuid(edgeEventType, new UUID(edgeNotificationMsg.getEntityIdMSB(), edgeNotificationMsg.getEntityIdLSB()));
185 185 switch (edgeEventActionType) {
186 186 // TODO: voba - ADDED is not required for CE version ?
187   - // case ADDED:
  187 + case ADDED:
188 188 case UPDATED:
189 189 case CREDENTIALS_UPDATED:
190 190 if (edgeEventType.equals(EdgeEventType.WIDGETS_BUNDLE) || edgeEventType.equals(EdgeEventType.WIDGET_TYPE)) {
... ...