Browse Source

接口实例

luqingbin 3 years ago
parent
commit
bd8dbfcf3a

+ 2 - 1
src/main/java/com/github/yxyl120/sdk/DefaultYxClient.java

@@ -4,6 +4,7 @@ import com.fasterxml.jackson.core.JsonProcessingException;
 import com.fasterxml.jackson.databind.ObjectMapper;
 import com.github.yxyl120.sdk.Utils.CheckRequestUtils;
 import com.github.yxyl120.sdk.Utils.HttpUtils;
+import com.github.yxyl120.sdk.enums.ResponseCode;
 import com.github.yxyl120.sdk.request.YxRequest;
 import com.github.yxyl120.sdk.response.AbstractResponse;
 import org.springframework.util.DigestUtils;
@@ -47,7 +48,7 @@ public class DefaultYxClient implements YxClient {
         if (readValue == null) {
             throw new YxException("解析数据异常:" + responseBodyStr, 400);
         }
-        if (readValue.getCode() != SUCCESS_CODE) {
+        if (readValue.getCode() != ResponseCode.SUCCESS.getCode()) {
             throw new YxException(readValue.getMsg(), readValue.getCode());
         }
         return readValue;

+ 4 - 2
src/main/java/com/github/yxyl120/sdk/Utils/CheckRequestUtils.java

@@ -2,6 +2,7 @@ package com.github.yxyl120.sdk.Utils;
 
 import com.github.yxyl120.sdk.YxException;
 import com.github.yxyl120.sdk.annotation.ApiFieldProperty;
+import com.github.yxyl120.sdk.enums.ResponseCode;
 
 import java.lang.reflect.Field;
 import java.util.HashMap;
@@ -15,7 +16,7 @@ public class CheckRequestUtils {
 
     public static void doCheck(Object parameter,String ivKey,String ivOffset) throws YxException {
         if (parameter == null) {
-            throw new YxException("参数不能为空", 400);
+            throw new YxException("参数不能为空", ResponseCode.MissingParameter.getCode());
         }
         String className = parameter.getClass().getName();
         Map<Field, ApiFieldProperty> propertyMap = fieldPropertys.get(className);
@@ -39,7 +40,8 @@ public class CheckRequestUtils {
                 if (property.required()) {
                     Object value = key.get(parameter);
                     if (value == null || ("java.lang.String".equals(name) && isEmpty((String) value))) {
-                        throw new YxException("参数[" + key.getName() + "]不能为空,字段描述:" + property.value(), 400);
+                        throw new YxException("参数[" + key.getName() + "]不能为空,字段描述:" + property.value(),
+                                ResponseCode.MissingParameter.getCode());
                     }
                 }
                 // 需要使用属性加密的值

+ 0 - 1
src/main/java/com/github/yxyl120/sdk/YxClient.java

@@ -4,6 +4,5 @@ import com.github.yxyl120.sdk.request.YxRequest;
 import com.github.yxyl120.sdk.response.AbstractResponse;
 
 public interface YxClient {
-    int SUCCESS_CODE = 200;
     <T extends AbstractResponse> T execute(YxRequest<T> request) throws YxException;
 }

+ 9 - 0
src/main/java/com/github/yxyl120/sdk/domain/Chat.java

@@ -1,11 +1,20 @@
 package com.github.yxyl120.sdk.domain;
 
+import com.fasterxml.jackson.annotation.JsonIgnore;
+
 public class Chat {
 
     private int chatType;
 
     private String orderSn;
 
+    @JsonIgnore
+    private String api ="/api/open/sendTextChat";
+
+    @JsonIgnore
+    public String getApi() {
+        return api;
+    }
 
     public int getChatType() {
         return chatType;

+ 23 - 0
src/main/java/com/github/yxyl120/sdk/domain/LiveChat.java

@@ -0,0 +1,23 @@
+package com.github.yxyl120.sdk.domain;
+
+public class LiveChat extends Chat {
+
+    /**
+     * 发起的时间戳
+     */
+    private long timeStamp;
+
+    public LiveChat(String orderSn) {
+        this.timeStamp = System.currentTimeMillis();
+        this.setChatType(4);
+        this.setOrderSn(orderSn);
+    }
+
+    public long getTimeStamp() {
+        return timeStamp;
+    }
+
+    public void setTimeStamp(long timeStamp) {
+        this.timeStamp = timeStamp;
+    }
+}

+ 31 - 6
src/main/java/com/github/yxyl120/sdk/domain/PharmacistUser.java

@@ -15,9 +15,18 @@ public class PharmacistUser {
     private Serializable userIdThree;
 
     /**
-     * 用户名
+     * 用户
      */
-    private String userName;
+    private String name;
+    /**
+     * 用户在一线的账号
+     */
+    private String userAccount;
+
+    /**
+     * 用户在一线的账号密码
+     */
+    private String userPassword;
 
     /**
      * 状态,同步到一线平台后,需要等待审核通过才可以使用此用户信息
@@ -45,12 +54,28 @@ public class PharmacistUser {
         this.userIdThree = userIdThree;
     }
 
-    public String getUserName() {
-        return userName;
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getUserAccount() {
+        return userAccount;
+    }
+
+    public void setUserAccount(String userAccount) {
+        this.userAccount = userAccount;
+    }
+
+    public String getUserPassword() {
+        return userPassword;
     }
 
-    public void setUserName(String userName) {
-        this.userName = userName;
+    public void setUserPassword(String userPassword) {
+        this.userPassword = userPassword;
     }
 
     public int getStatus() {

+ 65 - 0
src/main/java/com/github/yxyl120/sdk/domain/RoomEvent.java

@@ -0,0 +1,65 @@
+package com.github.yxyl120.sdk.domain;
+
+import com.github.yxyl120.sdk.annotation.ApiFieldProperty;
+
+/**
+ * 回调到第三方的房间事件信息
+ */
+public class RoomEvent {
+
+
+    @ApiFieldProperty("关联的处方单号")
+    private String orderSn;
+
+    @ApiFieldProperty("回调时间,单位毫秒")
+    private Long callbackTs;
+
+    @ApiFieldProperty("数字房间号")
+    private Long roomId;
+
+    @ApiFieldProperty("房间事件码,LiveEventType.code")
+    private Integer eventCode;
+
+    @ApiFieldProperty("房间事件枚举,LiveEventType")
+    private String event;
+
+    public String getOrderSn() {
+        return orderSn;
+    }
+
+    public void setOrderSn(String orderSn) {
+        this.orderSn = orderSn;
+    }
+
+    public Long getCallbackTs() {
+        return callbackTs;
+    }
+
+    public void setCallbackTs(Long callbackTs) {
+        this.callbackTs = callbackTs;
+    }
+
+    public Long getRoomId() {
+        return roomId;
+    }
+
+    public void setRoomId(Long roomId) {
+        this.roomId = roomId;
+    }
+
+    public Integer getEventCode() {
+        return eventCode;
+    }
+
+    public void setEventCode(Integer eventCode) {
+        this.eventCode = eventCode;
+    }
+
+    public String getEvent() {
+        return event;
+    }
+
+    public void setEvent(String event) {
+        this.event = event;
+    }
+}

+ 116 - 0
src/main/java/com/github/yxyl120/sdk/domain/RoomInfo.java

@@ -0,0 +1,116 @@
+package com.github.yxyl120.sdk.domain;
+
+public class RoomInfo {
+    /**
+     * 房间关联的订单号
+     */
+    private String orderId;
+    /**
+     * 房间关联的处方号
+     */
+    private String orderSn;
+
+    /**
+     * 房间号
+     */
+    private Long roomId;
+    /**
+     * 用户id
+     */
+    private String userId;
+    /**
+     * 签名信息
+     */
+    private String sign;
+
+    /**
+     * 腾讯实时音视频appid
+     */
+    private Long trtcAppId;
+
+    /**
+     * 房间平台,暂时为固定值 TRTC
+     */
+    private String roomPlatform;
+    /**
+     * 房间平台描述,暂时为固定值 腾讯实时音视频
+     */
+    private String roomPlatformDesc;
+
+    public String getOrderId() {
+        return orderId;
+    }
+
+    public void setOrderId(String orderId) {
+        this.orderId = orderId;
+    }
+
+    public String getOrderSn() {
+        return orderSn;
+    }
+
+    public void setOrderSn(String orderSn) {
+        this.orderSn = orderSn;
+    }
+
+    public Long getRoomId() {
+        return roomId;
+    }
+
+    public void setRoomId(Long roomId) {
+        this.roomId = roomId;
+    }
+
+    public String getUserId() {
+        return userId;
+    }
+
+    public void setUserId(String userId) {
+        this.userId = userId;
+    }
+
+    public String getSign() {
+        return sign;
+    }
+
+    public void setSign(String sign) {
+        this.sign = sign;
+    }
+
+    public Long getTrtcAppId() {
+        return trtcAppId;
+    }
+
+    public void setTrtcAppId(Long trtcAppId) {
+        this.trtcAppId = trtcAppId;
+    }
+
+    public String getRoomPlatform() {
+        return roomPlatform;
+    }
+
+    public void setRoomPlatform(String roomPlatform) {
+        this.roomPlatform = roomPlatform;
+    }
+
+    public String getRoomPlatformDesc() {
+        return roomPlatformDesc;
+    }
+
+    public void setRoomPlatformDesc(String roomPlatformDesc) {
+        this.roomPlatformDesc = roomPlatformDesc;
+    }
+
+    @Override
+    public String toString() {
+        return "RoomInfo{" +
+                "orderId='" + orderId + '\'' +
+                ", orderSn='" + orderSn + '\'' +
+                ", roomId=" + roomId +
+                ", userId='" + userId + '\'' +
+                ", sign='" + sign + '\'' +
+                ", roomPlatform='" + roomPlatform + '\'' +
+                ", roomPlatformDesc='" + roomPlatformDesc + '\'' +
+                '}';
+    }
+}

+ 27 - 0
src/main/java/com/github/yxyl120/sdk/enums/LiveEventType.java

@@ -0,0 +1,27 @@
+package com.github.yxyl120.sdk.enums;
+
+/**
+ * 房间事件枚举
+ */
+public enum LiveEventType {
+
+    EVENT_TYPE_CREATE_ROOM(101, "创建房间"),
+    EVENT_TYPE_DISMISS_ROOM(102, "解散房间"),
+    EVENT_TYPE_ENTER_ROOM(103, "进入房间"),
+    EVENT_TYPE_EXIT_ROOM(104, "退出房间");
+    private int code;
+    private String desc;
+
+    LiveEventType(int code, String desc) {
+        this.code = code;
+        this.desc = desc;
+    }
+
+    public int getCode() {
+        return code;
+    }
+
+    public String getDesc() {
+        return desc;
+    }
+}

+ 2 - 7
src/main/java/com/github/yxyl120/sdk/request/SendImageChatRequest.java → src/main/java/com/github/yxyl120/sdk/request/ImageChatRequest.java

@@ -8,17 +8,12 @@ import java.util.Map;
 /**
  * 发送图片消息到医生
  */
-public class SendImageChatRequest extends ImageChat implements YxRequest<EmptyResponse> {
+public class ImageChatRequest extends ImageChat implements YxRequest<EmptyResponse> {
 
-    public SendImageChatRequest(String orderSn, String imgUrl) {
+    public ImageChatRequest(String orderSn, String imgUrl) {
         super(orderSn, imgUrl);
     }
 
-    @Override
-    public String getApi() {
-        return "/api/open/sendTextChat";
-    }
-
     @Override
     public Map<String, Object> getQueryParam() {
         return null;

+ 27 - 0
src/main/java/com/github/yxyl120/sdk/request/LiveChatRequest.java

@@ -0,0 +1,27 @@
+package com.github.yxyl120.sdk.request;
+
+import com.github.yxyl120.sdk.domain.LiveChat;
+import com.github.yxyl120.sdk.response.EmptyResponse;
+
+import java.util.Map;
+
+/**
+ * 发起视频聊天
+ */
+public class LiveChatRequest extends LiveChat implements YxRequest<EmptyResponse>{
+
+    public LiveChatRequest(String orderSn) {
+        super(orderSn);
+    }
+
+    @Override
+    public Map<String, Object> getQueryParam() {
+        return null;
+    }
+
+    @Override
+    public Class<EmptyResponse> getResponseClass() {
+        return EmptyResponse.class;
+    }
+
+}

+ 45 - 1
src/main/java/com/github/yxyl120/sdk/request/PushOrderRequest.java

@@ -80,7 +80,7 @@ public class PushOrderRequest implements YxRequest<PushOrderResponse>{
     /**
      * 凭证图片 URL json格式 ["http://1.jpg", "http://2.jpg"]
      */
-    @ApiFieldProperty("凭证图片 URL Array格式 [\"1.jpg\", \"2.jpg\"]")
+    @ApiFieldProperty("凭证图片 URL Array格式 [\"http://1.jpg\", \"http://2.jpg\"]")
     private List<String> voucherImg;
 
     /**
@@ -89,6 +89,18 @@ public class PushOrderRequest implements YxRequest<PushOrderResponse>{
     @ApiFieldProperty("是否需要CA电子签名pdf文件,此功能需要药店相关的药师先进行电子签章注册并授权")
     private Integer signPDF;
 
+    @ApiFieldProperty("药师id使用模式:0-匹配模式,id不存在时将以一线平台药师代替,1-严格模式,id不可用时将提交失败")
+    private Integer pharmacistModel;
+
+    @ApiFieldProperty("在一线平台注册的审核药师id")
+    private Integer pharmacistId;
+
+    @ApiFieldProperty("在一线平台注册的配药药师id")
+    private Integer deploymentPharmacistId;
+
+    @ApiFieldProperty("在一线平台注册的发药药师id")
+    private Integer dispensingPharmacistId;
+
     /**
      * 创建时间
      */
@@ -216,6 +228,38 @@ public class PushOrderRequest implements YxRequest<PushOrderResponse>{
         this.signPDF = signPDF;
     }
 
+    public Integer getPharmacistModel() {
+        return pharmacistModel;
+    }
+
+    public void setPharmacistModel(Integer pharmacistModel) {
+        this.pharmacistModel = pharmacistModel;
+    }
+
+    public Integer getPharmacistId() {
+        return pharmacistId;
+    }
+
+    public void setPharmacistId(Integer pharmacistId) {
+        this.pharmacistId = pharmacistId;
+    }
+
+    public Integer getDeploymentPharmacistId() {
+        return deploymentPharmacistId;
+    }
+
+    public void setDeploymentPharmacistId(Integer deploymentPharmacistId) {
+        this.deploymentPharmacistId = deploymentPharmacistId;
+    }
+
+    public Integer getDispensingPharmacistId() {
+        return dispensingPharmacistId;
+    }
+
+    public void setDispensingPharmacistId(Integer dispensingPharmacistId) {
+        this.dispensingPharmacistId = dispensingPharmacistId;
+    }
+
     public Date getCreateTime() {
         return createTime;
     }

+ 5 - 3
src/main/java/com/github/yxyl120/sdk/request/SyncPharmacistInfoRequest.java

@@ -3,6 +3,8 @@ package com.github.yxyl120.sdk.request;
 import com.github.yxyl120.sdk.annotation.ApiFieldProperty;
 import com.github.yxyl120.sdk.response.SyncPharmacistResponse;
 
+import java.io.Serializable;
+
 /**
  * 同步药师到一线
  */
@@ -12,7 +14,7 @@ public class SyncPharmacistInfoRequest extends AbsRequest implements YxRequest<S
      * 合作方的药师id
      */
     @ApiFieldProperty(value = "合作方的药师id", required = true)
-    private String pharmacistId;
+    private Serializable pharmacistId;
 
     @ApiFieldProperty(value = "药师真实姓名", required = true)
     private String pharmacistName;
@@ -59,11 +61,11 @@ public class SyncPharmacistInfoRequest extends AbsRequest implements YxRequest<S
     }
 
 
-    public String getPharmacistId() {
+    public Serializable getPharmacistId() {
         return pharmacistId;
     }
 
-    public void setPharmacistId(String pharmacistId) {
+    public void setPharmacistId(Serializable pharmacistId) {
         this.pharmacistId = pharmacistId;
     }
 

+ 22 - 4
src/main/java/com/github/yxyl120/sdk/request/SyncPharmacistStatusRequest.java

@@ -3,17 +3,27 @@ package com.github.yxyl120.sdk.request;
 import com.github.yxyl120.sdk.annotation.ApiFieldProperty;
 import com.github.yxyl120.sdk.response.SyncPharmacistResponse;
 
+import java.io.Serializable;
+
 /**
  * 同步药师账号状态到一线
  */
 public class SyncPharmacistStatusRequest extends AbsRequest implements YxRequest<SyncPharmacistResponse> {
 
-    @ApiFieldProperty(value = "一线的药师id", required = true)
-    private String pharmacistId;
+    @ApiFieldProperty(value = "一线平台的用户id", required = true)
+    private Serializable pharmacistId;
 
     @ApiFieldProperty(value = "药师账号状态:0 注销 | 1 启用", required = true)
     private Integer status;
 
+    public SyncPharmacistStatusRequest() {
+    }
+
+    public SyncPharmacistStatusRequest(Serializable pharmacistId, Integer status) {
+        this.pharmacistId = pharmacistId;
+        this.status = status;
+    }
+
     @Override
     public String getApi() {
         return "/api/open/syncPharmacist";
@@ -24,11 +34,19 @@ public class SyncPharmacistStatusRequest extends AbsRequest implements YxRequest
         return SyncPharmacistResponse.class;
     }
 
-    public String getPharmacistId() {
+    public Serializable getPharmacistId() {
         return pharmacistId;
     }
 
-    public void setPharmacistId(String pharmacistId) {
+    public void setPharmacistId(Serializable pharmacistId) {
         this.pharmacistId = pharmacistId;
     }
+
+    public Integer getStatus() {
+        return status;
+    }
+
+    public void setStatus(Integer status) {
+        this.status = status;
+    }
 }

+ 2 - 7
src/main/java/com/github/yxyl120/sdk/request/SendTextChatRequest.java → src/main/java/com/github/yxyl120/sdk/request/TextChatRequest.java

@@ -5,17 +5,12 @@ import com.github.yxyl120.sdk.response.EmptyResponse;
 
 import java.util.Map;
 
-public class SendTextChatRequest extends TextChat implements YxRequest<EmptyResponse>{
+public class TextChatRequest extends TextChat implements YxRequest<EmptyResponse>{
 
-    public SendTextChatRequest(String orderSn, String content) {
+    public TextChatRequest(String orderSn, String content) {
         super(orderSn, content);
     }
 
-    @Override
-    public String getApi() {
-        return "/api/open/sendTextChat";
-    }
-
     @Override
     public Map<String, Object> getQueryParam() {
         return null;

+ 7 - 0
src/main/java/com/github/yxyl120/sdk/response/AbstractResponse.java

@@ -1,14 +1,21 @@
 package com.github.yxyl120.sdk.response;
 
 import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
+import com.github.yxyl120.sdk.enums.ResponseCode;
 
 import java.io.Serializable;
 
 @JsonIgnoreProperties(ignoreUnknown = true)
 public class AbstractResponse implements Serializable {
 
+    /**
+     * 响应编码{@link ResponseCode#getCode()}
+     */
     protected int code;
 
+    /**
+     * 响应描述
+     */
     protected String msg;
 
     public int getCode() {

+ 15 - 1
src/main/java/com/github/yxyl120/sdk/response/PushOrderResponse.java

@@ -1,11 +1,25 @@
 package com.github.yxyl120.sdk.response;
 
+import com.github.yxyl120.sdk.domain.RoomInfo;
+
 public class PushOrderResponse extends AbstractResponse {
+
+    private RoomInfo data;
+
     @Override
     public String toString() {
         return "PushOrderResponse{" +
-                "code=" + code +
+                "data=" + data +
+                ", code=" + code +
                 ", msg='" + msg + '\'' +
                 '}';
     }
+
+    public RoomInfo getData() {
+        return data;
+    }
+
+    public void setData(RoomInfo data) {
+        this.data = data;
+    }
 }

+ 88 - 5
src/test/java/APITest.java

@@ -1,32 +1,49 @@
 import com.github.yxyl120.sdk.DefaultYxClient;
+import com.github.yxyl120.sdk.YxClient;
 import com.github.yxyl120.sdk.YxException;
 import com.github.yxyl120.sdk.domain.DrugInfo;
 import com.github.yxyl120.sdk.domain.PatientInfo;
-import com.github.yxyl120.sdk.request.PushOrderRequest;
+import com.github.yxyl120.sdk.domain.RoomInfo;
+import com.github.yxyl120.sdk.request.*;
+import com.github.yxyl120.sdk.response.EmptyResponse;
 import com.github.yxyl120.sdk.response.PushOrderResponse;
+import com.github.yxyl120.sdk.response.SyncPharmacistResponse;
 
 import java.util.Collections;
 import java.util.Date;
 
 public class APITest {
 
-    public static void main(String[] args) throws YxException {
+    private YxClient yxClient;
 
+    public APITest() {
         String serverUrl = "http://localhost:8515";
+        String appId = "440004901";
         String secret = "DB957E8E2F41AB28B65840BD47A76AF2";
+        yxClient = new DefaultYxClient(serverUrl, appId, secret);
+    }
+
+    public static void main(String[] args) throws YxException {
+        new APITest().pushOrderTest();
+    }
 
-        DefaultYxClient yxClient = new DefaultYxClient(serverUrl, "440004901", secret);
+    /**
+     * 推送一张视频单或图文单
+     */
+    private void pushOrderTest() {
         PushOrderRequest orderRequest = new PushOrderRequest();
 
         orderRequest.setOrderIdThird("C2021232657");
         orderRequest.setDiagnosisSnThird("C2021232657");
         orderRequest.setStoreName("一线大药房");
         orderRequest.setCreateTime(new Date());
+        // 1图文 2为视频
         orderRequest.setType(2);
+
         PatientInfo patientInfo = new PatientInfo();
         orderRequest.setPatientInfo(patientInfo);
         patientInfo.setName("张三");
-        patientInfo.setAge(80);
+        patientInfo.setAge(1);
         patientInfo.setSex(1);
         patientInfo.setKidney(0);
         patientInfo.setLiver(0);
@@ -35,7 +52,7 @@ public class APITest {
         patientInfo.setBirthday("2021-12-29");
 
         patientInfo.setMainSuit("咳嗽");
-        patientInfo.setAllergyDesc("");
+        patientInfo.setAllergyDesc("");
 
         DrugInfo drugInfo = new DrugInfo();
         drugInfo.setDrugIdThird(669);
@@ -43,12 +60,78 @@ public class APITest {
         drugInfo.setDrugSpecification("0.1g*12片*2板");
         drugInfo.setSaleAmount(3);
         drugInfo.setSaleUnit("盒");
+        drugInfo.setInstructions("药品说明书");
 
         orderRequest.setDrugList(Collections.singletonList(drugInfo));
         orderRequest.setRpType("01");
 
         PushOrderResponse response = yxClient.execute(orderRequest);
         System.out.println(response);
+        // 房间进行视频通话的相关的信息
+        RoomInfo data = response.getData();
+    }
+
+    /**
+     * 根据处方号发送文本消息
+     */
+    private void sendTextMsg() {
+        TextChatRequest request = new TextChatRequest("C2201121686180076", "医生你好");
+        EmptyResponse response = yxClient.execute(request);
+        // 后续需要合作方的接口等待接收回调
+    }
 
+    /**
+     * 根据处方号发送图片消息
+     */
+    private void sendImageMsg() {
+        ImageChatRequest request = new ImageChatRequest("C2201121686180076",
+                "https://asset.nxk520.com/abc.png");
+        request.setImgWidth(60);
+        request.setImgHeight(110);
+        EmptyResponse response = yxClient.execute(request);
+        // 后续需要合作方的接口等待接收回调
     }
+
+    /**
+     * 根据处方号发起视频聊天
+     */
+    private void sendLiveMsg() {
+        LiveChatRequest request = new LiveChatRequest("C2201121686180076");
+        EmptyResponse response = yxClient.execute(request);
+        // 后续需要合作方的接口等待接收回调
+    }
+
+    /**
+     * 同步药师资料到一线
+     */
+    private void syncPharmacistInfoTest() {
+        SyncPharmacistInfoRequest request = new SyncPharmacistInfoRequest();
+        request.setPharmacistId(764);
+        request.setPharmacistName("张三");
+        request.setSex(1);
+        request.setRole(2);
+        request.setMobile("16666666666");
+        request.setIdNumber("632323190605260586");
+        request.setAvatar("https://asset.nxk520.com/abc.png");
+        request.setIdFrontImg("https://asset.nxk520.com/abc.png");
+        request.setIdEmblemImg("https://asset.nxk520.com/abc.png");
+        request.setCertificateImg("https://asset.nxk520.com/abc.png");
+        request.setPractitionerCertificateImg("https://asset.nxk520.com/abc.png");
+        request.setIntroduction("药师简介……");
+        SyncPharmacistResponse response = yxClient.execute(request);
+    }
+
+    /**
+     * 注销药师,或启用药师
+     */
+    private void SyncPharmacistStatusTest(){
+
+//        SyncPharmacistStatusRequest request = new SyncPharmacistStatusRequest();
+//        request.setPharmacistId(764);
+//        request.setStatus(0);
+        SyncPharmacistStatusRequest request = new SyncPharmacistStatusRequest(764,0);
+        SyncPharmacistResponse response = yxClient.execute(request);
+    }
+
+
 }