查询消息详情的时候展示消费情况

This commit is contained in:
许晓东
2021-12-12 23:35:17 +08:00
parent 54cd402810
commit 57a41e087f
8 changed files with 110 additions and 23 deletions

View File

@@ -5,10 +5,10 @@
<a-tab-pane key="1" tab="根据时间查询消息">
<SearchByTime :topic-list="topicList"></SearchByTime>
</a-tab-pane>
<a-tab-pane key="2" tab="根据移查询消息" force-render>
<a-tab-pane key="2" tab="根据移查询消息" force-render>
<SearchByOffset :topic-list="topicList"></SearchByOffset>
</a-tab-pane>
<a-tab-pane key="3" tab="消息发送"> 消息发送1 </a-tab-pane>
<!-- <a-tab-pane key="3" tab="消息发送"> 消息发送1 </a-tab-pane>-->
</a-tabs>
</a-spin>
</div>

View File

@@ -92,6 +92,21 @@
</p>
</div>
</div>
<div>
<h4>消费信息</h4>
<hr />
<a-table
:columns="columns"
:data-source="data.consumers"
bordered
row-key="groupId"
>
<div slot="status" slot-scope="text">
<span v-if="text == 'consumed'">已消费</span
><span v-else style="color: red">未消费</span>
</div>
</a-table>
</div>
</a-spin>
</div>
</a-modal>
@@ -120,6 +135,8 @@ export default {
deserializerList: [],
keyDeserializer: "String",
valueDeserializer: "String",
consumerDetail: [],
columns,
};
},
watch: {
@@ -184,6 +201,19 @@ export default {
},
},
};
const columns = [
{
title: "消费组",
dataIndex: "groupId",
key: "groupId",
},
{
title: "消费情况",
dataIndex: "status",
key: "status",
scopedSlots: { customRender: "status" },
},
];
</script>
<style scoped>