|
|
@ -148,6 +148,11 @@ class LifeCycle extends React.Component {
|
|
|
|
render() {
|
|
|
|
render() {
|
|
|
|
const {currentStatus, lifecycle, selectedStatus} = this.state;
|
|
|
|
const {currentStatus, lifecycle, selectedStatus} = this.state;
|
|
|
|
const selectedValue = selectedStatus == null ? [] : selectedStatus;
|
|
|
|
const selectedValue = selectedStatus == null ? [] : selectedStatus;
|
|
|
|
|
|
|
|
let proceedingStates = [];
|
|
|
|
|
|
|
|
if((lifecycle.hasOwnProperty(currentStatus)) && lifecycle[currentStatus].hasOwnProperty("proceedingStates")){
|
|
|
|
|
|
|
|
proceedingStates = lifecycle[currentStatus].proceedingStates;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
console.log(lifecycle);
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<div>
|
|
|
|
<div>
|
|
|
|
<Title level={4}>Manage Lifecycle</Title>
|
|
|
|
<Title level={4}>Manage Lifecycle</Title>
|
|
|
@ -169,11 +174,9 @@ class LifeCycle extends React.Component {
|
|
|
|
value={selectedValue}
|
|
|
|
value={selectedValue}
|
|
|
|
showSearch={true}
|
|
|
|
showSearch={true}
|
|
|
|
>
|
|
|
|
>
|
|
|
|
{
|
|
|
|
{proceedingStates.map(lifecycleState => {
|
|
|
|
Object.keys(lifecycle).map(lifecycleState => {
|
|
|
|
|
|
|
|
return (
|
|
|
|
return (
|
|
|
|
<Option
|
|
|
|
<Option
|
|
|
|
disabled={!(lifecycle[currentStatus].proceedingStates.includes(lifecycleState))}
|
|
|
|
|
|
|
|
key={lifecycleState}
|
|
|
|
key={lifecycleState}
|
|
|
|
value={lifecycleState}>
|
|
|
|
value={lifecycleState}>
|
|
|
|
{lifecycleState}
|
|
|
|
{lifecycleState}
|
|
|
|