Non-RT RIC Dashboard 73/1373/1
authorPatrikBuhr <patrik.buhr@est.tech>
Mon, 4 Nov 2019 13:26:04 +0000 (14:26 +0100)
committerPatrikBuhr <patrik.buhr@est.tech>
Mon, 4 Nov 2019 13:54:51 +0000 (14:54 +0100)
Removed unused code.
Added Nordix to some copyright texts.

Change-Id: I5bb26466418d826bd4005689915c64ddd8630674
Issue-ID: NONRTRIC-61
Signed-off-by: PatrikBuhr <patrik.buhr@est.tech>
41 files changed:
dashboard/INFO.yaml [deleted file]
dashboard/README.md
dashboard/docs/overview.rst
dashboard/docs/release-notes.rst
dashboard/webapp-backend/src/main/java/org/oransc/ric/portal/dashboard/config/WebSecurityConfiguration.java
dashboard/webapp-backend/src/main/java/org/oransc/ric/portal/dashboard/controller/Html5PathsController.java
dashboard/webapp-backend/src/main/java/org/oransc/ric/portal/dashboard/k8sapi/CaasIngressDemo.java [deleted file]
dashboard/webapp-backend/src/main/resources/application.properties
dashboard/webapp-frontend/README.md
dashboard/webapp-frontend/src/app/app-control/app-control.animations.ts [deleted file]
dashboard/webapp-frontend/src/app/app-control/app-control.component.html [deleted file]
dashboard/webapp-frontend/src/app/app-control/app-control.component.scss [deleted file]
dashboard/webapp-frontend/src/app/app-control/app-control.component.spec.ts [deleted file]
dashboard/webapp-frontend/src/app/app-control/app-control.component.ts [deleted file]
dashboard/webapp-frontend/src/app/app-control/app-control.datasource.ts [deleted file]
dashboard/webapp-frontend/src/app/control/control.component.html [deleted file]
dashboard/webapp-frontend/src/app/control/control.component.scss [deleted file]
dashboard/webapp-frontend/src/app/control/control.component.spec.ts [deleted file]
dashboard/webapp-frontend/src/app/control/control.component.ts [deleted file]
dashboard/webapp-frontend/src/app/footer/footer.component.html
dashboard/webapp-frontend/src/app/footer/footer.component.ts
dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.html [deleted file]
dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.scss [deleted file]
dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.ts [deleted file]
dashboard/webapp-frontend/src/app/ran-control/ran-control.component.html [deleted file]
dashboard/webapp-frontend/src/app/ran-control/ran-control.component.scss [deleted file]
dashboard/webapp-frontend/src/app/ran-control/ran-control.component.spec.ts [deleted file]
dashboard/webapp-frontend/src/app/ran-control/ran-control.component.ts [deleted file]
dashboard/webapp-frontend/src/app/ran-control/ran-control.datasource.ts [deleted file]
dashboard/webapp-frontend/src/app/rd.module.ts
dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.html [deleted file]
dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.scss [deleted file]
dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.ts [deleted file]
dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.html [deleted file]
dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.scss [deleted file]
dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.ts [deleted file]
dashboard/webapp-frontend/src/app/user/user.component.html [deleted file]
dashboard/webapp-frontend/src/app/user/user.component.scss [deleted file]
dashboard/webapp-frontend/src/app/user/user.component.spec.ts [deleted file]
dashboard/webapp-frontend/src/app/user/user.component.ts [deleted file]
dashboard/webapp-frontend/src/app/user/user.datasource.ts [deleted file]

diff --git a/dashboard/INFO.yaml b/dashboard/INFO.yaml
deleted file mode 100644 (file)
index 2cc8827..0000000
+++ /dev/null
@@ -1,47 +0,0 @@
----
-project: 'portal/ric-dashboard'
-project_creation_date: '2019-05-21'
-project_category: ''
-lifecycle_state: 'Incubation'
-project_lead: &portal_ric_dashboard_ptl
-    name: 'TBD'
-    email: 'TBD'
-    id: 'TBD'
-    company: 'AT&T Labs-Research'
-    timezone: 'America/New_York'
-primary_contact: *portal_ric_dashboard_ptl
-issue_tracking:
-    type: 'jira'
-    url: 'https://jira.o-ran-sc.org/projects/RICPLT'
-    key: 'DASHBOARD'
-mailing_list:
-    type: 'groups.io'
-    url: 'https://lists.o-ran-sc.org/g/main'
-    tag: '<[portal/ric-dashboard]>'
-realtime_discussion:
-    type: 'irc'
-    server: 'freenode.net'
-    channel: '#o-ran-sc'
-meetings:
-    - type: 'zoom'
-      agenda: ''
-      url: ''
-      server: 'n/a'
-      channel: 'n/a'
-      repeats: 'weekly'
-      time: ''
-repositories:
-    - 'portal/ric-dashboard'
-committers:
-    - name: 'Chris Lott'
-      email: 'clott@research.att.com'
-      company: 'AT&T Labs-Research'
-      id: 'cl778h'
-      timezone: 'America/New_York'
-    - name: 'Manoop Talasila'
-      email: 'talasila@research.att.com'
-      company: 'ATT'
-      id: 'talasila'
-      timezone: 'America/New_York'
-tsc:
-    approval: 'https://lists.o-ran-sc.org/g/toc'
index 9dbc046..03da2f2 100644 (file)
@@ -1,6 +1,6 @@
-# O-RAN-SC RIC Dashboard Web Application
+# O-RAN-SC NonRT RIC Dashboard Web Application
 
-The O-RAN SC RIC Dashboard provides administrative and operator
+The O-RAN NonRT RIC Dashboard provides administrative and operator
 functions for a radio access network (RAN) controller.
 This web app consists of an Angular (version 8) front end
 and a Java (version 11) Spring-Boot (version 2.1) back end.
@@ -13,6 +13,7 @@ URL `http://your-host-name-here:8080/swagger-ui.html`
 ## License
 
 Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+Modifications Copyright (C) 2019 Nordix Foundation
 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
index a58986e..f0d5c95 100644 (file)
@@ -1,14 +1,14 @@
-.. ===============LICENSE_START=======================================================
-.. O-RAN SC CC-BY-4.0
+.. ========================LICENSE_START=================================
+.. O-RAN-SC
 .. %%
-.. Copyright (C) 2019 AT&T Intellectual Property
+.. Copyright (C) 2019 Nordix Foundation
 .. %%
 .. 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.
 .. limitations under the License.
 .. ===============LICENSE_END=========================================================
 
-RIC Dashboard Overview
+NonRT RIC Dashboard Overview
 ======================
 
-The O-RAN SC RIC Dashboard provides administrative and operator
-functions for a radio access network (RAN) controller.  The web app is
+The O-RAN NonRT RIC Dashboard provides administrative and operator
+functions managing policies.  The web app is
 built as a single-page app using an Angular (version 8) front end and
 a Java (version 11) Spring-Boot (version 2.1) back end.
 
 Project Resources
 -----------------
+TBD
 
-The source code is available from the Linux Foundation Gerrit server:
-
-    `<https://gerrit.o-ran-sc.org/r/portal/ric-dashboard;a=summary>`_
-
-The build (CI) jobs are in the Linux Foundation Jenkins server:
-
-    `<https://jenkins.o-ran-sc.org/view/portal-ric-dashboard>`_
-
-Issues are tracked in the Linux Foundation Jira server:
-
-    `<https://jira.o-ran-sc.org/secure/Dashboard.jspa>`_
-
-Project information is available in the Linux Foundation Wiki:
-
-    `<https://wiki.o-ran-sc.org>`_
-
-
-A1 Mediator
------------
-
-The Dashboard interfaces with the A1 Mediator.  This platform
-component is accessed via HTTP/REST requests using a client that is
-generated from an API specification published by the A1 Mediator team.
-
-The A1 Mediator supports fetching and storing configuration of
-applications, which is referred to as getting or setting a policy.
-The Dashboard UI provides screens to view and modify configuration
-data for such applications.  As of this writing, the only application
-that is managed via the A1 Mediator interface is the Admission Control
-("AC") application.
-
-
-Application Manager
--------------------
-
-The Dashboard interfaces with the Application Manager.  This platform
-component is accessed via HTTP/REST requests using a client that is
-generated from an API specification published by the Application
-Manager team.
-
-The Application Manager supports deploying, undeploying and
-configuring applications in the RIC. The Dashboard UI provides screens
-for these functions.
-
-
-Automatic Neighbor Relation Application
----------------------------------------
-
-The Dashboard interfaces with the Automatic Neighbor Relation (ANR)
-application.  This RIC application is accessed via HTTP/REST requests
-using a client that is generated from an API specification published
-by the ANR team.
-
-This RIC application discovers and manages the Neighbor Cell Relation
-Table (NCRT). The Dashboard UI provides screens to view and modify
-NCRT data.
-
-
-E2 Manager
-----------
-
-The Dashboard interfaces with the E2 Manager.  This platform
-component is accessed via HTTP/REST requests using a client that is
-generated from an API specification published by the E2 Manager team.
-
-The E2 Manager platform component supports connecting and
-disconnecting RAN elements.  The Dashboard UI provides controls for
-operators to create "ENDC" and "X2" connections, and to disconnect RAN
-elements.
index 19a9e55..b9ee3fd 100644 (file)
@@ -1,7 +1,7 @@
 .. ===============LICENSE_START=======================================================
 .. O-RAN SC CC-BY-4.0
 .. %%
