|
@@ -31,10 +31,12 @@ public class ClinicSatisfiedService {
|
|
|
static {
|
|
|
String mainAnswerString = "{\"A\": \"满意。\",\"B\": \"不满意:\",\"C\": \"未接触。\"}";
|
|
|
|
|
|
- // index:0 问题 item1,item3,item5,item7,item9,item13;住院 item9,item13,item15,item17,item19,item21
|
|
|
+ // index:0 问题 item1,item3,item5,item7,item9;住院 item9,item15,item17,item19,item21
|
|
|
String outpatientCheckboxOptionString = "{\"A\": \"叫号服务\",\"B\": \"等待时长\",\"C\": \"服务态度\",\"D\": \"沟通解释\",\"E\": \"及时响应\",\"F\": \"服装礼仪\",\"G\": \"准确率\"}";
|
|
|
- // index:1 问题 item11
|
|
|
+ // index:1 问题 item13
|
|
|
String outpatientCheckboxOptionString2 = "{\"A\": \"技术水平\",\"B\": \"隐私保护\",\"C\": \"服务态度\",\"D\": \"沟通解释\",\"E\": \"按时坐诊\",\"F\": \"服装礼仪\"}";
|
|
|
+ // index:6 问题 item11
|
|
|
+ String outpatientCheckboxOptionString3 = "{\"A\": \"技术水平\",\"B\": \"隐私保护\",\"C\": \"服务态度\",\"D\": \"沟通解释\",\"E\": \"病情巡视\",\"F\": \"服装礼仪\"}";
|
|
|
|
|
|
// index:2 问题 item1
|
|
|
String inpatientCheckboxOptionString = "{\"A\": \"技术水平\",\"B\": \"隐私保护\",\"C\": \"服务态度\",\"D\": \"沟通解释\",\"E\": \"病情巡视\",\"F\": \"服装礼仪\",\"G\": \"其他\"}";
|
|
@@ -45,6 +47,11 @@ public class ClinicSatisfiedService {
|
|
|
// index:5 问题 item7
|
|
|
String inpatientCheckboxOptionString4 = "{\"A\": \"卫生情况\",\"B\": \"口味\",\"C\": \"菜品\",\"D\": \"服务态度\",\"E\": \"服装礼仪\",\"F\": \"其他\"}";
|
|
|
|
|
|
+ // index: 7
|
|
|
+ String whyChooseHereOptionString = "{\"A\": \"慕名而来\",\"B\": \"就近选择\",\"C\": \"朋友推荐\",\"D\": \"网络查询\",\"E\": \"服务水平\",\"F\": \"环境设备\",\"G\": \"医疗价格\"}";
|
|
|
+ // index: 8
|
|
|
+ String willComeAgainOptionString = "{\"A\": \"会\",\"B\": \"不会\",\"C\": \"不一定\"}";
|
|
|
+
|
|
|
mainAnswers = JSONObject.parseObject(mainAnswerString);
|
|
|
|
|
|
checkboxOptions.add(JSONObject.parseObject(outpatientCheckboxOptionString));
|
|
@@ -54,6 +61,10 @@ public class ClinicSatisfiedService {
|
|
|
checkboxOptions.add(JSONObject.parseObject(inpatientCheckboxOptionString2));
|
|
|
checkboxOptions.add(JSONObject.parseObject(inpatientCheckboxOptionString3));
|
|
|
checkboxOptions.add(JSONObject.parseObject(inpatientCheckboxOptionString4));
|
|
|
+ checkboxOptions.add(JSONObject.parseObject(outpatientCheckboxOptionString3));
|
|
|
+
|
|
|
+ checkboxOptions.add(JSONObject.parseObject(whyChooseHereOptionString));
|
|
|
+ checkboxOptions.add(JSONObject.parseObject(willComeAgainOptionString));
|
|
|
}
|
|
|
|
|
|
@Autowired
|
|
@@ -118,8 +129,11 @@ public class ClinicSatisfiedService {
|
|
|
item.setItem5(combineAnswerAndOptions(item.getItem5(), item.getItem6(), 0));
|
|
|
item.setItem7(combineAnswerAndOptions(item.getItem7(), item.getItem8(), 0));
|
|
|
item.setItem9(combineAnswerAndOptions(item.getItem9(), item.getItem10(), 0));
|
|
|
- item.setItem11(combineAnswerAndOptions(item.getItem11(), item.getItem12(), 1));
|
|
|
- item.setItem13(combineAnswerAndOptions(item.getItem13(), item.getItem14(), 0));
|
|
|
+ item.setItem11(combineAnswerAndOptions(item.getItem11(), item.getItem12(), 6));
|
|
|
+ item.setItem13(combineAnswerAndOptions(item.getItem13(), item.getItem14(), 1));
|
|
|
+ item.setItem15(castYbkOption(item.getItem15(), item.getItem16Input()));
|
|
|
+ item.setItem1002(analyzedCheckboxOptions(item.getItem1002(), 7));
|
|
|
+ item.setItem1004(analyzedCheckboxOptions(item.getItem1004(), 8));
|
|
|
});
|
|
|
} else {
|
|
|
list.forEach(item -> {
|
|
@@ -134,6 +148,9 @@ public class ClinicSatisfiedService {
|
|
|
item.setItem17(combineAnswerAndOptions(item.getItem17(), item.getItem18(), 0));
|
|
|
item.setItem19(combineAnswerAndOptions(item.getItem19(), item.getItem20(), 0));
|
|
|
item.setItem21(combineAnswerAndOptions(item.getItem21(), item.getItem22(), 0));
|
|
|
+ item.setItem23(castYbkOption(item.getItem23(), item.getItem24Input()));
|
|
|
+ item.setItem1002(analyzedCheckboxOptions(item.getItem1002(), 7));
|
|
|
+ item.setItem1004(analyzedCheckboxOptions(item.getItem1004(), 8));
|
|
|
});
|
|
|
}
|
|
|
}
|
|
@@ -149,6 +166,19 @@ public class ClinicSatisfiedService {
|
|
|
return transferredAnswer + analyzedCheckboxOptions(options, optionIndex);
|
|
|
}
|
|
|
|
|
|
+ private String castYbkOption(String answer, String input) {
|
|
|
+ if (StringUtil.isBlank(answer)) {
|
|
|
+ return "";
|
|
|
+ }
|
|
|
+ if (!answer.equals("B")) {
|
|
|
+ return mainAnswers.getString(answer);
|
|
|
+ }
|
|
|
+ if (StringUtil.notBlank(input)) {
|
|
|
+ return "不满意:" + input;
|
|
|
+ }
|
|
|
+ return "不满意";
|
|
|
+ }
|
|
|
+
|
|
|
private String analyzedCheckboxOptions(String checkboxString, int optionIndex) {
|
|
|
if (StringUtil.isBlank(checkboxString)) {
|
|
|
return "";
|
|
@@ -157,7 +187,11 @@ public class ClinicSatisfiedService {
|
|
|
String[] arr = checkboxString.split("\\^");
|
|
|
StringBuilder builder = new StringBuilder();
|
|
|
for (int i = 0; i < arr.length - 1; i ++) {
|
|
|
- builder.append(options.getString(arr[i])).append(";");
|
|
|
+ String val = options.getString(arr[i]);
|
|
|
+ if (StringUtil.isBlank(val)) {
|
|
|
+ continue;
|
|
|
+ }
|
|
|
+ builder.append(val).append(";");
|
|
|
}
|
|
|
builder.append(options.getString(arr[arr.length - 1])).append("。");
|
|
|
return builder.toString();
|
|
@@ -201,6 +235,11 @@ public class ClinicSatisfiedService {
|
|
|
result.setTotalUnsatisfiedPercentage(makePercentage(result.getTotalUnsatisfiedCount(),result.getTotalAssessmentsCount()));
|
|
|
int totalOptionCount = 0;
|
|
|
int totalUnsatisfiedOptionCount = 0;
|
|
|
+
|
|
|
+ int mjzdzhlAssessmentCount = 0;
|
|
|
+ int mjzdzhlUnsatisfiedCount = 0;
|
|
|
+ int mjzysAssessmentCount = 0;
|
|
|
+ int mjzysUnsatisfiedCount = 0;
|
|
|
int yjkAssessmentCount = 0;
|
|
|
int yjkUnsatisfiedCount = 0;
|
|
|
int fskAssessmentCount = 0;
|
|
@@ -211,10 +250,9 @@ public class ClinicSatisfiedService {
|
|
|
int jykUnsatisfiedCount = 0;
|
|
|
int sfckAssessmentCount = 0;
|
|
|
int sfckUnsatisfiedCount = 0;
|
|
|
- int mzyhAssessmentCount = 0;
|
|
|
- int mzyhUnsatisfiedCount = 0;
|
|
|
- int jzyhAssessmentCount = 0;
|
|
|
- int jzyhUnsatisfiedCount = 0;
|
|
|
+ int ybkAssessmentCount = 0;
|
|
|
+ int ybkUnsatisfiedCount = 0;
|
|
|
+
|
|
|
// <-- 以下住院独有
|
|
|
int hlryAssessmentCount = 0;
|
|
|
int hlryUnsatisfiedCount = 0;
|
|
@@ -224,6 +262,15 @@ public class ClinicSatisfiedService {
|
|
|
int hjwsUnsatisfiedCount = 0;
|
|
|
int stAssessmentCount = 0;
|
|
|
int stUnsatisfiedCount = 0;
|
|
|
+ int mzyhAssessmentCount = 0;
|
|
|
+ int mzyhUnsatisfiedCount = 0;
|
|
|
+ int jzyhAssessmentCount = 0;
|
|
|
+ int jzyhUnsatisfiedCount = 0;
|
|
|
+
|
|
|
+ int mjzdzhlCheckedOptionsCount = 0;
|
|
|
+ JSONObject mjzdzhlOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0}");
|
|
|
+ int mjzysCheckedOptionsCount = 0;
|
|
|
+ JSONObject mjzysOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0}");
|
|
|
|
|
|
int yjkCheckedOptionsCount = 0;
|
|
|
JSONObject yjkOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
@@ -235,10 +282,7 @@ public class ClinicSatisfiedService {
|
|
|
JSONObject jykOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
int sfckCheckedOptionsCount = 0;
|
|
|
JSONObject sfckOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
- int mzyhCheckedOptionsCount = 0;
|
|
|
- JSONObject mzyhOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
- int jzyhCheckedOptionsCount = 0;
|
|
|
- JSONObject jzyhOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
+
|
|
|
// <-- 以下住院独有
|
|
|
int hlryCheckedOptionsCount = 0;
|
|
|
JSONObject hlryOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
@@ -248,8 +292,32 @@ public class ClinicSatisfiedService {
|
|
|
JSONObject hjwsOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
int stCheckedOptionsCount = 0;
|
|
|
JSONObject stOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
+ int mzyhCheckedOptionsCount = 0;
|
|
|
+ JSONObject mzyhOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
+ int jzyhCheckedOptionsCount = 0;
|
|
|
+ JSONObject jzyhOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
+
|
|
|
+ int whyComeHereOptionsCount = 0;
|
|
|
+ JSONObject whyComeHereOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0,\"D\": 0,\"E\": 0,\"F\": 0,\"G\": 0}");
|
|
|
+ int willComeAgainOptionsCount = 0;
|
|
|
+ JSONObject willComeAgainOptionsJson = JSONObject.parseObject("{\"A\": 0,\"B\": 0,\"C\": 0}");
|
|
|
+ int[] gradeNumDetails = new int[] {0,0,0,0,0,0,0,0,0,0};
|
|
|
|
|
|
for (SatisfiedBody body : list) {
|
|
|
+ if (StringUtil.notBlank(body.getItem1002())) {
|
|
|
+ whyComeHereOptionsCount = getCheckedOptionsCount(whyComeHereOptionsCount,
|
|
|
+ whyComeHereOptionsJson, body.getItem1002());
|
|
|
+ }
|
|
|
+ if (StringUtil.notBlank(body.getItem1004())) {
|
|
|
+ willComeAgainOptionsCount = getCheckedOptionsCount(willComeAgainOptionsCount,
|
|
|
+ willComeAgainOptionsJson, body.getItem1004());
|
|
|
+ }
|
|
|
+
|
|
|
+ if (null != body.getItem1006()) {
|
|
|
+ int grade = body.getItem1006();
|
|
|
+ gradeNumDetails[grade - 1] = gradeNumDetails[grade - 1] + 1;
|
|
|
+ }
|
|
|
+
|
|
|
if (StringUtil.notBlank(body.getItem1()) && !body.getItem1().equals("C")) {
|
|
|
totalOptionCount += 1;
|
|
|
if (visitType == VisitType.OUTPATIENT) {
|
|
@@ -340,10 +408,11 @@ public class ClinicSatisfiedService {
|
|
|
yjkCheckedOptionsCount = getCheckedOptionsCount(yjkCheckedOptionsCount, yjkOptionsJson, body.getItem10());
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
if (StringUtil.notBlank(body.getItem11()) && !body.getItem11().equals("C")) {
|
|
|
totalOptionCount += 1;
|
|
|
if (visitType == VisitType.OUTPATIENT) {
|
|
|
- mzyhAssessmentCount += 1;
|
|
|
+ mjzdzhlAssessmentCount += 1;
|
|
|
} else {
|
|
|
fskAssessmentCount += 1;
|
|
|
}
|
|
@@ -351,17 +420,18 @@ public class ClinicSatisfiedService {
|
|
|
if (Objects.equals("B", body.getItem11())) {
|
|
|
totalUnsatisfiedOptionCount += 1;
|
|
|
if (visitType == VisitType.OUTPATIENT) {
|
|
|
- mzyhUnsatisfiedCount += 1;
|
|
|
- mzyhCheckedOptionsCount = getCheckedOptionsCount(mzyhCheckedOptionsCount, mzyhOptionsJson, body.getItem12());
|
|
|
+ mjzdzhlUnsatisfiedCount += 1;
|
|
|
+ mjzdzhlCheckedOptionsCount = getCheckedOptionsCount(mjzdzhlCheckedOptionsCount, mjzdzhlOptionsJson, body.getItem12());
|
|
|
} else {
|
|
|
fskUnsatisfiedCount += 1;
|
|
|
fskCheckedOptionsCount = getCheckedOptionsCount(fskCheckedOptionsCount, fskOptionsJson, body.getItem12());
|
|
|
}
|
|
|
}
|
|
|
+
|
|
|
if (StringUtil.notBlank(body.getItem13()) && !body.getItem13().equals("C")) {
|
|
|
totalOptionCount += 1;
|
|
|
if (visitType == VisitType.OUTPATIENT) {
|
|
|
- jzyhAssessmentCount += 1;
|
|
|
+ mjzysAssessmentCount += 1;
|
|
|
} else {
|
|
|
csyxkAssessmentCount += 1;
|
|
|
}
|
|
@@ -369,28 +439,38 @@ public class ClinicSatisfiedService {
|
|
|
if (Objects.equals("B", body.getItem13())) {
|
|
|
totalUnsatisfiedOptionCount += 1;
|
|
|
if (visitType == VisitType.OUTPATIENT) {
|
|
|
- jzyhUnsatisfiedCount += 1;
|
|
|
- jzyhCheckedOptionsCount = getCheckedOptionsCount(jzyhCheckedOptionsCount, jzyhOptionsJson, body.getItem14());
|
|
|
+ mjzysUnsatisfiedCount += 1;
|
|
|
+ mjzysCheckedOptionsCount = getCheckedOptionsCount(mjzysCheckedOptionsCount, mjzysOptionsJson, body.getItem14());
|
|
|
} else {
|
|
|
csyxkUnsatisfiedCount += 1;
|
|
|
csyxkCheckedOptionsCount = getCheckedOptionsCount(csyxkCheckedOptionsCount, csyxkOptionsJson, body.getItem14());
|
|
|
}
|
|
|
}
|
|
|
- if (visitType == VisitType.INPATIENT) {
|
|
|
- if (StringUtil.notBlank(body.getItem15()) && !body.getItem15().equals("C")) {
|
|
|
- totalOptionCount += 1;
|
|
|
+
|
|
|
+ if (StringUtil.notBlank(body.getItem15()) && !body.getItem15().equals("C")) {
|
|
|
+ totalOptionCount += 1;
|
|
|
+ if (visitType == VisitType.OUTPATIENT) {
|
|
|
+ ybkAssessmentCount += 1;
|
|
|
+ } else {
|
|
|
jykAssessmentCount += 1;
|
|
|
}
|
|
|
- if (Objects.equals("B", body.getItem16())) {
|
|
|
- totalUnsatisfiedOptionCount += 1;
|
|
|
+ }
|
|
|
+ if (Objects.equals("B", body.getItem15())) {
|
|
|
+ totalUnsatisfiedOptionCount += 1;
|
|
|
+ if (visitType == VisitType.OUTPATIENT) {
|
|
|
+ ybkUnsatisfiedCount += 1;
|
|
|
+ } else {
|
|
|
jykUnsatisfiedCount += 1;
|
|
|
jykCheckedOptionsCount = getCheckedOptionsCount(jykCheckedOptionsCount, jykOptionsJson, body.getItem16());
|
|
|
}
|
|
|
+ }
|
|
|
+
|
|
|
+ if (visitType == VisitType.INPATIENT) {
|
|
|
if (StringUtil.notBlank(body.getItem17()) && !body.getItem17().equals("C")) {
|
|
|
totalOptionCount += 1;
|
|
|
sfckAssessmentCount += 1;
|
|
|
}
|
|
|
- if (Objects.equals("B", body.getItem18())) {
|
|
|
+ if (Objects.equals("B", body.getItem17())) {
|
|
|
totalUnsatisfiedOptionCount += 1;
|
|
|
sfckUnsatisfiedCount += 1;
|
|
|
sfckCheckedOptionsCount = getCheckedOptionsCount(sfckCheckedOptionsCount, sfckOptionsJson, body.getItem18());
|
|
@@ -399,7 +479,7 @@ public class ClinicSatisfiedService {
|
|
|
totalOptionCount += 1;
|
|
|
mzyhAssessmentCount += 1;
|
|
|
}
|
|
|
- if (Objects.equals("B", body.getItem20())) {
|
|
|
+ if (Objects.equals("B", body.getItem19())) {
|
|
|
totalUnsatisfiedOptionCount += 1;
|
|
|
mzyhUnsatisfiedCount += 1;
|
|
|
mzyhCheckedOptionsCount = getCheckedOptionsCount(mzyhCheckedOptionsCount, mzyhOptionsJson, body.getItem20());
|
|
@@ -408,7 +488,7 @@ public class ClinicSatisfiedService {
|
|
|
totalOptionCount += 1;
|
|
|
jzyhAssessmentCount += 1;
|
|
|
}
|
|
|
- if (Objects.equals("B", body.getItem22())) {
|
|
|
+ if (Objects.equals("B", body.getItem21())) {
|
|
|
totalUnsatisfiedOptionCount += 1;
|
|
|
jzyhUnsatisfiedCount += 1;
|
|
|
jzyhCheckedOptionsCount = getCheckedOptionsCount(jzyhCheckedOptionsCount, jzyhOptionsJson, body.getItem22());
|
|
@@ -418,62 +498,136 @@ public class ClinicSatisfiedService {
|
|
|
result.setTotalOptionCount(totalOptionCount);
|
|
|
result.setTotalUnsatisfiedOptionCount(totalUnsatisfiedOptionCount);
|
|
|
result.setTotalUnsatisfiedOptionPercentage(makePercentage(totalUnsatisfiedOptionCount, totalOptionCount));
|
|
|
+
|
|
|
+ result.setMjzdzhlAssessmentCount(mjzdzhlAssessmentCount);
|
|
|
+ result.setMjzysAssessmentCount(mjzysAssessmentCount);
|
|
|
result.setYjkAssessmentCount(yjkAssessmentCount);
|
|
|
result.setFskAssessmentCount(fskAssessmentCount);
|
|
|
result.setCsyxkAssessmentCount(csyxkAssessmentCount);
|
|
|
result.setJykAssessmentCount(jykAssessmentCount);
|
|
|
result.setSfckAssessmentCount(sfckAssessmentCount);
|
|
|
- result.setMzyhAssessmentCount(mzyhAssessmentCount);
|
|
|
- result.setJzyhAssessmentCount(jzyhAssessmentCount);
|
|
|
+ result.setYbkAssessmentCount(ybkAssessmentCount);
|
|
|
// <-- 以下住院独有
|
|
|
result.setHlryAssessmentCount(hlryAssessmentCount);
|
|
|
result.setKsysAssessmentCount(ksysAssessmentCount);
|
|
|
result.setHjwsAssessmentCount(hjwsAssessmentCount);
|
|
|
result.setStAssessmentCount(stAssessmentCount);
|
|
|
+ result.setMzyhAssessmentCount(mzyhAssessmentCount);
|
|
|
+ result.setJzyhAssessmentCount(jzyhAssessmentCount);
|
|
|
// -->
|
|
|
|
|
|
+ result.setMjzdzhlUnsatisfiedCount(mjzdzhlUnsatisfiedCount);
|
|
|
+ result.setMjzysUnsatisfiedCount(mjzysUnsatisfiedCount);
|
|
|
result.setYjkUnsatisfiedCount(yjkUnsatisfiedCount);
|
|
|
result.setFskUnsatisfiedCount(fskUnsatisfiedCount);
|
|
|
result.setCsyxkUnsatisfiedCount(csyxkUnsatisfiedCount);
|
|
|
result.setJykUnsatisfiedCount(jykUnsatisfiedCount);
|
|
|
result.setSfckUnsatisfiedCount(sfckUnsatisfiedCount);
|
|
|
- result.setMzyhUnsatisfiedCount(mzyhUnsatisfiedCount);
|
|
|
- result.setJzyhUnsatisfiedCount(jzyhUnsatisfiedCount);
|
|
|
- // <-- 以下住院独有
|
|
|
+ result.setYbkUnsatisfiedCount(ybkUnsatisfiedCount);
|
|
|
+ // <-- 以下住院独有
|
|
|
result.setHlryUnsatisfiedCount(hlryUnsatisfiedCount);
|
|
|
result.setKsysUnsatisfiedCount(ksysUnsatisfiedCount);
|
|
|
result.setHjwsUnsatisfiedCount(hjwsUnsatisfiedCount);
|
|
|
result.setStUnsatisfiedCount(stUnsatisfiedCount);
|
|
|
+ result.setMzyhUnsatisfiedCount(mzyhUnsatisfiedCount);
|
|
|
+ result.setJzyhUnsatisfiedCount(jzyhUnsatisfiedCount);
|
|
|
// -->
|
|
|
-
|
|
|
+
|
|
|
+ result.setMjzdzhlUnsatisfiedPercentage(makePercentage(mjzdzhlUnsatisfiedCount, mjzdzhlAssessmentCount));
|
|
|
+ result.setMjzysUnsatisfiedPercentage(makePercentage(mjzysUnsatisfiedCount, mjzysAssessmentCount));
|
|
|
result.setYjkUnsatisfiedPercentage(makePercentage(yjkUnsatisfiedCount, yjkAssessmentCount));
|
|
|
result.setFskUnsatisfiedPercentage(makePercentage(fskUnsatisfiedCount, fskAssessmentCount));
|
|
|
result.setCsyxkUnsatisfiedPercentage(makePercentage(csyxkUnsatisfiedCount, csyxkAssessmentCount));
|
|
|
result.setJykUnsatisfiedPercentage(makePercentage(jykUnsatisfiedCount, jykAssessmentCount));
|
|
|
result.setSfckUnsatisfiedPercentage(makePercentage(sfckUnsatisfiedCount, sfckAssessmentCount));
|
|
|
- result.setMzyhUnsatisfiedPercentage(makePercentage(mzyhUnsatisfiedCount, mzyhAssessmentCount));
|
|
|
- result.setJzyhUnsatisfiedPercentage(makePercentage(jzyhUnsatisfiedCount, jzyhAssessmentCount));
|
|
|
+ result.setYbkUnsatisfiedPercentage(makePercentage(ybkUnsatisfiedCount, ybkAssessmentCount));
|
|
|
// <-- 以下住院独有
|
|
|
result.setHlryUnsatisfiedPercentage(makePercentage(hlryUnsatisfiedCount, hlryAssessmentCount));
|
|
|
result.setKsysUnsatisfiedPercentage(makePercentage(ksysUnsatisfiedCount, ksysAssessmentCount));
|
|
|
result.setHjwsUnsatisfiedPercentage(makePercentage(hjwsUnsatisfiedCount, hjwsAssessmentCount));
|
|
|
result.setStUnsatisfiedPercentage(makePercentage(stUnsatisfiedCount, stAssessmentCount));
|
|
|
+ result.setMzyhUnsatisfiedPercentage(makePercentage(mzyhUnsatisfiedCount, mzyhAssessmentCount));
|
|
|
+ result.setJzyhUnsatisfiedPercentage(makePercentage(jzyhUnsatisfiedCount, jzyhAssessmentCount));
|
|
|
// -->
|
|
|
-
|
|
|
+
|
|
|
+ result.setMjzdzhlUnsatisfiedOption(fillOptionDetails(mjzdzhlAssessmentCount, mjzdzhlCheckedOptionsCount, mjzdzhlOptionsJson, 6));
|
|
|
+ result.setMjzysUnsatisfiedOption(fillOptionDetails(mjzysAssessmentCount, mjzysCheckedOptionsCount, mjzysOptionsJson, 1));
|
|
|
result.setYjkUnsatisfiedOption(fillOptionDetails(yjkAssessmentCount, yjkCheckedOptionsCount, yjkOptionsJson, 0));
|
|
|
result.setFskUnsatisfiedOption(fillOptionDetails(fskAssessmentCount, fskCheckedOptionsCount, fskOptionsJson, visitType == VisitType.OUTPATIENT ? 0 : 3));
|
|
|
result.setCsyxkUnsatisfiedOption(fillOptionDetails(csyxkAssessmentCount, csyxkCheckedOptionsCount, csyxkOptionsJson, 0));
|
|
|
result.setJykUnsatisfiedOption(fillOptionDetails(jykAssessmentCount, jykCheckedOptionsCount, jykOptionsJson, 0));
|
|
|
result.setSfckUnsatisfiedOption(fillOptionDetails(sfckAssessmentCount, sfckCheckedOptionsCount, sfckOptionsJson, 0));
|
|
|
- result.setMzyhUnsatisfiedOption(fillOptionDetails(mzyhAssessmentCount, mzyhCheckedOptionsCount, mzyhOptionsJson, visitType == VisitType.OUTPATIENT ? 1 : 0));
|
|
|
- result.setJzyhUnsatisfiedOption(fillOptionDetails(jzyhAssessmentCount, jzyhCheckedOptionsCount, jzyhOptionsJson, 0));
|
|
|
|
|
|
// <-- 以下住院独有
|
|
|
result.setHlryUnsatisfiedOption(fillOptionDetails(hlryAssessmentCount, hlryCheckedOptionsCount, hlryOptionsJson, 2));
|
|
|
result.setKsysUnsatisfiedOption(fillOptionDetails(ksysAssessmentCount, ksysCheckedOptionsCount, ksysOptionsJson, 3));
|
|
|
result.setHjwsUnsatisfiedOption(fillOptionDetails(hjwsAssessmentCount, hjwsCheckedOptionsCount, hjwsOptionsJson, 4));
|
|
|
result.setStUnsatisfiedOption(fillOptionDetails(stAssessmentCount, stCheckedOptionsCount, stOptionsJson, 5));
|
|
|
+ result.setMzyhUnsatisfiedOption(fillOptionDetails(mzyhAssessmentCount, mzyhCheckedOptionsCount, mzyhOptionsJson, visitType == VisitType.OUTPATIENT ? 1 : 0));
|
|
|
+ result.setJzyhUnsatisfiedOption(fillOptionDetails(jzyhAssessmentCount, jzyhCheckedOptionsCount, jzyhOptionsJson, 0));
|
|
|
// -->
|
|
|
+
|
|
|
+ WhyChooseHere why = new WhyChooseHere();
|
|
|
+ WillComeAgain will = new WillComeAgain();
|
|
|
+ GradeNum grade = new GradeNum();
|
|
|
+
|
|
|
+ why.setTotalCount(whyComeHereOptionsCount);
|
|
|
+ why.setMmelCount(whyComeHereOptionsJson.getInteger("A"));
|
|
|
+ why.setJjxzCount(whyComeHereOptionsJson.getInteger("B"));
|
|
|
+ why.setPytjCount(whyComeHereOptionsJson.getInteger("C"));
|
|
|
+ why.setWlcxCount(whyComeHereOptionsJson.getInteger("D"));
|
|
|
+ why.setFwspCount(whyComeHereOptionsJson.getInteger("E"));
|
|
|
+ why.setHjsbCount(whyComeHereOptionsJson.getInteger("F"));
|
|
|
+ why.setYljgCount(whyComeHereOptionsJson.getInteger("G"));
|
|
|
+
|
|
|
+ why.setMmelPercentage(makePercentage(why.getMmelCount(), whyComeHereOptionsCount));
|
|
|
+ why.setJjxzPercentage(makePercentage(why.getJjxzCount(), whyComeHereOptionsCount));
|
|
|
+ why.setPytjPercentage(makePercentage(why.getPytjCount(), whyComeHereOptionsCount));
|
|
|
+ why.setWlcxPercentage(makePercentage(why.getWlcxCount(), whyComeHereOptionsCount));
|
|
|
+ why.setFwspPercentage(makePercentage(why.getFwspCount(), whyComeHereOptionsCount));
|
|
|
+ why.setHjsbPercentage(makePercentage(why.getHjsbCount(), whyComeHereOptionsCount));
|
|
|
+ why.setYljgPercentage(makePercentage(why.getYljgCount(), whyComeHereOptionsCount));
|
|
|
+
|
|
|
+ will.setTotalCount(willComeAgainOptionsCount);
|
|
|
+ will.setYesCount(willComeAgainOptionsJson.getInteger("A"));
|
|
|
+ will.setNoCount(willComeAgainOptionsJson.getInteger("B"));
|
|
|
+ will.setBydCount(willComeAgainOptionsJson.getInteger("C"));
|
|
|
+
|
|
|
+ will.setYesPercentage(makePercentage(will.getYesCount(), willComeAgainOptionsCount));
|
|
|
+ will.setNoPercentage(makePercentage(will.getNoCount(), willComeAgainOptionsCount));
|
|
|
+ will.setBydPercentage(makePercentage(will.getBydCount(), willComeAgainOptionsCount));
|
|
|
+
|
|
|
+ int gradeCount = 0;
|
|
|
+ for (int item : gradeNumDetails) {
|
|
|
+ gradeCount += item;
|
|
|
+ }
|
|
|
+ grade.setTotalCount(gradeCount);
|
|
|
+ grade.setOneCount(gradeNumDetails[0]);
|
|
|
+ grade.setTwoCount(gradeNumDetails[1]);
|
|
|
+ grade.setThreeCount(gradeNumDetails[2]);
|
|
|
+ grade.setFourCount(gradeNumDetails[3]);
|
|
|
+ grade.setFiveCount(gradeNumDetails[4]);
|
|
|
+ grade.setSixCount(gradeNumDetails[5]);
|
|
|
+ grade.setSevenCount(gradeNumDetails[6]);
|
|
|
+ grade.setEightCount(gradeNumDetails[7]);
|
|
|
+ grade.setNineCount(gradeNumDetails[8]);
|
|
|
+ grade.setTenCount(gradeNumDetails[9]);
|
|
|
+
|
|
|
+ grade.setOnePercentage(makePercentage(grade.getOneCount(), gradeCount));
|
|
|
+ grade.setTwoPercentage(makePercentage(grade.getTwoCount(), gradeCount));
|
|
|
+ grade.setThreePercentage(makePercentage(grade.getThreeCount(), gradeCount));
|
|
|
+ grade.setFourPercentage(makePercentage(grade.getFourCount(), gradeCount));
|
|
|
+ grade.setFivePercentage(makePercentage(grade.getFiveCount(), gradeCount));
|
|
|
+ grade.setSixPercentage(makePercentage(grade.getSixCount(), gradeCount));
|
|
|
+ grade.setSevenPercentage(makePercentage(grade.getSevenCount(), gradeCount));
|
|
|
+ grade.setEightPercentage(makePercentage(grade.getEightCount(), gradeCount));
|
|
|
+ grade.setNinePercentage(makePercentage(grade.getNineCount(), gradeCount));
|
|
|
+ grade.setTenPercentage(makePercentage(grade.getTenCount(), gradeCount));
|
|
|
+
|
|
|
+ result.setWhyChooseHere(why);
|
|
|
+ result.setWillComeAgain(will);
|
|
|
+ result.setGradeNum(grade);
|
|
|
+
|
|
|
return ResultVoUtil.success(result);
|
|
|
}
|
|
|
|
|
@@ -506,14 +660,17 @@ public class ClinicSatisfiedService {
|
|
|
unsatisfiedOption.setGtjsCount(optionsJson.getInteger("D"));
|
|
|
unsatisfiedOption.setGtjsPercentage(makePercentage(unsatisfiedOption.getGtjsCount(), checkedOptionSize));
|
|
|
}
|
|
|
- if (checkboxOptionIndex == 2 || checkboxOptionIndex == 3) {
|
|
|
+ if (checkboxOptionIndex == 2 || checkboxOptionIndex == 3 || checkboxOptionIndex == 6) {
|
|
|
unsatisfiedOption.setJsspCount(optionsJson.getInteger("A"));
|
|
|
unsatisfiedOption.setJsspPercentage(makePercentage(unsatisfiedOption.getJsspCount(), checkedOptionSize));
|
|
|
unsatisfiedOption.setYsbhCount(optionsJson.getInteger("B"));
|
|
|
unsatisfiedOption.setYsbhPercentage(makePercentage(unsatisfiedOption.getYsbhCount(), checkedOptionSize));
|
|
|
- unsatisfiedOption.setQtCount(optionsJson.getInteger("G"));
|
|
|
- unsatisfiedOption.setQtPercentage(makePercentage(unsatisfiedOption.getQtCount(), checkedOptionSize));
|
|
|
- if (checkboxOptionIndex == 2) {
|
|
|
+
|
|
|
+ if (checkboxOptionIndex != 6) {
|
|
|
+ unsatisfiedOption.setQtCount(optionsJson.getInteger("G"));
|
|
|
+ unsatisfiedOption.setQtPercentage(makePercentage(unsatisfiedOption.getQtCount(), checkedOptionSize));
|
|
|
+ }
|
|
|
+ if (checkboxOptionIndex == 2 || checkboxOptionIndex == 6) {
|
|
|
unsatisfiedOption.setBqxsCount(optionsJson.getInteger("E"));
|
|
|
unsatisfiedOption.setBqxsPercentage(makePercentage(unsatisfiedOption.getBqxsCount(), checkedOptionSize));
|
|
|
} else {
|
|
@@ -558,8 +715,7 @@ public class ClinicSatisfiedService {
|
|
|
String[] arr = options.split("\\^");
|
|
|
optionsCount += arr.length;
|
|
|
for (String option : arr) {
|
|
|
- int temp = optionsJson.getIntValue(option);
|
|
|
- temp += 1;
|
|
|
+ int temp = optionsJson.getIntValue(option) + 1;
|
|
|
optionsJson.replace(option, temp);
|
|
|
}
|
|
|
}
|