Change the delete confirmation dialog label.

master
Tom Hacohen 7 years ago
parent 074fc8e6c0
commit e956ef3059

@ -506,6 +506,7 @@ class ContactEdit extends React.PureComponent {
<ConfirmationDialog <ConfirmationDialog
title="Delete Confirmation" title="Delete Confirmation"
labelOk="Delete"
open={this.state.showDeleteDialog} open={this.state.showDeleteDialog}
onOk={() => this.props.onDelete(this.props.item!, this.props.initialCollection!)} onOk={() => this.props.onDelete(this.props.item!, this.props.initialCollection!)}
onCancel={() => this.setState({showDeleteDialog: false})} onCancel={() => this.setState({showDeleteDialog: false})}

@ -282,6 +282,7 @@ class EventEdit extends React.PureComponent {
<ConfirmationDialog <ConfirmationDialog
title="Delete Confirmation" title="Delete Confirmation"
labelOk="Delete"
open={this.state.showDeleteDialog} open={this.state.showDeleteDialog}
onOk={() => this.props.onDelete(this.props.item!, this.props.initialCollection!)} onOk={() => this.props.onDelete(this.props.item!, this.props.initialCollection!)}
onCancel={() => this.setState({showDeleteDialog: false})} onCancel={() => this.setState({showDeleteDialog: false})}

@ -9,6 +9,7 @@ export default pure((_props: any) => {
const { const {
onCancel, onCancel,
onOk, onOk,
labelOk,
...props, ...props,
} = _props; } = _props;
const actions = [ const actions = [
@ -24,7 +25,7 @@ export default pure((_props: any) => {
( (
<FlatButton <FlatButton
key="2" key="2"
label="Submit" label={labelOk || 'Confirm'}
primary={true} primary={true}
onClick={onOk} onClick={onOk}
/> />

Loading…
Cancel
Save