WebIndexController.java
3.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
package com.lhcredit.project.webbusiness.controller;
import com.lhcredit.framework.web.domain.AjaxResult;
import com.lhcredit.project.business.BasicInformation.service.BasicInformationService;
import com.lhcredit.project.business.TianYC.entity.param.RequestParams;
import com.lhcredit.project.business.judicial.service.JudicialService;
import com.lhcredit.project.business.jycount.domain.Jycount;
import com.lhcredit.project.business.jycount.service.IJycountService;
import com.lhcredit.project.business.memberUnit.service.IMemberUnitService;
import com.lhcredit.project.business.organization.domain.Organization;
import com.lhcredit.project.business.organization.service.IOrganizationService;
import com.lhcredit.project.business.sfcount.domain.Sfcount;
import com.lhcredit.project.business.sfcount.service.ISfcountService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Controller
@RequestMapping("/web/index")
public class WebIndexController {
@Autowired
IMemberUnitService memberUnitService;
@Autowired
IOrganizationService organizationService;
@Autowired
BasicInformationService basicInformationService;
@Autowired
private JudicialService judicialService;
@Autowired
private ISfcountService sfcountService;
@Autowired
private IJycountService jycountService;
@RequestMapping("/baseinfo")
@ResponseBody
public AjaxResult baseinfo() {
Map respData = new HashMap();
List<Map> listLevel= organizationService.selectAllOrganizationGroupLevel();
if(!listLevel.contains("D")){
Map resp = new HashMap();
resp.put("creditLevel","D");
resp.put("count",0);
listLevel.add(resp);
}
respData.put("level",listLevel);
List<Map> listreg = organizationService.selectAllOrganizationGroupReg();
respData.put("RegistCapi",listreg);
List<Map> listOrgType=organizationService.selectAllOrganizationGroupOrgTyp();
respData.put("OrgType",listOrgType);
List<Map> listScopeType=organizationService.selectAllOrganizationGroupScopeTyp();
respData.put("ScopeType",listScopeType);
int orgCount=organizationService.selectAllOrganizationCount();
respData.put("orgCount",orgCount);
int memberCount=memberUnitService.selectMemberUnitCount();
respData.put("memberCount",memberCount);
return AjaxResult.success(respData);
}
@RequestMapping("/getJudiciary")
@ResponseBody
public AjaxResult getJudiciary() {
Map respData = new HashMap();
Sfcount sf=new Sfcount();
sf.setStatus("0");
List<Sfcount> list=sfcountService.selectSfcountList(sf);
int count=0;
for(Sfcount sfcount:list){
count+=sfcount.getMs()+sfcount.getXs()+sfcount.getXz()+sfcount.getFsbq()+sfcount.getZx()+sfcount.getPc();
}
respData.put("sfNum",count);
respData.put("SfcountList",list);
return AjaxResult.success(respData);
}
@RequestMapping("/getOperate")
@ResponseBody
public AjaxResult getOperate() {
Map respData = new HashMap();
Jycount jy=new Jycount();
jy.setStatus("0");
List<Jycount> list=jycountService.selectJycountList(jy);
int count=0;
for(Jycount jycount:list){
count+=jycount.getJyyc()+jycount.getXzcf()+jycount.getYzwf()+jycount.getGqcz()+jycount.getGqdj()+jycount.getQsgg()+jycount.getQsxx()+jycount.getTddy()+jycount.getCcjc();
}
respData.put("jyNum",count);
respData.put("jycountList",list);
return AjaxResult.success(respData);
}
}