mirror of
https://github.com/jlengrand/quarkus.git
synced 2026-03-10 08:41:22 +00:00
Add missing Spring Controller templates for Kotlin and Scala
Fixes: #5817
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
package ${package_name};
|
||||
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
|
||||
|
||||
@RestController
|
||||
@RequestMapping("${path}")
|
||||
class ${class_name} {
|
||||
|
||||
@GetMapping
|
||||
fun hello() = "hello"
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
package ${package_name};
|
||||
|
||||
import org.springframework.web.bind.annotation.{GetMapping, RequestMapping, RestController, PathVariable};
|
||||
|
||||
|
||||
@RestController
|
||||
@RequestMapping(Array[String]("${path}"))
|
||||
class ${class_name} {
|
||||
|
||||
@GetMapping
|
||||
def hello() = "hello"
|
||||
}
|
||||
Reference in New Issue
Block a user