mirror of
https://github.com/linux-do/new-api.git
synced 2025-11-11 00:23:42 +08:00
perf: 运营设置-提示文案
This commit is contained in:
@@ -40,13 +40,13 @@ export default function SettingsCreditLimit(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败,请重试');
|
if (res.includes(undefined)) return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
@@ -44,13 +44,13 @@ export default function DataDashboard(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败');
|
if (res.includes(undefined)) return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
@@ -41,13 +41,13 @@ export default function SettingsDrawing(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败');
|
if (res.includes(undefined)) return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
@@ -47,13 +47,13 @@ export default function GeneralSettings(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败');
|
if (res.includes(undefined)) return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
@@ -43,13 +43,13 @@ export default function SettingsLog(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败');
|
if (res.includes(undefined)) return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
@@ -43,13 +43,14 @@ export default function SettingsMagnification(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败');
|
if (res.includes(undefined))
|
||||||
|
return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
@@ -40,13 +40,13 @@ export default function SettingsMonitoring(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败');
|
if (res.includes(undefined)) return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
@@ -39,13 +39,13 @@ export default function SettingsSensitiveWords(props) {
|
|||||||
if (requestQueue.length === 1) {
|
if (requestQueue.length === 1) {
|
||||||
if (res.includes(undefined)) return;
|
if (res.includes(undefined)) return;
|
||||||
} else if (requestQueue.length > 1) {
|
} else if (requestQueue.length > 1) {
|
||||||
if (res.includes(undefined)) return showError('部分更新失败');
|
if (res.includes(undefined)) return showError('部分保存失败,请重试');
|
||||||
}
|
}
|
||||||
showSuccess('更新成功');
|
showSuccess('保存成功');
|
||||||
props.refresh();
|
props.refresh();
|
||||||
})
|
})
|
||||||
.catch(() => {
|
.catch(() => {
|
||||||
showError('更新失败');
|
showError('保存失败,请重试');
|
||||||
})
|
})
|
||||||
.finally(() => {
|
.finally(() => {
|
||||||
setLoading(false);
|
setLoading(false);
|
||||||
|
|||||||
Reference in New Issue
Block a user