-.. Copyright (C) 2019 AT&T Intellectual Property
+.. Copyright (C) 2019 Nordix Foundation
 .. %%
 .. Licensed under the Apache License, Version 2.0 (the "License");
 .. you may not use this file except in compliance with the License.
 .. limitations under the License.
 .. ===============LICENSE_END=========================================================
 
-RIC Dashboard Release Notes
-===========================
+NonTR RIC Dashboard Release Notes
+=================================
 
-Version 1.2.4, 24 Oct 2019
---------------------------
-* Revise a1-med-client to use API spec in new submodule ric-plt/a1;
-  removed cached copy
-* Revise app manager client to use API spec in new submodule ric-plt/appmgr;
-  removed cached copy
-* Add Platform page showing Kubernetes pods in aux and platform obtained from CAAS-Ingress
-* Update Angular libraries to recent stable versions
-* Revise user controller to answer data sent by portal, drop the mock implementation
-* Set global style for page titles
-* Align page titles to top left,decrease font size
-* Update EPSDK-FW to version 2.6
-* Make constructor robust to missing caasingress.insecure property
-* Repair bug that omitted slashes in CAAS-Ingress URL builder
-* Improve the dark mode
-* Show container ready count with total count
-
-Version 1.2.3, 4 Oct 2019
--------------------------
-* Serve unauthenticated user a login-at-portal page without using redirect
-* Upgrade to Spring-Boot 2.1.9.RELEASE
-
-Version 1.2.2, 27 Sep 2019
---------------------------
-* Support Portal security using EPSDK-FW cookie and user management
-
-Version 1.2.1, 20 Sep 2019
---------------------------
-* Repair E2 URLs in front end like endc-setup/endcSetup
-* Extend ANR mock feature to persist edits for demos
-* Block whitespace in E2 IP input field validation
-* Relax validation in E2 RAN name field validation
-* Make RAN connection table robust to missing fields
-* Install curl when building Docker image
-
-Version 1.2.0, 11 Sep 2019
---------------------------
-* Split URL properties into prefix/suffix parts
-* Add jacoco plugin to back-end for code coverage
-* Compile with Java version 11, use base openjdk:11-jre-slim
-* Clean code of issues reported by Sonar
-* Drop mock RAN names feature that supported R1 testing
-* Extend mock endpoints to simulate delay seen in tests
-* Move mock configuration classes into test area
-* Update App manager client to spec version 0.1.7
-* Add controller for page refresh of Angular routes
-* Extend E2 mock configuration for demo purposes
-* Add pattern for matching AC/admin application name
-* Add custom (plain but not white-label) error page
-* Synch A1 method paths in front-end and back-end
-* Add xapp dynamic configuration feature
-* Disable x-frame-options response header
-* Repair app manager undeploy-app back/front methods
-* Display AC xAPP metrics data via Kibana source (metrics.url.ac) on dashboard
-* Pass AC policy parameter without parsing as JSON
-* Use snake_case (not camelCase) names in AC policy front end
-* Update A1 mediator client to spec version 0.10.3
-* Extend AC control screen to read policy from A1
-* Create loading-dialog component and service
-* Showing the loading-dialog while making API call
-* Add notification and error handling for xapp configuration
-* Update E2 manager client to spec version 2.0.5 of 2019-09-11
-* Display MC xAPP metrics data via Kibana source (metrics.url.mc) on dashboard
-
-Version 1.0.5, 5 July 2019
---------------------------
-* Upgrade to Angular version 8
-* Upgrade to Spring-Boot 2.1.6.RELEASE
-* Align AC xApp policy page title
-* Update E2 manager client to spec version 20190703
-* Add configuration-driven mock of E2 getNodebIdList
-* Revise front-end components to use prefix 'rd'
-* Improve error handling in BE and FE code
-* Revise the notification service to display multiple notifications
-* Add JUnit test cases for controller methods
-
-Version 1.0.4, 27 June 2019
----------------------------
-* Add AC xApp neighbor control screen
-* Add ANR xApp neighbor cell relation table
-* Drop the pendulum xApp control screen
-* Add column sorting on xApp catalog, xApp control, ANR
-* Add disconnect-all button to RAN connection screen
-* Extend E2 service with disconnect-all method
-* Update ANR xApp client to spec version 0.0.8
-* Update E2 manager client to spec version 20190620
-* Adjust CSS and HTML for main container positioning
-* Revise config property keys to use URL (not basepath)
-* Left menu overlap main content fix
-* Extend back-end controllers to return error details
-* Add feature resilient to malformed instance data
-* Extend Xapp Controller with config endpoints
-* Add build number to dashboard version string
-* Move mock admin screen user data to backend
-* Update App manager client to spec version 0.1.5
-* Move RAN connection feature to control screen
-* Rework admin table
-* Update the notification service
-* Move RAN connection feature to control screen
-* Repair deploy-app feature and use icon instead of text button
-
-Version 1.0.3, 28 May 2019
---------------------------
-* Add AC xApp controller to backend
-* Add AC xApp interface to frontend
-* Add RAN type radio selector to connection setup
-* Update ANR xApp client to spec version 0.0.7
-* Update E2 manager client to spec version 20190515
-* Update xApp manager client to spec version 0.1.4
-* Add get-version methods to all controllers
-* Add simple page footer with copyright and version
-* Add AC and ANR xApp services
-* Rename signal service to E2 Manager service
-* Use XappMgrService to replace ControlService and CatalogService
-* Apply mat-table to control and catalog
-* RAN Connection screen upgrade to mat-table
-
-Version 1.0.2, 13 May 2019
---------------------------
-* Update A1 mediator client to version 0.4.0
-* Add E2 response message with timestamp and status code
-* Fetch xAPP instance status information from xAPP Manager and display in dashboard
-* Allow the user to initiate an E2 (X2) connection between RIC and gNB/eNB
-* User input validations on connections between RIC and eNB/gNB in the dashboard
-* Add ANR xApp backend with mock implementation
-* Add undeploy xApp function
-* Add shared confirm dialog
-* Add shared notification
-
-Version 1.0.1, 6 May 2019
--------------------------
-* Add draft A1 Mediator API definition
-* Use E2 Manager API definition dated 2 May 2019, with tag modifications
-* Adjust group IDs and packages for name O-RAN-SC; drop ORAN-OSC
-* Add ANR API spec and client code generator
-* Update xApp Manager API spec to version 0.1.2
-
-Version 1.0.0, 30 Apr 2019
---------------------------
-* Initial version
index b912500..0a7f02c 100644 (file)
@@ -3,6 +3,7 @@
  * O-RAN-SC
  * %%
  * Copyright (C) 2019 AT&T Intellectual Property
+ * Modifications Copyright (C) 2019 Nordix Foundation
  * %%
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
index ed2e905..7fb6e67 100644 (file)
@@ -3,6 +3,7 @@
  * O-RAN-SC
  * %%
  * Copyright (C) 2019 AT&T Intellectual Property
