Replace formatter creation with definition in specs

https://fedorahosted.org/freeipa/ticket/3235
This commit is contained in:
Petr Vobornik 2013-04-16 14:29:41 +02:00
parent ff8580f441
commit 511452ec41
9 changed files with 18 additions and 16 deletions

View File

@ -125,7 +125,7 @@ IPA.dns.zone_entity = function(spec) {
{
name: 'idnszoneactive',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter()
formatter: 'boolean_status'
}
],
actions: [

View File

@ -42,7 +42,7 @@ IPA.hbac.rule_entity = function(spec) {
{
name: 'ipaenabledflag',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter()
formatter: 'boolean_status'
},
'description'
],

View File

@ -50,9 +50,10 @@ IPA.hbac.test_entity = function(spec) {
{
name: 'nsaccountlock',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter({
formatter: {
$type: 'boolean_status',
invert_value: true
})
}
}
]
}).
@ -69,7 +70,7 @@ IPA.hbac.test_entity = function(spec) {
{
name: 'has_keytab',
label: '@i18n:objects.host.enrolled',
formatter: IPA.boolean_formatter()
formatter: 'boolean'
}
]
}).
@ -98,7 +99,7 @@ IPA.hbac.test_entity = function(spec) {
{
name: 'ipaenabledflag',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter()
formatter: 'boolean_status'
},
'description'
]
@ -116,12 +117,12 @@ IPA.hbac.test_entity = function(spec) {
{
name: 'matched',
label: '@i18n:objects.hbactest.matched',
formatter: IPA.boolean_formatter()
formatter: 'boolean'
},
{
name: 'ipaenabledflag',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter()
formatter: 'boolean_status'
},
'description'
]

View File

@ -64,7 +64,7 @@ IPA.host.entity = function(spec) {
{
name: 'has_keytab',
label: '@i18n:objects.host.enrolled',
formatter: IPA.boolean_formatter()
formatter: 'boolean'
}
]
}).

View File

@ -260,7 +260,7 @@ IPA.netgroup.details_facet = function(spec) {
{
name: 'externalhost',
label: '@i18n:objects.netgroup.external',
formatter: IPA.boolean_formatter(),
formatter: 'boolean',
width: '200px'
}
]

View File

@ -130,7 +130,7 @@ IPA.rule_association_table_widget = function(spec) {
name: that.external,
label: '@i18n:objects.sudorule.external',
entity: that.other_entity,
formatter: IPA.boolean_formatter(),
formatter: 'boolean',
width: '200px'
});
}

View File

@ -41,7 +41,7 @@ IPA.selinux.selinuxusermap_entity = function(spec) {
{
name: 'ipaenabledflag',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter()
formatter: 'boolean_status'
},
'description'
],

View File

@ -40,7 +40,7 @@ IPA.sudo.rule_entity = function(spec) {
{
name: 'ipaenabledflag',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter()
formatter: 'boolean_status'
},
'description'
],

View File

@ -45,9 +45,10 @@ IPA.user.entity = function(spec) {
{
name: 'nsaccountlock',
label: '@i18n:status.label',
formatter: IPA.boolean_status_formatter({
formatter: {
$type: 'boolean_status',
invert_value: true
})
}
},
'uidnumber',
'mail',
@ -111,7 +112,7 @@ IPA.user.entity = function(spec) {
name: 'krbpasswordexpiration',
label: '@i18n:objects.user.krbpasswordexpiration',
read_only: true,
formatter: IPA.utc_date_formatter()
formatter: 'utc_date'
},
'uidnumber',
'gidnumber',