summaryrefslogtreecommitdiff
path: root/src/components
diff options
context:
space:
mode:
authorzephyr <[email protected]>2023-06-21 18:32:56 +0800
committerzephyr <[email protected]>2023-06-21 18:32:56 +0800
commit58d86c147440fa12d4f1c48c754efc2b273b48c1 (patch)
tree9e773929d5aa56f4a0767a49dce878821393787a /src/components
parente940712331c9bccd789eb5f02a1f1ee69cbd9085 (diff)
feat: client tag
Diffstat (limited to 'src/components')
-rw-r--r--src/components/Connections.tsx12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/components/Connections.tsx b/src/components/Connections.tsx
index c7a9b37..b380ea1 100644
--- a/src/components/Connections.tsx
+++ b/src/components/Connections.tsx
@@ -111,7 +111,7 @@ function getNameFromSource(source: string, sourceMap: { reg: string; name: strin
const regExp = new RegExp(reg, 'g');
if (regExp.test(source) && name) {
- sourceName = name;
+ sourceName = `${name}(${source})`;
}
});
@@ -280,8 +280,8 @@ function Conn({ apiConfig }) {
<table>
<thead>
<tr>
- <th>源IP</th>
- <th>设备名</th>
+ <th>{t('c_source')}</th>
+ <th>{t('device_name')}</th>
</tr>
</thead>
<tbody>
@@ -306,12 +306,12 @@ function Conn({ apiConfig }) {
/>
</td>
<td>
- <Button onClick={() => sourceMap.splice(index, 1)}>删除</Button>
+ <Button onClick={() => sourceMap.splice(index, 1)}>{t('delete')}</Button>
</td>
</tr>
))}
</tbody>
- <Button onClick={() => sourceMap.push({ reg: '', name: '' })}>添加规则</Button>
+ <Button onClick={() => sourceMap.push({ reg: '', name: '' })}>{t('add_tag')}</Button>
</table>
</BaseModal>
<div className={s.header}>
@@ -353,7 +353,7 @@ function Conn({ apiConfig }) {
</TabList>
<div>
- <Button onClick={openModalSource}>IP地址备注</Button>
+ <Button onClick={openModalSource}>{t('client_tag')}</Button>
<Button onClick={() => setFilterSourceIpStr('')} kind="minimal">
{t('All')}
</Button>