Commit c2233d2239973c0cf5ee49f3446380a8377f84b8
1 parent
b6e67986
fix: #251
Showing
1 changed file
with
4 additions
and
5 deletions
front-end/h5/src/components/core/support/excel.js
| ... | ... | @@ -34,11 +34,6 @@ export default { |
| 34 | 34 | } |
| 35 | 35 | } |
| 36 | 36 | }, |
| 37 | - watch: { | |
| 38 | - value () { | |
| 39 | - this.refreshSheet({ rows: this.innerItems }) | |
| 40 | - } | |
| 41 | - }, | |
| 42 | 37 | methods: { |
| 43 | 38 | parseCSV (csv) { |
| 44 | 39 | const sheetData = Parser.binaryMatrix2excel(csv.data) |
| ... | ... | @@ -84,6 +79,10 @@ export default { |
| 84 | 79 | </div> |
| 85 | 80 | }, |
| 86 | 81 | mounted () { |
| 82 | + // fix #251 | |
| 83 | + window.EditorApp.$on('setEditingElement', (ele) => { | |
| 84 | + this.refreshSheet({ rows: this.innerItems }) | |
| 85 | + }) | |
| 87 | 86 | this.sheet = this.initSheet() |
| 88 | 87 | this.refreshSheet({ rows: this.innerItems }) |
| 89 | 88 | } | ... | ... |