This is a bit of a holding spot for several issues with the current api:
major changes:
eg:
format :html do
view :new do :perms=>:create, :tags=>:unknown_ok do |args|
frame_and_form :create do
[
view.name_fieldset.optional,
view.type_fieldset.optional,
view.content_fieldsets.optional,
view.button_fieldset.optional
]
end
end
viewpoint :new do
point.optional_help = :show
....
end
end
The permissions handling (#2 above) is probably the most straightforward problem and should just require caching permissions checks on the format instance.
Getting rid of args should not be too hard, but there are a few considerations:
Tentatively, I'm thinking that the view methods themselves should be defined in the set modules so that include_set_modules already sets up the hierarchy. Those methods need to be executed by the format object (so the methods would need to return proc or lambda objects).
Let's say, for example, that a Claim cardtype overrides the "new" view in ...sets/type/claim.rb
It might create something like #_html_new in the set module. The format object could call that method on its card, and retrieve a proc that it could then execute.
I'm curious as to whether we can address #5 above and make it so that "super" will trace the ancesors chain in the card's singleton class. (Haven't worked that out yet)