GithubHelp home page GithubHelp logo

Comments (8)

zhouzhangfan avatar zhouzhangfan commented on April 27, 2024 2

https://run.iviewui.com/26HtrjP4

from viewui.

androidjdx avatar androidjdx commented on April 27, 2024 2

第一次手动更新可以,第二次就不更新了,请问怎么解决呢?
this.$nextTick(() => {
this.$refs.menu.updateOpened();
this.$refs.menu.updateActiveName();
});

from viewui.

sdochenwuhn avatar sdochenwuhn commented on April 27, 2024 1
 watch: {
    "active-name"() {
      this.$nextTick(() => {
        this.$refs.menuRef.updateOpened();
        this.$refs.menuRef.updateActiveName();
      });
    }
  },

手动更新一波可解决

from viewui.

fish-uncle avatar fish-uncle commented on April 27, 2024 1

只能这么搞了

const menuList = document.getElementsByClassName('ivu-menu-item');
  menuList.forEach(item => {
    if (item.getAttribute('data-id') == id) {
      item.className = 'ivu-menu-item ivu-menu-item-active ivu-menu-item-selected'
    } else {
      item.className = 'ivu-menu-item'
    }
  })
<Menu-item :name="item.id" :key="item.id" v-for="item in left.list" :data-id="item.id">
    {{item.reportName}}
</Menu-item>

from viewui.

zhouzhangfan avatar zhouzhangfan commented on April 27, 2024

Environment
Windows 10 Chrome 77.0.3865.120 Vue 2.5.2 iView 3.4.2

from viewui.

heiyeliuying avatar heiyeliuying commented on April 27, 2024

同样的问题,当我修改了Menu的active-name时,menu的选中状态并没有随之改变.
"view-design": "^4.0.0", "vue": "^2.5.16",

from viewui.

huzewei avatar huzewei commented on April 27, 2024

3.4.2版本。Menu下包含MenuItem和Submenu时active-name open-names没起作用。Menu动态菜单切换渲染的。

from viewui.

1442916418 avatar 1442916418 commented on April 27, 2024

请问怎么解决?

from viewui.

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.