From 6200ba627af8af4045155c1bd7e65220ce59d6ba Mon Sep 17 00:00:00 2001
From: Junjie <DELL@qq.com>
Date: 星期四, 15 一月 2026 14:36:36 +0800
Subject: [PATCH] #
---
src/main/java/com/zy/system/timer/LicenseTimer.java | 18 +++++++++---------
1 files changed, 9 insertions(+), 9 deletions(-)
diff --git a/src/main/java/com/zy/system/timer/LicenseTimer.java b/src/main/java/com/zy/system/timer/LicenseTimer.java
index dc49eb7..f6a724f 100644
--- a/src/main/java/com/zy/system/timer/LicenseTimer.java
+++ b/src/main/java/com/zy/system/timer/LicenseTimer.java
@@ -18,9 +18,9 @@
@Component
public class LicenseTimer {
- private static boolean SYSTEM_SUPPORT = false;//绯荤粺婵�娲荤姸鎬侊紝榛樿鍏抽棴
+ private static boolean SYSTEM_SUPPORT = false;// 绯荤粺婵�娲荤姸鎬侊紝榛樿鍏抽棴
- private static int LICENSE_DAYS = 0;//璁稿彲璇佸ぉ鏁�
+ private static int LICENSE_DAYS = 0;// 璁稿彲璇佸ぉ鏁�
/**
* 璇佷功subject
@@ -55,7 +55,7 @@
@Autowired
private LicenseInfosService licenseInfosService;
- //姣忓ぉ鏅氫笂11鐐规洿鏂扮郴缁熸縺娲荤姸鎬�
+ // 姣忓ぉ鏅氫笂11鐐规洿鏂扮郴缁熸縺娲荤姸鎬�
@Scheduled(cron = "0 0 23 * * ? ")
public void timer() {
try {
@@ -75,12 +75,12 @@
try {
AbstractServerInfos abstractServerInfos = null;
String osName = System.getProperty("os.name");
- //鏍规嵁涓嶅悓鎿嶄綔绯荤粺绫诲瀷閫夋嫨涓嶅悓鐨勬暟鎹幏鍙栨柟娉�
+ // 鏍规嵁涓嶅悓鎿嶄綔绯荤粺绫诲瀷閫夋嫨涓嶅悓鐨勬暟鎹幏鍙栨柟娉�
if (osName.startsWith("windows")) {
abstractServerInfos = new WindowsServerInfos();
} else if (osName.startsWith("linux")) {
abstractServerInfos = new LinuxServerInfos();
- }else{//鍏朵粬鏈嶅姟鍣ㄧ被鍨�
+ } else {// 鍏朵粬鏈嶅姟鍣ㄧ被鍨�
abstractServerInfos = new WindowsServerInfos();
}
LicenseCheck serverInfos = abstractServerInfos.getServerInfos();
@@ -123,9 +123,9 @@
param.setLicensePath(licensePath);
param.setPublicKeysStorePath(publicKeysStorePath);
- //楠岃瘉璁稿彲璇佹槸鍚︽湁鏁�
+ // 楠岃瘉璁稿彲璇佹槸鍚︽湁鏁�
LicenseVerify licenseVerify = new LicenseVerify();
- //瀹夎璇佷功
+ // 瀹夎璇佷功
LicenseContent install = licenseVerify.install(param, latestLicense.getLicense());
if (install != null) {
@@ -133,11 +133,11 @@
Date end = install.getNotAfter();
Long starTime = start.getTime();
Long endTime = end.getTime();
- long num = endTime - starTime;//鏃堕棿鎴崇浉宸殑姣鏁�
+ long num = endTime - starTime;// 鏃堕棿鎴崇浉宸殑姣鏁�
int day = (int) (num / 24 / 60 / 60 / 1000);
setLicenseDays(day);
setSystemSupport(true);
- }else {
+ } else {
setLicenseDays(0);
setSystemSupport(false);
}
--
Gitblit v1.9.1