From da620c17769c0357e4a9137eedbb7cf044cc38d4 Mon Sep 17 00:00:00 2001 From: Panagiotis Karalis Date: Thu, 18 Apr 2019 18:48:22 +0300 Subject: Bug fix for ONAP/OVP portals During portal review, some errors have been noticed and fixed. - 'no role', In the 'My Results' page are displayed also results from other users. - 'user,reviewer' role, In the 'My Results' page are appeared all results and not only for the current user. - 'administrator' role, The applications are not appeared in the application page - 'reviewer' role, Reviewers cannot submit votes and after few seconds a 'time out' is received. Change-Id: Ia9bc3c4fdcac1b37ac03adff64ff689ca2428c0f Signed-off-by: Panagiotis Karalis --- .../onap-ui/components/results/resultsController.js | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to '3rd_party/static/onap-ui/components/results') diff --git a/3rd_party/static/onap-ui/components/results/resultsController.js b/3rd_party/static/onap-ui/components/results/resultsController.js index 5983dd8..e8187f3 100644 --- a/3rd_party/static/onap-ui/components/results/resultsController.js +++ b/3rd_party/static/onap-ui/components/results/resultsController.js @@ -552,6 +552,7 @@ var start = $filter('date')(ctrl.startDate, 'yyyy-MM-dd'); var end = $filter('date')(ctrl.endDate, 'yyyy-MM-dd'); + ctrl.PageName = null; content_url += '?page=' + ctrl.currentPage; content_url += '&per_page=' + ctrl.itemsPerPage; if (start) { @@ -562,6 +563,7 @@ } if (ctrl.isUserResults) { content_url += '&signed'; + ctrl.PageName = 'MyResults'; } else { content_url += '&status={"$ne":"private"}&review'; } @@ -572,6 +574,25 @@ ctrl.totalItems = ctrl.data.pagination.total_pages * ctrl.itemsPerPage; ctrl.currentPage = ctrl.data.pagination.current_page; ctrl.numPages = ctrl.data.pagination.total_pages; + if (ctrl.PageName === 'MyResults') { + for (var i=0; i