This commit is contained in:
DyCTaTOR 2024-04-16 12:12:07 +04:00
parent f388f69e51
commit f448d6541a
5 changed files with 41 additions and 7 deletions

Binary file not shown.

View File

@ -20125,3 +20125,35 @@ Caused by: java.lang.AssertionError: 77824 != 69632
at org.h2.mvstore.RandomAccessStore.writeChunk(RandomAccessStore.java:28)
at org.h2.mvstore.FileStore.storeBuffer(FileStore.java:1524)
... 6 more
2024-04-16 12:03:21.805833+04:00 jdbc[3]: exception
java.sql.SQLClientInfoException: Client info name 'ApplicationName' not supported.
at org.h2.jdbc.JdbcConnection.setClientInfo(JdbcConnection.java:1626)
at org.jkiss.dbeaver.ext.generic.model.GenericDataSource.populateClientAppName(GenericDataSource.java:199)
at org.jkiss.dbeaver.ext.generic.model.GenericDataSource.openConnection(GenericDataSource.java:162)
at org.jkiss.dbeaver.ext.h2.model.H2DataSource.openConnection(H2DataSource.java:74)
at org.jkiss.dbeaver.model.impl.jdbc.JDBCExecutionContext.connect(JDBCExecutionContext.java:106)
at org.jkiss.dbeaver.model.impl.jdbc.JDBCRemoteInstance.initializeMainContext(JDBCRemoteInstance.java:102)
at org.jkiss.dbeaver.model.impl.jdbc.JDBCRemoteInstance.<init>(JDBCRemoteInstance.java:61)
at org.jkiss.dbeaver.model.impl.jdbc.JDBCDataSource.initializeRemoteInstance(JDBCDataSource.java:119)
at org.jkiss.dbeaver.ext.generic.model.GenericDataSource.<init>(GenericDataSource.java:124)
at org.jkiss.dbeaver.ext.h2.model.H2DataSource.<init>(H2DataSource.java:43)
at org.jkiss.dbeaver.ext.h2.model.H2MetaModel.createDataSourceImpl(H2MetaModel.java:55)
at org.jkiss.dbeaver.ext.generic.GenericDataSourceProvider.openDataSource(GenericDataSourceProvider.java:106)
at org.jkiss.dbeaver.registry.DataSourceDescriptor.openDataSource(DataSourceDescriptor.java:1402)
at org.jkiss.dbeaver.registry.DataSourceDescriptor.connect0(DataSourceDescriptor.java:1239)
at org.jkiss.dbeaver.registry.DataSourceDescriptor.connect(DataSourceDescriptor.java:1025)
at org.jkiss.dbeaver.runtime.jobs.ConnectJob.run(ConnectJob.java:77)
at org.jkiss.dbeaver.runtime.jobs.ConnectJob.runSync(ConnectJob.java:104)
at org.jkiss.dbeaver.ui.actions.datasource.DataSourceHandler.connectToDataSource(DataSourceHandler.java:117)
at org.jkiss.dbeaver.ui.actions.datasource.UIServiceConnectionsImpl.initConnection(UIServiceConnectionsImpl.java:87)
at org.jkiss.dbeaver.model.DBUtils.initDataSource(DBUtils.java:2488)
at org.jkiss.dbeaver.model.navigator.DBNDataSource.initializeNode(DBNDataSource.java:158)
at org.jkiss.dbeaver.model.navigator.DBNDatabaseNode.getChildren(DBNDatabaseNode.java:227)
at org.jkiss.dbeaver.model.navigator.DBNDatabaseNode.getChildren(DBNDatabaseNode.java:1)
at org.jkiss.dbeaver.model.navigator.DBNUtils.getNodeChildrenFiltered(DBNUtils.java:91)
at org.jkiss.dbeaver.ui.navigator.database.load.TreeLoadService.evaluate(TreeLoadService.java:49)
at org.jkiss.dbeaver.ui.navigator.database.load.TreeLoadService.evaluate(TreeLoadService.java:1)
at org.jkiss.dbeaver.ui.LoadingJob.run(LoadingJob.java:89)
at org.jkiss.dbeaver.ui.LoadingJob.run(LoadingJob.java:73)
at org.jkiss.dbeaver.model.runtime.AbstractJob.run(AbstractJob.java:114)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)

View File

@ -3,21 +3,22 @@ package com.example.demo.entrysData.api;
import com.fasterxml.jackson.annotation.JsonProperty;
import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotBlank;
import jakarta.validation.constraints.NotNull;
public class EntrysDataDto {
@JsonProperty(access = JsonProperty.Access.READ_ONLY)
private Long id;
@NotNull
@NotBlank
private String login;
@NotNull
private String role;
@NotNull
@NotBlank
private String password;
@NotNull
@Min(1)
private Long departmentId;
@JsonProperty(access = JsonProperty.Access.READ_ONLY)
public Long getId() {
return id;
}
@ -39,8 +40,8 @@ public class EntrysDataDto {
return role;
}
public void setRole(String role) {
this.role = role;
public void setRole() {
this.role = "user";
}
public String getPassword() {

View File

@ -54,8 +54,8 @@ public class EntrysDataEntity extends BaseEntity {
return role;
}
public void setRole(String role) {
this.role = role;
public void setRole() {
this.role = "user";
}
public DepartmentEntity getDepartment() {

View File

@ -56,6 +56,7 @@ public class EntrysDataService {
existsEntity.setLogin(entity.getLogin());
existsEntity.setPassword(entity.getPassword());
existsEntity.setDepartment(entity.getDepartment());
existsEntity.setRole();
return repository.save(existsEntity);
}