dattatable 2.11.63 → 2.11.65

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.
Files changed (74) hide show
  1. package/build/common/documents.js +4 -4
  2. package/build/common/itemForm.d.ts +58 -50
  3. package/build/common/itemForm.js +278 -280
  4. package/build/common/list.d.ts +5 -3
  5. package/build/common/list.js +24 -16
  6. package/build/dashboard/index.d.ts +1 -1
  7. package/build/dashboard/index.js +3 -3
  8. package/dist/dattatable.js +611 -611
  9. package/dist/dattatable.min.js +1 -1
  10. package/docs/assets/search.js +1 -1
  11. package/docs/classes/Accordion.html +2 -2
  12. package/docs/classes/AuditLog.html +2 -2
  13. package/docs/classes/CanvasForm.html +2 -2
  14. package/docs/classes/Comments.html +2 -2
  15. package/docs/classes/Dashboard.html +5 -5
  16. package/docs/classes/DataTable.html +3 -3
  17. package/docs/classes/Documents.html +6 -6
  18. package/docs/classes/FilterSlideout.html +2 -2
  19. package/docs/classes/Footer.html +2 -2
  20. package/docs/classes/Header.html +2 -2
  21. package/docs/classes/InstallationRequired.html +2 -2
  22. package/docs/classes/ItemForm.html +12 -7
  23. package/docs/classes/List.html +6 -4
  24. package/docs/classes/ListConfig.html +2 -2
  25. package/docs/classes/ListSecurity.html +2 -2
  26. package/docs/classes/LoadingDialog.html +2 -2
  27. package/docs/classes/Modal.html +2 -2
  28. package/docs/classes/Navigation.html +3 -3
  29. package/docs/classes/Tiles.html +2 -2
  30. package/docs/classes/Timeout.html +2 -2
  31. package/docs/enums/ActionButtonTypes.html +2 -2
  32. package/docs/functions/formatBytes.html +1 -1
  33. package/docs/functions/formatDateValue.html +1 -1
  34. package/docs/functions/formatTimeValue.html +1 -1
  35. package/docs/functions/getContextInfo.html +1 -1
  36. package/docs/functions/getFileExt.html +1 -1
  37. package/docs/functions/waitForTheme.html +1 -1
  38. package/docs/interfaces/IAccordion.html +2 -2
  39. package/docs/interfaces/IAccordionProps.html +2 -2
  40. package/docs/interfaces/IAuditLogItem.html +15 -13
  41. package/docs/interfaces/IAuditLogItemCreation.html +2 -2
  42. package/docs/interfaces/IAuditLogProps.html +2 -2
  43. package/docs/interfaces/IAuditLogViewProps.html +2 -2
  44. package/docs/interfaces/ICommentsItem.html +2 -2
  45. package/docs/interfaces/ICreateLookupData.html +2 -2
  46. package/docs/interfaces/IDashboardProps.html +2 -2
  47. package/docs/interfaces/IDataTable.html +2 -2
  48. package/docs/interfaces/IDataTableProps.html +2 -2
  49. package/docs/interfaces/IDocumentsProps.html +2 -2
  50. package/docs/interfaces/IFilterItem.html +2 -2
  51. package/docs/interfaces/IFilterProps.html +2 -2
  52. package/docs/interfaces/IFooterProps.html +2 -2
  53. package/docs/interfaces/IGenerateLookupDataProps.html +2 -2
  54. package/docs/interfaces/IHeaderProps.html +2 -2
  55. package/docs/interfaces/IInstallProps.html +2 -2
  56. package/docs/interfaces/IItemFormCreateProps.html +2 -2
  57. package/docs/interfaces/IItemFormEditProps.html +2 -2
  58. package/docs/interfaces/IItemFormSaveProps.html +2 -2
  59. package/docs/interfaces/IItemFormTab.html +2 -2
  60. package/docs/interfaces/IItemFormTabInfo.html +2 -2
  61. package/docs/interfaces/IItemFormViewProps.html +2 -2
  62. package/docs/interfaces/IListConfig.html +2 -2
  63. package/docs/interfaces/IListConfigProps.html +2 -2
  64. package/docs/interfaces/IListProps.html +2 -2
  65. package/docs/interfaces/IListSecurity.html +2 -2
  66. package/docs/interfaces/IListSecurityItem.html +2 -2
  67. package/docs/interfaces/ILookupData.html +2 -2
  68. package/docs/interfaces/IShowDialogProps.html +2 -2
  69. package/docs/interfaces/ITiles.html +2 -2
  70. package/docs/interfaces/ITilesProps.html +2 -2
  71. package/docs/interfaces/IValidateLookupsProps.html +2 -2
  72. package/docs/variables/DattaTable.html +1 -1
  73. package/docs/variables/ListSecurityDefaultGroups.html +1 -1
  74. package/package.json +2 -2
