| 
					
				 | 
			
			
				@ -24,6 +24,7 @@ import com.yihu.ehr.model.org.MOrganization; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import com.yihu.ehr.model.profile.MTemplate; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import com.yihu.ehr.model.security.MKey; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import com.yihu.ehr.model.user.MUser; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import com.yihu.ehr.organization.model.KeyModel; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import com.yihu.ehr.organization.service.OrganizationClient; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import com.yihu.ehr.redis.client.RedisUpdateClient; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import com.yihu.ehr.security.service.SecurityClient; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -37,6 +38,7 @@ import io.swagger.annotations.Api; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import io.swagger.annotations.ApiOperation; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import io.swagger.annotations.ApiParam; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.apache.commons.lang.StringUtils; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.beans.BeanUtils; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.beans.factory.annotation.Autowired; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.beans.factory.annotation.Value; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				import org.springframework.http.ResponseEntity; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@ -837,4 +839,17 @@ public class OrganizationController extends BaseController { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        List<Map<String, Object>> listMap = orgClient.getOrgListTreeByAddressPid(pid); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        return listMap; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    @RequestMapping(value = "/{org_code}/key", method = RequestMethod.GET) 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    @ApiOperation(value = "获取机构公钥", notes = "机构公钥") 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    public KeyModel getPublicKey( 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            @ApiParam(name = "org_code", value = "机构代码") 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				            @PathVariable(value = "org_code") 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                    String orgCode) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        MKey key = securityClient.getOrgKey(orgCode); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        KeyModel model = new KeyModel(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        BeanUtils.copyProperties(key, model, "privateKey","fromDate","expiryDate"); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				        return model; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				    } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				} 
			 |