From 09f3e9869a27adc8c07c305a2aa5107690aa1d04 Mon Sep 17 00:00:00 2001 From: "Endi S. Dewata" Date: Wed, 19 Oct 2011 18:11:09 -0200 Subject: Fixed inconsistent required/optional attributes. The dialogs and details pages have been modified to use the * symbol to mark required fields. The automount map and the DNS zone dialogs have been modified to update the required fields according to the input type. Ticket #1696, #1973 --- install/ui/host.js | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) (limited to 'install/ui/host.js') diff --git a/install/ui/host.js b/install/ui/host.js index 552979b1..b5028729 100644 --- a/install/ui/host.js +++ b/install/ui/host.js @@ -124,14 +124,14 @@ IPA.entity_factories.host = function () { { factory: IPA.widget, name: 'fqdn', - optional: true, + required: false, hidden: true }, { factory: IPA.text_widget, name: 'hostname', label: IPA.messages.objects.service.host, - param_info: { required: true } + required: true }, { factory: IPA.dnszone_select_widget, @@ -139,7 +139,7 @@ IPA.entity_factories.host = function () { label: IPA.metadata.objects.dnszone.label_singular, editable: true, empty_option: false, - param_info: { required: true } + required: true } ] }, @@ -190,12 +190,22 @@ IPA.host_fqdn_section = function(spec) { text: hostname.label }).appendTo(tr); + $('', { + 'class': 'required-indicator', + text: IPA.required_indicator + }).appendTo(th); + th = $('', { 'class': 'dnszone', title: dnszone.label, text: dnszone.label }).appendTo(tr); + $('', { + 'class': 'required-indicator', + text: IPA.required_indicator + }).appendTo(th); + tr = $('').appendTo(table); var td = $('', { @@ -256,7 +266,7 @@ IPA.host_adder_dialog = function(spec) { var that = IPA.add_dialog(spec); that.create = function() { - that.dialog_create(); + that.add_dialog_create(); that.container.addClass('host-adder-dialog'); }; -- cgit