vue-cnode icon indicating copy to clipboard operation
vue-cnode copied to clipboard

打扰下,不知道能不能告诉我一下有关tool.js里面的setMsg是干什么的

Open Zhengbledore opened this issue 10 years ago • 3 comments

兄台,我这两天在学习你的项目代码,有个疑惑就是你的setMsg的作用.不知道是干嘛的,除了请求返回时调用,也没看到其他组件再用到tool.js,或者说setMsg里面的信息给谁使用.

Zhengbledore avatar Sep 30 '16 09:09 Zhengbledore

是用于login.vue里面的吗

 this.setBaseInfo(this.access, (res) => {
              if (res.success) {
                    this.success()
              }
              this.setTip({
                    text: res.msg
              })
        `})`

Zhengbledore avatar Sep 30 '16 09:09 Zhengbledore

在vuex 下面的actions里面的content_actions里面。主要是我想组件和vuex通信时后传递的数据格式化。这样新同学加入项目也能快速开发。

wszgxa avatar Sep 30 '16 10:09 wszgxa

@wszgxa 理解了,多谢up

Zhengbledore avatar Sep 30 '16 11:09 Zhengbledore