Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

  • visibleWhen and datetime FormItem

    SmartClient Version: SNAPSHOT_v12.1d_2019-09-10/AllModules Development Only (built 2019-09-10)

    Chrome on OSX

    Hello, please try this test case:

    Code:
    isc.VLayout.create({
        members: [
            isc.DynamicForm.create({
                ID: "form1",
                numCols: 4,
                width: 650,
                fields: [
                    {
                        name: "date1", title: "Date1", type: "datetime", useTextField: true, wrapTitle: false
                    }
                ]
            }),
            isc.DynamicForm.create({
                ID: "form2",
                numCols: 4,
                width: 650,
                fields: [
                    {
                        name: "date2", title: "Date2", type: "datetime", useTextField: true, wrapTitle: false
                    }
                ]
            }),
            isc.Label.create({
                contents: "visible when Date 1 is greaterOrEqual than Date2",
                wrap: false,
                visibleWhen: {
                    _constructor: "AdvancedCriteria",
                    operator: "and",
                    criteria: [
                        {fieldName: "form1.values.date1", operator: "greaterOrEqualField", value: "form2.values.date2"}
                    ]
                }
            })
        ]
    })
    The label is visible when date1 is greater or equal to date2.

    This works unless you choose two datetime values with the same date, but where the time part of date2 is greater that the time part of date1.

    So, it seems that the time part is ignored in the criteria.

  • #2
    Thanks for the test case. This issue has been fixed back to 12.0 available in builds starting on Sep 11.

    Comment


    • #3

      SmartClient Version: SNAPSHOT_v12.1d_2019-09-12/AllModules Development Only (built 2019-09-12)

      I can confirm it's fixed, thank you very much.

      Comment

      Working...
      X