answered
2019-10-28 11:14:01 +0800
cor3000 6280 ● 2 ● 7 The zk.homepage property is a convenience parameter for single page applications.
For multi page applications you have all the possibilities spring mvc offers.
E.g. you can define multiple entrypoints in your application config, and return a string to your ViewResolvers.
In our demo we specify @GetMapping
s for the entry points "/mvvm" and "/resources"
https://github.com/zkoss/zkspringboot/blob/v1.0.4/zkspringboot-demos/zkspringboot-demo-jar/src/main/java/org/zkoss/zkspringboot/demo/DemoApplication.java
(BTW the homepage config does nothing different)
These returned Strings (view-names) are then handled view resolvers.
By default the zk.zul-view-resolver-enabled
is enabled. And will resolve view-names into urls like /zkau/web/{optional-prefix}/{view-name}.zul
Please also read the related README.md and Spring-mvc documentation (request-mappings, view-resolvers)
I know that's a lot to read but that's what you get when choosing a sophisticated framework as Spring boot. Even though they try to hide the nasty details, you still have to be aware of them in order to understand your application.