Commit f4f2f96d authored by Florian Fittkau's avatar Florian Fittkau

minor changes

parent 6a20fcec
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src/java"/>
<classpathentry kind="src" path="src/groovy"/>
<classpathentry kind="src" path="grails-app/conf"/>
<classpathentry kind="src" path="grails-app/controllers"/>
<classpathentry kind="src" path="grails-app/domain"/>
<classpathentry kind="src" path="grails-app/services"/>
<classpathentry kind="src" path="grails-app/taglib"/>
<classpathentry kind="src" path="grails-app/utils"/>
<classpathentry kind="src" path="test/integration"/>
<classpathentry kind="src" path="test/unit"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry exported="true" kind="con" path="GROOVY_DSL_SUPPORT"/>
<classpathentry kind="src" path=".link_to_grails_plugins/browser-detection-0.4.1/grails-app/services">
<attributes>
<attribute name="org.grails.ide.eclipse.core.SOURCE_FOLDER" value="true"/>
......
......@@ -33,38 +33,48 @@ class BootStrap {
private createExampleProject() {
def fmcockpit = new Project(name: "FMcockpit")
def ffi = User.findByUsername("ffi")
fmcockpit.setProductBacklog(createBacklog(ffi))
fmcockpit.addToSprints(createSprint(ffi))
fmcockpit.save(failOnError: true)
}
private createBacklog(User ffi) {
def productBacklog = new ProductBacklog()
def userStoryInBacklog = new UserStory(title: "Energiekataster Layer",
description: "Energiekataster Layer im GIS um &uuml;ber jeder VE die Energieausweise direkt zu sehen.")
def ffi = User.findByUsername("ffi")
userStoryInBacklog.shortId = "V-1"
def userStoryInBacklog = new UserStory("V-1", "Energiekataster Layer")
userStoryInBacklog.description = "Energiekataster Layer im GIS um &uuml;ber jeder VE die Energieausweise direkt zu sehen."
userStoryInBacklog.author = ffi
userStoryInBacklog.editor = ffi
userStoryInBacklog.points = 3
userStoryInBacklog.save(failOnError: true)
productBacklog.addToUserstories(userStoryInBacklog)
def sprintOne = new Sprint(number: 1)
productBacklog
}
private Sprint createSprint(User ffi) {
def sprintOne = new Sprint("Sprint 1")
sprintOne.due_date = new Date()
def userStoryInSprint = new UserStory(title: "Volltextsuche im GIS",
description: "Wenn man nach einer VE oder einer Adresse sucht, sollte diese in den Ergebnissen ber&uuml;cksichtigt werden.")
userStoryInSprint.shortId = "V-2"
def userStoryInSprint = new UserStory("V-2", "Volltextsuche im GIS")
userStoryInSprint.description = "Volltextsuche im GIS ermglichen"
userStoryInSprint.author = ffi
userStoryInSprint.editor = ffi
userStoryInSprint.points = 2
userStoryInSprint.status = UserStoryStatus.OPEN
sprintOne.addToUserstories(userStoryInSprint)
userStoryInSprint.save(failOnError: true)
sprintOne.due_date = new Date()
fmcockpit.addToSprints(sprintOne)
fmcockpit.setProductBacklog(productBacklog)
sprintOne.addToUserstories(userStoryInSprint)
fmcockpit.save(failOnError: true)
sprintOne
}
def destroy = {
......
......@@ -14,4 +14,8 @@ class SprintController {
currentSprint: currentSprint,
sprintUserStories: sprintUserStories])
}
def create(String name) {
new Sprint(name)
}
}
......@@ -36,6 +36,8 @@ class UserStoryController {
userStory.status = UserStoryStatus.DONE
}
userStory.save()
render ""
}
}
package scrumboard
class Color {
int red
int green
int blue
static constraints = {
red min: 0, max: 255
green min: 0, max: 255
blue min: 0, max: 255
}
Color(red, green, blue) {
this.red = red
this.green = green
this.blue = blue
}
}
package scrumboard
class Sprint {
int number
String name
Date due_date
static hasMany = [ userstories: UserStory ]
......@@ -10,7 +10,11 @@ class Sprint {
static constraints = {
}
Sprint(String name) {
this.name = name
}
def String toString() {
"Sprint " + number
name
};
}
......@@ -13,12 +13,19 @@ class UserStory implements Comparable {
UserStoryStatus status = UserStoryStatus.IN_BACKLOG
Color color
User author
User editor
static constraints = {
}
UserStory(String shortId, String title) {
this.shortId = shortId
this.title = title
}
def String toString() {shortId + ": " + title};
int compareTo(obj) {
......
......@@ -57,8 +57,6 @@
</div>
<div id="dialog-addSprint" title="Create new sprint">
<p class="validateTips">All form fields are required.</p>
<form>
<fieldset>
<label for="name">Name</label>
......@@ -70,7 +68,6 @@
</div>
<div id="dialog-showUserStory" title="Show User Story">
x
</div>
<script type="text/javascript">
......@@ -98,6 +95,7 @@ $(function() {
var bValid = true;
allFields.removeClass( "ui-state-error" );
if ( bValid ) {
$( this ).dialog( "close" );
}
},
......
......@@ -27,7 +27,6 @@
<g:layoutBody/>
<br>
<br>
<div class="footer" role="contentinfo"><div class="center" style='text-align: center;' width='100%'><a href="http://se.informatik.uni-kiel.de">Scrumboard</a></div></div>
<r:layoutResources />
</body>
</html>
\ No newline at end of file
package scrumboard
import grails.test.mixin.*
import org.junit.*
/**
* See the API for {@link grails.test.mixin.domain.DomainClassUnitTestMixin} for usage instructions
*/
@TestFor(Color)
class ColorTests {
void testSomething() {
fail "Implement me"
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment