VUE数据绑定失败

先上代码

  <el-card type="border-card">
    <template slot="header">
      <span>节点描述</span>
      <div class="pull-right">
        <el-button v-if="!quill.show" @click="quillEdit()" size="mini" class="yellow" icon="edit" title="编辑"></el-button>
        <el-button v-if="quill.show" @click="saveQuill()" size="mini" class="green" icon="fa-check" title="完成"></el-button>
        <el-button v-if="quill.show" @click="closeQuill()" size="mini" class="red" icon="fa-close" title="取消"></el-button>
      </div>
    </template>
    <el-form ref="nodeform" :model="data">
      <el-form-item prop="nodedesc" :error="error.nodedesc">
        <template>
          <quill-editor v-show="quill.show" v-model="data.nodedesc" ref="myQuillEditor" :options="editorOption" style="height:500px">
          </quill-editor>
          <quill-editor v-show="!quill.show" v-model="data.nodedesc" ref="myQuillEditor1" :options="{show : false,  readOnly: true , modules: { toolbar: null }}" style="height:500px">
          </quill-editor>
        </template>
      </el-form-item>
    </el-form>
  </el-card>
  
  下面的export default :data()里如下:
  nodeform: {
    data: {
      nodedesc: null,
      uuid: null
    },
  },
  

}
错误如下,我已经在data中定义了model 和nodedesc为什么还是说我未定义呢?菜鸟在此谢过
clipboard.png

clipboard.png

阅读 3.6k
1 个回答
:error="error.nodedesc"

应该是这个error没有定义?

撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
推荐问题