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
object Area extends Area with LongKeyedMetaMapper[Area] with CRUDify[Long, Area]{ | |
override def dbTableName = "area" | |
} | |
class Area extends LongKeyedMapper[Area] with IdPK{ | |
def getSingleton = Area; | |
object areaId extends MappedLong(this){ | |
override def dbColumnName = "area_id"; |
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
def listUsers(xhtml : NodeSeq) : NodeSeq = { | |
var searchText = ""; | |
def searchUser() : NodeSeq = { | |
val usersList = User.findByName(searchText); | |
def showUserView(user : User): NodeSeq = { | |
SetHtml("usersList", NodeSeq.Empty) | |
<ul type="none"> | |
<li> | |
{user.firstName} | |
</li> |
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
object Succ { | |
def main(args: Array[String]) { | |
assert(succ("") == "") | |
assert(succ("3") == "4") | |
assert(succ("R2D3") == "R2D4") | |
assert(succ("R293") == "R294") | |
assert(succ("R2D9") == "R2E0") | |
assert(succ("A99") == "B00") | |
assert(succ("Z99") == "AA00") |