use api in front

This commit is contained in:
2025-10-29 02:57:10 +01:00
parent 07dd1bc0ff
commit 52723b200a
14 changed files with 900 additions and 263 deletions
+11 -8
View File
@@ -61,29 +61,32 @@
<tbody>
<tr v-for="response in responses" :key="response.id" class="hover">
<td>
<span v-if="response.cost" class="badge badge-success badge-xs">
{{ response.cost }}
<span v-if="response.final_cost || response.cost" class="badge badge-success badge-xs">
{{ response.final_cost || response.cost }}
</span>
<span v-else class="text-base-content/50">-</span>
</td>
<td>
<span v-if="response.cycles" class="badge badge-info badge-xs">
{{ response.cycles }}
<span v-if="response.final_cycles || response.cycles" class="badge badge-info badge-xs">
{{ response.final_cycles || response.cycles }}
</span>
<span v-else class="text-base-content/50">-</span>
</td>
<td>
<span v-if="response.area" class="badge badge-warning badge-xs">
{{ response.area }}
<span v-if="response.final_area || response.area" class="badge badge-warning badge-xs">
{{ response.final_area || response.area }}
</span>
<span v-else class="text-base-content/50">-</span>
</td>
<td>
<div class="flex items-center gap-1">
<span class="badge badge-ghost badge-xs">{{ response.files.length }}</span>
<div class="tooltip" :data-tip="response.files.map(f => f.file.name).join(', ')">
<span class="badge badge-ghost badge-xs">{{ response.files?.length || 0 }}</span>
<div v-if="response.files?.length" class="tooltip" :data-tip="response.files.map(f => f.original_filename || f.file?.name).join(', ')">
<i class="mdi mdi-information-outline text-xs"></i>
</div>
<div v-if="response.needs_manual_validation" class="tooltip" data-tip="Needs manual validation">
<i class="mdi mdi-alert-circle text-xs text-warning"></i>
</div>
</div>
</td>
</tr>