mirror of
https://github.com/usememos/memos.git
synced 2025-06-05 22:09:59 +02:00
chore: update upgrade version view (#1791)
This commit is contained in:
@ -12,7 +12,6 @@ import "@/less/settings/system-section.less";
|
||||
interface State {
|
||||
dbSize: number;
|
||||
allowSignUp: boolean;
|
||||
ignoreUpgrade: boolean;
|
||||
disablePublicMemos: boolean;
|
||||
additionalStyle: string;
|
||||
additionalScript: string;
|
||||
@ -27,7 +26,6 @@ const SystemSection = () => {
|
||||
const [state, setState] = useState<State>({
|
||||
dbSize: systemStatus.dbSize,
|
||||
allowSignUp: systemStatus.allowSignUp,
|
||||
ignoreUpgrade: systemStatus.ignoreUpgrade,
|
||||
additionalStyle: systemStatus.additionalStyle,
|
||||
additionalScript: systemStatus.additionalScript,
|
||||
disablePublicMemos: systemStatus.disablePublicMemos,
|
||||
@ -82,17 +80,6 @@ const SystemSection = () => {
|
||||
});
|
||||
};
|
||||
|
||||
const handleIgnoreUpgradeChanged = async (value: boolean) => {
|
||||
setState({
|
||||
...state,
|
||||
ignoreUpgrade: value,
|
||||
});
|
||||
await api.upsertSystemSetting({
|
||||
name: "ignore-upgrade",
|
||||
value: JSON.stringify(value),
|
||||
});
|
||||
};
|
||||
|
||||
const handleUpdateCustomizedProfileButtonClick = () => {
|
||||
showUpdateCustomizedProfileDialog();
|
||||
};
|
||||
@ -261,10 +248,6 @@ const SystemSection = () => {
|
||||
<span className="normal-text">{t("setting.system-section.allow-user-signup")}</span>
|
||||
<Switch checked={state.allowSignUp} onChange={(event) => handleAllowSignUpChanged(event.target.checked)} />
|
||||
</div>
|
||||
<div className="form-label">
|
||||
<span className="normal-text">{t("setting.system-section.ignore-version-upgrade")}</span>
|
||||
<Switch checked={state.ignoreUpgrade} onChange={(event) => handleIgnoreUpgradeChanged(event.target.checked)} />
|
||||
</div>
|
||||
<div className="form-label">
|
||||
<span className="normal-text">{t("setting.system-section.disable-public-memos")}</span>
|
||||
<Switch checked={state.disablePublicMemos} onChange={(event) => handleDisablePublicMemosChanged(event.target.checked)} />
|
||||
|
Reference in New Issue
Block a user