no message

This commit is contained in:
2025-03-27 12:45:55 +03:00
parent 19afec4d25
commit fb296a02ee
17 changed files with 234 additions and 125 deletions

View File

@@ -5,6 +5,7 @@ import Common.Database.RepositoryRefuseException;
import Common.Utils.Utils_;
import _VisualDVM.ComponentsServer.BugReport.BugReport;
import _VisualDVM.ComponentsServer.BugReport.Json.BugReportAdditionJson;
import _VisualDVM.ComponentsServer.BugReportSetting.BugReportSetting;
import _VisualDVM.ComponentsServer.Component.ComponentType;
import _VisualDVM.ComponentsServer.Component.Json.ComponentPublicationInfoJson;
import _VisualDVM.ComponentsServer.Component.Json.ComponentVersionsInfoJson;
@@ -63,6 +64,18 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
}
}
@Override
protected void afterPublishAction(DBObject object) throws Exception {
if (object instanceof BugReport){
BugReport bugReport = (BugReport) object;
if (bugReport.settings!=null){
for (BugReportSetting setting: bugReport.settings){
setting.bugreport_id=bugReport.id;
db.Insert(setting);
}
}
}
}
@Override
protected void afterDeleteAction(DBObject object) throws Exception {
if (object instanceof BugReport) {
BugReport bugReport = (BugReport) object;
@@ -350,4 +363,9 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
throw new RepositoryRefuseException("Неподдерживаемый код: " + code);
}
}
@Override
public void StartAction() throws Exception {
super.StartAction();
// db.Patch();
}
}