v++
This commit is contained in:
5
.idea/workspace.xml
generated
5
.idea/workspace.xml
generated
@@ -7,7 +7,12 @@
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<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$/src/_VisualDVM/ComponentsServer/Recipient/RecipientsDataSet.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/ComponentsServer/Recipient/RecipientsDataSet.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/ComponentsServer/UserAccount/UserAccountsDBTable.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/ComponentsServer/UserAccount/UserAccountsDBTable.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Global.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Global.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Passes/All/PublishComponent.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Passes/All/PublishComponent.java" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/_VisualDVM/Passes/All/SynchronizeCredentials.java" beforeDir="false" afterPath="$PROJECT_DIR$/src/_VisualDVM/Passes/All/SynchronizeCredentials.java" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
|
||||
@@ -5,6 +5,7 @@ import Common.Visual.DataSetControlForm;
|
||||
import _VisualDVM.ComponentsServer.Recipient.Json.UserAccountJson;
|
||||
import _VisualDVM.ComponentsServer.Recipient.Json.UserAccountsJson;
|
||||
import _VisualDVM.ComponentsServer.Recipient.UI.RecipientsForm;
|
||||
import _VisualDVM.ComponentsServer.UserAccount.UserAccount;
|
||||
import _VisualDVM.Constants;
|
||||
import _VisualDVM.Global;
|
||||
|
||||
|
||||
@@ -10,6 +10,8 @@ import _VisualDVM.ComponentsServer.Recipient.Json.UserAccountJson;
|
||||
import _VisualDVM.ComponentsServer.Recipient.Json.UserAccountsJson;
|
||||
import _VisualDVM.ComponentsServer.SubscriberWorkspace.SubscriberWorkspace;
|
||||
import _VisualDVM.ComponentsServer.UserAccount.UI.UserAccountsForm;
|
||||
import _VisualDVM.Constants;
|
||||
import _VisualDVM.Global;
|
||||
|
||||
import javax.swing.*;
|
||||
import java.util.LinkedHashMap;
|
||||
@@ -62,5 +64,18 @@ public class UserAccountsDBTable extends iDBTable<UserAccount> {
|
||||
}
|
||||
return Utils_.gson.toJson(res);
|
||||
}
|
||||
|
||||
public Vector<String> getActiveMails(){
|
||||
Vector<String> res = new Vector<>();
|
||||
for (UserAccount account: Data.values()){
|
||||
if ((account.subscribe_active!=0)&& !res.contains(account.email))
|
||||
res.add(account.email);
|
||||
}
|
||||
for (String admin_mail : Constants.admins_mails) {
|
||||
if (!res.contains(admin_mail))
|
||||
res.add(admin_mail);
|
||||
}
|
||||
return res;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ import Common.Utils.Vector_;
|
||||
|
||||
import java.util.Vector;
|
||||
public class Constants {
|
||||
public static final int version = 1178;
|
||||
public static final int version = 1179;
|
||||
public static final int planner_version = 10;
|
||||
public static final int testingMaxKernels = 64; //вообще говоря, это параметр машины.
|
||||
//--
|
||||
|
||||
@@ -214,6 +214,7 @@ public class Global {
|
||||
Global.mainModule.getPass(PassCode.SynchronizeBugReports).Do();
|
||||
if (normalProperties.AutoTestsLoad)
|
||||
Global.mainModule.getPass(PassCode.SynchronizeTests).Do();
|
||||
Global.mainModule.getPass(PassCode.SynchronizeCredentials).Do();
|
||||
//--
|
||||
Global.mainModule.getSapfor().refreshPid(); //без сапфора сюда это все равно не дойдет.
|
||||
Global.mainModule.getUI().getMainWindow().Show();
|
||||
|
||||
@@ -101,7 +101,7 @@ public class PublishComponent extends ComponentsServerPass<Component> {
|
||||
return false;
|
||||
}
|
||||
};
|
||||
unsafeEmail.Do(message, new Vector<>(Global.componentsServer.db.recipients.Data.values()));
|
||||
unsafeEmail.Do(message, Global.componentsServer.credentials_db.userAccounts.getActiveMails());
|
||||
//---
|
||||
if (target.getComponentType().equals(ComponentType.Sapfor_F) && f.fields.cbAssemblyOnServer.isSelected()) {
|
||||
Global.mainModule.getUI().getMainWindow().FocusTesting();
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
package _VisualDVM.Passes.All;
|
||||
import _VisualDVM.ComponentsServer.UserAccount.AccountRole;
|
||||
import _VisualDVM.Global;
|
||||
import _VisualDVM.Passes.Server.ComponentsServerPass;
|
||||
import _VisualDVM.Repository.Server.ServerCode;
|
||||
@@ -13,7 +14,7 @@ public class SynchronizeCredentials extends ComponentsServerPass<Object> {
|
||||
}
|
||||
@Override
|
||||
protected boolean canStart(Object... args) throws Exception {
|
||||
return Global.mainModule.getAccount().CheckAdmin(Log) && SendRequest(ServerCode.ReceiveCredentialsDatabase);
|
||||
return Global.mainModule.getAccount().role.equals(AccountRole.Admin) && SendRequest(ServerCode.ReceiveCredentialsDatabase);
|
||||
}
|
||||
@Override
|
||||
protected void showPreparation() throws Exception {
|
||||
|
||||
Reference in New Issue
Block a user