develop
yuemian 2024-08-26 10:00:17 +08:00
parent 441ea98cd6
commit c04fefc812
2 changed files with 4 additions and 10 deletions

View File

@ -2,30 +2,24 @@ package com.bocloud.sms.service;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.bocloud.cmp.boot.controller.IndexController;
import com.bocloud.sms.entity.Department;
import com.bocloud.sms.entity.User;
import com.bocloud.sms.enums.YkInfo;
import com.bocloud.sms.interfaces.IndexService;
import com.bocloud.sms.repository.UserRepository;
import com.bocloud.sms.utils.YkUtils;
import com.bocloud.sms.utils.YkUtil;
import com.megatron.common.model.GeneralResult;
import com.megatron.common.model.Pager;
import com.megatron.common.model.RequestContext;
import com.megatron.common.utils.MapTools;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
import java.util.Map;
@Service("IndexService")
@Slf4j
public class IndexServiceImpl implements IndexService {
@Autowired
private YkUtils ykUtils;
private YkUtil ykUtil;
@Autowired
private UserRepository userRepository;
@ -37,7 +31,7 @@ public class IndexServiceImpl implements IndexService {
param.put("userId",user.getUserId());
param.put("page",pager.getPage());
param.put("limit",pager.getRows());
String result = ykUtils.call(YkInfo.getTaskList, param, JSONArray.class);
String result = ykUtil.call(YkInfo.getTaskList, param, JSONArray.class);
log.info("result");
JSONArray dataArray = JSONArray.parseArray(result);

View File

@ -11,7 +11,7 @@ import org.springframework.stereotype.Component;
@Component
@Slf4j
public class YkUtils {
public class YkUtil {
//参考application.yml配置文件
@Value("${yk.url:http://36.111.150.83:9527/}")