f
This commit is contained in:
@@ -22,7 +22,7 @@ import { getOrderQueryDetail } from '#/api/order/query';
|
||||
|
||||
const route = useRoute();
|
||||
const router = useRouter();
|
||||
const orderId = Number(route.params.id);
|
||||
const orderId = route.params.id as string;
|
||||
const loading = ref(false);
|
||||
const queryDetail = ref<OrderQueryApi.QueryDetail>();
|
||||
|
||||
@@ -111,7 +111,9 @@ onMounted(() => {
|
||||
<div class="p-4">
|
||||
<div class="mb-4 flex items-center">
|
||||
<Button @click="handleBack">
|
||||
<template #icon><MdiArrowLeft /></template>
|
||||
<template #icon>
|
||||
<MdiArrowLeft />
|
||||
</template>
|
||||
返回订单管理
|
||||
</Button>
|
||||
</div>
|
||||
@@ -122,10 +124,7 @@ onMounted(() => {
|
||||
<span class="text-lg font-medium">订单查询详情</span>
|
||||
<div class="flex items-center gap-2">
|
||||
<span class="text-gray-500">查询状态:</span>
|
||||
<Tag
|
||||
v-if="queryDetail"
|
||||
:color="getQueryStateConfig(queryDetail.query_state).color"
|
||||
>
|
||||
<Tag v-if="queryDetail" :color="getQueryStateConfig(queryDetail.query_state).color">
|
||||
{{ getQueryStateConfig(queryDetail.query_state).label }}
|
||||
</Tag>
|
||||
</div>
|
||||
@@ -160,11 +159,8 @@ onMounted(() => {
|
||||
</template>
|
||||
<template v-if="queryDetail.query_params">
|
||||
<Descriptions :column="2" bordered>
|
||||
<Descriptions.Item
|
||||
v-for="(value, key) in queryDetail.query_params"
|
||||
:key="key"
|
||||
:label="getFieldDisplayName(key)"
|
||||
>
|
||||
<Descriptions.Item v-for="(value, key) in queryDetail.query_params" :key="key"
|
||||
:label="getFieldDisplayName(key)">
|
||||
{{ value }}
|
||||
</Descriptions.Item>
|
||||
</Descriptions>
|
||||
@@ -177,30 +173,21 @@ onMounted(() => {
|
||||
<span class="text-lg font-medium">查询数据</span>
|
||||
</template>
|
||||
<template v-if="queryDetail.query_data?.length">
|
||||
<Collapse
|
||||
:default-active-key="
|
||||
queryDetail.query_data.map((_, index) => index)
|
||||
"
|
||||
>
|
||||
<Collapse.Panel
|
||||
v-for="(item, index) in queryDetail.query_data"
|
||||
:key="index"
|
||||
>
|
||||
<Collapse :default-active-key="queryDetail.query_data.map((_, index) => index)
|
||||
">
|
||||
<Collapse.Panel v-for="(item, index) in queryDetail.query_data" :key="index">
|
||||
<template #header>
|
||||
<div class="flex items-center justify-between">
|
||||
<div class="flex items-center gap-2">
|
||||
<span class="text-lg font-medium">{{
|
||||
item.feature.featureName
|
||||
}}</span>
|
||||
}}</span>
|
||||
<Tag color="blue">API: {{ item.data.apiID }}</Tag>
|
||||
</div>
|
||||
<Tag
|
||||
:color="
|
||||
String(item.data.success) === 'true'
|
||||
? 'success'
|
||||
: 'error'
|
||||
"
|
||||
>
|
||||
<Tag :color="String(item.data.success) === 'true'
|
||||
? 'success'
|
||||
: 'error'
|
||||
">
|
||||
{{
|
||||
String(item.data.success) === 'true'
|
||||
? '查询成功'
|
||||
@@ -213,13 +200,7 @@ onMounted(() => {
|
||||
<div class="grid gap-4">
|
||||
<div v-if="item.data.data">
|
||||
<div class="mb-2 font-medium">查询结果:</div>
|
||||
<JsonViewer
|
||||
:value="item.data.data"
|
||||
copyable
|
||||
:expand-depth="2"
|
||||
boxed
|
||||
@copied="handleCopied"
|
||||
/>
|
||||
<JsonViewer :value="item.data.data" copyable :expand-depth="2" boxed @copied="handleCopied" />
|
||||
</div>
|
||||
<div class="text-gray-500">
|
||||
查询时间: {{ item.data.timestamp }}
|
||||
|
||||
Reference in New Issue
Block a user