瀏覽代碼

Merge branch 'dev' of http://192.168.1.220:10080/Amoy2/wlyy2.0 into dev

# Conflicts:
#	common/common-entity/src/main/java/com/yihu/jw/entity/specialist/rehabilitation/PatientRehabilitationPlanDO.java
wangzhinan 5 年之前
父節點
當前提交
8ceae3682f

+ 8 - 0
business/es-service/src/main/java/com/yihu/jw/es/service/StatisticsEsService.java

@ -24,10 +24,13 @@ import org.apache.commons.lang3.StringUtils;
import org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParametersFactory;
import org.omg.CORBA.OBJ_ADAPTER;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.jdbc.core.JdbcTemplate;
import org.springframework.stereotype.Service;
import javax.transaction.Transactional;
import javax.xml.soap.SAAJMetaFactory;
import java.security.acl.LastOwnerException;
import java.text.DecimalFormat;
@ -39,8 +42,11 @@ import java.util.*;
 * Created by wangzhinan on 2019/12/3.
 */
@Service
@Transactional
public class StatisticsEsService {
    Logger logger = LoggerFactory.getLogger(StatisticsEsService.class);
    @Autowired
    private ElasticsearchUtil elasticsearchUtil;
    @Autowired
@ -150,6 +156,7 @@ public class StatisticsEsService {
     * @throws Exception
     */
    public JSONObject getOutPatientLine(String startDate, String endDate, String area, int level, String index,int interval, String level2_type) throws Exception {
        logger.info("service index:"+index+" and level2_type:"+level2_type+" and level:"+level);
        //问诊量
        JSONObject object = new JSONObject();
        if (interval==1){
@ -426,6 +433,7 @@ public class StatisticsEsService {
    public JSONObject getOutPatientPriceLine(String startDate, String endDate, String area, int level, String index,int interval, String level2_type) throws Exception {
        logger.info("service index:"+index+" and level2_type:"+level2_type+" and level:"+level);
        //问诊量
        JSONObject object = new JSONObject();
        if (interval==1){

+ 6 - 1
svr/svr-internet-hospital/src/main/java/com/yihu/jw/hospital/endpoint/statistics/EsStatisticsEndpoint.java

@ -11,6 +11,8 @@ import com.yihu.jw.rm.hospital.BaseHospitalRequestMapping;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
@ -27,6 +29,9 @@ import java.util.List;
@Api(value = "统计分析", description = "统计分析", tags = {"统计分析"})
public class EsStatisticsEndpoint extends EnvelopRestEndpoint {
    Logger logger = LoggerFactory.getLogger(EsStatisticsEndpoint.class);
    @Autowired
    private StatisticsEsService statisticsEsService;
@ -54,8 +59,8 @@ public class EsStatisticsEndpoint extends EnvelopRestEndpoint {
            @RequestParam(required = false)int interval,
            @RequestParam(required = false) String level2_type) {
            //新版与旧版统计适配
        String[] indexes = index.split(",");
        JSONObject result = new JSONObject();
        logger.info("index:"+index+" and level2_type:"+level2_type+" and level:"+level);
        try {
            if (index.contains("3")){
                result= statisticsEsService.getOutPatientPriceLine(startDate, endDate, area, level, index, interval,level2_type);