+ * Modifications Copyright (C) 2019 Nordix Foundation
  * %%
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -56,7 +57,7 @@ public class Html5PathsController {
         *                         On error
         */
        @RequestMapping(method = { RequestMethod.OPTIONS, RequestMethod.GET }, //
-                       path = { "/catalog", "/control", "/stats", "/user" })
+                       path = { "/policy", "/user" })
        public void forwardAngularRoutes(HttpServletRequest request, HttpServletResponse response) throws IOException {
                URL url = new URL(request.getScheme(), request.getServerName(), request.getServerPort(), "/index.html");
                if (logger.isDebugEnabled())
diff --git a/dashboard/webapp-backend/src/main/java/org/oransc/ric/portal/dashboard/k8sapi/CaasIngressDemo.java b/dashboard/webapp-backend/src/main/java/org/oransc/ric/portal/dashboard/k8sapi/CaasIngressDemo.java
deleted file mode 100644 (file)
index 3a75dfa..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-package org.oransc.ric.portal.dashboard.k8sapi;
-
-import java.lang.invoke.MethodHandles;
-
-import org.oransc.ric.portal.dashboard.util.HttpsURLConnectionUtils;
-import org.slf4j.Logger;
-import org.slf4j.LoggerFactory;
-import org.springframework.http.ResponseEntity;
-import org.springframework.web.client.RestTemplate;
-
-public class CaasIngressDemo {
-
-       private static final Logger logger = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
-
-       public static void main(String[] args) throws Exception {
-               HttpsURLConnectionUtils.turnOffSslChecking();
-               // Get IP address from REC deployment team for testing
-               final String podsUrl = "https://10.0.0.1:16443/api/v1/namespaces/ricaux/pods";
-               RestTemplate rt = new RestTemplate();
-               ResponseEntity<String> podsResponse = rt.getForEntity(podsUrl, String.class);
-               logger.info(podsResponse.getBody());
-               HttpsURLConnectionUtils.turnOnSslChecking();
-       }
-
-}
index e969968..585e795 100644 (file)
@@ -2,6 +2,7 @@
 # O-RAN-SC
 # %%
 # Copyright (C) 2019 AT&T Intellectual Property
+# Modifications Copyright (C) 2019 Nordix Foundation
 # %%
 # Licensed under the Apache License, Version 2.0 (the "License");
 # you may not use this file except in compliance with the License.
@@ -16,7 +17,7 @@
 # limitations under the License.
 # ========================LICENSE_END===================================
 
-# Defines RIC Dashboard property keys and default values.
+# Defines NonRT RIC Dashboard property keys and default values.
 # Create a copy in the launch directory to override values; or
 # copy to "application-abc.properties" as mentioned in the README.
 
@@ -40,23 +41,11 @@ portalapi.appname = RIC Dashboard
 portalapi.username =
 portalapi.password =
 
-# endpoint URLs must be supplied at deployment time
-# A1 Mediator
-a1med.url.prefix = http://jar-app-props-default-A1-URL-prefix
-a1med.url.suffix =
 # endpoint URLs must be supplied at deployment time
 # A1 Controller
 a1controller.url.prefix = http://localhost:8282
 a1controller.url.suffix = /restconf/operations
-# ANR xApp
-anrxapp.url.prefix = http://jar-app-props-default-ANR-URL-prefix
-anrxapp.url.suffix =
-# App Manager
-appmgr.url.prefix = http://jar-app-props-default-Xapp-Mgr-URL
-appmgr.url.suffix = /ric/v1
-# E2 Manager
-e2mgr.url.prefix = http://jar-app-props-default-E2-URL
-e2mgr.url.suffix = /v1
+
 # Kubernetes API via https://github.com/nokia/caas-ingress
 # Set insecure=true to disable SSL certificate and hostname checking
 caasingress.insecure = true
index f1c849e..569b771 100644 (file)
@@ -29,6 +29,7 @@ To get more help on the Angular CLI use `ng help` or go check out the [Angular C
 ## License
 
 Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+Modifications Copyright (C) 2019 Nordix Foundation
 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
diff --git a/dashboard/webapp-frontend/src/app/app-control/app-control.animations.ts b/dashboard/webapp-frontend/src/app/app-control/app-control.animations.ts
deleted file mode 100644 (file)
index c00f877..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
-import { animate, state, style, transition, trigger } from '@angular/animations';
-
-export const AppControlAnimations = {
-  messageTrigger: trigger('messageExpand', [
-    state('collapsed', style({ height: '0px', minHeight: '0', display: 'none' })),
-    state('expanded', style({ height: '*' })),
-  ])
-}
diff --git a/dashboard/webapp-frontend/src/app/app-control/app-control.component.html b/dashboard/webapp-frontend/src/app/app-control/app-control.component.html
deleted file mode 100644 (file)
index ec802f4..0000000
+++ /dev/null
@@ -1,100 +0,0 @@
-<!--
-  ========================LICENSE_START=================================
-  O-RAN-SC
-  %%
-  Copyright (C) 2019 AT&T Intellectual Property
-  %%
-  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
-  
-  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===================================
-  -->
-
-<div class="app-control__section">
-  <h3 class="rd-global-page-title">xApp Control</h3>
-
-  <table mat-table [dataSource]="dataSource" matSort multiTemplateDataRows class="app-control-table mat-elevation-z8">
-
-    <ng-container matColumnDef="xapp">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> App Name </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.xapp}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="name">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> Instance Name</mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.instance.name}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="status">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> Status </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.instance.status}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="ip" >
-      <mat-header-cell *matHeaderCellDef mat-sort-header> IP </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.instance.ip}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="port">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> Port </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.instance.port}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="action">
-      <mat-header-cell *matHeaderCellDef> Action </mat-header-cell>
-      <!-- click on button should not expand/collapse the row -->
-      <mat-cell *matCellDef="let element" (click)="$event.stopPropagation()">
-      <button mat-icon-button (click)="controlApp(element)">
-          <mat-icon matTooltip="Adjust settings">settings</mat-icon>
-        </button>
-        <button mat-icon-button (click)="onUndeployApp(element)">
-          <mat-icon matTooltip="Undeploy app">cloud_download</mat-icon>
-        </button>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="expandedDetail">
-      <td mat-cell *matCellDef="let element" [attr.colspan]="displayedColumns.length">
-        <div [@messageExpand]="element == expandedElement ? 'expanded' : 'collapsed'">
-          <div>
-            txMessages:
-          </div>
-          <li *ngFor="let rxmessage of element.instance.rxMessages">
-            <span>{{rxmessage}}</span>
-          </li>
-          <div>
-            rxMessages:
-          </div>
-          <li *ngFor="let txmessage of element.instance.txMessages">
-            <span>{{txmessage}}</span>
-          </li>
-        </div>
-      </td>
-    </ng-container>
-
-    <ng-container matColumnDef="noRecordsFound">
-      <mat-footer-cell *matFooterCellDef>No records found.</mat-footer-cell>
-    </ng-container>
-
-    <mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
-    <mat-row *matRowDef="let element; columns: displayedColumns;"
-      [class.example-expanded-row]="expandedElement === element"
-      (click)="expandedElement = expandedElement === element ? null : element"></mat-row>
-    <tr mat-row *matRowDef="let row; columns: ['expandedDetail']" class="message-row"></tr>
-    <mat-footer-row *matFooterRowDef="['noRecordsFound']" [ngClass]="{'display-none': dataSource.rowCount > 0}"></mat-footer-row>
-
-  </table>
-
-  <div class="spinner-container" *ngIf="dataSource.loading$ | async">
-    <mat-spinner diameter=50></mat-spinner>
-  </div>
-
-</div>
diff --git a/dashboard/webapp-frontend/src/app/app-control/app-control.component.scss b/dashboard/webapp-frontend/src/app/app-control/app-control.component.scss
deleted file mode 100644 (file)
index 232562f..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- *
- * 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===================================
- */
- .app-control__section {
-}
-
-
-.spinner-container {
-  height: 100px;
-  width: 100px;
-}
-
-.spinner-container mat-spinner {
-  margin: 0 auto 0 auto;
-}
-
-.app-control-table {
-  width: 100%;
-  min-height: 150px;
-  margin-top: 10px;
-  background-color: transparent;
-}
-
-tr.message-row {
-  height: 0;
-}
-
-.display-none {
-  display: none;
-}
diff --git a/dashboard/webapp-frontend/src/app/app-control/app-control.component.spec.ts b/dashboard/webapp-frontend/src/app/app-control/app-control.component.spec.ts
deleted file mode 100644 (file)
index 6648d81..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { AppControlComponent } from './app-control.component';
-
-describe('AppControlComponent', () => {
-  let component: AppControlComponent;
-  let fixture: ComponentFixture<AppControlComponent>;
-
-  beforeEach(async(() => {
-    TestBed.configureTestingModule({
-      declarations: [ AppControlComponent ]
-    })
-    .compileComponents();
-  }));
-
-  beforeEach(() => {
-    fixture = TestBed.createComponent(AppControlComponent);
-    component = fixture.componentInstance;
-    fixture.detectChanges();
-  });
-
-  it('should create', () => {
-    expect(component).toBeTruthy();
-  });
-});
diff --git a/dashboard/webapp-frontend/src/app/app-control/app-control.component.ts b/dashboard/webapp-frontend/src/app/app-control/app-control.component.ts
deleted file mode 100644 (file)
index 07b931d..0000000
+++ /dev/null
@@ -1,103 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { HttpErrorResponse, HttpResponse } from '@angular/common/http';
-import { Component, OnInit, ViewChild } from '@angular/core';
-import { MatSort } from '@angular/material/sort';
-import { Router } from '@angular/router';
-import { XappControlRow } from '../interfaces/app-mgr.types';
-import { AppMgrService } from '../services/app-mgr/app-mgr.service';
-import { ConfirmDialogService } from '../services/ui/confirm-dialog.service';
-import { ErrorDialogService } from '../services/ui/error-dialog.service';
-import { LoadingDialogService } from '../services/ui/loading-dialog.service';
-import { NotificationService } from '../services/ui/notification.service';
-import { AppControlAnimations } from './app-control.animations';
-import { AppControlDataSource } from './app-control.datasource';
-import { finalize } from 'rxjs/operators';
-
-@Component({
-  selector: 'rd-app-control',
-  templateUrl: './app-control.component.html',
-  styleUrls: ['./app-control.component.scss'],
-  animations: [AppControlAnimations.messageTrigger]
-})
-export class AppControlComponent implements OnInit {
-
-  displayedColumns: string[] = ['xapp', 'name', 'status', 'ip', 'port', 'action'];
-  dataSource: AppControlDataSource;
-  @ViewChild(MatSort, {static: true}) sort: MatSort;
-
-  constructor(
-    private appMgrSvc: AppMgrService,
-    private router: Router,
-    private confirmDialogService: ConfirmDialogService,
-    private errorDialogService: ErrorDialogService,
-    private loadingDialogService: LoadingDialogService,
-    private notificationService: NotificationService) { }
-
-  ngOnInit() {
-    this.dataSource = new AppControlDataSource(this.appMgrSvc, this.sort, this.notificationService);
-    this.dataSource.loadTable();
-  }
-
-  controlApp(app: XappControlRow): void {
-    // TODO: identify apps without hardcoding to names
-    const acAppPattern0 =  /[Aa][Dd][Mm][Ii][Nn]/;
-    const acAppPattern1 =  /[Aa][Dd][Mm][Ii][Ss]{2}[Ii][Oo][Nn]/;
-    const anrAppPattern0 = /ANR/;
-    const anrAppPattern1 = /[Aa][Uu][Tt][Oo][Mm][Aa][Tt][Ii][Cc]/;
-    const anrAppPattern2 = /[Nn][Ee][Ii][Gg][Hh][Bb][Oo][Rr]/;
-    if (acAppPattern0.test(app.xapp) || acAppPattern1.test(app.xapp)) {
-      this.router.navigate(['/ac']);
-    } else if (anrAppPattern0.test(app.xapp) || (anrAppPattern1.test(app.xapp) && anrAppPattern2.test(app.xapp))) {
-      this.router.navigate(['/anr']);
-    } else {
-      this.errorDialogService.displayError('No control available for ' + app.xapp + ' (yet)');
-    }
-  }
-
-  onUndeployApp(app: XappControlRow): void {
-    this.confirmDialogService.openConfirmDialog('Are you sure you want to undeploy App ' + app.xapp + '?')
-      .afterClosed().subscribe( (res: boolean) => {
-        if (res) {
-          this.loadingDialogService.startLoading("Undeploying " + app.xapp);
-          this.appMgrSvc.undeployXapp(app.xapp)
-            .pipe(
-              finalize(() => this.loadingDialogService.stopLoading())
-            )
-            .subscribe(
-            ( httpResponse: HttpResponse<Object>) => {
-              // Answers 204/No content on success
-              this.notificationService.success('App undeployed successfully!');
-              this.dataSource.loadTable();
-            },
-            ( (her: HttpErrorResponse) => {
-              // the error field should have an ErrorTransport object
-              let msg = her.message;
-              if (her.error && her.error.message) {
-                msg = her.error.message;
-              }
-              this.notificationService.warn('App undeploy failed: ' + msg);
-            })
-          );
-        }
-      });
-  }
-
-}
diff --git a/dashboard/webapp-frontend/src/app/app-control/app-control.datasource.ts b/dashboard/webapp-frontend/src/app/app-control/app-control.datasource.ts
deleted file mode 100644 (file)
index e97dc63..0000000
+++ /dev/null
@@ -1,134 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
-import { CollectionViewer, DataSource } from '@angular/cdk/collections';
-import { HttpErrorResponse } from '@angular/common/http';
-import { MatSort } from '@angular/material/sort';
-import { Observable } from 'rxjs/Observable';
-import { BehaviorSubject } from 'rxjs/BehaviorSubject';
-import { merge } from 'rxjs';
-import { of } from 'rxjs/observable/of';
-import { catchError, finalize, map } from 'rxjs/operators';
-import { XappControlRow, XMDeployedApp, XMXappInstance } from '../interfaces/app-mgr.types';
-import { AppMgrService } from '../services/app-mgr/app-mgr.service';
-import { NotificationService } from '../services/ui/notification.service';
-
-export class AppControlDataSource extends DataSource<XappControlRow> {
-
-  private appControlSubject = new BehaviorSubject<XappControlRow[]>([]);
-
-  private loadingSubject = new BehaviorSubject<boolean>(false);
-
-  public loading$ = this.loadingSubject.asObservable();
-
-  public rowCount = 1; // hide footer during intial load
-
-  private emptyInstances: XMXappInstance =
-    { ip: null,
-      name: null,
-      port: null,
-      status: null,
-      rxMessages: [],
-      txMessages: [],
-    };
-
-  constructor(private appMgrSvc: AppMgrService,
-    private sort: MatSort,
-    private notificationService: NotificationService) {
-    super();
-  }
-
-  loadTable() {
-    this.loadingSubject.next(true);
-    this.appMgrSvc.getDeployed()
-      .pipe(
-        catchError( (her: HttpErrorResponse) => {
-          console.log('AppControlDataSource failed: ' + her.message);
-          this.notificationService.error('Failed to get applications: ' + her.message);
-          return of([]);
-        }),
-        finalize(() => this.loadingSubject.next(false))
-      )
-      .subscribe( (xApps: XMDeployedApp[]) => {
-        this.rowCount = xApps.length;
-        const flattenedApps = this.flatten(xApps);
-        this.appControlSubject.next(flattenedApps);
-      });
-  }
-
-  connect(collectionViewer: CollectionViewer): Observable<XappControlRow[]> {
-    const dataMutations = [
-      this.appControlSubject.asObservable(),
-      this.sort.sortChange
-    ];
-    return merge(...dataMutations).pipe(map(() => {
-      return this.getSortedData([...this.appControlSubject.getValue()]);
-    }));
-  }
-
-  disconnect(collectionViewer: CollectionViewer): void {
-    this.appControlSubject.complete();
-    this.loadingSubject.complete();
-  }
-
-  private flatten(allxappdata: XMDeployedApp[]): XappControlRow[]  {
-    const xAppInstances: XappControlRow[] = [];
-    for (const xapp of allxappdata) {
-      if (!xapp.instances) {
-        const row: XappControlRow = {
-          xapp: xapp.name,
-          instance: this.emptyInstances
-        };
-        xAppInstances.push(row);
-      } else {
-        for (const ins of xapp.instances) {
-          const row: XappControlRow = {
-            xapp: xapp.name,
-            instance: ins
-          };
-          xAppInstances.push(row);
-        }
-      }
-    }
-    return xAppInstances;
-  }
-
-  private getSortedData(data: XappControlRow[]) {
-    if (!this.sort.active || this.sort.direction === '') {
-      return data;
-    }
-
-    return data.sort((a, b) => {
-      const isAsc = this.sort.direction === 'asc';
-      switch (this.sort.active) {
-        case 'xapp': return compare(a.xapp, b.xapp, isAsc);
-        case 'name': return compare(a.instance.name, b.instance.name, isAsc);
-        case 'status': return compare(a.instance.status, b.instance.status, isAsc);
-        case 'ip': return compare(a.instance.ip, b.instance.ip, isAsc);
-        case 'port': return compare(a.instance.port, b.instance.port, isAsc);
-        default: return 0;
-      }
-    });
-  }
-}
-
-function compare(a: any, b: any, isAsc: boolean) {
-  return (a < b ? -1 : 1) * (isAsc ? 1 : -1);
-}
diff --git a/dashboard/webapp-frontend/src/app/control/control.component.html b/dashboard/webapp-frontend/src/app/control/control.component.html
deleted file mode 100644 (file)
index e3258b6..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-<!--
-  ========================LICENSE_START=================================
-  O-RAN-SC
-  %%
-  Copyright (C) 2019 AT&T Intellectual Property
-  %%
-  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
-  
-  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===================================
-  -->
-<div class="control__section">
-  <rd-ran-control></rd-ran-control>
-  <hr>
-  <rd-app-control></rd-app-control>
-</div>
diff --git a/dashboard/webapp-frontend/src/app/control/control.component.scss b/dashboard/webapp-frontend/src/app/control/control.component.scss
deleted file mode 100644 (file)
index f06d0ce..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-.control__section {
-  background-color: transparent;
-}
diff --git a/dashboard/webapp-frontend/src/app/control/control.component.spec.ts b/dashboard/webapp-frontend/src/app/control/control.component.spec.ts
deleted file mode 100644 (file)
index eb7d064..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { ControlComponent } from './control.component';
-
-describe('ControlComponent', () => {
-  let component: ControlComponent;
-  let fixture: ComponentFixture<ControlComponent>;
-
-  beforeEach(async(() => {
-    TestBed.configureTestingModule({
-      declarations: [ ControlComponent ]
-    })
-    .compileComponents();
-  }));
-
-  beforeEach(() => {
-    fixture = TestBed.createComponent(ControlComponent);
-    component = fixture.componentInstance;
-    fixture.detectChanges();
-  });
-
-  it('should create', () => {
-    expect(component).toBeTruthy();
-  });
-});
diff --git a/dashboard/webapp-frontend/src/app/control/control.component.ts b/dashboard/webapp-frontend/src/app/control/control.component.ts
deleted file mode 100644 (file)
index 18545af..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { Component, OnInit } from '@angular/core';
-
-@Component({
-  selector: 'rd-control',
-  templateUrl: './control.component.html',
-  styleUrls: ['./control.component.scss']
-})
-export class ControlComponent implements OnInit {
-
-  constructor() { }
-
-  ngOnInit() {
-  }
-
-}
index 5dd1c36..2970209 100644 (file)
@@ -3,6 +3,7 @@
   O-RAN-SC
   %%
   Copyright (C) 2019 AT&T Intellectual Property
