mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core: fix contest_edit timezone convert
This commit is contained in:
1 parent
0c587d1786
commit
c00c2160ec
7 files changed
+22
-23
No files matched your search
@@ -10,9 +10,6 @@ declare global {
|
||||
interface ArrayConstructor {
|
||||
isDiff: (a: any[], b: any[]) => boolean;
|
||||
}
|
||||
interface Date {
|
||||
format: (fmt?: string) => string;
|
||||
}
|
||||
interface Math {
|
||||
sum: (...args: Array<number[] | number>) => number;
|
||||
}
|
||||
@@ -75,6 +72,7 @@ Array.isDiff = function isDiff(a, b) {
|
||||
return false;
|
||||
};
|
||||
|
||||
// @ts-ignore
|
||||
Date.prototype.format = function formatDate(fmt = '%Y-%m-%d %H:%M:%S') {
|
||||
let m = this.getMonth() + 1;
|
||||
if (m < 10) m = `0${m}`;
|
||||
|
||||
Reference in new issue
Block a user