cloudroam
2025-03-29 5997dc8acfa81a6c867c28810d1c3c9714efc46c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
package com.mzl.flower.schedule;
 
import com.mzl.flower.service.district.DistrictTengxunService;
import com.mzl.flower.service.map.MapGaodeService;
import com.mzl.flower.service.map.MapTengxunService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;
 
@Component
@Slf4j
public class MapScheduleService {
 
    @Autowired
    private MapTengxunService mapTengxunService;
 
    @Autowired
    private MapGaodeService mapGaodeService;
 
    @Autowired
    private DistrictTengxunService districtTengxunService;
 
 
 
 
    /**
     * 每个月第一天凌晨5点执行一次
     */
//    @Scheduled(cron = "5 * * * * ?")
    @Scheduled(cron = "0 5 0 1 * ?")
    public void expiredPointGoodsRecord() {
 
        // 高德地图解析-行政区划
//        mapGaodeService.getAdministrativeDivision();
        // 腾讯地图解析-行政区划
        mapTengxunService.getAdministrativeDivision();
 
//        districtTengxunService.refreshDistrict();
 
    }
 
 
}