@optimiser/common 1.0.249 → 1.0.253

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.
@@ -158,7 +158,7 @@ var AwsServices = /** @class */ (function () {
158
158
  case 2:
159
159
  err_1 = _a.sent();
160
160
  console.error("Error While Creating Signed Url:", err_1);
161
- throw new err_1;
161
+ return [3 /*break*/, 3];
162
162
  case 3: return [2 /*return*/];
163
163
  }
164
164
  });
@@ -264,6 +264,11 @@ var AwsServices = /** @class */ (function () {
264
264
  };
265
265
  AwsServices.prototype.GeneratePreSignedUrlNotAccelerated = function (params) {
266
266
  var region = params.region, bucket = params.bucket, path = params.path, _a = params.expires, expires = _a === void 0 ? 60 : _a, _b = params.acl, acl = _b === void 0 ? 'private' : _b, _c = params.contentType, contentType = _c === void 0 ? 'application/octet-stream' : _c, _d = params.accessKeyId, accessKeyId = _d === void 0 ? this.accessKeyId : _d, _e = params.secretAccessKey, secretAccessKey = _e === void 0 ? this.secretAccessKey : _e;
267
+ // added by Mohan ason 28-01-2022. To overwrite acl variable.
268
+ // acl variable will have public-read OR private value. default is private
269
+ if (params.accessType != '' && params.accessType != undefined && params.accessType != null) {
270
+ acl = params.accessType;
271
+ }
267
272
  var S3 = new aws_sdk_1.default.S3({
268
273
  accessKeyId: accessKeyId,
269
274
  secretAccessKey: secretAccessKey,
@@ -257,7 +257,8 @@ function GetPageFieldData(pageName, db, mdb, msp_d, next, callback) {
257
257
  ExtraLookupFields: [
258
258
  "UserStatus",
259
259
  "IsAppUser"
260
- ]
260
+ ],
261
+ OnLinkRender: "if(lookupRecord.IsAppUser==true){isHyperlink=false;}"
261
262
  }
262
263
  };
263
264
  createdDateObj = {
@@ -295,7 +296,8 @@ function GetPageFieldData(pageName, db, mdb, msp_d, next, callback) {
295
296
  ExtraLookupFields: [
296
297
  "UserStatus",
297
298
  "IsAppUser"
298
- ]
299
+ ],
300
+ OnLinkRender: "if(lookupRecord.IsAppUser==true){isHyperlink=false;}"
299
301
  }
300
302
  };
301
303
  modDateObj = {
@@ -390,13 +392,13 @@ function GetPageFieldData(pageName, db, mdb, msp_d, next, callback) {
390
392
  };
391
393
  pageData.Fields.splice(0, 0, idObject);
392
394
  //By Kashish : To handle System Info Fields in Grid
393
- if (!pageData.Fields.find(function (x) { return x.Name == 'CreatedBy'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName) && pageData.ObjectName != 'Task')
395
+ if (!pageData.Fields.find(function (x) { return x.Name == 'CreatedBy'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName) && pageData.ObjectName != 'Task' && pageData.ObjectName != 'Session')
394
396
  pageData.Fields.push(createdByObj);
395
- if (!pageData.Fields.find(function (x) { return x.Name == 'CreatedDate'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName))
397
+ if (!pageData.Fields.find(function (x) { return x.Name == 'CreatedDate'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName) && pageData.ObjectName != 'Session')
396
398
  pageData.Fields.push(createdDateObj);
397
- if (!pageData.Fields.find(function (x) { return x.Name == 'ModifiedBy'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName))
399
+ if (!pageData.Fields.find(function (x) { return x.Name == 'ModifiedBy'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName) && pageData.ObjectName != 'Session')
398
400
  pageData.Fields.push(modByObj);
399
- if (!pageData.Fields.find(function (x) { return x.Name == 'ModifiedDate'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName))
401
+ if (!pageData.Fields.find(function (x) { return x.Name == 'ModifiedDate'; }) && !['CompanySessionLogList', 'CompanyTransactionLogsList'].includes(pageData.PageName) && pageData.ObjectName != 'Session')
400
402
  pageData.Fields.push(modDateObj);
401
403
  }
402
404
  if (pageData.Fields && pageData.Type == "ObjectDetail") {
@@ -1695,8 +1697,10 @@ function CheckDataBeforeUpdate(updateObj, objectData, objectSchema, db) {
1695
1697
  if (fieldSchema.UIDataType == 'multiselect' || fieldSchema.UIDataType == 'multilookup') {
1696
1698
  isSame = IsEqualArrays(oldValue, newValue);
1697
1699
  }
1698
- else
1699
- isSame = IsEqualValue(oldValue, newValue);
1700
+ else {
1701
+ if (fldName !== "ModifiedBy")
1702
+ isSame = IsEqualValue(oldValue, newValue);
1703
+ }
1700
1704
  if (!isSame) return [3 /*break*/, 3];
1701
1705
  delete updateObj[fldName];
1702
1706
  return [3 /*break*/, 5];
@@ -2617,6 +2621,9 @@ function SignoutUserFromAllDevices(options, dbMaster, redisClient) {
2617
2621
  options.callback({ message: 'error', error: err });
2618
2622
  }
2619
2623
  if (data) {
2624
+ if (options.Platform) {
2625
+ data = data.filter(function (x) { return (x.Platform == options.Platform); });
2626
+ }
2620
2627
  for (var i = 0; i < data.length; i++) {
2621
2628
  try {
2622
2629
  redisClient.del(data[i].SessionKey.toString());
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@optimiser/common",
3
- "version": "1.0.249",
3
+ "version": "1.0.253",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {