diff --git a/src/App.vue b/src/App.vue index 150c24c..b5116f5 100644 --- a/src/App.vue +++ b/src/App.vue @@ -27,7 +27,9 @@ :data="gridData" :fixed-left="2" :fixed-right="1" - @on-update="onUpdate" + @after-edit-cell="afterEditCell" + @after-autofill="afterAutofill" + @after-paste="afterPaste" > @@ -88,7 +90,13 @@ export default { ] this.$refs.datagrid.updateData(data); }, - onUpdate(data) { + afterEditCell(data) { + console.log(data) + }, + afterAutofill(data) { + console.log(data) + }, + afterPaste(data) { console.log(data) }, getCheckedRows() { diff --git a/src/components/index.vue b/src/components/index.vue index 56b034c..2e3013a 100644 --- a/src/components/index.vue +++ b/src/components/index.vue @@ -16,7 +16,9 @@ contenteditable="true" v-show="isSimple" @input="inputHandler" - @keydown.tab.prevent @keydown.enter.prevent @keydown.esc.prevent + @keydown.tab.prevent + @keydown.enter.prevent + @keydown.esc.prevent > + ref="cascader" + v-else-if="dataType==='cascader'" + :class="`${CSS_PREFIX}-popup`" + :style="popupSty" + v-model="cascader_value" + size="medium" + :options="selectOptions" + @change="selectChange"> + --> @@ -99,9 +101,9 @@