自动添加注释,仅转到特定的视图codeigniter vue

时间:2018-11-29 15:26:07

标签: php codeigniter vue.js

我的Vue中有一个手表属性。当我对select标记中的某些特定数据进行更改时,应该添加注释。但是,当我在codeigniter应用程序中访问该页面时,它会添加注释。这是Watch的代码

      watch: {
        clonedPodType: function (newVal, oldVal) {
            console.log(oldVal, newVal)
            this.oldType = oldVal
            this.newType = newVal
            if (typeof(oldVal) != "undefined" ) {
                if (oldVal == null) {
                    oldVal = " "
                }
                if (newVal == null) {
                    newVal = " "
                }
                this.createNewMessage(oldVal, newVal)
            }

        },
  },

createNewMessage是添加带有新值和旧值的注释的函数。 谁能帮我解决这个问题。我只想在某些用户进行更改时添加评论,但是当前它只是从select标记中获取值并将其视为更改并添加评论

0 个答案:

没有答案