@@ -1,5 +1,5 @@
1
1
  import { Types } from "gd-sprest-bs";
2
- import { IItemFormCreateProps, IItemFormEditProps, IItemFormViewProps } from ".";
2
+ import { ItemForm, IItemFormCreateProps, IItemFormEditProps, IItemFormViewProps } from ".";
3
3
  /** List Properties */
4
4
  export interface IListProps<T = Types.SP.ListItem> {
5
5
  camlQuery?: string;
@@ -28,6 +28,10 @@ export declare class List<T = Types.SP.ListItem> {
28
28
  get CanViewItems(): boolean;
29
29
  get EditForm(): import("gd-sprest-bs/src/components/components").IListFormEdit;
30
30
  get EditForms(): import("gd-sprest-bs/src/components/components").IListFormEdit[];
31
+ private _itemForm;
32
+ get ItemForm(): ItemForm;
33
+ private _items;
34
+ get Items(): T[];
31
35
  private _listContentTypes;
32
36
  get ListContentTypes(): Types.SP.ContentTypeOData[];
33
37
  private _listFields;
@@ -39,8 +43,6 @@ export declare class List<T = Types.SP.ListItem> {
39
43
  get ListUrl(): string;
40
44
  private _listViews;
41
45
  get ListViews(): Types.SP.ViewOData[];
42
- private _items;
43
- get Items(): T[];
44
46
  private _listId;
45
47
  get ListId(): string;
46
48
  private _listName;
@@ -13,6 +13,10 @@ var List = /** @class */ (function () {
13
13
  /** Public Properties */
14
14
  // CAML query
15
15
  this._camlQuery = null;
16
+ // Item Form
17
+ this._itemForm = null;
18
+ // Items
19
+ this._items = null;
16
20
  // List Content Types Information
17
21
  this._listContentTypes = null;
18
22
  // List Fields Information
@@ -23,8 +27,6 @@ var List = /** @class */ (function () {
23
27
  this._listUrl = null;
24
28
  // List Views Information
25
29
  this._listViews = null;
26
- // Items
27
- this._items = null;
28
30
  // List Id
29
31
  this._listId = null;
30
32
  // List Name
@@ -140,13 +142,23 @@ var List = /** @class */ (function () {
140
142
  });
141
143
  Object.defineProperty(List.prototype, "EditForm", {
142
144
  // Reference to the edit form
143
- get: function () { return _1.ItemForm.EditForm; },
145
+ get: function () { return this.ItemForm.EditForm; },
144
146
  enumerable: false,
145
147
  configurable: true
146
148
  });
147
149
  Object.defineProperty(List.prototype, "EditForms", {
148
150
  // Reference to the edit forms, if tabs are used
149
- get: function () { return _1.ItemForm.EditForms; },
151
+ get: function () { return this.ItemForm.EditForms; },
152
+ enumerable: false,
153
+ configurable: true
154
+ });
155
+ Object.defineProperty(List.prototype, "ItemForm", {
156
+ get: function () { return this._itemForm; },
157
+ enumerable: false,
158
+ configurable: true
159
+ });
160
+ Object.defineProperty(List.prototype, "Items", {
161
+ get: function () { return this._items; },
150
162
  enumerable: false,
151
163
  configurable: true
152
164
  });
@@ -181,11 +193,6 @@ var List = /** @class */ (function () {
181
193
  enumerable: false,
182
194
  configurable: true
183
195
  });
184
- Object.defineProperty(List.prototype, "Items", {
185
- get: function () { return this._items; },
186
- enumerable: false,
187
- configurable: true
188
- });
189
196
  Object.defineProperty(List.prototype, "ListId", {
190
197
  get: function () { return this._listId; },
191
198
  enumerable: false,
@@ -203,13 +210,13 @@ var List = /** @class */ (function () {
203
210
  });
204
211
  Object.defineProperty(List.prototype, "ViewForm", {
205
212
  // Reference to the display form
206
- get: function () { return _1.ItemForm.DisplayForm; },
213
+ get: function () { return this.ItemForm.DisplayForm; },
207
214
  enumerable: false,
208
215
  configurable: true
209
216
  });
210
217
  Object.defineProperty(List.prototype, "ViewForms", {
211
218
  // Reference to the display forms, if tabs are used
212
- get: function () { return _1.ItemForm.DisplayForms; },
219
+ get: function () { return this.ItemForm.DisplayForms; },
213
220
  enumerable: false,
214
221
  configurable: true
215
222
  });
@@ -230,14 +237,15 @@ var List = /** @class */ (function () {
230
237
  });
231
238
  // Clears the modal or canvas
232
239
  List.prototype.clear = function (props) {
240
+ // Set the item form
241
+ this._itemForm = new _1.ItemForm(props);
242
+ this._itemForm.ListName = this.ListName;
233
243
  // Ensure we are not rendering to a specified element
234
244
  if (props.elForm == null) {
235
245
  // Clear the modal/form
236
- var useModal = typeof (props.useModal) === "boolean" ? props.useModal : _1.ItemForm.UseModal;
246
+ var useModal = typeof (props.useModal) === "boolean" ? props.useModal : this.ItemForm.UseModal;
237
247
  useModal ? _1.Modal.clear() : _1.CanvasForm.clear();
238
248
  }
239
- // Set the list name
240
- _1.ItemForm.ListName = this.ListName;
241
249
  // Call the event
242
250
  this._onResetForm ? this._onResetForm() : null;
243
251
  };
@@ -274,7 +282,7 @@ var List = /** @class */ (function () {
274
282
  // Clear the modal/canvas
275
283
  this.clear(props);
276
284
  // Display the form
277
- _1.ItemForm.edit(props).then(null, this._onLoadFormError);
285
+ this.ItemForm.edit(props).then(null, this._onLoadFormError);
278
286
  };
279
287
  // Gets the changes for a list item's version history
280
288
  List.prototype.getChanges = function (id, defaultFields) {
@@ -693,7 +701,7 @@ var List = /** @class */ (function () {
693
701
  // Saves the item with an option to bypass validation
694
702
  List.prototype.save = function (bypassValidation) {
695
703
  // Save the item
696
- return _1.ItemForm.save({ bypassValidation: bypassValidation });
704
+ return this.ItemForm.save({ bypassValidation: bypassValidation });
697
705
  };
698
706
  // Updates an item
699
707
  List.prototype.updateItem = function (itemId, values) {
@@ -161,5 +161,5 @@ export declare class Dashboard {
161
161
  setFilterValue(key: string, value?: string | string[]): void;
162
162
  showFilter(): void;
163
163
  updateCell(row: number, column: number, value: any): void;
164
- updateRow: (rowIdx: number, data: any) => void;
164
+ updateRow(rowIdx: number, data: any): void;
165
165
  }
@@ -27,7 +27,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
27
27
  Object.defineProperty(exports, "__esModule", { value: true });
28
28
  exports.Dashboard = void 0;
29
29
  var gd_sprest_bs_1 = require("gd-sprest-bs");
30
- var common_1 = require("../common");
31
30
  var accordion_1 = require("./accordion");
32
31
  var filter_1 = require("./filter");
33
32
  var footer_1 = require("./footer");
@@ -58,8 +57,6 @@ var Dashboard = /** @class */ (function () {
58
57
  this._tiles = null;
59
58
  // Set the properties
60
59
  this._props = props;
61
- // Set the flag
62
- typeof (props.useModal) === "boolean" ? common_1.ItemForm.UseModal = props.useModal : null;
63
60
  // Render the dashboard
64
61
  this.render();
65
62
  // Let the object get instaniated before calling the event
@@ -438,6 +435,9 @@ var Dashboard = /** @class */ (function () {
438
435
  Dashboard.prototype.showFilter = function () { this._filters.show(); };
439
436
  // Updates a cell in the data table
440
437
  Dashboard.prototype.updateCell = function (row, column, value) { var _a; (_a = this._dt) === null || _a === void 0 ? void 0 : _a.updateCell(row, column, value); };
438
+ // Updates a row in the data table
439
+ Dashboard.prototype.updateRow = function (rowIdx, data) { var _a; (_a = this._dt) === null || _a === void 0 ? void 0 : _a.updateRow(rowIdx, data); };
440
+ ;
441
441
  return Dashboard;
442
442
  }());
443
443
  exports.Dashboard = Dashboard;