Browse Source

KERNEL-14215 fix:bi.year_interval组件下拉框无法显示-bug40

es6
Vivy.Pan 2 years ago
parent
commit
5d8aa7ba02
  1. 7
      src/core/func/date.js

7
src/core/func/date.js

@ -1,5 +1,6 @@
/** Constants used for time computations */ /** Constants used for time computations */
import { getDate, getTime, parseInt, i18nText } from "../2.base"; import { getDate, getTime, parseInt } from "../2.base";
import { i18nText } from "../utils";
import { StartOfWeek } from "../constant"; import { StartOfWeek } from "../constant";
import { isKhtml } from "../platform/web"; import { isKhtml } from "../platform/web";
@ -343,7 +344,7 @@ export function print(date, str) {
s["%Q"] = qr; s["%Q"] = qr;
let re = /%./g; let re = /%./g;
isKhtml = isKhtml || function () { const isNewKhtml = isKhtml || function () {
if (!_global.navigator) { if (!_global.navigator) {
return false; return false;
} }
@ -373,7 +374,7 @@ export function print(date, str) {
} }
} }
if (!isKhtml()) { if (!isNewKhtml()) {
return str.replace(re, par => s[par] || par); return str.replace(re, par => s[par] || par);
} }
const a = str.match(re); const a = str.match(re);

Loading…
Cancel
Save