Commit c2151650fa13c746420aa4ae61713bbb13d3fa82
Merge branch 'main' of http://git.yuntengiot.com/huang/yun-teng-iot-front
Showing
6 changed files
with
44 additions
and
11 deletions
| ... | ... | @@ -29,11 +29,11 @@ const { createMessage, createErrorModal } = useMessage(); |
| 29 | 29 | |
| 30 | 30 | const getJwtTokenInfo = getAuthCache(REFRESH_TOKEN_KEY); |
| 31 | 31 | const getRefreshTokenInfo = getAuthCache(JWT_TOKEN_KEY); |
| 32 | -console.log(getJwtTokenInfo); | |
| 33 | -console.log(getRefreshTokenInfo); | |
| 32 | +// console.log(getJwtTokenInfo); | |
| 33 | +// console.log(getRefreshTokenInfo); | |
| 34 | 34 | const getRefreshTokenInfo1 = getAuthCache(PROJ_CFG_KEY); |
| 35 | 35 | |
| 36 | -console.log(getRefreshTokenInfo1); | |
| 36 | +// console.log(getRefreshTokenInfo1); | |
| 37 | 37 | |
| 38 | 38 | /** |
| 39 | 39 | * @description: 数据处理,方便区分多种处理方式 | ... | ... |
| ... | ... | @@ -12,14 +12,49 @@ |
| 12 | 12 | <div class="md:w-3/10 w-full enter-y"> |
| 13 | 13 | <HelpDoc /> |
| 14 | 14 | </div> |
| 15 | + <!-- 密码弹窗 --> | |
| 16 | + <BasicModal | |
| 17 | + @register="register" | |
| 18 | + v-bind="$attrs" | |
| 19 | + :mask="true" | |
| 20 | + :showCancelBtn="false" | |
| 21 | + :showOkBtn="false" | |
| 22 | + :canFullscreen="false" | |
| 23 | + :closable="false" | |
| 24 | + :maskStyle="maskColor" | |
| 25 | + :height="600" | |
| 26 | + :width="1500" | |
| 27 | + :maskClosable="false" | |
| 28 | + title="请修改密码" | |
| 29 | + :helpMessage="['请您修改密码']" | |
| 30 | + > | |
| 31 | + <PasswordDialog /> | |
| 32 | + </BasicModal> | |
| 15 | 33 | </div> |
| 16 | 34 | </template> |
| 17 | 35 | <script lang="ts" setup> |
| 18 | - import { ref } from 'vue'; | |
| 36 | + import PasswordDialog from '/@/views/system/password/index.vue'; | |
| 37 | + import { BasicModal, useModal } from '/@/components/Modal'; | |
| 38 | + import { getAuthCache } from '/@/utils/auth'; | |
| 39 | + import { USER_INFO_KEY } from '/@/enums/cacheEnum'; | |
| 40 | + import { ref, onMounted } from 'vue'; | |
| 19 | 41 | import GrowCard from './components/GrowCard.vue'; |
| 20 | 42 | import SiteAnalysis from './components/SiteAnalysis.vue'; |
| 21 | 43 | import { Card } from 'ant-design-vue'; |
| 22 | 44 | import HelpDoc from './components/HelpDoc.vue'; |
| 45 | + | |
| 46 | + const maskColor = ref({ backgroundColor: 'grey' }); | |
| 47 | + const statusModel = ref(false); | |
| 48 | + const [register, { openModal }] = useModal(); | |
| 49 | + onMounted(() => { | |
| 50 | + const userInfo: object = getAuthCache(USER_INFO_KEY); | |
| 51 | + if (userInfo.needSetPwd == true) { | |
| 52 | + statusModel.value = true; | |
| 53 | + openModal(statusModel.value); | |
| 54 | + } else if (userInfo.needSetPwd == false) { | |
| 55 | + openModal(statusModel.value); | |
| 56 | + } | |
| 57 | + }); | |
| 23 | 58 | const loading = ref(true); |
| 24 | 59 | setTimeout(() => { |
| 25 | 60 | loading.value = false; | ... | ... |
| ... | ... | @@ -70,7 +70,7 @@ |
| 70 | 70 | }); |
| 71 | 71 | |
| 72 | 72 | //编辑模式,菜单名称为不可用 |
| 73 | - updateSchema({ field: 'title', componentProps: { disabled: true } }); | |
| 73 | + updateSchema({ field: 'title', componentProps: { disabled: false } }); | |
| 74 | 74 | } |
| 75 | 75 | if (isUpdate.value) { |
| 76 | 76 | menuId = Reflect.get(data.record, 'id'); |
| ... | ... | @@ -128,7 +128,6 @@ |
| 128 | 128 | status: Reflect.get(values, 'status'), |
| 129 | 129 | }; |
| 130 | 130 | Reflect.set(values, 'meta', metaTemp); |
| 131 | - | |
| 132 | 131 | // saveMenu |
| 133 | 132 | const data = await saveMenuApi(values, isUpdate.value); |
| 134 | 133 | console.log('_______保存返回结果____data:' + data); | ... | ... |
| ... | ... | @@ -54,8 +54,8 @@ export const columns: BasicColumn[] = [ |
| 54 | 54 | const status = record.meta.status; |
| 55 | 55 | const enable = ~~status === 0; |
| 56 | 56 | const color = enable ? 'green' : 'red'; |
| 57 | - let enableText: string = t('routes.common.system.tableTitleSystemEnable'); //国际化处理--启用 | |
| 58 | - let stopText: string = t('routes.common.system.tableTitleSystemStop'); //国际化处理--停用 | |
| 57 | + const enableText: string = t('routes.common.system.tableTitleSystemEnable'); //国际化处理--启用 | |
| 58 | + const stopText: string = t('routes.common.system.tableTitleSystemStop'); //国际化处理--停用 | |
| 59 | 59 | const text = enable ? enableText : stopText; |
| 60 | 60 | return h(Tag, { color: color }, () => text); |
| 61 | 61 | }, | ... | ... |
| ... | ... | @@ -50,7 +50,6 @@ |
| 50 | 50 | const treeData = ref<TreeItem[]>([]); |
| 51 | 51 | const roleMenus = ref<string[]>([]); |
| 52 | 52 | const allCheckedKeys = ref<string[]>([]); |
| 53 | - const roleHalfCheckedKeys = ref<string[]>([]); | |
| 54 | 53 | const roleId = ref<string>(''); |
| 55 | 54 | const [registerForm, { resetFields, setFieldsValue, validate }] = useForm({ |
| 56 | 55 | labelWidth: 90, | ... | ... |