mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-11-05 22:20:17 +08:00
17 lines
423 B
JavaScript
17 lines
423 B
JavaScript
export default {
|
|
methods: {
|
|
itemSelected() {
|
|
let item = this.dtComponent.selectedRows.find((item) => {
|
|
return item.id == this.params.id;
|
|
});
|
|
|
|
if (item) {
|
|
this.dtComponent.selectedRows = this.dtComponent.selectedRows.filter((item) => {
|
|
return item.id != this.params.id;
|
|
});
|
|
} else {
|
|
this.dtComponent.selectedRows.push(this.params);
|
|
}
|
|
}
|
|
}
|
|
}
|