Merge "refactor: Update Label component to support floating ip's icon"
This commit is contained in:
commit
1f99dcfd07
@ -36,6 +36,7 @@ import {
|
|||||||
LoadingOutlined,
|
LoadingOutlined,
|
||||||
TeamOutlined,
|
TeamOutlined,
|
||||||
ProjectOutlined,
|
ProjectOutlined,
|
||||||
|
AimOutlined,
|
||||||
} from '@ant-design/icons';
|
} from '@ant-design/icons';
|
||||||
import styles from './index.less';
|
import styles from './index.less';
|
||||||
|
|
||||||
@ -70,6 +71,7 @@ const iconTypeMap = {
|
|||||||
lb: LBIcon,
|
lb: LBIcon,
|
||||||
group: <TeamOutlined />,
|
group: <TeamOutlined />,
|
||||||
project: <ProjectOutlined />,
|
project: <ProjectOutlined />,
|
||||||
|
floatingIp: <AimOutlined />,
|
||||||
};
|
};
|
||||||
|
|
||||||
export default class index extends Component {
|
export default class index extends Component {
|
||||||
|
@ -12,14 +12,12 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import React from 'react';
|
|
||||||
import { inject, observer } from 'mobx-react';
|
import { inject, observer } from 'mobx-react';
|
||||||
import globalPortForwardingStore from 'stores/neutron/port-forwarding';
|
import globalPortForwardingStore from 'stores/neutron/port-forwarding';
|
||||||
import globalPortStore, { PortStore } from 'stores/neutron/port';
|
import globalPortStore, { PortStore } from 'stores/neutron/port';
|
||||||
import { getCanReachSubnetIdsWithRouterIdInComponent } from 'resources/neutron/router';
|
import { getCanReachSubnetIdsWithRouterIdInComponent } from 'resources/neutron/router';
|
||||||
import { getInterfaceWithReason } from 'resources/neutron/floatingip';
|
import { getInterfaceWithReason } from 'resources/neutron/floatingip';
|
||||||
import { getPortFormItem, getPortsAndReasons } from 'resources/neutron/port';
|
import { getPortFormItem, getPortsAndReasons } from 'resources/neutron/port';
|
||||||
import { DesktopOutlined } from '@ant-design/icons';
|
|
||||||
import { ModalAction } from 'containers/Action';
|
import { ModalAction } from 'containers/Action';
|
||||||
|
|
||||||
export class Edit extends ModalAction {
|
export class Edit extends ModalAction {
|
||||||
@ -204,7 +202,7 @@ export class Edit extends ModalAction {
|
|||||||
name: 'floatingIp',
|
name: 'floatingIp',
|
||||||
label: t('Floating Ip'),
|
label: t('Floating Ip'),
|
||||||
type: 'label',
|
type: 'label',
|
||||||
icon: <DesktopOutlined />,
|
iconType: 'floatingIp',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'protocol',
|
name: 'protocol',
|
||||||
|
@ -14,7 +14,6 @@
|
|||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import { inject, observer } from 'mobx-react';
|
import { inject, observer } from 'mobx-react';
|
||||||
import { DesktopOutlined } from '@ant-design/icons';
|
|
||||||
import { ModalAction } from 'containers/Action';
|
import { ModalAction } from 'containers/Action';
|
||||||
import globalServerStore, { ServerStore } from 'stores/nova/instance';
|
import globalServerStore, { ServerStore } from 'stores/nova/instance';
|
||||||
import globalRouterStore, { RouterStore } from 'stores/neutron/router';
|
import globalRouterStore, { RouterStore } from 'stores/neutron/router';
|
||||||
@ -231,7 +230,7 @@ export class Associate extends ModalAction {
|
|||||||
name: 'floatingIp',
|
name: 'floatingIp',
|
||||||
label: t('Floating Ip'),
|
label: t('Floating Ip'),
|
||||||
type: 'label',
|
type: 'label',
|
||||||
icon: <DesktopOutlined />,
|
iconType: 'floatingIp',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'resourceType',
|
name: 'resourceType',
|
||||||
|
@ -12,9 +12,7 @@
|
|||||||
// See the License for the specific language governing permissions and
|
// See the License for the specific language governing permissions and
|
||||||
// limitations under the License.
|
// limitations under the License.
|
||||||
|
|
||||||
import React from 'react';
|
|
||||||
import { inject, observer } from 'mobx-react';
|
import { inject, observer } from 'mobx-react';
|
||||||
import { DesktopOutlined } from '@ant-design/icons';
|
|
||||||
import { ModalAction } from 'containers/Action';
|
import { ModalAction } from 'containers/Action';
|
||||||
import { isNull } from 'lodash';
|
import { isNull } from 'lodash';
|
||||||
import { getCanReachSubnetIdsWithRouterIdInComponent } from 'resources/neutron/router';
|
import { getCanReachSubnetIdsWithRouterIdInComponent } from 'resources/neutron/router';
|
||||||
@ -142,7 +140,7 @@ export class CreateDNAT extends ModalAction {
|
|||||||
name: 'floatingIp',
|
name: 'floatingIp',
|
||||||
label: t('Floating Ip'),
|
label: t('Floating Ip'),
|
||||||
type: 'label',
|
type: 'label',
|
||||||
icon: <DesktopOutlined />,
|
iconType: 'floatingIp',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'protocol',
|
name: 'protocol',
|
||||||
|
Loading…
Reference in New Issue
Block a user