Revision 3692b5bf
Added by Andreas Kohlbecker about 10 years ago
eu.etaxonomy.taxeditor.store/plugin.xml | ||
---|---|---|
894 | 894 |
properties="isModifiable" |
895 | 895 |
type="org.eclipse.jface.viewers.IStructuredSelection"> |
896 | 896 |
</propertyTester> |
897 |
<propertyTester |
|
898 |
class="eu.etaxonomy.taxeditor.security.PermissionPropertyTester" |
|
899 |
id="eu.etaxonomy.taxeditor.security.permissionTester" |
|
900 |
namespace="eu.etaxonomy.taxeditor.security.permissionTester" |
|
901 |
properties="hasPermissions, hasRoles" |
|
902 |
type="org.eclipse.jface.viewers.IStructuredSelection"> |
|
903 |
</propertyTester> |
|
897 | 904 |
</extension> |
898 | 905 |
<extension |
899 | 906 |
point="org.eclipse.core.expressions.definitions"> |
... | ... | |
924 | 931 |
</test> |
925 | 932 |
</with> |
926 | 933 |
</definition> |
934 |
<definition |
|
935 |
id="canUPDATE"> |
|
936 |
<with |
|
937 |
variable="selection"> |
|
938 |
<test |
|
939 |
args="UPDATE" |
|
940 |
property="eu.etaxonomy.taxeditor.security.permissionTester.hasPermissions"> |
|
941 |
</test> |
|
942 |
</with> |
|
943 |
</definition> |
|
944 |
<definition |
|
945 |
id="canDELETE"> |
|
946 |
<with |
|
947 |
variable="selection"> |
|
948 |
<test |
|
949 |
args="DELETE" |
|
950 |
property="eu.etaxonomy.taxeditor.security.permissionTester.hasPermissions"> |
|
951 |
</test> |
|
952 |
</with> |
|
953 |
</definition> |
|
954 |
<definition |
|
955 |
id="canCREATE"> |
|
956 |
<with |
|
957 |
variable="selection"> |
|
958 |
<test |
|
959 |
args="CREATE" |
|
960 |
property="eu.etaxonomy.taxeditor.security.permissionTester.hasPermissions"> |
|
961 |
</test> |
|
962 |
</with> |
|
963 |
</definition> |
|
964 |
<definition |
|
965 |
id="hasROLE_USER_MANAGER"> |
|
966 |
<test |
|
967 |
args="ROLE_USER_MANAGER" |
|
968 |
property="eu.etaxonomy.taxeditor.security.permissionTester.hasRole"> |
|
969 |
</test> |
|
970 |
</definition> |
|
971 |
</extension> |
|
972 |
<extension |
|
973 |
point="org.eclipse.ui.activities"> |
|
974 |
<activity |
|
975 |
description="DELETE permission dependent ui contributions" |
|
976 |
id="eu.etaxonomy.taxeditor.store.activityDelete" |
|
977 |
name="Delete"> |
|
978 |
<enabledWhen> |
|
979 |
<reference |
|
980 |
definitionId="canDELETE"> |
|
981 |
</reference> |
|
982 |
</enabledWhen> |
|
983 |
</activity> |
|
984 |
<activityPatternBinding |
|
985 |
activityId="eu.etaxonomy.taxeditor.store.activityDelete" |
|
986 |
pattern="eu\.etaxonomy\.taxeditor\..*/.*.delete"> |
|
987 |
</activityPatternBinding> |
|
988 |
<activity |
|
989 |
description="UPDATE permission dependent ui contributions" |
|
990 |
id="eu.etaxonomy.taxeditor.store.activityUpdate" |
|
991 |
name="Update"> |
|
992 |
<enabledWhen> |
|
993 |
<reference |
|
994 |
definitionId="canUPDATE"> |
|
995 |
</reference> |
|
996 |
</enabledWhen> |
|
997 |
</activity> |
|
998 |
<activityPatternBinding |
|
999 |
activityId="eu.etaxonomy.taxeditor.store.activityUpdate" |
|
1000 |
pattern="eu\.etaxonomy\.taxeditor\..*/.*.command\.update\..*"> |
|
1001 |
</activityPatternBinding> |
|
1002 |
<activity |
|
1003 |
description="CREATE permission dependent ui contributions" |
|
1004 |
id="eu.etaxonomy.taxeditor.store.activityCreate" |
|
1005 |
name="Delete"> |
|
1006 |
<enabledWhen> |
|
1007 |
<reference |
|
1008 |
definitionId="canDELETE"> |
|
1009 |
</reference> |
|
1010 |
</enabledWhen> |
|
1011 |
</activity> |
|
1012 |
<activityPatternBinding |
|
1013 |
activityId="eu.etaxonomy.taxeditor.store.activityCreate" |
|
1014 |
pattern="eu\.etaxonomy\.taxeditor\..*/.*.command\.create\..*"> |
|
1015 |
</activityPatternBinding> |
|
1016 |
<activity |
|
1017 |
description="ROLE_USER_MANAGER dependent ui contributions" |
|
1018 |
id="eu.etaxonomy.taxeditor.store.activityUserManagement" |
|
1019 |
name="UserManagement"> |
|
1020 |
<enabledWhen> |
|
1021 |
<reference |
|
1022 |
definitionId="hasROLE_USER_MANAGER"> |
|
1023 |
</reference> |
|
1024 |
</enabledWhen> |
|
1025 |
</activity> |
|
1026 |
<activityPatternBinding |
|
1027 |
activityId="eu.etaxonomy.taxeditor.store.activityUserManagement" |
|
1028 |
pattern="eu\.etaxonomy\.taxeditor\..*/.*.UserManagement"> |
|
1029 |
</activityPatternBinding> |
|
927 | 1030 |
</extension> |
928 | 1031 |
|
929 | 1032 |
</plugin> |
Also available in: Unified diff
base implementation and configuration for securing the editor - #4055 (action enablement adapts to the users granted authorities)