mirror of
https://codeup.aliyun.com/64f7d6b8ce01efaafef1e678/coal/coal.git
synced 2026-01-25 07:46:40 +08:00
feat: 添加钉钉机器人场景相关的控制器、服务、DTO、实体和映射器
This commit is contained in:
@@ -14,4 +14,6 @@ public class SendMsgRequest {
|
||||
|
||||
private Map<String, Object> params;
|
||||
|
||||
private Map<String, Object> paramsList;
|
||||
|
||||
}
|
||||
|
||||
@@ -21,6 +21,7 @@ import freemarker.core.InvalidReferenceException;
|
||||
import lombok.SneakyThrows;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.apache.commons.collections4.MapUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.core.convert.ConversionService;
|
||||
import org.springframework.data.domain.Page;
|
||||
@@ -103,6 +104,20 @@ public class DingtalkBotService extends BaseService<DingtalkBotEntity, DingtalkB
|
||||
|
||||
results.add(doSend(dingtalkBotEntity, dingtalkBotTemplateEntity, request.getParams()));
|
||||
}
|
||||
|
||||
if (MapUtils.isNotEmpty(request.getParamsList())) {
|
||||
|
||||
for (DingtalkBotEntity dingtalkBotEntity : all) {
|
||||
|
||||
for (Map.Entry<String, Object> entry : request.getParamsList().entrySet()) {
|
||||
results.add(
|
||||
doSend(
|
||||
dingtalkBotEntity,
|
||||
dingtalkBotTemplateEntity,
|
||||
(Map<String, Object>) entry.getValue()));
|
||||
}
|
||||
}
|
||||
}
|
||||
return response;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user