+  Modifications Copyright (C) 2019 Nordix Foundation
   %%
   Licensed under the Apache License, Version 2.0 (the "License");
   you may not use this file except in compliance with the License.
@@ -20,5 +21,7 @@
 <div class="copyright__text" [ngClass]="{'footer-dark': darkMode}">
   Copyright (C) 2019 AT&T Intellectual Property. Licensed under the Apache License, Version 2.0.
   <br/>
+  Modifications Copyright (C) 2019 Nordix Foundation
+  <br/>
   Version {{dashboardVersion}}
 </div>
index e119d70..66430ec 100644 (file)
@@ -3,6 +3,7 @@
  * O-RAN-SC
  * %%
  * Copyright (C) 2019 AT&T Intellectual Property
+ * Modifications Copyright (C) 2019 Nordix Foundation
  * %%
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -40,7 +41,8 @@ export class FooterComponent implements OnInit {
               public ui: UiService ) { }
 
   ngOnInit() {
-    this.dashboardService.getVersion().subscribe((res: DashboardSuccessTransport) => this.dashboardVersion = res.data);
+    this.dashboardVersion = '0.0';
+    //this.dashboardService.getVersion().subscribe((res: DashboardSuccessTransport) => this.dashboardVersion = res.data);
     this.ui.darkModeState.subscribe((isDark) => {
       this.darkMode = isDark;
     });
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.html b/dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.html
deleted file mode 100644 (file)
index 0642baa..0000000
+++ /dev/null
@@ -1,54 +0,0 @@
-<!--
-  ========================LICENSE_START=================================
-  O-RAN-SC
-  %%
-  Copyright (C) 2019 AT&T Intellectual Property
-  %%
-  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
-  
-  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===================================
-  -->
-
-<div mat-dialog-title>
-    Setup RAN Connection
-</div>
-<form [formGroup]="ranDialogForm" novalidate autocomplete="off" (ngSubmit)="setupConnection(ranDialogForm.value)">
-  <div mat-dialog-content>
-    <div name="rantype">
-      <label id="request-type-radio-group-label">RAN type:</label>
-      <mat-radio-group aria-label="RAN Type" formControlName="ranType">
-        <mat-radio-button class="ran-type-radio-button" value="endc">EN-DC</mat-radio-button>
-        <mat-radio-button class="ran-type-radio-button" value="x2">X2</mat-radio-button>
-      </mat-radio-group>
-    </div>
-    <mat-form-field class="input-display-block">
-      <input matInput type="text" placeholder="RAN Name" formControlName="ranName">
-      <mat-hint align="end">Example: ABCD123456</mat-hint>
-      <mat-error *ngIf="validateControl('ranName') && hasError('ranName', 'required')">Name is required</mat-error>
-      <mat-error *ngIf="hasError('ranName', 'length')">Valid name is required</mat-error>
-    </mat-form-field>
-    <mat-form-field class="input-display-block">
-      <input matInput type="text" placeholder="IP" formControlName="ranIp">
-      <mat-error *ngIf="validateControl('ranIp') && hasError('ranIp', 'required')">IP is required</mat-error>
-      <mat-error *ngIf="hasError('ranIp', 'pattern')">Valid IP is required</mat-error>
-    </mat-form-field>
-    <mat-form-field class="input-display-block">
-      <input matInput type="text" placeholder="Port" formControlName="ranPort">
-      <mat-error *ngIf="validateControl('ranPort') && hasError('ranPort', 'required')">Port is required</mat-error>
-      <mat-error *ngIf="hasError('ranPort', 'pattern')">Valid port number is required</mat-error>
-    </mat-form-field>
-  </div>
-  <div mat-dialog-actions class="modal-footer justify-content-center">
-    <button class="mat-raised-button" (click)="onCancel()">Cancel</button>
-    <button class="mat-raised-button mat-primary" [disabled]="!ranDialogForm.valid || processing">Connect</button>
-  </div>
-</form>
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.scss b/dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.scss
deleted file mode 100644 (file)
index 484ceb9..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
- /* used to place form fields on separate lines/rows in dialog */
-.input-display-block {
-  display: block;
-}
-
-/* leave a bit of space */
-.ran-type-radio-button {
-  margin-left: 5px;
-}
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.ts b/dashboard/webapp-frontend/src/app/ran-control/ran-connection-dialog.component.ts
deleted file mode 100644 (file)
index ad87121..0000000
+++ /dev/null
@@ -1,124 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { HttpErrorResponse, HttpResponse } from '@angular/common/http';
-import { Component, OnInit } from '@angular/core';
-import { FormControl, FormGroup, Validators } from '@angular/forms';
-import { MatDialogRef } from '@angular/material/dialog';
-import { Observable } from 'rxjs';
-import { finalize } from 'rxjs/operators';
-import { E2SetupRequest, RanDialogFormData } from '../interfaces/e2-mgr.types';
-import { E2ManagerService } from '../services/e2-mgr/e2-mgr.service';
-import { ErrorDialogService } from '../services/ui/error-dialog.service';
-import { LoadingDialogService } from '../services/ui/loading-dialog.service';
-import { NotificationService } from '../services/ui/notification.service';
-
-@Component({
-  selector: 'rd-ran-control-connect-dialog',
-  templateUrl: './ran-connection-dialog.component.html',
-  styleUrls: ['./ran-connection-dialog.component.scss']
-})
-
-export class RanControlConnectDialogComponent implements OnInit {
-
-  public ranDialogForm: FormGroup;
-  public processing = false;
-
-  constructor(
-    private dialogRef: MatDialogRef<RanControlConnectDialogComponent>,
-    private service: E2ManagerService,
-    private errorService: ErrorDialogService,
-    private loadingDialogService: LoadingDialogService,
-    private notifService: NotificationService) {
-    // opens with empty fields; accepts no data to display
-  }
-
-  ngOnInit() {
-    const namePattern = /^([A-Z0-9])+$/;
-    // tslint:disable-next-line:max-line-length
-    const ipPattern = /((((([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5]))$)|(^((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?$))/;
-    const portPattern = /^([0-9]{1,4}|[1-5][0-9]{4}|6[0-4][0-9]{3}|65[0-4][0-9]{2}|655[0-2][0-9]|6553[0-5])$/;
-    this.ranDialogForm = new FormGroup({
-      ranType: new FormControl('endc'),
-      ranName: new FormControl('', [Validators.required, Validators.pattern(namePattern)]),
-      ranIp: new FormControl('', [Validators.required, Validators.pattern(ipPattern)]),
-      ranPort: new FormControl('', [Validators.required, Validators.pattern(portPattern)])
-    });
-  }
-
-  onCancel() {
-    this.dialogRef.close(false);
-  }
-
-  setupConnection = (ranFormValue: RanDialogFormData) => {
-    if (!this.ranDialogForm.valid) {
-      // should never happen
-      return;
-    }
-    this.processing = true;
-    const setupRequest: E2SetupRequest = {
-      ranName: ranFormValue.ranName.trim(),
-      ranIp: ranFormValue.ranIp.trim(),
-      ranPort: ranFormValue.ranPort.trim()
-    };
-    this.loadingDialogService.startLoading('Setting up connection');
-    let observable: Observable<HttpResponse<Object>>;
-    if (ranFormValue.ranType === 'endc') {
-      observable = this.service.endcSetup(setupRequest);
-    } else {
-      observable = this.service.x2Setup(setupRequest);
-    }
-    observable
-      .pipe(
-        finalize(() => this.loadingDialogService.stopLoading())
-      )
-      .subscribe(
-        (response: any) => {
-          this.processing = false;
-          this.notifService.success('Connect request sent!');
-          this.dialogRef.close(true);
-        },
-        ((her: HttpErrorResponse) => {
-          this.processing = false;
-          // the error field carries the server's response
-          let msg = her.message;
-          if (her.error && her.error.message) {
-            msg = her.error.message;
-          }
-          this.errorService.displayError('Connect request failed: ' + msg);
-          // keep the dialog open
-        })
-      );
-  }
-
-  hasError(controlName: string, errorName: string) {
-    if (this.ranDialogForm.controls[controlName].hasError(errorName)) {
-      return true;
-    }
-    return false;
-  }
-
-  validateControl(controlName: string) {
-    if (this.ranDialogForm.controls[controlName].invalid && this.ranDialogForm.controls[controlName].touched) {
-      return true;
-    }
-    return false;
-  }
-
-}
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.html b/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.html
deleted file mode 100644 (file)
index 01dd292..0000000
+++ /dev/null
@@ -1,89 +0,0 @@
-<!--
-  ========================LICENSE_START=================================
-  O-RAN-SC
-  %%
-  Copyright (C) 2019 AT&T Intellectual Property
-  %%
-  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
-
-  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===================================
--->
-
-<div class="ran-control__section">
-  <h3 class="rd-global-page-title">RAN Connections</h3>
-
-  <button mat-raised-button (click)="setupRANConnection()">Setup Connection..</button>
-  <button mat-raised-button color="warn" class="disconnect-all-button"
-    (click)="disconnectAllRANConnections()">Disconnect All</button>
-
-  <table mat-table class="ran-control-table mat-elevation-z8" [dataSource]="dataSource">
-
-    <ng-template #noValue></ng-template>
-
-    <ng-container matColumnDef="nbId">
-      <mat-header-cell *matHeaderCellDef>Nodeb ID</mat-header-cell>
-      <mat-cell *matCellDef="let ran">
-        <div *ngIf="ran.nodebIdentity.globalNbId; else noValue">{{ran.nodebIdentity.globalNbId.nbId}}</div>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="nodeType">
-      <mat-header-cell *matHeaderCellDef>Node Type</mat-header-cell>
-      <mat-cell *matCellDef="let ran">
-        <div *ngIf="ran.nodebStatus; else noValue">{{ran.nodebStatus.nodeType}}</div>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="ranName">
-      <mat-header-cell *matHeaderCellDef>RAN Name</mat-header-cell>
-      <mat-cell *matCellDef="let ran">
-        <div *ngIf="ran.nodebIdentity; else noValue">{{ran.nodebIdentity.inventoryName}}</div>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="ranIp">
-      <mat-header-cell *matHeaderCellDef>IP</mat-header-cell>
-      <mat-cell *matCellDef="let ran">
-        <div *ngIf="ran.nodebStatus; else noValue">{{ran.nodebStatus.ip}}</div>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="ranPort">
-      <mat-header-cell *matHeaderCellDef>Port</mat-header-cell>
-      <mat-cell *matCellDef="let ran">
-        <div *ngIf="ran.nodebStatus; else noValue">{{ran.nodebStatus.port}}</div>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="connectionStatus">
-      <mat-header-cell *matHeaderCellDef>Connection Status</mat-header-cell>
-      <mat-cell *matCellDef="let ran">
-        <div *ngIf="ran.nodebStatus; else noValue">{{ran.nodebStatus.connectionStatus}}</div>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="noRecordsFound">
-      <mat-footer-cell *matFooterCellDef>No records found.</mat-footer-cell>
-    </ng-container>
-
-    <mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
-    <mat-row *matRowDef="let row; columns: displayedColumns"></mat-row>
-    <mat-footer-row *matFooterRowDef="['noRecordsFound']" [ngClass]="{'display-none': dataSource.rowCount > 0}">
-    </mat-footer-row>
-
-  </table>
-
-  <div class="spinner-container" *ngIf="dataSource.loading$ | async">
-    <mat-spinner diameter=50></mat-spinner>
-  </div>
-
-</div>
\ No newline at end of file
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.scss b/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.scss
deleted file mode 100644 (file)
index c86d062..0000000
+++ /dev/null
@@ -1,51 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- *
- * 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===================================
- */
- .ran-control__section {
-}
-
-.disconnect-all-button {
-    float: right;
-}
-
-.ran-control-table {
-    width: 100%;
-    min-height: 100px;
-    margin-top: 10px;
-    background-color:transparent;
-}
-
-.spinner-container {
-    height: 100px;
-    width: 100px;
-}
-
-.spinner-container mat-spinner {
-    margin: 0 auto 0 auto;
-}
-
-.version__text {
-    color: gray;
-    letter-spacing: 0.1rem;
-    font-size: 10px;
-}
-
-.display-none {
-    display: none;
-}
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.spec.ts b/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.spec.ts
deleted file mode 100644 (file)
index aa0e8b8..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { RanControlComponent } from './ran-control.component';
-
-describe('RanControlComponent', () => {
-  let component: RanControlComponent;
-  let fixture: ComponentFixture<RanControlComponent>;
-
-  beforeEach(async(() => {
-    TestBed.configureTestingModule({
-      declarations: [ RanControlComponent ]
-    })
-    .compileComponents();
-  }));
-
-  beforeEach(() => {
-    fixture = TestBed.createComponent(RanControlComponent);
-    component = fixture.componentInstance;
-    fixture.detectChanges();
-  });
-
-  it('should create', () => {
-    expect(component).toBeTruthy();
-  });
-});
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.ts b/dashboard/webapp-frontend/src/app/ran-control/ran-control.component.ts
deleted file mode 100644 (file)
index b5aba66..0000000
+++ /dev/null
@@ -1,107 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { HttpErrorResponse } from '@angular/common/http';
-import { Component, OnInit } from '@angular/core';
-import { MatDialog } from '@angular/material/dialog';
-import { finalize } from 'rxjs/operators';
-import { E2ManagerService } from '../services/e2-mgr/e2-mgr.service';
-import { ConfirmDialogService } from '../services/ui/confirm-dialog.service';
-import { ErrorDialogService } from '../services/ui/error-dialog.service';
-import { LoadingDialogService } from '../services/ui/loading-dialog.service';
-import { NotificationService } from '../services/ui/notification.service';
-import { RanControlConnectDialogComponent } from './ran-connection-dialog.component';
-import { RANControlDataSource } from './ran-control.datasource';
-import { UiService } from '../services/ui/ui.service';
-
-@Component({
-  selector: 'rd-ran-control',
-  templateUrl: './ran-control.component.html',
-  styleUrls: ['./ran-control.component.scss']
-})
-export class RanControlComponent implements OnInit {
-
-  darkMode: boolean;
-  panelClass: string = "";
-  displayedColumns: string[] = ['nbId', 'nodeType', 'ranName', 'ranIp', 'ranPort', 'connectionStatus'];
-  dataSource: RANControlDataSource;
-
-  constructor(private e2MgrSvc: E2ManagerService,
-    private errorDialogService: ErrorDialogService,
-    private confirmDialogService: ConfirmDialogService,
-    private notificationService: NotificationService,
-    private loadingDialogService: LoadingDialogService,
-    public dialog: MatDialog,
-    public ui: UiService) { }
-
-  ngOnInit() {
-    this.dataSource = new RANControlDataSource(this.e2MgrSvc, this.notificationService);
-    this.dataSource.loadTable();
-    this.ui.darkModeState.subscribe((isDark) => {
-      this.darkMode = isDark;
-    });
-  }
-
-  setupRANConnection() {
-    if (this.darkMode) {
-      this.panelClass = "dark-theme";
-    } else {
-      this.panelClass = "";
-    }
-    const dialogRef = this.dialog.open(RanControlConnectDialogComponent, {
-      panelClass: this.panelClass,
-      width: '450px'
-    });
-    dialogRef.afterClosed()
-      .subscribe((result: boolean) => {
-      if (result) {
-        this.dataSource.loadTable();
-      }
-    });
-  }
-
-  disconnectAllRANConnections() {
-    const aboutError = 'Disconnect all RAN Connections Failed: ';
-    this.confirmDialogService.openConfirmDialog('Are you sure you want to disconnect all RAN connections?')
-      .afterClosed().subscribe( (res: boolean) => {
-        if (res) {
-          this.loadingDialogService.startLoading("Disconnecting");
-          this.e2MgrSvc.nodebPut()
-            .pipe(
-              finalize(() => this.loadingDialogService.stopLoading())
-            )
-            .subscribe(
-            ( body: any ) => {
-              this.notificationService.success('Disconnect succeeded!');
-              this.dataSource.loadTable();
-            },
-            (her: HttpErrorResponse) => {
-              // the error field should have an ErrorTransport object
-              let msg = her.message;
-              if (her.error && her.error.message) {
-                msg = her.error.message;
-              }
-              this.errorDialogService.displayError('Disconnect failed: ' + msg);
-            }
-          );
-        }
-      });
-  }
-
-}
diff --git a/dashboard/webapp-frontend/src/app/ran-control/ran-control.datasource.ts b/dashboard/webapp-frontend/src/app/ran-control/ran-control.datasource.ts
deleted file mode 100644 (file)
index b23a3cd..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
-import { CollectionViewer, DataSource } from '@angular/cdk/collections';
-import { HttpErrorResponse } from '@angular/common/http';
-import { Observable } from 'rxjs/Observable';
-import { BehaviorSubject } from 'rxjs/BehaviorSubject';
-import { of } from 'rxjs/observable/of';
-import { catchError, finalize } from 'rxjs/operators';
-import { E2RanDetails } from '../interfaces/e2-mgr.types';
-import { E2ManagerService } from '../services/e2-mgr/e2-mgr.service';
-import { NotificationService } from '../services/ui/notification.service';
-
-export class RANControlDataSource extends DataSource<E2RanDetails> {
-
-  private ranControlSubject = new BehaviorSubject<E2RanDetails[]>([]);
-
-  private loadingSubject = new BehaviorSubject<boolean>(false);
-
-  public loading$ = this.loadingSubject.asObservable();
-
-  public rowCount = 1; // hide footer during intial load
-
-  constructor(private e2MgrSvcservice: E2ManagerService,
-    private notificationService: NotificationService) {
-    super();
-  }
-
-  loadTable() {
-    this.loadingSubject.next(true);
-    this.e2MgrSvcservice.getRan()
-      .pipe(
-        catchError( (her: HttpErrorResponse) => {
-          console.log('RANControlDataSource failed: ' + her.message);
-          this.notificationService.error('Failed to get RAN details: ' + her.message);
-          return of([]);
-        }),
-        finalize( () =>  this.loadingSubject.next(false) )
-      )
-      .subscribe( (ranControl: E2RanDetails[] ) => {
-        this.rowCount = ranControl.length;
-        this.ranControlSubject.next(ranControl);
-      });
-  }
-
-  connect(collectionViewer: CollectionViewer): Observable<E2RanDetails[]> {
-    return this.ranControlSubject.asObservable();
-  }
-
-  disconnect(collectionViewer: CollectionViewer): void {
-    this.ranControlSubject.complete();
-    this.loadingSubject.complete();
-  }
-
-}
index 378374a..3ba8a40 100644 (file)
@@ -35,15 +35,10 @@ import { ChartsModule } from 'ng2-charts';
 import { MDBBootstrapModule } from 'angular-bootstrap-md';
 import { FormsModule, ReactiveFormsModule } from '@angular/forms';
 import { ToastrModule } from 'ngx-toastr';
-
-import { AddDashboardUserDialogComponent } from './user/add-dashboard-user-dialog/add-dashboard-user-dialog.component';
-import { AppControlComponent } from './app-control/app-control.component';
 import { AppMgrService } from './services/app-mgr/app-mgr.service';
 import { ConfirmDialogComponent } from './ui/confirm-dialog/confirm-dialog.component';
-import { ControlComponent } from './control/control.component';
 import { DashboardService } from './services/dashboard/dashboard.service';
 import { E2ManagerService } from './services/e2-mgr/e2-mgr.service';
-import { EditDashboardUserDialogComponent } from './user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component';
 import { ErrorDialogComponent } from './ui/error-dialog/error-dialog.component';
 import { ErrorDialogService } from './services/ui/error-dialog.service';
 import { FlexLayoutModule } from '@angular/flex-layout';
@@ -56,21 +51,14 @@ import { PolicyCardComponent } from './ui/policy-card/policy-card.component';
 import { PolicyControlComponent } from './policy-control/policy-control.component';
 import { PolicyInstanceComponent } from './policy-control/policy-instance.component';
 import { PolicyInstanceDialogComponent } from './policy-control/policy-instance-dialog.component';
-import { RanControlComponent } from './ran-control/ran-control.component';
-import { RanControlConnectDialogComponent } from './ran-control/ran-connection-dialog.component';
 import { RdComponent } from './rd.component';
 import { RdRoutingModule } from './rd-routing.module';
 import { SidenavListComponent } from './navigation/sidenav-list/sidenav-list.component';
 import { UiService } from './services/ui/ui.service';
-import { UserComponent } from './user/user.component';
 
 @NgModule({
-  declarations: [
-    AddDashboardUserDialogComponent,
-    AppControlComponent,
+  declarations: [   
     ConfirmDialogComponent,
-    ControlComponent,
-    EditDashboardUserDialogComponent,
     ErrorDialogComponent,
     FooterComponent,
     LoadingDialogComponent,
@@ -80,11 +68,8 @@ import { UserComponent } from './user/user.component';
     PolicyControlComponent,
     PolicyInstanceComponent,
     PolicyInstanceDialogComponent,
-    RanControlComponent,
-    RanControlConnectDialogComponent,
     RdComponent,
     SidenavListComponent,   
-    UserComponent
   ],
   imports: [
     BrowserModule,
@@ -140,17 +125,13 @@ import { UserComponent } from './user/user.component';
     MatSidenavModule,
     MatSliderModule,
     MatSlideToggleModule,
-    MatTabsModule,
-    RanControlConnectDialogComponent
+    MatTabsModule
   ],
-  entryComponents: [
-    AddDashboardUserDialogComponent,
-    ConfirmDialogComponent,
-    EditDashboardUserDialogComponent,
+  entryComponents: [  
+    ConfirmDialogComponent,   
     ErrorDialogComponent,
     LoadingDialogComponent,
-    PolicyInstanceDialogComponent,
-    RanControlConnectDialogComponent
+    PolicyInstanceDialogComponent
   ],
   providers: [
     AppMgrService,
diff --git a/dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.html b/dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.html
deleted file mode 100644 (file)
index ef29a83..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-<!--
-  ========================LICENSE_START=================================
-  O-RAN-SC
-  %%
-  Copyright (C) 2019 AT&T Intellectual Property
-  %%
-  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
-
-  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===================================
--->
-<div mat-dialog-title>
-  Add Dashboard User
-</div>
-
-<form [formGroup]="addUserDialogForm" novalidate autocomplete="off">
-  <div mat-dialog-content>
-    <mat-form-field class="input-display-block">
-      <input matInput type="text" placeholder="First Name" formControlName="firstName">
-    </mat-form-field>
-    <mat-form-field class="input-display-block">
-      <input matInput type="text" placeholder="Last Name" formControlName="lastName">
-    </mat-form-field>
-  </div>
-  <div name="status">
-    <label id="request-type-radio-group-label">Status:</label>
-    <mat-radio-group aria-label="status" formControlName="status">
-      <mat-radio-button value="Active">Active</mat-radio-button>
-      <mat-radio-button value="Inactive">Inactive</mat-radio-button>
-    </mat-radio-group>
-  </div>
-  <div mat-dialog-actions class="modal-footer justify-content-center">
-    <button class="mat-raised-button" (click)="onCancel()">Cancel</button>
-    <button class="mat-raised-button mat-primary" [disabled]="!addUserDialogForm.valid" (click)="addUser(addUserDialogForm.value)" >Add</button>
-  </div>
-</form>
diff --git a/dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.scss b/dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.scss
deleted file mode 100644 (file)
index 9717962..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
-.input-display-block {
-    display: block;
-}
\ No newline at end of file
diff --git a/dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.ts b/dashboard/webapp-frontend/src/app/user/add-dashboard-user-dialog/add-dashboard-user-dialog.component.ts
deleted file mode 100644 (file)
index faca105..0000000
+++ /dev/null
@@ -1,61 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
-import { Component, OnInit } from '@angular/core';
-import { FormControl, FormGroup, Validators } from '@angular/forms';
-import { MatDialogRef } from '@angular/material/dialog';
-import { DashboardService } from '../../services/dashboard/dashboard.service';
-import { ErrorDialogService } from '../../services/ui/error-dialog.service';
-
-@Component({
-  selector: 'add-dashboard-user-dialog',
-  templateUrl: './add-dashboard-user-dialog.component.html',
-  styleUrls: ['./add-dashboard-user-dialog.component.scss']
-})
-export class AddDashboardUserDialogComponent implements OnInit {
-
-  public addUserDialogForm: FormGroup;
-
-  constructor(
-    private dialogRef: MatDialogRef<AddDashboardUserDialogComponent>,
-    private dashSvc: DashboardService,
-    private errorService: ErrorDialogService) { }
-
-  ngOnInit() {
-    this.addUserDialogForm = new FormGroup({
-      firstName: new FormControl('', [Validators.required]),
-      lastName: new FormControl('', [Validators.required]),
-      status: new FormControl('', [Validators.required])
-    });
-  }
-
-  onCancel() {
-    this.dialogRef.close(false);
-  }
-
-  public addUser = (FormValue) => {
-    if (this.addUserDialogForm.valid) {
-      // send the request to backend when it's ready
-      const aboutError = 'Not implemented yet';
-      this.errorService.displayError(aboutError);
-    }
-  }
-
-}
diff --git a/dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.html b/dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.html
deleted file mode 100644 (file)
index f64d9df..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-<!--
-  ========================LICENSE_START=================================
-  O-RAN-SC
-  %%
-  Copyright (C) 2019 AT&T Intellectual Property
-  %%
-  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
-
-  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===================================
--->
-<div mat-dialog-title>
-  Edit Dashboard User
-</div>
-  
-<form [formGroup]="editUserDialogForm" novalidate autocomplete="off">
-  <div mat-dialog-content>
-    <mat-form-field class="input-display-block">
-      <input matInput type="text" placeholder="First Name" formControlName="firstName" >
-    </mat-form-field>
-    <mat-form-field class="input-display-block">
-      <input matInput type="text" placeholder="Last Name" formControlName="lastName" >
-    </mat-form-field>
-  </div>
-  <div name="status">
-    <label id="request-type-radio-group-label">Status:</label>
-    <mat-radio-group aria-label="status" formControlName="status">
-      <mat-radio-button value="Active">Active</mat-radio-button>
-      <mat-radio-button value="Inactive">Inactive</mat-radio-button>
-    </mat-radio-group>
-  </div>
-  <div mat-dialog-actions class="modal-footer justify-content-center">
-    <button class="mat-raised-button" (click)="onCancel()">Cancel</button>
-    <button class="mat-raised-button mat-primary" [disabled]="!editUserDialogForm.valid" (click)="editUser(editUserDialogForm.value)">Update</button>
-  </div>
-</form>
diff --git a/dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.scss b/dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.scss
deleted file mode 100644 (file)
index 9717962..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
-.input-display-block {
-    display: block;
-}
\ No newline at end of file
diff --git a/dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.ts b/dashboard/webapp-frontend/src/app/user/edit-dashboard-user-dialog/edit-dashboard-user-dialog.component.ts
deleted file mode 100644 (file)
index aef8860..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-
-import { Component, Inject, OnInit } from '@angular/core';
-import { FormControl, FormGroup, Validators } from '@angular/forms';
-import { MatDialogRef, MAT_DIALOG_DATA } from '@angular/material/dialog';
-import { DashboardService } from '../../services/dashboard/dashboard.service';
-import { ErrorDialogService } from '../../services/ui/error-dialog.service';
-
-
-@Component({
-  selector: 'rd-edit-app-dashboard-user-dialog',
-  templateUrl: './edit-dashboard-user-dialog.component.html',
-  styleUrls: ['./edit-dashboard-user-dialog.component.scss']
-})
-export class EditDashboardUserDialogComponent implements OnInit {
-
-  public editUserDialogForm: FormGroup;
-
-  constructor(
-    @Inject(MAT_DIALOG_DATA) public data,
-    private dialogRef: MatDialogRef<EditDashboardUserDialogComponent>,
-    private dashSvc: DashboardService,
-    private errorService: ErrorDialogService) { }
-
-  ngOnInit() {
-    this.editUserDialogForm = new FormGroup({
-      firstName: new FormControl(this.data.firstName , [Validators.required]),
-      lastName: new FormControl(this.data.lastName, [Validators.required]),
-      status: new FormControl(this.data.status, [Validators.required])
-    });
-  }
-
-  onCancel() {
-    this.dialogRef.close(false);
-  }
-
-  public editUser = (FormValue) => {
-    if (this.editUserDialogForm.valid) {
-      // send the request to backend when it's ready
-      const aboutError = 'Not implemented yet';
-      this.errorService.displayError(aboutError);
-    }
-  }
-
-}
diff --git a/dashboard/webapp-frontend/src/app/user/user.component.html b/dashboard/webapp-frontend/src/app/user/user.component.html
deleted file mode 100644 (file)
index 5bffc79..0000000
+++ /dev/null
@@ -1,76 +0,0 @@
-<!--
-  ========================LICENSE_START=================================
-  O-RAN-SC
-  %%
-  Copyright (C) 2019 AT&T Intellectual Property
-  %%
-  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
-  
-  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===================================
--->
-<div class="user__section">
-  <h3 class="rd-global-page-title">Users</h3>
-  <button mat-raised-button (click)="addUser()">Add User</button>
-  <div class="spinner-container" *ngIf="dataSource.loading$ | async">
-    <mat-spinner></mat-spinner>
-  </div>
-  <table mat-table [dataSource]="dataSource" matSort class="user-table mat-elevation-z8">
-
-    <ng-container matColumnDef="loginId">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> Login ID </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.loginId}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="firstName">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> First Name </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.firstName}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="lastName">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> Last Name </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.lastName}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="active">
-      <mat-header-cell *matHeaderCellDef mat-sort-header> Active? </mat-header-cell>
-      <mat-cell *matCellDef="let element"> {{element.active}} </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="action">
-      <mat-header-cell *matHeaderCellDef> Action </mat-header-cell>
-      <mat-cell *matCellDef="let element">
-        <div class="user-button-row">
-          <button mat-icon-button (click)="editUser(element)">
-            <mat-icon matTooltip="Edit properties">edit</mat-icon>
-          </button>
-          <button mat-icon-button color="warn" (click)="deleteUser(element)">
-            <mat-icon matTooltip="Delete user">delete</mat-icon>
-          </button>
-        </div>
-      </mat-cell>
-    </ng-container>
-
-    <ng-container matColumnDef="noRecordsFound">
-      <mat-footer-cell *matFooterCellDef>No records found.</mat-footer-cell>
-    </ng-container>
-
-    <mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
-    <mat-row *matRowDef="let row; columns: displayedColumns;"></mat-row>
-    <mat-footer-row *matFooterRowDef="['noRecordsFound']" [ngClass]="{'display-none': dataSource.rowCount > 0}"></mat-footer-row>
-
-  </table>
-
-  <div class="spinner-container" *ngIf="dataSource.loading$ | async">
-    <mat-spinner diameter=50></mat-spinner>
-  </div>
-
-</div>
\ No newline at end of file
diff --git a/dashboard/webapp-frontend/src/app/user/user.component.scss b/dashboard/webapp-frontend/src/app/user/user.component.scss
deleted file mode 100644 (file)
index f3a5d89..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-.user__section {
-}
-
-.spinner-container {
-    height: 360px;
-    width: 390px;
-    position: fixed;
-}
-
-.spinner-container mat-spinner {
-    margin: 130px auto 0 auto;
-}
-
-.user-table {
-    width: 99%;
-    min-height: 150px;
-    margin-top: 10px;
-    background-color: transparent;
-}
-
-.user-button-row button {
-    margin-right: 5px;
-}
-
-.display-none {
-    display: none;
-}
diff --git a/dashboard/webapp-frontend/src/app/user/user.component.spec.ts b/dashboard/webapp-frontend/src/app/user/user.component.spec.ts
deleted file mode 100644 (file)
index d4d822e..0000000
+++ /dev/null
@@ -1,44 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- * 
- * 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===================================
- */
-import { async, ComponentFixture, TestBed } from '@angular/core/testing';
-
-import { UserComponent } from './user.component';
-
-describe('UserComponent', () => {
-  let component: AdminComponent;
-  let fixture: ComponentFixture<UserComponent>;
-
-  beforeEach(async(() => {
-    TestBed.configureTestingModule({
-      declarations: [UserComponent]
-    })
-    .compileComponents();
-  }));
-
-  beforeEach(() => {
-    fixture = TestBed.createComponent(UserComponent);
-    component = fixture.componentInstance;
-    fixture.detectChanges();
-  });
-
-  it('should create', () => {
-    expect(component).toBeTruthy();
-  });
-});
diff --git a/dashboard/webapp-frontend/src/app/user/user.component.ts b/dashboard/webapp-frontend/src/app/user/user.component.ts
deleted file mode 100644 (file)
index a3573c0..0000000
+++ /dev/null
@@ -1,97 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- *
- * 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===================================
- */
-import { Component, OnInit, ViewChild } from '@angular/core';
-import { MatDialog } from '@angular/material/dialog';
-import { MatSort } from '@angular/material/sort';
-import { DashboardService } from '../services/dashboard/dashboard.service';
-import { ErrorDialogService } from '../services/ui/error-dialog.service';
-import { EcompUser } from './../interfaces/dashboard.types';
-import { NotificationService } from './../services/ui/notification.service';
-import { UserDataSource } from './user.datasource';
-import { AddDashboardUserDialogComponent } from './add-dashboard-user-dialog/add-dashboard-user-dialog.component';
-import { EditDashboardUserDialogComponent } from './edit-dashboard-user-dialog/edit-dashboard-user-dialog.component';
-import { UiService } from '../services/ui/ui.service';
-
-@Component({
-  selector: 'rd-user',
-  templateUrl: './user.component.html',
-  styleUrls: ['./user.component.scss']
-})
-
-export class UserComponent implements OnInit {
-
-  darkMode: boolean;
-  panelClass: string = "";
-  displayedColumns: string[] = ['loginId', 'firstName', 'lastName', 'active', 'action'];
-  dataSource: UserDataSource;
-  @ViewChild(MatSort, {static: true}) sort: MatSort;
-
-  constructor(
-    private dashboardSvc: DashboardService,
-    private errorService: ErrorDialogService,
-    private notificationService: NotificationService,
-    public dialog: MatDialog,
-    public ui: UiService) { }
-
-  ngOnInit() {
-    this.dataSource = new UserDataSource(this.dashboardSvc, this.sort, this.notificationService);
-    this.dataSource.loadTable();
-    this.ui.darkModeState.subscribe((isDark) => {
-      this.darkMode = isDark;
-    });
-  }
-
-  editUser(user: EcompUser) {
-    if (this.darkMode) {
-      this.panelClass = "dark-theme"
-    } else {
-      this.panelClass = "";
-    }
-    const dialogRef = this.dialog.open(EditDashboardUserDialogComponent, {
-      panelClass: this.panelClass,
-      width: '450px',
-      data: user
-    });
-    dialogRef.afterClosed().subscribe(result => {
-      this.dataSource.loadTable();
-    });
-  }
-
-  deleteUser() {
-    const aboutError = 'Not implemented (yet).';
-    this.errorService.displayError(aboutError);
-  }
-
-  addUser() {
-    if (this.darkMode) {
-      this.panelClass = "dark-theme"
-    } else {
-      this.panelClass = "";
-    }
-    const dialogRef = this.dialog.open(AddDashboardUserDialogComponent, {
-      panelClass: this.panelClass,
-      width: '450px'
-    });
-    dialogRef.afterClosed().subscribe(result => {
-      this.dataSource.loadTable();
-    });
-  }
-}
-
diff --git a/dashboard/webapp-frontend/src/app/user/user.datasource.ts b/dashboard/webapp-frontend/src/app/user/user.datasource.ts
deleted file mode 100644 (file)
index 6b7805b..0000000
+++ /dev/null
@@ -1,102 +0,0 @@
-/*-
- * ========================LICENSE_START=================================
- * O-RAN-SC
- * %%
- * Copyright (C) 2019 AT&T Intellectual Property
- * %%
- * 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
- *
- * 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===================================
- */
-
-import { CollectionViewer, DataSource } from '@angular/cdk/collections';
-import { HttpErrorResponse } from '@angular/common/http';
-import { MatSort } from '@angular/material/sort';
-import { Observable } from 'rxjs/Observable';
-import { BehaviorSubject } from 'rxjs/BehaviorSubject';
-import { merge } from 'rxjs';
-import { of } from 'rxjs/observable/of';
-import { catchError, finalize, map } from 'rxjs/operators';
-import { EcompUser } from '../interfaces/dashboard.types';
-import { DashboardService } from '../services/dashboard/dashboard.service';
-import { NotificationService } from '../services/ui/notification.service';
-
-export class UserDataSource extends DataSource<EcompUser> {
-
-  private userSubject = new BehaviorSubject<EcompUser[]>([]);
-
-  private loadingSubject = new BehaviorSubject<boolean>(false);
-
-  public loading$ = this.loadingSubject.asObservable();
-
-  public rowCount = 1; // hide footer during intial load
-
-  constructor(private dashboardSvc: DashboardService,
-    private sort: MatSort,
-    private notificationService: NotificationService) {
-    super();
-  }
-
-  loadTable() {
-    this.loadingSubject.next(true);
-    this.dashboardSvc.getUsers()
-      .pipe(
-        catchError( (her: HttpErrorResponse) => {
-          console.log('UserDataSource failed: ' + her.message);
-          this.notificationService.error('Failed to get users: ' + her.message);
-          return of([]);
-        }),
-        finalize(() => this.loadingSubject.next(false))
-      )
-      .subscribe( (users: EcompUser[]) => {
-        this.rowCount = users.length;
-        this.userSubject.next(users);
-      });
-  }
-
-  connect(collectionViewer: CollectionViewer): Observable<EcompUser[]> {
-    const dataMutations = [
-      this.userSubject.asObservable(),
-      this.sort.sortChange
-    ];
-    return merge(...dataMutations).pipe(map(() => {
-      return this.getSortedData([...this.userSubject.getValue()]);
-    }));
-  }
-
-  disconnect(collectionViewer: CollectionViewer): void {
-    this.userSubject.complete();
-    this.loadingSubject.complete();
-  }
-
-  private getSortedData(data: EcompUser[]) {
-    if (!this.sort.active || this.sort.direction === '') {
-      return data;
-    }
-
-    return data.sort((a: EcompUser, b: EcompUser) => {
-      const isAsc = this.sort.direction === 'asc';
-      switch (this.sort.active) {
-        case 'loginId': return this.compare(a.loginId, b.loginId, isAsc);
-        case 'firstName': return this.compare(a.firstName, b.firstName, isAsc);
-        case 'lastName': return this.compare(a.lastName, b.lastName, isAsc);
-        case 'active': return this.compare(a.active, b.active, isAsc);
-        default: return 0;
-      }
-    });
-  }
-
-  private compare(a: any, b: any, isAsc: boolean) {
-    return (a < b ? -1 : 1) * (isAsc ? 1 : -1);
-  }
-
-}