mirror of
https://github.com/Jeuners/ECC.git
synced 2026-09-09 15:02:30 +02:00
Merge pull request #2516 from thejesh23/fix/dashboard-refresh-rules-commands
fix(ecc_dashboard): repopulate Rules and Commands trees on Refresh Data
This commit is contained in:
commit
fee94fb778
1 changed files with 12 additions and 3 deletions
|
|
@ -656,10 +656,17 @@ Usage: This skill is automatically activated when working with related technolog
|
|||
scrollbar.pack(side=tk.RIGHT, fill=tk.Y)
|
||||
|
||||
# Populate
|
||||
for i, cmd in enumerate(self.commands, 1):
|
||||
self.command_tree.insert('', tk.END, text=str(i),
|
||||
self.populate_commands(self.commands)
|
||||
|
||||
def populate_commands(self, commands: List[Dict]):
|
||||
"""Populate commands list"""
|
||||
for item in self.command_tree.get_children():
|
||||
self.command_tree.delete(item)
|
||||
|
||||
for i, cmd in enumerate(commands, 1):
|
||||
self.command_tree.insert('', tk.END, text=str(i),
|
||||
values=('/' + cmd['name'], cmd['description']))
|
||||
|
||||
|
||||
# =========================================================================
|
||||
# RULES TAB
|
||||
# =========================================================================
|
||||
|
|
@ -868,6 +875,8 @@ Project: github.com/affaan-m/ECC"""
|
|||
# Repopulate
|
||||
self.populate_agents(self.agents)
|
||||
self.populate_skills(self.skills)
|
||||
self.populate_commands(self.commands)
|
||||
self.populate_rules(self.rules)
|
||||
|
||||
# Update status
|
||||
self.status_label.config(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue