mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2025-02-25 18:55:28 -06:00
Replace usage of action factories with types
https://fedorahosted.org/freeipa/ticket/3235
This commit is contained in:
parent
5be709bf9d
commit
7a3f08002d
@ -766,7 +766,7 @@ IPA.association_facet = function (spec, no_init) {
|
||||
//default buttons and their actions
|
||||
spec.actions = spec.actions || [];
|
||||
spec.actions.unshift(
|
||||
IPA.refresh_action,
|
||||
'refresh',
|
||||
{
|
||||
name: 'remove',
|
||||
hide_cond: ['read-only'],
|
||||
@ -1151,7 +1151,7 @@ IPA.attribute_facet = function(spec, no_init) {
|
||||
//default buttons and their actions
|
||||
spec.actions = spec.actions || [];
|
||||
spec.actions.unshift(
|
||||
IPA.refresh_action,
|
||||
'refresh',
|
||||
{
|
||||
name: 'remove',
|
||||
hide_cond: ['read-only'],
|
||||
|
@ -1130,8 +1130,8 @@ IPA.cert.entity = function(spec) {
|
||||
$factory: IPA.cert.details_facet,
|
||||
no_update: true,
|
||||
actions: [
|
||||
IPA.cert.revoke_action,
|
||||
IPA.cert.restore_action
|
||||
'cert_revoke',
|
||||
'cert_restore'
|
||||
],
|
||||
state: {
|
||||
evaluators: [
|
||||
|
@ -244,9 +244,9 @@ exp.details_facet = IPA.details_facet = function(spec, no_init) {
|
||||
|
||||
spec.actions = spec.actions || [];
|
||||
spec.actions.unshift(
|
||||
IPA.refresh_action,
|
||||
IPA.reset_action,
|
||||
IPA.update_action);
|
||||
'refresh',
|
||||
'reset',
|
||||
'update');
|
||||
|
||||
spec.control_buttons = spec.control_buttons || [];
|
||||
|
||||
|
@ -129,8 +129,8 @@ IPA.dns.zone_entity = function(spec) {
|
||||
}
|
||||
],
|
||||
actions: [
|
||||
IPA.batch_disable_action,
|
||||
IPA.batch_enable_action
|
||||
'batch_disable',
|
||||
'batch_enable'
|
||||
],
|
||||
control_buttons: [
|
||||
{
|
||||
@ -233,12 +233,12 @@ IPA.dns.zone_entity = function(spec) {
|
||||
]
|
||||
}],
|
||||
actions: [
|
||||
IPA.select_action,
|
||||
IPA.enable_action,
|
||||
IPA.disable_action,
|
||||
IPA.delete_action,
|
||||
IPA.dns.add_permission_action,
|
||||
IPA.dns.remove_permission_action
|
||||
'select',
|
||||
'enable',
|
||||
'disable',
|
||||
'delete',
|
||||
'dns_add_permission',
|
||||
'dns_remove_permission'
|
||||
],
|
||||
header_actions: ['select_action', 'enable', 'disable', 'delete',
|
||||
'add_permission', 'remove_permission'],
|
||||
|
@ -73,10 +73,10 @@ IPA.group.entity = function(spec) {
|
||||
}
|
||||
],
|
||||
actions: [
|
||||
IPA.select_action,
|
||||
IPA.group.make_posix_action,
|
||||
IPA.group.make_external_action,
|
||||
IPA.delete_action
|
||||
'select',
|
||||
'make_posix',
|
||||
'make_external',
|
||||
'delete'
|
||||
],
|
||||
header_actions: ['select_action', 'make_posix', 'make_external', 'delete'],
|
||||
state: {
|
||||
|
@ -47,8 +47,8 @@ IPA.hbac.rule_entity = function(spec) {
|
||||
'description'
|
||||
],
|
||||
actions: [
|
||||
IPA.batch_disable_action,
|
||||
IPA.batch_enable_action
|
||||
'batch_disable',
|
||||
'batch_enable'
|
||||
],
|
||||
control_buttons: [
|
||||
{
|
||||
@ -68,10 +68,10 @@ IPA.hbac.rule_entity = function(spec) {
|
||||
entity: that,
|
||||
command_mode: 'info',
|
||||
actions: [
|
||||
IPA.select_action,
|
||||
IPA.enable_action,
|
||||
IPA.disable_action,
|
||||
IPA.delete_action
|
||||
'select',
|
||||
'enable',
|
||||
'disable',
|
||||
'delete'
|
||||
],
|
||||
header_actions: ['select_action', 'enable', 'disable', 'delete'],
|
||||
state: {
|
||||
|
@ -145,26 +145,26 @@ IPA.host.entity = function(spec) {
|
||||
}
|
||||
],
|
||||
actions: [
|
||||
IPA.host.unprovision_action,
|
||||
'host_unprovision',
|
||||
{
|
||||
$factory: IPA.host.set_otp_action,
|
||||
$type: 'set_otp',
|
||||
name: 'set_otp',
|
||||
label: '@i18n:objects.host.password_set_title',
|
||||
status: 'missing',
|
||||
hide_cond: ['has_password']
|
||||
},
|
||||
{
|
||||
$factory: IPA.host.set_otp_action,
|
||||
$type: 'set_otp',
|
||||
name: 'reset_otp',
|
||||
label: '@i18n:objects.host.password_reset_title',
|
||||
status: 'present',
|
||||
show_cond: ['has_password']
|
||||
},
|
||||
IPA.cert.view_action,
|
||||
IPA.cert.get_action,
|
||||
IPA.cert.request_action,
|
||||
IPA.cert.revoke_action,
|
||||
IPA.cert.restore_action
|
||||
'cert_view',
|
||||
'cert_get',
|
||||
'cert_request',
|
||||
'cert_revoke',
|
||||
'cert_restore'
|
||||
],
|
||||
state: {
|
||||
evaluators: [
|
||||
|
@ -46,9 +46,9 @@ IPA.search_facet = function(spec, no_init) {
|
||||
|
||||
spec.actions = spec.actions || [];
|
||||
spec.actions.unshift(
|
||||
IPA.refresh_action,
|
||||
IPA.batch_remove_action,
|
||||
IPA.add_action);
|
||||
'refresh',
|
||||
'batch_remove',
|
||||
'add');
|
||||
|
||||
spec.control_buttons = spec.control_buttons || [];
|
||||
|
||||
|
@ -46,8 +46,8 @@ IPA.selinux.selinuxusermap_entity = function(spec) {
|
||||
'description'
|
||||
],
|
||||
actions: [
|
||||
IPA.batch_disable_action,
|
||||
IPA.batch_enable_action
|
||||
'batch_disable',
|
||||
'batch_enable'
|
||||
],
|
||||
control_buttons: [
|
||||
{
|
||||
@ -67,10 +67,10 @@ IPA.selinux.selinuxusermap_entity = function(spec) {
|
||||
entity: that,
|
||||
command_mode: 'info',
|
||||
actions: [
|
||||
IPA.select_action,
|
||||
IPA.enable_action,
|
||||
IPA.disable_action,
|
||||
IPA.delete_action
|
||||
'select',
|
||||
'enable',
|
||||
'disable',
|
||||
'delete'
|
||||
],
|
||||
header_actions: ['select_action', 'enable', 'disable', 'delete'],
|
||||
state: {
|
||||
|
@ -149,12 +149,12 @@ IPA.service.entity = function(spec) {
|
||||
}
|
||||
],
|
||||
actions: [
|
||||
IPA.service.unprovision_action,
|
||||
IPA.cert.view_action,
|
||||
IPA.cert.get_action,
|
||||
IPA.cert.request_action,
|
||||
IPA.cert.revoke_action,
|
||||
IPA.cert.restore_action
|
||||
'service_unprovision',
|
||||
'cert_view',
|
||||
'cert_get',
|
||||
'cert_request',
|
||||
'cert_revoke',
|
||||
'cert_restore'
|
||||
],
|
||||
state: {
|
||||
evaluators: [
|
||||
|
@ -45,8 +45,8 @@ IPA.sudo.rule_entity = function(spec) {
|
||||
'description'
|
||||
],
|
||||
actions: [
|
||||
IPA.batch_disable_action,
|
||||
IPA.batch_enable_action
|
||||
'batch_disable',
|
||||
'batch_enable'
|
||||
],
|
||||
control_buttons: [
|
||||
{
|
||||
@ -66,10 +66,10 @@ IPA.sudo.rule_entity = function(spec) {
|
||||
entity: that,
|
||||
command_mode: 'info',
|
||||
actions: [
|
||||
IPA.select_action,
|
||||
IPA.enable_action,
|
||||
IPA.disable_action,
|
||||
IPA.delete_action
|
||||
'select',
|
||||
'enable',
|
||||
'disable',
|
||||
'delete'
|
||||
],
|
||||
header_actions: ['select_action', 'enable', 'disable', 'delete'],
|
||||
state: {
|
||||
|
@ -67,11 +67,11 @@ IPA.user.entity = function(spec) {
|
||||
],
|
||||
actions: [
|
||||
{
|
||||
$factory: IPA.batch_disable_action,
|
||||
$type: 'batch_disable',
|
||||
hide_cond: ['self-service']
|
||||
},
|
||||
{
|
||||
$factory: IPA.batch_enable_action,
|
||||
$type: 'batch_enable',
|
||||
hide_cond: ['self-service']
|
||||
}
|
||||
],
|
||||
@ -234,11 +234,11 @@ IPA.user.entity = function(spec) {
|
||||
}
|
||||
],
|
||||
actions: [
|
||||
IPA.select_action,
|
||||
IPA.enable_action,
|
||||
IPA.disable_action,
|
||||
IPA.delete_action,
|
||||
IPA.user.reset_password_action
|
||||
'select',
|
||||
'enable',
|
||||
'disable',
|
||||
'delete',
|
||||
'reset_password'
|
||||
],
|
||||
header_actions: ['select_action', 'enable', 'disable', 'delete'],
|
||||
state: {
|
||||
|
Loading…
Reference in New Issue
Block a user