diff --git a/src/components/Form/index.jsx b/src/components/Form/index.jsx
index 4254b21f..b06fb289 100644
--- a/src/components/Form/index.jsx
+++ b/src/components/Form/index.jsx
@@ -175,18 +175,30 @@ export default class BaseForm extends React.Component {
}
get successText() {
+ if (this.instanceName) {
+ return firstUpperCase(
+ t('{action} successfully, instance: {name}.', {
+ action: this.name.toLowerCase(),
+ name: this.instanceName,
+ })
+ );
+ }
return firstUpperCase(
- t('{action} successfully, instance: {name}.', {
+ t('{action} successfully.', {
action: this.name.toLowerCase(),
- name: this.instanceName,
})
);
}
get errorText() {
- return t('Unable to {action}, instance: {name}.', {
+ if (this.instanceName) {
+ return t('Unable to {action}, instance: {name}.', {
+ action: this.name.toLowerCase(),
+ name: this.instanceName,
+ });
+ }
+ return t('Unable to {action}.', {
action: this.name.toLowerCase(),
- name: this.instanceName,
});
}
diff --git a/src/components/StepForm/index.jsx b/src/components/StepForm/index.jsx
index a7e02ab0..efdfd6cb 100644
--- a/src/components/StepForm/index.jsx
+++ b/src/components/StepForm/index.jsx
@@ -148,18 +148,30 @@ export default class BaseStepForm extends React.Component {
}
get successText() {
+ if (this.instanceName) {
+ return firstUpperCase(
+ t('{action} successfully, instance: {name}.', {
+ action: this.name.toLowerCase(),
+ name: this.instanceName,
+ })
+ );
+ }
return firstUpperCase(
- t('{action} successfully, instance: {name}.', {
+ t('{action} successfully.', {
action: this.name.toLowerCase(),
- name: this.instanceName,
})
);
}
get errorText() {
- return t('Unable to {action}, instance: {name}.', {
+ if (this.instanceName) {
+ return t('Unable to {action}, instance: {name}.', {
+ action: this.name.toLowerCase(),
+ name: this.instanceName,
+ });
+ }
+ return t('Unable to {action}.', {
action: this.name.toLowerCase(),
- name: this.instanceName,
});
}
diff --git a/src/containers/Action/ConfirmAction/index.jsx b/src/containers/Action/ConfirmAction/index.jsx
index 374ff6df..df98b7c0 100644
--- a/src/containers/Action/ConfirmAction/index.jsx
+++ b/src/containers/Action/ConfirmAction/index.jsx
@@ -89,12 +89,14 @@ export default class ConfirmAction {
unescape = (message) => unescapeHtml(message);
- getNameOne = (data) => data.name;
+ getItemId = (data) => data.id;
+
+ getItemName = (data) => data.name || `- (${this.getItemId(data)})`;
getName = (data) =>
isArray(data)
- ? data.map((it) => this.getNameOne(it)).join(', ')
- : this.getNameOne(data);
+ ? data.map((it) => this.getItemName(it)).join(', ')
+ : this.getItemName(data);
// eslint-disable-next-line no-unused-vars
allowedCheckFunc = (data) => true;
@@ -154,7 +156,14 @@ export default class ConfirmAction {
);
};
- performErrorMsg = (data) => {
+ performErrorMsg = (data, isBatch) => {
+ if (isBatch) {
+ if (!this.messageHasItemName) {
+ return '';
+ }
+ const name = this.getName(data);
+ return t('instance: {name}.', { name });
+ }
if (!this.messageHasItemName) {
return t('You are not allowed to {action}.', {
action: this.actionNameDisplay || this.title,
@@ -184,8 +193,14 @@ export default class ConfirmAction {
onSubmit = (data) => Promise.resolve();
getBatchPerformTitle() {
+ if (this.messageHasItemName) {
+ return t(
+ 'There are resources that cannot {action} in the selected resources, such as:',
+ { action: this.passiveAction.toLowerCase() }
+ );
+ }
return t(
- 'There are resources that cannot {action} in the selected resources, such as:',
+ 'There are resources that cannot {action} in the selected resources.',
{ action: this.passiveAction.toLowerCase() }
);
}
@@ -208,7 +223,7 @@ export default class ConfirmAction {
failedItems.push(items[index]);
}
});
- const errorMsg = this.unescape(this.performErrorMsg(failedItems));
+ const errorMsg = this.unescape(this.performErrorMsg(failedItems, true));
const title = this.getBatchPerformTitle();
const msg = (
diff --git a/src/containers/Action/ModalAction/index.jsx b/src/containers/Action/ModalAction/index.jsx
index e5651efb..a0fa345b 100644
--- a/src/containers/Action/ModalAction/index.jsx
+++ b/src/containers/Action/ModalAction/index.jsx
@@ -70,7 +70,7 @@ export default class ModalAction extends BaseForm {
}
get instanceName() {
- return this.item.name || this.values.name;
+ return (this.item || {}).name || (this.values || {}).name;
}
get isAsyncAction() {
diff --git a/src/locales/en.json b/src/locales/en.json
index 7189e567..3eedf04c 100644
--- a/src/locales/en.json
+++ b/src/locales/en.json
@@ -238,7 +238,6 @@
"Click to show detail": "Click to show detail",
"Clone Volume": "Clone Volume",
"Clone volume": "Clone volume",
- "Close": "Close",
"Close External Gateway": "Close External Gateway",
"Close all notifications.": "Close all notifications.",
"Close external gateway": "Close external gateway",
@@ -1039,7 +1038,6 @@
"One entry per line(e.g. {ip})": "One entry per line(e.g. {ip})",
"Online Resize": "Online Resize",
"Only a MAC address or an OpenFlow based datapath_id of the switch are accepted in this field": "Only a MAC address or an OpenFlow based datapath_id of the switch are accepted in this field",
- "Open": "Open",
"Open External Gateway": "Open External Gateway",
"Operating Status": "Operating Status",
"Operating System": "Operating System",
@@ -1553,6 +1551,7 @@
"The {action} instruction has been issued, instance: {name}. \n You can wait for a few seconds to follow the changes of the list data or manually refresh the data to get the final display result.": "The {action} instruction has been issued, instance: {name}. \n You can wait for a few seconds to follow the changes of the list data or manually refresh the data to get the final display result.",
"The {action} instruction has been issued. \n You can wait for a few seconds to follow the changes of the list data or manually refresh the data to get the final display result.": "The {action} instruction has been issued. \n You can wait for a few seconds to follow the changes of the list data or manually refresh the data to get the final display result.",
"There are resources that cannot {action} in the selected resources, such as:": "There are resources that cannot {action} in the selected resources, such as:",
+ "There are resources that cannot {action} in the selected resources.": "There are resources that cannot {action} in the selected resources.",
"There are resources under the project and cannot be deleted.": "There are resources under the project and cannot be deleted.",
"This service will automatically query the configuration (CPU, memory, etc.) and mac address of the physical machine, and the ironic-inspector service will automatically register this information in the node information.": "This service will automatically query the configuration (CPU, memory, etc.) and mac address of the physical machine, and the ironic-inspector service will automatically register this information in the node information.",
"This will delete all child objects of the load balancer.": "This will delete all child objects of the load balancer.",
@@ -1577,8 +1576,6 @@
"USER": "USER",
"UUID": "UUID",
"Ubuntu": "Ubuntu",
- "Unable to batch {action} {name}.": "Unable to batch {action} {name}.",
- "Unable to batch {action}, instance: {name}.": "Unable to batch {action}, instance: {name}.",
"Unable to create instance: batch creation is not supported when specifying IP.": "Unable to create instance: batch creation is not supported when specifying IP.",
"Unable to create instance: insufficient quota to create resources.": "Unable to create instance: insufficient quota to create resources.",
"Unable to create volume: insufficient quota to create resources.": "Unable to create volume: insufficient quota to create resources.",
@@ -1854,6 +1851,7 @@
"ingress": "ingress",
"instance": "instance",
"instance snapshot": "instance snapshot",
+ "instance: {name}.": "instance: {name}.",
"instances": "instances",
"jump to the console": "jump to the console",
"keypair": "keypair",
diff --git a/src/locales/zh.json b/src/locales/zh.json
index 80b609c5..72868b7f 100644
--- a/src/locales/zh.json
+++ b/src/locales/zh.json
@@ -238,7 +238,6 @@
"Click to show detail": "点击查看详情",
"Clone Volume": "克隆云硬盘",
"Clone volume": "克隆云硬盘",
- "Close": "关闭",
"Close External Gateway": "关闭公网网关",
"Close all notifications.": "关闭所有消息提示",
"Close external gateway": "关闭公网网关",
@@ -1039,7 +1038,6 @@
"One entry per line(e.g. {ip})": "每行一条(例如: {ip})",
"Online Resize": "在线修改配置",
"Only a MAC address or an OpenFlow based datapath_id of the switch are accepted in this field": "只可填写交换机的Mac地址或者交换机基于openflow的数据路径ID",
- "Open": "开",
"Open External Gateway": "开启公网网关",
"Operating Status": "操作状态",
"Operating System": "操作系统",
@@ -1553,6 +1551,7 @@
"The {action} instruction has been issued, instance: {name}. \n You can wait for a few seconds to follow the changes of the list data or manually refresh the data to get the final display result.": "{action}指令已下发,实例名称:{name}。 \n 您可等待几秒关注列表数据的变更或是手动刷新数据,以获取最终展示结果。",
"The {action} instruction has been issued. \n You can wait for a few seconds to follow the changes of the list data or manually refresh the data to get the final display result.": "{action}指令已下发。 \n 您可等待几秒关注列表数据的变更或是手动刷新数据,以获取最终展示结果。",
"There are resources that cannot {action} in the selected resources, such as:": "您选中的资源中有无法{action}的资源,如:",
+ "There are resources that cannot {action} in the selected resources.": "您选中的资源中有无法{action}的资源。",
"There are resources under the project and cannot be deleted.": "项目下存在资源,无法执行删除操作。",
"This service will automatically query the configuration (CPU, memory, etc.) and mac address of the physical machine, and the ironic-inspector service will automatically register this information in the node information.": "此服务将对在对物理机的配置(CPU、内存等)和 mac 地址进行自动查询, 并且 ironic-inspector 服务会将这些信息自动注册入节点信息中。",
"This will delete all child objects of the load balancer.": "这会删除所有LB下的资源",
@@ -1577,8 +1576,6 @@
"USER": "用户",
"UUID": "",
"Ubuntu": "",
- "Unable to batch {action} {name}.": "无法批量{action} {name}。",
- "Unable to batch {action}, instance: {name}.": "无法批量{action},实例名称:{name}。",
"Unable to create instance: batch creation is not supported when specifying IP.": "无法创建云主机:指定IP时,不支持批量创建云主机。",
"Unable to create instance: insufficient quota to create resources.": "无法创建云主机:超过配额。",
"Unable to create volume: insufficient quota to create resources.": "无法创建云硬盘:超过配额。",
@@ -1854,6 +1851,7 @@
"ingress": "入方向",
"instance": "云主机",
"instance snapshot": "云主机快照",
+ "instance: {name}.": "实例名称:{name}。",
"instances": "云主机",
"jump to the console": "跳转到控制台",
"keypair": "密钥",
diff --git a/src/pages/compute/containers/BareMetalNode/Detail/Port/actions/Delete.jsx b/src/pages/compute/containers/BareMetalNode/Detail/Port/actions/Delete.jsx
index 70a3c9a3..218655b1 100644
--- a/src/pages/compute/containers/BareMetalNode/Detail/Port/actions/Delete.jsx
+++ b/src/pages/compute/containers/BareMetalNode/Detail/Port/actions/Delete.jsx
@@ -42,7 +42,7 @@ export default class Delete extends ConfirmAction {
policy = 'baremetal:port:delete';
- getNameOne = (data) => data.name || data.uuid;
+ getItemId = (data) => data.uuid;
allowedCheckFunc = () => true;
diff --git a/src/pages/compute/containers/BareMetalNode/Detail/PortGroup/actions/Delete.jsx b/src/pages/compute/containers/BareMetalNode/Detail/PortGroup/actions/Delete.jsx
index 384df2c2..b8935394 100644
--- a/src/pages/compute/containers/BareMetalNode/Detail/PortGroup/actions/Delete.jsx
+++ b/src/pages/compute/containers/BareMetalNode/Detail/PortGroup/actions/Delete.jsx
@@ -42,7 +42,7 @@ export default class Delete extends ConfirmAction {
policy = 'baremetal:portgroup:delete';
- getNameOne = (data) => data.name || data.uuid;
+ getItemId = (data) => data.uuid;
allowedCheckFunc = () => true;
diff --git a/src/pages/compute/containers/BareMetalNode/actions/ClearMaintenance.jsx b/src/pages/compute/containers/BareMetalNode/actions/ClearMaintenance.jsx
index afd36352..1b230e5d 100644
--- a/src/pages/compute/containers/BareMetalNode/actions/ClearMaintenance.jsx
+++ b/src/pages/compute/containers/BareMetalNode/actions/ClearMaintenance.jsx
@@ -30,7 +30,7 @@ export default class ClearMaintenance extends ConfirmAction {
policy = 'baremetal:node:clear_maintenance';
- getNameOne = (data) => data.name || data.uuid;
+ getItemId = (data) => data.uuid;
allowedCheckFunc = (item) => item.maintenance;
diff --git a/src/pages/compute/containers/BareMetalNode/actions/Delete.jsx b/src/pages/compute/containers/BareMetalNode/actions/Delete.jsx
index d25cbf19..42041d10 100644
--- a/src/pages/compute/containers/BareMetalNode/actions/Delete.jsx
+++ b/src/pages/compute/containers/BareMetalNode/actions/Delete.jsx
@@ -42,7 +42,7 @@ export default class Delete extends ConfirmAction {
policy = 'baremetal:node:delete';
- getNameOne = (data) => data.name || data.uuid;
+ getItemId = (data) => data.uuid;
allowedCheckFunc = () => true;
diff --git a/src/pages/compute/containers/BareMetalNode/actions/Inspect.jsx b/src/pages/compute/containers/BareMetalNode/actions/Inspect.jsx
index 8552dc3a..328779dc 100644
--- a/src/pages/compute/containers/BareMetalNode/actions/Inspect.jsx
+++ b/src/pages/compute/containers/BareMetalNode/actions/Inspect.jsx
@@ -31,7 +31,7 @@ export default class Inspect extends ConfirmAction {
policy = 'baremetal:node:set_provision_state';
- getNameOne = (data) => data.name || data.uuid;
+ getItemId = (data) => data.uuid;
allowedCheckFunc = (item) => item.provision_state === 'manageable';
diff --git a/src/pages/compute/containers/BareMetalNode/actions/PowerOff.jsx b/src/pages/compute/containers/BareMetalNode/actions/PowerOff.jsx
index 75e0b8d2..03f911b6 100644
--- a/src/pages/compute/containers/BareMetalNode/actions/PowerOff.jsx
+++ b/src/pages/compute/containers/BareMetalNode/actions/PowerOff.jsx
@@ -34,7 +34,7 @@ export default class PowerOn extends ConfirmAction {
policy = 'baremetal:node:set_power_state';
- getNameOne = (data) => data.name || data.uuid;
+ getItemId = (data) => data.uuid;
allowedCheckFunc = (item) => item.power_state === 'power off';
diff --git a/src/pages/compute/containers/BareMetalNode/actions/PowerOn.jsx b/src/pages/compute/containers/BareMetalNode/actions/PowerOn.jsx
index 9b9366d0..6ed3b488 100644
--- a/src/pages/compute/containers/BareMetalNode/actions/PowerOn.jsx
+++ b/src/pages/compute/containers/BareMetalNode/actions/PowerOn.jsx
@@ -34,7 +34,7 @@ export default class PowerOff extends ConfirmAction {
policy = 'baremetal:node:set_power_state';
- getNameOne = (data) => data.name || data.uuid;
+ getItemId = (data) => data.uuid;
allowedCheckFunc = (item) => item.power_state === 'power on';
diff --git a/src/pages/compute/containers/Hypervisors/ComputeHost/actions/Enable.jsx b/src/pages/compute/containers/Hypervisors/ComputeHost/actions/Enable.jsx
index 17917050..1c1cb0d9 100644
--- a/src/pages/compute/containers/Hypervisors/ComputeHost/actions/Enable.jsx
+++ b/src/pages/compute/containers/Hypervisors/ComputeHost/actions/Enable.jsx
@@ -28,7 +28,7 @@ export default class EnableAction extends ConfirmAction {
return t('Enable');
}
- getNameOne = (data) => data.host;
+ getItemName = (data) => data.host;
get actionName() {
return t('Enable compute host');
diff --git a/src/pages/configuration/containers/Setting/actions/Reset.jsx b/src/pages/configuration/containers/Setting/actions/Reset.jsx
index c9a89024..f93a1f94 100644
--- a/src/pages/configuration/containers/Setting/actions/Reset.jsx
+++ b/src/pages/configuration/containers/Setting/actions/Reset.jsx
@@ -32,7 +32,7 @@ export default class Reset extends ConfirmAction {
return t('Reset To Initial Value');
}
- getNameOne = (data) => data.key;
+ getItemName = (data) => data.key;
policy = 'skyline:system_admin';
diff --git a/src/pages/configuration/containers/SystemInfo/CinderService/actions/Enable.jsx b/src/pages/configuration/containers/SystemInfo/CinderService/actions/Enable.jsx
index 8bc29ef7..d0f36416 100644
--- a/src/pages/configuration/containers/SystemInfo/CinderService/actions/Enable.jsx
+++ b/src/pages/configuration/containers/SystemInfo/CinderService/actions/Enable.jsx
@@ -36,7 +36,7 @@ export default class Enable extends ConfirmAction {
return t('enable cinder service');
}
- getName = (data) => data.binary;
+ getItemName = (data) => data.binary;
policy = 'volume_extension:services:update';
diff --git a/src/pages/configuration/containers/SystemInfo/ComputeService/actions/Enable.jsx b/src/pages/configuration/containers/SystemInfo/ComputeService/actions/Enable.jsx
index 5fe9f4d5..48aefb17 100644
--- a/src/pages/configuration/containers/SystemInfo/ComputeService/actions/Enable.jsx
+++ b/src/pages/configuration/containers/SystemInfo/ComputeService/actions/Enable.jsx
@@ -28,7 +28,7 @@ export default class EnableAction extends ConfirmAction {
return t('Enable');
}
- getName = (data) => data.host;
+ getItemName = (data) => data.host;
get actionName() {
return t('enable compute service');
diff --git a/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Disable.jsx b/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Disable.jsx
index 1697e15e..e882fe2a 100644
--- a/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Disable.jsx
+++ b/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Disable.jsx
@@ -36,7 +36,7 @@ export default class Disable extends ConfirmAction {
return t('disable neutron agent');
}
- getName = (data) => data.binary;
+ getItemName = (data) => data.binary;
policy = 'update_agent';
diff --git a/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Enable.jsx b/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Enable.jsx
index 4e9ccf4a..940bf886 100644
--- a/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Enable.jsx
+++ b/src/pages/configuration/containers/SystemInfo/NeutronAgent/actions/Enable.jsx
@@ -36,7 +36,7 @@ export default class Enable extends ConfirmAction {
return t('enable neutron agent');
}
- getName = (data) => data.binary;
+ getItemName = (data) => data.binary;
policy = 'update_agent';
diff --git a/src/pages/network/containers/FloatingIp/Detail/PortForwarding/actions/Delete.jsx b/src/pages/network/containers/FloatingIp/Detail/PortForwarding/actions/Delete.jsx
index d08b0d33..c3f390bb 100644
--- a/src/pages/network/containers/FloatingIp/Detail/PortForwarding/actions/Delete.jsx
+++ b/src/pages/network/containers/FloatingIp/Detail/PortForwarding/actions/Delete.jsx
@@ -38,7 +38,7 @@ export default class DeleteAction extends ConfirmAction {
policy = 'delete_floatingip_port_forwarding';
- getNameOne = (data) => {
+ getItemName = (data) => {
const {
floating_ip_address,
external_port,
diff --git a/src/pages/network/containers/FloatingIp/actions/Disassociate.js b/src/pages/network/containers/FloatingIp/actions/Disassociate.js
index 860a145c..55f62cdd 100644
--- a/src/pages/network/containers/FloatingIp/actions/Disassociate.js
+++ b/src/pages/network/containers/FloatingIp/actions/Disassociate.js
@@ -38,7 +38,7 @@ export default class Release extends ConfirmAction {
allowedCheckFunc = (item) =>
!_.isNull(item.fixed_ip_address) && item.status !== 'DOWN';
- getNameOne = (data) => data.floating_ip_address;
+ getItemName = (data) => data.floating_ip_address;
onSubmit = (value) => globalFloatingIpsStore.disassociateFip(value);
}
diff --git a/src/pages/network/containers/FloatingIp/actions/Release.jsx b/src/pages/network/containers/FloatingIp/actions/Release.jsx
index f16ea488..e15257ae 100644
--- a/src/pages/network/containers/FloatingIp/actions/Release.jsx
+++ b/src/pages/network/containers/FloatingIp/actions/Release.jsx
@@ -41,7 +41,7 @@ export default class Release extends ConfirmAction {
policy = 'delete_floatingip';
- getNameOne = (data) => data.floating_ip_address;
+ getItemName = (data) => data.floating_ip_address;
onChangeType(choosed, data) {
if (isArray(data)) {
diff --git a/src/pages/network/containers/Router/StaticRouter/actions/Delete.jsx b/src/pages/network/containers/Router/StaticRouter/actions/Delete.jsx
index 3cf0e8cc..b4a83593 100644
--- a/src/pages/network/containers/Router/StaticRouter/actions/Delete.jsx
+++ b/src/pages/network/containers/Router/StaticRouter/actions/Delete.jsx
@@ -38,7 +38,7 @@ export default class DeleteAction extends ConfirmAction {
policy = 'update_router';
- getNameOne = (data) => {
+ getItemName = (data) => {
const { destination, nexthop } = data;
return `${destination}(${nexthop})`;
};
diff --git a/src/pages/network/containers/SecurityGroup/Detail/Rule/actions/Delete.jsx b/src/pages/network/containers/SecurityGroup/Detail/Rule/actions/Delete.jsx
index ecb763b1..53992ff8 100644
--- a/src/pages/network/containers/SecurityGroup/Detail/Rule/actions/Delete.jsx
+++ b/src/pages/network/containers/SecurityGroup/Detail/Rule/actions/Delete.jsx
@@ -38,7 +38,7 @@ export default class DeleteAction extends ConfirmAction {
policy = 'delete_security_group_rule';
- getNameOne = (item) => {
+ getItemName = (item) => {
if (item.name) {
return item.name;
}
diff --git a/src/pages/network/containers/VirtualAdapter/Detail/AllowedAddressPair/actions/Delete.jsx b/src/pages/network/containers/VirtualAdapter/Detail/AllowedAddressPair/actions/Delete.jsx
index 262539bc..5ae872c9 100644
--- a/src/pages/network/containers/VirtualAdapter/Detail/AllowedAddressPair/actions/Delete.jsx
+++ b/src/pages/network/containers/VirtualAdapter/Detail/AllowedAddressPair/actions/Delete.jsx
@@ -37,7 +37,7 @@ export default class DeleteAction extends ConfirmAction {
return t('delete allowed address pair');
}
- getNameOne = (data) => data.ip_address;
+ getItemName = (data) => data.ip_address;
policy = 'update_port';
diff --git a/src/pages/network/containers/VirtualAdapter/Detail/FixedIPs/actions/ReleaseIP.jsx b/src/pages/network/containers/VirtualAdapter/Detail/FixedIPs/actions/ReleaseIP.jsx
index 4382755a..ffcbca8b 100644
--- a/src/pages/network/containers/VirtualAdapter/Detail/FixedIPs/actions/ReleaseIP.jsx
+++ b/src/pages/network/containers/VirtualAdapter/Detail/FixedIPs/actions/ReleaseIP.jsx
@@ -40,7 +40,7 @@ export default class DeleteAction extends ConfirmAction {
return t('be released');
}
- getNameOne = (data) => data.ip_address;
+ getItemName = (data) => data.ip_address;
policy = 'update_port';
diff --git a/src/pages/network/containers/VirtualAdapter/actions/Delete.jsx b/src/pages/network/containers/VirtualAdapter/actions/Delete.jsx
index a343d9f6..3a9f96ca 100644
--- a/src/pages/network/containers/VirtualAdapter/actions/Delete.jsx
+++ b/src/pages/network/containers/VirtualAdapter/actions/Delete.jsx
@@ -36,8 +36,6 @@ export default class DeleteAction extends ConfirmAction {
return t('delete virtual adapter');
}
- getNameOne = (data) => data.name || data.id;
-
policy = 'delete_port';
allowedCheckFunc = (item) => {
diff --git a/src/pages/network/containers/VirtualAdapter/actions/Detach.jsx b/src/pages/network/containers/VirtualAdapter/actions/Detach.jsx
index ff9431e0..ffe3be88 100644
--- a/src/pages/network/containers/VirtualAdapter/actions/Detach.jsx
+++ b/src/pages/network/containers/VirtualAdapter/actions/Detach.jsx
@@ -39,8 +39,6 @@ export default class Detach extends ConfirmAction {
policy = 'os_compute_api:os-attach-interfaces:delete';
- getNameOne = (data) => data.name || data.id;
-
hasMoreInterfaces(instance) {
let count = 0;
const { addresses } = instance;
diff --git a/src/pages/storage/containers/Volume/actions/Delete.jsx b/src/pages/storage/containers/Volume/actions/Delete.jsx
index 7237d6ea..f40f3c67 100644
--- a/src/pages/storage/containers/Volume/actions/Delete.jsx
+++ b/src/pages/storage/containers/Volume/actions/Delete.jsx
@@ -42,8 +42,6 @@ export default class DeleteAction extends ConfirmAction {
policy = 'volume:delete';
- getNameOne = (data) => data.name || data.id;
-
canDelete = (item) =>
['available', 'error', 'error_extending'].indexOf(item.status) >= 0;