Skip to content

Commit

Permalink
initial commit of prototype using editable grid component
Browse files Browse the repository at this point in the history
  • Loading branch information
steveswinsburg committed Nov 16, 2014
1 parent 9f42c7f commit ab5b1c7
Show file tree
Hide file tree
Showing 20 changed files with 809 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
target/
54 changes: 54 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<modelVersion>4.0.0</modelVersion>

<name>GradebookNG</name>
<description>The Next Generation Gradebook for the Sakai CLE</description>

<groupId>org.sakaiproject.gradebookng</groupId>
<artifactId>gradebookng</artifactId>
<version>1.0-SNAPSHOT</version>

<packaging>pom</packaging>

<parent>
<groupId>org.sakaiproject</groupId>
<artifactId>master</artifactId>
<version>11-SNAPSHOT</version>
<relativePath>../master/pom.xml</relativePath>
</parent>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>

<dependencyManagement>
<dependencies>

<!-- additional third party dependencies -->
<dependency>
<groupId>org.apache.wicket</groupId>
<artifactId>wicket</artifactId>
<version>6.16.0</version>
<type>pom</type>
</dependency>
<dependency>
<groupId>org.apache.wicket</groupId>
<artifactId>wicket-spring</artifactId>
<version>6.16.0</version>
</dependency>
<dependency>
<groupId>org.wicketstuff</groupId>
<artifactId>wicketstuff-inmethod-grid</artifactId>
<version>6.16.0</version>
</dependency>

</dependencies>
</dependencyManagement>


<modules>
<module>tool</module>
</modules>
</project>
29 changes: 29 additions & 0 deletions tool/.classpath
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="src" path="src/java"/>
<classpathentry kind="src" path="src/resources" including="*.properties" excluding="**/*.java"/>
<classpathentry kind="output" path="target/classes"/>
<classpathentry kind="var" path="M2_REPO/javax/inject/javax.inject/1/javax.inject-1.jar"/>
<classpathentry kind="var" path="M2_REPO/javax/servlet/servlet-api/2.4/servlet-api-2.4.jar"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="var" path="M2_REPO/org/apache/wicket/wicket-core/6.16.0/wicket-core-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/org/apache/wicket/wicket-util/6.16.0/wicket-util-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/org/slf4j/slf4j-api/1.7.5/slf4j-api-1.7.5.jar"/>
<classpathentry kind="var" path="M2_REPO/org/apache/wicket/wicket-request/6.16.0/wicket-request-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/org/apache/wicket/wicket-spring/6.16.0/wicket-spring-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/org/apache/wicket/wicket-ioc/6.16.0/wicket-ioc-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/cglib/cglib/2.2.2/cglib-2.2.2.jar"/>
<classpathentry kind="var" path="M2_REPO/asm/asm/3.3.1/asm-3.3.1.jar"/>
<classpathentry kind="var" path="M2_REPO/org/slf4j/slf4j-log4j12/1.7.5/slf4j-log4j12-1.7.5.jar"/>
<classpathentry kind="var" path="M2_REPO/log4j/log4j/1.2.16/log4j-1.2.16.jar"/>
<classpathentry kind="var" path="M2_REPO/org/projectlombok/lombok/1.12.4/lombok-1.12.4.jar"/>
<classpathentry kind="var" path="M2_REPO/org/sakaiproject/kernel/sakai-kernel-api/11-SNAPSHOT/sakai-kernel-api-11-SNAPSHOT.jar"/>
<classpathentry kind="var" path="M2_REPO/org/sakaiproject/kernel/sakai-component-manager/11-SNAPSHOT/sakai-component-manager-11-SNAPSHOT.jar"/>
<classpathentry kind="var" path="M2_REPO/org/sakaiproject/kernel/sakai-kernel-util/11-SNAPSHOT/sakai-kernel-util-11-SNAPSHOT.jar"/>
<classpathentry kind="var" path="M2_REPO/org/wicketstuff/wicketstuff-inmethod-grid/6.16.0/wicketstuff-inmethod-grid-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/org/apache/wicket/wicket-datetime/6.16.0/wicket-datetime-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/joda-time/joda-time/2.0/joda-time-2.0.jar"/>
<classpathentry kind="var" path="M2_REPO/org/apache/wicket/wicket-extensions/6.16.0/wicket-extensions-6.16.0.jar"/>
<classpathentry kind="var" path="M2_REPO/junit/junit/4.11/junit-4.11.jar"/>
<classpathentry kind="var" path="M2_REPO/org/hamcrest/hamcrest-core/1.3/hamcrest-core-1.3.jar"/>
</classpath>
14 changes: 14 additions & 0 deletions tool/.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>gradebookng-tool</name>
<comment>The Next Generation Gradebook for the Sakai CLE. NO_M2ECLIPSE_SUPPORT: Project files created with the maven-eclipse-plugin are not supported in M2Eclipse.</comment>
<projects/>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>
5 changes: 5 additions & 0 deletions tool/.settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#Sun Nov 16 23:00:46 EST 2014
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.source=1.6
org.eclipse.jdt.core.compiler.compliance=1.6
92 changes: 92 additions & 0 deletions tool/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,92 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<modelVersion>4.0.0</modelVersion>

