File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed
src/main/java/springAngularApp/system/ws Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change 3030@ SuppressWarnings ("all" )
3131public class InitDBController {
3232
33+ public static final String ADMINISTRATOR = "Administrator" ;
34+ public static final String DEFAULT_USER = "Default user" ;
3335 @ Autowired private UserAuthorityRepository userAuthorityRepository ;
3436 @ Autowired private UserGroupRepository userGroupRepository ;
3537 @ Autowired private UserRepository userRepository ;
@@ -45,9 +47,9 @@ public ResponseEntity init() throws IOException {
4547 sessionFactory .getCurrentSession ().flush ();
4648 sessionFactory .getCurrentSession ().clear ();
4749
48- UserGroup adminGroup = new UserGroup ("Administrator" );
50+ UserGroup adminGroup = new UserGroup (ADMINISTRATOR );
4951 adminGroup .setSuperUserGroup (true );
50- UserGroup defaultUserGroup = new UserGroup ("Default user" );
52+ UserGroup defaultUserGroup = new UserGroup (DEFAULT_USER );
5153
5254 UserAuthority roleDefault = new UserAuthority (ROLE_DEFAULT );
5355 UserAuthority roleUserEdit = new UserAuthority (ROLE_USER_EDIT );
You can’t perform that action at this time.
0 commit comments