mirror of https://gitee.com/topiam/eiam
⚡ 优化代码
parent
dac0eb6342
commit
e96846e8fe
|
@ -47,7 +47,7 @@
|
||||||
"@ant-design/charts": "^1.4.2",
|
"@ant-design/charts": "^1.4.2",
|
||||||
"@ant-design/icons": "^5.2.6",
|
"@ant-design/icons": "^5.2.6",
|
||||||
"@ant-design/maps": "^1.0.7",
|
"@ant-design/maps": "^1.0.7",
|
||||||
"@ant-design/pro-components": "^2.6.16",
|
"@ant-design/pro-components": "^2.6.18",
|
||||||
"ahooks": "^3.7.8",
|
"ahooks": "^3.7.8",
|
||||||
"antd": "^5.8.6",
|
"antd": "^5.8.6",
|
||||||
"antd-img-crop": "^4.12.2",
|
"antd-img-crop": "^4.12.2",
|
||||||
|
@ -89,14 +89,14 @@
|
||||||
"@types/google-libphonenumber": "^7.4.26",
|
"@types/google-libphonenumber": "^7.4.26",
|
||||||
"@types/history": "^4.7.11",
|
"@types/history": "^4.7.11",
|
||||||
"@types/js-yaml": "^4.0.5",
|
"@types/js-yaml": "^4.0.5",
|
||||||
"@types/lodash": "^4.14.197",
|
"@types/lodash": "^4.14.198",
|
||||||
"@types/numeral": "^2.0.2",
|
"@types/numeral": "^2.0.2",
|
||||||
"@types/qs": "^6.9.8",
|
"@types/qs": "^6.9.8",
|
||||||
"@types/react": "^18.2.21",
|
"@types/react": "^18.2.21",
|
||||||
"@types/react-dom": "^18.2.7",
|
"@types/react-dom": "^18.2.7",
|
||||||
"@types/react-helmet": "^6.1.6",
|
"@types/react-helmet": "^6.1.6",
|
||||||
"@umijs/lint": "^4.0.79",
|
"@umijs/lint": "^4.0.80",
|
||||||
"@umijs/max": "^4.0.79",
|
"@umijs/max": "^4.0.80",
|
||||||
"cross-env": "^7.0.3",
|
"cross-env": "^7.0.3",
|
||||||
"cross-port-killer": "^1.4.0",
|
"cross-port-killer": "^1.4.0",
|
||||||
"eslint": "^8.48.0",
|
"eslint": "^8.48.0",
|
||||||
|
|
|
@ -35,7 +35,7 @@ export default (): React.ReactNode => {
|
||||||
const { type } = query as {
|
const { type } = query as {
|
||||||
type: TabType;
|
type: TabType;
|
||||||
};
|
};
|
||||||
if (!type) {
|
if (!type || !TabType[type]) {
|
||||||
setActiveKey(TabType.mail_template);
|
setActiveKey(TabType.mail_template);
|
||||||
history.replace({
|
history.replace({
|
||||||
pathname: location.pathname,
|
pathname: location.pathname,
|
||||||
|
|
|
@ -21,18 +21,6 @@ import type { SortOrder } from 'antd/es/table/interface';
|
||||||
import { request } from '@umijs/max';
|
import { request } from '@umijs/max';
|
||||||
import type { UploadFile } from 'antd/es/upload/interface';
|
import type { UploadFile } from 'antd/es/upload/interface';
|
||||||
|
|
||||||
/**
|
|
||||||
* Get Application Template FormSchema
|
|
||||||
*/
|
|
||||||
export async function getAppTemplateFormSchema(
|
|
||||||
code: string,
|
|
||||||
): Promise<API.ApiResult<Record<string, any>>> {
|
|
||||||
return request<API.ApiResult<AppAPI.GetApp>>(`/api/v1/app/template/form_schema`, {
|
|
||||||
method: 'GET',
|
|
||||||
params: { code: code },
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取应用列表
|
* 获取应用列表
|
||||||
*/
|
*/
|
||||||
|
@ -65,15 +53,6 @@ export async function updateApp(params: Record<string, string>): Promise<API.Api
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Get Application
|
|
||||||
*/
|
|
||||||
export async function getApp(id: string): Promise<API.ApiResult<AppAPI.GetApp>> {
|
|
||||||
return request<API.ApiResult<AppAPI.GetApp>>(`/api/v1/app/get/${id}`, {
|
|
||||||
method: 'GET',
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get Config
|
* Get Config
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -48,7 +48,7 @@
|
||||||
"@ant-design/charts": "^1.4.2",
|
"@ant-design/charts": "^1.4.2",
|
||||||
"@ant-design/icons": "^5.2.6",
|
"@ant-design/icons": "^5.2.6",
|
||||||
"@ant-design/maps": "^1.0.7",
|
"@ant-design/maps": "^1.0.7",
|
||||||
"@ant-design/pro-components": "^2.6.16",
|
"@ant-design/pro-components": "^2.6.18",
|
||||||
"ahooks": "^3.7.8",
|
"ahooks": "^3.7.8",
|
||||||
"antd": "^5.8.6",
|
"antd": "^5.8.6",
|
||||||
"antd-img-crop": "^4.12.2",
|
"antd-img-crop": "^4.12.2",
|
||||||
|
@ -84,14 +84,14 @@
|
||||||
"@types/google-libphonenumber": "^7.4.26",
|
"@types/google-libphonenumber": "^7.4.26",
|
||||||
"@types/history": "^4.7.11",
|
"@types/history": "^4.7.11",
|
||||||
"@types/js-yaml": "^4.0.5",
|
"@types/js-yaml": "^4.0.5",
|
||||||
"@types/lodash": "^4.14.197",
|
"@types/lodash": "^4.14.198",
|
||||||
"@types/numeral": "^2.0.2",
|
"@types/numeral": "^2.0.2",
|
||||||
"@types/qs": "^6.9.8",
|
"@types/qs": "^6.9.8",
|
||||||
"@types/react": "^18.2.21",
|
"@types/react": "^18.2.21",
|
||||||
"@types/react-dom": "^18.2.7",
|
"@types/react-dom": "^18.2.7",
|
||||||
"@types/react-helmet": "^6.1.6",
|
"@types/react-helmet": "^6.1.6",
|
||||||
"@umijs/lint": "^4.0.79",
|
"@umijs/lint": "^4.0.80",
|
||||||
"@umijs/max": "^4.0.79",
|
"@umijs/max": "^4.0.80",
|
||||||
"cross-env": "^7.0.3",
|
"cross-env": "^7.0.3",
|
||||||
"cross-port-killer": "^1.4.0",
|
"cross-port-killer": "^1.4.0",
|
||||||
"eslint": "^8.48.0",
|
"eslint": "^8.48.0",
|
||||||
|
|
|
@ -70,7 +70,7 @@ const ModifyPassword = (props: {
|
||||||
destroyOnClose: true,
|
destroyOnClose: true,
|
||||||
maskClosable: false,
|
maskClosable: false,
|
||||||
onCancel: async () => {
|
onCancel: async () => {
|
||||||
await setVisible(false);
|
setVisible(false);
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
onFinish={async (formData: Record<string, any>) => {
|
onFinish={async (formData: Record<string, any>) => {
|
||||||
|
@ -89,7 +89,7 @@ const ModifyPassword = (props: {
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
if (success && result) {
|
if (success && result) {
|
||||||
await setVisible(false);
|
setVisible(false);
|
||||||
message.success(intl.formatMessage({ id: 'page.account.modify_password.success' }));
|
message.success(intl.formatMessage({ id: 'page.account.modify_password.success' }));
|
||||||
setRefresh(true);
|
setRefresh(true);
|
||||||
return Promise.resolve();
|
return Promise.resolve();
|
||||||
|
|
Loading…
Reference in New Issue