Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
daa10617c0 | ||
|
|
c3b5c13cc5 | ||
|
|
1dd83645bd |
@@ -78,6 +78,9 @@ export default defineConfig({
|
|||||||
model: {},
|
model: {},
|
||||||
initialState: {},
|
initialState: {},
|
||||||
request: {},
|
request: {},
|
||||||
|
routePrefetch: {
|
||||||
|
defaultPrefetch: 'intent'
|
||||||
|
},
|
||||||
keepalive: keepAlive,
|
keepalive: keepAlive,
|
||||||
locale: {
|
locale: {
|
||||||
antd: true,
|
antd: true,
|
||||||
|
|||||||
@@ -164,6 +164,7 @@ const SiderMenu: React.FC<SiderMenuProps> = (props) => {
|
|||||||
key={key}
|
key={key}
|
||||||
>
|
>
|
||||||
<Link
|
<Link
|
||||||
|
prefetch="intent"
|
||||||
to={menuItem.path.replace('/*', '')}
|
to={menuItem.path.replace('/*', '')}
|
||||||
target={menuItem.target}
|
target={menuItem.target}
|
||||||
className={cx(styles.menuItemWrapper, 'menu-item', {
|
className={cx(styles.menuItemWrapper, 'menu-item', {
|
||||||
|
|||||||
@@ -1,7 +1,11 @@
|
|||||||
import { initialPasswordAtom, userAtom } from '@/atoms/user';
|
import { initialPasswordAtom, userAtom } from '@/atoms/user';
|
||||||
import SealInput from '@/components/seal-form/seal-input';
|
import SealInput from '@/components/seal-form/seal-input';
|
||||||
import { PasswordReg } from '@/config';
|
import { PasswordReg } from '@/config';
|
||||||
import { CRYPT_TEXT } from '@/utils/localstore/index';
|
import {
|
||||||
|
CRYPT_TEXT,
|
||||||
|
IS_FIRST_LOGIN,
|
||||||
|
writeState
|
||||||
|
} from '@/utils/localstore/index';
|
||||||
import { LockOutlined } from '@ant-design/icons';
|
import { LockOutlined } from '@ant-design/icons';
|
||||||
import { useIntl } from '@umijs/max';
|
import { useIntl } from '@umijs/max';
|
||||||
import { Button, Form, message } from 'antd';
|
import { Button, Form, message } from 'antd';
|
||||||
@@ -38,6 +42,8 @@ const PasswordForm: React.FC = () => {
|
|||||||
require_password_change: false
|
require_password_change: false
|
||||||
});
|
});
|
||||||
setInitialPassword('');
|
setInitialPassword('');
|
||||||
|
// Reset first login flag
|
||||||
|
writeState(IS_FIRST_LOGIN, null);
|
||||||
gotoDefaultPage(userInfo);
|
gotoDefaultPage(userInfo);
|
||||||
message.success(intl.formatMessage({ id: 'common.message.success' }));
|
message.success(intl.formatMessage({ id: 'common.message.success' }));
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|||||||
@@ -187,7 +187,11 @@ const Workers: React.FC = () => {
|
|||||||
if (!currentData) {
|
if (!currentData) {
|
||||||
currentData = clusterData.list[0];
|
currentData = clusterData.list[0];
|
||||||
}
|
}
|
||||||
handleAddWorker(currentData as ClusterListItem);
|
if (currentData) {
|
||||||
|
handleAddWorker(currentData as ClusterListItem);
|
||||||
|
} else {
|
||||||
|
message.info(intl.formatMessage({ id: 'noresult.resources.cluster' }));
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
const { noResourceResult } = useNoResourceResult({
|
const { noResourceResult } = useNoResourceResult({
|
||||||
|
|||||||
Reference in New Issue
Block a user