@michalrakus/x-react-web-lib 1.37.2 → 1.37.3

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.
@@ -13,6 +13,9 @@ export interface XAutoCompleteProps extends XFormComponentProps<XObject> {
13
13
  searchBrowse?: JSX.Element;
14
14
  assocForm?: JSX.Element;
15
15
  dropdownButtonEnabled?: boolean;
16
+ insertButtonTooltip?: string;
17
+ updateButtonTooltip?: string;
18
+ searchButtonTooltip?: string;
16
19
  suggestions?: any[];
17
20
  suggestionsLoad?: XSuggestionsLoadProp;
18
21
  lazyLoadMaxRows?: number;
@@ -70,7 +70,7 @@ var XAutoComplete = /** @class */ (function (_super) {
70
70
  // div className="col" nam zabezpeci aby XAutoCompleteBase nezaberal celu dlzku grid-u (ma nastaveny width=100% vdaka "formgroup-inline")
71
71
  return (react_1.default.createElement("div", { className: "field grid" },
72
72
  react_1.default.createElement("label", { htmlFor: this.props.assocField, className: "col-fixed", style: this.getLabelStyle() }, this.getLabel()),
73
- react_1.default.createElement(XAutoCompleteBase_1.XAutoCompleteBase, { value: this.getValue(), onChange: this.onChangeAutoCompleteBase, field: this.props.displayField, itemTemplate: this.props.itemTemplate, searchBrowse: this.props.searchBrowse, valueForm: this.props.assocForm, dropdownButtonEnabled: this.props.dropdownButtonEnabled, idField: xEntityAssoc.idField, readOnly: this.isReadOnly(), error: this.getError(), onErrorChange: this.onErrorChangeAutoCompleteBase, width: this.props.width, scrollHeight: this.props.scrollHeight, suggestions: this.props.suggestions, suggestionsLoad: this.props.suggestionsLoad, lazyLoadMaxRows: this.props.lazyLoadMaxRows, splitQueryValue: this.props.splitQueryValue, minLength: this.props.minLength, suggestionsQuery: { entity: this.xAssoc.entityName, filter: function () { return _this.getFilterBase(_this.props.filter); }, sortField: this.props.sortField, fields: this.props.fields }, inputClassName: this.props.inputClassName, setFocusOnCreate: this.props.setFocusOnCreate })));
73
+ react_1.default.createElement(XAutoCompleteBase_1.XAutoCompleteBase, { value: this.getValue(), onChange: this.onChangeAutoCompleteBase, field: this.props.displayField, itemTemplate: this.props.itemTemplate, searchBrowse: this.props.searchBrowse, valueForm: this.props.assocForm, dropdownButtonEnabled: this.props.dropdownButtonEnabled, insertButtonTooltip: this.props.insertButtonTooltip, updateButtonTooltip: this.props.updateButtonTooltip, searchButtonTooltip: this.props.searchButtonTooltip, idField: xEntityAssoc.idField, readOnly: this.isReadOnly(), error: this.getError(), onErrorChange: this.onErrorChangeAutoCompleteBase, width: this.props.width, scrollHeight: this.props.scrollHeight, suggestions: this.props.suggestions, suggestionsLoad: this.props.suggestionsLoad, lazyLoadMaxRows: this.props.lazyLoadMaxRows, splitQueryValue: this.props.splitQueryValue, minLength: this.props.minLength, suggestionsQuery: { entity: this.xAssoc.entityName, filter: function () { return _this.getFilterBase(_this.props.filter); }, sortField: this.props.sortField, fields: this.props.fields }, inputClassName: this.props.inputClassName, setFocusOnCreate: this.props.setFocusOnCreate })));
74
74
  };
75
75
  return XAutoComplete;
76
76
  }(XFormComponent_1.XFormComponent));
@@ -342,11 +342,16 @@ function intervalFromUI(valueString) {
342
342
  else {
343
343
  var posColon = valueString.indexOf(':');
344
344
  if (posColon === -1) {
345
- var minutes = parseInt(valueString);
346
- if (!isNaN(minutes)) {
347
- var hours = Math.floor(minutes / 60);
348
- minutes = minutes - (hours * 60);
349
- valueInterval = { hours: hours, minutes: minutes };
345
+ // for depaul project, we use hours as default value - TODO - some param/env value to have both types of init value
346
+ // let minutes: number = parseInt(valueString);
347
+ // if (!isNaN(minutes)) {
348
+ // const hours = Math.floor(minutes / 60);
349
+ // minutes = minutes - (hours * 60);
350
+ // valueInterval = {hours: hours, minutes: minutes} as IPostgresInterval;
351
+ // }
352
+ var hours = parseInt(valueString);
353
+ if (!isNaN(hours)) {
354
+ valueInterval = { hours: hours, minutes: 0 };
350
355
  }
351
356
  }
352
357
  else {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@michalrakus/x-react-web-lib",
3
- "version": "1.37.2",
3
+ "version": "1.37.3",
4
4
  "description": "",
5
5
  "scripts": {
6
6
  "clean": "rimraf lib",