Procházet zdrojové kódy

二维码和导出vcf都修改为不存服务器目录

luojing před 5 roky
rodič
revize
497004fff0

+ 42 - 9
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/jaxrs/personcard/ActionCreateCode.java

@@ -1,11 +1,14 @@
 package com.x.organization.assemble.control.jaxrs.personcard;
 
+import java.awt.image.BufferedImage;
+import java.io.ByteArrayOutputStream;
 import java.io.File;
 import java.io.FileOutputStream;
 import java.io.OutputStream;
 import java.util.HashMap;
 import java.util.Map;
 
+import javax.imageio.ImageIO;
 import org.apache.commons.lang3.StringUtils;
 
 import com.google.zxing.BarcodeFormat;
@@ -16,8 +19,7 @@ import com.x.base.core.container.EntityManagerContainer;
 import com.x.base.core.container.factory.EntityManagerContainerFactory;
 import com.x.base.core.project.http.ActionResult;
 import com.x.base.core.project.http.EffectivePerson;
-import com.x.base.core.project.jaxrs.WoId;
-import com.x.organization.assemble.control.staticconfig.FollowConfig;
+import com.x.base.core.project.jaxrs.WoFile;
 import com.x.organization.core.entity.PersonCard;
 
 
@@ -27,16 +29,15 @@ class ActionCreateCode extends BaseAction {
 
 
 	//个人通讯录生成二维码。
-	ActionResult<String> qrcode(EffectivePerson effectivePerson, String flag) throws Exception {
+	ActionResult<Wo> qrcode(EffectivePerson effectivePerson, String flag) throws Exception {
 		try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {
-			ActionResult<String> result = new ActionResult<>();
+			ActionResult<Wo> result = new ActionResult<>();
 			PersonCard personCard = emc.find(flag, PersonCard.class);
 			if (null == personCard) {
 				throw new ExceptionPersonCardNotExist(flag);
 			}
 			
-			//String path = "D:\\tmp\\pilar111.png";
-			String path = FollowConfig.QRPATH+personCard.getId()+".png";
+			String fname = personCard.getId()+".png";
 			String content = "BEGIN:VCARD\n" +
 	        	    "VERSION:3.0\n" +
 	        	    "N:"+personCard.getName()+"\n";
@@ -71,8 +72,10 @@ class ActionCreateCode extends BaseAction {
 	        	    "URL:http://blog.csdn.net/lidew521\n" +
 	        	    "NOTE:呼呼测试下吧。。。\n" +
 	        	    "END:VCARD";*/
-			getBarCode(content,path);
-			result.setData(path);
+			//getBarCode(content,path);
+			
+			Wo wo = new Wo(getBarCodeWo(content), this.contentType(false, fname), this.contentDisposition(false, fname));
+			result.setData(wo);
 			return result;
 		}
 	}
@@ -101,8 +104,38 @@ class ActionCreateCode extends BaseAction {
 	            e.printStackTrace();
 	        }
 	}
+	
+	/**
+     *二维码实现
+     * @param msg /二维码包含的信息
+     */
+	public static byte[] getBarCodeWo(String msg){
+			byte[] bs = null;
+	        try {
+	            String format = "png";
+	            Map<EncodeHintType,String> map =new HashMap<EncodeHintType, String>();
+	            //设置编码 EncodeHintType类中可以设置MAX_SIZE, ERROR_CORRECTION,CHARACTER_SET,DATA_MATRIX_SHAPE,AZTEC_LAYERS等参数
+	            map.put(EncodeHintType.CHARACTER_SET,"UTF-8");
+	            map.put(EncodeHintType.MARGIN,"1");
+	            //生成二维码
+	            BitMatrix bitMatrix = new MultiFormatWriter().encode(msg, BarcodeFormat.QR_CODE,300,300,map);
+	            BufferedImage image = MatrixToImageWriter.toBufferedImage(bitMatrix);
+				ByteArrayOutputStream out = new ByteArrayOutputStream();
+				ImageIO.write(image, "gif", out);
+				bs = out.toByteArray();
+	            
+	        }catch (Exception e) {
+	            e.printStackTrace();
+	        }
+	        return bs;
+	}
 	 
-	public static class Wo extends WoId {
+	public static class Wo extends WoFile {
+
+		public Wo(byte[] bytes, String contentType, String contentDisposition) {
+			super(bytes, contentType, contentDisposition);
+		}
+
 	}
 
 }

+ 0 - 169
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/jaxrs/personcard/ActionExportPersonalVcf2.java

@@ -1,169 +0,0 @@
-package com.x.organization.assemble.control.jaxrs.personcard;
-
-import java.io.BufferedWriter;
-import java.io.ByteArrayOutputStream;
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.OutputStreamWriter;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.apache.commons.lang3.StringUtils;
-
-import com.google.gson.JsonElement;
-import com.x.base.core.container.EntityManagerContainer;
-import com.x.base.core.container.factory.EntityManagerContainerFactory;
-import com.x.base.core.project.annotation.FieldDescribe;
-import com.x.base.core.project.cache.ApplicationCache;
-import com.x.base.core.project.exception.ExceptionAccessDenied;
-import com.x.base.core.project.exception.ExceptionPersonNotExist;
-import com.x.base.core.project.gson.GsonPropertyObject;
-import com.x.base.core.project.http.ActionResult;
-import com.x.base.core.project.http.EffectivePerson;
-import com.x.base.core.project.jaxrs.WoFile;
-import com.x.base.core.project.jaxrs.WoId;
-import com.x.base.core.project.logger.Logger;
-import com.x.base.core.project.logger.LoggerFactory;
-import com.x.base.core.project.tools.StringTools;
-import com.x.organization.assemble.control.Business;
-import com.x.organization.assemble.control.staticconfig.FollowConfig;
-import com.x.organization.core.entity.PersonCard;
-
-import net.sf.ehcache.Element;
-
-
-
-class ActionExportPersonalVcf2 extends BaseAction {
-
-	private static Logger logger = LoggerFactory.getLogger(ActionExportPersonalVcf2.class);
-	//导出通讯录vcf
-	ActionResult<Wo> exportPersonalVcf(EffectivePerson effectivePerson, String idList) throws Exception {
-		try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {
-			ActionResult<Wo> result = new ActionResult<>();
-			Business business = new Business(emc);
-			/*Wi wi = this.convertToWrapIn(jsonElement, Wi.class);
-			List<String> personIdList = wi.getPersonList();*/
-			List<String> personIdList = Arrays.asList(idList.split(","));
-			Wo wo = null;
-			if(!personIdList.isEmpty()){
-				ByteArrayOutputStream os = new ByteArrayOutputStream();
-				
-				for (String flag : personIdList) {
-					PersonCard personCard = emc.find(flag, PersonCard.class);
-					if (null == personCard) {
-						throw new ExceptionPersonNotExist(flag);
-					}
-					os.write("BEGIN:VCARD".getBytes());
-					os.write("\r\n".getBytes());
-					os.write("VERSION:3.0".getBytes());
-					os.write("\r\n".getBytes());
-					os.write(("N:"+personCard.getName()+";;;;").getBytes());
-					os.write("\r\n".getBytes());
-					os.write(("FN:"+personCard.getName()).getBytes());
-					os.write("\r\n".getBytes());	    
-					if(personCard.getOfficePhone()!=null && !personCard.getOfficePhone().equals("")){
-						os.write(("TEL:"+personCard.getOfficePhone()).getBytes());
-						os.write(("\r\n").getBytes());
-					}
-					if(personCard.getMobile()!=null && !personCard.getMobile().equals("")){
-						os.write(("TEL;CELL:"+personCard.getMobile()).getBytes());
-						os.write("\r\n".getBytes());
-					}
-					if(personCard.getAddress()!=null && !personCard.getAddress().equals("")){
-						os.write(("ADR;HOME;POSTAL:;;"+personCard.getAddress()).getBytes());
-						os.write("\r\n".getBytes());
-					}
-					if(personCard.getGroupType()!=null && !personCard.getGroupType().equals("")){
-						os.write(("ORG:"+personCard.getGroupType()).getBytes());
-						os.write("\r\n".getBytes());
-					}
-					if(personCard.getDescription()!=null && !personCard.getDescription().equals("")){
-						os.write(("NOTE:"+personCard.getDescription()).getBytes());
-						os.write("\r\n".getBytes());
-					}									
-					os.write("END:VCARD".getBytes());
-					os.write("\r\n".getBytes());
-					
-				}
-				String fileName = "export_personal_contacts"+System.currentTimeMillis()+".txt";
-				/*VcfResultObject obj = new VcfResultObject();
-				obj.setBytes(os.toByteArray());
-				obj.setName(name);
-				String flagid = StringTools.uniqueToken();
-				business.cache().put(new Element(flagid, obj));
-				
-				//result = execute(effectivePerson,flagid);
-				String cacheKey = ApplicationCache.concreteCacheKey(flagid);
-				Element element = business.cache().get(cacheKey);
-				if (null != element && null != element.getObjectValue()) {
-					result.setData((Wo) element.getObjectValue());				
-				} else {
-					Wo wo = new Wo(obj.getBytes(), this.contentType(true, obj.getName()),
-							this.contentDisposition(true, obj.getName()));
-					business.cache().put(new Element(cacheKey, wo));
-					result.setData(wo); 
-				}*/
-				try {
-					wo = new Wo(os.toByteArray(), 
-							this.contentType(true, fileName), 
-							this.contentDisposition(true, fileName));
-				} finally {
-					os.close();
-				}
-				result.setData(wo);
-			}
-
-			return result;
-		}
-	}
-	
-	/*public static class Wi extends GsonPropertyObject {
-
-		@FieldDescribe("个人通讯录人员标识")
-		private List<String> personList = new ArrayList<>();
-
-		public List<String> getPersonList() {
-			return personList;
-		}
-
-		public void setPersonList(List<String> personList) {
-			this.personList = personList;
-		}
-
-	}*/
-	public static class VcfResultObject extends GsonPropertyObject {
-
-		private byte[] bytes;
-		private String name;
-		
-		public byte[] getBytes() {
-			return bytes;
-		}
-
-		public void setBytes(byte[] bytes) {
-			this.bytes = bytes;
-		}
-
-		public String getName() {
-			return name;
-		}
-
-		public void setName(String name) {
-			this.name = name;
-		}
-
-	}
-	public static class Wo extends WoFile {
-
-		public Wo(byte[] bytes, String contentType, String contentDisposition) {
-			super(bytes, contentType, contentDisposition);
-		}
-
-	}
-	/*public static class Wo extends WoId {
-		
-	}*/
-
-}

+ 30 - 11
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/jaxrs/personcard/ActionPersonCode.java

@@ -1,8 +1,13 @@
 package com.x.organization.assemble.control.jaxrs.personcard;
 
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
 import java.io.File;
 import java.util.List;
 
+import java.awt.image.BufferedImage;
+import javax.imageio.ImageIO;
+
 import javax.persistence.EntityManager;
 import javax.persistence.criteria.CriteriaBuilder;
 import javax.persistence.criteria.CriteriaQuery;
@@ -15,9 +20,11 @@ import com.x.base.core.project.exception.ExceptionEntityNotExist;
 import com.x.base.core.project.exception.ExceptionPersonNotExist;
 import com.x.base.core.project.http.ActionResult;
 import com.x.base.core.project.http.EffectivePerson;
+import com.x.base.core.project.jaxrs.WoFile;
 import com.x.base.core.project.jaxrs.WoId;
 import com.x.base.core.project.tools.DateTools;
 import com.x.organization.assemble.control.Business;
+import com.x.organization.assemble.control.jaxrs.personcard.ActionCreateCode.Wo;
 import com.x.organization.assemble.control.staticconfig.FollowConfig;
 import com.x.organization.core.entity.Identity;
 import com.x.organization.core.entity.Identity_;
@@ -26,25 +33,24 @@ import com.x.organization.core.entity.Unit;
 import com.x.organization.core.entity.UnitDuty;
 import com.x.organization.core.entity.UnitDuty_;
 
+import sun.misc.BASE64Decoder;
+
 
 
 
 class ActionPersonCode extends BaseAction {
 
 	//组织里管理_个人生成二维码。
-	ActionResult<String> personcode(EffectivePerson effectivePerson, String flag) throws Exception {
+	ActionResult<Wo> personcode(EffectivePerson effectivePerson, String flag) throws Exception {
 		try (EntityManagerContainer emc = EntityManagerContainerFactory.instance().create()) {
-			ActionResult<String> result = new ActionResult<>();
+			ActionResult<Wo> result = new ActionResult<>();
 			Business business = new Business(emc);
 			Person personCard = emc.find(flag, Person.class);
 			if (null == personCard) {
 				throw new ExceptionPersonNotExist(flag);
 			}
 			
-			//String path = "D:\\tmp\\pilar666.png";
-			//String logopath = "D:\\tmp\\pilar666_logo.png";
-			String path = FollowConfig.QRPATH+personCard.getId()+".png";
-			String logopath = FollowConfig.LOGOPATH+personCard.getId()+"_logo.png";
+			String fname = personCard.getId()+".png";
 			String content = "BEGIN:VCARD\n" +
 	        	    "VERSION:3.0\n" +
 	        	    "N:"+personCard.getName()+"\n";
@@ -105,19 +111,32 @@ class ActionPersonCode extends BaseAction {
 			}
 			 
 			content = content+"END:VCARD";
+			/*
 			File logoFile = null;
 			if(personCard.getIconMdpi()!=null && !personCard.getIconMdpi().equals("")){
 				logoFile = CodeUtil.decoderBase64File(logopath,personCard.getIconMdpi());
 			}
-			File QrCodeFile = new File(path);
-			CodeUtil.drawLogoQRCode(logoFile, QrCodeFile, content, "");
-			result.setData(path);
+			
+			 File QrCodeFile = new File(path);
+			CodeUtil.drawLogoQRCode(logoFile, QrCodeFile, content, "");*/
+			
+			BufferedImage logoFile = null;
+			ByteArrayOutputStream QrCodeFile = new ByteArrayOutputStream();
+			if(personCard.getIconMdpi()!=null && !personCard.getIconMdpi().equals("")){
+				byte[] buffer = new BASE64Decoder().decodeBuffer(personCard.getIconMdpi());  
+				ByteArrayInputStream in = new ByteArrayInputStream(buffer);    //将b作为输入流;
+				logoFile = ImageIO.read(in);     //将in作为输入流,读取图片存入image中,而这里in可以为ByteArrayInputStream();
+			}
+			Wo wo = new Wo(CodeUtil.drawLogoQRCodeByte(logoFile, QrCodeFile, content, ""), this.contentType(false, fname), this.contentDisposition(false, fname));
+			result.setData(wo);
 			return result;
 		}
 	}
 	 
-	public static class Wo extends WoId {
-		
+	public static class Wo extends WoFile {
+		public Wo(byte[] bytes, String contentType, String contentDisposition) {
+			super(bytes, contentType, contentDisposition);
+		}
 	}
 	
 	public List<Identity> referenceIdentity(Business business,String flag) throws Exception {

+ 83 - 0
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/jaxrs/personcard/CodeUtil.java

@@ -4,6 +4,7 @@ import java.awt.Color;
 import java.awt.Font;
 import java.awt.Graphics2D;
 import java.awt.image.BufferedImage;
+import java.io.ByteArrayOutputStream;
 import java.io.File;
 import java.io.FileOutputStream;
 import java.util.HashMap;
@@ -106,6 +107,88 @@ public class CodeUtil {
 	            e.printStackTrace();
 	        }
 	    }
+	    
+	    /**
+	     *生成带logo的二维码图片
+	     * @param logoFile /logo图片文件
+	     * @param codeFile /二维码图片
+	     * @param qrUrl /二维码存储的信息:vcard格式
+	     * @param note /二维码描述信息
+	     */
+	    public static byte[] drawLogoQRCodeByte(BufferedImage logo, ByteArrayOutputStream codeFile, String qrUrl, String note) {
+	    	byte[] bs = null;
+	        try {
+	            MultiFormatWriter multiFormatWriter = new MultiFormatWriter();
+	            // 参数顺序分别为:编码内容,编码类型,生成图片宽度,生成图片高度,设置参数
+	            BitMatrix bm = multiFormatWriter.encode(qrUrl, BarcodeFormat.QR_CODE, WIDTH, HEIGHT, hints);
+	            BufferedImage image = new BufferedImage(WIDTH, HEIGHT, BufferedImage.TYPE_INT_RGB);
+
+	            // 开始利用二维码数据创建Bitmap图片,分别设为黑(0xFFFFFFFF)白(0xFF000000)两色
+	            for (int x = 0; x < WIDTH; x++) {
+	                for (int y = 0; y < HEIGHT; y++) {
+	                    image.setRGB(x, y, bm.get(x, y) ? QRCOLOR : BGWHITE);
+	                }
+	            }
+
+	            int width = image.getWidth();
+	            int height = image.getHeight();
+	            if (Objects.nonNull(logo)) {
+	                // 构建绘图对象
+	                Graphics2D g = image.createGraphics();
+	                // 读取Logo图片
+	                //BufferedImage logo = ImageIO.read(logoFile);
+	                // 开始绘制logo图片
+	                g.drawImage(logo, width * 2 / 5, height * 2 / 5, width * 2 / 10, height * 2 / 10, null);
+	                g.dispose();
+	                logo.flush();
+	            }
+
+	            // 自定义文本描述
+	            if (StringUtils.isNotEmpty(note)) {
+	                // 新的图片,把带logo的二维码下面加上文字
+	                BufferedImage outImage = new BufferedImage(400, 445, BufferedImage.TYPE_4BYTE_ABGR);
+	                Graphics2D outg = outImage.createGraphics();
+	                // 画二维码到新的面板
+	                outg.drawImage(image, 0, 0, image.getWidth(), image.getHeight(), null);
+	                // 画文字到新的面板
+	                outg.setColor(Color.BLACK);
+	                outg.setFont(new Font("楷体", Font.BOLD, 30)); // 字体、字型、字号
+	                int strWidth = outg.getFontMetrics().stringWidth(note);
+	                if (strWidth > WIDTH) {
+	                    // //长度过长就截取前面部分
+	                    // 长度过长就换行
+	                    String note1 = note.substring(0, note.length() / 2);
+	                    String note2 = note.substring(note.length() / 2, note.length());
+	                    int strWidth1 = outg.getFontMetrics().stringWidth(note1);
+	                    int strWidth2 = outg.getFontMetrics().stringWidth(note2);
+	                    outg.drawString(note1, 200 - strWidth1 / 2, height + (outImage.getHeight() - height) / 2 + 12);
+	                    BufferedImage outImage2 = new BufferedImage(400, 485, BufferedImage.TYPE_4BYTE_ABGR);
+	                    Graphics2D outg2 = outImage2.createGraphics();
+	                    outg2.drawImage(outImage, 0, 0, outImage.getWidth(), outImage.getHeight(), null);
+	                    outg2.setColor(Color.BLACK);
+	                    outg2.setFont(new Font("宋体", Font.BOLD, 30)); // 字体、字型、字号
+	                    outg2.drawString(note2, 200 - strWidth2 / 2,outImage.getHeight() + (outImage2.getHeight() - outImage.getHeight()) / 2 + 5);
+	                    outg2.dispose();
+	                    outImage2.flush();
+	                    outImage = outImage2;
+	                } else {
+	                    outg.drawString(note, 200 - strWidth / 2, height + (outImage.getHeight() - height) / 2 + 12); // 画文字
+	                }
+	                outg.dispose();
+	                outImage.flush();
+	                image = outImage;
+	            }
+
+	            image.flush();
+
+	            ImageIO.write(image, "png", codeFile); // TODO
+	            bs = codeFile.toByteArray();
+	        } catch (Exception e) {
+	            e.printStackTrace();
+	        }
+	        return bs;
+	    }
+	    
 	    // 用于设置QR二维码参数
 	    private static Map<EncodeHintType, Object> hints = new HashMap<EncodeHintType, Object>() {
 	        private static final long serialVersionUID = 1L;

+ 2 - 4
o2server/x_organization_assemble_control/src/main/java/com/x/organization/assemble/control/jaxrs/personcard/PersonCardAction.java

@@ -181,11 +181,10 @@ public class PersonCardAction extends StandardJaxrsAction {
 	@JaxrsMethodDescribe(value = "个人通讯录生成二维码", action = ActionCreateCode.class) 
 	@GET
 	@Path("createQR/{cardId}")
-	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8) 
 	@Consumes(MediaType.APPLICATION_JSON)
 	public void code(@Suspended final AsyncResponse asyncResponse, @Context HttpServletRequest request,
 			@JaxrsParameterDescribe("名片id") @PathParam("cardId") String cardId) {
-		ActionResult<String> result = new ActionResult<>(); 
+		ActionResult<ActionCreateCode.Wo> result = new ActionResult<>(); 
 		EffectivePerson effectivePerson = this.effectivePerson(request);
 		try {
 			result = new ActionCreateCode().qrcode(effectivePerson, cardId);
@@ -199,11 +198,10 @@ public class PersonCardAction extends StandardJaxrsAction {
 	@JaxrsMethodDescribe(value = "组织人员生成二维码", action = ActionPersonCode.class) 
 	@GET
 	@Path("createCode/{cardId}")
-	@Produces(HttpMediaType.APPLICATION_JSON_UTF_8) 
 	@Consumes(MediaType.APPLICATION_JSON)
 	public void personcode(@Suspended final AsyncResponse asyncResponse, @Context HttpServletRequest request,
 			@JaxrsParameterDescribe("名片id") @PathParam("cardId") String cardId) {
-		ActionResult<String> result = new ActionResult<>(); 
+		ActionResult<ActionPersonCode.Wo> result = new ActionResult<>(); 
 		EffectivePerson effectivePerson = this.effectivePerson(request);
 		try {
 			result = new ActionPersonCode().personcode(effectivePerson, cardId);

+ 53 - 23
o2server/x_organization_assemble_control/src/main/webapp/describe/describe.json

@@ -8671,7 +8671,6 @@
           "type": "GET",
           "path": "jaxrs/personcard/createQR/{cardId}",
           "contentType": "application/json",
-          "resultContentType": "application/json; charset\u003dUTF-8",
           "useJsonElementParameter": false,
           "useStringParameter": false,
           "pathParameters": [
@@ -8686,10 +8685,22 @@
           "ins": [],
           "outs": [
             {
-              "name": "id",
+              "name": "contentDisposition",
               "type": "String",
               "isCollection": false,
-              "description": "id"
+              "description": "说明"
+            },
+            {
+              "name": "contentType",
+              "type": "String",
+              "isCollection": false,
+              "description": "类型"
+            },
+            {
+              "name": "bytes",
+              "type": "byte[]",
+              "isCollection": false,
+              "description": "字节内容."
             }
           ]
         },
@@ -8968,13 +8979,12 @@
           ]
         },
         {
-          "name": "listPersonalVCf2",
-          "className": "com.x.organization.assemble.control.jaxrs.personcard.ActionExportPersonalVcf2",
+          "name": "listPersonalVCf",
+          "className": "com.x.organization.assemble.control.jaxrs.personcard.ActionExportPersonalVcf",
           "description": "导出个人通讯录vcf",
           "type": "GET",
           "path": "jaxrs/personcard/listPersonalVCf/{idList}",
           "contentType": "application/json",
-          "resultContentType": "application/json; charset\u003dUTF-8",
           "useJsonElementParameter": false,
           "useStringParameter": false,
           "pathParameters": [
@@ -9012,30 +9022,39 @@
           "name": "listVCf",
           "className": "com.x.organization.assemble.control.jaxrs.personcard.ActionExportVcf",
           "description": "导出组织通讯录vcf",
-          "type": "POST",
-          "path": "jaxrs/personcard/listVCf",
+          "type": "GET",
+          "path": "jaxrs/personcard/listVCf/{idList}",
           "contentType": "application/json",
-          "resultContentType": "application/json; charset\u003dUTF-8",
           "useJsonElementParameter": false,
           "useStringParameter": false,
-          "pathParameters": [],
-          "formParameters": [],
-          "queryParameters": [],
-          "ins": [
+          "pathParameters": [
             {
-              "name": "personList",
-              "type": "List\u003cString\u003e",
-              "isCollection": true,
-              "description": "通讯录人员标识",
-              "isBaseType": true
+              "name": "idList",
+              "type": "String",
+              "description": "名片id组"
             }
           ],
+          "formParameters": [],
+          "queryParameters": [],
+          "ins": [],
           "outs": [
             {
-              "name": "id",
+              "name": "contentDisposition",
               "type": "String",
               "isCollection": false,
-              "description": "id"
+              "description": "说明"
+            },
+            {
+              "name": "contentType",
+              "type": "String",
+              "isCollection": false,
+              "description": "类型"
+            },
+            {
+              "name": "bytes",
+              "type": "byte[]",
+              "isCollection": false,
+              "description": "字节内容."
             }
           ]
         },
@@ -9177,7 +9196,6 @@
           "type": "GET",
           "path": "jaxrs/personcard/createCode/{cardId}",
           "contentType": "application/json",
-          "resultContentType": "application/json; charset\u003dUTF-8",
           "useJsonElementParameter": false,
           "useStringParameter": false,
           "pathParameters": [
@@ -9192,10 +9210,22 @@
           "ins": [],
           "outs": [
             {
-              "name": "id",
+              "name": "contentDisposition",
               "type": "String",
               "isCollection": false,
-              "description": "id"
+              "description": "说明"
+            },
+            {
+              "name": "contentType",
+              "type": "String",
+              "isCollection": false,
+              "description": "类型"
+            },
+            {
+              "name": "bytes",
+              "type": "byte[]",
+              "isCollection": false,
+              "description": "字节内容."
             }
           ]
         },