trick9191 vor 8 Jahren
Ursprung
Commit
cd15d3c00a

+ 2 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/prescription/PrescriptionExpressageService.java

@ -8,12 +8,14 @@ import com.yihu.wlyy.repository.patient.PatientDao;
import com.yihu.wlyy.repository.prescription.*;
import com.yihu.wlyy.util.DateUtil;
import com.yihu.wlyy.util.SystemConf;
import org.json.JSONArray;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import java.util.Date;
import java.util.List;
import java.util.Map;
import java.util.UUID;
import java.util.concurrent.ExecutionException;

+ 7 - 1
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/app/prescription/PrescriptionInfoService.java

@ -902,7 +902,7 @@ public class PrescriptionInfoService extends BaseService {
        if(StringUtils.isNotBlank(AllocationType)){
            //1为未分配建管师列表
            if("1".equals(AllocationType)){
                pre_sql.append(" AND pr.expressage_code IS NULL ");
                pre_sql.append(" AND e.expressage_code IS NULL ");
            }
        }
@ -1109,4 +1109,10 @@ public class PrescriptionInfoService extends BaseService {
        List<Map<String,Object>> rs = jdbcTemplate.queryForList(sql.toString(),new Object[]{jwHospital,jwDoctorCode});
        return new JSONArray(rs);
    }
    public JSONArray getUsageDict(){
        StringBuffer sql = new StringBuffer("SELECT t.code,t.`name` FROM zy_common_dict t WHERE t.dict_name='IV_RECIPE_USAGE_DICT'");
        List<Map<String,Object>> rs = jdbcTemplate.queryForList(sql.toString());
        return new JSONArray(rs);
    }
}

+ 8 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/service/third/jw/JwPrescriptionService.java

@ -4,6 +4,8 @@ import com.alibaba.fastjson.JSONObject;
import com.yihu.wlyy.util.HttpClientUtil;
import org.apache.http.NameValuePair;
import org.apache.http.message.BasicNameValuePair;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.jdbc.core.JdbcTemplate;
@ -20,6 +22,7 @@ import java.util.Map;
@Service
public class JwPrescriptionService {
    private static final Logger logger = LoggerFactory.getLogger(JwPrescriptionService.class);
    //基卫服务地址
    @Value("${sign.check_upload}")
    private String jwUrl;
@ -115,6 +118,11 @@ public class JwPrescriptionService {
     * @throws Exception
     */
    public String saveRecipe(String prescriptionCode) throws Exception{
        try {
        }catch (Exception e){
        }
        String url = jwUrl + "/third/prescription/saveRecipe";
        List<NameValuePair> params = new ArrayList<>();
        params.add(new BasicNameValuePair("prescriptionCode", prescriptionCode));

+ 11 - 0
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/prescription/PrescriptionInfoController.java

@ -428,4 +428,15 @@ public class PrescriptionInfoController extends BaseController{
        }
    }
    @RequestMapping(value = "/getUsageDict" ,method = RequestMethod.GET)
    @ApiOperation(value = "获取药品用法列表")
    public String getUsageDict(){
        try {
            return write(200, "查询成功!", "data", prescriptionInfoService.getUsageDict());
        } catch (Exception e) {
            error(e);
            return error(-1, "查询失败!");
        }
    }
}