wicket-spring-boot
wicket-spring-boot copied to clipboard
[Request] Multiple annotated pages
Hello,
I like the way the annotate a page like the homepage with an annotation. But I'm working on a framework with a very light template website included inside. I imagine to have a default homepage and the developer using this framework overriding the default homepage by a new homepage.
For that, I'm planning to add an optional "weight" property on the annotations.
Do you think it can be a feature included in wicket-spring-boot in a future release if I make a pull request ?
Currently all Classes with the WicketPage are added to the WicketClassCandidatesHolder. The Exception is thrown in the WicketBootStandardWebApplication on line 99 and WicketBootSecuredWebApplication on line 110. I can imagine that we won't throw an Exception but order the classes by Spring Boots @Order annotation or look at the @Primary annotation to choose the right one. Of there are multiple HomePage classes annotated with @Primary or with the highest precedence in the @Order annotation an exception is thrown. Could you imagine to provide a pull request?