|
|
@@ -20,8 +20,8 @@ import com.goafanti.customer.bo.LockingReleaseBo;
|
|
|
import com.goafanti.customer.service.CustomerService;
|
|
|
import com.goafanti.user.service.UserService;
|
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
|
-import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
-import org.springframework.web.bind.annotation.RestController;
|
|
|
+import org.springframework.scheduling.annotation.Scheduled;
|
|
|
+import org.springframework.stereotype.Component;
|
|
|
|
|
|
import javax.annotation.Resource;
|
|
|
import java.time.LocalDateTime;
|
|
|
@@ -32,8 +32,8 @@ import java.util.List;
|
|
|
import java.util.UUID;
|
|
|
|
|
|
|
|
|
-//@Component
|
|
|
-@RestController
|
|
|
+@Component
|
|
|
+//@RestController
|
|
|
public class ReleaseUserTask {
|
|
|
@Resource
|
|
|
private CustomerService customerService;
|
|
|
@@ -64,8 +64,8 @@ public class ReleaseUserTask {
|
|
|
*
|
|
|
*/
|
|
|
// @Scheduled(cron = "0 22 16 * * ?")
|
|
|
- @RequestMapping("/open/test")
|
|
|
-// @Scheduled(cron = "0 0 1 * * ?")
|
|
|
+// @RequestMapping("/open/test")
|
|
|
+ @Scheduled(cron = "0 0 1 * * ?")
|
|
|
public void startTask() {
|
|
|
try {
|
|
|
List<User> userList = userService.selectUserByRoleName("营销员", "营销经理");
|