Commit 9a79d7110989293af01bb4b9ce062f3ff74a4e2d

Authored by jiangjiazhi
1 parent e10e8170f7

commit

Showing 1 changed file with 11 additions and 0 deletions

platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntenatalExaminationController.java View file @ 9a79d71
... ... @@ -19,8 +19,11 @@
19 19 import com.lyms.platform.operate.web.request.*;
20 20 import com.lyms.platform.permission.service.CouponService;
21 21 import org.apache.commons.lang.StringUtils;
  22 +import org.slf4j.Logger;
  23 +import org.slf4j.LoggerFactory;
22 24 import org.springframework.beans.factory.annotation.Autowired;
23 25 import org.springframework.stereotype.Controller;
  26 +import org.springframework.util.StopWatch;
24 27 import org.springframework.web.bind.annotation.RequestBody;
25 28 import org.springframework.web.bind.annotation.RequestMapping;
26 29 import org.springframework.web.bind.annotation.RequestMethod;
... ... @@ -37,6 +40,8 @@
37 40 */
38 41 @Controller
39 42 public class AntenatalExaminationController extends BaseController {
  43 +
  44 + private static final Logger logger = LoggerFactory.getLogger(AntenatalExaminationFacade.class);
40 45 @Autowired
41 46 private AntenatalExaminationFacade antenatalExaminationFacade;
42 47  
43 48  
44 49  
... ... @@ -163,8 +168,14 @@
163 168 @TokenRequired
164 169 public BaseResponse addOneAntEx(@Valid @RequestBody AntExcAddRequest antExcAddRequest,HttpServletRequest request) {
165 170 LoginContext loginState = (LoginContext) request.getAttribute("loginContext");
  171 + StopWatch stopWatch=new StopWatch("start post antex");
  172 + stopWatch.start("addOneAnetExChu");
166 173 BaseResponse baseResponse = antenatalExaminationFacade.addOneAnetExChu(antExcAddRequest, loginState.getId());
  174 + stopWatch.stop();
  175 + stopWatch.start("getPatientsInfoByCode");
167 176 baseResponse.setObject(couponService.getPatientsInfoByCode(antExcAddRequest.getCouponCode()));
  177 + stopWatch.stop();
  178 + logger.info(stopWatch.toString());
168 179 return baseResponse;
169 180 }
170 181