1
This commit is contained in:
parent
65eab9985b
commit
6b18b1651b
@ -14,7 +14,6 @@ import com.evo.common.core.domain.AjaxResult;
|
|||||||
import com.evo.common.utils.Collections;
|
import com.evo.common.utils.Collections;
|
||||||
import com.evo.common.utils.http.HttpUtils;
|
import com.evo.common.utils.http.HttpUtils;
|
||||||
import com.evo.ding.DingUtils;
|
import com.evo.ding.DingUtils;
|
||||||
import com.evo.kingdeeUtils.kenum.KingdeeParamsEnum;
|
|
||||||
import com.evo.personnelMatters.mapper.RzOverTimeDetailMapper;
|
import com.evo.personnelMatters.mapper.RzOverTimeDetailMapper;
|
||||||
import com.evo.personnelMatters.mapper.RzOverTimeMapper;
|
import com.evo.personnelMatters.mapper.RzOverTimeMapper;
|
||||||
import com.evo.restaurant.service.IRzRestaurantStatisticsService;
|
import com.evo.restaurant.service.IRzRestaurantStatisticsService;
|
||||||
@ -26,8 +25,6 @@ import com.evo.wechat.dto.MessageTemplate;
|
|||||||
import com.evo.wechat.service.GZHAccessTokenService;
|
import com.evo.wechat.service.GZHAccessTokenService;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.jasypt.encryption.StringEncryptor;
|
import org.jasypt.encryption.StringEncryptor;
|
||||||
import org.springframework.core.io.FileSystemResource;
|
|
||||||
import org.springframework.stereotype.Controller;
|
|
||||||
import org.springframework.ui.Model;
|
import org.springframework.ui.Model;
|
||||||
import org.springframework.util.LinkedMultiValueMap;
|
import org.springframework.util.LinkedMultiValueMap;
|
||||||
import org.springframework.util.MultiValueMap;
|
import org.springframework.util.MultiValueMap;
|
||||||
@ -195,8 +192,8 @@ public class TestController {
|
|||||||
*/
|
*/
|
||||||
@GetMapping("/testAdapterSend")
|
@GetMapping("/testAdapterSend")
|
||||||
public AjaxResult testSend() throws ParseException {
|
public AjaxResult testSend() throws ParseException {
|
||||||
// RestTemplate restTemplate = new RestTemplate();
|
RestTemplate restTemplate = new RestTemplate();
|
||||||
// MultiValueMap<String, Object> params = new LinkedMultiValueMap<>();
|
MultiValueMap<String, Object> params = new LinkedMultiValueMap<>();
|
||||||
// // 文件
|
// // 文件
|
||||||
// File file = new File("D:\\andy\\车辆管理.png");
|
// File file = new File("D:\\andy\\车辆管理.png");
|
||||||
//// File file1 = new File("D:\\andy\\index.ts");
|
//// File file1 = new File("D:\\andy\\index.ts");
|
||||||
@ -222,61 +219,63 @@ public class TestController {
|
|||||||
//
|
//
|
||||||
//
|
//
|
||||||
//
|
//
|
||||||
// Map<String,String> dataMap = Collections.emptyMap();
|
// {"month":"sendMarkdownAndFileToUser","robotCode":"dinge794oclijuyxsyub","clientId":"dinge794oclijuyxsyub","clientSecret":"4ryzLl48I8ghhKqEMPCwablFqbs6PCmadqfDAPFWBNuIEBMJvPFQg-XHAe2oH2Fe","recipientType":"code","users":["00312","00150"],"title":"消息通知测试","content":"消息正文内容。。。。。。。。"}
|
||||||
// dataMap.put("month", "sendMarkdownAndFileToUser");
|
|
||||||
// dataMap.put("robotCode","dinge794oclijuyxsyub");
|
Map<String,String> dataMap = Collections.emptyMap();
|
||||||
// dataMap.put("clientId", "dinge794oclijuyxsyub");
|
dataMap.put("month", "sendMarkdownAndFileToUser");
|
||||||
// dataMap.put("clientSecret", "4ryzLl48I8ghhKqEMPCwablFqbs6PCmadqfDAPFWBNuIEBMJvPFQg-XHAe2oH2Fe");
|
dataMap.put("robotCode","dinge794oclijuyxsyub");
|
||||||
// dataMap.put("recipientType", "code");//00146
|
dataMap.put("clientId", "dinge794oclijuyxsyub");
|
||||||
// dataMap.put("users", JSON.toJSONString(Collections.asList("00272")));
|
dataMap.put("clientSecret", "4ryzLl48I8ghhKqEMPCwablFqbs6PCmadqfDAPFWBNuIEBMJvPFQg-XHAe2oH2Fe");
|
||||||
// dataMap.put("title", "test测试");
|
dataMap.put("recipientType", "code");//00146
|
||||||
// dataMap.put("content", markdownMsg.toString());
|
dataMap.put("users", JSON.toJSONString(Collections.asList("00312","00150")));
|
||||||
|
dataMap.put("title", "消息通知测试");
|
||||||
|
dataMap.put("content", "消息正文内容。。。。。。。。");
|
||||||
//
|
//
|
||||||
//// dataMap.put("parameterTypes", JSON.toJSONString(Collections.asList("java.lang.String","java.lang.String")));
|
//// dataMap.put("parameterTypes", JSON.toJSONString(Collections.asList("java.lang.String","java.lang.String")));
|
||||||
//// dataMap.put("parameters", JSON.toJSONString(Collections.asList("test测试",markdownMsg.toString())));
|
//// dataMap.put("parameters", JSON.toJSONString(Collections.asList("test测试",markdownMsg.toString())));
|
||||||
// //推送数据类型
|
// //推送数据类型
|
||||||
// params.add("data", JSON.toJSONString(dataMap));
|
params.add("data", JSON.toJSONString(dataMap));
|
||||||
//
|
//
|
||||||
// String url = "http://localhost:8089/ding/send";
|
String url = "http://localhost:8089/ding/send";
|
||||||
// return AjaxResult.success(restTemplate.postForObject(url, params, String.class));
|
return AjaxResult.success(restTemplate.postForObject(url, params, String.class));
|
||||||
//
|
//
|
||||||
|
|
||||||
//String data = "{\"FormId\":\"BD_Empinfo\",\"FieldKeys\":\"FID\",\"FilterString\":[{\"Left\":\"\",\"FieldName\":\"FStaffNumber\",\"Compare\":\"17\",\"Value\":\"00046\",\"Right\":\"\",\"Logic\":0}],\"OrderString\":\"\",\"TopRowCount\":0,\"StartRow\":0,\"Limit\":2000,\"SubSystemId\":\"\"}";
|
//String data = "{\"FormId\":\"BD_Empinfo\",\"FieldKeys\":\"FID\",\"FilterString\":[{\"Left\":\"\",\"FieldName\":\"FStaffNumber\",\"Compare\":\"17\",\"Value\":\"00046\",\"Right\":\"\",\"Logic\":0}],\"OrderString\":\"\",\"TopRowCount\":0,\"StartRow\":0,\"Limit\":2000,\"SubSystemId\":\"\"}";
|
||||||
|
//
|
||||||
String data = "{\n" +
|
// String data = "{\n" +
|
||||||
" \"FormId\" : \"PRD_MO\",\n" +
|
// " \"FormId\" : \"PRD_MO\",\n" +
|
||||||
" \"FieldKeys\" : \"F_HBYT_SCLH,FBillNo,FWorkShopID.FName,FMaterialId.FNumber,FMaterialName,FPlanStartDate,FPlanFinishDate,FPickMtrlStatus\",\n" +
|
// " \"FieldKeys\" : \"F_HBYT_SCLH,FBillNo,FWorkShopID.FName,FMaterialId.FNumber,FMaterialName,FPlanStartDate,FPlanFinishDate,FPickMtrlStatus\",\n" +
|
||||||
" \"FilterString\" : [ {\n" +
|
// " \"FilterString\" : [ {\n" +
|
||||||
" \"FieldName\" : \"FStatus\",\n" +
|
// " \"FieldName\" : \"FStatus\",\n" +
|
||||||
" \"Compare\" : \"105\",\n" +
|
// " \"Compare\" : \"105\",\n" +
|
||||||
" \"Value\" : \"4\",\n" +
|
// " \"Value\" : \"4\",\n" +
|
||||||
" \"Left\" : \"\",\n" +
|
// " \"Left\" : \"\",\n" +
|
||||||
" \"Right\" : \"\",\n" +
|
// " \"Right\" : \"\",\n" +
|
||||||
" \"Logic\" : 0\n" +
|
// " \"Logic\" : 0\n" +
|
||||||
" }, {\n" +
|
// " }, {\n" +
|
||||||
" \"FieldName\" : \"FPickMtrlStatus\",\n" +
|
// " \"FieldName\" : \"FPickMtrlStatus\",\n" +
|
||||||
" \"Compare\" : \"29\",\n" +
|
// " \"Compare\" : \"29\",\n" +
|
||||||
" \"Value\" : \"1\",\n" +
|
// " \"Value\" : \"1\",\n" +
|
||||||
" \"Left\" : \"\",\n" +
|
// " \"Left\" : \"\",\n" +
|
||||||
" \"Right\" : \"\",\n" +
|
// " \"Right\" : \"\",\n" +
|
||||||
" \"Logic\" : 0\n" +
|
// " \"Logic\" : 0\n" +
|
||||||
" }, {\n" +
|
// " }, {\n" +
|
||||||
" \"FieldName\" : \"F_HBYT_SCLH\",\n" +
|
// " \"FieldName\" : \"F_HBYT_SCLH\",\n" +
|
||||||
" \"Compare\" : \"67\",\n" +
|
// " \"Compare\" : \"67\",\n" +
|
||||||
" \"Value\" : \"QB-26-163-XCL\",\n" +
|
// " \"Value\" : \"QB-26-163-XCL\",\n" +
|
||||||
" \"Left\" : \"\",\n" +
|
// " \"Left\" : \"\",\n" +
|
||||||
" \"Right\" : \"\",\n" +
|
// " \"Right\" : \"\",\n" +
|
||||||
" \"Logic\" : 0\n" +
|
// " \"Logic\" : 0\n" +
|
||||||
" } ],\n" +
|
// " } ],\n" +
|
||||||
" \"OrderString\" : \"\",\n" +
|
// " \"OrderString\" : \"\",\n" +
|
||||||
" \"TopRowCount\" : 0,\n" +
|
// " \"TopRowCount\" : 0,\n" +
|
||||||
" \"StartRow\" : 0,\n" +
|
// " \"StartRow\" : 0,\n" +
|
||||||
" \"Limit\" : 10000,\n" +
|
// " \"Limit\" : 10000,\n" +
|
||||||
" \"SubSystemId\" : \"\"\n" +
|
// " \"SubSystemId\" : \"\"\n" +
|
||||||
"}";
|
// "}";
|
||||||
|
//
|
||||||
return AjaxResult.success(HttpUtils.sendPost("http://localhost:8089/distribution/kingdee/send", JSONObject.toJSONString(
|
// return AjaxResult.success(HttpUtils.sendPost("http://localhost:8089/distribution/kingdee/send", JSONObject.toJSONString(
|
||||||
Collections.asMap("fromId","PRD_MO", "month","billQuery", "parameterTypes",Collections.asList(String.class),"data",Collections.asMap("123",data)))));
|
// Collections.asMap("fromId","PRD_MO", "month","billQuery", "parameterTypes",Collections.asList(String.class),"data",Collections.asMap("123",data)))));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user