From d9fe9624262bd06fdfd9dd886755ff48678f76ae Mon Sep 17 00:00:00 2001
From: Junjie <xjj@123>
Date: 星期四, 25 九月 2025 08:34:01 +0800
Subject: [PATCH] #

---
 /dev/null                                                    |   44 --------------------------------------------
 src/main/java/com/zy/common/properties/SystemProperties.java |    2 +-
 2 files changed, 1 insertions(+), 45 deletions(-)

diff --git a/src/main/java/com/zy/common/properties/SystemProperties.java b/src/main/java/com/zy/common/properties/SystemProperties.java
index ba6350b..75bb685 100644
--- a/src/main/java/com/zy/common/properties/SystemProperties.java
+++ b/src/main/java/com/zy/common/properties/SystemProperties.java
@@ -15,7 +15,7 @@
     public static final String SALT = "123456789qwertyu";
 
     // 绯荤粺婵�娲荤姸鎬� (榛樿鏈縺娲�)
-    public static boolean SYSTEM_ACTIVATION = Boolean.FALSE;
+    public static boolean SYSTEM_ACTIVATION = Boolean.TRUE;
 
     public static String getActivationCode(String fileName){
         StringBuilder activationCode = new StringBuilder();
diff --git a/src/main/java/com/zy/common/task/ActivateScheduler.java b/src/main/java/com/zy/common/task/ActivateScheduler.java
deleted file mode 100644
index 4b96119..0000000
--- a/src/main/java/com/zy/common/task/ActivateScheduler.java
+++ /dev/null
@@ -1,44 +0,0 @@
-package com.zy.common.task;
-
-import com.core.common.AesUtils;
-import com.core.common.Cools;
-import com.core.common.DateUtils;
-import com.zy.common.properties.OSinfo;
-import com.zy.common.properties.SystemProperties;
-import org.springframework.scheduling.annotation.Scheduled;
-import org.springframework.stereotype.Component;
-
-import javax.annotation.PostConstruct;
-import java.util.Date;
-
-/**
- * 绯荤粺婵�娲讳换鍔�
- */
-@Component
-public class ActivateScheduler {
-
-//    @Scheduled(cron = "0/1 * 8 * * ? ") // 姣忓ぉ8鐐�
-    @Scheduled(cron = "* 0/1 * * * ? ") // 姣忓垎閽�
-    @PostConstruct
-    private void execute(){
-        // 鑾峰彇婵�娲荤爜
-        String activationCode = SystemProperties.getActivationCode(OSinfo.getOSname().getActivationCodePath());
-        if (!Cools.isEmpty(activationCode)) {
-            // 鑾峰彇鏈夋晥鏈�
-            String timeStr = AesUtils.decrypt(activationCode, SystemProperties.SALT);
-            if (null == timeStr) {
-                SystemProperties.SYSTEM_ACTIVATION = Boolean.FALSE;
-                return;
-            }
-            Date exprTime = DateUtils.convert(timeStr, DateUtils.yyyyMMddHHmmss);
-            if (new Date().getTime() < exprTime.getTime()) {
-                SystemProperties.SYSTEM_ACTIVATION = Boolean.TRUE;
-            } else {
-                SystemProperties.SYSTEM_ACTIVATION = Boolean.FALSE;
-            }
-        } else {
-            SystemProperties.SYSTEM_ACTIVATION = Boolean.FALSE;
-        }
-    }
-
-}

--
Gitblit v1.9.1