Showing
6 changed files
with
33 additions
and
5 deletions
| ... | ... | @@ -7,7 +7,19 @@ | 
| 7 | 7 | width="30%" | 
| 8 | 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 | 23 | </BasicDrawer> | 
| 12 | 24 | </template> | 
| 13 | 25 | <script lang="ts"> | 
| ... | ... | @@ -17,10 +29,11 @@ | 
| 17 | 29 | import { BasicDrawer, useDrawerInner } from '/@/components/Drawer'; | 
| 18 | 30 | import { saveOrEditAlarmContact } from '/@/api/alarm/contact/alarmContact'; | 
| 19 | 31 | import { useMessage } from '/@/hooks/web/useMessage'; | 
| 32 | + import { TypographyParagraph, Typography } from 'ant-design-vue'; | |
| 20 | 33 | |
| 21 | 34 | export default defineComponent({ | 
| 22 | 35 | name: 'ContactDrawer', | 
| 23 | - components: { BasicDrawer, BasicForm }, | |
| 36 | + components: { BasicDrawer, BasicForm, TypographyParagraph, Typography }, | |
| 24 | 37 | emits: ['success', 'register'], | 
| 25 | 38 | setup(_, { emit }) { | 
| 26 | 39 | const isUpdate = ref(true); | 
| ... | ... | @@ -74,3 +87,10 @@ | 
| 74 | 87 | }, | 
| 75 | 88 | }); | 
| 76 | 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 | 114 | }, | 
| 115 | 115 | }, | 
| 116 | 116 | { | 
| 117 | + field: 'wechatMessage', | |
| 118 | + label: ' ', | |
| 119 | + slot: 'wechatMessage', | |
| 120 | + component: 'Input', | |
| 121 | + ifShow: ({ model }) => model.wechat, | |
| 122 | + }, | |
| 123 | + { | |
| 117 | 124 | field: 'dingtalk', | 
| 118 | 125 | label: '钉钉', | 
| 119 | 126 | component: 'Input', | ... | ... | 
| ... | ... | @@ -25,7 +25,6 @@ | 
| 25 | 25 | const recordInfo = ref<any>({}); | 
| 26 | 26 | |
| 27 | 27 | const [register, { closeModal, setModalProps }] = useModalInner(async (data) => { | 
| 28 | - console.log(123131, data); | |
| 29 | 28 | setModalProps({ confirmLoading: false, loading: true }); | 
| 30 | 29 | isUpdate.value = data?.isUpdate; | 
| 31 | 30 | recordInfo.value = data?.record; | ... | ... | 
| ... | ... | @@ -78,7 +78,7 @@ | 
| 78 | 78 | </template> | 
| 79 | 79 | <template #action="{ record }"> | 
| 80 | 80 | <Button type="link" :disabled="categoryId === record.id" @click="handleChecked(record)">{{ | 
| 81 | - categoryId === record.id ? '已选择' : '选择' | |
| 81 | + categoryId === record?.id ? '已选择' : '选择' | |
| 82 | 82 | }}</Button> | 
| 83 | 83 | </template> | 
| 84 | 84 | </BasicTable> | ... | ... | 
| ... | ... | @@ -58,7 +58,6 @@ | 
| 58 | 58 | importCsvDeviceProfileId, | 
| 59 | 59 | excelExport, | 
| 60 | 60 | } from '/@/api/device/modelOfMatter'; | 
| 61 | - // import XLSX, { CellObject } from 'xlsx'; | |
| 62 | 61 | import { useLoading } from '/@/components/Loading'; | 
| 63 | 62 | import JSONImage from '/@/assets/svg/JSON.svg'; | 
| 64 | 63 | import CSVImage from '/@/assets/svg/excel.svg'; | ... | ... |