Compare commits
1 Commits
main
...
bug_report
| Author | SHA1 | Date | |
|---|---|---|---|
| 3287410940 |
4
.idea/workspace.xml
generated
4
.idea/workspace.xml
generated
@@ -8,10 +8,6 @@
|
|||||||
<component name="ChangeListManager">
|
<component name="ChangeListManager">
|
||||||
<list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment="">
|
<list default="true" id="e42177c3-2328-4b27-8a01-35779b2beb99" name="Default Changelist" comment="">
|
||||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||||
<change beforePath="$PROJECT_DIR$/properties" beforeDir="false" afterPath="$PROJECT_DIR$/properties" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Constants.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Constants.java" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Visual/Menus/MainMenuBar/VisualiserSettingsMenu/VersionsComparisonMenu.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Visual/Menus/MainMenuBar/VisualiserSettingsMenu/VersionsComparisonMenu.java" afterDir="false" />
|
|
||||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Visual/Windows/ComparisonForm.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Visual/Windows/ComparisonForm.java" afterDir="false" />
|
|
||||||
</list>
|
</list>
|
||||||
<option name="SHOW_DIALOG" value="false" />
|
<option name="SHOW_DIALOG" value="false" />
|
||||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
"ServerUserPassword": "mprit_2011",
|
"ServerUserPassword": "mprit_2011",
|
||||||
"OfferRegistrationOnStart": true,
|
"OfferRegistrationOnStart": true,
|
||||||
"Workspace": "E:\\Tests",
|
"Workspace": "E:\\Tests",
|
||||||
"ProjectsSearchDirectory": "E:\\Tests\\Downloads\\1331\\EP\\v1\\v1\\v4",
|
"ProjectsSearchDirectory": "E:\\Tests\\Downloads\\bugreport_1765484296",
|
||||||
"DocumentsDirectory": "C:\\Users\\misha\\Documents\\_testing_system",
|
"DocumentsDirectory": "C:\\Users\\misha\\Documents\\_testing_system",
|
||||||
"VisualiserPath": "C:\\Users\\misha\\Downloads",
|
"VisualiserPath": "C:\\Users\\misha\\Downloads",
|
||||||
"Sapfor_FPath": "E:\\_sapfor_x64\\Components\\Sapfor_F",
|
"Sapfor_FPath": "E:\\_sapfor_x64\\Components\\Sapfor_F",
|
||||||
@@ -34,7 +34,7 @@
|
|||||||
"CreateEthalonTasks": true,
|
"CreateEthalonTasks": true,
|
||||||
"ErasePackageWorkspace": true,
|
"ErasePackageWorkspace": true,
|
||||||
"lastMachineId": 13,
|
"lastMachineId": 13,
|
||||||
"lastUserId": 24,
|
"lastUserId": 34,
|
||||||
"lastCompilerId": 52,
|
"lastCompilerId": 52,
|
||||||
"RegisterOn": false,
|
"RegisterOn": false,
|
||||||
"SpacesOn": false,
|
"SpacesOn": false,
|
||||||
|
|||||||
32
src/Common/Database/Objects/rDBObject.java
Normal file
32
src/Common/Database/Objects/rDBObject.java
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
package Common.Database.Objects;
|
||||||
|
import java.util.Date;
|
||||||
|
//объект репозитория. ключ имя, и есть данные отправителя.
|
||||||
|
public class rDBObject extends nDBObject {
|
||||||
|
public String sender_name = "";
|
||||||
|
public String sender_address = "";
|
||||||
|
public String description = "";
|
||||||
|
//-
|
||||||
|
public long date = 0;
|
||||||
|
public long change_date;
|
||||||
|
public rDBObject(rDBObject src) {
|
||||||
|
this.SynchronizeFields(src);
|
||||||
|
}
|
||||||
|
public rDBObject() {
|
||||||
|
}
|
||||||
|
public Date getDate() {
|
||||||
|
return new Date(date);
|
||||||
|
}
|
||||||
|
public Date getChangeDate() {
|
||||||
|
return new Date(change_date);
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public void SynchronizeFields(DBObject src) {
|
||||||
|
super.SynchronizeFields(src);
|
||||||
|
rDBObject r = (rDBObject) src;
|
||||||
|
sender_name = r.sender_name;
|
||||||
|
sender_address = r.sender_address;
|
||||||
|
description = r.description;
|
||||||
|
date = r.date;
|
||||||
|
change_date = r.change_date;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,7 +1,6 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReport;
|
package _VisualDVM.ComponentsServer.BugReport;
|
||||||
import Common.CommonConstants;
|
|
||||||
import Common.Database.Objects.DBObject;
|
import Common.Database.Objects.DBObject;
|
||||||
import Common.Database.Objects.riDBObject;
|
import Common.Database.Objects.rDBObject;
|
||||||
import Common.Utils.TextLog;
|
import Common.Utils.TextLog;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
import Common.Utils.Vector_;
|
import Common.Utils.Vector_;
|
||||||
@@ -18,8 +17,7 @@ import java.io.File;
|
|||||||
import java.nio.file.Paths;
|
import java.nio.file.Paths;
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
public class BugReport extends riDBObject {
|
public class BugReport extends rDBObject {
|
||||||
//---
|
|
||||||
public String project_version = "";
|
public String project_version = "";
|
||||||
public long visualiser_version = -1;
|
public long visualiser_version = -1;
|
||||||
public long sapfor_version = -1;
|
public long sapfor_version = -1;
|
||||||
@@ -40,17 +38,13 @@ public class BugReport extends riDBObject {
|
|||||||
public File owner = null;
|
public File owner = null;
|
||||||
@Description("IGNORE")
|
@Description("IGNORE")
|
||||||
public byte[] packed_archive = null;
|
public byte[] packed_archive = null;
|
||||||
//--
|
|
||||||
public long date = 0;
|
|
||||||
public long change_date;
|
|
||||||
//--
|
|
||||||
public BugReport() {
|
public BugReport() {
|
||||||
}
|
}
|
||||||
public BugReport(BugReport src) {
|
public BugReport(BugReport src) {
|
||||||
this.SynchronizeFields(src);
|
this.SynchronizeFields(src);
|
||||||
}
|
}
|
||||||
public BugReport(String sender_name_in, String sender_address_in, String description_in, String version_in) {
|
public BugReport(String sender_name_in, String sender_address_in, String description_in, String version_in) {
|
||||||
id = CommonConstants.Nan;
|
genName();
|
||||||
sender_name = sender_name_in;
|
sender_name = sender_name_in;
|
||||||
sender_address = sender_address_in;
|
sender_address = sender_address_in;
|
||||||
project_version = version_in;
|
project_version = version_in;
|
||||||
@@ -82,16 +76,11 @@ public class BugReport extends riDBObject {
|
|||||||
descriptionAdditionDraft = b.descriptionAdditionDraft;
|
descriptionAdditionDraft = b.descriptionAdditionDraft;
|
||||||
commentAdditionDraft = b.commentAdditionDraft;
|
commentAdditionDraft = b.commentAdditionDraft;
|
||||||
owner = b.owner;
|
owner = b.owner;
|
||||||
change_date = b.change_date;
|
|
||||||
}
|
}
|
||||||
//--
|
//--
|
||||||
public File getHome() {
|
|
||||||
return Utils_.getFile(System.getProperty("user.dir"), "BugReports", String.valueOf(id));
|
|
||||||
}
|
|
||||||
public File getArchiveFile() {
|
public File getArchiveFile() {
|
||||||
return new File(getHome(),id + ".zip");
|
return Paths.get(System.getProperty("user.dir"), "Bugs", id + ".zip").toFile();
|
||||||
}
|
}
|
||||||
//--
|
|
||||||
public String getDescriptionHeader() {
|
public String getDescriptionHeader() {
|
||||||
if (description != null) {
|
if (description != null) {
|
||||||
String[] data = description.split("\n");
|
String[] data = description.split("\n");
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReport;
|
package _VisualDVM.ComponentsServer.BugReport;
|
||||||
import Common.Database.Objects.DBObject;
|
import Common.Database.Objects.DBObject;
|
||||||
|
import Common.Database.Tables.DBTable;
|
||||||
import Common.Database.Tables.FKBehaviour;
|
import Common.Database.Tables.FKBehaviour;
|
||||||
import Common.Database.Tables.FKCurrentObjectBehaviuor;
|
import Common.Database.Tables.FKCurrentObjectBehaviuor;
|
||||||
import Common.Database.Tables.FKDataBehaviour;
|
import Common.Database.Tables.FKDataBehaviour;
|
||||||
import Common.Database.Tables.iDBTable;
|
|
||||||
import Common.Visual.DataSetControlForm;
|
import Common.Visual.DataSetControlForm;
|
||||||
import _VisualDVM.ComponentsServer.BugReport.UI.BugReportsForm;
|
import _VisualDVM.ComponentsServer.BugReport.UI.BugReportsForm;
|
||||||
import _VisualDVM.ComponentsServer.BugReportFile.BugReportFile;
|
|
||||||
import _VisualDVM.ComponentsServer.BugReportRecipient.BugReportRecipient;
|
import _VisualDVM.ComponentsServer.BugReportRecipient.BugReportRecipient;
|
||||||
import _VisualDVM.ComponentsServer.BugReportSetting.BugReportSetting;
|
import _VisualDVM.ComponentsServer.BugReportSetting.BugReportSetting;
|
||||||
|
|
||||||
@@ -14,9 +13,9 @@ import javax.swing.*;
|
|||||||
import java.util.LinkedHashMap;
|
import java.util.LinkedHashMap;
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
public class BugReportsDBTable extends iDBTable<BugReport> {
|
public class BugReportsDBTable extends DBTable<String, BugReport> {
|
||||||
public BugReportsDBTable() {
|
public BugReportsDBTable() {
|
||||||
super(BugReport.class);
|
super(String.class, BugReport.class);
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public String getSingleDescription() {
|
public String getSingleDescription() {
|
||||||
@@ -38,7 +37,6 @@ public class BugReportsDBTable extends iDBTable<BugReport> {
|
|||||||
LinkedHashMap<Class<? extends DBObject>, FKBehaviour> res = new LinkedHashMap<>();
|
LinkedHashMap<Class<? extends DBObject>, FKBehaviour> res = new LinkedHashMap<>();
|
||||||
res.put(BugReportSetting.class, new FKBehaviour(FKDataBehaviour.DELETE, FKCurrentObjectBehaviuor.PASSIVE));
|
res.put(BugReportSetting.class, new FKBehaviour(FKDataBehaviour.DELETE, FKCurrentObjectBehaviuor.PASSIVE));
|
||||||
res.put(BugReportRecipient.class, new FKBehaviour(FKDataBehaviour.DELETE, FKCurrentObjectBehaviuor.PASSIVE));
|
res.put(BugReportRecipient.class, new FKBehaviour(FKDataBehaviour.DELETE, FKCurrentObjectBehaviuor.PASSIVE));
|
||||||
res.put(BugReportFile.class, new FKBehaviour(FKDataBehaviour.DELETE, FKCurrentObjectBehaviuor.ACTIVE));
|
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
//-
|
//-
|
||||||
|
|||||||
@@ -1,12 +1,11 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReport.Json;
|
package _VisualDVM.ComponentsServer.BugReport.Json;
|
||||||
import Common.CommonConstants;
|
|
||||||
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
||||||
import com.google.gson.annotations.Expose;
|
import com.google.gson.annotations.Expose;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
public class BugReportAdditionJson implements Serializable {
|
public class BugReportAdditionJson implements Serializable {
|
||||||
@Expose
|
@Expose
|
||||||
public int id = CommonConstants.Nan;
|
public String id = "";
|
||||||
@Expose
|
@Expose
|
||||||
public String fieldName = "";
|
public String fieldName = "";
|
||||||
@Expose
|
@Expose
|
||||||
|
|||||||
@@ -101,14 +101,6 @@ public class BugReportsForm extends DataSetControlForm<BugReport> {
|
|||||||
return RendererStatusEnum.class;
|
return RendererStatusEnum.class;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
/*,
|
|
||||||
new ColumnInfo<BugReport>("id_") {
|
|
||||||
@Override
|
|
||||||
public Object getFieldAt(BugReport object) {
|
|
||||||
return object.id_;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
@@ -151,7 +143,7 @@ public class BugReportsForm extends DataSetControlForm<BugReport> {
|
|||||||
public DataMenuBar createMenuBar() {
|
public DataMenuBar createMenuBar() {
|
||||||
return new DataMenuBar(dataSource.getPluralDescription(),
|
return new DataMenuBar(dataSource.getPluralDescription(),
|
||||||
PassCode.SynchronizeBugReports,
|
PassCode.SynchronizeBugReports,
|
||||||
// PassCode.DownloadAllBugReportsArchives,
|
PassCode.DownloadAllBugReportsArchives,
|
||||||
PassCode.AddBugReport,
|
PassCode.AddBugReport,
|
||||||
PassCode.PublishBugReport,
|
PassCode.PublishBugReport,
|
||||||
PassCode.OpenBugReportTestProject,
|
PassCode.OpenBugReportTestProject,
|
||||||
@@ -162,14 +154,13 @@ public class BugReportsForm extends DataSetControlForm<BugReport> {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected Comparator<BugReport> getDefaultComparator() {
|
protected Comparator<BugReport> getDefaultComparator() {
|
||||||
|
return (o1, o2) -> -(o1.getDate().compareTo(o2.getDate()));
|
||||||
return (o1, o2) -> -Long.compare(o1.date, o2.date);
|
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public boolean isObjectVisible(BugReport object) {
|
public boolean isObjectVisible(BugReport object) {
|
||||||
return super.isObjectVisible(object) && (
|
return super.isObjectVisible(object) && (
|
||||||
object.state.equals(BugReportState.draft) ||
|
object.state.equals(BugReportState.draft) ||
|
||||||
(String.valueOf(object.id)).toUpperCase().contains(filterKey.toUpperCase())
|
object.id.toUpperCase().contains(filterKey.toUpperCase())
|
||||||
&& object.sender_name.toUpperCase().contains(filterSenderName.toUpperCase())
|
&& object.sender_name.toUpperCase().contains(filterSenderName.toUpperCase())
|
||||||
&& object.description.toUpperCase().contains(filterDescription.toUpperCase())
|
&& object.description.toUpperCase().contains(filterDescription.toUpperCase())
|
||||||
&& object.comment.toUpperCase().contains(filterComment.toUpperCase())
|
&& object.comment.toUpperCase().contains(filterComment.toUpperCase())
|
||||||
|
|||||||
@@ -1,25 +0,0 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReportFile;
|
|
||||||
import Common.CommonConstants;
|
|
||||||
import Common.Database.Objects.DBObject;
|
|
||||||
import Common.Database.Objects.riDBObject;
|
|
||||||
import com.sun.org.glassfish.gmbal.Description;
|
|
||||||
public class BugReportFile extends riDBObject {
|
|
||||||
@Description("DEFAULT -1")
|
|
||||||
public int bugreport_id = CommonConstants.Nan;
|
|
||||||
@Description("DEFAULT ''")
|
|
||||||
public String name = "";
|
|
||||||
@Override
|
|
||||||
public void SynchronizeFields(DBObject src) {
|
|
||||||
super.SynchronizeFields(src);
|
|
||||||
BugReportFile f = (BugReportFile) src;
|
|
||||||
bugreport_id = f.bugreport_id;
|
|
||||||
name = f.name;
|
|
||||||
}
|
|
||||||
//-
|
|
||||||
public BugReportFile(BugReportFile src) {
|
|
||||||
SynchronizeFields(src);
|
|
||||||
}
|
|
||||||
public BugReportFile() {
|
|
||||||
}
|
|
||||||
//-
|
|
||||||
}
|
|
||||||
@@ -1,23 +0,0 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReportFile;
|
|
||||||
import Common.Database.Tables.iDBTable;
|
|
||||||
import Common.Visual.DataSetControlForm;
|
|
||||||
import _VisualDVM.ComponentsServer.BugReportFile.UI.BugReportFilesForm;
|
|
||||||
|
|
||||||
import javax.swing.*;
|
|
||||||
public class BugReportFilesDBTable extends iDBTable<BugReportFile> {
|
|
||||||
public BugReportFilesDBTable() {
|
|
||||||
super(BugReportFile.class);
|
|
||||||
}
|
|
||||||
@Override
|
|
||||||
public String getSingleDescription() {
|
|
||||||
return "файл";
|
|
||||||
}
|
|
||||||
@Override
|
|
||||||
public String getPluralDescription() {
|
|
||||||
return "файлы";
|
|
||||||
}
|
|
||||||
@Override
|
|
||||||
protected DataSetControlForm createUI(JPanel mountPanel) {
|
|
||||||
return new BugReportFilesForm(this, mountPanel);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,29 +0,0 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReportFile.UI;
|
|
||||||
import Common.Database.Tables.DataSet;
|
|
||||||
import Common.Visual.DataSetControlForm;
|
|
||||||
import Common.Visual.Tables.ColumnInfo;
|
|
||||||
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
|
||||||
import _VisualDVM.ComponentsServer.BugReportFile.BugReportFile;
|
|
||||||
import _VisualDVM.Global;
|
|
||||||
|
|
||||||
import javax.swing.*;
|
|
||||||
public class BugReportFilesForm extends DataSetControlForm<BugReportFile> {
|
|
||||||
public BugReportFilesForm(DataSet<?, BugReportFile> dataSource_in, JPanel mountPanel_in) {
|
|
||||||
super(dataSource_in, mountPanel_in);
|
|
||||||
}
|
|
||||||
@Override
|
|
||||||
protected void createColumns() {
|
|
||||||
AddColumns(
|
|
||||||
new ColumnInfo<BugReportFile>("имя") {
|
|
||||||
@Override
|
|
||||||
public Object getFieldAt(BugReportFile object) {
|
|
||||||
return object.name;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
);
|
|
||||||
}
|
|
||||||
@Override
|
|
||||||
public boolean isObjectVisible(BugReportFile object) {
|
|
||||||
return super.isObjectVisible(object)&&Global.componentsServer.db.getTable(BugReport.class).getUI().matchCurrentID(object.bugreport_id);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,13 +1,10 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReportRecipient;
|
package _VisualDVM.ComponentsServer.BugReportRecipient;
|
||||||
import Common.CommonConstants;
|
|
||||||
import Common.Database.Objects.DBObject;
|
import Common.Database.Objects.DBObject;
|
||||||
import Common.Database.Objects.iDBObject;
|
import Common.Database.Objects.iDBObject;
|
||||||
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
||||||
import com.sun.org.glassfish.gmbal.Description;
|
|
||||||
public class BugReportRecipient extends iDBObject {
|
public class BugReportRecipient extends iDBObject {
|
||||||
|
public String bugreport_id = "";
|
||||||
public String email = "";
|
public String email = "";
|
||||||
@Description("DEFAULT '-1'")
|
|
||||||
public int bugreport_id = CommonConstants.Nan;
|
|
||||||
public BugReportRecipient() {
|
public BugReportRecipient() {
|
||||||
}
|
}
|
||||||
public BugReportRecipient(BugReport bugReport, String email_in) {
|
public BugReportRecipient(BugReport bugReport, String email_in) {
|
||||||
|
|||||||
@@ -6,6 +6,6 @@ public class BugReportRecipientsDBTable extends iDBTable<BugReportRecipient> {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public boolean isEqual(BugReportRecipient o1, BugReportRecipient o2) {
|
public boolean isEqual(BugReportRecipient o1, BugReportRecipient o2) {
|
||||||
return o1.bugreport_id==o2.bugreport_id && o1.email.equals(o2.email);
|
return o1.bugreport_id.equals(o2.bugreport_id) && o1.email.equals(o2.email);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,14 +1,11 @@
|
|||||||
package _VisualDVM.ComponentsServer.BugReportSetting;
|
package _VisualDVM.ComponentsServer.BugReportSetting;
|
||||||
import Common.CommonConstants;
|
|
||||||
import Common.Database.Objects.DBObject;
|
import Common.Database.Objects.DBObject;
|
||||||
import Common.Database.Objects.iDBObject;
|
import Common.Database.Objects.iDBObject;
|
||||||
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
||||||
import com.sun.org.glassfish.gmbal.Description;
|
|
||||||
public class BugReportSetting extends iDBObject {
|
public class BugReportSetting extends iDBObject {
|
||||||
|
public String bugreport_id = "";
|
||||||
public String name = "";
|
public String name = "";
|
||||||
public String value = "";
|
public String value = "";
|
||||||
@Description("DEFAULT '-1'")
|
|
||||||
public int bugreport_id = CommonConstants.Nan;
|
|
||||||
public BugReportSetting() {
|
public BugReportSetting() {
|
||||||
}
|
}
|
||||||
public BugReportSetting(BugReport bugReport, String name_in, Object value_in) {
|
public BugReportSetting(BugReport bugReport, String name_in, Object value_in) {
|
||||||
|
|||||||
@@ -2,7 +2,6 @@ package _VisualDVM.ComponentsServer;
|
|||||||
import Common.Database.SQLITE.SQLiteDatabase;
|
import Common.Database.SQLITE.SQLiteDatabase;
|
||||||
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
||||||
import _VisualDVM.ComponentsServer.BugReport.BugReportsDBTable;
|
import _VisualDVM.ComponentsServer.BugReport.BugReportsDBTable;
|
||||||
import _VisualDVM.ComponentsServer.BugReportFile.BugReportFilesDBTable;
|
|
||||||
import _VisualDVM.ComponentsServer.BugReportRecipient.BugReportRecipient;
|
import _VisualDVM.ComponentsServer.BugReportRecipient.BugReportRecipient;
|
||||||
import _VisualDVM.ComponentsServer.BugReportRecipient.BugReportRecipientsDBTable;
|
import _VisualDVM.ComponentsServer.BugReportRecipient.BugReportRecipientsDBTable;
|
||||||
import _VisualDVM.ComponentsServer.BugReportSetting.BugReportSettingsDBTable;
|
import _VisualDVM.ComponentsServer.BugReportSetting.BugReportSettingsDBTable;
|
||||||
@@ -15,7 +14,6 @@ public class BugReportsDatabase extends SQLiteDatabase {
|
|||||||
public BugReportsDBTable bugReports;
|
public BugReportsDBTable bugReports;
|
||||||
public BugReportSettingsDBTable bugReportSettings;
|
public BugReportSettingsDBTable bugReportSettings;
|
||||||
public BugReportRecipientsDBTable bugReportRecipients;
|
public BugReportRecipientsDBTable bugReportRecipients;
|
||||||
public BugReportFilesDBTable bugReportsFiles;
|
|
||||||
public RecipientsDataSet recipients = new RecipientsDataSet();
|
public RecipientsDataSet recipients = new RecipientsDataSet();
|
||||||
public BugReportsDatabase() {
|
public BugReportsDatabase() {
|
||||||
super(Paths.get(System.getProperty("user.dir"), "Data", "bug_reports.sqlite").toFile());
|
super(Paths.get(System.getProperty("user.dir"), "Data", "bug_reports.sqlite").toFile());
|
||||||
@@ -25,13 +23,10 @@ public class BugReportsDatabase extends SQLiteDatabase {
|
|||||||
addTable(bugReports = new BugReportsDBTable());
|
addTable(bugReports = new BugReportsDBTable());
|
||||||
addTable(bugReportSettings = new BugReportSettingsDBTable());
|
addTable(bugReportSettings = new BugReportSettingsDBTable());
|
||||||
addTable(bugReportRecipients = new BugReportRecipientsDBTable());
|
addTable(bugReportRecipients = new BugReportRecipientsDBTable());
|
||||||
addTable(bugReportsFiles = new BugReportFilesDBTable());
|
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public void Init() throws Exception {
|
public void Init() throws Exception {
|
||||||
DeleteDrafts();
|
DeleteDrafts();
|
||||||
//--
|
|
||||||
Patch();
|
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public PassCode getSynchronizePassCode() {
|
public PassCode getSynchronizePassCode() {
|
||||||
@@ -63,72 +58,5 @@ public class BugReportsDatabase extends SQLiteDatabase {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
public void Patch() throws Exception {
|
public void Patch() throws Exception {
|
||||||
/*
|
|
||||||
int i = 0;
|
|
||||||
Vector<BugReport> sortedBugs = new Vector<>(bugReports.Data.values());
|
|
||||||
sortedBugs.sort(new Comparator<BugReport>() {
|
|
||||||
@Override
|
|
||||||
public int compare(BugReport o1, BugReport o2) {
|
|
||||||
return Long.compare(o1.date,o2.date);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
//--
|
|
||||||
for (BugReport bugReport: sortedBugs){
|
|
||||||
bugReport.id_ = i;
|
|
||||||
++i;
|
|
||||||
//--
|
|
||||||
Update(bugReport);
|
|
||||||
}
|
|
||||||
//--
|
|
||||||
for (BugReport bugReport: sortedBugs){
|
|
||||||
Vector<BugReportSetting> bugSettings = getVectorByFK(bugReport, BugReportSetting.class);
|
|
||||||
Vector<BugReportRecipient> bugReportRecipients = getVectorByFK(bugReport, BugReportRecipient.class);
|
|
||||||
for (BugReportSetting setting: bugSettings){
|
|
||||||
setting.bugreport_id_ = bugReport.id_;
|
|
||||||
Update(setting);
|
|
||||||
}
|
|
||||||
for (BugReportRecipient recipient: bugReportRecipients){
|
|
||||||
recipient.bugreport_id_ = bugReport.id_;
|
|
||||||
Update(recipient);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//перенос архивов
|
|
||||||
for (BugReport bugReport: sortedBugs){
|
|
||||||
System.out.println("bugreport_id="+bugReport.id+"/"+bugReport.id_);
|
|
||||||
File new_home = new File(Global.BugReportsDirectory,String.valueOf(bugReport.id_));
|
|
||||||
//--
|
|
||||||
if (!new_home.exists())
|
|
||||||
FileUtils.forceMkdir(new_home);
|
|
||||||
//--
|
|
||||||
Utils.CleanDirectory(new_home);
|
|
||||||
//--
|
|
||||||
File old_archive = new File(Global.BugReportsDirectory_OLD, bugReport.id);
|
|
||||||
File new_archive = new File(new_home,String.valueOf(bugReport.id_)+".zip");
|
|
||||||
if (old_archive.exists()) {
|
|
||||||
FileUtils.copyFile(old_archive, new_archive);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//--
|
|
||||||
//упоминания других багов.
|
|
||||||
for (BugReport bugReport: sortedBugs){
|
|
||||||
//--
|
|
||||||
Vector<String> mentioned_keys = new Vector<>();
|
|
||||||
for (String id: bugReports.Data.keySet()){
|
|
||||||
if ((bugReport.description.contains(id) || bugReport.comment.contains(id)) && !mentioned_keys.contains(id)){
|
|
||||||
mentioned_keys.add(id);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//--
|
|
||||||
for (String id: mentioned_keys){
|
|
||||||
BugReport owner = bugReports.get(id);
|
|
||||||
if (owner!=null) {
|
|
||||||
bugReport.comment = bugReport.comment.replace(id, String.valueOf(owner.id_));
|
|
||||||
bugReport.description = bugReport.description.replace(id, String.valueOf(owner.id_));
|
|
||||||
Update(bugReport);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,7 +22,6 @@ import org.apache.commons.io.FileUtils;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.nio.charset.Charset;
|
import java.nio.charset.Charset;
|
||||||
import java.util.*;
|
import java.util.*;
|
||||||
import java.util.concurrent.TimeUnit;
|
|
||||||
public abstract class Sapfor extends OSDComponent {
|
public abstract class Sapfor extends OSDComponent {
|
||||||
public static final int empty_code = -100;
|
public static final int empty_code = -100;
|
||||||
public static final int canceled_code = -99;
|
public static final int canceled_code = -99;
|
||||||
@@ -107,10 +106,9 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
}
|
}
|
||||||
public static PassCode[] getPreparationTransformationsCodes() {
|
public static PassCode[] getPreparationTransformationsCodes() {
|
||||||
return new PassCode[]{
|
return new PassCode[]{
|
||||||
PassCode.SPF_CorrectCodeStylePass,
|
|
||||||
PassCode.SPF_MoveOperators,
|
|
||||||
PassCode.SPF_RenameIncludes,
|
PassCode.SPF_RenameIncludes,
|
||||||
PassCode.SPF_InsertIncludesPass,
|
PassCode.SPF_InsertIncludesPass,
|
||||||
|
PassCode.SPF_CorrectCodeStylePass,
|
||||||
PassCode.SPF_ConvertStructures,
|
PassCode.SPF_ConvertStructures,
|
||||||
PassCode.SPF_CreateCheckpoints,
|
PassCode.SPF_CreateCheckpoints,
|
||||||
PassCode.SPF_InitDeclsWithZero,
|
PassCode.SPF_InitDeclsWithZero,
|
||||||
@@ -164,7 +162,6 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
res.add(PassCode.SPF_InsertDvmhRegions);//+
|
res.add(PassCode.SPF_InsertDvmhRegions);//+
|
||||||
res.add(PassCode.SPF_SharedMemoryParallelization);//+
|
res.add(PassCode.SPF_SharedMemoryParallelization);//+
|
||||||
res.add(PassCode.SPF_InsertImplicitNone);//+
|
res.add(PassCode.SPF_InsertImplicitNone);//+
|
||||||
res.add(PassCode.SPF_MoveOperators);
|
|
||||||
res.add(PassCode.CreateParallelVariants); //?
|
res.add(PassCode.CreateParallelVariants); //?
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
@@ -207,10 +204,8 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
Utils_.CheckDirectory(data_workspace);
|
Utils_.CheckDirectory(data_workspace);
|
||||||
File outputFile = new File(data_workspace, outName);
|
File outputFile = new File(data_workspace, outName);
|
||||||
File errorsFile = new File(data_workspace, errName);
|
File errorsFile = new File(data_workspace, errName);
|
||||||
// File logFile = new File(data_workspace, "log.txt");
|
|
||||||
Utils_.forceDeleteWithCheck(outputFile);
|
Utils_.forceDeleteWithCheck(outputFile);
|
||||||
Utils_.forceDeleteWithCheck(errorsFile);
|
Utils_.forceDeleteWithCheck(errorsFile);
|
||||||
// Utils_.forceDeleteWithCheck(logFile);
|
|
||||||
//---
|
//---
|
||||||
File file = new File(data_workspace, name + (Utils_.isWindows() ? ".bat" : ".sh"));
|
File file = new File(data_workspace, name + (Utils_.isWindows() ? ".bat" : ".sh"));
|
||||||
FileUtils.write(file,
|
FileUtils.write(file,
|
||||||
@@ -226,36 +221,20 @@ public abstract class Sapfor extends OSDComponent {
|
|||||||
if (!file.setExecutable(true))
|
if (!file.setExecutable(true))
|
||||||
throw new Exception("Не удалось сделать файл скрипта " + name + " исполняемым!");
|
throw new Exception("Не удалось сделать файл скрипта " + name + " исполняемым!");
|
||||||
//-- Windows
|
//-- Windows
|
||||||
//запустить процесс
|
boolean flag = false;
|
||||||
boolean process_started = false;
|
|
||||||
do {
|
do {
|
||||||
try {
|
try {
|
||||||
ProcessBuilder procBuilder = new ProcessBuilder(file.getAbsolutePath());
|
ProcessBuilder procBuilder = new ProcessBuilder(file.getAbsolutePath());
|
||||||
procBuilder.directory(workspace);
|
procBuilder.directory(workspace);
|
||||||
process = procBuilder.start();
|
process = procBuilder.start();
|
||||||
process_started = true;
|
exit_code = process.waitFor();
|
||||||
|
flag = true;
|
||||||
} catch (Exception ex) {
|
} catch (Exception ex) {
|
||||||
Utils_.MainLog.PrintException(ex);
|
Utils_.MainLog.PrintException(ex);
|
||||||
Utils_.sleep(1000);
|
Utils_.sleep(1000);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
while (!process_started);
|
while (!flag);
|
||||||
//--
|
|
||||||
for (int i=0; i<40; ++i){
|
|
||||||
if (process.waitFor(1, TimeUnit.SECONDS)){
|
|
||||||
//дождались. все хорошо.
|
|
||||||
exit_code=0;
|
|
||||||
// FileUtils.writeStringToFile(logFile,sapfor_drv.getName()+" done for "+i+" seconds");
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (exit_code!=0){
|
|
||||||
// FileUtils.writeStringToFile(logFile,sapfor_drv.getName()+" timeout");
|
|
||||||
//-
|
|
||||||
Process killer = Runtime.getRuntime().exec("pkill -SIGKILL -f "+sapfor_drv.getName());
|
|
||||||
killer.waitFor();
|
|
||||||
//-
|
|
||||||
}
|
|
||||||
process = null;
|
process = null;
|
||||||
//---
|
//---
|
||||||
Vector<String> outputLines = new Vector<>(FileUtils.readLines(outputFile));
|
Vector<String> outputLines = new Vector<>(FileUtils.readLines(outputFile));
|
||||||
|
|||||||
@@ -46,7 +46,7 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void extraBackup(File todayBackUp) {
|
protected void extraBackup(File todayBackUp) {
|
||||||
zip.Do("BugReports", new File(todayBackUp, "BugReports.zip").getAbsolutePath());
|
zip.Do("Bugs", new File(todayBackUp, "Bugs.zip").getAbsolutePath());
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
public Database getDb() {
|
public Database getDb() {
|
||||||
@@ -55,9 +55,18 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
|
|||||||
return super.getDb();
|
return super.getDb();
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
|
protected void beforePublishAction(DBObject object) throws Exception {
|
||||||
|
if (object instanceof BugReport) {
|
||||||
|
BugReport bugReport = (BugReport) object;
|
||||||
|
if (bugReport.packed_archive != null) {
|
||||||
|
File bugArchive = Utils_.getFile(Utils_.getHomePath(), "Bugs", bugReport.id);
|
||||||
|
Utils_.bytesToFile(bugReport.packed_archive, bugArchive);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@Override
|
||||||
protected void afterPublishAction(DBObject object) throws Exception {
|
protected void afterPublishAction(DBObject object) throws Exception {
|
||||||
if (object instanceof BugReport) {
|
if (object instanceof BugReport) {
|
||||||
//---
|
|
||||||
BugReport bugReport = (BugReport) object;
|
BugReport bugReport = (BugReport) object;
|
||||||
if (bugReport.settings != null) {
|
if (bugReport.settings != null) {
|
||||||
for (BugReportSetting setting : bugReport.settings) {
|
for (BugReportSetting setting : bugReport.settings) {
|
||||||
@@ -68,14 +77,6 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
|
|||||||
if (bugReport.recipients != null) {
|
if (bugReport.recipients != null) {
|
||||||
db.saveBugreportRecipients(bugReport);
|
db.saveBugreportRecipients(bugReport);
|
||||||
}
|
}
|
||||||
//-->
|
|
||||||
Utils_.CheckAndCleanDirectory(bugReport.getHome());
|
|
||||||
//-->
|
|
||||||
if (bugReport.packed_archive != null) {
|
|
||||||
File bugArchive = bugReport.getArchiveFile();
|
|
||||||
Utils_.bytesToFile(bugReport.packed_archive, bugArchive);
|
|
||||||
bugReport.packed_archive = null;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
@@ -93,7 +94,7 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
|
|||||||
protected void afterDeleteAction(DBObject object) throws Exception {
|
protected void afterDeleteAction(DBObject object) throws Exception {
|
||||||
if (object instanceof BugReport) {
|
if (object instanceof BugReport) {
|
||||||
BugReport bugReport = (BugReport) object;
|
BugReport bugReport = (BugReport) object;
|
||||||
Utils_.forceDeleteWithCheck(bugReport.getHome());
|
if (!bugReport.project_version.isEmpty()) Utils_.forceDeleteWithCheck(bugReport.getArchiveFile());
|
||||||
} else if (object instanceof UserAccount) {
|
} else if (object instanceof UserAccount) {
|
||||||
UserAccount account = (UserAccount) object;
|
UserAccount account = (UserAccount) object;
|
||||||
Utils_.forceDeleteWithCheck(account.getServerKeyFile());
|
Utils_.forceDeleteWithCheck(account.getServerKeyFile());
|
||||||
@@ -169,7 +170,7 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
|
|||||||
void ReceiveAllArchives() throws Exception {
|
void ReceiveAllArchives() throws Exception {
|
||||||
ZipFolderPass zip = new ZipFolderPass();
|
ZipFolderPass zip = new ZipFolderPass();
|
||||||
File archives = new File(Utils_.getDateName("Bugs"));
|
File archives = new File(Utils_.getDateName("Bugs"));
|
||||||
if (zip.Do("BugReports", archives.getAbsolutePath())) {
|
if (zip.Do("Bugs", archives.getAbsolutePath())) {
|
||||||
response.object = Utils_.fileToBytes(archives);
|
response.object = Utils_.fileToBytes(archives);
|
||||||
} else throw new RepositoryRefuseException("Не удалось запаковать архивы");
|
} else throw new RepositoryRefuseException("Не удалось запаковать архивы");
|
||||||
}
|
}
|
||||||
@@ -178,7 +179,7 @@ public class ComponentsServer extends RepositoryServer<BugReportsDatabase> {
|
|||||||
response.arg = credentials_db.userAccounts.getPackedActiveRecipients();
|
response.arg = credentials_db.userAccounts.getPackedActiveRecipients();
|
||||||
}
|
}
|
||||||
void ReceiveBugReport() throws Exception {
|
void ReceiveBugReport() throws Exception {
|
||||||
File bugArchive = Utils_.getFile(Utils_.getHomePath(), "BugReports", request.arg, request.arg + ".zip");
|
File bugArchive = Utils_.getFile(Utils_.getHomePath(), "Bugs", request.arg);
|
||||||
response.object = Utils_.fileToBytes(bugArchive);
|
response.object = Utils_.fileToBytes(bugArchive);
|
||||||
}
|
}
|
||||||
void UpdateBugReport() throws Exception {
|
void UpdateBugReport() throws Exception {
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ package _VisualDVM.ComponentsServer.UserAccount;
|
|||||||
import Common.Database.Objects.DBObject;
|
import Common.Database.Objects.DBObject;
|
||||||
import Common.Database.Objects.iDBObject;
|
import Common.Database.Objects.iDBObject;
|
||||||
import Common.Utils.TextLog;
|
import Common.Utils.TextLog;
|
||||||
|
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import com.sun.org.glassfish.gmbal.Description;
|
import com.sun.org.glassfish.gmbal.Description;
|
||||||
import org.apache.commons.io.FileUtils;
|
import org.apache.commons.io.FileUtils;
|
||||||
@@ -74,6 +75,20 @@ public class UserAccount extends iDBObject {
|
|||||||
public boolean CheckAccessRights(String address_in, TextLog log) {
|
public boolean CheckAccessRights(String address_in, TextLog log) {
|
||||||
return (CheckRegistered(log) && CheckAuthorship(address_in, log));
|
return (CheckRegistered(log) && CheckAuthorship(address_in, log));
|
||||||
}
|
}
|
||||||
|
public boolean ExtendedCheckAccessRights(BugReport bugReport, TextLog log) {
|
||||||
|
if (CheckRegistered(log)) {
|
||||||
|
if (email.equals(bugReport.executor_address)) {
|
||||||
|
//метод вывести как нерабочий.когда будет изменена схема админства.
|
||||||
|
return true;
|
||||||
|
} else {
|
||||||
|
if (!isAdmin() && (!email.equals(bugReport.sender_address))) {
|
||||||
|
log.Writeln_("Вы не являетесь автором, исполнителем, или администратором");
|
||||||
|
return false;
|
||||||
|
} else return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
public boolean isAdmin() {
|
public boolean isAdmin() {
|
||||||
return role.equals(AccountRole.Admin);
|
return role.equals(AccountRole.Admin);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import Common.Utils.Vector_;
|
|||||||
|
|
||||||
import java.util.Vector;
|
import java.util.Vector;
|
||||||
public class Constants {
|
public class Constants {
|
||||||
public static final int version = 1265;
|
public static final int version = 1261;
|
||||||
public static final int planner_version = 24;
|
public static final int planner_version = 24;
|
||||||
public static final int testingMaxKernels = 64;
|
public static final int testingMaxKernels = 64;
|
||||||
//--
|
//--
|
||||||
@@ -47,7 +47,7 @@ public class Constants {
|
|||||||
public static final int MailSocketPort = 465;
|
public static final int MailSocketPort = 465;
|
||||||
//
|
//
|
||||||
//7998 отладочный порт. теперь.
|
//7998 отладочный порт. теперь.
|
||||||
public static final int ComponentsServerPort = 7995; //7795
|
public static final int ComponentsServerPort = 7998; //7795
|
||||||
public static final int TestingServerPort = 7996; //7996
|
public static final int TestingServerPort = 7996; //7996
|
||||||
public static final int SocketTimeout = 0;
|
public static final int SocketTimeout = 0;
|
||||||
//-
|
//-
|
||||||
|
|||||||
@@ -65,7 +65,7 @@ public class Global {
|
|||||||
Utils_.CheckDirectory(DataDirectory = new File(Utils_.getHomeDirectory(), Constants.DataDirectoryName));
|
Utils_.CheckDirectory(DataDirectory = new File(Utils_.getHomeDirectory(), Constants.DataDirectoryName));
|
||||||
//-
|
//-
|
||||||
Utils_.CheckDirectory(RepoDirectory = new File(Utils_.getHomeDirectory(), Constants.RepoDirectoryName));
|
Utils_.CheckDirectory(RepoDirectory = new File(Utils_.getHomeDirectory(), Constants.RepoDirectoryName));
|
||||||
Utils_.CheckDirectory(BugReportsDirectory = new File(Utils_.getHomeDirectory(), "BugReports"));
|
Utils_.CheckDirectory(BugReportsDirectory = new File(Utils_.getHomeDirectory(), Constants.BugsDirectoryName));
|
||||||
Utils_.CheckDirectory(BackUpsDirectory = new File(Utils_.getHomeDirectory(), Constants.BackUpsDirectoryName));
|
Utils_.CheckDirectory(BackUpsDirectory = new File(Utils_.getHomeDirectory(), Constants.BackUpsDirectoryName));
|
||||||
Utils_.CheckDirectory(ProjectsDirectory = new File(Utils_.getHomeDirectory(), Constants.ProjectsDirectoryName));
|
Utils_.CheckDirectory(ProjectsDirectory = new File(Utils_.getHomeDirectory(), Constants.ProjectsDirectoryName));
|
||||||
Utils_.CheckDirectory(CompilationTasksDirectory = new File(Utils_.getHomeDirectory(), Constants.CompilationTasksDirectoryName));
|
Utils_.CheckDirectory(CompilationTasksDirectory = new File(Utils_.getHomeDirectory(), Constants.CompilationTasksDirectoryName));
|
||||||
@@ -88,7 +88,7 @@ public class Global {
|
|||||||
Utils_.CheckDirectory(DataDirectory = new File(Utils_.getHomeDirectory(), Constants.DataDirectoryName));
|
Utils_.CheckDirectory(DataDirectory = new File(Utils_.getHomeDirectory(), Constants.DataDirectoryName));
|
||||||
Utils_.CheckDirectory(DataBackUpsDirectory = new File(Utils_.getHomeDirectory(), Constants.DataBackUpsDirectoryName));
|
Utils_.CheckDirectory(DataBackUpsDirectory = new File(Utils_.getHomeDirectory(), Constants.DataBackUpsDirectoryName));
|
||||||
//--
|
//--
|
||||||
Utils_.CheckDirectory(BugReportsDirectory = new File(Utils_.getHomeDirectory(), "BugReports"));
|
Utils_.CheckDirectory(BugReportsDirectory = new File(Utils_.getHomeDirectory(), Constants.BugsDirectoryName));
|
||||||
Utils_.CheckDirectory(KeysDirectory = new File(Utils_.getHomeDirectory(), Constants.KeyDirectoryName));
|
Utils_.CheckDirectory(KeysDirectory = new File(Utils_.getHomeDirectory(), Constants.KeyDirectoryName));
|
||||||
}
|
}
|
||||||
public static void CheckTestingSystemDirectories() {
|
public static void CheckTestingSystemDirectories() {
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
package _VisualDVM.Passes.All;
|
package _VisualDVM.Passes.All;
|
||||||
import Common.CommonConstants;
|
|
||||||
import Common.Database.Database;
|
import Common.Database.Database;
|
||||||
import Common.Passes.AddObjectPass;
|
import Common.Passes.AddObjectPass;
|
||||||
import Common.Utils.Utils_;
|
import Common.Utils.Utils_;
|
||||||
@@ -31,10 +30,6 @@ public class AddBugReport extends AddObjectPass<BugReport> {
|
|||||||
Log.Writeln_("Для создания отчёта требуется регистрация");
|
Log.Writeln_("Для создания отчёта требуется регистрация");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (getDb().getTable(BugReport.class).containsKey(CommonConstants.Nan)){
|
|
||||||
Log.Writeln_("Может существовать не более одного черновика одновременно!");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (Global.mainModule.HasProject()) {
|
if (Global.mainModule.HasProject()) {
|
||||||
String version = Global.mainModule.getProject().Home.getAbsolutePath().substring(Global.mainModule.getRoot().Home.getParent().length());
|
String version = Global.mainModule.getProject().Home.getAbsolutePath().substring(Global.mainModule.getRoot().Home.getParent().length());
|
||||||
if (version.toCharArray()[0] == '\\') version = version.substring(1);
|
if (version.toCharArray()[0] == '\\') version = version.substring(1);
|
||||||
@@ -44,7 +39,7 @@ public class AddBugReport extends AddObjectPass<BugReport> {
|
|||||||
} else {
|
} else {
|
||||||
if (UI.Warning("Создать отчёт об ошибке без прикрепления проекта.")) {
|
if (UI.Warning("Создать отчёт об ошибке без прикрепления проекта.")) {
|
||||||
target = new BugReport();
|
target = new BugReport();
|
||||||
target.id = CommonConstants.Nan;
|
target.genName();
|
||||||
target.sender_name = Global.mainModule.getAccount().name;
|
target.sender_name = Global.mainModule.getAccount().name;
|
||||||
target.sender_address = Global.mainModule.getAccount().email;
|
target.sender_address = Global.mainModule.getAccount().email;
|
||||||
target.project_version = "";
|
target.project_version = "";
|
||||||
@@ -67,12 +62,10 @@ public class AddBugReport extends AddObjectPass<BugReport> {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void body() throws Exception {
|
protected void body() throws Exception {
|
||||||
//--
|
super.body();
|
||||||
Utils_.CheckAndCleanDirectory(target.getHome());
|
|
||||||
//--
|
|
||||||
if (!target.project_version.isEmpty()) {
|
if (!target.project_version.isEmpty()) {
|
||||||
Global.mainModule.getRoot().cleanDepAndGCOVR(); //удаление депов и гкова
|
Global.mainModule.getRoot().cleanDepAndGCOVR(); //удаление депов и гкова
|
||||||
//логи во вложения. todo переделать в полноценные вложения.
|
//логи во вложения.
|
||||||
File attachementsDir = Global.mainModule.getProject().getAttachmentsDirectory();
|
File attachementsDir = Global.mainModule.getProject().getAttachmentsDirectory();
|
||||||
Vector<File> logs = new Vector<>();
|
Vector<File> logs = new Vector<>();
|
||||||
logs.add(Utils_.MainLog.getLogFile());
|
logs.add(Utils_.MainLog.getLogFile());
|
||||||
@@ -87,7 +80,6 @@ public class AddBugReport extends AddObjectPass<BugReport> {
|
|||||||
Global.mainModule.getPass(PassCode.ZipFolderPass).Do(Global.mainModule.getRoot().Home.getAbsolutePath(),
|
Global.mainModule.getPass(PassCode.ZipFolderPass).Do(Global.mainModule.getRoot().Home.getAbsolutePath(),
|
||||||
target.getArchiveFile().getAbsolutePath());
|
target.getArchiveFile().getAbsolutePath());
|
||||||
}
|
}
|
||||||
getDb().getTable(BugReport.class).put(target.id, target);
|
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected boolean validate() {
|
protected boolean validate() {
|
||||||
|
|||||||
@@ -76,7 +76,6 @@ public class AppendBugReportField extends ComponentsServerPass<BugReport> {
|
|||||||
message_header + " " + Utils_.Brackets(Global.mainModule.getAccount().name),
|
message_header + " " + Utils_.Brackets(Global.mainModule.getAccount().name),
|
||||||
message_text
|
message_text
|
||||||
);
|
);
|
||||||
|
|
||||||
Global.mainModule.getPass(PassCode.Email).Do(
|
Global.mainModule.getPass(PassCode.Email).Do(
|
||||||
message,
|
message,
|
||||||
Global.componentsServer.db.recipients.getSelectedMails());
|
Global.componentsServer.db.recipients.getSelectedMails());
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
package _VisualDVM.Passes.All;
|
package _VisualDVM.Passes.All;
|
||||||
import Common.Database.Database;
|
import Common.Database.Database;
|
||||||
import Common.Passes.DeleteObjectPass;
|
import Common.Passes.DeleteObjectPass;
|
||||||
import Common.Utils.Utils_;
|
|
||||||
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
import _VisualDVM.ComponentsServer.BugReport.BugReport;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.Passes.PassCode;
|
import _VisualDVM.Passes.PassCode;
|
||||||
@@ -16,7 +15,6 @@ public class DeleteBugReport extends DeleteObjectPass<BugReport> {
|
|||||||
@Override
|
@Override
|
||||||
protected void performDone() throws Exception {
|
protected void performDone() throws Exception {
|
||||||
super.performDone();
|
super.performDone();
|
||||||
Utils_.forceDeleteWithCheck(target.getHome());
|
|
||||||
Global.mainModule.getPass(PassCode.DeleteBugReportFromServer).Do(target);
|
Global.mainModule.getPass(PassCode.DeleteBugReportFromServer).Do(target);
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
package _VisualDVM.Passes.All;
|
package _VisualDVM.Passes.All;
|
||||||
import Common.Utils.Utils_;
|
|
||||||
import _VisualDVM.Current;
|
import _VisualDVM.Current;
|
||||||
import _VisualDVM.Global;
|
import _VisualDVM.Global;
|
||||||
import _VisualDVM.Passes.PassCode;
|
import _VisualDVM.Passes.PassCode;
|
||||||
@@ -11,7 +10,6 @@ import org.apache.commons.io.FileUtils;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.nio.file.Paths;
|
import java.nio.file.Paths;
|
||||||
public class DownloadAllBugReportsArchives extends ComponentsServerPass<File> {
|
public class DownloadAllBugReportsArchives extends ComponentsServerPass<File> {
|
||||||
//упраздненный временно проход.
|
|
||||||
@Override
|
@Override
|
||||||
public String getIconPath() {
|
public String getIconPath() {
|
||||||
return "/icons/DownloadAll.png";
|
return "/icons/DownloadAll.png";
|
||||||
@@ -46,12 +44,10 @@ public class DownloadAllBugReportsArchives extends ComponentsServerPass<File> {
|
|||||||
//теперь скопировать это в папку Bugs, с нормальными именами через zip
|
//теперь скопировать это в папку Bugs, с нормальными именами через zip
|
||||||
File t2 = Paths.get(tempFolder.getAbsolutePath(), "Bugs").toFile();
|
File t2 = Paths.get(tempFolder.getAbsolutePath(), "Bugs").toFile();
|
||||||
File[] archives = t2.listFiles();
|
File[] archives = t2.listFiles();
|
||||||
/*
|
|
||||||
if (archives != null) {
|
if (archives != null) {
|
||||||
for (File file : archives) {
|
for (File file : archives) {
|
||||||
FileUtils.moveFile(file, Paths.get(Global.BugReportsDirectory_OLD.getAbsolutePath(), file.getName() + ".zip").toFile());
|
FileUtils.moveFile(file, Paths.get(Global.BugReportsDirectory.getAbsolutePath(), file.getName() + ".zip").toFile());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ public class DownloadBugReport extends ComponentsServerPass<BugReport> {
|
|||||||
@Override
|
@Override
|
||||||
protected boolean canStart(Object... args) {
|
protected boolean canStart(Object... args) {
|
||||||
target = (BugReport) args[0];
|
target = (BugReport) args[0];
|
||||||
return !target.getArchiveFile().exists() && SendRequest(ServerCode.ReceiveBugReport, String.valueOf(target.id));
|
return !target.getArchiveFile().exists() && SendRequest(ServerCode.ReceiveBugReport, target.id);
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void performPreparation() throws Exception {
|
protected void performPreparation() throws Exception {
|
||||||
@@ -16,7 +16,6 @@ public class DownloadBugReport extends ComponentsServerPass<BugReport> {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void body() throws Exception {
|
protected void body() throws Exception {
|
||||||
Utils_.CheckAndCleanDirectory(target.getHome());
|
|
||||||
Utils_.bytesToFile((byte[]) request.server_response.object, target.getArchiveFile());
|
Utils_.bytesToFile((byte[]) request.server_response.object, target.getArchiveFile());
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
@@ -23,7 +23,7 @@ public class OpenBugReportTestProject extends Pass<BugReport> {
|
|||||||
if (Global.componentsServer.db.CheckCurrent(Log, BugReport.class) &&
|
if (Global.componentsServer.db.CheckCurrent(Log, BugReport.class) &&
|
||||||
(target = Global.componentsServer.db.bugReports.getUI().getCurrent()).CheckNotDraft(Log)) {
|
(target = Global.componentsServer.db.bugReports.getUI().getCurrent()).CheckNotDraft(Log)) {
|
||||||
if (!target.project_version.isEmpty()) {
|
if (!target.project_version.isEmpty()) {
|
||||||
root = new File(Global.visualiser.getDownloadsDirectory(), String.valueOf(target.id));
|
root = new File(Global.visualiser.getDownloadsDirectory(), target.id);
|
||||||
project = new File(root,
|
project = new File(root,
|
||||||
Utils_.isWindows() ? Utils_.toW(target.project_version) : Utils_.toU(target.project_version)
|
Utils_.isWindows() ? Utils_.toW(target.project_version) : Utils_.toU(target.project_version)
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ public class PublishBugReport extends PublishServerObject<ComponentsServer, BugR
|
|||||||
protected void performDone() throws Exception {
|
protected void performDone() throws Exception {
|
||||||
//3- рассылка
|
//3- рассылка
|
||||||
EmailMessage message = new EmailMessage(
|
EmailMessage message = new EmailMessage(
|
||||||
"Обнаружена ошибка " + Utils_.Brackets(pk),
|
"Обнаружена ошибка " + Utils_.Brackets(target.id),
|
||||||
target.getNewMailText()
|
target.getNewMailText()
|
||||||
);
|
);
|
||||||
Global.mainModule.getPass(PassCode.Email).Do(
|
Global.mainModule.getPass(PassCode.Email).Do(
|
||||||
|
|||||||
@@ -1,4 +0,0 @@
|
|||||||
package _VisualDVM.Passes.All;
|
|
||||||
import _VisualDVM.Passes.Sapfor.SapforTransformation;
|
|
||||||
public class SPF_MoveOperators extends SapforTransformation {
|
|
||||||
}
|
|
||||||
@@ -124,7 +124,6 @@ public class UpdateBugReportField extends ComponentsServerPass<BugReport> {
|
|||||||
message_header + " " + Utils_.Brackets(Global.mainModule.getAccount().name),
|
message_header + " " + Utils_.Brackets(Global.mainModule.getAccount().name),
|
||||||
message_text
|
message_text
|
||||||
);
|
);
|
||||||
|
|
||||||
Global.mainModule.getPass(PassCode.Email).Do(
|
Global.mainModule.getPass(PassCode.Email).Do(
|
||||||
message,
|
message,
|
||||||
Global.componentsServer.db.recipients.getSelectedMails());
|
Global.componentsServer.db.recipients.getSelectedMails());
|
||||||
|
|||||||
@@ -362,15 +362,11 @@ public enum PassCode implements PassCode_ {
|
|||||||
TestingServerBackUp,
|
TestingServerBackUp,
|
||||||
CompareDVMRunTaskToEthalon,
|
CompareDVMRunTaskToEthalon,
|
||||||
DropSapforConfigurationEthalon,
|
DropSapforConfigurationEthalon,
|
||||||
RefreshSapforPackageResults,
|
RefreshSapforPackageResults;
|
||||||
SPF_MoveOperators
|
|
||||||
;
|
|
||||||
//--
|
//--
|
||||||
@Override
|
@Override
|
||||||
public String getDescription() {
|
public String getDescription() {
|
||||||
switch (this) {
|
switch (this) {
|
||||||
case SPF_MoveOperators:
|
|
||||||
return "Оптимальный порядок операторов";
|
|
||||||
case SPF_InsertPrivateArrayDirectives:
|
case SPF_InsertPrivateArrayDirectives:
|
||||||
return "Анализ и вставка директив приватизации массивов";
|
return "Анализ и вставка директив приватизации массивов";
|
||||||
case CompareSapforPackageToEthalon:
|
case CompareSapforPackageToEthalon:
|
||||||
@@ -960,9 +956,6 @@ public enum PassCode implements PassCode_ {
|
|||||||
case SPF_RemoveDistArraysFromIO:
|
case SPF_RemoveDistArraysFromIO:
|
||||||
name = "REMOVE_DIST_ARRAYS_FROM_IO";
|
name = "REMOVE_DIST_ARRAYS_FROM_IO";
|
||||||
break;
|
break;
|
||||||
case SPF_MoveOperators:
|
|
||||||
name = "MOVE_OPERATORS";
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
return p + " " + name;
|
return p + " " + name;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,32 +11,29 @@ import org.apache.commons.io.FileUtils;
|
|||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.nio.charset.Charset;
|
import java.nio.charset.Charset;
|
||||||
import java.nio.file.Files;
|
|
||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
public class PackageModeSupervisor extends ThreadsPlanner {
|
public class PackageModeSupervisor extends ThreadsPlanner {
|
||||||
SapforPackage_json package_json = null;
|
SapforPackage_json package_json = null;
|
||||||
// File sapfor_drv = null;
|
File sapfor_drv = null;
|
||||||
public PackageModeSupervisor() throws Exception {
|
public PackageModeSupervisor() throws Exception {
|
||||||
super(2000);
|
super(2000);
|
||||||
package_json = (SapforPackage_json) Utils_.jsonFromFile(new File(Constants.package_json), SapforPackage_json.class);
|
package_json = (SapforPackage_json) Utils_.jsonFromFile(new File(Constants.package_json), SapforPackage_json.class);
|
||||||
//--
|
//--
|
||||||
File sapfor_src = new File(package_json.sapfor_drv);
|
File sapfor_src = new File(package_json.sapfor_drv);
|
||||||
//--
|
sapfor_drv = new File(Utils_.getHomeDirectory(), Utils_.getDateName("SAPFOR_F"));
|
||||||
String pid_prefix = Utils_.getDateName("SAPFOR_F");
|
FileUtils.copyFile(sapfor_src, sapfor_drv);
|
||||||
//--
|
if (!sapfor_drv.setExecutable(true))
|
||||||
|
throw new Exception("Не удалось сделать файл " + sapfor_drv.getName() + " исполняемым!");
|
||||||
File PID = new File("PID");
|
File PID = new File("PID");
|
||||||
FileUtils.writeStringToFile(PID, pid_prefix, Charset.defaultCharset());
|
FileUtils.writeStringToFile(PID, sapfor_drv.getName(), Charset.defaultCharset());
|
||||||
//---
|
//---
|
||||||
Date startDate = new Date();
|
Date startDate = new Date();
|
||||||
File started = new File(CommonConstants.STARTED);
|
File started = new File(CommonConstants.STARTED);
|
||||||
FileUtils.writeStringToFile(started, String.valueOf(startDate));
|
FileUtils.writeStringToFile(started, String.valueOf(startDate));
|
||||||
//формирование списка задач.
|
//формирование списка задач.
|
||||||
setMaxKernels(package_json.kernels);
|
setMaxKernels(package_json.kernels);
|
||||||
for (SapforTask task : package_json.tasks) {
|
for (SapforTask task : package_json.tasks)
|
||||||
File task_drv = new File(Utils_.getHomeDirectory(),pid_prefix+"_"+task.id);
|
addThread(new TaskThread(task, sapfor_drv));
|
||||||
Files.createSymbolicLink(task_drv.toPath(), sapfor_src.toPath());
|
|
||||||
addThread(new TaskThread(task, task_drv));
|
|
||||||
}
|
|
||||||
interruptThread.start();
|
interruptThread.start();
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
@@ -58,8 +55,8 @@ public class PackageModeSupervisor extends ThreadsPlanner {
|
|||||||
// ,"sh", "exe", "bat"
|
// ,"sh", "exe", "bat"
|
||||||
);
|
);
|
||||||
//удаление сапфора exception
|
//удаление сапфора exception
|
||||||
// if (sapfor_drv.exists())
|
if (sapfor_drv.exists())
|
||||||
// FileUtils.forceDelete(sapfor_drv);
|
FileUtils.forceDelete(sapfor_drv);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Utils_.MainLog.PrintException(e);
|
Utils_.MainLog.PrintException(e);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,7 +22,6 @@ import _VisualDVM.TestingSystem.SAPFOR.ServerSapfor.ServerSapforState;
|
|||||||
import org.apache.commons.io.FileUtils;
|
import org.apache.commons.io.FileUtils;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.FileFilter;
|
|
||||||
import java.nio.charset.Charset;
|
import java.nio.charset.Charset;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
import java.nio.file.Paths;
|
import java.nio.file.Paths;
|
||||||
@@ -149,7 +148,6 @@ public class SapforTestingPlanner extends TestingPlanner<SapforPackage> {
|
|||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
protected void DownloadResults() throws Exception {
|
protected void DownloadResults() throws Exception {
|
||||||
//-
|
|
||||||
UpdatePackageState(TasksPackageState.Analysis);
|
UpdatePackageState(TasksPackageState.Analysis);
|
||||||
}
|
}
|
||||||
@Override
|
@Override
|
||||||
@@ -157,16 +155,6 @@ public class SapforTestingPlanner extends TestingPlanner<SapforPackage> {
|
|||||||
//не требуется.
|
//не требуется.
|
||||||
testingPackage.progress = 100;
|
testingPackage.progress = 100;
|
||||||
testingPackage.checkFinishState();
|
testingPackage.checkFinishState();
|
||||||
//--
|
|
||||||
File workspace = testingPackage.getLocalWorkspace();
|
|
||||||
File[] links = workspace.listFiles();
|
|
||||||
if (links!=null){
|
|
||||||
Print("files found: "+links.length);
|
|
||||||
for (File file: links) {
|
|
||||||
if (file.isFile() && file.getName().startsWith("SAPFOR"))
|
|
||||||
FileUtils.forceDelete(file);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
//--для эталона
|
//--для эталона
|
||||||
if (testingPackage.ethalon_id != CommonConstants.Nan) {
|
if (testingPackage.ethalon_id != CommonConstants.Nan) {
|
||||||
TextLog log = new TextLog();
|
TextLog log = new TextLog();
|
||||||
@@ -230,8 +218,7 @@ public class SapforTestingPlanner extends TestingPlanner<SapforPackage> {
|
|||||||
Thread.sleep(1000);
|
Thread.sleep(1000);
|
||||||
} while (!aborted_file.exists());
|
} while (!aborted_file.exists());
|
||||||
Print("coup de grace..");
|
Print("coup de grace..");
|
||||||
// String kill_command = "killall -SIGKILL " + testingPackage.PID;
|
String kill_command = "killall -SIGKILL " + testingPackage.PID;
|
||||||
String kill_command = "pkill -SIGKILL -f " + testingPackage.PID;
|
|
||||||
Print(kill_command);
|
Print(kill_command);
|
||||||
Process killer = Runtime.getRuntime().exec(kill_command);
|
Process killer = Runtime.getRuntime().exec(kill_command);
|
||||||
killer.waitFor();
|
killer.waitFor();
|
||||||
|
|||||||
@@ -3,10 +3,10 @@ import _VisualDVM.Global;
|
|||||||
import _VisualDVM.Visual.Menus.PropertiesSubmenu;
|
import _VisualDVM.Visual.Menus.PropertiesSubmenu;
|
||||||
public class VersionsComparisonMenu extends PropertiesSubmenu {
|
public class VersionsComparisonMenu extends PropertiesSubmenu {
|
||||||
public VersionsComparisonMenu() {
|
public VersionsComparisonMenu() {
|
||||||
super("Сравнение текстов", null,
|
super("Сравнение версий", null,
|
||||||
Global.normalProperties,
|
Global.normalProperties,
|
||||||
// "RegisterOn",
|
// "RegisterOn",
|
||||||
"SpacesOn",
|
// "SpacesOn",
|
||||||
// "EmptyLinesOn",
|
// "EmptyLinesOn",
|
||||||
// "FortranWrapsOn",
|
// "FortranWrapsOn",
|
||||||
"ExtensionsOn",
|
"ExtensionsOn",
|
||||||
|
|||||||
@@ -192,7 +192,7 @@
|
|||||||
<properties>
|
<properties>
|
||||||
<font name="Times New Roman" size="14" style="2"/>
|
<font name="Times New Roman" size="14" style="2"/>
|
||||||
<foreground color="-16777216"/>
|
<foreground color="-16777216"/>
|
||||||
<text value="id"/>
|
<text value="bug_"/>
|
||||||
</properties>
|
</properties>
|
||||||
</component>
|
</component>
|
||||||
<component id="a9e5" class="javax.swing.JTextField" binding="BugReportsKeyFilter" custom-create="true">
|
<component id="a9e5" class="javax.swing.JTextField" binding="BugReportsKeyFilter" custom-create="true">
|
||||||
@@ -426,41 +426,6 @@
|
|||||||
</grid>
|
</grid>
|
||||||
</children>
|
</children>
|
||||||
</grid>
|
</grid>
|
||||||
<grid id="58b74" layout-manager="BorderLayout" hgap="0" vgap="0">
|
|
||||||
<constraints>
|
|
||||||
<tabbedpane title="Вложения"/>
|
|
||||||
</constraints>
|
|
||||||
<properties/>
|
|
||||||
<border type="none"/>
|
|
||||||
<children>
|
|
||||||
<splitpane id="4276b" binding="SC91">
|
|
||||||
<constraints border-constraint="Center"/>
|
|
||||||
<properties>
|
|
||||||
<dividerLocation value="300"/>
|
|
||||||
<dividerSize value="3"/>
|
|
||||||
</properties>
|
|
||||||
<border type="none"/>
|
|
||||||
<children>
|
|
||||||
<grid id="a0a40" binding="bugRepotsFilesPanel" layout-manager="BorderLayout" hgap="0" vgap="0">
|
|
||||||
<constraints>
|
|
||||||
<splitpane position="left"/>
|
|
||||||
</constraints>
|
|
||||||
<properties/>
|
|
||||||
<border type="none"/>
|
|
||||||
<children/>
|
|
||||||
</grid>
|
|
||||||
<grid id="13d" layout-manager="BorderLayout" hgap="0" vgap="0">
|
|
||||||
<constraints>
|
|
||||||
<splitpane position="right"/>
|
|
||||||
</constraints>
|
|
||||||
<properties/>
|
|
||||||
<border type="none"/>
|
|
||||||
<children/>
|
|
||||||
</grid>
|
|
||||||
</children>
|
|
||||||
</splitpane>
|
|
||||||
</children>
|
|
||||||
</grid>
|
|
||||||
</children>
|
</children>
|
||||||
</tabbedpane>
|
</tabbedpane>
|
||||||
</children>
|
</children>
|
||||||
|
|||||||
@@ -32,7 +32,6 @@ public class CallbackForm implements FormWithSplitters, CallbackWindow {
|
|||||||
public DescriptionInterface descriptionInterface;
|
public DescriptionInterface descriptionInterface;
|
||||||
public CommentInterface commentInterface;
|
public CommentInterface commentInterface;
|
||||||
public JSplitPane SC6;
|
public JSplitPane SC6;
|
||||||
public JSplitPane SC91;
|
|
||||||
DocumentListener descriptionAdditionListener = new DocumentListener() {
|
DocumentListener descriptionAdditionListener = new DocumentListener() {
|
||||||
@Override
|
@Override
|
||||||
public void removeUpdate(DocumentEvent e) {
|
public void removeUpdate(DocumentEvent e) {
|
||||||
@@ -124,7 +123,6 @@ public class CallbackForm implements FormWithSplitters, CallbackWindow {
|
|||||||
private JTextField BugReportsCommentFilter;
|
private JTextField BugReportsCommentFilter;
|
||||||
private JPanel workspacesPanel;
|
private JPanel workspacesPanel;
|
||||||
private JLabel adminLabel;
|
private JLabel adminLabel;
|
||||||
private JPanel bugRepotsFilesPanel;
|
|
||||||
private Viewer BugReportSettings;
|
private Viewer BugReportSettings;
|
||||||
public CallbackForm() {
|
public CallbackForm() {
|
||||||
LoadSplitters();
|
LoadSplitters();
|
||||||
@@ -155,7 +153,6 @@ public class CallbackForm implements FormWithSplitters, CallbackWindow {
|
|||||||
SwitchScreen(Global.normalProperties.SmallScreen);
|
SwitchScreen(Global.normalProperties.SmallScreen);
|
||||||
//-
|
//-
|
||||||
Global.componentsServer.db.bugReports.mountUI(bugReportsPanel);
|
Global.componentsServer.db.bugReports.mountUI(bugReportsPanel);
|
||||||
Global.componentsServer.db.bugReportsFiles.mountUI(bugRepotsFilesPanel);
|
|
||||||
Global.componentsServer.db.recipients.mountUI(recipientsPanel);
|
Global.componentsServer.db.recipients.mountUI(recipientsPanel);
|
||||||
//-
|
//-
|
||||||
if (!Global.mainModule.getPass(PassCode.CheckAccount).isDone()) {
|
if (!Global.mainModule.getPass(PassCode.CheckAccount).isDone()) {
|
||||||
|
|||||||
@@ -8,7 +8,6 @@ import Common.Visual.Controls.ShortLabel;
|
|||||||
import Common.Visual.Editor.BaseEditor;
|
import Common.Visual.Editor.BaseEditor;
|
||||||
import Common.Visual.Menus.VisualiserMenuBar;
|
import Common.Visual.Menus.VisualiserMenuBar;
|
||||||
import Common.Visual.UI;
|
import Common.Visual.UI;
|
||||||
import _VisualDVM.Global;
|
|
||||||
import _VisualDVM.ProjectData.Files.UI.Editor.SPFEditor;
|
import _VisualDVM.ProjectData.Files.UI.Editor.SPFEditor;
|
||||||
import _VisualDVM.Utils;
|
import _VisualDVM.Utils;
|
||||||
import com.github.difflib.text.DiffRow;
|
import com.github.difflib.text.DiffRow;
|
||||||
@@ -186,7 +185,7 @@ public abstract class ComparisonForm<T> {
|
|||||||
DiffRowGenerator generator = DiffRowGenerator.create()
|
DiffRowGenerator generator = DiffRowGenerator.create()
|
||||||
.showInlineDiffs(true)
|
.showInlineDiffs(true)
|
||||||
.inlineDiffByWord(true)
|
.inlineDiffByWord(true)
|
||||||
.ignoreWhiteSpaces(!Global.normalProperties.SpacesOn)
|
// .ignoreWhiteSpaces(false)
|
||||||
.oldTag(f -> separator)
|
.oldTag(f -> separator)
|
||||||
.newTag(f -> separator)
|
.newTag(f -> separator)
|
||||||
.build();
|
.build();
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 843 B |
Reference in New Issue
Block a user