主要完善了注释
This commit is contained in:
@@ -207,7 +207,7 @@ public class WeixinProxy {
|
||||
}
|
||||
|
||||
/**
|
||||
* 发送客服消息(需要管理员对应用有使用权限,对收件人touser、toparty、totag有查看权限,否则本次调用失败)
|
||||
* 发送消息提醒(需要管理员对应用有使用权限,对收件人touser、toparty、totag有查看权限,否则本次调用失败)
|
||||
* <p>
|
||||
* 1) 发送人员列表存在错误的userid:执行发送,开发者需注意返回结果说明</br>
|
||||
* 2)发送人员不在通讯录权限范围内:不执行发送任务,返回首个出错的userid</br>
|
||||
@@ -215,7 +215,7 @@ public class WeixinProxy {
|
||||
* </p>
|
||||
*
|
||||
* @param message
|
||||
* 客服消息对象
|
||||
* 消息对象
|
||||
* @return 如果对应用或收件人、部门、标签任何一个无权限,则本次发送失败;如果收件人、部门或标签不存在,发送仍然执行,但返回无效的部分
|
||||
* </br> { "errcode": 0, "errmsg": "ok", "invaliduser": "UserID1",
|
||||
* "invalidparty":"PartyID1", "invalidtag":"TagID1" }
|
||||
@@ -245,7 +245,7 @@ public class WeixinProxy {
|
||||
* 发送客服消息
|
||||
*
|
||||
* @param message
|
||||
* 客服消息对象
|
||||
* 消息对象
|
||||
* @return 发送结果
|
||||
* @see <a href=
|
||||
* "http://qydev.weixin.qq.com/wiki/index.php?title=%E4%BC%81%E4%B8%9A%E5%AE%A2%E6%9C%8D%E6%8E%A5%E5%8F%A3%E8%AF%B4%E6%98%8E">
|
||||
|
||||
@@ -47,7 +47,7 @@ public class NotifyApi extends QyApi {
|
||||
}
|
||||
|
||||
/**
|
||||
* 发送消息(需要管理员对应用有使用权限,对收件人touser、toparty、totag有查看权限,否则本次调用失败)
|
||||
* 发送消息提醒(需要管理员对应用有使用权限,对收件人touser、toparty、totag有查看权限,否则本次调用失败)
|
||||
* <p>
|
||||
* 1) 发送人员列表存在错误的userid:执行发送,开发者需注意返回结果说明</br>
|
||||
* 2)发送人员不在通讯录权限范围内:不执行发送任务,返回首个出错的userid</br>
|
||||
@@ -55,7 +55,7 @@ public class NotifyApi extends QyApi {
|
||||
* </p>
|
||||
*
|
||||
* @param message
|
||||
* 普通消息对象
|
||||
* 消息对象
|
||||
* @return 如果无权限,则本次发送失败;如果收件人不存在或未关注,发送仍然执行。两种情况下均返回无效的部分</br> { "errcode":
|
||||
* 0, "errmsg": "ok", "invaliduser": "UserID1",
|
||||
* "invalidparty":"PartyID1", "invalidtag":"TagID1" }
|
||||
@@ -126,7 +126,7 @@ public class NotifyApi extends QyApi {
|
||||
* 发送客服消息
|
||||
*
|
||||
* @param message
|
||||
* 客服消息对象
|
||||
* 消息对象
|
||||
* @return 发送结果
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E4%BC%81%E4%B8%9A%E5%AE%A2%E6%9C%8D%E6%8E%A5%E5%8F%A3%E8%AF%B4%E6%98%8E">客服接口说明</a>
|
||||
|
||||
@@ -20,8 +20,8 @@ import com.foxinmy.weixin4j.tuple.NotifyTuple;
|
||||
* @see com.foxinmy.weixin4j.tuple.File
|
||||
* @see com.foxinmy.weixin4j.tuple.News
|
||||
* @see com.foxinmy.weixin4j.tuple.MpNews
|
||||
* @see <a
|
||||
* href="http://qydev.weixin.qq.com/wiki/index.php?title=%E6%B6%88%E6%81%AF%E7%B1%BB%E5%9E%8B%E5%8F%8A%E6%95%B0%E6%8D%AE%E6%A0%BC%E5%BC%8F">消息说明</a>
|
||||
* @see <a href=
|
||||
* "http://qydev.weixin.qq.com/wiki/index.php?title=%E6%B6%88%E6%81%AF%E7%B1%BB%E5%9E%8B%E5%8F%8A%E6%95%B0%E6%8D%AE%E6%A0%BC%E5%BC%8F">消息说明</a>
|
||||
*/
|
||||
public class NotifyMessage implements Serializable {
|
||||
|
||||
@@ -51,22 +51,13 @@ public class NotifyMessage implements Serializable {
|
||||
this(agentid, tuple, new IdParameter(), false);
|
||||
}
|
||||
|
||||
public NotifyMessage(int agentId, NotifyTuple tuple, IdParameter target,
|
||||
boolean isSafe) {
|
||||
public NotifyMessage(int agentId, NotifyTuple tuple, IdParameter target, boolean isSafe) {
|
||||
this.agentId = agentId;
|
||||
this.safe = isSafe ? 1 : 0;
|
||||
this.tuple = tuple;
|
||||
this.target = target;
|
||||
}
|
||||
|
||||
public int getSafe() {
|
||||
return safe;
|
||||
}
|
||||
|
||||
public void setSafe(boolean isSafe) {
|
||||
this.safe = isSafe ? 1 : 0;
|
||||
}
|
||||
|
||||
public int getAgentId() {
|
||||
return agentId;
|
||||
}
|
||||
@@ -79,9 +70,20 @@ public class NotifyMessage implements Serializable {
|
||||
return target;
|
||||
}
|
||||
|
||||
public void setTarget(IdParameter target) {
|
||||
this.target = target;
|
||||
}
|
||||
|
||||
public int getSafe() {
|
||||
return safe;
|
||||
}
|
||||
|
||||
public void setSafe(boolean isSafe) {
|
||||
this.safe = isSafe ? 1 : 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "NotifyMessage [agentId=" + agentId + ", safe=" + safe
|
||||
+ ", tuple=" + tuple + ", target=" + target + "]";
|
||||
return "NotifyMessage [agentId=" + agentId + ", safe=" + safe + ", tuple=" + tuple + ", target=" + target + "]";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -36,7 +36,7 @@ public class WeixinQyAccount extends WeixinAccount {
|
||||
/**
|
||||
*
|
||||
* @param corpid
|
||||
* 企业ID 必填
|
||||
* 企业ID 使用普通接口(WeixinProxy对象)必须填写
|
||||
* @param corpsecret
|
||||
* 管理组的凭证密钥 使用普通接口(WeixinProxy对象)必须填写
|
||||
* @param suites
|
||||
|
||||
Reference in New Issue
Block a user