|
|
@@ -78,7 +78,7 @@ class APIGroupCard extends Component {
|
|
|
frontType,
|
|
|
userDomain,
|
|
|
userStatus,
|
|
|
- groupRegion: region
|
|
|
+ groupRegion: next.region === '' ? region: next.region
|
|
|
})
|
|
|
} else {
|
|
|
this.setState ( {
|
|
|
@@ -88,7 +88,7 @@ class APIGroupCard extends Component {
|
|
|
frontType: 'http&https',
|
|
|
userDomain: '',
|
|
|
userStatus: 'open',
|
|
|
- groupRegion: next.region
|
|
|
+ groupRegion: next.region === '' ? 'ap-beijing' : next.region
|
|
|
});
|
|
|
}
|
|
|
};
|
|
|
@@ -186,6 +186,26 @@ class APIGroupCard extends Component {
|
|
|
<Input value={this.state.groupName} style={{width: 400}}
|
|
|
onChange={this.switchConfig('groupName')}/>
|
|
|
</div>
|
|
|
+
|
|
|
+ <div style={{marginBottom: 10}}>
|
|
|
+ <span className='vice-title'>{valueToKey['region']}
|
|
|
+ <span> </span>
|
|
|
+ <Tooltip placement="top" title={toolTipTitle['region']}>
|
|
|
+ <Icon type="question-circle"/>
|
|
|
+ </Tooltip>
|
|
|
+ </span>
|
|
|
+ <Radio.Group onChange={(e)=>{
|
|
|
+ // 如果不想一变所有都变,就将 onchange 改成
|
|
|
+ // onChange={this.switchConfig('groupRegion')}
|
|
|
+ this.props.switchRegion(e);
|
|
|
+ }} value={removePrefix('ap-', this.state.groupRegion)} buttonStyle="solid">
|
|
|
+ <Radio.Button value="guangzhou">Guangzhou</Radio.Button>
|
|
|
+ <Radio.Button value="shanghai">Shanghai</Radio.Button>
|
|
|
+ <Radio.Button value="beijing">Beijing</Radio.Button>
|
|
|
+ <Radio.Button value="chengdu">Chengdu</Radio.Button>
|
|
|
+ </Radio.Group>
|
|
|
+ </div>
|
|
|
+
|
|
|
<div style={{marginBottom: 10}}>
|
|
|
<span className='vice-title'>{valueToKey['environmentName']}
|
|
|
<span> </span>
|
|
|
@@ -203,20 +223,6 @@ class APIGroupCard extends Component {
|
|
|
<Collapse bordered={false}>
|
|
|
<Panel header="Want more options?" style={customPanelStyle}>
|
|
|
|
|
|
- {/*<div style={{marginBottom: 10}}>*/}
|
|
|
- {/*<span className='vice-title'>{valueToKey['region']}*/}
|
|
|
- {/*<span> </span>*/}
|
|
|
- {/*<Tooltip placement="top" title={toolTipTitle['region']}>*/}
|
|
|
- {/*<Icon type="question-circle"/>*/}
|
|
|
- {/*</Tooltip>*/}
|
|
|
- {/*</span>*/}
|
|
|
- {/*<Radio.Group onChange={this.switchConfig('groupRegion')} value={removePrefix('ap-', this.state.groupRegion)} buttonStyle="solid">*/}
|
|
|
- {/*<Radio.Button value="guangzhou">Guangzhou</Radio.Button>*/}
|
|
|
- {/*<Radio.Button value="shanghai">Shanghai</Radio.Button>*/}
|
|
|
- {/*<Radio.Button value="beijing">Beijing</Radio.Button>*/}
|
|
|
- {/*<Radio.Button value="chengdu">Chengdu</Radio.Button>*/}
|
|
|
- {/*</Radio.Group>*/}
|
|
|
- {/*</div>*/}
|
|
|
<div style={{marginBottom: 10}}>
|
|
|
<span className='vice-title'>{valueToKey['frontType']}
|
|
|
<span> </span>
|