Skip to content

Commit

Permalink
Add an update all funtion
Browse files Browse the repository at this point in the history
  • Loading branch information
DomiiBunn committed Jul 26, 2024
1 parent 109222f commit e9de111
Show file tree
Hide file tree
Showing 30 changed files with 78 additions and 30 deletions.
21 changes: 20 additions & 1 deletion frontend/src/components/StackList.vue
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
</button>

<div class="placeholder"></div>

<div class="search-wrapper">
<a v-if="searchText == ''" class="search-icon">
<font-awesome-icon icon="search" />
Expand All @@ -19,6 +20,12 @@
<input v-model="searchText" class="form-control search-input" autocomplete="off" />
</form>
</div>
<div class="update-all-wrapper">
<button class="btn btn-primary" @click="updateAll">
<font-awesome-icon icon="fa-cloud-arrow-down me-1" />
{{ $t("updateAll") }}
</button>
</div>
</div>

<!-- TODO -->
Expand Down Expand Up @@ -346,6 +353,18 @@ export default {
this.cancelSelectMode();
},
updateAll() {
console.log("updateAll");
console.log(this.sortedStackList);
for (let stack of this.sortedStackList) {
console.log(stack);
this.$root.emitAgent(stack.endpoint, "updateStack", stack.name, (res) => {
this.processing = false;
this.$root.toastRes(res);
});
}
}
},
};
</script>
Expand Down Expand Up @@ -417,7 +436,7 @@ export default {
}
.search-input {
max-width: 15em;
max-width: 10em;
}
.stack-item {
Expand Down
3 changes: 2 additions & 1 deletion frontend/src/lang/ar.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,5 +98,6 @@
"url": "رابط | روابط",
"extra": "إضافات",
"reverseProxyMsg1": "هل تستدخم خادم عكسي؟",
"connecting...": "جاري الاتصال بخادم المقبس…"
"connecting...": "جاري الاتصال بخادم المقبس…",
"updateAll": "تحديث الكل",
}
3 changes: 2 additions & 1 deletion frontend/src/lang/bg-BG.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"dockgeAgent": "Dockge агент | Dockge агенти",
"connecting": "Свързване",
"agentRemovedSuccessfully": "Агентът е премахнат успешно.",
"LongSyntaxNotSupported": "Дългият синтаксис не се поддържа тук. Моля, използвайте YAML редактора."
"LongSyntaxNotSupported": "Дългият синтаксис не се поддържа тук. Моля, използвайте YAML редактора.",
"updateAll": "Обнови всички"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/ca.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"Please use this option carefully!": "Si us plau, utilitzeu aquesta opció amb cura!",
"Enable Auth": "Habilitar autenticació",
"I understand, please disable": "Ho entenc, si us plau deshabilita",
"Password": "Contrasenya"
"Password": "Contrasenya",
"updateAll": "Actualitzar totes"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/cs-CZ.json
Original file line number Diff line number Diff line change
Expand Up @@ -97,5 +97,6 @@
"extra": "Extra",
"reverseProxyMsg1": "Používáte Reverzní proxy server?",
"reverseProxyMsg2": "Podívat se jak to nastavit pro WebSocket",
"Cannot connect to the socket server.": "Nelze se připojit k serveru ."
"Cannot connect to the socket server.": "Nelze se připojit k serveru .",
"updateAll": "Aktualizovat všechny"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/da.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"agentAddedSuccessfully": "Agent succesfuld tilføjet.",
"agentRemovedSuccessfully": "Agent succesfuld fjernet.",
"removeAgent": "Fjern agent",
"removeAgentMsg": "Er du sikker på at du vil fjerne denne agent?"
"removeAgentMsg": "Er du sikker på at du vil fjerne denne agent?",
"updateAll": "Opdater alle"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"agentRemovedSuccessfully": "Agent erfolgreich entfernt.",
"removeAgent": "Agent Entfernen",
"removeAgentMsg": "Bist Du sicher, dass Du diesen Agent entfernen möchtest?",
"LongSyntaxNotSupported": "Lange Syntax wird nicht unterstützt. Bitte verwende den YAML-Editor."
"LongSyntaxNotSupported": "Lange Syntax wird nicht unterstützt. Bitte verwende den YAML-Editor.",
"updateAll": "Alle aktualisieren"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"agentRemovedSuccessfully": "Agent removed successfully.",
"removeAgent": "Remove Agent",
"removeAgentMsg": "Are you sure you want to remove this agent?",
"LongSyntaxNotSupported": "Long syntax is not supported here. Please use the YAML editor."
"LongSyntaxNotSupported": "Long syntax is not supported here. Please use the YAML editor.",
"updateAll": "Update All"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"removeAgentMsg": "Estás seguro que deseas remover este agente?",
"dockgeAgent": "Agentes Dockge",
"connecting": "Conectando",
"agentRemovedSuccessfully": "Agente removido satisfactoriamente."
"agentRemovedSuccessfully": "Agente removido satisfactoriamente.",
"updateAll": "Actualizar todos"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/fr.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"currentEndpoint": "Actuel",
"connect": "Connecter",
"removeAgentMsg": "Êtes-vous sûr de vouloir supprimer cet agent ?",
"LongSyntaxNotSupported": "La syntaxe longue n'est pas prise en charge ici. Veuillez utiliser l'éditeur YAML."
"LongSyntaxNotSupported": "La syntaxe longue n'est pas prise en charge ici. Veuillez utiliser l'éditeur YAML.",
"updateAll": "Mettre à jour tout"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/hu.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"Cannot connect to the socket server.": "A Socket csatlakozás nem elérhető.",
"connecting...": "Csatlakozás a socket szerver-hez…",
"url": "URL | URL-ek",
"dockgeURL": "Dockge URL (pl. http://127.0.0.1:5001)"
"dockgeURL": "Dockge URL (pl. http://127.0.0.1:5001)",
"updateAll": "Frissítés Minden"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/id.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"currentEndpoint": "Sekarang",
"agentOnline": "Terhubung",
"agentOffline": "Terputus",
"removeAgentMsg": "Apakah anda yakin untuk menghapus agen ini?"
"removeAgentMsg": "Apakah anda yakin untuk menghapus agen ini?",
"updateAll": "Perbarui Semua"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/it-IT.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"removeAgent": "Rimuovi Agente",
"removeAgentMsg": "Sei sicuro di voler rimuovere questo agente?",
"addAgent": "Aggungi Agente",
"agentAddedSuccessfully": "Agente aggiunto correttamente."
"agentAddedSuccessfully": "Agente aggiunto correttamente.",
"updateAll": "Aggiorna tutti"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/ja.json
Original file line number Diff line number Diff line change
Expand Up @@ -107,5 +107,6 @@
"agentRemovedSuccessfully": "エージェントは正常に削除されました。",
"removeAgent": "エージェントを削除",
"removeAgentMsg": "本当にこのエージェントを削除しますか?",
"url": "URL | URL"
"url": "URL | URL",
"updateAll": "全てのエージェントをアップデート"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/ko-KR.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"currentEndpoint": "현재",
"connecting": "연결 중",
"agentRemovedSuccessfully": "에이전트를 성공적으로 삭제했습니다.",
"LongSyntaxNotSupported": "긴 문법은 여기서 지원되지 않습니다. YAML 에디터를 사용하세요."
"LongSyntaxNotSupported": "긴 문법은 여기서 지원되지 않습니다. YAML 에디터를 사용하세요.",
"updateAll": "정지 & 비활성화"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/nl.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"agentAddedSuccessfully": "Agent toegevoegd.",
"agentRemovedSuccessfully": "Agent verwijderd.",
"removeAgent": "Verwijder agent",
"removeAgentMsg": "Weet je zeker dat je deze agent wilt verwijderen?"
"removeAgentMsg": "Weet je zeker dat je deze agent wilt verwijderen?",
"updateAll": "Update alles"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/pl-PL.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"connecting...": "Łączenie z socketem serwera…",
"extra": "Ekstra",
"url": "URL | URLe",
"reconnecting...": "Wznawianie połączenia…"
"reconnecting...": "Wznawianie połączenia…",
"updateAll": "Zaktualizuj wszystkie"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/pt-BR.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"agentAddedSuccessfully": "Agente adicionado com sucesso.",
"agentRemovedSuccessfully": "Agente removido com sucesso.",
"removeAgent": "Remover Agente",
"removeAgentMsg": "Tem certeza de que deseja remover este agente?"
"removeAgentMsg": "Tem certeza de que deseja remover este agente?",
"updateAll": "Atualizar tudo"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/pt.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"url": "URL | URLs",
"extra": "Extra",
"reconnecting...": "Reconectando…",
"connecting...": "Conectando ao servidor de socket…"
"connecting...": "Conectando ao servidor de socket…",
"updateAll": "Atualizar tudo"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/ro.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,5 +98,6 @@
"Please use this option carefully!": "Vă rugăm să utilizați această opțiune cu atenție!",
"Show update if available": "Afișează actualizarea dacă este disponibilă",
"disableauth.message1": "Sigur doriți să <strong>dezactivați autentificarea</strong>?",
"disableauth.message2": "Este conceput pentru scenarii <strong>în care intenționați să implementați autentificarea terță</strong> în fața Dockge-lui, cum ar fi Cloudflare Access, Authelia sau alte mecanisme de autentificare."
"disableauth.message2": "Este conceput pentru scenarii <strong>în care intenționați să implementați autentificarea terță</strong> în fața Dockge-lui, cum ar fi Cloudflare Access, Authelia sau alte mecanisme de autentificare.",
"updateAll": "Actualizează "
}
3 changes: 2 additions & 1 deletion frontend/src/lang/ru.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"dockgeAgent": "Агент Dockge | Агенты Dockge",
"dockgeURL": "URL-адрес Dockge (например: http://127.0.0.1:5001)",
"agentRemovedSuccessfully": "Агент успешно удален.",
"LongSyntaxNotSupported": "Длинный синтаксис здесь не поддерживается. Пожалуйста, используйте редактор YAML."
"LongSyntaxNotSupported": "Длинный синтаксис здесь не поддерживается. Пожалуйста, используйте редактор YAML.",
"updateAll": "Обновить все"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/sl.json
Original file line number Diff line number Diff line change
Expand Up @@ -99,5 +99,6 @@
"newUpdate": "Nova posodobitev",
"reverseProxyMsg2": "Preverite, kako ga konfigurirati za WebSocket",
"Cannot connect to the socket server.": "Ni mogoče vzpostaviti povezave s strežnikom vtičnic.",
"url": "URL | URL-ji"
"url": "URL | URL-ji",
"updateAll": "Posodobi vse"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/sv-SE.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"removeAgent": "Ta bort agent",
"removeAgentMsg": "Är du säker att du vill ta bort denna agent?",
"dockgeAgent": "Dockge agenter | Dockge agenter",
"agentAddedSuccessfully": "Agent tillagd."
"agentAddedSuccessfully": "Agent tillagd.",
"updateAll": "Uppdatera alla"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/th.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,5 +98,6 @@
"connecting...": "กำลังเชื่อมต่อกับเซิร์ฟเวอร์ socket…",
"url": "URL | URLs",
"extra": "พิเศษ",
"reconnecting...": "กำลังเชื่อมต่อใหม่…"
"reconnecting...": "กำลังเชื่อมต่อใหม่…",
"updateAll": "อัปเดตทุกอย่าง"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/tr.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"agentAddedSuccessfully": "Aracı başarıyla eklendi.",
"agentRemovedSuccessfully": "Aracı başarıyla kaldırıldı.",
"removeAgent": "Aracıyı Kaldır",
"removeAgentMsg": "Bu aracıyı kaldırmak istediğinize emin misiniz?"
"removeAgentMsg": "Bu aracıyı kaldırmak istediğinize emin misiniz?",
"updateAll": "Tut"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/uk-UA.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"agentRemovedSuccessfully": "Агент успішно видалено.",
"agentAddedSuccessfully": "Агент успішно додано.",
"removeAgentMsg": "Ви впевнені, що хочете видалити цей агент?",
"LongSyntaxNotSupported": "Довгий синтаксис тут не підтримується. Будь ласка, використовуйте редактор YAML."
"LongSyntaxNotSupported": "Довгий синтаксис тут не підтримується. Будь ласка, використовуйте редактор YAML.",
"updateAll": "Оновити все"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/ur.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"agentRemovedSuccessfully": "ایجنٹ کو کامیابی سے ہٹا دیا گیا۔",
"removeAgent": "ایجنٹ کو ہٹا دیں",
"removeAgentMsg": "کیا آپ واقعی اس ایجنٹ کو ہٹانا چاہتے ہیں؟",
"LongSyntaxNotSupported": "لمبا نحو یہاں تعاون یافتہ نہیں ہے۔ براہ کرم YAML ایڈیٹر استعمال کریں۔"
"LongSyntaxNotSupported": "لمبا نحو یہاں تعاون یافتہ نہیں ہے۔ براہ کرم YAML ایڈیٹر استعمال کریں۔",
"updateAll": "تمام تازہ کاری کو ہٹا دیں"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/vi.json
Original file line number Diff line number Diff line change
Expand Up @@ -111,5 +111,6 @@
"disableauth.message2": "Nó được thiết kế trong hoàn cảnh <strong>mà bạn dự định triển khai xác thực đăng nhập bên thứ ba</strong> trước Dockge như là Cloudflare Access, Authelia hay các phương thức xác minh đăng nhập khác.",
"dockerImage": "Image",
"Show update if available": "Hiển thị cập nhật nếu có",
"restartPolicyUnlessStopped": "Trừ Khi Dừng Lại"
"restartPolicyUnlessStopped": "Trừ Khi Dừng Lại",
"updateAll": "Cập Nhật Càc"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -112,5 +112,6 @@
"removeAgent": "移除代理",
"removeAgentMsg": "您确定要移除此代理?",
"agentAddedSuccessfully": "代理添加成功。",
"LongSyntaxNotSupported": "此处不支持Long syntax,请使用YAML编辑器。"
"LongSyntaxNotSupported": "此处不支持Long syntax,请使用YAML编辑器。",
"updateAll": "更新全部"
}
3 changes: 2 additions & 1 deletion frontend/src/lang/zh-TW.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,5 +100,6 @@
"url": "網址 | 網址",
"extra": "額外",
"newUpdate": "新版本",
"currentEndpoint": "目前"
"currentEndpoint": "目前",
"updateAll": "更新所有"
}

0 comments on commit e9de111

Please sign in to comment.