Browse Source

Merge branch 'dev' of liuwenbin/patient-co-management into dev

trick9191 7 years ago
parent
commit
1c258569ed

+ 2 - 3
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/controller/PrescriptionController.java

@ -218,11 +218,10 @@ public class PrescriptionController extends BaseController{
	@ApiOperation("请求实名软证书并进行数字签名")
	public Result requestRealNameSoftCertAndSign(@ApiParam(name="strUserIdcardNum",value="用户身份证号") @RequestParam String strUserIdcardNum,
												 @ApiParam(name="strRealNameSoftCertCalledPasswd",value="证书被调用保护口令") @RequestParam String strRealNameSoftCertCalledPasswd,
												 @ApiParam(name="strOriginalData",value="原文(若原文大于 1KB,需先对原文取 MD5摘要值,而后以该 MD5摘要值入参)") @RequestParam String strOriginalData,
												 @ApiParam(name="srcBusinessStreamNO",value="本次请求的业务流水号,用于与业务系统关联") @RequestParam String srcBusinessStreamNO)
												 @ApiParam(name="strOriginalData",value="原文(若原文大于 1KB,需先对原文取 MD5摘要值,而后以该 MD5摘要值入参)") @RequestParam String strOriginalData)
	{
		try {
			String re = caService.requestRealNameSoftCertAndSign(strUserIdcardNum,strRealNameSoftCertCalledPasswd,strOriginalData,srcBusinessStreamNO);
			String re = caService.requestRealNameSoftCertAndSign(strUserIdcardNum,strRealNameSoftCertCalledPasswd,strOriginalData);
			return Result.success("请求实名软证书并进行数字签名成功!",re);
		} catch (Exception ex) {

+ 2 - 2
patient-co-service/wlyy_service/src/main/java/com/yihu/wlyy/service/service/prescription/PrescriptionCAService.java

@ -130,7 +130,7 @@ public class PrescriptionCAService {
    /**
     * 请求实名软证书并进行数字签名
     **/
    public String requestRealNameSoftCertAndSign(String strUserIdcardNum,String strRealNameSoftCertCalledPasswd,String strOriginalData,String srcBusinessStreamNO) throws Exception
    public String requestRealNameSoftCertAndSign(String strUserIdcardNum,String strRealNameSoftCertCalledPasswd,String strOriginalData) throws Exception
    {
        Boolean isSuccess = true;
        String re = "";
@ -142,7 +142,7 @@ public class PrescriptionCAService {
            params.put("strUserIdcardNum",strUserIdcardNum);
            params.put("strRealNameSoftCertCalledPasswd",strRealNameSoftCertCalledPasswd);
            params.put("strOriginalData",strOriginalData);
            params.put("srcBusinessStreamNO",srcBusinessStreamNO);
//            params.put("srcBusinessStreamNO",srcBusinessStreamNO);
            body = objectMapper.writeValueAsString(params);

+ 11 - 9
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/account/DoctorController.java

@ -25,6 +25,7 @@ import com.yihu.wlyy.service.common.account.RoleService;
import com.yihu.wlyy.util.*;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import io.swagger.models.auth.In;
import org.apache.commons.lang3.StringUtils;
import org.apache.http.NameValuePair;
@ -1953,9 +1954,9 @@ public class DoctorController extends BaseController {
    @ResponseBody
    @RequestMapping(value = "/requestRealNameSoftCertAndSign", method = RequestMethod.POST)
    public String requestRealNameSoftCertAndSign(
            @RequestParam(value = "strRealNameSoftCertCalledPasswd",required = true) String strRealNameSoftCertCalledPasswd,
            @RequestParam(value = "strOriginalData",required = true) String strOriginalData,
            @RequestParam(value = "prescriptionCode",required = true) String prescriptionCode){
            @ApiParam(required = true, name = "strRealNameSoftCertCalledPasswd", value = "证书被调用保护口令") @RequestParam(value = "strRealNameSoftCertCalledPasswd",required = true) String strRealNameSoftCertCalledPasswd,
            @ApiParam(required = true, name = "strOriginalData", value = "原文") @RequestParam(value = "strOriginalData",required = true) String strOriginalData,
            @ApiParam(required = true, name = "prescriptionCode", value = "处方code") @RequestParam(value = "prescriptionCode",required = true) String prescriptionCode){
        try {
            Doctor doctor = doctorInfoService.findDoctorByCode(getRepUID());
@ -1978,7 +1979,8 @@ public class DoctorController extends BaseController {
    @ObserverRequired
    @ResponseBody
    @RequestMapping(value = "/checkCertificate", method = RequestMethod.GET)
    public String checkCertificate(@RequestParam(value = "certificateNum",required = true) String certificateNum){
    public String checkCertificate(
            @ApiParam(required = true, name = "certificateNum", value = "证书编号") @RequestParam(value = "certificateNum",required = true) String certificateNum){
        try {
            boolean b = doctorInfoService.checkCertificate("0de6a26a62dd11e69faffa163e8aee56",certificateNum);
@ -1997,13 +1999,13 @@ public class DoctorController extends BaseController {
    @ResponseBody
    @RequestMapping(value = "/verifySignOnMultiServer", method = RequestMethod.GET)
    public String verifySignOnMultiServer(
            @RequestParam(value = "strSignData",required = true) String strSignData,
            @RequestParam(value = "strCertData",required = true) String strCertData,
            @RequestParam(value = "strOriginalData",required = true) String strOriginalData){
            @ApiParam(required = true, name = "strSignData", value = "签名值") @RequestParam(value = "strSignData",required = true) String strSignData,
            @ApiParam(required = true, name = "strCertData", value = "证书主体数据") @RequestParam(value = "strCertData",required = true) String strCertData,
            @ApiParam(required = true, name = "strOriginalData", value = "原文数据") @RequestParam(value = "strOriginalData",required = true) String strOriginalData){
            try {
                boolean b = doctorInfoService.verifySignOnMultiServer(strSignData,strCertData,strOriginalData);
                return write(200, "获取信息成功!", "data", b);
                boolean bl = doctorInfoService.verifySignOnMultiServer(strSignData,strCertData,strOriginalData);
                return write(200, "获取信息成功!", "data", bl);
            }catch (Exception e) {
                error(e);
                return error(-1, e.getMessage());

+ 4 - 2
patient-co/patient-co-wlyy/src/main/java/com/yihu/wlyy/web/doctor/prescription/PrescriptionCodeController.java

@ -119,7 +119,8 @@ public class PrescriptionCodeController extends BaseController{
    @RequestMapping(value = "/dispensaryCode/getDoctorDispensaryQrcode", method = RequestMethod.GET)
    @ObserverRequired
    @ApiOperation("医生端获取取药码")
    public String getDoctorDispensaryQrcode(@RequestParam(value = "prescriptionCode", required = true) String prescriptionCode) {
    public String getDoctorDispensaryQrcode(
            @ApiParam(required = true, name = "prescriptionCode", value = "处方code") @RequestParam(value = "prescriptionCode", required = true) String prescriptionCode) {
        try{
            Map<String, Object> map = prescriptionDispensaryCodeService.getQrcode(prescriptionCode,getRepUID(),2);
@ -140,7 +141,8 @@ public class PrescriptionCodeController extends BaseController{
    @RequestMapping(value = "/dispensaryCode/getDoctorDeliveryQrcode", method = RequestMethod.GET)
    @ObserverRequired
    @ApiOperation("医生端获取配送码")
    public String getDoctorDeliveryQrcode(@RequestParam(value = "prescriptionCode", required = true) String prescriptionCode) {
    public String getDoctorDeliveryQrcode(
            @ApiParam(required = true, name = "prescriptionCode", value = "处方code") @RequestParam(value = "prescriptionCode", required = true) String prescriptionCode) {
        try{
            Map<String, Object> map = prescriptionDispensaryCodeService.getQrcode(prescriptionCode,getRepUID(),3);