mmhglobal-dynamicform 1.1.31 → 1.1.32
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/README.md +7 -0
- package/bundles/mmhglobal-dynamicform.umd.js +45 -6
- package/bundles/mmhglobal-dynamicform.umd.js.map +1 -1
- package/bundles/mmhglobal-dynamicform.umd.min.js +1 -1
- package/bundles/mmhglobal-dynamicform.umd.min.js.map +1 -1
- package/esm2015/lib/zgrid/zgrid.component.js +20 -2
- package/esm2015/lib/zquerybuilder/zquerybuilder.component.js +23 -5
- package/esm2015/lib/zupload/zupload.component.js +3 -1
- package/fesm2015/mmhglobal-dynamicform.js +45 -7
- package/fesm2015/mmhglobal-dynamicform.js.map +1 -1
- package/lib/zgrid/zgrid.component.d.ts +2 -0
- package/lib/zquerybuilder/zquerybuilder.component.d.ts +9 -0
- package/mmhglobal-dynamicform.metadata.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -3,6 +3,13 @@
|
|
|
3
3
|
This library was generated with [Angular CLI](https://github.com/angular/angular-cli) version 11.2.13.
|
|
4
4
|
|
|
5
5
|
## Changelog
|
|
6
|
+
`1.32`<br/>
|
|
7
|
+
[zgrid] - added getFormControlData function to retrieve incell data. <br/>
|
|
8
|
+
[zgrid] - added AfterloadCallback attribute handling. <br/>
|
|
9
|
+
[zgrid] - fix form control error when grid data is null. <br/>
|
|
10
|
+
[zupload] - save file data to group scope. <br/>
|
|
11
|
+
[zquerybuilder] - bug fix for query builder.
|
|
12
|
+
|
|
6
13
|
`1.31`<br/>
|
|
7
14
|
update dynamicform module for zuploadmodule. <br/>
|
|
8
15
|
|
|
@@ -5537,7 +5537,9 @@
|
|
|
5537
5537
|
});
|
|
5538
5538
|
}
|
|
5539
5539
|
}
|
|
5540
|
-
_this.
|
|
5540
|
+
if (_this.gData) {
|
|
5541
|
+
_this.createFormControls();
|
|
5542
|
+
}
|
|
5541
5543
|
};
|
|
5542
5544
|
/* Available Functions */
|
|
5543
5545
|
this.setEnable = function (status) {
|
|
@@ -5628,6 +5630,9 @@
|
|
|
5628
5630
|
_this.setGridSessionKey(_this.group);
|
|
5629
5631
|
}
|
|
5630
5632
|
return rxjs.of(true);
|
|
5633
|
+
}), operators.tap(function () {
|
|
5634
|
+
_this.gridCallback(_this.group);
|
|
5635
|
+
return rxjs.of(true);
|
|
5631
5636
|
})).subscribe();
|
|
5632
5637
|
};
|
|
5633
5638
|
ZgridComponent.prototype.ngOnDestroy = function () {
|
|
@@ -5769,6 +5774,16 @@
|
|
|
5769
5774
|
});
|
|
5770
5775
|
}
|
|
5771
5776
|
};
|
|
5777
|
+
ZgridComponent.prototype.gridCallback = function (group) {
|
|
5778
|
+
if (this.data['AfterloadCallback']) {
|
|
5779
|
+
var me = Object.assign({}, this);
|
|
5780
|
+
this.group.subject.next({
|
|
5781
|
+
type: "zgrid-AfterloadCallback",
|
|
5782
|
+
target: this.data['AfterloadCallback'],
|
|
5783
|
+
data: me
|
|
5784
|
+
});
|
|
5785
|
+
}
|
|
5786
|
+
};
|
|
5772
5787
|
ZgridComponent.prototype.getData = function () {
|
|
5773
5788
|
if (this.zgrid) {
|
|
5774
5789
|
this.zgrid.getDataBinding();
|
|
@@ -6074,6 +6089,9 @@
|
|
|
6074
6089
|
var formArray = this.inlineEditedFormGroups.get('items');
|
|
6075
6090
|
return formArray.at(rowIndex);
|
|
6076
6091
|
};
|
|
6092
|
+
ZgridComponent.prototype.getFormControlData = function (value) {
|
|
6093
|
+
return this.inlineEditedFormGroups.value.items;
|
|
6094
|
+
};
|
|
6077
6095
|
/* Event */
|
|
6078
6096
|
ZgridComponent.prototype.beforeGridGetData = function (group, me) {
|
|
6079
6097
|
console.warn("beforeDataBinding triggered");
|
|
@@ -8125,10 +8143,12 @@
|
|
|
8125
8143
|
return this.qbItems[rule.field].options ? this.qbItems[rule.field].options : optionsList;
|
|
8126
8144
|
};
|
|
8127
8145
|
ZquerybuilderComponent.prototype.setQueryValue = function (queryValueString) {
|
|
8128
|
-
|
|
8129
|
-
|
|
8130
|
-
|
|
8131
|
-
|
|
8146
|
+
if (queryValueString) {
|
|
8147
|
+
var defaultQueryValueJson = toQueryRule(JSON.parse(queryValueString));
|
|
8148
|
+
this.queryCtrl = defaultQueryValueJson;
|
|
8149
|
+
// default lock the query builder if there default query
|
|
8150
|
+
this.completeRule(true, defaultQueryValueJson);
|
|
8151
|
+
}
|
|
8132
8152
|
};
|
|
8133
8153
|
return ZquerybuilderComponent;
|
|
8134
8154
|
}());
|
|
@@ -8150,7 +8170,23 @@
|
|
|
8150
8170
|
data: [{ type: i0.Input }],
|
|
8151
8171
|
group: [{ type: i0.Input }],
|
|
8152
8172
|
form: [{ type: i0.Input }]
|
|
8153
|
-
};
|
|
8173
|
+
};
|
|
8174
|
+
function toQueryRule(queryBuilderModel) {
|
|
8175
|
+
var rule = {};
|
|
8176
|
+
if (queryBuilderModel.condition) {
|
|
8177
|
+
rule.condition = queryBuilderModel.condition;
|
|
8178
|
+
rule.rules = queryBuilderModel.rules.map(function (q) { return toQueryRule(q); });
|
|
8179
|
+
}
|
|
8180
|
+
else {
|
|
8181
|
+
rule.field = queryBuilderModel.field;
|
|
8182
|
+
rule.type = queryBuilderModel.type;
|
|
8183
|
+
rule.operator = queryBuilderModel.operator;
|
|
8184
|
+
rule.value = queryBuilderModel.value instanceof Array
|
|
8185
|
+
? queryBuilderModel.type === 'date' ? new Date(queryBuilderModel.value) : queryBuilderModel.value
|
|
8186
|
+
: [queryBuilderModel.type === 'date' ? new Date(queryBuilderModel.value) : queryBuilderModel.value];
|
|
8187
|
+
}
|
|
8188
|
+
return rule;
|
|
8189
|
+
}
|
|
8154
8190
|
|
|
8155
8191
|
/********** Angular **********/
|
|
8156
8192
|
var ZreportComponent = /** @class */ (function () {
|
|
@@ -10944,6 +10980,8 @@
|
|
|
10944
10980
|
} // file type check
|
|
10945
10981
|
}); // loop each file
|
|
10946
10982
|
} // imagecompression check
|
|
10983
|
+
// add to group scope
|
|
10984
|
+
me.group['zupload_' + me.data.Value] = e.files;
|
|
10947
10985
|
}
|
|
10948
10986
|
}
|
|
10949
10987
|
};
|
|
@@ -11646,6 +11684,7 @@
|
|
|
11646
11684
|
exports.ZuploadComponent = ZuploadComponent;
|
|
11647
11685
|
exports.ZworkflowbuttonsComponent = ZworkflowbuttonsComponent;
|
|
11648
11686
|
exports.refreshGrid = refreshGrid;
|
|
11687
|
+
exports.toQueryRule = toQueryRule;
|
|
11649
11688
|
exports.ɵa = ZComponentDebugService;
|
|
11650
11689
|
exports.ɵb = ZGridCalendarBindingDirective;
|
|
11651
11690
|
exports.ɵc = ZComponentService;
|