ExcelRiBaoLYBM4.java 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326
  1. package com.bofeng.entity;
  2. import com.alibaba.excel.annotation.ExcelProperty;
  3. import com.google.common.base.Strings;
  4. import com.yvan.platform.Conv;
  5. import lombok.Getter;
  6. import lombok.Setter;
  7. import java.math.BigDecimal;
  8. @Getter
  9. @Setter
  10. public class ExcelRiBaoLYBM4 {
  11. private String ridgepole = "";
  12. private String unit = "";
  13. private String doorplate = "";
  14. private BigDecimal temperature = new BigDecimal(0);
  15. private int grender = 0;
  16. private String familyStatus = "0,0,0,0,0,0,0";
  17. private int medical = 0;
  18. private int cough = 0;
  19. private int muscle = 0;
  20. private int dyspnea = 0;
  21. private int fatigue = 0;
  22. private int diarrhea = 0;
  23. private int singleRoom = 0;
  24. private int scoreRezult = 0;
  25. private int safetyNum = 0;
  26. private int reportStatus = 0;
  27. private int sureNum = 0;
  28. private int singleNum = 0;
  29. private int suspectedNum = 0;
  30. private int normalNum = 0;
  31. private String statusDesp = "";
  32. private String others = "";
  33. private Long tripId = 0L;
  34. private int workLocal = 0;
  35. private String workLocalOther = "";
  36. private int todayLocal = 0;
  37. private String todayLocalOther = "";
  38. private int isTrip = 0;
  39. @ExcelProperty(value = "部门名称", index = 1)
  40. private String loudong = "";
  41. public String getLoudong() {
  42. if (loudong.length() <= 0) {
  43. loudong = ridgepole + unit;
  44. }
  45. return loudong;
  46. }
  47. @ExcelProperty(value = "工号", index = 3)
  48. private String fanghao = "";
  49. public String getFanghao() {
  50. if (fanghao.length() <= 0) {
  51. fanghao = doorplate;
  52. }
  53. return fanghao;
  54. }
  55. @ExcelProperty(value = "姓名", index = 0)
  56. private String linkman;
  57. @ExcelProperty(value = "联系电话", index = 2)
  58. private String phone;
  59. private String safetyNumStr = "";
  60. public String getSafetyNumStr() {
  61. if (reportStatus == 0) {
  62. return "未填报";
  63. }
  64. safetyNumStr = "" + safetyNum;
  65. return safetyNumStr;
  66. }
  67. private String sureNumStr;
  68. public String getSureNumStr() {
  69. if (reportStatus == 0) {
  70. return "未填报";
  71. }
  72. sureNumStr = "" + sureNum;
  73. return sureNumStr;
  74. }
  75. private String singleNumStr;
  76. public String getSingleNumStr() {
  77. if (reportStatus == 0) {
  78. return "未填报";
  79. }
  80. singleNumStr = "" + singleNum;
  81. return singleNumStr;
  82. }
  83. private String suspectedNumStr;
  84. public String getSuspectedNumStr() {
  85. if (reportStatus == 0) {
  86. return "未填报";
  87. }
  88. suspectedNumStr = "" + suspectedNum;
  89. return suspectedNumStr;
  90. }
  91. private String normalNumStr;
  92. public String getNormalNumStr() {
  93. if (reportStatus == 0) {
  94. return "未填报";
  95. }
  96. normalNumStr = "" + normalNum;
  97. return normalNumStr;
  98. }
  99. private String userName;
  100. //
  101. // @ExcelProperty(value = "性别", index = 10)
  102. // private String grenderStr;
  103. // public String getGrenderStr() {
  104. // if (grender == 1) {
  105. // grenderStr = "男";
  106. // } else if (grender == 2) {
  107. // grenderStr = "女";
  108. // } else {
  109. // grenderStr = "未知";
  110. // }
  111. // return grenderStr;
  112. // }
  113. // @ExcelProperty(value = "年龄", index = 11)
  114. // private String age;
  115. private String temperatureStr;
  116. public String getTemperatureStr() {
  117. if (reportStatus == 0) {
  118. return "未填报";
  119. }
  120. temperatureStr = temperature.floatValue() > 10 ? temperature + "" : "未填报";
  121. return temperatureStr;
  122. }
  123. private String medicalStr;
  124. public String getMedicalStr() {
  125. if (reportStatus == 0) {
  126. return "未填报";
  127. }
  128. if (medical == 0) {
  129. medicalStr = "无";
  130. } else if (medical == 1) {
  131. medicalStr = "确诊";
  132. } else if (medical == 2) {
  133. medicalStr = "疑似";
  134. } else if (medical == 3) {
  135. medicalStr = "有接触史";
  136. } else if (medical == 4) {
  137. medicalStr = "解除隔离";
  138. }
  139. return medicalStr;
  140. }
  141. private String singleRoomStr;
  142. public String getSingleRoomStr() {
  143. if (reportStatus == 0) {
  144. return "未填报";
  145. }
  146. if (singleRoom == 0) {
  147. singleRoomStr = "否";
  148. } else {
  149. singleRoomStr = "是";
  150. }
  151. return singleRoomStr;
  152. }
  153. private String baseDesc = "";
  154. public String getBaseDesc() {
  155. if (reportStatus == 0) {
  156. return "未填报";
  157. }
  158. if (Conv.NI(familyStatus.split(",")[0]) == 1) {
  159. baseDesc += "心血管疾病(服用ARB),";
  160. } else if (Conv.NI(familyStatus.split(",")[1]) == 1) {
  161. baseDesc += "心血管疾病(未服用ARB),";
  162. }
  163. if (Conv.NI(familyStatus.split(",")[2]) == 1) {
  164. baseDesc += "呼吸系统病史,";
  165. }
  166. if (Conv.NI(familyStatus.split(",")[3]) == 1) {
  167. baseDesc += "肿瘤病史,";
  168. }
  169. if (Conv.NI(familyStatus.split(",")[4]) == 1) {
  170. baseDesc += "糖尿病史,";
  171. }
  172. if (Conv.NI(familyStatus.split(",")[5]) == 1) {
  173. baseDesc += "服用过激素药物,";
  174. }
  175. if (Conv.NI(familyStatus.split(",")[6]) == 1) {
  176. baseDesc += "妊娠期";
  177. }
  178. return baseDesc;
  179. }
  180. @ExcelProperty(value = "病情描述", index = 4)
  181. private String bingqingDesc = "";
  182. public String getBingqingDesc() {
  183. if (reportStatus == 0) {
  184. return "未填报";
  185. }
  186. if (medical == 1) {
  187. bingqingDesc += "已确诊、";
  188. }
  189. if (singleRoom == 1) {
  190. bingqingDesc += "单间隔离、";
  191. }
  192. bingqingDesc = bingqingDesc + "体温:" + getTemperatureStr() + "、";
  193. if (cough == 1) {
  194. bingqingDesc += "偶尔短暂咳嗽、";
  195. } else if (cough == 2) {
  196. bingqingDesc += "咳嗽轻度影响生活、";
  197. } else if (cough == 3) {
  198. bingqingDesc += "咳嗽严重影响生活、";
  199. }
  200. if (muscle == 1) {
  201. bingqingDesc += "肌肉按压有酸痛、";
  202. } else if (muscle == 2) {
  203. bingqingDesc += "偶尔肌肉按压酸痛、";
  204. } else if (muscle == 3) {
  205. bingqingDesc += "肌肉按压持续酸痛、";
  206. }
  207. if (dyspnea == 1) {
  208. bingqingDesc += "呼吸急走或上坡气短、";
  209. } else if (dyspnea == 2) {
  210. bingqingDesc += "呼吸气短而走路变慢、";
  211. } else if (dyspnea == 3) {
  212. bingqingDesc += "呼吸走路数分钟后气短、";
  213. } else if (dyspnea == 4) {
  214. bingqingDesc += "呼吸气短无法离开房间、";
  215. }
  216. if (fatigue == 1) {
  217. bingqingDesc += "可体力劳动但觉得累、";
  218. } else if (fatigue == 2) {
  219. bingqingDesc += "轻体力劳动后长时间不能恢复、";
  220. } else if (fatigue == 3) {
  221. bingqingDesc += "不能正常生活、";
  222. }
  223. if (diarrhea == 1) {
  224. bingqingDesc += "轻度腹泻少于于3次、";
  225. } else if (diarrhea == 2) {
  226. bingqingDesc += "中度腹泻4-6次、";
  227. } else if (diarrhea == 3) {
  228. bingqingDesc += "重度腹泻超过6次、";
  229. }
  230. if (!Strings.isNullOrEmpty(statusDesp)) {
  231. bingqingDesc += statusDesp;
  232. bingqingDesc += "、";
  233. }
  234. if (!Strings.isNullOrEmpty(others)) {
  235. bingqingDesc += others;
  236. }
  237. return bingqingDesc;
  238. }
  239. private String workLoalDesc = "";
  240. public String getWorkLoalDesc() {
  241. if (workLocal == 1) {
  242. workLoalDesc = "武汉";
  243. } else if (workLocal == 2) {
  244. workLoalDesc = "宜昌";
  245. } else if (workLocal == 3) {
  246. workLoalDesc = "当阳";
  247. }else if (workLocal == 4) {
  248. workLoalDesc = workLocalOther;
  249. }
  250. return workLoalDesc;
  251. }
  252. private String todayLoalDesc = "";
  253. public String getTodayLoalDesc() {
  254. if (todayLocal == 1) {
  255. todayLoalDesc = "武汉";
  256. } else if (todayLocal == 2) {
  257. todayLoalDesc = "宜昌";
  258. } else if (todayLocal == 3) {
  259. todayLoalDesc = "当阳";
  260. } else if (todayLocal == 4) {
  261. todayLoalDesc = todayLocalOther;
  262. }
  263. return workLoalDesc;
  264. }
  265. private String isTripDesc = "";
  266. public String getIsTripDesc() {
  267. if (isTrip == 1) {
  268. isTripDesc = "是";
  269. } else if (isTrip == 0) {
  270. isTripDesc = "否";
  271. }
  272. return isTripDesc;
  273. }
  274. private String tripDetDesc = "";
  275. }