Browse Source

Merge branch 'feature/10.0' of http://cloud.finedevelop.com:2015/scm/~xiaoxia/design into feature/10.0

* 'feature/10.0' of http://cloud.finedevelop.com:2015/scm/~xiaoxia/design:
  页大小改大一点
  REPORT-16461 设计器中关闭自动推送更新无效=>调整代码
  REPORT-16461 设计器中关闭自动推送更新无效
research/10.0
XiaXiang 6 years ago
parent
commit
1e639cb0e9
  1. 25
      designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateManager.java
  2. 2
      designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/impl/AbstractSendDataToCloud.java

25
designer-base/src/main/java/com/fr/design/update/push/DesignerPushUpdateManager.java

@ -13,28 +13,27 @@ import com.fr.log.FineLoggerFactory;
import com.fr.stable.StringUtils;
import com.fr.workspace.WorkContext;
import java.io.IOException;
/**
* Created by plough on 2019/4/8.
*/
public class DesignerPushUpdateManager {
private static final String SPLIT_CHAR = "-";
private static DesignerPushUpdateManager singleton;
private DesignerUpdateInfo updateInfo;
private DesignerPushUpdateConfigManager config;
static {
DesignerContext.getDesignerFrame().addDesignerOpenedListener(new DesignerOpenedListener() {
@Override
public void designerOpened() {
getInstance().checkAndPop();
}
});
if (DesignerPushUpdateConfigManager.getInstance().isAutoPushUpdateEnabled()) {
DesignerContext.getDesignerFrame().addDesignerOpenedListener(new DesignerOpenedListener() {
@Override
public void designerOpened() {
getInstance().checkAndPop();
}
});
}
}
private DesignerPushUpdateManager() {
config = DesignerPushUpdateConfigManager.getInstance();
}
public static DesignerPushUpdateManager getInstance() {
@ -45,7 +44,7 @@ public class DesignerPushUpdateManager {
}
private void initUpdateInfo(String currentVersion, String latestVersion) {
String lastIgnoredVersion = config.getLastIgnoredVersion();
String lastIgnoredVersion = DesignerPushUpdateConfigManager.getInstance().getLastIgnoredVersion();
String updatePushInfo = CloudCenter.getInstance().acquireUrlByKind("update.push");
JSONObject pushData = new JSONObject(updatePushInfo);
@ -56,7 +55,7 @@ public class DesignerPushUpdateManager {
try {
String res = HttpToolbox.get(CloudCenter.getInstance().acquireUrlByKind("jar10.update"));
return new JSONObject(res).optString("buildNO");
} catch (IOException e) {
} catch (Throwable e) {
FineLoggerFactory.getLogger().error(e.getMessage(), e);
}
return StringUtils.EMPTY;
@ -164,6 +163,6 @@ public class DesignerPushUpdateManager {
if (updateInfo == null) {
return;
}
config.setLastIgnoredVersion(updateInfo.getPushVersion());
DesignerPushUpdateConfigManager.getInstance().setLastIgnoredVersion(updateInfo.getPushVersion());
}
}

2
designer-realize/src/main/java/com/fr/design/mainframe/messagecollect/impl/AbstractSendDataToCloud.java

@ -26,7 +26,7 @@ public abstract class AbstractSendDataToCloud implements XMLable {
private static final String COLUMN_TIME = "time";
protected String lastTime;
private static final int PAGE_SIZE = 200;
private static final int PAGE_SIZE = 10000;
private long totalCount = -1;
private FileEntityBuilder fileEntityBuilder;

Loading…
Cancel
Save