ps-toolkit-ui 1.5.3 → 1.5.6
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 +12 -4
- 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/classes/enum.class.js +2 -1
- package/esm2015/lib/components/form/plaque/form.plaque.component.js +9 -5
- package/esm2015/lib/components/table/row/table.row.component.js +4 -1
- package/fesm2015/ps-toolkit-ui.js +12 -4
- package/fesm2015/ps-toolkit-ui.js.map +1 -1
- package/lib/classes/enum.class.d.ts +2 -1
- package/package.json +1 -1
- package/ps-toolkit-ui.metadata.json +1 -1
|
@@ -804,6 +804,7 @@
|
|
|
804
804
|
TableCollType[TableCollType["Bool"] = 13] = "Bool";
|
|
805
805
|
TableCollType[TableCollType["Options"] = 14] = "Options";
|
|
806
806
|
TableCollType[TableCollType["Color"] = 15] = "Color";
|
|
807
|
+
TableCollType[TableCollType["Number"] = 16] = "Number";
|
|
807
808
|
})(exports.TableCollType || (exports.TableCollType = {}));
|
|
808
809
|
(function (UserType) {
|
|
809
810
|
UserType[UserType["All"] = 0] = "All";
|
|
@@ -2861,6 +2862,9 @@
|
|
|
2861
2862
|
else if (col.type === exports.TableCollType.Price) {
|
|
2862
2863
|
return cv.toLocaleString() + ' ' + this.table.l('Rial');
|
|
2863
2864
|
}
|
|
2865
|
+
else if (col.type === exports.TableCollType.Number) {
|
|
2866
|
+
return cv.toLocaleString();
|
|
2867
|
+
}
|
|
2864
2868
|
else if (col.type === exports.TableCollType.Plaque) {
|
|
2865
2869
|
var parts = cv.split('_');
|
|
2866
2870
|
if (parts.length === 4) {
|
|
@@ -4841,10 +4845,14 @@
|
|
|
4841
4845
|
}
|
|
4842
4846
|
};
|
|
4843
4847
|
this.inp.isValid = function () {
|
|
4844
|
-
|
|
4845
|
-
|
|
4848
|
+
_this.inp.value = _this.getValue();
|
|
4849
|
+
if (_this.inp.required && !_this.inp.value) {
|
|
4850
|
+
_this.inp.error = exports.InputError.Required;
|
|
4846
4851
|
return false;
|
|
4847
4852
|
}
|
|
4853
|
+
if (!_this.inp.required && !_this.inp.value) {
|
|
4854
|
+
return true;
|
|
4855
|
+
}
|
|
4848
4856
|
return true;
|
|
4849
4857
|
};
|
|
4850
4858
|
this.inp.clear = function () {
|
|
@@ -4861,11 +4869,11 @@
|
|
|
4861
4869
|
};
|
|
4862
4870
|
};
|
|
4863
4871
|
FormPlaqueComponent.prototype.isValid = function () {
|
|
4864
|
-
if (this.inp.
|
|
4872
|
+
if (this.inp.type === exports.InputType.Plaque &&
|
|
4865
4873
|
(!this.part1.isValid() || !this.part2.isValid() || !this.part3.isValid() || !this.part4.isValid())) {
|
|
4866
4874
|
return false;
|
|
4867
4875
|
}
|
|
4868
|
-
return !(
|
|
4876
|
+
return !((this.inp.type === exports.InputType.PlaqueM || this.inp.type === exports.InputType.PlaqueF) && (!this.part1.isValid() || !this.part3.isValid()));
|
|
4869
4877
|
};
|
|
4870
4878
|
FormPlaqueComponent.prototype.changeFocus = function (p, a) {
|
|
4871
4879
|
if (this.inp.type === exports.InputType.Plaque) {
|