Skip to content

Commit

Permalink
Merge pull request #612 from jembi/TB-84-update-packages
Browse files Browse the repository at this point in the history
TB-84 Update packages and lint
  • Loading branch information
bradsawadye authored Jun 12, 2023
2 parents b7ada6c + c63bd0c commit 41a88a2
Show file tree
Hide file tree
Showing 20 changed files with 4,360 additions and 6,162 deletions.
2 changes: 1 addition & 1 deletion app/scripts/controllers/auditDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ export function AuditDetailsCtrl ($scope, $uibModal, $location, $routeParams, Ap
controller: AuditsContentModalCtrl,
resolve: {
auditData: function () {
return { type: type, content: content }
return { type, content }
}
}
})
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/controllers/audits.js
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ export function AuditsCtrl ($scope, $uibModal, $location, $interval, Api, Alerti

// if patientID set then update query to include 'AND' operator
if (valueNotEmpty(patientID) === true) {
filtersObject.filters['participantObjectIdentification.participantObjectID'] = { type: 'AND', patientID: participantPatientID, objectID: objectID }
filtersObject.filters['participantObjectIdentification.participantObjectID'] = { type: 'AND', patientID: participantPatientID, objectID }
} else {
filtersObject.filters['participantObjectIdentification.participantObjectID'] = JSON.stringify(objectID)
}
Expand Down
24 changes: 12 additions & 12 deletions app/scripts/controllers/channel-tabs/routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export function channelRoutesCtrl ($scope, $timeout, Api, Alerting) {
angular.forEach(mediators, function (mediator) {
// foreach endpoint in the mediator
angular.forEach(mediator.endpoints, function (endpoint) {
$scope.mediatorRoutes.push({ fullName: mediator.name + ' - ' + endpoint.name, mediator: mediator.urn, endpoint: endpoint })
$scope.mediatorRoutes.push({ fullName: mediator.name + ' - ' + endpoint.name, mediator: mediator.urn, endpoint })
})
})
}, function () { /* server error - could not connect to API to get Mediators */ })
Expand Down Expand Up @@ -109,7 +109,7 @@ export function channelRoutesCtrl ($scope, $timeout, Api, Alerting) {
port: '',
path: '',
pathTransform: '',
primary: primary,
primary,
username: '',
password: '',
type: 'http',
Expand Down Expand Up @@ -168,18 +168,18 @@ export function channelRoutesCtrl ($scope, $timeout, Api, Alerting) {

// add mediator to channel.routes array
$scope.channel.routes.push({
name: name,
secured: secured,
host: host,
port: port,
path: path,
pathTransform: pathTransform,
primary: primary,
username: username,
password: password,
name,
secured,
host,
port,
path,
pathTransform,
primary,
username,
password,
type: routeType,
status: 'enabled',
forwardAuthHeader: forwardAuthHeader
forwardAuthHeader
})
}

Expand Down
10 changes: 5 additions & 5 deletions app/scripts/controllers/channelMonitoring.js
Original file line number Diff line number Diff line change
Expand Up @@ -87,31 +87,31 @@ export function ChannelMonitoringCtrl ($scope, $uibModal, $interval, $location,
if (parseInt(channelsResults[0].processing) !== 0) {
value = parseInt(channelsResults[0].processing)
percent = (100 / totalTransactions * value).toFixed(2)
channelsData.push({ label: 'Processing', value: value, percent: percent, color: '#777777' })
channelsData.push({ label: 'Processing', value, percent, color: '#777777' })
}

if (parseInt(channelsResults[0].failed) !== 0) {
value = parseInt(channelsResults[0].failed)
percent = (100 / totalTransactions * value).toFixed(2)
channelsData.push({ label: 'Failed', value: value, percent: percent, color: '#d9534f' })
channelsData.push({ label: 'Failed', value, percent, color: '#d9534f' })
}

if (parseInt(channelsResults[0].completed) !== 0) {
value = parseInt(channelsResults[0].completed)
percent = (100 / totalTransactions * value).toFixed(2)
channelsData.push({ label: 'Completed', value: value, percent: percent, color: '#EFC300' })
channelsData.push({ label: 'Completed', value, percent, color: '#EFC300' })
}

if (parseInt(channelsResults[0].completedWErrors) !== 0) {
value = parseInt(channelsResults[0].completedWErrors)
percent = (100 / totalTransactions * value).toFixed(2)
channelsData.push({ label: 'Completed With Error (s)', value: value, percent: percent, color: '#FB8B24' })
channelsData.push({ label: 'Completed With Error (s)', value, percent, color: '#FB8B24' })
}

if (parseInt(channelsResults[0].successful) !== 0) {
value = parseInt(channelsResults[0].successful)
percent = (100 / totalTransactions * value).toFixed(2)
channelsData.push({ label: 'Successful', value: value, percent: percent, color: '#5cb85c' })
channelsData.push({ label: 'Successful', value, percent, color: '#5cb85c' })
}

updateChannelsBarChart(channelsData)
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/controllers/exportImport.js
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ export function ExportImportCtrl ($scope, $uibModal, Api, Alerting) {
windowClass: 'modal-fullview',
resolve: {
bodyData: function () {
return { type: type, content: content, headers: { 'content-type': 'application/json' } }
return { type, content, headers: { 'content-type': 'application/json' } }
}
}
})
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/controllers/exportImportModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ export function ExportImportModalCtrl ($scope, $uibModalInstance, $uibModal, $ti
windowClass: 'modal-fullview',
resolve: {
bodyData: function () {
return { type: type, content: content, headers: { 'content-type': 'application/json' } }
return { type, content, headers: { 'content-type': 'application/json' } }
}
}
})
Expand Down
10 changes: 5 additions & 5 deletions app/scripts/controllers/login.js
Original file line number Diff line number Diff line change
Expand Up @@ -195,11 +195,11 @@ export function LoginCtrl ($scope, login, $window, $location, $timeout, $rootSco

// create session object
const consoleSessionObject = {
sessionID: sessionID,
sessionID,
sessionUser: loginEmail,
sessionUserGroups: sessionUserGroups,
sessionUserSettings: sessionUserSettings,
sessionProvider: sessionProvider
sessionUserGroups,
sessionUserSettings,
sessionProvider
}

// Put the object into storage
Expand All @@ -213,7 +213,7 @@ export function LoginCtrl ($scope, login, $window, $location, $timeout, $rootSco
$scope.signInWithKeyCloak = function () {
keycloak.keycloakInstance.login({
// Must match to the configured value in keycloak
redirectUri: $window.location.origin,
redirectUri: $window.location.origin
})
}
}
2 changes: 1 addition & 1 deletion app/scripts/controllers/taskDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ export function TaskDetailsCtrl ($scope, $uibModal, $location, $routeParams, Api
if (showpage === i) {
status = 'active'
}
$scope.pagesArray.push({ pageNum: i, status: status })
$scope.pagesArray.push({ pageNum: i, status })
}
}

