|
@ -658,7 +658,7 @@ public class QuestionService implements IQuestionService { |
|
|
canvasLine.setWidth(htPatientCanvas.getLineWidth()); |
|
|
canvasLine.setWidth(htPatientCanvas.getLineWidth()); |
|
|
patientCanvas.setLine(canvasLine); |
|
|
patientCanvas.setLine(canvasLine); |
|
|
//颜色和轨迹坐标
|
|
|
//颜色和轨迹坐标
|
|
|
List<QuestionVo.Point> canvasPoints = getCanvasPoints(htPatientCanvas); |
|
|
List<QuestionVo.PointStatus> canvasPoints = getCanvasPoints(htPatientCanvas); |
|
|
patientCanvas.setPoints(canvasPoints); |
|
|
patientCanvas.setPoints(canvasPoints); |
|
|
//计算参数
|
|
|
//计算参数
|
|
|
QuestionVo.Parameter parameter = getParameter(question, htPatientCanvas, param); |
|
|
QuestionVo.Parameter parameter = getParameter(question, htPatientCanvas, param); |
|
@ -675,14 +675,15 @@ public class QuestionService implements IQuestionService { |
|
|
return patientCanvasDao.selectByExample(canvasExample); |
|
|
return patientCanvasDao.selectByExample(canvasExample); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
private List<QuestionVo.Point> getCanvasPoints(HtPatientCanvas htPatientCanvas) { |
|
|
private List<QuestionVo.PointStatus> getCanvasPoints(HtPatientCanvas htPatientCanvas) { |
|
|
List<QuestionVo.Point> canvasPoints = patientCanvasDao.getCanvasPoints(htPatientCanvas.getId()); |
|
|
// List<QuestionVo.Point> canvasPoints = patientCanvasDao.getCanvasPoints(htPatientCanvas.getId());
|
|
|
|
|
|
List<QuestionVo.PointStatus> canvasPoints = patientCanvasDao.getCanvasPointsDel(htPatientCanvas.getId()); |
|
|
int num = 16; |
|
|
int num = 16; |
|
|
if(canvasPoints.size() > num){ |
|
|
if(canvasPoints.size() > num){ |
|
|
int c = 240 / (((canvasPoints.size() + 1) / 4) - 1); |
|
|
int c = 240 / (((canvasPoints.size() + 1) / 4) - 1); |
|
|
int a = 0; |
|
|
int a = 0; |
|
|
int b = 0; |
|
|
int b = 0; |
|
|
for(QuestionVo.Point point : canvasPoints){ |
|
|
for(QuestionVo.PointStatus point : canvasPoints){ |
|
|
if(a < 4){ |
|
|
if(a < 4){ |
|
|
point.setColor(b); |
|
|
point.setColor(b); |
|
|
a++; |
|
|
a++; |
|
@ -696,7 +697,7 @@ public class QuestionService implements IQuestionService { |
|
|
int a = 0; |
|
|
int a = 0; |
|
|
int b = 0; |
|
|
int b = 0; |
|
|
List<Integer> colours = Constant.LineColour.COLOUR; |
|
|
List<Integer> colours = Constant.LineColour.COLOUR; |
|
|
for(QuestionVo.Point point : canvasPoints){ |
|
|
for(QuestionVo.PointStatus point : canvasPoints){ |
|
|
if(a < 4){ |
|
|
if(a < 4){ |
|
|
a++; |
|
|
a++; |
|
|
}else { |
|
|
}else { |
|
@ -1251,4 +1252,12 @@ public class QuestionService implements IQuestionService { |
|
|
PoiUtil.exportWB("笔画长度", rows, workbook); |
|
|
PoiUtil.exportWB("笔画长度", rows, workbook); |
|
|
return workbook; |
|
|
return workbook; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
|
public void backCanvas(QuestionDto.BackPatientCanvas param, Long userId) { |
|
|
|
|
|
HtPatientCanvasLine back = new HtPatientCanvasLine(); |
|
|
|
|
|
back.setId(param.getPointId()); |
|
|
|
|
|
back.setIsDel(Constant.Ht.NO_DEL); |
|
|
|
|
|
patientCanvasLineMapper.updateByPrimaryKeySelective(back); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|