Implementing user feed back
[aai/sparky-fe.git] / src / app / vnfSearch / VnfSearchReducer.js
index 4c8337f..afd822c 100644 (file)
@@ -1,29 +1,27 @@
 /*
- * ============LICENSE_START===================================================
- * SPARKY (AAI UI service)
- * ============================================================================
- * Copyright © 2017 AT&T Intellectual Property.
+ * ============LICENSE_START=======================================================
+ * org.onap.aai
+ * ================================================================================
+ * Copyright © 2017 AT&T Intellectual Property. All rights reserved.
  * Copyright © 2017 Amdocs
- * All rights reserved.
- * ============================================================================
+ * ================================================================================
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
  *
- *      http://www.apache.org/licenses/LICENSE-2.0
+ *       http://www.apache.org/licenses/LICENSE-2.0
  *
  * Unless required by applicable law or agreed to in writing, software
  * distributed under the License is distributed on an "AS IS" BASIS,
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
- * ============LICENSE_END=====================================================
+ * ============LICENSE_END=========================================================
  *
- * ECOMP and OpenECOMP are trademarks
- * and service marks of AT&T Intellectual Property.
+ * ECOMP is a trademark and service mark of AT&T Intellectual Property.
  */
-import {vnfActionTypes} from 'app/vnfSearch/VnfSearchConstants.js';
 import {
+  vnfActionTypes,
   CHART_ORCH_STATUS,
   CHART_PROV_STATUS,
   CHART_NF_ROLE,
@@ -31,13 +29,13 @@ import {
   TOTAL_VNF_COUNT
 } from 'app/vnfSearch/VnfSearchConstants.js';
 import {ERROR_RETRIEVING_DATA} from 'app/networking/NetworkConstants.js';
-import {MESSAGE_LEVEL_DANGER} from 'utils/GlobalConstants.js';
+import {
+  filterBarActionTypes,
+  MESSAGE_LEVEL_DANGER
+} from 'utils/GlobalConstants.js';
 import {
   globalAutoCompleteSearchBarActionTypes
 } from 'app/globalAutoCompleteSearchBar/GlobalAutoCompleteSearchBarConstants.js';
-import {
-  filterBarActionTypes
-} from 'generic-components/filterBar/FilterBarConstants.js';
 
 export default (state = {}, action) => {
   let data = action.data;
@@ -107,6 +105,16 @@ export default (state = {}, action) => {
         vnfFilterValues: data.nonConvertedValues  // launching DI view via menu button requires this
                                                   // to be set so visualizations and table will populate themselves
       };
+    case vnfActionTypes.VNF_ACTIVATE_BUSY_FEEDBACK:
+      return {
+        ...state,
+        enableBusyFeedback: true
+      };
+    case vnfActionTypes.VNF_DISABLE_BUSY_FEEDBACK:
+      return {
+        ...state,
+        enableBusyFeedback: false
+      }; 
     case filterBarActionTypes.CLEAR_FILTERS:
       return {
         ...state,