[Freeipa-devel] [PATCH] 0270-removing-setters-setup-and-init
Adam Young
ayoung at redhat.com
Wed Jul 27 16:33:44 UTC 2011
This applies on top of my old patch 270 version 13. Changes are in a
separate patch due to the size of the original. When submitted, I can
squash the two patches into one.
I have not rebased on top of the latest changes, as that would involve
changing patch 270. I will do so prior to pushing.
On 07/27/2011 01:51 AM, Endi Sukma Dewata wrote:
> On 7/26/2011 3:36 PM, Adam Young wrote:
>>> 41. The radio buttons in the 'As Whom' section in sudo rule section
>>> are missing the labels. It should show the doc attributes of the
>>> ipasudorunasusercategory and ipasudorunasgroupcategory.
>> Fixed
>
> These labels (sudo.js:1033,1069) should be followed by "a colon and a
> space" like the other labels (see the original code).
Done
>
> 56. The IPA.spacer_widget should be removed from dns.js and widget.js
> as we discussed before.
Done
>
> 57. The parameter validation in IPA.column (widget.js:1131) doesn't
> really look that different from other initialization code in line
> 1172, so we can move it into the initialization area too.
This is precondition checking. Note that it merely throws an exception
if the entity_name is not set. I want this stuff at the top of the
function so that it is obvious to people looking to use them what is
required. I added a comment to make this clear, but I'd like to keep
precondition checking at the top of the function.
>
> 58. The create() in IPA.add_dialog (add.js:46) is unnecessary.
removed
>
> 59. The initialization area in IPA.association_adder_dialog
> (association.js:212) should be marked with a comment.
Done
>
> 60. The pkey_name in IPA.association_facet (association.js:664) should
> not be defined inside a block because it will be used outside the
> block. JS allows this but we should avoid that. Maybe it should be
> changed into an instance variable.
>
> 61. Instead of modifying spec.columns in IPA.association_facet
> (association.js:670-676), we can revert it back to call
> create_column() and move it into the initialization area along with
> the pkey_name in issue #60.
Moved the whole thing to setup_columns, and use the tah. variables
instead of the spec
>
> Optional: A similar logic can be applied to adder_columns as well.
> This will eliminate create_adder_column() invocation in
> IPA.host_managedby_host_facet and maybe
> IPA.service_managedby_host_facet too.
Lets do this in its own patch.
>
> 62. Since the code in #60 and #61 is moved to initialization area, the
> spec.link can be reverted back to that.link.
Removed link. I don't see where it is used. Tested without it and
everything seems to work fine.
>
> 63. This is an existing issue. There's an initialization code in
> IPA.association_facet that calls create_adder_column()
> (association.js:726-729), this can be moved down as well.
>
Done
> 64. The code in setup_columns() in IPA.association_facet is originally
> from init(), so it should be called from the initialization area
> instead of from create_content().
done
>
> 65. The parameter validation in IPA.adder_dialog (dialog.js:308) can
> be moved into the initialization area. Same reason as #57.
Leaving. Same reason.
>
> 66. The add_section() invocations in IPA.hbacrule_details_facet should
> be moved into the initialization area because they are originally from
> init().
Done
>
> 67. The table widget initialization in IPA.search_facet
> (search.js:52-89) is originally from init(), so it should be moved
> into the initialization area.
Has to be here, or you have endless recursion due to get_entity circular
references.
>
> 68. The add_section() and host_section() invocations in
> IPA.sudorule_details_facet should be moved into the initialization area.
Done
>
> 69. The initialization code in IPA.sudo.options_section
> (sudo.js:603-638) should be moved into the initialization area.
Done
>
> 70. The initialization code in IPA.sudo.rule_details_command_section
> (sudo.js:784-823) should be moved into the initialization area.
Done
>
> 71. The initialization area in IPA.sudo.rule_details_runas_section
> (sudo.js:1137) should be marked with a comment.
Done
>
> 72. There's a whitespace warning.
Fixed
-------------- next part --------------
A non-text attachment was scrubbed...
Name: freeipa-admiyo-0278-init-and-setup-method-removal.patch
Type: text/x-patch
Size: 23108 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/freeipa-devel/attachments/20110727/132ff995/attachment.bin>
More information about the Freeipa-devel
mailing list