Commit fdfdd823a60fbe2fb9eeee914381f6a508b2dfef
1 parent
5da9ae25
fix: tenant
Showing
2 changed files
with
1 additions
and
7 deletions
yudao-ui-admin-vue3/src/views/system/tenant/index.vue
| @@ -99,7 +99,6 @@ | @@ -99,7 +99,6 @@ | ||
| 99 | </template> | 99 | </template> |
| 100 | <script setup lang="ts"> | 100 | <script setup lang="ts"> |
| 101 | import { ref, unref, onMounted } from 'vue' | 101 | import { ref, unref, onMounted } from 'vue' |
| 102 | -import dayjs from 'dayjs' | ||
| 103 | import { useI18n } from '@/hooks/web/useI18n' | 102 | import { useI18n } from '@/hooks/web/useI18n' |
| 104 | import { useMessage } from '@/hooks/web/useMessage' | 103 | import { useMessage } from '@/hooks/web/useMessage' |
| 105 | import { useVxeGrid } from '@/hooks/web/useVxeGrid' | 104 | import { useVxeGrid } from '@/hooks/web/useVxeGrid' |
| @@ -163,7 +162,6 @@ const handleUpdate = async (rowId: number) => { | @@ -163,7 +162,6 @@ const handleUpdate = async (rowId: number) => { | ||
| 163 | // 设置数据 | 162 | // 设置数据 |
| 164 | const res = await TenantApi.getTenantApi(rowId) | 163 | const res = await TenantApi.getTenantApi(rowId) |
| 165 | tenantPackageId.value = res.packageId | 164 | tenantPackageId.value = res.packageId |
| 166 | - res.expireTime = dayjs(res.expireTime).format('YYYY-MM-DD HH:mm:ss') | ||
| 167 | unref(formRef)?.setValues(res) | 165 | unref(formRef)?.setValues(res) |
| 168 | } | 166 | } |
| 169 | 167 | ||
| @@ -198,11 +196,9 @@ const submitForm = async () => { | @@ -198,11 +196,9 @@ const submitForm = async () => { | ||
| 198 | const data = unref(formRef)?.formModel as TenantApi.TenantVO | 196 | const data = unref(formRef)?.formModel as TenantApi.TenantVO |
| 199 | data.packageId = tenantPackageId.value | 197 | data.packageId = tenantPackageId.value |
| 200 | if (actionType.value === 'create') { | 198 | if (actionType.value === 'create') { |
| 201 | - data.expireTime = dayjs(data.expireTime).valueOf().toString() | ||
| 202 | await TenantApi.createTenantApi(data) | 199 | await TenantApi.createTenantApi(data) |
| 203 | message.success(t('common.createSuccess')) | 200 | message.success(t('common.createSuccess')) |
| 204 | } else { | 201 | } else { |
| 205 | - data.expireTime = dayjs(data.expireTime).valueOf().toString() | ||
| 206 | await TenantApi.updateTenantApi(data) | 202 | await TenantApi.updateTenantApi(data) |
| 207 | message.success(t('common.updateSuccess')) | 203 | message.success(t('common.updateSuccess')) |
| 208 | } | 204 | } |
yudao-ui-admin-vue3/src/views/system/tenant/tenant.data.ts
| @@ -69,11 +69,9 @@ const crudSchemas = reactive<VxeCrudSchema>({ | @@ -69,11 +69,9 @@ const crudSchemas = reactive<VxeCrudSchema>({ | ||
| 69 | field: 'expireTime', | 69 | field: 'expireTime', |
| 70 | formatter: 'formatDate', | 70 | formatter: 'formatDate', |
| 71 | form: { | 71 | form: { |
| 72 | - show: true, | ||
| 73 | component: 'DatePicker', | 72 | component: 'DatePicker', |
| 74 | componentProps: { | 73 | componentProps: { |
| 75 | - type: 'datetime', | ||
| 76 | - valueFormat: 'x' | 74 | + type: 'datetime' |
| 77 | } | 75 | } |
| 78 | } | 76 | } |
| 79 | }, | 77 | }, |