|  |  |  | 
|---|
|  |  |  | import com.matrix.system.shopXcx.dao.ShopActivitiesDao; | 
|---|
|  |  |  | import com.matrix.system.shopXcx.dao.ShopActivitiesGroupJoinDao; | 
|---|
|  |  |  | import org.springframework.beans.factory.annotation.Autowired; | 
|---|
|  |  |  | import org.springframework.beans.factory.annotation.Value; | 
|---|
|  |  |  | import org.springframework.context.annotation.Configuration; | 
|---|
|  |  |  | import org.springframework.scheduling.annotation.Scheduled; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | 
|---|
|  |  |  | @Autowired | 
|---|
|  |  |  | private ShopActivitiesDao shopActivitiesDao ; | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @Value("${scheduling.enabled}") | 
|---|
|  |  |  | private boolean taskSwitch; | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  |  | 
|---|
|  |  |  | @Scheduled(cron = "0 */1 * * * ?") | 
|---|
|  |  |  | public boolean executeExt() { | 
|---|
|  |  |  | if (taskSwitch) { | 
|---|
|  |  |  | LogUtil.info("#开团时间超时任务处理#"); | 
|---|
|  |  |  | List<ShopActivitiesGroupJoin> groupJoins = shopActivitiesGroupJoinDao.selectGroupJoinWithEnd(); | 
|---|
|  |  |  | ShopActivityTimeOutQuartz timeOutQuartz = new ShopActivityTimeOutQuartz(); | 
|---|
|  |  |  | 
|---|
|  |  |  | timeOutQuartz.doUnVirtualGroup(groupJoin); | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | } | 
|---|
|  |  |  | return true; | 
|---|
|  |  |  | } | 
|---|