Skip to content

Commit

Permalink
Auto-clear checkboxes in user list view after changing experience dom…
Browse files Browse the repository at this point in the history
…ains (#3178)

* auto-clear checkboxes in user list view after changing experience domains

* update changelog

* update snapshots

* update snapshots
  • Loading branch information
philippotto authored Sep 10, 2018
1 parent 5755da6 commit 703e700
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ For upgrade instructions, please check the [migration guide](MIGRATIONS.md).
- The fallback segmentation layer attribute of volume tracings is now persisted to NML/ZIP files. Upon re-upload, only volume tracings with this attribute will show a fallback layer. Use `tools/volumeAddFallbackLayer.py` to add this attribute to existing volume tracings. [#3088](https://github.com/scalableminds/webknossos/pull/3088)
- When splitting a tree, the split part that contains the initial node will now keep the original tree name and id. [#3145](https://github.com/scalableminds/webknossos/pull/3145)
- The welcome header will now also show on the default page if there are no existing organisations. [#3133](https://github.com/scalableminds/webknossos/pull/3133)
- The checkboxes in the user list view will clear now after the experience domains of users have been changed. [#3178](https://github.com/scalableminds/webknossos/pull/3178)
- Resetting a user's task requires a confirmation now. [#3181](https://github.com/scalableminds/webknossos/pull/3181)

### Fixed
Expand Down
6 changes: 5 additions & 1 deletion app/assets/javascripts/admin/user/user_list_view.js
Original file line number Diff line number Diff line change
Expand Up @@ -244,6 +244,7 @@ class UserListView extends React.PureComponent<Props, State> {
getCheckboxProps: user => ({
disabled: !user.isActive,
}),
selectedRowKeys: this.state.selectedUserIds,
};

const activationFilterWarning = this.state.activationFilter.includes("true") ? (
Expand Down Expand Up @@ -467,7 +468,10 @@ class UserListView extends React.PureComponent<Props, State> {
visible={this.state.isExperienceModalVisible}
selectedUserIds={this.state.selectedUserIds}
users={this.state.users}
onChange={this.handleUsersChange}
onChange={newUsers => {
this.handleUsersChange(newUsers);
this.setState({ selectedUserIds: [] });
}}
onCancel={() => this.setState({ isExperienceModalVisible: false })}
/>
<TeamRoleModalView
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6607,7 +6607,7 @@ Generated by [AVA](https://ava.li).
</Table>␊
</div>␊
</Component>␊
<ExperienceModalView visible={false} selectedUserIds={{...}} users={{...}} onChange={[Function]} onCancel={[Function: onCancel]} />␊
<ExperienceModalView visible={false} selectedUserIds={{...}} users={{...}} onChange={[Function: onChange]} onCancel={[Function: onCancel]} />␊
<TeamRoleModalView visible={false} selectedUserIds={{...}} users={{...}} onChange={[Function]} onCancel={[Function: onCancel]}>␊
<Modal title="Assign Teams" visible={false} onCancel={[Function: onCancel]} footer={{...}} prefixCls="ant-modal" width={520} transitionName="zoom" maskTransitionName="fade" confirmLoading={false} okType="primary">␊
<DialogWrap title="Assign Teams" visible={false} onCancel={[Function: onCancel]} footer={{...}} prefixCls="ant-modal" width={520} transitionName="zoom" maskTransitionName="fade" confirmLoading={false} okType="primary" mousePosition={[undefined]} onClose={[Function]} />␊
Expand Down
Binary file not shown.

0 comments on commit 703e700

Please sign in to comment.