cleared worktype request success/errors on unmount
This commit is contained in:
parent
204e83a2a8
commit
3c5aa92840
|
@ -6,7 +6,9 @@ import { Container, Form, Header, Label, Message } from "semantic-ui-react";
|
||||||
|
|
||||||
import {
|
import {
|
||||||
setFormWorktypeColor,
|
setFormWorktypeColor,
|
||||||
setFormWorktypeLabel
|
setFormWorktypeLabel,
|
||||||
|
clearWorktypeRequestSuccess,
|
||||||
|
clearWorktypeRequestError,
|
||||||
} from "../../actions/worktype/reducer.actions";
|
} from "../../actions/worktype/reducer.actions";
|
||||||
import {
|
import {
|
||||||
updateWorktypeRequest,
|
updateWorktypeRequest,
|
||||||
|
@ -23,6 +25,8 @@ class UpdateWorkTypeForm extends Component {
|
||||||
componentWillUnmount = () => {
|
componentWillUnmount = () => {
|
||||||
this.props.dispatch(setFormWorktypeColor(""));
|
this.props.dispatch(setFormWorktypeColor(""));
|
||||||
this.props.dispatch(setFormWorktypeLabel(""));
|
this.props.dispatch(setFormWorktypeLabel(""));
|
||||||
|
this.props.dispatch(clearWorktypeRequestSuccess());
|
||||||
|
this.props.dispatch(clearWorktypeRequestError());
|
||||||
};
|
};
|
||||||
|
|
||||||
changeColor = color => {
|
changeColor = color => {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user