[Freeipa-devel] [PATCH] 315 Added commands into metadata.
Alexander Bokovoy
abokovoy at redhat.com
Fri Nov 18 11:37:14 UTC 2011
On Thu, 17 Nov 2011, Endi Sukma Dewata wrote:
> The json_metadata command has been modified to return the command
> metadata. The API.txt has been updated as well.
>
> Needed by ticket #388
...
> --- a/ipalib/plugins/internal.py
> +++ b/ipalib/plugins/internal.py
> @@ -49,15 +52,25 @@ class json_metadata(Command):
> )
>
> has_output = (
> + Output('commands', dict, doc=_('Dict of JSON encoded IPA Commands')),
> Output('objects', dict, doc=_('Dict of JSON encoded IPA Objects')),
> Output('methods', dict, doc=_('Dict of JSON encoded IPA Methods')),
> )
>
> - def execute(self, objname, methodname):
> + def execute(self, cmdname, objname, methodname):
> + commands = dict()
> objects = dict()
> methods = dict()
I don't like this particular change of order of arguments but as
API.Command.json_metadata is only used in two (three now) places in
ipa.js, it is acceptable -- there is practically no old Web UI
anywhere as it is downloaded from the server.
--
/ Alexander Bokovoy
More information about the Freeipa-devel
mailing list