Expand Down
2 changes: 1 addition & 1 deletion app/scripts/controllers/transactionDetails.js
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ export function TransactionDetailsCtrl ($scope, $uibModal, $compile, $location,
windowClass: 'modal-fullview',
resolve: {
bodyData: function () {
return { type: type, content: content, headers: headers }
return { type, content, headers }
}
}
})
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/controllers/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export function UsersCtrl ($scope, $uibModal, $window, Api, Alerting, Notify) {
})
})

usersArray.push({ user: user, allowedChannels: allowedChannels, allowedChannelsBody: allowedChannelsBody, allowedChannelsRerun: allowedChannelsRerun })
usersArray.push({ user, allowedChannels, allowedChannelsBody, allowedChannelsRerun })
})

$scope.usersChannelsMatrix = {}
Expand Down
30 changes: 15 additions & 15 deletions app/scripts/controllers/visualizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,22 +107,22 @@ export function VisualizerCtrl ($scope, $http, $interval, $window, $uibModal, lo
$scope.visualizerData = []
$scope.visualizerSettings = {
name: visSettings.name,
components: components,
channels: channels,
mediators: mediators,
visResponsive: visResponsive,
visW: visW,
visH: visH,
pad: pad,
inactiveColor: inactiveColor,
activeColor: activeColor,
errorColor: errorColor,
textColor: textColor,
updatePeriod: updatePeriod,
minDisplayPeriod: minDisplayPeriod,
components,
channels,
mediators,
visResponsive,
visW,
visH,
pad,
inactiveColor,
activeColor,
errorColor,
textColor,
updatePeriod,
minDisplayPeriod,
speed: $scope.visualizerSpeed,
maxSpeed: maxSpeed,
maxTimeout: maxTimeout
maxSpeed,
maxTimeout
}

// check if visualizer should be loaded - no errors found
Expand Down
6 changes: 3 additions & 3 deletions app/scripts/directives/graph-directives-morris.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export function morrisLineChart ($parse) {
} else {
// create Morris Line Chart if it doesnt yet exist
scope.morrisLineChart = new Morris.Line({
element: element,
element,
data: data.data,
xkey: data.xkey,
ykeys: data.ykeys,
Expand Down Expand Up @@ -56,7 +56,7 @@ export function morrisBarChart ($parse) {
} else {
// create Morris Bar Chart if it doesnt yet exist
scope.morrisBarChart = new Morris.Bar({
element: element,
element,
data: data.data,
xkey: data.xkey,
ykeys: data.ykeys,
Expand Down Expand Up @@ -98,7 +98,7 @@ export function morrisDonutChart ($parse) {
elem.empty()
if (data) {
scope.morrisDonutChart = new Morris.Donut({
element: element,
element,
data: data.data,
colors: data.colors,
resize: true,
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/external/angular-taglist-directive.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ angular.module(angularTaglist, []).directive('taglist', ['$timeout', function ($
taglistBlurTimeout: '='
},
transclude: true,
template: template,
template,
compile: function (tElement, tAttrs, transcludeFn) {
return function (scope, element, attrs) {
element.bind('click', function () {
Expand Down
10 changes: 5 additions & 5 deletions app/scripts/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -165,11 +165,11 @@ app.run(function ($rootScope, $location, $anchorScroll, Api) {

// create session object
const consoleSessionObject = {
sessionID: sessionID,
sessionUser: sessionUser,
sessionUserGroups: sessionUserGroups,
sessionUserSettings: sessionUserSettings,
sessionProvider: sessionProvider
sessionID,
sessionUser,
sessionUserGroups,
sessionUserSettings,
sessionProvider
}

// Put updated object into storage
Expand Down
2 changes: 1 addition & 1 deletion app/scripts/services/login.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export function login (Api, $rootScope, keycloak) {
Api.AuthenticateLocal.save({ username: email, password }, function () {
// on success
// Verify that you can make authenticated requests
Api.Users.get({ email: email }, function (profile) {
Api.Users.get({ email }, function (profile) {
userProfile = profile
done('Authentication Success')
}, function () {
Expand Down
6 changes: 3 additions & 3 deletions app/scripts/services/metrics.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export function Metrics () {
}
}

graphData.push({ timestamp: timestamp.format('YYYY-MM-DD HH:mm'), value: value })
graphData.push({ timestamp: timestamp.format('YYYY-MM-DD HH:mm'), value })
}

avgResponseTime = (avgResponseTimeTotal / metrics.length).toFixed(2)
Expand All @@ -68,8 +68,8 @@ export function Metrics () {
xkey: 'timestamp',
ykeys: ['value'],
labels: [label],
loadTotal: loadTotal,
avgResponseTime: avgResponseTime
loadTotal,
avgResponseTime
}
}
}
Expand Down
4 changes: 2 additions & 2 deletions app/scripts/utils/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,11 +62,11 @@ export function beautifyIndent (type, content) {
}
} catch (err) {
console.log(err)
return { lang: '', content: content }
return { lang: '', content }
}

// if not applicable then return as is
return { lang: '', content: content }
return { lang: '', content }
}

export function isCoreVersionCompatible (minVersion, actualVersion) {
Expand Down
Loading

0 comments on commit 41a88a2

Please sign in to comment.