Commit a66d28edb8d81c860b8ef5213d355e3f8ae2c24a

Authored by xp.Huang
2 parents 813e4330 61d4681f

Merge branch 'fix/import-style' into 'main_dev'

fix: 修改物模型导入样式问题

See merge request yunteng/thingskit-front!1070
... ... @@ -5,8 +5,7 @@
5 5 destroyOnClose
6 6 v-bind="$attrs"
7 7 width="25rem"
8   - :height="160"
9   - :min-height="160"
  8 + :min-height="150"
10 9 @register="register"
11 10 @cancel="handleCancel"
12 11 :showOkBtn="false"
... ... @@ -17,7 +16,7 @@
17 16 <Radio value="2">JSON导入</Radio>
18 17 <Radio value="1">Excel导入</Radio>
19 18 </RadioGroup>
20   - <div v-if="model.importType == 1" class="absolute -left-28 mb-1">
  19 + <div v-if="model.importType === '1'" class="absolute -left-28">
21 20 <Button @click="handleTemplateDownload" type="link">excel模板下载</Button>
22 21 </div>
23 22 </template>
... ... @@ -83,7 +82,6 @@
83 82 component: 'ApiUpload',
84 83 componentProps: ({ formModel }) => {
85 84 return {
86   - // listType: 'picture-card',
87 85 maxFileLimit: 1,
88 86 accept: formModel.importType == 2 ? '.json,' : '.csv,.xls,.xlsx',
89 87 api: async (file: File) => {
... ... @@ -93,6 +91,10 @@
93 91 } else {
94 92 handleCSVImport(file);
95 93 }
  94 + return {
  95 + uid: '',
  96 + name: '',
  97 + };
96 98 } catch {}
97 99 },
98 100 };
... ... @@ -218,4 +220,8 @@
218 220 };
219 221 </script>
220 222
221   -<style lang="less" scope></style>
  223 +<style lang="less" scoped>
  224 + :deep(.ant-form-item) {
  225 + margin-bottom: 28px !important;
  226 + }
  227 +</style>
... ...