Closed CodeCraftStudio closed 10 years ago
Hi Łukasz, thanks for letting me know. Can you help with this one?
I can try, but I don't know Scala, and I'm just starting with Play. When I add boolean (for testing) to controllers.Assets.at(path, file, false/true), this problem disappears, but another one (in Scala) appear.
I recently switched a project which version was 2.3 to version 2.2 in order to use play2-crud.
Switching from to another was quite a nightmare. I ended up copy paste almost every conf file of the activator sample project of play2-crud.
build.sbt
name := """appGestion"""
version := "1.0-SNAPSHOT"
lazy val root = (project in file(".")).enablePlugins(PlayJava)
scalaVersion := "2.11.1"
resolvers += "jBCrypt Repository" at "http://repo1.maven.org/maven2/org/"
libraryDependencies ++= Seq(
javaJdbc,
javaEbean,
cache,
javaWs,
"mysql" % "mysql-connector-java" % "5.1.+",
"org.mindrot" % "jbcrypt" % "0.3m"
)
plugin.sbt
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
// The Play plugin
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.3.1")
// web plugins
addSbtPlugin("com.typesafe.sbt" % "sbt-coffeescript" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-less" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-jshint" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-rjs" % "1.0.1")
addSbtPlugin("com.typesafe.sbt" % "sbt-digest" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-mocha" % "1.0.0")
build.sbt
name := """appGestion"""
version := "0.7.3-SNAPSHOT"
scalaVersion := "2.10.1"
resolvers += "jBCrypt Repository" at "http://repo1.maven.org/maven2/org/"
libraryDependencies ++= Seq(
javaJdbc, javaCore,
javaEbean,
cache,
"mysql" % "mysql-connector-java" % "5.1.+",
"org.mindrot" % "jbcrypt" % "0.3m",
"play2-crud" % "play2-crud_2.10" % "0.7.3-SNAPSHOT"
)
play.Project.playJavaSettings
resolvers += "release repository" at "http://hakandilek.github.com/maven-repo/releases/"
resolvers += "snapshot repository" at "http://hakandilek.github.com/maven-repo/snapshots/"
plugin.sbt
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
// The Play plugin
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.2.2")
// web plugins
addSbtPlugin("com.typesafe.sbt" % "sbt-coffeescript" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-less" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-jshint" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-rjs" % "1.0.1")
addSbtPlugin("com.typesafe.sbt" % "sbt-digest" % "1.0.0")
addSbtPlugin("com.typesafe.sbt" % "sbt-mocha" % "1.0.0")
This are the two main file I had to change. I don't exactly remembered the other changes and I never knew if this changes were relevant.
Becausse of the downgrade, here is some of the issue I had to face: removing twirl import. Not that important since I used this import to create a less-effective implementation of crud2-play. Using the deprecated class SimpleResult. We use this class in the actions for example (which can't be used in the CRUDController, another issue about it later). Using the deprecated play.mvc.Content class.
Hope it will help you upgrade to the version 2.3. This will make this plugin even better !
Play team moved template system to new project play.twirl.api. So we need few changes: import play.mvc.Content -> import play.twirl.api.Content import play.api.templates.Html -> import play.twirl.api.Html
http://www.playframework.com/documentation/2.3.x/Migration23
Unfortunetly more need to be fixed. When I change imports, compiler crashes on the wrong number of parameters in Assets (return controllers.Assets.at(path, file);)