我希望我的员工有如下用户
import org.isisaddons.module.security.dom.role.ApplicationRole;
import org.isisaddons.module.security.dom.user.ApplicationUser;
import org.isisaddons.module.security.dom.user.ApplicationUserRepository;
@Column(allowsNull = "true")
@Property(editing = Editing.ENABLED)
@Getter @Setter
private ApplicationUser user;
public List<ApplicationUser> choicesUser() {
return applicationUserRepository.allUsers();
}
public List<ApplicationRole> getUserRoles() {
return user!=null? Lists.newArrayList(user.getRoles()):Lists.newArrayList();
}
@Action()
public Employee createUser(
@ParameterLayout(named = "Username") final String username,
@ParameterLayout(named = "Password") final Password password,
@ParameterLayout(named = "Repeat Password") final Password repeatPassword,
final ApplicationRole initialRole,
final Boolean enable,
final String emailAddress) {
ApplicationUser applicationUser = applicationUserRepository.newLocalUser(username, password, repeatPassword, initialRole, enable, emailAddress);
this.setUser(applicationUser);
return this;
}
当我在 IDE 上运行时,它运行良好,一切都按预期工作,但是当我运行mvn clean install
它时,它会出现如下错误,当我删除它上面的代码时,它构建得很好。还有什么我错过的吗?
[INFO] calling @PostConstruct on all domain services
[WARNING] NOT configured
[ERROR]
[ERROR]
[ERROR]
[ERROR] @DomainObject annotation on org.isisaddons.module.security.dom.role.ApplicationRole specifies unknown repository 'org.isisaddons.module.security.dom.role.ApplicationRoleRepository'
[ERROR] @DomainObject annotation on org.isisaddons.module.security.dom.user.ApplicationUser specifies unknown repository 'org.isisaddons.module.security.dom.user.ApplicationUserRepository'
[ERROR]
[ERROR]
[ERROR]
[INFO] calling @PreDestroy on all domain services
[INFO] shutting down org.apache.isis.core.metamodel.specloader.SpecificationLoader@1f041bad
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary:
[INFO]
[INFO] Incode QuickStart .................................. SUCCESS [ 0.279 s]
[INFO] Incode QuickStart Base Module ...................... SUCCESS [ 2.480 s]
[INFO] Employment Module .................................. FAILURE [ 11.695 s]
[INFO] Incode QuickStart App Definition ................... SKIPPED
[INFO] Incode QuickStart Webapp ........................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 15.022 s
[INFO] Finished at: 2017-11-06T11:09:35+07:00
[INFO] Final Memory: 59M/457M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.isis.tool:isis-maven-plugin:1.15.1:validate (default) on project pApp-module-employment: 2 meta-model problems found. -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :pApp-module-employment
请帮助,我也!
通过关注另一个具有类似问题的问题来大摇大摆地删除 pom,但它不起作用!