sirius-common-utils 1.0.9 → 1.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/sirius-common-utils.js +244 -1
- package/dist/sirius-common-utils.umd.cjs +246 -3
- package/package.json +1 -1
|
@@ -530,6 +530,249 @@ const AxiosUtils = {
|
|
|
530
530
|
getErrorMsgByCode,
|
|
531
531
|
RESULT
|
|
532
532
|
};
|
|
533
|
+
var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
|
|
534
|
+
function getDefaultExportFromCjs(x) {
|
|
535
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
536
|
+
}
|
|
537
|
+
var updateLocale$1 = { exports: {} };
|
|
538
|
+
(function(module, exports) {
|
|
539
|
+
!function(e, n) {
|
|
540
|
+
module.exports = n();
|
|
541
|
+
}(commonjsGlobal, function() {
|
|
542
|
+
return function(e, n, t) {
|
|
543
|
+
t.updateLocale = function(e2, n2) {
|
|
544
|
+
var o = t.Ls[e2];
|
|
545
|
+
if (o)
|
|
546
|
+
return (n2 ? Object.keys(n2) : []).forEach(function(e3) {
|
|
547
|
+
o[e3] = n2[e3];
|
|
548
|
+
}), o;
|
|
549
|
+
};
|
|
550
|
+
};
|
|
551
|
+
});
|
|
552
|
+
})(updateLocale$1);
|
|
553
|
+
var updateLocaleExports = updateLocale$1.exports;
|
|
554
|
+
const updateLocale = /* @__PURE__ */ getDefaultExportFromCjs(updateLocaleExports);
|
|
555
|
+
var customParseFormat$1 = { exports: {} };
|
|
556
|
+
(function(module, exports) {
|
|
557
|
+
!function(e, t) {
|
|
558
|
+
module.exports = t();
|
|
559
|
+
}(commonjsGlobal, function() {
|
|
560
|
+
var e = { LTS: "h:mm:ss A", LT: "h:mm A", L: "MM/DD/YYYY", LL: "MMMM D, YYYY", LLL: "MMMM D, YYYY h:mm A", LLLL: "dddd, MMMM D, YYYY h:mm A" }, t = /(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g, n = /\d\d/, r = /\d\d?/, i = /\d*[^-_:/,()\s\d]+/, o = {}, s = function(e2) {
|
|
561
|
+
return (e2 = +e2) + (e2 > 68 ? 1900 : 2e3);
|
|
562
|
+
};
|
|
563
|
+
var a = function(e2) {
|
|
564
|
+
return function(t2) {
|
|
565
|
+
this[e2] = +t2;
|
|
566
|
+
};
|
|
567
|
+
}, f = [/[+-]\d\d:?(\d\d)?|Z/, function(e2) {
|
|
568
|
+
(this.zone || (this.zone = {})).offset = function(e3) {
|
|
569
|
+
if (!e3)
|
|
570
|
+
return 0;
|
|
571
|
+
if ("Z" === e3)
|
|
572
|
+
return 0;
|
|
573
|
+
var t2 = e3.match(/([+-]|\d\d)/g), n2 = 60 * t2[1] + (+t2[2] || 0);
|
|
574
|
+
return 0 === n2 ? 0 : "+" === t2[0] ? -n2 : n2;
|
|
575
|
+
}(e2);
|
|
576
|
+
}], h = function(e2) {
|
|
577
|
+
var t2 = o[e2];
|
|
578
|
+
return t2 && (t2.indexOf ? t2 : t2.s.concat(t2.f));
|
|
579
|
+
}, u = function(e2, t2) {
|
|
580
|
+
var n2, r2 = o.meridiem;
|
|
581
|
+
if (r2) {
|
|
582
|
+
for (var i2 = 1; i2 <= 24; i2 += 1)
|
|
583
|
+
if (e2.indexOf(r2(i2, 0, t2)) > -1) {
|
|
584
|
+
n2 = i2 > 12;
|
|
585
|
+
break;
|
|
586
|
+
}
|
|
587
|
+
} else
|
|
588
|
+
n2 = e2 === (t2 ? "pm" : "PM");
|
|
589
|
+
return n2;
|
|
590
|
+
}, d = { A: [i, function(e2) {
|
|
591
|
+
this.afternoon = u(e2, false);
|
|
592
|
+
}], a: [i, function(e2) {
|
|
593
|
+
this.afternoon = u(e2, true);
|
|
594
|
+
}], S: [/\d/, function(e2) {
|
|
595
|
+
this.milliseconds = 100 * +e2;
|
|
596
|
+
}], SS: [n, function(e2) {
|
|
597
|
+
this.milliseconds = 10 * +e2;
|
|
598
|
+
}], SSS: [/\d{3}/, function(e2) {
|
|
599
|
+
this.milliseconds = +e2;
|
|
600
|
+
}], s: [r, a("seconds")], ss: [r, a("seconds")], m: [r, a("minutes")], mm: [r, a("minutes")], H: [r, a("hours")], h: [r, a("hours")], HH: [r, a("hours")], hh: [r, a("hours")], D: [r, a("day")], DD: [n, a("day")], Do: [i, function(e2) {
|
|
601
|
+
var t2 = o.ordinal, n2 = e2.match(/\d+/);
|
|
602
|
+
if (this.day = n2[0], t2)
|
|
603
|
+
for (var r2 = 1; r2 <= 31; r2 += 1)
|
|
604
|
+
t2(r2).replace(/\[|\]/g, "") === e2 && (this.day = r2);
|
|
605
|
+
}], M: [r, a("month")], MM: [n, a("month")], MMM: [i, function(e2) {
|
|
606
|
+
var t2 = h("months"), n2 = (h("monthsShort") || t2.map(function(e3) {
|
|
607
|
+
return e3.slice(0, 3);
|
|
608
|
+
})).indexOf(e2) + 1;
|
|
609
|
+
if (n2 < 1)
|
|
610
|
+
throw new Error();
|
|
611
|
+
this.month = n2 % 12 || n2;
|
|
612
|
+
}], MMMM: [i, function(e2) {
|
|
613
|
+
var t2 = h("months").indexOf(e2) + 1;
|
|
614
|
+
if (t2 < 1)
|
|
615
|
+
throw new Error();
|
|
616
|
+
this.month = t2 % 12 || t2;
|
|
617
|
+
}], Y: [/[+-]?\d+/, a("year")], YY: [n, function(e2) {
|
|
618
|
+
this.year = s(e2);
|
|
619
|
+
}], YYYY: [/\d{4}/, a("year")], Z: f, ZZ: f };
|
|
620
|
+
function c(n2) {
|
|
621
|
+
var r2, i2;
|
|
622
|
+
r2 = n2, i2 = o && o.formats;
|
|
623
|
+
for (var s2 = (n2 = r2.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, function(t2, n3, r3) {
|
|
624
|
+
var o2 = r3 && r3.toUpperCase();
|
|
625
|
+
return n3 || i2[r3] || e[r3] || i2[o2].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, function(e2, t3, n4) {
|
|
626
|
+
return t3 || n4.slice(1);
|
|
627
|
+
});
|
|
628
|
+
})).match(t), a2 = s2.length, f2 = 0; f2 < a2; f2 += 1) {
|
|
629
|
+
var h2 = s2[f2], u2 = d[h2], c2 = u2 && u2[0], l = u2 && u2[1];
|
|
630
|
+
s2[f2] = l ? { regex: c2, parser: l } : h2.replace(/^\[|\]$/g, "");
|
|
631
|
+
}
|
|
632
|
+
return function(e2) {
|
|
633
|
+
for (var t2 = {}, n3 = 0, r3 = 0; n3 < a2; n3 += 1) {
|
|
634
|
+
var i3 = s2[n3];
|
|
635
|
+
if ("string" == typeof i3)
|
|
636
|
+
r3 += i3.length;
|
|
637
|
+
else {
|
|
638
|
+
var o2 = i3.regex, f3 = i3.parser, h3 = e2.slice(r3), u3 = o2.exec(h3)[0];
|
|
639
|
+
f3.call(t2, u3), e2 = e2.replace(u3, "");
|
|
640
|
+
}
|
|
641
|
+
}
|
|
642
|
+
return function(e3) {
|
|
643
|
+
var t3 = e3.afternoon;
|
|
644
|
+
if (void 0 !== t3) {
|
|
645
|
+
var n4 = e3.hours;
|
|
646
|
+
t3 ? n4 < 12 && (e3.hours += 12) : 12 === n4 && (e3.hours = 0), delete e3.afternoon;
|
|
647
|
+
}
|
|
648
|
+
}(t2), t2;
|
|
649
|
+
};
|
|
650
|
+
}
|
|
651
|
+
return function(e2, t2, n2) {
|
|
652
|
+
n2.p.customParseFormat = true, e2 && e2.parseTwoDigitYear && (s = e2.parseTwoDigitYear);
|
|
653
|
+
var r2 = t2.prototype, i2 = r2.parse;
|
|
654
|
+
r2.parse = function(e3) {
|
|
655
|
+
var t3 = e3.date, r3 = e3.utc, s2 = e3.args;
|
|
656
|
+
this.$u = r3;
|
|
657
|
+
var a2 = s2[1];
|
|
658
|
+
if ("string" == typeof a2) {
|
|
659
|
+
var f2 = true === s2[2], h2 = true === s2[3], u2 = f2 || h2, d2 = s2[2];
|
|
660
|
+
h2 && (d2 = s2[2]), o = this.$locale(), !f2 && d2 && (o = n2.Ls[d2]), this.$d = function(e4, t4, n3) {
|
|
661
|
+
try {
|
|
662
|
+
if (["x", "X"].indexOf(t4) > -1)
|
|
663
|
+
return new Date(("X" === t4 ? 1e3 : 1) * e4);
|
|
664
|
+
var r4 = c(t4)(e4), i3 = r4.year, o2 = r4.month, s3 = r4.day, a3 = r4.hours, f3 = r4.minutes, h3 = r4.seconds, u3 = r4.milliseconds, d3 = r4.zone, l2 = /* @__PURE__ */ new Date(), m2 = s3 || (i3 || o2 ? 1 : l2.getDate()), M2 = i3 || l2.getFullYear(), Y = 0;
|
|
665
|
+
i3 && !o2 || (Y = o2 > 0 ? o2 - 1 : l2.getMonth());
|
|
666
|
+
var p = a3 || 0, v = f3 || 0, D = h3 || 0, g = u3 || 0;
|
|
667
|
+
return d3 ? new Date(Date.UTC(M2, Y, m2, p, v, D, g + 60 * d3.offset * 1e3)) : n3 ? new Date(Date.UTC(M2, Y, m2, p, v, D, g)) : new Date(M2, Y, m2, p, v, D, g);
|
|
668
|
+
} catch (e5) {
|
|
669
|
+
return /* @__PURE__ */ new Date("");
|
|
670
|
+
}
|
|
671
|
+
}(t3, a2, r3), this.init(), d2 && true !== d2 && (this.$L = this.locale(d2).$L), u2 && t3 != this.format(a2) && (this.$d = /* @__PURE__ */ new Date("")), o = {};
|
|
672
|
+
} else if (a2 instanceof Array)
|
|
673
|
+
for (var l = a2.length, m = 1; m <= l; m += 1) {
|
|
674
|
+
s2[1] = a2[m - 1];
|
|
675
|
+
var M = n2.apply(this, s2);
|
|
676
|
+
if (M.isValid()) {
|
|
677
|
+
this.$d = M.$d, this.$L = M.$L, this.init();
|
|
678
|
+
break;
|
|
679
|
+
}
|
|
680
|
+
m === l && (this.$d = /* @__PURE__ */ new Date(""));
|
|
681
|
+
}
|
|
682
|
+
else
|
|
683
|
+
i2.call(this, e3);
|
|
684
|
+
};
|
|
685
|
+
};
|
|
686
|
+
});
|
|
687
|
+
})(customParseFormat$1);
|
|
688
|
+
var customParseFormatExports = customParseFormat$1.exports;
|
|
689
|
+
const customParseFormat = /* @__PURE__ */ getDefaultExportFromCjs(customParseFormatExports);
|
|
690
|
+
var utc$1 = { exports: {} };
|
|
691
|
+
(function(module, exports) {
|
|
692
|
+
!function(t, i) {
|
|
693
|
+
module.exports = i();
|
|
694
|
+
}(commonjsGlobal, function() {
|
|
695
|
+
var t = "minute", i = /[+-]\d\d(?::?\d\d)?/g, e = /([+-]|\d\d)/g;
|
|
696
|
+
return function(s, f, n) {
|
|
697
|
+
var u = f.prototype;
|
|
698
|
+
n.utc = function(t2) {
|
|
699
|
+
var i2 = { date: t2, utc: true, args: arguments };
|
|
700
|
+
return new f(i2);
|
|
701
|
+
}, u.utc = function(i2) {
|
|
702
|
+
var e2 = n(this.toDate(), { locale: this.$L, utc: true });
|
|
703
|
+
return i2 ? e2.add(this.utcOffset(), t) : e2;
|
|
704
|
+
}, u.local = function() {
|
|
705
|
+
return n(this.toDate(), { locale: this.$L, utc: false });
|
|
706
|
+
};
|
|
707
|
+
var o = u.parse;
|
|
708
|
+
u.parse = function(t2) {
|
|
709
|
+
t2.utc && (this.$u = true), this.$utils().u(t2.$offset) || (this.$offset = t2.$offset), o.call(this, t2);
|
|
710
|
+
};
|
|
711
|
+
var r = u.init;
|
|
712
|
+
u.init = function() {
|
|
713
|
+
if (this.$u) {
|
|
714
|
+
var t2 = this.$d;
|
|
715
|
+
this.$y = t2.getUTCFullYear(), this.$M = t2.getUTCMonth(), this.$D = t2.getUTCDate(), this.$W = t2.getUTCDay(), this.$H = t2.getUTCHours(), this.$m = t2.getUTCMinutes(), this.$s = t2.getUTCSeconds(), this.$ms = t2.getUTCMilliseconds();
|
|
716
|
+
} else
|
|
717
|
+
r.call(this);
|
|
718
|
+
};
|
|
719
|
+
var a = u.utcOffset;
|
|
720
|
+
u.utcOffset = function(s2, f2) {
|
|
721
|
+
var n2 = this.$utils().u;
|
|
722
|
+
if (n2(s2))
|
|
723
|
+
return this.$u ? 0 : n2(this.$offset) ? a.call(this) : this.$offset;
|
|
724
|
+
if ("string" == typeof s2 && (s2 = function(t2) {
|
|
725
|
+
void 0 === t2 && (t2 = "");
|
|
726
|
+
var s3 = t2.match(i);
|
|
727
|
+
if (!s3)
|
|
728
|
+
return null;
|
|
729
|
+
var f3 = ("" + s3[0]).match(e) || ["-", 0, 0], n3 = f3[0], u3 = 60 * +f3[1] + +f3[2];
|
|
730
|
+
return 0 === u3 ? 0 : "+" === n3 ? u3 : -u3;
|
|
731
|
+
}(s2), null === s2))
|
|
732
|
+
return this;
|
|
733
|
+
var u2 = Math.abs(s2) <= 16 ? 60 * s2 : s2, o2 = this;
|
|
734
|
+
if (f2)
|
|
735
|
+
return o2.$offset = u2, o2.$u = 0 === s2, o2;
|
|
736
|
+
if (0 !== s2) {
|
|
737
|
+
var r2 = this.$u ? this.toDate().getTimezoneOffset() : -1 * this.utcOffset();
|
|
738
|
+
(o2 = this.local().add(u2 + r2, t)).$offset = u2, o2.$x.$localOffset = r2;
|
|
739
|
+
} else
|
|
740
|
+
o2 = this.utc();
|
|
741
|
+
return o2;
|
|
742
|
+
};
|
|
743
|
+
var h = u.format;
|
|
744
|
+
u.format = function(t2) {
|
|
745
|
+
var i2 = t2 || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
|
|
746
|
+
return h.call(this, i2);
|
|
747
|
+
}, u.valueOf = function() {
|
|
748
|
+
var t2 = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
|
|
749
|
+
return this.$d.valueOf() - 6e4 * t2;
|
|
750
|
+
}, u.isUTC = function() {
|
|
751
|
+
return !!this.$u;
|
|
752
|
+
}, u.toISOString = function() {
|
|
753
|
+
return this.toDate().toISOString();
|
|
754
|
+
}, u.toString = function() {
|
|
755
|
+
return this.toDate().toUTCString();
|
|
756
|
+
};
|
|
757
|
+
var l = u.toDate;
|
|
758
|
+
u.toDate = function(t2) {
|
|
759
|
+
return "s" === t2 && this.$offset ? n(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : l.call(this);
|
|
760
|
+
};
|
|
761
|
+
var c = u.diff;
|
|
762
|
+
u.diff = function(t2, i2, e2) {
|
|
763
|
+
if (t2 && this.$u === t2.$u)
|
|
764
|
+
return c.call(this, t2, i2, e2);
|
|
765
|
+
var s2 = this.local(), f2 = n(t2).local();
|
|
766
|
+
return c.call(s2, f2, i2, e2);
|
|
767
|
+
};
|
|
768
|
+
};
|
|
769
|
+
});
|
|
770
|
+
})(utc$1);
|
|
771
|
+
var utcExports = utc$1.exports;
|
|
772
|
+
const utc = /* @__PURE__ */ getDefaultExportFromCjs(utcExports);
|
|
773
|
+
dayjs.extend(utc);
|
|
774
|
+
dayjs.extend(updateLocale);
|
|
775
|
+
dayjs.extend(customParseFormat);
|
|
533
776
|
const FORMAT_DATE = "DD-MM-YYYY";
|
|
534
777
|
const FORMAT_DATETIME = "DD-MM-YYYY HH:mm:ss";
|
|
535
778
|
const FORMAT_YEARMONTH = "YYYY-MMMM";
|
|
@@ -840,7 +1083,7 @@ async function confirmOfLeavingForm(formOrCheckFormDirtyFunc) {
|
|
|
840
1083
|
if (formOrCheckFormDirtyFunc == null) {
|
|
841
1084
|
return true;
|
|
842
1085
|
}
|
|
843
|
-
let formDirty
|
|
1086
|
+
let formDirty;
|
|
844
1087
|
if (typeof formOrCheckFormDirtyFunc === "function") {
|
|
845
1088
|
formDirty = await formOrCheckFormDirtyFunc();
|
|
846
1089
|
} else {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
(function(
|
|
2
|
-
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("lodash"), require("js-base64"), require("dayjs")) : typeof define === "function" && define.amd ? define(["exports", "lodash", "js-base64", "dayjs"], factory) : (
|
|
1
|
+
(function(global2, factory) {
|
|
2
|
+
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("lodash"), require("js-base64"), require("dayjs")) : typeof define === "function" && define.amd ? define(["exports", "lodash", "js-base64", "dayjs"], factory) : (global2 = typeof globalThis !== "undefined" ? globalThis : global2 || self, factory(global2["sirius-common-utils"] = {}, global2._$1, global2.jsBase64, global2.dayjs));
|
|
3
3
|
})(this, function(exports2, _$1, jsBase64, dayjs) {
|
|
4
4
|
"use strict";
|
|
5
5
|
const CfgUtils = {
|
|
@@ -531,6 +531,249 @@
|
|
|
531
531
|
getErrorMsgByCode,
|
|
532
532
|
RESULT
|
|
533
533
|
};
|
|
534
|
+
var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
|
|
535
|
+
function getDefaultExportFromCjs(x) {
|
|
536
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, "default") ? x["default"] : x;
|
|
537
|
+
}
|
|
538
|
+
var updateLocale$1 = { exports: {} };
|
|
539
|
+
(function(module2, exports3) {
|
|
540
|
+
!function(e, n) {
|
|
541
|
+
module2.exports = n();
|
|
542
|
+
}(commonjsGlobal, function() {
|
|
543
|
+
return function(e, n, t) {
|
|
544
|
+
t.updateLocale = function(e2, n2) {
|
|
545
|
+
var o = t.Ls[e2];
|
|
546
|
+
if (o)
|
|
547
|
+
return (n2 ? Object.keys(n2) : []).forEach(function(e3) {
|
|
548
|
+
o[e3] = n2[e3];
|
|
549
|
+
}), o;
|
|
550
|
+
};
|
|
551
|
+
};
|
|
552
|
+
});
|
|
553
|
+
})(updateLocale$1);
|
|
554
|
+
var updateLocaleExports = updateLocale$1.exports;
|
|
555
|
+
const updateLocale = /* @__PURE__ */ getDefaultExportFromCjs(updateLocaleExports);
|
|
556
|
+
var customParseFormat$1 = { exports: {} };
|
|
557
|
+
(function(module2, exports3) {
|
|
558
|
+
!function(e, t) {
|
|
559
|
+
module2.exports = t();
|
|
560
|
+
}(commonjsGlobal, function() {
|
|
561
|
+
var e = { LTS: "h:mm:ss A", LT: "h:mm A", L: "MM/DD/YYYY", LL: "MMMM D, YYYY", LLL: "MMMM D, YYYY h:mm A", LLLL: "dddd, MMMM D, YYYY h:mm A" }, t = /(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g, n = /\d\d/, r = /\d\d?/, i = /\d*[^-_:/,()\s\d]+/, o = {}, s = function(e2) {
|
|
562
|
+
return (e2 = +e2) + (e2 > 68 ? 1900 : 2e3);
|
|
563
|
+
};
|
|
564
|
+
var a = function(e2) {
|
|
565
|
+
return function(t2) {
|
|
566
|
+
this[e2] = +t2;
|
|
567
|
+
};
|
|
568
|
+
}, f = [/[+-]\d\d:?(\d\d)?|Z/, function(e2) {
|
|
569
|
+
(this.zone || (this.zone = {})).offset = function(e3) {
|
|
570
|
+
if (!e3)
|
|
571
|
+
return 0;
|
|
572
|
+
if ("Z" === e3)
|
|
573
|
+
return 0;
|
|
574
|
+
var t2 = e3.match(/([+-]|\d\d)/g), n2 = 60 * t2[1] + (+t2[2] || 0);
|
|
575
|
+
return 0 === n2 ? 0 : "+" === t2[0] ? -n2 : n2;
|
|
576
|
+
}(e2);
|
|
577
|
+
}], h = function(e2) {
|
|
578
|
+
var t2 = o[e2];
|
|
579
|
+
return t2 && (t2.indexOf ? t2 : t2.s.concat(t2.f));
|
|
580
|
+
}, u = function(e2, t2) {
|
|
581
|
+
var n2, r2 = o.meridiem;
|
|
582
|
+
if (r2) {
|
|
583
|
+
for (var i2 = 1; i2 <= 24; i2 += 1)
|
|
584
|
+
if (e2.indexOf(r2(i2, 0, t2)) > -1) {
|
|
585
|
+
n2 = i2 > 12;
|
|
586
|
+
break;
|
|
587
|
+
}
|
|
588
|
+
} else
|
|
589
|
+
n2 = e2 === (t2 ? "pm" : "PM");
|
|
590
|
+
return n2;
|
|
591
|
+
}, d = { A: [i, function(e2) {
|
|
592
|
+
this.afternoon = u(e2, false);
|
|
593
|
+
}], a: [i, function(e2) {
|
|
594
|
+
this.afternoon = u(e2, true);
|
|
595
|
+
}], S: [/\d/, function(e2) {
|
|
596
|
+
this.milliseconds = 100 * +e2;
|
|
597
|
+
}], SS: [n, function(e2) {
|
|
598
|
+
this.milliseconds = 10 * +e2;
|
|
599
|
+
}], SSS: [/\d{3}/, function(e2) {
|
|
600
|
+
this.milliseconds = +e2;
|
|
601
|
+
}], s: [r, a("seconds")], ss: [r, a("seconds")], m: [r, a("minutes")], mm: [r, a("minutes")], H: [r, a("hours")], h: [r, a("hours")], HH: [r, a("hours")], hh: [r, a("hours")], D: [r, a("day")], DD: [n, a("day")], Do: [i, function(e2) {
|
|
602
|
+
var t2 = o.ordinal, n2 = e2.match(/\d+/);
|
|
603
|
+
if (this.day = n2[0], t2)
|
|
604
|
+
for (var r2 = 1; r2 <= 31; r2 += 1)
|
|
605
|
+
t2(r2).replace(/\[|\]/g, "") === e2 && (this.day = r2);
|
|
606
|
+
}], M: [r, a("month")], MM: [n, a("month")], MMM: [i, function(e2) {
|
|
607
|
+
var t2 = h("months"), n2 = (h("monthsShort") || t2.map(function(e3) {
|
|
608
|
+
return e3.slice(0, 3);
|
|
609
|
+
})).indexOf(e2) + 1;
|
|
610
|
+
if (n2 < 1)
|
|
611
|
+
throw new Error();
|
|
612
|
+
this.month = n2 % 12 || n2;
|
|
613
|
+
}], MMMM: [i, function(e2) {
|
|
614
|
+
var t2 = h("months").indexOf(e2) + 1;
|
|
615
|
+
if (t2 < 1)
|
|
616
|
+
throw new Error();
|
|
617
|
+
this.month = t2 % 12 || t2;
|
|
618
|
+
}], Y: [/[+-]?\d+/, a("year")], YY: [n, function(e2) {
|
|
619
|
+
this.year = s(e2);
|
|
620
|
+
}], YYYY: [/\d{4}/, a("year")], Z: f, ZZ: f };
|
|
621
|
+
function c(n2) {
|
|
622
|
+
var r2, i2;
|
|
623
|
+
r2 = n2, i2 = o && o.formats;
|
|
624
|
+
for (var s2 = (n2 = r2.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g, function(t2, n3, r3) {
|
|
625
|
+
var o2 = r3 && r3.toUpperCase();
|
|
626
|
+
return n3 || i2[r3] || e[r3] || i2[o2].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g, function(e2, t3, n4) {
|
|
627
|
+
return t3 || n4.slice(1);
|
|
628
|
+
});
|
|
629
|
+
})).match(t), a2 = s2.length, f2 = 0; f2 < a2; f2 += 1) {
|
|
630
|
+
var h2 = s2[f2], u2 = d[h2], c2 = u2 && u2[0], l = u2 && u2[1];
|
|
631
|
+
s2[f2] = l ? { regex: c2, parser: l } : h2.replace(/^\[|\]$/g, "");
|
|
632
|
+
}
|
|
633
|
+
return function(e2) {
|
|
634
|
+
for (var t2 = {}, n3 = 0, r3 = 0; n3 < a2; n3 += 1) {
|
|
635
|
+
var i3 = s2[n3];
|
|
636
|
+
if ("string" == typeof i3)
|
|
637
|
+
r3 += i3.length;
|
|
638
|
+
else {
|
|
639
|
+
var o2 = i3.regex, f3 = i3.parser, h3 = e2.slice(r3), u3 = o2.exec(h3)[0];
|
|
640
|
+
f3.call(t2, u3), e2 = e2.replace(u3, "");
|
|
641
|
+
}
|
|
642
|
+
}
|
|
643
|
+
return function(e3) {
|
|
644
|
+
var t3 = e3.afternoon;
|
|
645
|
+
if (void 0 !== t3) {
|
|
646
|
+
var n4 = e3.hours;
|
|
647
|
+
t3 ? n4 < 12 && (e3.hours += 12) : 12 === n4 && (e3.hours = 0), delete e3.afternoon;
|
|
648
|
+
}
|
|
649
|
+
}(t2), t2;
|
|
650
|
+
};
|
|
651
|
+
}
|
|
652
|
+
return function(e2, t2, n2) {
|
|
653
|
+
n2.p.customParseFormat = true, e2 && e2.parseTwoDigitYear && (s = e2.parseTwoDigitYear);
|
|
654
|
+
var r2 = t2.prototype, i2 = r2.parse;
|
|
655
|
+
r2.parse = function(e3) {
|
|
656
|
+
var t3 = e3.date, r3 = e3.utc, s2 = e3.args;
|
|
657
|
+
this.$u = r3;
|
|
658
|
+
var a2 = s2[1];
|
|
659
|
+
if ("string" == typeof a2) {
|
|
660
|
+
var f2 = true === s2[2], h2 = true === s2[3], u2 = f2 || h2, d2 = s2[2];
|
|
661
|
+
h2 && (d2 = s2[2]), o = this.$locale(), !f2 && d2 && (o = n2.Ls[d2]), this.$d = function(e4, t4, n3) {
|
|
662
|
+
try {
|
|
663
|
+
if (["x", "X"].indexOf(t4) > -1)
|
|
664
|
+
return new Date(("X" === t4 ? 1e3 : 1) * e4);
|
|
665
|
+
var r4 = c(t4)(e4), i3 = r4.year, o2 = r4.month, s3 = r4.day, a3 = r4.hours, f3 = r4.minutes, h3 = r4.seconds, u3 = r4.milliseconds, d3 = r4.zone, l2 = /* @__PURE__ */ new Date(), m2 = s3 || (i3 || o2 ? 1 : l2.getDate()), M2 = i3 || l2.getFullYear(), Y = 0;
|
|
666
|
+
i3 && !o2 || (Y = o2 > 0 ? o2 - 1 : l2.getMonth());
|
|
667
|
+
var p = a3 || 0, v = f3 || 0, D = h3 || 0, g = u3 || 0;
|
|
668
|
+
return d3 ? new Date(Date.UTC(M2, Y, m2, p, v, D, g + 60 * d3.offset * 1e3)) : n3 ? new Date(Date.UTC(M2, Y, m2, p, v, D, g)) : new Date(M2, Y, m2, p, v, D, g);
|
|
669
|
+
} catch (e5) {
|
|
670
|
+
return /* @__PURE__ */ new Date("");
|
|
671
|
+
}
|
|
672
|
+
}(t3, a2, r3), this.init(), d2 && true !== d2 && (this.$L = this.locale(d2).$L), u2 && t3 != this.format(a2) && (this.$d = /* @__PURE__ */ new Date("")), o = {};
|
|
673
|
+
} else if (a2 instanceof Array)
|
|
674
|
+
for (var l = a2.length, m = 1; m <= l; m += 1) {
|
|
675
|
+
s2[1] = a2[m - 1];
|
|
676
|
+
var M = n2.apply(this, s2);
|
|
677
|
+
if (M.isValid()) {
|
|
678
|
+
this.$d = M.$d, this.$L = M.$L, this.init();
|
|
679
|
+
break;
|
|
680
|
+
}
|
|
681
|
+
m === l && (this.$d = /* @__PURE__ */ new Date(""));
|
|
682
|
+
}
|
|
683
|
+
else
|
|
684
|
+
i2.call(this, e3);
|
|
685
|
+
};
|
|
686
|
+
};
|
|
687
|
+
});
|
|
688
|
+
})(customParseFormat$1);
|
|
689
|
+
var customParseFormatExports = customParseFormat$1.exports;
|
|
690
|
+
const customParseFormat = /* @__PURE__ */ getDefaultExportFromCjs(customParseFormatExports);
|
|
691
|
+
var utc$1 = { exports: {} };
|
|
692
|
+
(function(module2, exports3) {
|
|
693
|
+
!function(t, i) {
|
|
694
|
+
module2.exports = i();
|
|
695
|
+
}(commonjsGlobal, function() {
|
|
696
|
+
var t = "minute", i = /[+-]\d\d(?::?\d\d)?/g, e = /([+-]|\d\d)/g;
|
|
697
|
+
return function(s, f, n) {
|
|
698
|
+
var u = f.prototype;
|
|
699
|
+
n.utc = function(t2) {
|
|
700
|
+
var i2 = { date: t2, utc: true, args: arguments };
|
|
701
|
+
return new f(i2);
|
|
702
|
+
}, u.utc = function(i2) {
|
|
703
|
+
var e2 = n(this.toDate(), { locale: this.$L, utc: true });
|
|
704
|
+
return i2 ? e2.add(this.utcOffset(), t) : e2;
|
|
705
|
+
}, u.local = function() {
|
|
706
|
+
return n(this.toDate(), { locale: this.$L, utc: false });
|
|
707
|
+
};
|
|
708
|
+
var o = u.parse;
|
|
709
|
+
u.parse = function(t2) {
|
|
710
|
+
t2.utc && (this.$u = true), this.$utils().u(t2.$offset) || (this.$offset = t2.$offset), o.call(this, t2);
|
|
711
|
+
};
|
|
712
|
+
var r = u.init;
|
|
713
|
+
u.init = function() {
|
|
714
|
+
if (this.$u) {
|
|
715
|
+
var t2 = this.$d;
|
|
716
|
+
this.$y = t2.getUTCFullYear(), this.$M = t2.getUTCMonth(), this.$D = t2.getUTCDate(), this.$W = t2.getUTCDay(), this.$H = t2.getUTCHours(), this.$m = t2.getUTCMinutes(), this.$s = t2.getUTCSeconds(), this.$ms = t2.getUTCMilliseconds();
|
|
717
|
+
} else
|
|
718
|
+
r.call(this);
|
|
719
|
+
};
|
|
720
|
+
var a = u.utcOffset;
|
|
721
|
+
u.utcOffset = function(s2, f2) {
|
|
722
|
+
var n2 = this.$utils().u;
|
|
723
|
+
if (n2(s2))
|
|
724
|
+
return this.$u ? 0 : n2(this.$offset) ? a.call(this) : this.$offset;
|
|
725
|
+
if ("string" == typeof s2 && (s2 = function(t2) {
|
|
726
|
+
void 0 === t2 && (t2 = "");
|
|
727
|
+
var s3 = t2.match(i);
|
|
728
|
+
if (!s3)
|
|
729
|
+
return null;
|
|
730
|
+
var f3 = ("" + s3[0]).match(e) || ["-", 0, 0], n3 = f3[0], u3 = 60 * +f3[1] + +f3[2];
|
|
731
|
+
return 0 === u3 ? 0 : "+" === n3 ? u3 : -u3;
|
|
732
|
+
}(s2), null === s2))
|
|
733
|
+
return this;
|
|
734
|
+
var u2 = Math.abs(s2) <= 16 ? 60 * s2 : s2, o2 = this;
|
|
735
|
+
if (f2)
|
|
736
|
+
return o2.$offset = u2, o2.$u = 0 === s2, o2;
|
|
737
|
+
if (0 !== s2) {
|
|
738
|
+
var r2 = this.$u ? this.toDate().getTimezoneOffset() : -1 * this.utcOffset();
|
|
739
|
+
(o2 = this.local().add(u2 + r2, t)).$offset = u2, o2.$x.$localOffset = r2;
|
|
740
|
+
} else
|
|
741
|
+
o2 = this.utc();
|
|
742
|
+
return o2;
|
|
743
|
+
};
|
|
744
|
+
var h = u.format;
|
|
745
|
+
u.format = function(t2) {
|
|
746
|
+
var i2 = t2 || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
|
|
747
|
+
return h.call(this, i2);
|
|
748
|
+
}, u.valueOf = function() {
|
|
749
|
+
var t2 = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
|
|
750
|
+
return this.$d.valueOf() - 6e4 * t2;
|
|
751
|
+
}, u.isUTC = function() {
|
|
752
|
+
return !!this.$u;
|
|
753
|
+
}, u.toISOString = function() {
|
|
754
|
+
return this.toDate().toISOString();
|
|
755
|
+
}, u.toString = function() {
|
|
756
|
+
return this.toDate().toUTCString();
|
|
757
|
+
};
|
|
758
|
+
var l = u.toDate;
|
|
759
|
+
u.toDate = function(t2) {
|
|
760
|
+
return "s" === t2 && this.$offset ? n(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : l.call(this);
|
|
761
|
+
};
|
|
762
|
+
var c = u.diff;
|
|
763
|
+
u.diff = function(t2, i2, e2) {
|
|
764
|
+
if (t2 && this.$u === t2.$u)
|
|
765
|
+
return c.call(this, t2, i2, e2);
|
|
766
|
+
var s2 = this.local(), f2 = n(t2).local();
|
|
767
|
+
return c.call(s2, f2, i2, e2);
|
|
768
|
+
};
|
|
769
|
+
};
|
|
770
|
+
});
|
|
771
|
+
})(utc$1);
|
|
772
|
+
var utcExports = utc$1.exports;
|
|
773
|
+
const utc = /* @__PURE__ */ getDefaultExportFromCjs(utcExports);
|
|
774
|
+
dayjs.extend(utc);
|
|
775
|
+
dayjs.extend(updateLocale);
|
|
776
|
+
dayjs.extend(customParseFormat);
|
|
534
777
|
const FORMAT_DATE = "DD-MM-YYYY";
|
|
535
778
|
const FORMAT_DATETIME = "DD-MM-YYYY HH:mm:ss";
|
|
536
779
|
const FORMAT_YEARMONTH = "YYYY-MMMM";
|
|
@@ -841,7 +1084,7 @@
|
|
|
841
1084
|
if (formOrCheckFormDirtyFunc == null) {
|
|
842
1085
|
return true;
|
|
843
1086
|
}
|
|
844
|
-
let formDirty
|
|
1087
|
+
let formDirty;
|
|
845
1088
|
if (typeof formOrCheckFormDirtyFunc === "function") {
|
|
846
1089
|
formDirty = await formOrCheckFormDirtyFunc();
|
|
847
1090
|
} else {
|