[WEB-1607[ fix: state dropwdown default state. (#4816)
This commit is contained in:
parent
d1bfed950a
commit
fd9f0fb17c
1 changed files with 1 additions and 1 deletions
|
|
@ -77,7 +77,7 @@ export const StateDropdown: React.FC<Props> = observer((props) => {
|
|||
const { fetchProjectStates, getProjectStates, getStateById } = useProjectState();
|
||||
const statesList = getProjectStates(projectId);
|
||||
const defaultState = statesList?.find((state) => state.default);
|
||||
const stateValue = value ?? (showDefaultState ? defaultState?.id : undefined);
|
||||
const stateValue = !!value ? value : showDefaultState ? defaultState?.id : undefined;
|
||||
|
||||
const options = statesList?.map((state) => ({
|
||||
value: state.id,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue