Showing
4 changed files
with
25 additions
and
4 deletions
@@ -17,7 +17,8 @@ export enum ConfigurationPermission { | @@ -17,7 +17,8 @@ export enum ConfigurationPermission { | ||
17 | UPDATE = 'api:yt:dataview:center:update', | 17 | UPDATE = 'api:yt:dataview:center:update', |
18 | DELETE = 'api:yt:dataview:center:delete', | 18 | DELETE = 'api:yt:dataview:center:delete', |
19 | SHARE = 'api:yt:dataview:center:share', | 19 | SHARE = 'api:yt:dataview:center:share', |
20 | - DESIGN = 'api:yt:dataview:center:get_configuration_info:design', | 20 | + // DESIGN = 'api:yt:dataview:center:get_configuration_info:design', |
21 | + DESIGN = 'api:yt:dataview:center:get_dataview_info:design', | ||
21 | PREVIEW = 'api:yt:dataview:center:get_configuration_info:preview', | 22 | PREVIEW = 'api:yt:dataview:center:get_configuration_info:preview', |
22 | PUBLISH = 'api:yt:dataview:center:publish', | 23 | PUBLISH = 'api:yt:dataview:center:publish', |
23 | // CANCEL_PUBLISH = 'api:yt:dataview:center:cancel_publish', | 24 | // CANCEL_PUBLISH = 'api:yt:dataview:center:cancel_publish', |
@@ -280,6 +280,7 @@ | @@ -280,6 +280,7 @@ | ||
280 | </Tooltip> | 280 | </Tooltip> |
281 | <Tooltip v-if="!isCustomerUser" title="设计"> | 281 | <Tooltip v-if="!isCustomerUser" title="设计"> |
282 | <AuthIcon | 282 | <AuthIcon |
283 | + :auth="ConfigurationPermission.DESIGN" | ||
283 | :disabled="item.state === 1" | 284 | :disabled="item.state === 1" |
284 | icon="ant-design:edit-outlined" | 285 | icon="ant-design:edit-outlined" |
285 | @click="handleDesign(item)" | 286 | @click="handleDesign(item)" |
@@ -33,9 +33,15 @@ | @@ -33,9 +33,15 @@ | ||
33 | </Button> | 33 | </Button> |
34 | </Authority> | 34 | </Authority> |
35 | <Button type="primary" @click="handleOpenTsl"> 物模型TSL </Button> | 35 | <Button type="primary" @click="handleOpenTsl"> 物模型TSL </Button> |
36 | - <Upload v-if="isShowBtn" :show-upload-list="false" :customRequest="handleImportModel"> | ||
37 | - <Button type="primary" :loading="importLoading"> 导入物模型 </Button> | ||
38 | - </Upload> | 36 | + <Authority value="api:yt:things_model:import"> |
37 | + <Upload | ||
38 | + v-if="isShowBtn" | ||
39 | + :show-upload-list="false" | ||
40 | + :customRequest="handleImportModel" | ||
41 | + > | ||
42 | + <Button type="primary" :loading="importLoading"> 导入物模型 </Button> | ||
43 | + </Upload> | ||
44 | + </Authority> | ||
39 | </div> | 45 | </div> |
40 | <div class="flex gap-2"> | 46 | <div class="flex gap-2"> |
41 | <Authority :value="ModelOfMatterPermission.RELEASE"> | 47 | <Authority :value="ModelOfMatterPermission.RELEASE"> |
@@ -18,6 +18,7 @@ | @@ -18,6 +18,7 @@ | ||
18 | import { UserDTO } from '/@/api/tenant/tenantInfo'; | 18 | import { UserDTO } from '/@/api/tenant/tenantInfo'; |
19 | import { ChineseRegexp, EmailRegexp, emailRule, phoneRule } from '/@/utils/rules'; | 19 | import { ChineseRegexp, EmailRegexp, emailRule, phoneRule } from '/@/utils/rules'; |
20 | import { chineseAndEnlishRule } from '/@/utils/rules'; | 20 | import { chineseAndEnlishRule } from '/@/utils/rules'; |
21 | + import { getAllRoleList } from '/@/api/system/system'; | ||
21 | 22 | ||
22 | export default defineComponent({ | 23 | export default defineComponent({ |
23 | name: 'TenantAdminFormDrawer', | 24 | name: 'TenantAdminFormDrawer', |
@@ -106,6 +107,17 @@ | @@ -106,6 +107,17 @@ | ||
106 | rules: emailRule, | 107 | rules: emailRule, |
107 | }, | 108 | }, |
108 | { | 109 | { |
110 | + field: 'roleIds', | ||
111 | + label: '租户角色', | ||
112 | + component: 'ApiSelect', | ||
113 | + componentProps: { | ||
114 | + mode: 'multiple', | ||
115 | + api: getAllRoleList, | ||
116 | + labelField: 'name', | ||
117 | + valueField: 'id', | ||
118 | + }, | ||
119 | + }, | ||
120 | + { | ||
109 | field: 'enabled', | 121 | field: 'enabled', |
110 | label: '状态', | 122 | label: '状态', |
111 | required: true, | 123 | required: true, |
@@ -159,6 +171,7 @@ | @@ -159,6 +171,7 @@ | ||
159 | ? values.tenantExpireTime.format('YYYY-MM-DD HH:mm:ss') | 171 | ? values.tenantExpireTime.format('YYYY-MM-DD HH:mm:ss') |
160 | : null, | 172 | : null, |
161 | tenantId: tenantId.value, | 173 | tenantId: tenantId.value, |
174 | + roleIds: values.roleIds, | ||
162 | }; | 175 | }; |
163 | await saveTenantAdmin(requestParams as any as UserDTO); | 176 | await saveTenantAdmin(requestParams as any as UserDTO); |
164 | closeDrawer(); //关闭侧框 | 177 | closeDrawer(); //关闭侧框 |