| | |
| | | import com.whyc.dto.Response; |
| | | import com.whyc.service.PwrdevHistorydataGwService; |
| | | import com.whyc.util.ActionUtil; |
| | | import com.whyc.util.ThreadLocalUtil; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | public Response serchByCondition(@RequestParam String recordTime1, @RequestParam String recordTime2, @RequestParam int devId) throws ParseException, InterruptedException { |
| | | Date testTime1 = null; |
| | | Date testTime2 = null; |
| | | try { |
| | | testTime1 = ActionUtil.sdf.parse(recordTime1); |
| | | testTime2 = ActionUtil.sdf.parse(recordTime2); |
| | | } catch (ParseException e) { |
| | | e.printStackTrace(); |
| | | } |
| | | /*testTime1 = ActionUtil.sdf.parse(recordTime1); |
| | | testTime2 = ActionUtil.sdf.parse(recordTime2);*/ |
| | | testTime1 = ThreadLocalUtil.parse(recordTime1,1); |
| | | testTime2 = ThreadLocalUtil.parse(recordTime2,1); |
| | | return service.serchByCondition(testTime1, testTime2, devId); |
| | | } |
| | | } |