dattatable 2.2.5 → 2.2.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/build/dashboard/index.d.ts +1 -0
- package/build/dashboard/index.js +8 -1
- package/build/dashboard/navigation.d.ts +5 -0
- package/build/dashboard/navigation.js +7 -2
- package/dist/dattatable.js +796 -796
- package/dist/dattatable.min.js +1 -1
- package/docs/assets/search.js +1 -1
- package/docs/classes/CanvasForm.html +17 -17
- package/docs/classes/Comments.html +12 -12
- package/docs/classes/Dashboard.html +22 -15
- package/docs/classes/DataTable.html +11 -11
- package/docs/classes/Documents.html +45 -45
- package/docs/classes/FilterSlideout.html +14 -14
- package/docs/classes/Footer.html +4 -4
- package/docs/classes/Header.html +4 -4
- package/docs/classes/InstallationRequired.html +12 -12
- package/docs/classes/ItemForm.html +47 -47
- package/docs/classes/LoadingDialog.html +12 -12
- package/docs/classes/Modal.html +26 -26
- package/docs/classes/Navigation.html +25 -6
- package/docs/enums/ActionButtonTypes.html +6 -6
- package/docs/functions/formatBytes.html +1 -1
- package/docs/functions/formatDateValue.html +1 -1
- package/docs/functions/formatTimeValue.html +1 -1
- package/docs/functions/getFileExt.html +1 -1
- package/docs/interfaces/ICommentsItem.html +6 -6
- package/docs/interfaces/IDashboardProps.html +14 -14
- package/docs/interfaces/IDataTable.html +7 -7
- package/docs/interfaces/IDataTableProps.html +6 -6
- package/docs/interfaces/IDocumentsProps.html +25 -25
- package/docs/interfaces/IFilterItem.html +5 -5
- package/docs/interfaces/IFilterProps.html +4 -4
- package/docs/interfaces/IFooterProps.html +6 -6
- package/docs/interfaces/IHeaderProps.html +5 -5
- package/docs/interfaces/IItemFormCreateProps.html +14 -14
- package/docs/interfaces/IItemFormEditProps.html +15 -15
- package/docs/interfaces/IItemFormTab.html +7 -7
- package/docs/interfaces/IItemFormTabInfo.html +3 -3
- package/docs/interfaces/IItemFormViewProps.html +12 -12
- package/docs/interfaces/IShowDialogProps.html +5 -5
- package/package.json +2 -2
- package/pnpm-lock.yaml +16 -16
package/build/dashboard/index.js
CHANGED
|
@@ -37,6 +37,7 @@ var Dashboard = /** @class */ (function () {
|
|
|
37
37
|
var _this = this;
|
|
38
38
|
this._dt = null;
|
|
39
39
|
this._filters = null;
|
|
40
|
+
this._navigation = null;
|
|
40
41
|
this._props = null;
|
|
41
42
|
// Set the properties
|
|
42
43
|
this._props = props;
|
|
@@ -76,7 +77,7 @@ var Dashboard = /** @class */ (function () {
|
|
|
76
77
|
else {
|
|
77
78
|
// Render the navigation
|
|
78
79
|
var navProps_1 = this._props.navigation || {};
|
|
79
|
-
new navigation_1.Navigation({
|
|
80
|
+
this._navigation = new navigation_1.Navigation({
|
|
80
81
|
el: this._props.el.querySelector("#navigation"),
|
|
81
82
|
hideFilter: navProps_1.showFilter != null ? !navProps_1.showFilter : false,
|
|
82
83
|
hideSearch: navProps_1.showSearch != null ? !navProps_1.showSearch : false,
|
|
@@ -222,6 +223,12 @@ var Dashboard = /** @class */ (function () {
|
|
|
222
223
|
Dashboard.prototype.refresh = function (rows) {
|
|
223
224
|
// Refresh the table
|
|
224
225
|
this._dt.refresh(rows);
|
|
226
|
+
// See if a search value exists
|
|
227
|
+
var searchValue = this._navigation ? this._navigation.getSearchValue() : "";
|
|
228
|
+
if (searchValue) {
|
|
229
|
+
// Apply the search value
|
|
230
|
+
this.search(searchValue);
|
|
231
|
+
}
|
|
225
232
|
};
|
|
226
233
|
// Search the table
|
|
227
234
|
Dashboard.prototype.search = function (value) {
|
|
@@ -20,8 +20,13 @@ interface INavProps {
|
|
|
20
20
|
* Navigation
|
|
21
21
|
*/
|
|
22
22
|
export declare class Navigation {
|
|
23
|
+
private _nav;
|
|
23
24
|
private _props;
|
|
24
25
|
constructor(props: INavProps);
|
|
25
26
|
private render;
|
|
27
|
+
/**
|
|
28
|
+
* Public Interface
|
|
29
|
+
*/
|
|
30
|
+
getSearchValue(): string;
|
|
26
31
|
}
|
|
27
32
|
export {};
|
|
@@ -36,14 +36,14 @@ var Navigation = /** @class */ (function () {
|
|
|
36
36
|
// Call the rendering event
|
|
37
37
|
this._props.onRendering ? this._props.onRendering(props) : null;
|
|
38
38
|
// Render a navbar
|
|
39
|
-
|
|
39
|
+
this._nav = gd_sprest_bs_1.Components.Navbar(props);
|
|
40
40
|
// See if we are showing the filter
|
|
41
41
|
if (this._props.hideFilter != true) {
|
|
42
42
|
// Render the filter icon
|
|
43
43
|
// Create a span to wrap the icon in
|
|
44
44
|
var span = document.createElement("span");
|
|
45
45
|
span.className = "bg-white d-inline-flex filter-icon ms-2 rounded";
|
|
46
|
-
|
|
46
|
+
this._nav.el.firstElementChild.appendChild(span);
|
|
47
47
|
// Render a tooltip
|
|
48
48
|
var ttp = gd_sprest_bs_1.Components.Tooltip({
|
|
49
49
|
el: span,
|
|
@@ -63,6 +63,11 @@ var Navigation = /** @class */ (function () {
|
|
|
63
63
|
// Call the event
|
|
64
64
|
this._props.onSearchRendered ? this._props.onSearchRendered(this._props.el.querySelector("input[type='search']")) : null;
|
|
65
65
|
};
|
|
66
|
+
/**
|
|
67
|
+
* Public Interface
|
|
68
|
+
*/
|
|
69
|
+
// Returns the current search value
|
|
70
|
+
Navigation.prototype.getSearchValue = function () { return this._nav.getSearchValue(); };
|
|
66
71
|
return Navigation;
|
|
67
72
|
}());
|
|
68
73
|
exports.Navigation = Navigation;
|