ps-toolkit-ui 0.0.66 → 0.0.70
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/bundles/ps-toolkit-ui.umd.js +22 -15
- package/bundles/ps-toolkit-ui.umd.js.map +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js +1 -1
- package/bundles/ps-toolkit-ui.umd.min.js.map +1 -1
- package/esm2015/lib/components/form/date/form.date.component.js +23 -16
- package/fesm2015/ps-toolkit-ui.js +22 -15
- package/fesm2015/ps-toolkit-ui.js.map +1 -1
- package/lib/components/form/date/form.date.component.d.ts +1 -0
- package/package.json +1 -1
- package/ps-toolkit-ui.metadata.json +1 -1
|
@@ -3245,22 +3245,9 @@
|
|
|
3245
3245
|
else {
|
|
3246
3246
|
this.active = moment__namespace();
|
|
3247
3247
|
}
|
|
3248
|
-
this.
|
|
3248
|
+
this.setInpValue(this.inp.value);
|
|
3249
3249
|
this.inp.setValue = function (v) {
|
|
3250
|
-
|
|
3251
|
-
_this.inp.clear();
|
|
3252
|
-
return;
|
|
3253
|
-
}
|
|
3254
|
-
else if (typeof v === 'string') {
|
|
3255
|
-
var d = parseInt(v.substring(6, v.length - 2), 10);
|
|
3256
|
-
_this.active = moment__namespace(d);
|
|
3257
|
-
}
|
|
3258
|
-
else {
|
|
3259
|
-
_this.active = moment__namespace(v);
|
|
3260
|
-
}
|
|
3261
|
-
_this.inp.value = _this.active.format('jYYYY/jMM/jDD');
|
|
3262
|
-
_this.inp.search = _this.active.format('jYYYY/jMM/jDD');
|
|
3263
|
-
_this.setDate();
|
|
3250
|
+
_this.setInpValue(v);
|
|
3264
3251
|
};
|
|
3265
3252
|
this.inp.isValid = function () {
|
|
3266
3253
|
_this.inp.error = null;
|
|
@@ -3296,6 +3283,26 @@
|
|
|
3296
3283
|
$__namespace(_this.inputBase.nativeElement).blur();
|
|
3297
3284
|
};
|
|
3298
3285
|
};
|
|
3286
|
+
FormDateComponent.prototype.setInpValue = function (v) {
|
|
3287
|
+
console.log(typeof v, 'typeof vtypeof vtypeof vtypeof v');
|
|
3288
|
+
if (v === null) {
|
|
3289
|
+
this.inp.clear();
|
|
3290
|
+
return;
|
|
3291
|
+
}
|
|
3292
|
+
else if (typeof v === 'string') {
|
|
3293
|
+
var d = parseInt(v.substring(6, v.length - 2), 10);
|
|
3294
|
+
this.active = moment__namespace(d);
|
|
3295
|
+
}
|
|
3296
|
+
else if (typeof v === 'number') {
|
|
3297
|
+
this.active = moment__namespace(v);
|
|
3298
|
+
}
|
|
3299
|
+
else {
|
|
3300
|
+
this.active = v;
|
|
3301
|
+
}
|
|
3302
|
+
this.inp.value = this.active.format('jYYYY/jMM/jDD');
|
|
3303
|
+
this.inp.search = this.active.format('jYYYY/jMM/jDD');
|
|
3304
|
+
this.setDate();
|
|
3305
|
+
};
|
|
3299
3306
|
FormDateComponent.prototype.setDate = function () {
|
|
3300
3307
|
var n = this.active.clone();
|
|
3301
3308
|
var countDayInMonth = n.daysInMonth();
|