gd-sprest 8.0.0 → 8.0.1

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.
@@ -414,8 +414,14 @@ export interface ISPCfgViewInfo {
414
414
  /** The JSLink property. */
415
415
  JSLink?: string;
416
416
 
417
+ /** Flag to set the view as hidden. */
418
+ Hidden?: boolean;
419
+
417
420
  /** The row limit property. */
418
421
  RowLimit?: number;
422
+
423
+ /** Flag to enable the tabular view option. */
424
+ Tabular?: boolean;
419
425
 
420
426
  /** The view fields. */
421
427
  ViewFields?: Array<string>;
@@ -471,6 +471,9 @@ exports.SPConfig = function (cfg, webUrl) {
471
471
  else {
472
472
  // Add the view
473
473
  views.add({
474
+ DefaultView: cfg.Default,
475
+ Hidden: cfg.Hidden,
476
+ TabularView: cfg.Tabular,
474
477
  Title: cfg.ViewName,
475
478
  RowLimit: cfg.RowLimit,
476
479
  ViewQuery: cfg.ViewQuery
@@ -1011,12 +1014,15 @@ exports.SPConfig = function (cfg, webUrl) {
1011
1014
  }
1012
1015
  }
1013
1016
  // See if we are updating the view properties
1014
- if (typeof (cfg.Default) === "boolean" || cfg.JSLink || cfg.RowLimit > 0 || cfg.ViewQuery) {
1017
+ if (typeof (cfg.Default) === "boolean" || typeof (cfg.Hidden) === "boolean" ||
1018
+ typeof (cfg.Tabular) === "boolean" || cfg.JSLink || cfg.RowLimit > 0 || cfg.ViewQuery) {
1015
1019
  var props = {};
1016
1020
  // Log
1017
1021
  console.log("[gd-sprest][View] Updating the view properties for the '" + cfg.ViewName + "' view.");
1018
1022
  // Set the properties
1019
1023
  typeof (cfg.Default) === "boolean" ? props["DefaultView"] = cfg.Default : null;
1024
+ typeof (cfg.Hidden) === "boolean" ? props["Hidden"] = cfg.Hidden : null;
1025
+ typeof (cfg.Tabular) === "boolean" ? props["TabularView"] = cfg.Tabular : null;
1020
1026
  cfg.JSLink ? props["JSLink"] = cfg.JSLink : null;
1021
1027
  cfg.RowLimit > 0 ? props["RowLimit"] = cfg.RowLimit : null;
1022
1028
  cfg.ViewQuery ? props["ViewQuery"] = cfg.ViewQuery : null;
package/build/rest.js CHANGED
@@ -9,7 +9,7 @@ var sptypes_1 = require("./sptypes");
9
9
  * SharePoint REST Library
10
10
  */
11
11
  exports.$REST = {
12
- __ver: 8.00,
12
+ __ver: 8.01,
13
13
  AppContext: function (siteUrl) { return Lib.Site.getAppContext(siteUrl); },
14
14
  Apps: Lib.Apps,
15
15
  ContextInfo: Lib.ContextInfo,
@@ -3891,9 +3891,15 @@ declare module 'gd-sprest/helper/spCfg' {
3891
3891
  /** The JSLink property. */
3892
3892
  JSLink?: string;
3893
3893
 
3894
+ /** Flag to set the view as hidden. */
3895
+ Hidden?: boolean;
3896
+
3894
3897
  /** The row limit property. */
3895
3898
  RowLimit?: number;
3896
3899
 
3900
+ /** Flag to enable the tabular view option. */
3901
+ Tabular?: boolean;
3902
+
3897
3903
  /** The view fields. */
3898
3904
  ViewFields?: Array<string>;
3899
3905