Created
January 8, 2011 14:58
-
-
Save lopex/770900 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import _root_.net.liftweb.mapper._ | |
import _root_.net.liftweb.http._ | |
import _root_.net.liftweb.common.{Full, Box} | |
import _root_.scala.xml.{NodeSeq, Elem} | |
trait ErrorMessageSupport extends BaseMappedField { | |
self: MappedField[_,_] => | |
abstract override def _toForm:Box[Elem] = toForm(super._toForm.open_!) | |
def toForm(in: NodeSeq) = Full( | |
<div> | |
{in} | |
<div class="error_msg"><lift:msg id={uniqueFieldId.open_!}/></div> | |
</div> | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment