Moti Asayag has uploaded a new change for review. Change subject: webadmin: Add Network to add role dialog ......................................................................
webadmin: Add Network to add role dialog The patch adds the Network as a main entity for creation of custom role or for presenting predefined role in the role dialog. Network entity is positioned in the same location as main-tabs are organized. Change-Id: I86243bdd22679ae4cd25be647acd4a56cd0b601f Signed-off-by: Moti Asayag <[email protected]> --- M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/PermissionListModel.java M frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/roles_ui/RoleTreeView.java M frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/Constants.java M frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/LocalizedEnums.java M frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_es.properties M frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_fr.properties M frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_ja.properties M frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_zh_CN.properties M frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/LocalizedEnums.properties 9 files changed, 83 insertions(+), 26 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/36/9536/1 diff --git a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/PermissionListModel.java b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/PermissionListModel.java index edd9e61..64d4a29 100644 --- a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/PermissionListModel.java +++ b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/PermissionListModel.java @@ -8,14 +8,15 @@ import org.ovirt.engine.core.common.action.VdcActionType; import org.ovirt.engine.core.common.businessentities.DbUser; import org.ovirt.engine.core.common.businessentities.DiskImage; +import org.ovirt.engine.core.common.businessentities.NetworkView; import org.ovirt.engine.core.common.businessentities.Quota; +import org.ovirt.engine.core.common.businessentities.Role; import org.ovirt.engine.core.common.businessentities.VDS; import org.ovirt.engine.core.common.businessentities.VDSGroup; import org.ovirt.engine.core.common.businessentities.VM; import org.ovirt.engine.core.common.businessentities.VmTemplate; import org.ovirt.engine.core.common.businessentities.ad_groups; import org.ovirt.engine.core.common.businessentities.permissions; -import org.ovirt.engine.core.common.businessentities.Role; import org.ovirt.engine.core.common.businessentities.storage_domains; import org.ovirt.engine.core.common.businessentities.storage_pool; import org.ovirt.engine.core.common.businessentities.vm_pools; @@ -398,6 +399,9 @@ if (getEntity() instanceof DiskImage) { return VdcObjectType.Disk; } + if (getEntity() instanceof NetworkView) { + return VdcObjectType.Network; + } return VdcObjectType.Unknown; } diff --git a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/roles_ui/RoleTreeView.java b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/roles_ui/RoleTreeView.java index 1f60c78..77e44af 100644 --- a/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/roles_ui/RoleTreeView.java +++ b/frontend/webadmin/modules/uicommonweb/src/main/java/org/ovirt/engine/ui/uicommonweb/models/configure/roles_ui/RoleTreeView.java @@ -158,11 +158,48 @@ new RoleNode(ActionGroup.EDIT_STORAGE_POOL_CONFIGURATION, ConstantsManager.getInstance() .getConstants() - .allowToModifyDataCenterPropertiesRoleTreeTooltip()), - new RoleNode(ActionGroup.CONFIGURE_STORAGE_POOL_NETWORK, - ConstantsManager.getInstance() - .getConstants() - .allowToConfigureLogicalNetworkPerDataCenterRoleTreeTooltip()) })), + .allowToModifyDataCenterPropertiesRoleTreeTooltip()) })), + new RoleNode(ConstantsManager.getInstance().getConstants().networkRoleTree(), + new RoleNode[] { + new RoleNode(ConstantsManager.getInstance() + .getConstants() + .configureNetworkRoleTree(), + new RoleNode[] { + new RoleNode(ActionGroup.CREATE_STORAGE_POOL_NETWORK, + ConstantsManager.getInstance() + .getConstants() + .allowToCreateLogicalNetworkPerDataCenterRoleTreeTooltip()), + new RoleNode(ActionGroup.CONFIGURE_STORAGE_POOL_NETWORK, + ConstantsManager.getInstance() + .getConstants() + .allowToEditLogicalNetworkRoleTreeTooltip()), + new RoleNode(ActionGroup.DELETE_STORAGE_POOL_NETWORK, + ConstantsManager.getInstance() + .getConstants() + .allowToDeleteLogicalNetworkRoleTreeTooltip()), + new RoleNode(ActionGroup.ASSIGN_CLUSTER_NETWORK, + ConstantsManager.getInstance() + .getConstants() + .allowToAddRemoveLogicalNetworksForTheClusterRoleTreeTooltip()), + new RoleNode(ActionGroup.CONFIGURE_VM_NETWORK, + ConstantsManager.getInstance() + .getConstants() + .allowToConfigureVMsNetworkRoleTreeTooltip()), + new RoleNode(ActionGroup.CONFIGURE_TEMPLATE_NETWORK, + ConstantsManager.getInstance() + .getConstants() + .allowToConfigureTemlateNetworkRoleTreeTooltip()) }), + new RoleNode(ConstantsManager.getInstance() + .getConstants() + .administrationOperationsRoleTree(), + ConstantsManager.getInstance() + .getConstants() + .notePermissionsContainigTheseOperationsShuoldAssociatNetworkOrEqualRoleTreeTooltip(), + new RoleNode[] { + new RoleNode(ActionGroup.PORT_MIRRORING, + ConstantsManager.getInstance() + .getConstants() + .allowVmNetworkPortMirroringRoleTreeTooltip()) }) }), new RoleNode(ConstantsManager.getInstance().getConstants().storageDomainRoleTree(), new RoleNode(ConstantsManager.getInstance() .getConstants() @@ -204,7 +241,7 @@ new RoleNode(ActionGroup.CONFIGURE_CLUSTER_NETWORK, ConstantsManager.getInstance() .getConstants() - .allowToAddRemoveLogicalNetworksForTheClusterRoleTreeTooltip()) })), + .allowToEditLogicalNetworksForTheClusterRoleTreeTooltip()) })), new RoleNode(ConstantsManager.getInstance().getConstants().glusterRoleTree(), new RoleNode(ConstantsManager.getInstance() .getConstants() @@ -252,11 +289,7 @@ new RoleNode(ActionGroup.EDIT_TEMPLATE_PROPERTIES, ConstantsManager.getInstance() .getConstants() - .allowToChangeTemplatePropertiesRoleTreeTooltip()), - new RoleNode(ActionGroup.CONFIGURE_TEMPLATE_NETWORK, - ConstantsManager.getInstance() - .getConstants() - .allowToConfigureTemlateNetworkRoleTreeTooltip()) }), + .allowToChangeTemplatePropertiesRoleTreeTooltip()) }), new RoleNode(ConstantsManager.getInstance() .getConstants() .provisioningOperationsRoleTree(), @@ -321,10 +354,6 @@ ConstantsManager.getInstance() .getConstants() .allowImportExportOperationsRoleTreeTooltip()), - new RoleNode(ActionGroup.CONFIGURE_VM_NETWORK, - ConstantsManager.getInstance() - .getConstants() - .allowToConfigureVMsNetworkRoleTreeTooltip()), new RoleNode(ActionGroup.CONFIGURE_VM_STORAGE, ConstantsManager.getInstance() .getConstants() diff --git a/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/Constants.java b/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/Constants.java index 8d22841..008d747 100644 --- a/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/Constants.java +++ b/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/Constants.java @@ -962,8 +962,14 @@ @DefaultStringValue("Allow to modify Data Center properties") String allowToModifyDataCenterPropertiesRoleTreeTooltip(); - @DefaultStringValue("Allow to configure Logical Network per Data Center") - String allowToConfigureLogicalNetworkPerDataCenterRoleTreeTooltip(); + @DefaultStringValue("Allow to edit Logical Network's properties") + String allowToEditLogicalNetworkRoleTreeTooltip(); + + @DefaultStringValue("Allow to create Logical Network per Data Center") + String allowToCreateLogicalNetworkPerDataCenterRoleTreeTooltip(); + + @DefaultStringValue("Allow to delete Logical Network") + String allowToDeleteLogicalNetworkRoleTreeTooltip(); @DefaultStringValue("Allow to create Storage Domain") String allowToCreateStorageDomainRoleTreeTooltip(); @@ -988,6 +994,9 @@ @DefaultStringValue("Allow to add/remove Logical Networks for the Cluster (from the list of Networks defined by the Data Center)") String allowToAddRemoveLogicalNetworksForTheClusterRoleTreeTooltip(); + + @DefaultStringValue("Allow to edit Logical Networks properties within the Cluster (e.g. non-required or display network)") + String allowToEditLogicalNetworksForTheClusterRoleTreeTooltip(); @DefaultStringValue("Allow to add new Host to the Cluster") String allowToAddNewHostToTheClusterRoleTreeTooltip(); @@ -1063,6 +1072,9 @@ @DefaultStringValue("note: Permissions containing these operations should be associated with Data Center Object (or equivalent)") String notePermissionsContainigTheseOperationsShuoldAssociatDcOrEqualRoleTreeTooltip(); + + @DefaultStringValue("note: Permissions containing these operations should be associated with Network Object (or equivalent)") + String notePermissionsContainigTheseOperationsShuoldAssociatNetworkOrEqualRoleTreeTooltip(); @DefaultStringValue("Allow to move VM image to another Storage Domain") String allowToMoveVmImageToAnotherStorageDomainRoleTreeTooltip(); @@ -1225,6 +1237,12 @@ @DefaultStringValue("Configure Data Center") String configureDataCenterRoleTree(); + @DefaultStringValue("Network") + String networkRoleTree(); + + @DefaultStringValue("Configure Network") + String configureNetworkRoleTree(); + @DefaultStringValue("Storage Domain") String storageDomainRoleTree(); diff --git a/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/LocalizedEnums.java b/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/LocalizedEnums.java index c0f7a83..d214a26 100644 --- a/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/LocalizedEnums.java +++ b/frontend/webadmin/modules/uicompat/src/main/java/org/ovirt/engine/ui/uicompat/LocalizedEnums.java @@ -66,6 +66,8 @@ String ActionGroup___CONFIGURE_CLUSTER_NETWORK(); + String ActionGroup___ASSIGN_CLUSTER_NETWORK(); + String ActionGroup___CREATE_HOST(); String ActionGroup___DELETE_HOST(); @@ -120,7 +122,11 @@ String ActionGroup___MANIPULATE_ROLES(); - String ActionGroup___CONFIGURE_STORAGE_POOL_NETWORK(); + String ActionGroup___CONFIGURE_STORAGE_POOL_NETWORK(); + + String ActionGroup___CREATE_STORAGE_POOL_NETWORK(); + + String ActionGroup___DELETE_STORAGE_POOL_NETWORK(); String ActionGroup___CONFIGURE_ENGINE(); diff --git a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_es.properties b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_es.properties index 1703695..e8a0d8d 100644 --- a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_es.properties +++ b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_es.properties @@ -40,7 +40,6 @@ allowToChangeTemplatePropertiesRoleTreeTooltip=Permitir el cambio de propiedades de la plantilla allowToChangeVmCustomPropertiesRoleTreeTooltip=Permitir el cambio de propiedades personalizadas de la MV allowToConfigureHostsNetworkPhysicalInterfacesRoleTreeTooltip=Permitir configurar las interfaces f\u00EDsicas de la red del host (Nics) -allowToConfigureLogicalNetworkPerDataCenterRoleTreeTooltip=Permitir configurar la red l\u00F3gica por centro de datos allowToConfigureTemlateNetworkRoleTreeTooltip=Permitir configurar la red de plantillas allowToConfigureVMsNetworkRoleTreeTooltip=Permitir configurar la red de la MV allowToCopyTemplateBetweenStorageDomainsRoleTreeTooltip=Permitir la copia de la plantilla entre dominios de almacenamiento diff --git a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_fr.properties b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_fr.properties index e9c3bb5..b8041e2 100644 --- a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_fr.properties +++ b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_fr.properties @@ -42,7 +42,6 @@ allowToChangeTemplatePropertiesRoleTreeTooltip=Autoriser le changement de propri\u00E9t\u00E9s du mod\u00E8le allowToChangeVmCustomPropertiesRoleTreeTooltip=Autoriser le changement de propri\u00E9t\u00E9s personnalis\u00E9es de la VM allowToConfigureHostsNetworkPhysicalInterfacesRoleTreeTooltip=Autoriser la configuration des NIC de l'interface physique de l'h\u00F4te -allowToConfigureLogicalNetworkPerDataCenterRoleTreeTooltip=Autoriser la configuration du R\u00E9seau logique par Centre de donn\u00E9es allowToConfigureTemlateNetworkRoleTreeTooltip=Autoriser la configuration du R\u00E9seau de mod\u00E8les allowToConfigureVMsNetworkRoleTreeTooltip=Autoriser la configuration du r\u00E9seau de VM allowToCopyTemplateBetweenStorageDomainsRoleTreeTooltip=Autoriser la copie de Mod\u00E8le entre les Domaines de stockage diff --git a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_ja.properties b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_ja.properties index 481fa94..0e54cd4 100644 --- a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_ja.properties +++ b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_ja.properties @@ -40,7 +40,6 @@ allowToChangeTemplatePropertiesRoleTreeTooltip=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u30D7\u30ED\u30D1\u30C6\u30A3\u306E\u5909\u66F4\u3092\u8A31\u53EF allowToChangeVmCustomPropertiesRoleTreeTooltip=VM \u30AB\u30B9\u30BF\u30E0\u30D7\u30ED\u30D1\u30C6\u30A3\u306E\u5909\u66F4\u3092\u8A31\u53EF allowToConfigureHostsNetworkPhysicalInterfacesRoleTreeTooltip=\u30DB\u30B9\u30C8\u306E\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u7269\u7406\u30A4\u30F3\u30BF\u30FC\u30D5\u30A7\u30FC\u30B9 (NIC) \u306E\u8A2D\u5B9A\u3092\u8A31\u53EF -allowToConfigureLogicalNetworkPerDataCenterRoleTreeTooltip=\u30C7\u30FC\u30BF\u30BB\u30F3\u30BF\u30FC\u3054\u3068\u306E\u8AD6\u7406\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8A2D\u5B9A\u3092\u8A31\u53EF allowToConfigureTemlateNetworkRoleTreeTooltip=\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8A2D\u5B9A\u3092\u8A31\u53EF allowToConfigureVMsNetworkRoleTreeTooltip=\u4EEE\u60F3\u30DE\u30B7\u30F3\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306E\u8A2D\u5B9A\u3092\u8A31\u53EF allowToCopyTemplateBetweenStorageDomainsRoleTreeTooltip=\u30B9\u30C8\u30EC\u30FC\u30B8\u30C9\u30E1\u30A4\u30F3\u9593\u306B\u304A\u3051\u308B\u30C6\u30F3\u30D7\u30EC\u30FC\u30C8\u306E\u30B3\u30D4\u30FC\u3092\u8A31\u53EF diff --git a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_zh_CN.properties b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_zh_CN.properties index 08816db..1726beb 100644 --- a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_zh_CN.properties +++ b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/Constants_zh_CN.properties @@ -40,7 +40,6 @@ allowToChangeTemplatePropertiesRoleTreeTooltip=\u5141\u8BB8\u4FEE\u6539\u6A21\u677F\u5C5E\u6027 allowToChangeVmCustomPropertiesRoleTreeTooltip=\u5141\u8BB8\u4FEE\u6539\u865A\u62DF\u673A\u81EA\u5B9A\u4E49\u5C5E\u6027 allowToConfigureHostsNetworkPhysicalInterfacesRoleTreeTooltip=\u5141\u8BB8\u4FEE\u6539\u4E3B\u673A\u7684\u7F51\u7EDC\u7269\u7406\u63A5\u53E3\uFF08NIC\uFF09 -allowToConfigureLogicalNetworkPerDataCenterRoleTreeTooltip=\u5141\u8BB8\u4E3A\u6BCF\u4E2A\u6570\u636E\u4E2D\u5FC3\u914D\u7F6E\u903B\u8F91\u7F51\u7EDC allowToConfigureTemlateNetworkRoleTreeTooltip=\u5141\u8BB8\u914D\u7F6E\u6A21\u677F\u7F51\u7EDC allowToConfigureVMsNetworkRoleTreeTooltip=\u5141\u8BB8\u914D\u7F6E\u865A\u62DF\u673A\u7F51\u7EDC allowToCopyTemplateBetweenStorageDomainsRoleTreeTooltip=\u5141\u8BB8\u5728\u5B58\u50A8\u57DF\u95F4\u590D\u5236\u6A21\u677F diff --git a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/LocalizedEnums.properties b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/LocalizedEnums.properties index c05605c..0fa84cd 100644 --- a/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/LocalizedEnums.properties +++ b/frontend/webadmin/modules/uicompat/src/main/resources/org/ovirt/engine/ui/uicompat/LocalizedEnums.properties @@ -23,12 +23,13 @@ ActionGroup___CREATE_TEMPLATE=Create ActionGroup___DELETE_TEMPLATE=Delete ActionGroup___EDIT_TEMPLATE_PROPERTIES=Edit Properties -ActionGroup___CONFIGURE_TEMPLATE_NETWORK=Edit Network +ActionGroup___CONFIGURE_TEMPLATE_NETWORK=Assign Network to Template ActionGroup___COPY_TEMPLATE=Copy ActionGroup___CREATE_CLUSTER=Create ActionGroup___DELETE_CLUSTER=Delete ActionGroup___EDIT_CLUSTER_CONFIGURATION=Edit Properties ActionGroup___CONFIGURE_CLUSTER_NETWORK=Edit Network +ActionGroup___ASSIGN_CLUSTER_NETWORK=Assign Network to Cluster ActionGroup___CREATE_HOST=Create ActionGroup___DELETE_HOST=Delete ActionGroup___EDIT_HOST_CONFIGURATION=Edit Properties @@ -41,7 +42,7 @@ ActionGroup___MIGRATE_VM=Migrate ActionGroup___CHANGE_VM_CUSTOM_PROPERTIES=Edit custom properties ActionGroup___IMPORT_EXPORT_VM=Import/Export -ActionGroup___CONFIGURE_VM_NETWORK=Edit Network +ActionGroup___CONFIGURE_VM_NETWORK=Assign Network to VM ActionGroup___CONFIGURE_VM_STORAGE=Edit Storage ActionGroup___VM_BASIC_OPERATIONS=Basic Operations ActionGroup___CHANGE_VM_CD=Change CD @@ -56,7 +57,10 @@ ActionGroup___MANIPULATE_PERMISSIONS=Manipulate Permissions ActionGroup___LOGIN=Login Permissions ActionGroup___MANIPULATE_ROLES=Manipulate Roles -ActionGroup___CONFIGURE_STORAGE_POOL_NETWORK=Edit Network +ActionGroup___CREATE_STORAGE_POOL_NETWORK=Create +ActionGroup___CONFIGURE_STORAGE_POOL_NETWORK=Edit Properties +ActionGroup___CREATE_STORAGE_POOL_NETWORK=Create +ActionGroup___DELETE_STORAGE_POOL_NETWORK=Delete ActionGroup___CONFIGURE_ENGINE=Generic Configuration ActionGroup___CREATE_GLUSTER_VOLUME=Create Volume ActionGroup___MANIPULATE_GLUSTER_VOLUME=Manipulate Volume -- To view, visit http://gerrit.ovirt.org/9536 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I86243bdd22679ae4cd25be647acd4a56cd0b601f Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Moti Asayag <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
