TaskStatisticsController.java 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494
  1. package com.ydtech.modules.admin.controller.taskStatistics;
  2. import com.baomidou.mybatisplus.core.metadata.IPage;
  3. import com.github.pagehelper.PageInfo;
  4. import com.ydtech.core.page.HttpResult;
  5. import com.ydtech.modules.admin.model.dto.TaskStatisticsDto;
  6. import com.ydtech.modules.admin.model.dto.TaskStatisticsDtoNew;
  7. import com.ydtech.modules.admin.model.vo.BusinessAgentData;
  8. import com.ydtech.modules.admin.model.vo.BusinessOrderData;
  9. import com.ydtech.modules.admin.model.vo.KztGetDeptUtilsDto;
  10. import com.ydtech.modules.admin.model.vo.TaskStatisticsVo;
  11. import com.ydtech.modules.admin.service.TaskStatisticsService;
  12. import com.ydtech.modules.admin.utils.KztGetDeptUtils;
  13. import io.swagger.annotations.*;
  14. import org.apache.commons.lang3.ObjectUtils;
  15. import org.apache.commons.lang3.StringUtils;
  16. import org.springframework.beans.factory.annotation.Autowired;
  17. import org.springframework.web.bind.annotation.PostMapping;
  18. import org.springframework.web.bind.annotation.RequestBody;
  19. import org.springframework.web.bind.annotation.RequestMapping;
  20. import org.springframework.web.bind.annotation.RestController;
  21. import javax.servlet.http.HttpServletRequest;
  22. import java.util.HashMap;
  23. import java.util.List;
  24. /**
  25. * @description: 任务统计
  26. * @author: whp
  27. * @date: 2024/7/25
  28. **/
  29. @Api(tags = "控制台-任务统计")
  30. @RequestMapping("/taskStatistics")
  31. @RestController
  32. public class TaskStatisticsController {
  33. @Autowired
  34. private TaskStatisticsService taskStatisticsService;
  35. /**
  36. * @description: 渠道任务统计查询
  37. * @author: whp
  38. * @date: 2024/7/25
  39. **/
  40. @PostMapping("queryPage")
  41. @ApiOperation(value = "控制台-渠道任务统计查询")
  42. public HttpResult<IPage<TaskStatisticsDto>> queryPage(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  43. try{
  44. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  45. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  46. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  47. if("1".equals(kztGetDeptUtilsDto.getType())){
  48. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  49. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  50. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  51. }
  52. }
  53. IPage<TaskStatisticsDto> result = taskStatisticsService.queryPage(taskStatisticsVo);
  54. return HttpResult.ok("查询数据成功", result);
  55. }catch (Exception e){
  56. return HttpResult.error("查询错误"+e.getMessage());
  57. }
  58. }
  59. /**
  60. * @description: 电销任务统计查询
  61. * @author: whp
  62. * @date: 2024/10/11
  63. **/
  64. @PostMapping("queryPageElectric")
  65. @ApiOperation(value = "控制台-电销任务统计查询")
  66. public HttpResult<IPage<TaskStatisticsDto>> queryPageElectric(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  67. try{
  68. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  69. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  70. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  71. if("1".equals(kztGetDeptUtilsDto.getType())){
  72. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  73. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  74. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  75. }
  76. }
  77. IPage<TaskStatisticsDto> result = taskStatisticsService.queryPageElectric(taskStatisticsVo);
  78. return HttpResult.ok("查询数据成功", result);
  79. }catch (Exception e){
  80. return HttpResult.error("查询错误"+e.getMessage());
  81. }
  82. }
  83. /**
  84. * @description: 任务统计-电销导出
  85. * @author: whp
  86. * @date: 2024/10/29
  87. **/
  88. @PostMapping("/electricExcel")
  89. @ApiOperation(value = "任务统计-电销导出")
  90. public HttpResult electricExcel(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  91. return this.taskStatisticsService.electricExcel(taskStatisticsVo);
  92. }
  93. /**
  94. * @description: 保险公司统计查询
  95. * @author: whp
  96. * @date: 2024/7/25
  97. **/
  98. @PostMapping("insuranceCompanyQueryPage")
  99. @ApiOperation(value = "控制台-保险公司统计查询")
  100. public HttpResult<IPage<TaskStatisticsDto>> insuranceCompanyQueryPage(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  101. try{
  102. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  103. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  104. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  105. if("1".equals(kztGetDeptUtilsDto.getType())){
  106. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  107. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  108. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  109. }
  110. }
  111. IPage<TaskStatisticsDto> result = taskStatisticsService.insuranceCompanyQueryPage(taskStatisticsVo);
  112. return HttpResult.ok("查询数据成功", result);
  113. }catch (Exception e){
  114. return HttpResult.error("查询错误"+e.getMessage());
  115. }
  116. }
  117. /**
  118. * @description: 代理人统计查询
  119. * @author: whp
  120. * @date: 2024/7/26
  121. **/
  122. @PostMapping("agentStatisticsQueryPage")
  123. @ApiOperation(value = "控制台-代理人统计查询")
  124. public HttpResult<IPage<TaskStatisticsDto>> agentStatisticsQueryPage(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  125. try{
  126. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  127. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  128. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  129. if("1".equals(kztGetDeptUtilsDto.getType())){
  130. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  131. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  132. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  133. }
  134. }
  135. IPage<TaskStatisticsDto> result = taskStatisticsService.agentStatisticsQueryPage(taskStatisticsVo);
  136. return HttpResult.ok("查询数据成功", result);
  137. }catch (Exception e){
  138. return HttpResult.error("查询错误"+e.getMessage());
  139. }
  140. }
  141. /**
  142. * @description: 任务统计-代理人导出
  143. * @author: whp
  144. * @date: 2024/9/9
  145. **/
  146. @PostMapping("/agentExcel")
  147. @ApiOperation(value = "任务统计-代理人导出")
  148. public HttpResult channelAgentExcel(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  149. return this.taskStatisticsService.agentExcel(taskStatisticsVo);
  150. }
  151. /**
  152. * @description: 财务中心-费用校验
  153. * @author: whp
  154. * @date: 2024/7/29
  155. **/
  156. @PostMapping("costCenter")
  157. @ApiOperation(value = "控制台-财务中心-费用校验")
  158. public HttpResult<IPage<TaskStatisticsDto>> costCenter(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  159. try{
  160. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  161. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  162. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  163. if("1".equals(kztGetDeptUtilsDto.getType())){
  164. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  165. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  166. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  167. }
  168. }
  169. IPage<TaskStatisticsDto> result = taskStatisticsService.costCenter(taskStatisticsVo);
  170. return HttpResult.ok("查询数据成功", result);
  171. }catch (Exception e){
  172. return HttpResult.error("查询错误"+e.getMessage());
  173. }
  174. }
  175. /**
  176. * @description: 财务中心-费用校验-明细
  177. * @author: whp
  178. * @date: 2024/10/10
  179. **/
  180. @PostMapping("costCenterDetails")
  181. @ApiOperation(value = "控制台-财务中心-费用校验详情")
  182. public HttpResult<IPage<TaskStatisticsDto>> costCenterDetails(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  183. try{
  184. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  185. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  186. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  187. if("1".equals(kztGetDeptUtilsDto.getType())){
  188. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  189. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  190. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  191. }
  192. }
  193. IPage<TaskStatisticsDto> result = taskStatisticsService.costCenterDetails(taskStatisticsVo);
  194. return HttpResult.ok("查询数据成功", result);
  195. }catch (Exception e){
  196. return HttpResult.error("查询错误"+e.getMessage());
  197. }
  198. }
  199. /**
  200. * @description: 财务中心-费用校验-明细-查看
  201. * @author: whp
  202. * @date: 2024/10/10
  203. **/
  204. @PostMapping("costCenterDetailsLicense")
  205. @ApiOperation(value = "控制台-财务中心-费用校验详情-查看")
  206. public HttpResult<TaskStatisticsDtoNew> costCenterDetailsLicense(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  207. try{
  208. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  209. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  210. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  211. if("1".equals(kztGetDeptUtilsDto.getType())){
  212. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  213. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  214. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  215. }
  216. }
  217. TaskStatisticsDtoNew result = taskStatisticsService.costCenterDetailsLicense(taskStatisticsVo);
  218. return HttpResult.ok("查询数据成功", result);
  219. }catch (Exception e){
  220. return HttpResult.error("查询错误"+e.getMessage());
  221. }
  222. }
  223. /**
  224. * @description: 任务统计-保险公司-导出
  225. * @author: whp
  226. * @date: 2024/9/9
  227. **/
  228. @PostMapping("/costCenterDetailsExcel")
  229. @ApiOperation(value = "控制台-财务中心-费用校验详情-导出")
  230. public HttpResult costCenterDetailsExcel(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  231. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  232. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  233. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  234. if("1".equals(kztGetDeptUtilsDto.getType())){
  235. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  236. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  237. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  238. }
  239. }
  240. return this.taskStatisticsService.costCenterDetailsExcel(taskStatisticsVo);
  241. }
  242. /**
  243. * @description: 财务中心-费用校验-合计
  244. * @author: whp
  245. * @date: 2024/9/28
  246. **/
  247. @PostMapping("costCenterTotal")
  248. @ApiOperation(value = "财务中心-费用校验-合计")
  249. public HttpResult<HashMap<String,Object>> costCenterTotal(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  250. try{
  251. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  252. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  253. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  254. if("1".equals(kztGetDeptUtilsDto.getType())){
  255. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  256. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  257. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  258. }
  259. }
  260. HashMap<String,Object> result = taskStatisticsService.costCenterTotal(taskStatisticsVo);
  261. return HttpResult.ok("查询数据成功", result);
  262. }catch (Exception e){
  263. return HttpResult.error("查询错误"+e.getMessage());
  264. }
  265. }
  266. /**
  267. * @description: 保险公司统计总报价
  268. * @author: whp
  269. * @date: 2024/8/12
  270. **/
  271. @PostMapping("totalQuotation")
  272. @ApiOperation(value = "控制台-保险公司统计查询")
  273. public HttpResult<IPage<TaskStatisticsDto>> totalQuotation(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  274. try{
  275. IPage<TaskStatisticsDto> result = taskStatisticsService.totalQuotation(taskStatisticsVo);
  276. return HttpResult.ok("查询数据成功", result);
  277. }catch (Exception e){
  278. return HttpResult.error("查询错误"+e.getMessage());
  279. }
  280. }
  281. /**
  282. * @description: 任务统计-保险公司-导出
  283. * @author: whp
  284. * @date: 2024/9/9
  285. **/
  286. @PostMapping("/insuranceCompanyExcel")
  287. @ApiOperation(value = "任务统计-保险公司-导出")
  288. public HttpResult insuranceCompanyExcel(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  289. return this.taskStatisticsService.insuranceCompanyExcel(taskStatisticsVo);
  290. }
  291. /**
  292. * @description: 控制台-业务数据
  293. * @author: whp
  294. * @date: 2024/8/13
  295. **/
  296. @PostMapping("getBusinessData")
  297. @ApiOperation(value = "控制台-业务数据")
  298. public HttpResult<IPage<TaskStatisticsDto>> getBusinessData(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  299. try{
  300. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  301. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  302. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  303. if("1".equals(kztGetDeptUtilsDto.getType())){
  304. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  305. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  306. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  307. }
  308. }
  309. IPage<TaskStatisticsDto> result = taskStatisticsService.getBusinessData(taskStatisticsVo);
  310. return HttpResult.ok("查询数据成功", result);
  311. }catch (Exception e){
  312. return HttpResult.error("查询错误"+e.getMessage());
  313. }
  314. }
  315. /**
  316. * @description: 控制台-业务数据-统计
  317. * @author: whp
  318. * @date: 2024/10/12
  319. **/
  320. @PostMapping("getCountBusinessData")
  321. @ApiOperation(value = "控制台-业务数据")
  322. public HttpResult<TaskStatisticsDto> getCountBusinessData(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  323. try{
  324. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  325. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  326. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  327. if("1".equals(kztGetDeptUtilsDto.getType())){
  328. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  329. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  330. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  331. }
  332. }
  333. TaskStatisticsDto result = taskStatisticsService.getCountBusinessData(taskStatisticsVo);
  334. return HttpResult.ok("查询数据成功", result);
  335. }catch (Exception e){
  336. return HttpResult.error("查询错误"+e.getMessage());
  337. }
  338. }
  339. /**
  340. * @description: 控制台-业务数据 - 保险分布
  341. * @author: whp
  342. * @date: 2024/8/13
  343. **/
  344. @PostMapping("getDistribution")
  345. @ApiOperation(value = "控制台-业务数据-保险分布")
  346. public HttpResult<List<TaskStatisticsDto>> getDistribution(@RequestBody TaskStatisticsVo taskStatisticsVo, HttpServletRequest httpServerRequest) {
  347. try{
  348. KztGetDeptUtils kztGetDeptUtils = new KztGetDeptUtils();
  349. KztGetDeptUtilsDto kztGetDeptUtilsDto = kztGetDeptUtils.KztGetDeptIds(httpServerRequest.getRequestURL().toString());
  350. if(ObjectUtils.isNotEmpty(kztGetDeptUtilsDto)){
  351. if("1".equals(kztGetDeptUtilsDto.getType())){
  352. taskStatisticsVo.setDeptIds(kztGetDeptUtilsDto.getIds());
  353. } else if ("2".equals(kztGetDeptUtilsDto.getType())) {
  354. taskStatisticsVo.setUserIds(kztGetDeptUtilsDto.getIds());
  355. }
  356. }
  357. List<TaskStatisticsDto> result = taskStatisticsService.getDistribution(taskStatisticsVo);
  358. return HttpResult.ok("查询数据成功", result);
  359. }catch (Exception e){
  360. return HttpResult.error("查询错误"+e.getMessage());
  361. }
  362. }
  363. /**
  364. * @description: 任务统计-渠道导出
  365. * @author: whp
  366. * @date: 2024/8/13
  367. **/
  368. @PostMapping("/channelExcel")
  369. @ApiOperation(value = "任务统计-渠道导出")
  370. public HttpResult channelExcel(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  371. return this.taskStatisticsService.channelExcel(taskStatisticsVo);
  372. }
  373. /**
  374. * @description: 任控制台-业务数据-代理人
  375. * @author: whp
  376. * @date: 2024/09/09
  377. **/
  378. @PostMapping("getBusinessAgentData")
  379. @ApiOperation(value = "控制台-业务数据-代理人")
  380. public HttpResult<IPage<BusinessAgentData>> getBusinessAgentData(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  381. try{
  382. IPage<BusinessAgentData> result = taskStatisticsService.getBusinessAgentData(taskStatisticsVo);
  383. return HttpResult.ok("查询数据成功", result);
  384. }catch (Exception e){
  385. return HttpResult.error("查询错误"+e.getMessage());
  386. }
  387. }
  388. /**
  389. * @description: 任控制台-业务数据-代理人-合计
  390. * @author: whp
  391. * @date: 2024/09/09
  392. **/
  393. @PostMapping("getBusinessAgentDataTotal")
  394. @ApiOperation(value = "控制台-业务数据-代理人-合计")
  395. public HttpResult<BusinessAgentData> getBusinessAgentDataTotal(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  396. try{
  397. BusinessAgentData result = taskStatisticsService.getBusinessAgentDataTotal(taskStatisticsVo);
  398. return HttpResult.ok("查询数据成功", result);
  399. }catch (Exception e){
  400. return HttpResult.error("查询错误"+e.getMessage());
  401. }
  402. }
  403. /**
  404. * @description: 任控制台-业务数据-代理人-详情
  405. * @author: whp
  406. * @date: 2024/09/10
  407. **/
  408. @PostMapping("getBusinessAgentDataDetails")
  409. @ApiOperation(value = "控制台-业务数据-代理人-详情")
  410. public HttpResult<IPage<BusinessAgentData>> getBusinessAgentDataDetails(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  411. try{
  412. IPage<BusinessAgentData> result = taskStatisticsService.getBusinessAgentDataDetails(taskStatisticsVo);
  413. return HttpResult.ok("查询数据成功", result);
  414. }catch (Exception e){
  415. return HttpResult.error("查询错误"+e.getMessage());
  416. }
  417. }
  418. /**
  419. *
  420. * @param taskStatisticsVo
  421. * @return 控制台任务统计 渠道代理人详情
  422. */
  423. @PostMapping("channelAgentDetails")
  424. @ApiOperation(value = "控制台任务统计 渠道代理人详情")
  425. public HttpResult<IPage<TaskStatisticsDto>> channelAgentDetails(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  426. try{
  427. IPage<TaskStatisticsDto> result = taskStatisticsService.channelAgentDetails(taskStatisticsVo);
  428. return HttpResult.ok("查询数据成功", result);
  429. }catch (Exception e){
  430. return HttpResult.error("查询错误"+e.getMessage());
  431. }
  432. }
  433. /**
  434. * @description: 任控制台-业务数据-渠道-详情
  435. * @author: hh
  436. * @date: 2024/11/19
  437. **/
  438. @PostMapping("getBusinessOrderDataDetails")
  439. @ApiOperation(value = "控制台-业务数据-电销-订单详情-详情")
  440. public HttpResult<PageInfo<BusinessOrderData>> getBusinessOrderDataDetails(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  441. try {
  442. PageInfo<BusinessOrderData> businessOrderDataDetails = taskStatisticsService.getBusinessOrderDataDetails(taskStatisticsVo);
  443. return HttpResult.ok("查询数据成功", businessOrderDataDetails);
  444. } catch (Exception e) {
  445. return HttpResult.error("查询错误"+e.getMessage());
  446. }
  447. }
  448. /**
  449. * @description: 控制台-业务数据-渠道-订单详情-合计
  450. * @author: hh
  451. * @date: 2024/11/19
  452. **/
  453. @PostMapping("getBusinessOrderDataTotal")
  454. @ApiOperation(value = "控制台-业务数据-电销-订单详情-合计")
  455. public HttpResult<BusinessOrderData> getBusinessOrderDataTotal(@RequestBody TaskStatisticsVo taskStatisticsVo) {
  456. try {
  457. BusinessOrderData result = taskStatisticsService.getBusinessOrderDataTotal(taskStatisticsVo);
  458. return HttpResult.ok("查询数据成功", result);
  459. } catch (Exception e) {
  460. return HttpResult.error("查询错误"+e.getMessage());
  461. }
  462. }
  463. }