Announcement

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

    form.valuesHaveChanged bug

    SmartClient Version: SNAPSHOT_v13.1d_2024-09-05/AllModules Development Only (built 2024-09-05)


    Hello, please try this test case in the showcase sample sqlAutoDeriveSchema:

    Code:
    isc.ListGrid.create({
        width: 850, height: 400,
        autoFetchData: true,
        dataSource: "AutoDerivedCustomer",
        initialCriteria: {country: 'USA'},
        canEdit: true,
        canRemoveRecords: true,
        // override titles in a few cases, to include a space where needed
        recordClick: "editForm.editRecord(record)",
        fields: [
            {name: "CUSTOMERNUMBER", title: "Customer Number"},
            {name: "CUSTOMERNAME", title: "Customer Name"},
            {name: "CITY"},
            {name: "STATE"},
            {name: "POSTALCODE", title: "Postal Code"},
            {name: "salesRepEmployeeNumber"}
        ]
    });
    isc.DynamicForm.create({
        ID: "editForm",
        top: 420,
        dataSource: "AutoDerivedCustomer",
        fields: [
            {name: "CUSTOMERNUMBER", title: "Customer Number"},
            {name: "CUSTOMERNAME", title: "Customer Name"},
            {name: "CITY"},
            {name: "STATE"},
            {name: "POSTALCODE", title: "Postal Code"},
            {name: "SALESREPEMPLOYEENUMBER", displayField: "salesRepEmployeeName"}
        ]
    })
    then click a record *without a Sales Rep name*, like Customer Number 125, in the grid, to see it ready for editing in the form.
    Without modifying anything, run in the console:

    editForm.valuesHaveChanged() // result: true
    and
    editForm.getChangedValues() // result: {salesRepEmployeeName: null}


    #2
    Sorry, possibly dense here, but this presumably involved a DataSource (not shown) called "AutoDerivedCustomer" which uses autoDeriveSchema - but with which table?

    We're asking because autoDeriveSchema wouldn't normally produce fieldNames compatible with those field names shown in your grid and form. This is perhaps something happening with Oracle and in your particular Oracle setup?

    Can you reproduce a similar problem of a seeming false detection of a change if you use either the sample databases or even a clientOnly DataSource?

    Comment


      #3
      Hello, this test case is modified from the showcase sample sqlAutoDeriveSchema.
      Please let me know if it’s not suitable and I’ll try to make another one.

      Comment


        #4
        Hello, do you see the problem or I must produce a different test case?

        Comment


          #5
          Hi Claudio
          The test case is good and we have a developer working on the problem. We'll follow up when we have more information for you
          Regards
          Isomorphic Software

          Comment

          Working...
          X