
No functional change, just name the components with their type first, so that all 'link' related components are more discoverable and next to each other.
22 lines
601 B
Vue
22 lines
601 B
Vue
<template>
|
|
<span>
|
|
<router-link v-if="workerTask" :to="{ name: 'jobs', params: { jobID: workerTask.job_id, taskID: workerTask.id } }">
|
|
{{ workerTask.name }}
|
|
(<span class="status-label" :class="'status-' + workerTask.status">{{ workerTask.status }}</span>)
|
|
</router-link>
|
|
<span v-else>-</span>
|
|
</span>
|
|
</template>
|
|
|
|
<script setup>
|
|
// 'workerTask' should be a WorkerTask object (see schema defined in `flamenco-openapi.yaml`).
|
|
const props = defineProps(['workerTask']);
|
|
</script>
|
|
|
|
<style scoped>
|
|
.status-label {
|
|
color: var(--indicator-color);
|
|
font-weight: bold;
|
|
}
|
|
</style>
|