Skip to content

Commit cd35234

Browse files
authored
Blinking issue of health button while clicking on Event Logs submenu form other menus. (#153)
* removed setlogs commit as it resetting the health satus with logs * Addressed review comments
1 parent 5c2db28 commit cd35234

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

src/store/modules/Logs/EventLogStore.js

+7-1
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,15 @@ const EventLogStore = {
2525
allEvents: [],
2626
ceLogs: [],
2727
loadedEvents: false,
28+
eventlogs: [],
2829
},
2930
getters: {
3031
allEvents: (state) => state.allEvents.concat(state.ceLogs),
3132
ceLogs: (state) => state.ceLogs,
3233
highPriorityEvents: (state) => getHighPriorityEvents(state.allEvents),
3334
healthStatus: (state) =>
3435
getHealthStatus(state.allEvents, state.loadedEvents),
36+
eventlogs: (state) => state.allEvents.concat(state.ceLogs),
3537
},
3638
mutations: {
3739
setAllEvents: (state, allEvents) => (
@@ -40,11 +42,14 @@ const EventLogStore = {
4042
setCeLogs: (state, ceLogs) => (
4143
(state.ceLogs = ceLogs), (state.loadedEvents = true)
4244
),
45+
eventlogs: (state, eventlogs) => (
46+
(state.eventlogs = eventlogs), (state.loadedEvents = true)
47+
),
4348
},
4449
actions: {
4550
async getEventLogData({ commit }) {
4651
let eventLogs = [];
47-
commit('setAllEvents', eventLogs);
52+
commit('eventlogs', eventLogs);
4853
commit('setCeLogs', eventLogs);
4954
return await api
5055
.get('/redfish/v1/Systems/system/LogServices/EventLog/Entries')
@@ -79,6 +84,7 @@ const EventLogStore = {
7984
additionalDataUri: AdditionalDataURI,
8085
};
8186
});
87+
commit('eventlogs', eventLogs);
8288
commit('setAllEvents', eventLogs);
8389
})
8490
.catch((error) => {

src/views/Logs/EventLogs/EventLogs.vue

+1-1
Original file line numberDiff line numberDiff line change
@@ -442,7 +442,7 @@ export default {
442442
: this.filteredLogs.length;
443443
},
444444
allLogs() {
445-
return this.$store.getters['eventLog/allEvents'].map((event) => {
445+
return this.$store.getters['eventLog/eventlogs'].map((event) => {
446446
return {
447447
...event,
448448
actions: [

0 commit comments

Comments
 (0)