Showing
6 changed files
with
33 additions
and
5 deletions
@@ -4,6 +4,9 @@ import { defHttp } from '/@/utils/http/axios'; | @@ -4,6 +4,9 @@ import { defHttp } from '/@/utils/http/axios'; | ||
4 | enum Api { | 4 | enum Api { |
5 | DEVICE_PROFILE_CATEGORY = '/device_profile/category', | 5 | DEVICE_PROFILE_CATEGORY = '/device_profile/category', |
6 | } | 6 | } |
7 | +// export enum CATEGORY_POST { | ||
8 | + | ||
9 | +// } | ||
7 | 10 | ||
8 | /** | 11 | /** |
9 | * 新增产品分类 | 12 | * 新增产品分类 |
@@ -7,7 +7,19 @@ | @@ -7,7 +7,19 @@ | ||
7 | width="30%" | 7 | width="30%" |
8 | @ok="handleSubmit" | 8 | @ok="handleSubmit" |
9 | > | 9 | > |
10 | - <BasicForm @register="registerForm" /> | 10 | + <BasicForm @register="registerForm"> |
11 | + <template #wechatMessage> | ||
12 | + <div> | ||
13 | + <Typography> | ||
14 | + <TypographyParagraph | ||
15 | + class="w-99/100" | ||
16 | + :ellipsis="{ rows: 1, expandable: true, symbol: '展开' }" | ||
17 | + content="注意事项:微信通知人必须在thingskit小程序中绑定使用账号,未绑定则接收不到通知" | ||
18 | + /> | ||
19 | + </Typography> | ||
20 | + </div> | ||
21 | + </template> | ||
22 | + </BasicForm> | ||
11 | </BasicDrawer> | 23 | </BasicDrawer> |
12 | </template> | 24 | </template> |
13 | <script lang="ts"> | 25 | <script lang="ts"> |
@@ -17,10 +29,11 @@ | @@ -17,10 +29,11 @@ | ||
17 | import { BasicDrawer, useDrawerInner } from '/@/components/Drawer'; | 29 | import { BasicDrawer, useDrawerInner } from '/@/components/Drawer'; |
18 | import { saveOrEditAlarmContact } from '/@/api/alarm/contact/alarmContact'; | 30 | import { saveOrEditAlarmContact } from '/@/api/alarm/contact/alarmContact'; |
19 | import { useMessage } from '/@/hooks/web/useMessage'; | 31 | import { useMessage } from '/@/hooks/web/useMessage'; |
32 | + import { TypographyParagraph, Typography } from 'ant-design-vue'; | ||
20 | 33 | ||
21 | export default defineComponent({ | 34 | export default defineComponent({ |
22 | name: 'ContactDrawer', | 35 | name: 'ContactDrawer', |
23 | - components: { BasicDrawer, BasicForm }, | 36 | + components: { BasicDrawer, BasicForm, TypographyParagraph, Typography }, |
24 | emits: ['success', 'register'], | 37 | emits: ['success', 'register'], |
25 | setup(_, { emit }) { | 38 | setup(_, { emit }) { |
26 | const isUpdate = ref(true); | 39 | const isUpdate = ref(true); |
@@ -74,3 +87,10 @@ | @@ -74,3 +87,10 @@ | ||
74 | }, | 87 | }, |
75 | }); | 88 | }); |
76 | </script> | 89 | </script> |
90 | + | ||
91 | +<style lang="less" scoped> | ||
92 | + :deep(.ant-typography-single-line) { | ||
93 | + white-space: normal; | ||
94 | + margin-bottom: 0 !important; | ||
95 | + } | ||
96 | +</style> |
@@ -114,6 +114,13 @@ export const formSchema: FormSchema[] = [ | @@ -114,6 +114,13 @@ export const formSchema: FormSchema[] = [ | ||
114 | }, | 114 | }, |
115 | }, | 115 | }, |
116 | { | 116 | { |
117 | + field: 'wechatMessage', | ||
118 | + label: ' ', | ||
119 | + slot: 'wechatMessage', | ||
120 | + component: 'Input', | ||
121 | + ifShow: ({ model }) => model.wechat, | ||
122 | + }, | ||
123 | + { | ||
117 | field: 'dingtalk', | 124 | field: 'dingtalk', |
118 | label: '钉钉', | 125 | label: '钉钉', |
119 | component: 'Input', | 126 | component: 'Input', |
@@ -25,7 +25,6 @@ | @@ -25,7 +25,6 @@ | ||
25 | const recordInfo = ref<any>({}); | 25 | const recordInfo = ref<any>({}); |
26 | 26 | ||
27 | const [register, { closeModal, setModalProps }] = useModalInner(async (data) => { | 27 | const [register, { closeModal, setModalProps }] = useModalInner(async (data) => { |
28 | - console.log(123131, data); | ||
29 | setModalProps({ confirmLoading: false, loading: true }); | 28 | setModalProps({ confirmLoading: false, loading: true }); |
30 | isUpdate.value = data?.isUpdate; | 29 | isUpdate.value = data?.isUpdate; |
31 | recordInfo.value = data?.record; | 30 | recordInfo.value = data?.record; |
@@ -78,7 +78,7 @@ | @@ -78,7 +78,7 @@ | ||
78 | </template> | 78 | </template> |
79 | <template #action="{ record }"> | 79 | <template #action="{ record }"> |
80 | <Button type="link" :disabled="categoryId === record.id" @click="handleChecked(record)">{{ | 80 | <Button type="link" :disabled="categoryId === record.id" @click="handleChecked(record)">{{ |
81 | - categoryId === record.id ? '已选择' : '选择' | 81 | + categoryId === record?.id ? '已选择' : '选择' |
82 | }}</Button> | 82 | }}</Button> |
83 | </template> | 83 | </template> |
84 | </BasicTable> | 84 | </BasicTable> |
@@ -58,7 +58,6 @@ | @@ -58,7 +58,6 @@ | ||
58 | importCsvDeviceProfileId, | 58 | importCsvDeviceProfileId, |
59 | excelExport, | 59 | excelExport, |
60 | } from '/@/api/device/modelOfMatter'; | 60 | } from '/@/api/device/modelOfMatter'; |
61 | - // import XLSX, { CellObject } from 'xlsx'; | ||
62 | import { useLoading } from '/@/components/Loading'; | 61 | import { useLoading } from '/@/components/Loading'; |
63 | import JSONImage from '/@/assets/svg/JSON.svg'; | 62 | import JSONImage from '/@/assets/svg/JSON.svg'; |
64 | import CSVImage from '/@/assets/svg/excel.svg'; | 63 | import CSVImage from '/@/assets/svg/excel.svg'; |