Skip to content

Commit 038763f

Browse files
Merge pull request #4674 from kobotoolbox/release/2.023.37-dda-UI-bug
Fixes reloading page on select all and empty import causing page crash in dynamic data attachments
2 parents e81a9e7 + 15ddb18 commit 038763f

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

jsapp/js/components/dataAttachments/connectProjects.es6

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -375,9 +375,9 @@ class ConnectProjects extends React.Component {
375375
/>
376376

377377
{this.state.fieldsErrors?.source &&
378-
<bem.KoboSelect__errors>
378+
<bem.KoboSelect__error>
379379
{this.state.fieldsErrors?.source}
380-
</bem.KoboSelect__errors>
380+
</bem.KoboSelect__error>
381381
}
382382
</bem.KoboSelect__wrapper>
383383
);

jsapp/js/components/dataAttachments/dataAttachmentColumnsForm.es6

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -91,13 +91,17 @@ class DataAttachmentColumnsForm extends React.Component {
9191
onAttachToSourceCompleted() {
9292
this.props.onModalClose();
9393
}
94-
onBulkSelect() {
94+
onBulkSelect(evt) {
95+
evt.preventDefault();
96+
9597
let newList = this.state.columnsToDisplay.map((item) => {
9698
return {label: item.label, checked: true}
9799
});
98100
this.setState({columnsToDisplay: newList})
99101
}
100-
onBulkDeselect() {
102+
onBulkDeselect(evt) {
103+
evt.preventDefault();
104+
101105
let newList = this.state.columnsToDisplay.map((item) => {
102106
return {label: item.label, checked: false}
103107
});

0 commit comments

Comments
 (0)