feat(daemon): execute and verify organisation repository connections
This commit is contained in:
1 parent
32642af4a9
commit
05987f04e2
45 files changed
+1600
-284
No files matched your search
@@ -33,13 +33,13 @@ const recentRepos = ref<string[]>([]);
|
||||
const loadError = ref("");
|
||||
onMounted(async () => {
|
||||
try {
|
||||
const [workflows, tasks] = await Promise.all([
|
||||
const [workflows, repositories] = await Promise.all([
|
||||
api.workflows<{ definitions?: WorkflowDefinition[]; workflows?: WorkflowStats[] }>(),
|
||||
api.tasks<{ owner?: string; repo?: string }[]>(),
|
||||
api.repositories<{ owner: string; name: string }[]>(),
|
||||
]);
|
||||
definitions.value = (workflows?.definitions ?? []).filter((d) => d.enabled);
|
||||
stats.value = workflows?.workflows ?? [];
|
||||
recentRepos.value = [...new Set((tasks ?? []).filter((t) => t.owner && t.repo).map((t) => `${t.owner}/${t.repo}`))].slice(0, 5);
|
||||
recentRepos.value = (repositories ?? []).map((repo) => `${repo.owner}/${repo.name}`);
|
||||
} catch (err) {
|
||||
loadError.value = String((err as Error).message || err);
|
||||
}
|
||||
@@ -107,7 +107,7 @@ async function submit() {
|
||||
<datalist :id="`${uid}-repos`">
|
||||
<option v-for="r in recentRepos" :key="r" :value="r" />
|
||||
</datalist>
|
||||
<p v-if="recentRepos.length" class="text-xs text-fg-subtle">Recent:
|
||||
<p v-if="recentRepos.length" class="text-xs text-fg-subtle">Configured:
|
||||
<Button
|
||||
v-for="r in recentRepos"
|
||||
:key="r"
|
||||
|
||||
Reference in new issue
Block a user