Hello,
I have added support for setting the Http Method as an attribute for
the action functions instead of suffixing _get or _post. With the new
change the Controller class might look like this :
type
TBlogController = class(TApplicationController)
public
[HttpGet]
procedure Index(out data: ISuperObject);
[HttpPost]
procedure New(const data: TBlog);
procedure View(id: Integer; out data: ISuperObject);
procedure Edit(id: Integer; out data: ISuperObject);overload; {If
no attribute is not specified, it will default to HttpGet}
[HttpPost]
procedure Edit(const data: TBlog);overload;
[HttpPost]
procedure Delete(id: Integer);
end;
This is similar to that of
ASP.NET MVC style. The change also retains
the old style of action reference to maintain backward compatibility.
Please check the changes at :
http://twinforms.com/downloads/attribute_support_changes.zip
Thanks,
Guru Kathiresan