bug
This commit is contained in:
parent
4fa5b24bb9
commit
b6f3192948
@ -9,6 +9,7 @@ import com.pusong.business.domain.vo.home.*;
|
||||
import com.pusong.business.service.HomeService;
|
||||
import com.pusong.business.service.IPsSalaryService;
|
||||
import com.pusong.common.core.domain.R;
|
||||
import com.pusong.common.log.annotation.Log;
|
||||
import com.pusong.common.mybatis.core.page.PageQuery;
|
||||
import com.pusong.common.mybatis.core.page.TableDataInfo;
|
||||
import com.pusong.common.satoken.utils.LoginHelper;
|
||||
@ -81,7 +82,7 @@ public class HomeController extends BaseController {
|
||||
@SaCheckPermission("business:salary:list")
|
||||
@GetMapping("/byChannel")
|
||||
public R<ChannelAmountVo> byChannel(@RequestParam() Integer type) {
|
||||
return R.ok(homeService.byChannel(type,1));
|
||||
return R.ok(homeService.byChannelAll(type));
|
||||
}
|
||||
// /**
|
||||
// * 各渠道成交统计
|
||||
@ -134,7 +135,7 @@ public class HomeController extends BaseController {
|
||||
@SaCheckPermission("business:salary:list")
|
||||
@GetMapping("/channelByUser")
|
||||
public R<ChannelAmountVo> channelByUser(@RequestParam() Integer type) {
|
||||
return R.ok(homeService.byChannel(type,2));
|
||||
return R.ok(homeService.byChannelByUser(type, LoginHelper.getUserId()));
|
||||
}
|
||||
/**
|
||||
* 首页大盘数据:任务完成情况
|
||||
|
@ -19,12 +19,14 @@ public interface HomeService {
|
||||
UserAmountVo getUserContractSourceAmountsByDeptId(Integer type, int tabType);
|
||||
List<UserContractAmountVo> getUserContractAmountsByDeptId(Integer type, Long deptId);
|
||||
UserAmountVo getUserContractAndPayInfo(Integer type, int tabType);
|
||||
|
||||
ChannelAmountVo byChannelByUser(Integer type, Long uid);
|
||||
/**
|
||||
* 首页大盘数据:各渠道成交
|
||||
* @param type
|
||||
* @return
|
||||
*/
|
||||
ChannelAmountVo byChannel(Integer type,Integer dateType);
|
||||
ChannelAmountVo byChannelAll(Integer type);
|
||||
|
||||
/**
|
||||
* 首页大盘数据:任务完成率
|
||||
|
@ -620,14 +620,20 @@ public class HomeServiceImpl implements HomeService {
|
||||
return userAmountVo;
|
||||
}
|
||||
|
||||
|
||||
@Cacheable(cacheNames = CacheNames.HOME_C, key = "#type+'_2_'+#uid")
|
||||
public ChannelAmountVo byChannelByUser(Integer type, Long uid){
|
||||
return byChannel(type, 2);
|
||||
}
|
||||
@Cacheable(cacheNames = CacheNames.HOME_C, key = "#type+'_1'")
|
||||
public ChannelAmountVo byChannelAll(Integer type){
|
||||
return byChannel(type, 1);
|
||||
}
|
||||
/**
|
||||
* 首页大盘数据:各渠道成交
|
||||
* @param type
|
||||
* @param dateType 1查全部数据 2查个人权限的数据
|
||||
* @return
|
||||
*/
|
||||
@Cacheable(cacheNames = CacheNames.HOME_C, key = "#type+'_'+#dateType")
|
||||
public ChannelAmountVo byChannel(Integer type, Integer dateType){
|
||||
Map<String, Object> mapParam = dateType == 1 ? this.getDate(type) : this.getDateByUser(type);
|
||||
LocalDate startDate = (LocalDate)mapParam.get("startDate");
|
||||
|
Loading…
Reference in New Issue
Block a user