Commit 6c62f04d558aac2b64b8ce89a093630644da2642
Merge branch 'fix/teambition/10-12/2024' into 'main_dev'
fix: 云端英文模式下,网关设备的网关子设备界面,红框中应该显示为英文 See merge request yunteng/thingskit-front!1509
Showing
10 changed files
with
31 additions
and
21 deletions
@@ -34,6 +34,7 @@ export default { | @@ -34,6 +34,7 @@ export default { | ||
34 | }, | 34 | }, |
35 | }, | 35 | }, |
36 | template: { | 36 | template: { |
37 | + pushParameter: 'Push parameter', | ||
37 | templateName: 'Template Name', | 38 | templateName: 'Template Name', |
38 | templateCode: 'Template encoding', | 39 | templateCode: 'Template encoding', |
39 | signName: 'Signature Information', | 40 | signName: 'Signature Information', |
@@ -8,8 +8,8 @@ export default { | @@ -8,8 +8,8 @@ export default { | ||
8 | email: '邮箱', | 8 | email: '邮箱', |
9 | createButton: '创建告警联系人', | 9 | createButton: '创建告警联系人', |
10 | weChatMessageL: '注意事项:微信通知人必须在thingskit小程序中绑定使用账号,未绑定则接收不到通知', | 10 | weChatMessageL: '注意事项:微信通知人必须在thingskit小程序中绑定使用账号,未绑定则接收不到通知', |
11 | - createAlarm: '@:common.createText 联系人配置', | ||
12 | - updateAlarm: '@:common.editText 联系人配置', | 11 | + createAlarm: '创建告警联系人', |
12 | + updateAlarm: '编辑告警联系人', | ||
13 | weChatMessageNew: '企业微信通知电话,须在对应企业微信绑定,否则不能收到告警通知。', | 13 | weChatMessageNew: '企业微信通知电话,须在对应企业微信绑定,否则不能收到告警通知。', |
14 | table: { | 14 | table: { |
15 | title: '告警联系人列表', | 15 | title: '告警联系人列表', |
@@ -33,6 +33,7 @@ export default { | @@ -33,6 +33,7 @@ export default { | ||
33 | }, | 33 | }, |
34 | }, | 34 | }, |
35 | template: { | 35 | template: { |
36 | + pushParameter: '发送参数', | ||
36 | templateName: '模板名称', //Template Name | 37 | templateName: '模板名称', //Template Name |
37 | templateCode: '模板编码', //模板编码 | 38 | templateCode: '模板编码', //模板编码 |
38 | signName: '签名', //Signature Information | 39 | signName: '签名', //Signature Information |
@@ -37,6 +37,6 @@ export default { | @@ -37,6 +37,6 @@ export default { | ||
37 | selectAllText: '全部', | 37 | selectAllText: '全部', |
38 | selectPartText: '部分', | 38 | selectPartText: '部分', |
39 | deviceWithChannelText: '设备和通道号', | 39 | deviceWithChannelText: '设备和通道号', |
40 | - deviceSelectPlaceholderText: '@:common.chooseText 设备', | 40 | + deviceSelectPlaceholderText: '请选择设备', |
41 | channelNumberRuleText: '通道数需要小于50个', | 41 | channelNumberRuleText: '通道数需要小于50个', |
42 | }; | 42 | }; |
@@ -264,5 +264,5 @@ export function getAlarmStatus({ | @@ -264,5 +264,5 @@ export function getAlarmStatus({ | ||
264 | ? t('monitor.alarm.log.table.confirmed') | 264 | ? t('monitor.alarm.log.table.confirmed') |
265 | : t('monitor.alarm.log.table.unconfirmed'); | 265 | : t('monitor.alarm.log.table.unconfirmed'); |
266 | 266 | ||
267 | - return `${status} ${ackStatus}`; | 267 | + return `${status}${ackStatus}`; |
268 | } | 268 | } |
@@ -4,13 +4,15 @@ | @@ -4,13 +4,15 @@ | ||
4 | <template #toolbar> | 4 | <template #toolbar> |
5 | <Authority :value="DeviceListAuthEnum.DELETE"> | 5 | <Authority :value="DeviceListAuthEnum.DELETE"> |
6 | <Popconfirm | 6 | <Popconfirm |
7 | - title="您确定要批量删除数据" | ||
8 | - ok-text="确定" | ||
9 | - cancel-text="取消" | 7 | + :title="t('common.batchDeleteConfirmText')" |
8 | + :ok-text="t('common.okText')" | ||
9 | + :cancel-text="t('common.cancelText')" | ||
10 | @confirm="handleDelete()" | 10 | @confirm="handleDelete()" |
11 | :disabled="disabledDeleteFlag" | 11 | :disabled="disabledDeleteFlag" |
12 | > | 12 | > |
13 | - <Button danger :disabled="disabledDeleteFlag"> 批量删除 </Button> | 13 | + <Button danger :disabled="disabledDeleteFlag"> |
14 | + {{ t('common.batchDeleteText') }} | ||
15 | + </Button> | ||
14 | </Popconfirm> | 16 | </Popconfirm> |
15 | </Authority> | 17 | </Authority> |
16 | </template> | 18 | </template> |
@@ -23,11 +25,11 @@ | @@ -23,11 +25,11 @@ | ||
23 | <TableAction | 25 | <TableAction |
24 | :actions="[ | 26 | :actions="[ |
25 | { | 27 | { |
26 | - label: '删除', | 28 | + label: t('common.delText'), |
27 | auth: DeviceListAuthEnum.DETAIL, | 29 | auth: DeviceListAuthEnum.DETAIL, |
28 | icon: 'ant-design:eye-outlined', | 30 | icon: 'ant-design:eye-outlined', |
29 | popConfirm: { | 31 | popConfirm: { |
30 | - title: '是否确认删除', | 32 | + title: t('common.deleteConfirmText'), |
31 | confirm: handleDelete.bind(null, record), | 33 | confirm: handleDelete.bind(null, record), |
32 | }, | 34 | }, |
33 | }, | 35 | }, |
@@ -48,6 +50,8 @@ | @@ -48,6 +50,8 @@ | ||
48 | import { DeviceListAuthEnum } from '../../config/device.data'; | 50 | import { DeviceListAuthEnum } from '../../config/device.data'; |
49 | import { Authority } from '/@/components/Authority'; | 51 | import { Authority } from '/@/components/Authority'; |
50 | import { useMessage } from '/@/hooks/web/useMessage'; | 52 | import { useMessage } from '/@/hooks/web/useMessage'; |
53 | + import { useI18n } from '/@/hooks/web/useI18n'; | ||
54 | + | ||
51 | export default defineComponent({ | 55 | export default defineComponent({ |
52 | name: 'DeviceManagement', | 56 | name: 'DeviceManagement', |
53 | components: { | 57 | components: { |
@@ -65,6 +69,7 @@ | @@ -65,6 +69,7 @@ | ||
65 | }, | 69 | }, |
66 | emits: ['openTbDeviceDetail'], | 70 | emits: ['openTbDeviceDetail'], |
67 | setup(props, { emit }) { | 71 | setup(props, { emit }) { |
72 | + const { t } = useI18n(); | ||
68 | const [registerTable, { getSelectRowKeys, reload, setLoading }] = useTable({ | 73 | const [registerTable, { getSelectRowKeys, reload, setLoading }] = useTable({ |
69 | api: getChildDevicePage, | 74 | api: getChildDevicePage, |
70 | columns: childDeviceColumns, | 75 | columns: childDeviceColumns, |
@@ -83,7 +88,7 @@ | @@ -83,7 +88,7 @@ | ||
83 | clickToRowSelect: false, | 88 | clickToRowSelect: false, |
84 | actionColumn: { | 89 | actionColumn: { |
85 | width: 200, | 90 | width: 200, |
86 | - title: '操作', | 91 | + title: t('common.operateTable'), |
87 | slots: { customRender: 'action' }, | 92 | slots: { customRender: 'action' }, |
88 | fixed: 'right', | 93 | fixed: 'right', |
89 | }, | 94 | }, |
@@ -123,7 +128,7 @@ | @@ -123,7 +128,7 @@ | ||
123 | try { | 128 | try { |
124 | setLoading(true); | 129 | setLoading(true); |
125 | await deleteDevice(ids); | 130 | await deleteDevice(ids); |
126 | - createMessage.success('删除成功'); | 131 | + createMessage.success(t('common.deleteSuccessText')); |
127 | reload(); | 132 | reload(); |
128 | } catch (error) { | 133 | } catch (error) { |
129 | throw error; | 134 | throw error; |
@@ -139,6 +144,7 @@ | @@ -139,6 +144,7 @@ | ||
139 | DeviceListAuthEnum, | 144 | DeviceListAuthEnum, |
140 | handleDelete, | 145 | handleDelete, |
141 | disabledDeleteFlag, | 146 | disabledDeleteFlag, |
147 | + t, | ||
142 | }; | 148 | }; |
143 | }, | 149 | }, |
144 | }); | 150 | }); |
@@ -53,13 +53,10 @@ | @@ -53,13 +53,10 @@ | ||
53 | </div> | 53 | </div> |
54 | <div class="mt-4" v-if="!isCustomer"> | 54 | <div class="mt-4" v-if="!isCustomer"> |
55 | <a-button type="primary" class="mr-4" @click="copyTbDeviceId"> | 55 | <a-button type="primary" class="mr-4" @click="copyTbDeviceId"> |
56 | - {{ t('common.copyText') }} | ||
57 | - {{ t('business.deviceText') }} | ||
58 | - ID | 56 | + {{ t('common.copyText') }}{{ t('business.deviceText') }}ID |
59 | </a-button> | 57 | </a-button> |
60 | <a-button type="primary" class="mr-4" @click="copyDeviceToken"> | 58 | <a-button type="primary" class="mr-4" @click="copyDeviceToken"> |
61 | - {{ t('common.copyText') }} | ||
62 | - {{ t('deviceManagement.device.accessTokenText') }} | 59 | + {{ t('common.copyText') }}{{ t('deviceManagement.device.accessTokenText') }} |
63 | </a-button> | 60 | </a-button> |
64 | <Authority value="api:yt:device:equipment"> | 61 | <Authority value="api:yt:device:equipment"> |
65 | <a-button type="primary" class="mr-4" @click="manageDeviceToken"> | 62 | <a-button type="primary" class="mr-4" @click="manageDeviceToken"> |
@@ -13,7 +13,7 @@ const { t } = useI18n(); | @@ -13,7 +13,7 @@ const { t } = useI18n(); | ||
13 | // 表格配置 | 13 | // 表格配置 |
14 | export const columns: BasicColumn[] = [ | 14 | export const columns: BasicColumn[] = [ |
15 | { | 15 | { |
16 | - title: '时间', | 16 | + title: t('common.timeText'), |
17 | dataIndex: 'eventTime', | 17 | dataIndex: 'eventTime', |
18 | format(text) { | 18 | format(text) { |
19 | return formatToDateTime(text, 'YYYY-MM-DD HH:mm:ss'); | 19 | return formatToDateTime(text, 'YYYY-MM-DD HH:mm:ss'); |
1 | <template> | 1 | <template> |
2 | - <BasicModal v-bind="$attrs" @register="register" title="发送参数" @ok="handleOK"> | 2 | + <BasicModal |
3 | + v-bind="$attrs" | ||
4 | + @register="register" | ||
5 | + :title="t('monitor.message.template.pushParameter')" | ||
6 | + @ok="handleOK" | ||
7 | + > | ||
3 | <div class="pt-4px pr-4px"> | 8 | <div class="pt-4px pr-4px"> |
4 | <BasicForm @register="registerForm" /> | 9 | <BasicForm @register="registerForm" /> |
5 | </div> | 10 | </div> |
@@ -217,7 +222,7 @@ | @@ -217,7 +222,7 @@ | ||
217 | createMessage.success(t('common.sendText')); | 222 | createMessage.success(t('common.sendText')); |
218 | } | 223 | } |
219 | 224 | ||
220 | - return { register, schemas, registerForm, handleOK }; | 225 | + return { register, schemas, registerForm, handleOK, t }; |
221 | }, | 226 | }, |
222 | }); | 227 | }); |
223 | </script> | 228 | </script> |