0

Upgrade ZK from v8.6.0.1 to v.9.0.0.3

asked 2021-04-02 21:11:42 +0800

rmalik gravatar image rmalik
31 2

Hi all,

We have been trying to upgrade our ZK version from maven by updating our pom.xml. However upon starting the project we see that the most user interfaces that we have build are functioning correctly.

However, upon using the the paging for our listbox:

<n:footer class="main-footer"> 
<paging onPaging="@command('onPaging', activePage=event.activePage)" pageSize="@load(vm.pageSize)"
            totalSize="@load(vm.totalSize)" activePage="@bind(vm.activePage)" sclass="floatright" pageIncrement="1" detailed="false"></paging>
</n:footer>

We encounter two errors (8901/dev/zkau/web/_zv2021032310/js/zul.inp.wpd:19):

Uncaught TypeError: Cannot read property 'value' of undefined

 bind_: function() {
                    this.$supers(g, "bind_", arguments);
                    var a = this.getInputNode();
                    this._lastChg = this._defRawVal = a.value;
                    this.domListen_(a, "onFocus", "doFocus_").domListen_(a, "onBlur", "doBlur_").domListen_(a, "onSelect").domListen_(a, "onMouseOver").domListen_(a, "onMouseOut");
                    if (zk.ie10_ || zk.ie11_) {
                        var b = this;
                        setTimeout(function() {
                            b.domListen_(a, "onInput", "doInput_")
                        }, 100)
                    } else
                        this.domListen_(a, "onInput", "doInput_");
                    zk.ios && this.domListen_(a, "onTouchStart", "_doTouch");
                    if (a = a.form)
                        jq(a).on("reset", this.proxy(this._resetForm));
                    zWatch.listen({
                        onShow: this
                    })

The above line (this.lastChg = this.defRawVal = a.value;) The value this._defRawVal is undefined.

And on line (zul.inp.wpd:formatted:460):

Uncaught (in promise) TypeError: Cannot read property 'form' of undefined

 unbind_: function() {
                    zWatch.unlisten({
                        onShow: this
                    });
                    this.$class._stopOnChanging(this);
                    this.clearErrorMessage(!0);
                    var a = this.getInputNode();
                    this.domUnlisten_(a, "onFocus", "doFocus_").domUnlisten_(a, "onBlur", "doBlur_").domUnlisten_(a, "onSelect").domUnlisten_(a, "onMouseOver").domUnlisten_(a, "onMouseOut").domUnlisten_(a, "onInput", "doInput_");
                    zk.ios && this.domUnlisten_(a, "onTouchStart", "_doTouch");
                    (a = a.form) && jq(a).off("reset", this.proxy(this._resetForm));
                    this.$supers(g, "unbind_", arguments)
                },

Here a.form = null.

How can we solve these errors?

Here is a small video in which i recorded the actions: link video

Kind regards,

Remie

delete flag offensive retag edit

4 Answers

Sort by ยป oldest newest most voted
0

answered 2021-04-08 18:01:39 +0800

MDuchemin gravatar image MDuchemin
2560 1 6
ZK Team

Hi Remie,

9.5.1 stable releases are already available for PE / EE download. This fix will be available in all releases after that. I believe next CE release including this fix will be 9.6.0 CE

link publish delete flag offensive edit

Comments

Hi MDuchemin, thanks for your information. I will wait for the 9.6.0 CE version to be released.

rmalik ( 2021-04-12 16:47:58 +0800 )edit
0

answered 2021-04-06 16:07:50 +0800

rmalik gravatar image rmalik
31 2

Hi MDuchemin,

You are completely right! I have switched to version 9.5.1(-Eval) and paging just works fine without any errors. My next question is, when will this fix be pushed to a new stable release? That way i can use that version that is compatible.

Kind regards,

Remie

link publish delete flag offensive edit
1

answered 2021-04-06 09:58:17 +0800

MDuchemin gravatar image MDuchemin
2560 1 6
ZK Team

Hi rmalik,

The most likely cause is that in recent version, the listbox will perform partial invalidation instead of redrawing its full content under some scenarios.

This is more efficient from a network and rendering pov, but it has caused issues in similar structures as yours (component to update located in the headers). See ticket here: https://tracker.zkoss.org/browse/ZK-4709

Could you test out the 9.5.1(-Eval) release and check if this issue still happens after the bug fix has been applied?

link publish delete flag offensive edit
0

answered 2021-04-02 22:33:46 +0800

rmalik gravatar image rmalik
31 2

updated 2021-04-02 22:44:14 +0800

Upon further investigation its the combination of the auxheader and datebox causing this issue. After removing:

<auxheader><datebox width="100%" value="@bind(filtervm.field('ReceiptDate').value)" format="dd-MM-yy"  /></auxheader></template>

Paging works correctly without errors. Is something changed for the datebox when using it in auxheaders zk 9.5.0.3?

link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
1 follower

RSS

Stats

Asked: 2021-04-02 21:11:42 +0800

Seen: 12 times

Last updated: Apr 08 '21

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More