Permalink
Browse files

closes #1019. Add seeOther to stateful snippet

  • Loading branch information...
1 parent f01b9d5 commit 291eee2e2a17735707c78d10680e3cb728234d5b @dpp dpp committed Jun 30, 2011
Showing with 11 additions and 1 deletion.
  1. +11 −1 web/webkit/src/main/scala/net/liftweb/http/StatefulSnippet.scala
@@ -89,7 +89,17 @@ trait StatefulSnippet extends DispatchSnippet {
def link(to: String, func: () => Any, body: NodeSeq, attrs: SHtml.ElemAttr*): Elem =
SHtml.link(to, () => { registerThisSnippet(); func() }, body, attrs: _*)
- def redirectTo(where: String) = S.redirectTo(where, registerThisSnippet)
+ /**
+ * Redirect to another page, but make sure this StatefulSnippet is registered
+ * on that page so the state continues on the new page
+ */
+ def redirectTo(where: String): Nothing = S.redirectTo(where, registerThisSnippet)
+
+ /**
+ * See Other to another page, but make sure this StatefulSnippet is registered
+ * on that page so the state continues on the new page
+ */
+ def seeOther(where: String): Nothing = S.seeOther(where, registerThisSnippet)
/**
* Merge the SHtml into the form

0 comments on commit 291eee2

Please sign in to comment.