Giter Club home page Giter Club logo

Comments (8)

Renford avatar Renford commented on August 26, 2024 2

终于知道是啥问题了,跟详情页数据不会重置的解决方案(如下所示)冲突了。

Vue.mixin({
  onUnload () {
    if (this.$options.data) {
      this._watchers = []
      this._watcher.teardown()
      Object.assign(this, this.$options.data)
    }
  }
})

from mpvue-picker.

KuangPF avatar KuangPF commented on August 26, 2024

可以,下次迭代就加上了这个事件,如果你现在这个需求比较急的话,你可以自己先自改一下源码,添加一个pickerCancel 事件。

from mpvue-picker.

KuangPF avatar KuangPF commented on August 26, 2024

v2.0.1 已支持

from mpvue-picker.

Renford avatar Renford commented on August 26, 2024

1、在pageA的onUnload调用pickerCancel,
2、再次进入showPicker依然是true,
3、然后调用this.$refs.mpvuePicker.show(),便不会再弹出picker

请问这个如何解决呢?

from mpvue-picker.

KuangPF avatar KuangPF commented on August 26, 2024

你是怎样调用的 pickerCancel ,方便提供一下代码不

from mpvue-picker.

Renford avatar Renford commented on August 26, 2024

@KuangPF 这用调用有问题吗

  onUnload () {
    console.log('关闭日历....onUnload', this.$refs)
    this.$refs.mpvuePicker.pickerCancel()
  }

from mpvue-picker.

KuangPF avatar KuangPF commented on August 26, 2024

我测试了下,在 onUnload 里面调用 pickerCancel 方法,然后再次进入页面显示正常,不知道方不方便提供一下更多的代码,好排查问题。
issues 4

from mpvue-picker.

Renford avatar Renford commented on August 26, 2024

不好意思,那个是公司项目。
用最新mpvue-quickstart新建了一个项目(老项目是俩个月之前创建的),将老工程源代码考进去,就可以了,具体为啥还不清楚。
其实,这段时间mpvue-quickstart只是更新了下mpvue-loader,从1.0.12升级到1.1.2。

from mpvue-picker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.