@magic-xpa/gui 4.1000.0-dev4100.419 → 4.1000.0-dev4100.420
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.
|
@@ -5649,37 +5649,7 @@ class DisplayConvertor {
|
|
|
5649
5649
|
breakParams.month = breakParams.month - 1;
|
|
5650
5650
|
if (breakParams.year == 0 && breakParams.month == 0 && breakParams.day == 0)
|
|
5651
5651
|
return null;
|
|
5652
|
-
|
|
5653
|
-
let outVal = NString.ToCharArray(maskStr);
|
|
5654
|
-
let len = pic.getMaskSize();
|
|
5655
|
-
let year = breakParams.year;
|
|
5656
|
-
let outIdx = 0;
|
|
5657
|
-
while (len > 0) {
|
|
5658
|
-
switch (outVal[outIdx].charCodeAt(0)) {
|
|
5659
|
-
case PICInterface.PIC_YY:
|
|
5660
|
-
{
|
|
5661
|
-
this.int_2_a(outVal, outIdx, 2, breakParams.year, '0');
|
|
5662
|
-
let yearStr = NString.FromChars(outVal, outIdx, 2);
|
|
5663
|
-
year = +yearStr;
|
|
5664
|
-
outIdx += 2;
|
|
5665
|
-
len -= 2;
|
|
5666
|
-
}
|
|
5667
|
-
break;
|
|
5668
|
-
case PICInterface.PIC_YYYY:
|
|
5669
|
-
this.int_2_a(outVal, outIdx, 4, breakParams.year, '0');
|
|
5670
|
-
let yearStr = NString.FromChars(outVal, outIdx, 4);
|
|
5671
|
-
year = +yearStr;
|
|
5672
|
-
outIdx += 4;
|
|
5673
|
-
len -= 4;
|
|
5674
|
-
break;
|
|
5675
|
-
default:
|
|
5676
|
-
outIdx++;
|
|
5677
|
-
len--;
|
|
5678
|
-
break;
|
|
5679
|
-
}
|
|
5680
|
-
}
|
|
5681
|
-
let nativeDt = new Date(year, breakParams.month, breakParams.day);
|
|
5682
|
-
return nativeDt;
|
|
5652
|
+
return new Date(breakParams.year, breakParams.month, breakParams.day);
|
|
5683
5653
|
}
|
|
5684
5654
|
fromNativeDateToMgDateNumber(nativeDate, pic) {
|
|
5685
5655
|
let numVal;
|