Breezejs Double trouble in angularjs

前端 未结 5 1699
一整个雨季
一整个雨季 2021-01-20 14:46

I am trying to change a value in a angular view from a integer to a float/double value that is bind to ngmodel. The input don’t except anything other than a integer.

5条回答
  •  栀梦
    栀梦 (楼主)
    2021-01-20 15:34

    I've checked a preliminary fix into GitHub for this. Please check it out and let me know if it works ( or not). We are still testing it.

    This issue is caused by Angular's (new) behavior where if the angular digest cycle does not see a change to a model property then it seems to reset the UI to what it was on the previous digest cycle. So.. the idea behind this fix is to convince angular that the model value has changed even when it hasn’t.

    and.. nice catch ( this was not obvious and your plunkr helped) :)

    Ward adds: You must love the breeze team responsiveness :-) Jay jumped right on this and came up with an interesting solution. But please note the word "preliminary" in Jay's answer. We are discussing this "fix" internally and it may be withdrawn. Consider the zEquivalent directive in this new plunker or just wait until the dust settles.

提交回复
热议问题