Date date = new Date();
SimpleDateFormat dft = new SimpleDateFormat("yyyyMMdd");
String freeDay = dft.format(date);
Long nowDate=Long.valueOf(freeDay);
if(nowDate > 20180720 || nowDate < 20180718){ //活动不在范围内( 20180718-20180720)
return -1;
}
Date date = new Date();
SimpleDateFormat dft = new SimpleDateFormat("yyyyMMdd");
String freeDay = dft.format(date);
Long nowDate=Long.valueOf(freeDay);
if(nowDate > 20180720 || nowDate < 20180718){ //活动不在范围内( 20180718-20180720)
return -1;
}