优化访问日志Header显示

This commit is contained in:
GoEdgeLab
2022-04-05 15:43:49 +08:00
parent d54e4af295
commit 0abc5dd8a6
2 changed files with 12 additions and 4 deletions

View File

@@ -81,7 +81,10 @@
<table class="ui table selectable small">
<tbody v-for="header in responseHeaders">
<tr v-for="value in header.values">
<td class="title">{{header.name}}</td>
<td class="title">
<span v-if="header.isGeneral">{{header.name}}</span>
<span style="font-style: italic" v-else>{{header.name}}</span>
</td>
<td>{{value}}</td>
</tr>
</tbody>
@@ -92,7 +95,10 @@
<table class="ui table selectable small">
<tbody v-for="header in requestHeaders">
<tr v-for="value in header.values">
<td class="title">{{header.name}}</td>
<td class="title">
<span v-if="header.isGeneral">{{header.name}}</span>
<span style="font-style: italic" v-else>{{header.name}}</span>
</td>
<td>{{value}}</td>
</tr>
</tbody>

View File

@@ -14,7 +14,8 @@ Tea.context(function () {
}
this.requestHeaders.push({
name: k,
values: v.values
values: v.values,
isGeneral: !k.startsWith("X-")
})
}
}
@@ -32,7 +33,8 @@ Tea.context(function () {
}
this.responseHeaders.push({
name: k,
values: v.values
values: v.values,
isGeneral: !k.startsWith("X-")
})
}
}