@arquimedes.co/eureka-forms 2.0.114 → 2.0.116

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.
@@ -120,10 +120,12 @@ export interface EntityDateCondition extends EntityPropertyConditionBase {
120
120
  export interface EntityRelativeDateCondition extends EntityPropertyConditionBase {
121
121
  propertyType: EntityPropertyTypes.DATEPICKER;
122
122
  propertyOperator: OperatorTypes.PAST_RELATIVE_LESS | OperatorTypes.PAST_RELATIVE_MORE | OperatorTypes.FUTURE_RELATIVE_LESS | OperatorTypes.FUTURE_RELATIVE_MORE;
123
- days: number;
124
- hours: number;
125
- minutes: number;
126
- working: boolean;
123
+ value: {
124
+ days: number;
125
+ hours: number;
126
+ minutes: number;
127
+ working: boolean;
128
+ };
127
129
  }
128
130
  export type EntityTimeCondition = BaseEntityTimeCondition | WorkingEntityTimeCondition;
129
131
  export interface BaseEntityTimeCondition extends EntityPropertyConditionBase {
@@ -514,6 +514,7 @@ var evaluateEntityValueCondition = function (condition, entity, entityValue) {
514
514
  return false;
515
515
  };
516
516
  var evaluateEntityPropertyCondition = function (condition, entity, entityValue) {
517
+ var _a, _b, _c;
517
518
  if (isEntityPropertyExistance(condition)) {
518
519
  var boolFactor = condition.propertyOperator === OperatorTypes.EXISTS;
519
520
  var value_3 = entityValue[condition.idProperty];
@@ -563,7 +564,7 @@ var evaluateEntityPropertyCondition = function (condition, entity, entityValue)
563
564
  case OperatorTypes.PAST_RELATIVE_MORE:
564
565
  case OperatorTypes.FUTURE_RELATIVE_LESS:
565
566
  case OperatorTypes.FUTURE_RELATIVE_MORE: {
566
- var date_1 = getRelativeDate(condition.days, condition.hours, condition.minutes, condition.propertyOperator ===
567
+ var date_1 = getRelativeDate((_a = condition.value) === null || _a === void 0 ? void 0 : _a.days, (_b = condition.value) === null || _b === void 0 ? void 0 : _b.hours, (_c = condition.value) === null || _c === void 0 ? void 0 : _c.minutes, condition.propertyOperator ===
567
568
  OperatorTypes.PAST_RELATIVE_LESS ||
568
569
  condition.propertyOperator ===
569
570
  OperatorTypes.PAST_RELATIVE_MORE);
@@ -571,9 +572,9 @@ var evaluateEntityPropertyCondition = function (condition, entity, entityValue)
571
572
  OperatorTypes.PAST_RELATIVE_LESS ||
572
573
  condition.propertyOperator ===
573
574
  OperatorTypes.FUTURE_RELATIVE_LESS)
574
- return new Date().getTime() > date_1.getTime();
575
+ return new Date(value).getTime() < date_1.getTime();
575
576
  else
576
- return new Date().getTime() < date_1.getTime();
577
+ return new Date(value).getTime() > date_1.getTime();
577
578
  }
578
579
  default:
579
580
  false;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@arquimedes.co/eureka-forms",
3
3
  "repository": "git://github.com/Arquimede5/Eureka-Forms.git",
4
- "version": "2.0.114",
4
+ "version": "2.0.116",
5
5
  "scripts": {
6
6
  "start": "react-scripts start",
7
7
  "build": "react-scripts build",