From 82103d73e2ba7a01864d78384f977eba6b92be28 Mon Sep 17 00:00:00 2001 From: sadnub Date: Thu, 14 Oct 2021 13:22:53 -0400 Subject: [PATCH] fix audit manager tab and modal --- src/components/agents/AuditTab.vue | 4 +- src/components/logs/AuditManager.vue | 138 +++++++++++++++------------ src/components/logs/DebugLog.vue | 2 +- 3 files changed, 81 insertions(+), 63 deletions(-) diff --git a/src/components/agents/AuditTab.vue b/src/components/agents/AuditTab.vue index ced0ff6..d9ef08c 100644 --- a/src/components/agents/AuditTab.vue +++ b/src/components/agents/AuditTab.vue @@ -1,7 +1,7 @@ @@ -21,10 +21,12 @@ export default { setup() { const store = useStore(); const selectedAgent = computed(() => store.state.selectedRow); + const tabHeight = computed(() => store.state.tabHeight); return { // computed selectedAgent, + tabHeight, }; }, }; diff --git a/src/components/logs/AuditManager.vue b/src/components/logs/AuditManager.vue index 21bbaa3..bca5151 100644 --- a/src/components/logs/AuditManager.vue +++ b/src/components/logs/AuditManager.vue @@ -8,13 +8,37 @@ Close -
- -
- -
-
+ + + + @@ -212,7 +227,8 @@ export default { name: "AuditManager", components: { TacticalDropdown, ExportTableBtn }, props: { - agentpk: Number, + agent: String, + tabHeight: String, modal: { type: Boolean, default: false, @@ -303,14 +319,14 @@ export default { clientFilter.value = null; }); - if (props.agentpk) { - agentFilter.value = [props.agentpk]; + if (props.agent) { + agentFilter.value = [props.agent]; watch([userFilter, actionFilter, timeFilter], search); watch( - () => props.agentpk, + () => props.agent, (newValue, oldValue) => { if (newValue) { - agentFilter.value = [props.agentpk]; + agentFilter.value = [props.agent]; search(); } } @@ -319,7 +335,7 @@ export default { // vue component hooks onMounted(() => { - if (!props.agentpk) { + if (!props.agent) { getClientOptions(); getAgentOptions(); } else { @@ -348,7 +364,7 @@ export default { clientOptions, agentOptions, columns, - actionOptions: props.agentpk ? [...agentActionOptions] : [...agentActionOptions, ...actionOptions], + actionOptions: props.agent ? [...agentActionOptions] : [...agentActionOptions, ...actionOptions], objectOptions, timeOptions, filterTypeOptions, diff --git a/src/components/logs/DebugLog.vue b/src/components/logs/DebugLog.vue index 10734d6..b7a23a3 100644 --- a/src/components/logs/DebugLog.vue +++ b/src/components/logs/DebugLog.vue @@ -10,7 +10,7 @@