bug
This commit is contained in:
@@ -16,9 +16,8 @@ import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.text.ParseException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.*;
|
||||
|
||||
@Slf4j
|
||||
@RestController
|
||||
@RequestMapping("book/point")
|
||||
@@ -172,14 +171,31 @@ public class PointController {
|
||||
return R.ok().put("points",pointEntities);
|
||||
}
|
||||
|
||||
/**
|
||||
* 时辰取穴
|
||||
* @param map
|
||||
* @return
|
||||
* @throws ParseException
|
||||
*/
|
||||
@RequestMapping("/SCQX")
|
||||
public R SCQX(@RequestBody Map<String,Object> map) throws ParseException {
|
||||
String date = map.get("date").toString();
|
||||
SimpleDateFormat simpleDateFormat = new SimpleDateFormat();
|
||||
simpleDateFormat.applyPattern("yyyy-MM-dd hh:mm:ss");
|
||||
Date parse = simpleDateFormat.parse(date);
|
||||
pointService.ZWLZ(parse);
|
||||
|
||||
return null;
|
||||
List<Map<String,Object>> flag = new ArrayList<>();
|
||||
for (int i=0;i<24;i+=2){
|
||||
Calendar instance = Calendar.getInstance();
|
||||
instance.setTime(parse);
|
||||
instance.set(Calendar.HOUR_OF_DAY,i);
|
||||
Date time = instance.getTime();
|
||||
Map<String,Object> ff = new HashMap<>();
|
||||
ff.put("zwlz",pointService.ZWLZ(time));
|
||||
ff.put("lgbf",pointService.LGBF(time));
|
||||
ff.put("ftbf",pointService.FTBF(time));
|
||||
flag.add(ff);
|
||||
}
|
||||
return R.ok().put("flag",flag);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user