<name>GradebookNG :: Tool</name>
<groupId>org.sakaiproject.gradebookng</groupId>
<artifactId>gradebookng-tool</artifactId>

<parent>
<groupId>org.sakaiproject.gradebookng</groupId>
<artifactId>gradebookng</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>

<packaging>war</packaging>

<dependencies>

<!-- third party dependencies -->
<dependency>
<groupId>org.apache.wicket</groupId>
<artifactId>wicket</artifactId>
<type>pom</type>
</dependency>
<dependency>
<groupId>org.apache.wicket</groupId>
<artifactId>wicket-spring</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
</dependency>
<dependency>
<groupId>org.sakaiproject.kernel</groupId>
<artifactId>sakai-kernel-api</artifactId>
</dependency>
<dependency>
<groupId>org.sakaiproject.kernel</groupId>
<artifactId>sakai-component-manager</artifactId>
</dependency>
<dependency>
<groupId>org.sakaiproject.kernel</groupId>
<artifactId>sakai-kernel-util</artifactId>
</dependency>
<dependency>
<groupId>org.wicketstuff</groupId>
<artifactId>wicketstuff-inmethod-grid</artifactId>
</dependency>

</dependencies>


<build>
<resources>
<!-- include our HTML but not the Java source -->
<resource>
<directory>src/java</directory>
<includes>
<include>**</include>
</includes>
<excludes>
<exclude>**/*.java</exclude>
</excludes>
</resource>
<!-- include our log4j.properties -->
<resource>
<directory>src/resources</directory>
<includes>
<include>*.properties</include>
</includes>
</resource>
</resources>
</build>

</project>
142 changes: 142 additions & 0 deletions tool/src/java/org/sakaiproject/gradebookng/GradebookNgApplication.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,142 @@
package org.sakaiproject.gradebookng;

import org.apache.wicket.protocol.http.WebApplication;
import org.apache.wicket.request.IRequestHandler;
import org.apache.wicket.request.Url;
import org.apache.wicket.request.cycle.IRequestCycleListener;
import org.apache.wicket.request.cycle.RequestCycle;
import org.apache.wicket.spring.injection.annot.SpringComponentInjector;
import org.sakaiproject.gradebookng.tool.pages.GradebookPage;

/**
* Main application class
*
* @author Steve Swinsburg ([email protected])
*
*/
public class GradebookNgApplication extends WebApplication {

@Override
protected void init() {

//Configure for Spring injection
getComponentInstantiationListeners().add(new SpringComponentInjector(this));

//Don't throw an exception if we are missing a property, just fallback
getResourceSettings().setThrowExceptionOnMissingResource(false);

//Remove the wicket specific tags from the generated markup
getMarkupSettings().setStripWicketTags(true);

//Don't add any extra tags around a disabled link (default is <em></em>)
getMarkupSettings().setDefaultBeforeDisabledLink(null);
getMarkupSettings().setDefaultAfterDisabledLink(null);

// On Wicket session timeout, redirect to main page
//getApplicationSettings().setPageExpiredErrorPage(FirstPage.class);
//getApplicationSettings().setAccessDeniedPage(FirstPage.class);

getRequestCycleListeners().add(new IRequestCycleListener() {

public void onBeginRequest()
{
// optionally do something at the beginning of the request
}

public void onEndRequest()
{
// optionally do something at the end of the request
}

public IRequestHandler onException(RequestCycle cycle, Exception ex)
{
// optionally do something here when there's an exception

// then, return the appropriate IRequestHandler, or "null"
// to let another listener handle the exception
ex.printStackTrace();
return null;
}

@Override
public void onBeginRequest(RequestCycle arg0) {
// TODO Auto-generated method stub

}

@Override
public void onDetach(RequestCycle arg0) {
// TODO Auto-generated method stub

}

@Override
public void onEndRequest(RequestCycle arg0) {
// TODO Auto-generated method stub

}

@Override
public void onExceptionRequestHandlerResolved(
RequestCycle arg0, IRequestHandler arg1, Exception arg2) {
// TODO Auto-generated method stub

}

@Override
public void onRequestHandlerExecuted(RequestCycle arg0,
IRequestHandler arg1) {
// TODO Auto-generated method stub

}

@Override
public void onRequestHandlerResolved(RequestCycle arg0,
IRequestHandler arg1) {
// TODO Auto-generated method stub

}

@Override
public void onRequestHandlerScheduled(RequestCycle arg0,
IRequestHandler arg1) {
// TODO Auto-generated method stub

}

@Override
public void onUrlMapped(RequestCycle arg0,
IRequestHandler arg1, Url arg2) {
// TODO Auto-generated method stub

}
});




//to put this app into deployment mode, see web.xml
}



/**
* The main page for our app
*
* @see org.apache.wicket.Application#getHomePage()
*/
public Class<GradebookPage> getHomePage() {
return GradebookPage.class;
}


/**
* Constructor
*/
public GradebookNgApplication()
{
}



}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
app.title = GradebookNG

link.gradebook = Gradebook
link.gradebook.tooltip = Go to the gradebook
Loading

0 comments on commit ab5b1c7

Please sign in to comment.