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
./skinny g scaffold employeeRoles employeeRole name:String technology:String responsibilities:String minExperience:Int | |
./skinny db:migrate |
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
./skinny run |
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 createFixtures() = { | |
if(EmployeeRole.countAllModels() == 0) { | |
EmployeeRole.createWithAttributes( | |
'name -> "Scala Hakker", | |
'technology -> "Scala, Akka, Play, JVM", | |
'responsibilities -> "Create awesome things!", | |
'minExperience -> 1 | |
) | |
} | |
} |
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
./skinny g scaffold pollResults pollResult name:String email:String description:String role:Long | |
./skinny db:migrate |
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
paramKey("email") is required & maxLength(512) & email, |
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
<%@val roles: Seq[model.EmployeeRole] = model.EmployeeRole.findAll() %> | |
<div class="form-group"> | |
<label class="control-label" for="role"> | |
${s.i18n.getOrKey("pollResult.role")} | |
</label> | |
<div class="controls row"> | |
<div class="${if(keyAndErrorMessages.hasErrors("role")) "has-error" else ""}"> | |
<div class="col-xs-12"> | |
<select name="role"> | |
#for (r <- roles) |
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
<%@val s: skinny.Skinny %> | |
<p> | |
<a href="${s.url(Controllers.pollResults.newUrl)}">Fill the survey</a> | |
</p> |
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
yo skinny |
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
./skinny g scaffold employeeRoles employeeRole name:String technology:String responsibilities:String minExperience:Int | |
./skinny db:migrate |
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 pollResults extends _root_.controller.PollResultsController with Routes { | |
val fillForm = get("/poll_results/new")(fillAction).as('customCreate) | |
} |