diff --git a/packages/presets/nocobase/src/client/index.ts b/packages/presets/nocobase/src/client/index.ts index 894bc64488..c3c35d81c8 100644 --- a/packages/presets/nocobase/src/client/index.ts +++ b/packages/presets/nocobase/src/client/index.ts @@ -2,7 +2,7 @@ import { NocoBaseBuildInPlugin, Plugin } from '@nocobase/client'; const getCurrentTimezone = () => { const timezoneOffset = new Date().getTimezoneOffset() / -60; - const timezone = String(timezoneOffset).padStart(2, '0') + ':00'; + const timezone = String(Math.abs(timezoneOffset)).padStart(2, '0') + ':00'; return (timezoneOffset > 0 ? '+' : '-') + timezone; };