Merge remote-tracking branch 'origin/huacheng_test' into huacheng_test
| | |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>com.alibaba</groupId> |
| | | <artifactId>fastjson</artifactId> |
| | | <version>1.2.74</version> |
| | | </dependency> |
| | | |
| | | <dependency> |
| | | <groupId>cn.afterturn</groupId> |
| | | <artifactId>easypoi-annotation</artifactId> |
| | | <version>4.1.0</version> |
| | |
| | | id=0; |
| | | return iClassifyAdministrationService.queryListById(id); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | WorkOrder workOrder=new WorkOrder(); |
| | | List<String> ids=iOrganizationChartService.getIds(sysUser.getDepartmentId()); |
| | | //状态(1待分配 2 待办结 3 已办结 4 待评价 5 已取消 8未解决 9已解决) |
| | | workOrder.setAllNum(iGuideRepairOrderService.countStatisticsNum("",ids,null,null,null)); |
| | | workOrder.setWaitDistribution(iGuideRepairOrderService.countStatisticsNum("1",ids,null,null,null)); |
| | | workOrder.setWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",ids,null,null,null)); |
| | | workOrder.setHaveDealWith(iGuideRepairOrderService.countStatisticsNum("3",ids,null,null,null)); |
| | | workOrder.setRemainEvaluated(iGuideRepairOrderService.countStatisticsNum("4",ids,null,null,null)); |
| | | workOrder.setCanceled(iGuideRepairOrderService.countStatisticsNum("5",ids,null,null,null)); |
| | | workOrder.setUnsolved(iGuideRepairOrderService.countStatisticsNum("6",ids,null,null,null)); |
| | | workOrder.setResolved(iGuideRepairOrderService.countStatisticsNum("7",ids,null,null,null)); |
| | | workOrder.setAllNum(iGuideRepairOrderService.countStatisticsNum("",ids,null,null,null,null)); |
| | | workOrder.setWaitDistribution(iGuideRepairOrderService.countStatisticsNum("1",ids,null,null,null,null)); |
| | | workOrder.setWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",ids,null,null,null,null)); |
| | | workOrder.setHaveDealWith(iGuideRepairOrderService.countStatisticsNum("3",ids,null,null,null,null)); |
| | | workOrder.setRemainEvaluated(iGuideRepairOrderService.countStatisticsNum("4",ids,null,null,null,null)); |
| | | workOrder.setCanceled(iGuideRepairOrderService.countStatisticsNum("5",ids,null,null,null,null)); |
| | | workOrder.setUnsolved(iGuideRepairOrderService.countStatisticsNum("6",ids,null,null,null,null)); |
| | | workOrder.setResolved(iGuideRepairOrderService.countStatisticsNum("7",ids,null,null,null,null)); |
| | | |
| | | |
| | | //是否超时 (1 未超时 2已超时) 超时未办结 |
| | | workOrder.setOvertime(iGuideRepairOrderService.countStatisticsNum(null,ids,null,"2",null)); |
| | | workOrder.setOvertimeWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",ids,null,"2",null)); |
| | | workOrder.setOvertime(iGuideRepairOrderService.countStatisticsNum(null,ids,null,"2",null,null)); |
| | | workOrder.setOvertimeWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",ids,null,"2",null,null)); |
| | | return ResultData.success(workOrder); |
| | | } |
| | | |
| | |
| | | |
| | | import com.dg.core.ResultData; |
| | | import com.dg.core.db.gen.entity.*; |
| | | import com.dg.core.service.IClassifyAdministrationService; |
| | | import com.dg.core.service.IGuideEvolveService; |
| | | import com.dg.core.service.IGuideRepairOrderService; |
| | | import com.dg.core.service.ITransactionEventService; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import org.apache.commons.lang3.StringUtils; |
| | |
| | | import org.springframework.web.bind.annotation.RequestParam; |
| | | import org.springframework.web.bind.annotation.RestController; |
| | | |
| | | import java.util.ArrayList; |
| | | import java.util.Calendar; |
| | | import java.util.List; |
| | | |
| | |
| | | @Autowired |
| | | IGuideEvolveService iGuideEvolveService; |
| | | |
| | | //分类 |
| | | @Autowired |
| | | IClassifyAdministrationService iClassifyAdministrationService; |
| | | |
| | | @Autowired |
| | | ITransactionEventService iTransactionEventService; |
| | | |
| | | @ApiOperation("首页统计不同状态工单数") |
| | | @GetMapping("/getWorkOrder") |
| | | public ResultData getWorkOrder() |
| | | { |
| | | WorkOrder workOrder=new WorkOrder(); |
| | | //状态(1待分配 2 待办结 3 已办结 4 待评价 5 已取消 6未解决 7已解决) |
| | | workOrder.setAllNum(iGuideRepairOrderService.countStatisticsNum("",null,null,null,null)); |
| | | workOrder.setWaitDistribution(iGuideRepairOrderService.countStatisticsNum("1",null,null,null,null)); |
| | | workOrder.setWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",null,null,null,null)); |
| | | workOrder.setHaveDealWith(iGuideRepairOrderService.countStatisticsNum("3",null,null,null,null)); |
| | | workOrder.setRemainEvaluated(iGuideRepairOrderService.countStatisticsNum("4",null,null,null,null)); |
| | | workOrder.setCanceled(iGuideRepairOrderService.countStatisticsNum("5",null,null,null,null)); |
| | | workOrder.setUnsolved(iGuideRepairOrderService.countStatisticsNum("6",null,null,null,null)); |
| | | workOrder.setResolved(iGuideRepairOrderService.countStatisticsNum("7",null,null,null,null)); |
| | | workOrder.setAllNum(iGuideRepairOrderService.countStatisticsNum("",null,null,null,null,null)); |
| | | workOrder.setWaitDistribution(iGuideRepairOrderService.countStatisticsNum("1",null,null,null,null,null)); |
| | | workOrder.setWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",null,null,null,null,null)); |
| | | workOrder.setHaveDealWith(iGuideRepairOrderService.countStatisticsNum("3",null,null,null,null,null)); |
| | | workOrder.setRemainEvaluated(iGuideRepairOrderService.countStatisticsNum("4",null,null,null,null,null)); |
| | | workOrder.setCanceled(iGuideRepairOrderService.countStatisticsNum("5",null,null,null,null,null)); |
| | | workOrder.setUnsolved(iGuideRepairOrderService.countStatisticsNum("6",null,null,null,null,null)); |
| | | workOrder.setResolved(iGuideRepairOrderService.countStatisticsNum("7",null,null,null,null,null)); |
| | | |
| | | //是否超时 (1 未超时 2已超时) 超时未办结 |
| | | workOrder.setOvertime(iGuideRepairOrderService.countStatisticsNum(null,null,null,"2",null)); |
| | | workOrder.setOvertime(iGuideRepairOrderService.countStatisticsNum(null,null,null,"2",null,null)); |
| | | // 超时未办结 |
| | | workOrder.setOvertimeWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",null,null,"2",null)); |
| | | workOrder.setOvertimeWaitDealWith(iGuideRepairOrderService.countStatisticsNum("2",null,null,"2",null,null)); |
| | | return ResultData.success(workOrder); |
| | | } |
| | | |
| | |
| | | //1 今天 2昨天 3本月 4本年度 |
| | | //累计全部 本年 本月 今日 昨日 |
| | | TimeWorkOrder timeWorkOrder=new TimeWorkOrder(); |
| | | timeWorkOrder.setAllNum(iGuideRepairOrderService.countStatisticsNum(null,null,null,null,null)); |
| | | timeWorkOrder.setYearNum(iGuideRepairOrderService.countStatisticsNum(null,null,"4",null,null)); |
| | | timeWorkOrder.setMonthNum(iGuideRepairOrderService.countStatisticsNum(null,null,"3",null,null)); |
| | | timeWorkOrder.setTodayNum(iGuideRepairOrderService.countStatisticsNum(null,null,"1",null,null)); |
| | | timeWorkOrder.setYesterdayNum(iGuideRepairOrderService.countStatisticsNum(null,null,"2",null,null)); |
| | | timeWorkOrder.setAllNum(iGuideRepairOrderService.countStatisticsNum(null,null,null,null,null,null)); |
| | | timeWorkOrder.setYearNum(iGuideRepairOrderService.countStatisticsNum(null,null,"4",null,null,null)); |
| | | timeWorkOrder.setMonthNum(iGuideRepairOrderService.countStatisticsNum(null,null,"3",null,null,null)); |
| | | timeWorkOrder.setTodayNum(iGuideRepairOrderService.countStatisticsNum(null,null,"1",null,null,null)); |
| | | timeWorkOrder.setYesterdayNum(iGuideRepairOrderService.countStatisticsNum(null,null,"2",null,null,null)); |
| | | return ResultData.success(timeWorkOrder); |
| | | } |
| | | |
| | |
| | | { |
| | | EfficiencyEntity entity=new EfficiencyEntity(); |
| | | //总工单数 |
| | | int allNum=iGuideRepairOrderService.countStatisticsNum("",null,null,null,null); |
| | | int allNum=iGuideRepairOrderService.countStatisticsNum("",null,null,null,null,null); |
| | | |
| | | java.text.DecimalFormat weekDf=new java.text.DecimalFormat("##.##%");//传入格式模板 |
| | | |
| | | int bj=iGuideRepairOrderService.countStatisticsNum("3",null,null,null,null); |
| | | int bj=iGuideRepairOrderService.countStatisticsNum("3",null,null,null,null,null); |
| | | if(bj!=0) |
| | | { |
| | | // 好评率=评价为满意的导办工单数量/已办结状态工单数量 |
| | | String goodReputationEfficiency=weekDf.format((float)(iGuideRepairOrderService.countStatisticsNum(null,null,null,null,"1") |
| | | String goodReputationEfficiency=weekDf.format((float)(iGuideRepairOrderService.countStatisticsNum(null,null,null,null,"1",null) |
| | | /bj)); |
| | | entity.setGoodReputationEfficiency(goodReputationEfficiency); |
| | | |
| | | // 解决率=已解决状态的导办工单数量/已办结状态工单数量 |
| | | String resolveEfficiency=weekDf.format((float)(iGuideRepairOrderService.countStatisticsNum("7",null,null,null,null) |
| | | String resolveEfficiency=weekDf.format((float)(iGuideRepairOrderService.countStatisticsNum("7",null,null,null,null,null) |
| | | /bj)); |
| | | entity.setResolveEfficiency(resolveEfficiency); |
| | | |
| | | if(allNum!=0) |
| | | { |
| | | // 办结率=待评价+已办结状态的导办工单数量/总工单数量 |
| | | String workEfficiency=weekDf.format((float)((iGuideRepairOrderService.countStatisticsNum("4",null,null,null,null) |
| | | String workEfficiency=weekDf.format((float)((iGuideRepairOrderService.countStatisticsNum("4",null,null,null,null,null) |
| | | +bj)/allNum)); |
| | | entity.setWorkEfficiency(workEfficiency); |
| | | } |
| | | } |
| | | |
| | | int cs=iGuideRepairOrderService.countStatisticsNum(null,null,null,"2",null); |
| | | int cs=iGuideRepairOrderService.countStatisticsNum(null,null,null,"2",null,null); |
| | | if(cs!=0) |
| | | { |
| | | // 超时办结率=超时状态下的待评价+已办结状态的导办工单数量/超时状态的导办工单数量 |
| | | String timeoutEfficiency=weekDf.format((float)((iGuideRepairOrderService.countStatisticsNum("4",null,null,"2",null) |
| | | +iGuideRepairOrderService.countStatisticsNum("3",null,null,null,null)) |
| | | String timeoutEfficiency=weekDf.format((float)((iGuideRepairOrderService.countStatisticsNum("4",null,null,"2",null,null) |
| | | +iGuideRepairOrderService.countStatisticsNum("3",null,null,null,null,null)) |
| | | /cs)); |
| | | entity.setTimeoutEfficiency(timeoutEfficiency); |
| | | |
| | |
| | | return ResultData.success(entity); |
| | | } |
| | | |
| | | @ApiOperation("工单 办事指南饼状图数据") |
| | | @GetMapping("/getPieChart") |
| | | public ResultData getPieChart() |
| | | { |
| | | PieChartAll pieChartAll=new PieChartAll(); |
| | | pieChartAll.setWorkOrderNum(iGuideRepairOrderService.countStatisticsNum("",null,null,null,null,null)+""); |
| | | pieChartAll.setFingerpostNum(iTransactionEventService.countStatisticsNum(null)+""); |
| | | List<PieChart> workOrderList=new ArrayList<>(); |
| | | List<PieChart> fingerpostList=new ArrayList<>(); |
| | | List<ClassifyAdministration> oneIds=iClassifyAdministrationService.getClassify(null,"1"); |
| | | for (ClassifyAdministration oneClassify:oneIds) |
| | | { |
| | | PieChart workOrder=new PieChart(); |
| | | PieChart fingerpost=new PieChart(); |
| | | workOrder.setName(oneClassify.getClassifyName()); |
| | | fingerpost.setName(oneClassify.getClassifyName()); |
| | | List<ClassifyAdministration> twoIds = iClassifyAdministrationService.getClassify(oneClassify.getId()+"",null); |
| | | |
| | | List clasIds=new ArrayList(); |
| | | |
| | | clasIds.add(oneClassify.getId()); |
| | | for (ClassifyAdministration classify:twoIds) |
| | | { |
| | | clasIds.add(classify.getId()); |
| | | } |
| | | int workOrderNum=0; |
| | | int fingerpostNum=0; |
| | | if(clasIds.size()>0) |
| | | { |
| | | workOrderNum=iGuideRepairOrderService.countStatisticsNum(null,null,null,null,null,clasIds); |
| | | fingerpostNum=iTransactionEventService.countStatisticsNum(clasIds); |
| | | } |
| | | workOrder.setNum(workOrderNum+""); |
| | | fingerpost.setNum(fingerpostNum+""); |
| | | workOrderList.add(workOrder); |
| | | fingerpostList.add(fingerpost); |
| | | } |
| | | |
| | | pieChartAll.setWorkOrderList(workOrderList); |
| | | pieChartAll.setFingerpostList(fingerpostList); |
| | | |
| | | return ResultData.success(pieChartAll); |
| | | } |
| | | |
| | | |
| | | @ApiOperation("组织排行榜") |
| | | @GetMapping("/getOrganization") |
| | | public ResultData getOrganization() |
| | | { |
| | | |
| | | |
| | | |
| | | return ResultData.success(); |
| | | } |
| | | |
| | | |
| | | |
| | |
| | | @ApiModelProperty(name = "guideDepartmentName", value = "导办部门") |
| | | private String guideDepartmentName; |
| | | |
| | | @TableField(exist = false) |
| | | @ApiModelProperty(name = "areaName", value = "所属地区名字") |
| | | private String areaName; |
| | | |
| | | @Override |
| | | public String toString() { |
| | | return "GuideRepairOrder{" + |
New file |
| | |
| | | package com.dg.core.db.gen.entity; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | |
| | | @ApiModel("饼状图子类实体类") |
| | | @Data |
| | | public class PieChart implements Serializable |
| | | { |
| | | @ApiModelProperty("一级分类名称") |
| | | private String name; |
| | | |
| | | |
| | | @ApiModelProperty("一级分类数量") |
| | | private String num; |
| | | } |
New file |
| | |
| | | package com.dg.core.db.gen.entity; |
| | | |
| | | import io.swagger.annotations.ApiModel; |
| | | import io.swagger.annotations.ApiModelProperty; |
| | | import lombok.Data; |
| | | |
| | | import java.io.Serializable; |
| | | import java.util.List; |
| | | |
| | | @ApiModel("饼状图实体类") |
| | | @Data |
| | | public class PieChartAll implements Serializable |
| | | { |
| | | @ApiModelProperty("工单总数") |
| | | private String workOrderNum; |
| | | |
| | | @ApiModelProperty("办事指南总数") |
| | | private String fingerpostNum; |
| | | |
| | | @ApiModelProperty("工单统计图数据") |
| | | private List<PieChart> workOrderList; |
| | | |
| | | @ApiModelProperty("办事指南统计图数据") |
| | | private List<PieChart> fingerpostList; |
| | | |
| | | |
| | | } |
| | |
| | | List<ClassifyAdministration> selectRootList (@Param("parentId")String parentId,@Param("departmentId")Integer departmentId); |
| | | |
| | | |
| | | |
| | | |
| | | /** |
| | | * 首页统计用 |
| | | * @param parentId |
| | | * @param classifyGrade |
| | | * @return |
| | | */ |
| | | public List<ClassifyAdministration> getClassify(@Param("parentId") String parentId, |
| | | @Param("classifyGrade") String classifyGrade); |
| | | |
| | | } |
| | |
| | | @Param("ids") List<String> ids, |
| | | @Param("time") String time, |
| | | @Param("isTimeout") String isTimeout, |
| | | @Param("evaluateState") String evaluateState); |
| | | @Param("evaluateState") String evaluateState, |
| | | @Param("classifyIds") List<String> classifyIds); |
| | | |
| | | /** |
| | | * 统计工单用 |
| | |
| | | * @return |
| | | */ |
| | | List<TransactionEvent> selectListByIds(String[] list); |
| | | |
| | | |
| | | /** |
| | | * 获取统计数据 首页用 勿动 |
| | | */ |
| | | int countStatisticsNum(List<String> classifyIds); |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | request.setAttribute(Constant.CURRENT_USER_ID, manager.getHCUserId(HCtoken)); |
| | | System.out.println("花城用户id:"+manager.getHCUserId(HCtoken)); |
| | | SysUser ss = IUserService.selectData(manager.getHCUserId(HCtoken)+""); |
| | | if(ss==null) |
| | | if(ss==null && ss.getUserId()<0) |
| | | { |
| | | HuaChengSysUser huaChengSysUser=iHuaChengSysUserService.selectData(manager.getHCUserId(HCtoken)+"","",""); |
| | | if(huaChengSysUser!=null) |
| | | if(huaChengSysUser!=null && huaChengSysUser.getUserId()<0 ) |
| | | { |
| | | //本地没有此用户 新用户 |
| | | SysUser newSysUser=new SysUser(); |
| | |
| | | facade.setContentLength(reponse.getBytes(StandardCharsets.UTF_8).length); |
| | | facade.getWriter().write(reponse); |
| | | return false; |
| | | // } |
| | | } |
| | | } |
| | | // } |
| | | return true; |
| | | } |
| | | } |
| | |
| | | * @return |
| | | */ |
| | | ResultData queryListById(Integer id); |
| | | |
| | | |
| | | /** |
| | | * 首页统计用 |
| | | * @param parentId |
| | | * @param classifyGrade |
| | | * @return |
| | | */ |
| | | public List<ClassifyAdministration> getClassify(String parentId, |
| | | String classifyGrade); |
| | | |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | * 统计工单用 1 今天 2昨天 3本月 4本年度 String time |
| | | * @return |
| | | */ |
| | | int countStatisticsNum(String state,List<String> ids,String time,String isTimeout,String evaluateState); |
| | | int countStatisticsNum(String state,List<String> ids,String time,String isTimeout,String evaluateState,List<String> classifyIds); |
| | | |
| | | |
| | | List<CountListNum> countListNum(String state, |
| | |
| | | * @return |
| | | */ |
| | | RecommendResult smartConsulting(String keyWord); |
| | | |
| | | |
| | | /** |
| | | * 获取统计数据 首页用 勿动 |
| | | */ |
| | | int countStatisticsNum(List<String> classifyIds); |
| | | |
| | | } |
| | |
| | | } |
| | | |
| | | @Override |
| | | public List<ClassifyAdministration> getClassify(String parentId, String classifyGrade) { |
| | | return baseMapper.getClassify(parentId,classifyGrade); |
| | | } |
| | | |
| | | @Override |
| | | public int insertConfig(ClassifyAdministration entity) { |
| | | return baseMapper.insertConfig(entity); |
| | | } |
| | |
| | | import java.util.List; |
| | | |
| | | @Service |
| | | public class GuideRepairOrderServiceImpl extends ServiceImpl<GuideRepairOrderMapper, GuideRepairOrder> implements IGuideRepairOrderService { |
| | | public class GuideRepairOrderServiceImpl extends ServiceImpl<GuideRepairOrderMapper, GuideRepairOrder> |
| | | implements IGuideRepairOrderService { |
| | | |
| | | @Resource |
| | | private TransactionEventMapper transactionEventMapper; |
| | |
| | | * @return |
| | | */ |
| | | @Override |
| | | public int countStatisticsNum(String state,List<String> ids,String time,String isTimeout,String evaluateState) { |
| | | return baseMapper.countStatisticsNum(state,ids,time,isTimeout,evaluateState); |
| | | public int countStatisticsNum(String state,List<String> ids,String time, |
| | | String isTimeout,String evaluateState,List<String> classifyIds) { |
| | | return baseMapper.countStatisticsNum(state,ids,time,isTimeout,evaluateState,classifyIds); |
| | | } |
| | | |
| | | @Override |
| | |
| | | } |
| | | |
| | | @Override |
| | | public int countStatisticsNum(List<String> classifyIds) { |
| | | return baseMapper.countStatisticsNum(classifyIds); |
| | | } |
| | | |
| | | @Override |
| | | public int countNumByMatterName(String matterName) { |
| | | return baseMapper.countNumByMatterName(matterName); |
| | | } |
New file |
| | |
| | | package com.dg.core.util; |
| | | |
| | | import com.alibaba.fastjson.JSON; |
| | | import com.dg.core.db.manual.mapper.util.ConstantPropertiesUtil; |
| | | import org.apache.http.HttpResponse; |
| | | import org.apache.http.client.methods.HttpGet; |
| | | import org.apache.http.impl.client.DefaultHttpClient; |
| | | |
| | | import java.io.BufferedReader; |
| | | import java.io.IOException; |
| | | import java.io.InputStreamReader; |
| | | import java.util.Iterator; |
| | | import java.util.List; |
| | | import java.util.Map; |
| | | |
| | | public class WxUtil { |
| | | |
| | | private static String ACCESS_TOKEN_URL = "https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential"; |
| | | |
| | | /** |
| | | * 获取花城token,(ps:0=token获取失败) |
| | | * |
| | | * @return |
| | | */ |
| | | public String getBatteryCarAccessToken() throws Exception { |
| | | String accessToken = "0"; |
| | | try { |
| | | // 此处APP_ID APP_SECRET 在微信小程序后端可见 |
| | | // String accessTokenUrl = String.format(TEMP_URL, APP_ID, APP_SECRET); |
| | | String accessTokenUrl = ACCESS_TOKEN_URL + "&appid=" + ConstantPropertiesUtil.WX_OPEN_APP_ID |
| | | + "&secret=" + ConstantPropertiesUtil.WX_OPEN_APP_SECRET; |
| | | String result = this.httpGet(accessTokenUrl, null, null); |
| | | Map<String, Object> resultMap = JSON.parseObject(result, Map.class); |
| | | if (resultMap.containsKey("access_token")) { |
| | | accessToken = resultMap.get("access_token").toString(); |
| | | } |
| | | } catch (IOException ioe) { |
| | | ioe.printStackTrace(); |
| | | } |
| | | return accessToken; |
| | | } |
| | | |
| | | |
| | | /** |
| | | * http请求工具类,get请求 |
| | | * |
| | | * @param url |
| | | * @param params |
| | | * @param resonseCharSet |
| | | * @return |
| | | * @throws Exception |
| | | */ |
| | | public static String httpGet(String url, Map<String, Object> params, String... resonseCharSet) throws Exception { |
| | | DefaultHttpClient defaultHttpClient = null; |
| | | BufferedReader bufferedReader = null; |
| | | try { |
| | | defaultHttpClient = new DefaultHttpClient(); |
| | | if (params != null) { |
| | | StringBuilder stringBuilder = new StringBuilder(); |
| | | Iterator<String> iterator = params.keySet().iterator(); |
| | | String key; |
| | | while (iterator.hasNext()) { |
| | | key = iterator.next(); |
| | | Object val = params.get(key); |
| | | if (val instanceof List) { |
| | | List v = (List) val; |
| | | for (Object o : v) { |
| | | stringBuilder.append(key).append("=").append(o.toString()).append("&"); |
| | | } |
| | | } else { |
| | | stringBuilder.append(key).append("=").append(val.toString()).append("&"); |
| | | } |
| | | } |
| | | stringBuilder.deleteCharAt(stringBuilder.length() - 1); |
| | | url = url + "?" + stringBuilder.toString(); |
| | | } |
| | | HttpGet httpGet = new HttpGet(url); |
| | | httpGet.setHeader("Content-Type", "application/json;charset=ut-8"); |
| | | HttpResponse httpResponse = defaultHttpClient.execute(httpGet); |
| | | if (httpResponse.getStatusLine().getStatusCode() != 200) { |
| | | String errorLog = "请求失败,errorCode:" + httpResponse.getStatusLine().getStatusCode(); |
| | | |
| | | throw new Exception(url + errorLog); |
| | | } |
| | | // 读取返回信息 |
| | | String charSet = "utf-8"; |
| | | if (resonseCharSet != null && resonseCharSet.length > 0) |
| | | charSet = resonseCharSet[0]; |
| | | String output; |
| | | bufferedReader = new BufferedReader(new InputStreamReader(httpResponse.getEntity().getContent(), charSet)); |
| | | |
| | | StringBuilder dataBuilder = new StringBuilder(); |
| | | while ((output = bufferedReader.readLine()) != null) { |
| | | dataBuilder.append(output); |
| | | } |
| | | return dataBuilder.toString(); |
| | | } catch (IOException e) { |
| | | e.printStackTrace(); |
| | | throw e; |
| | | } finally { |
| | | if (defaultHttpClient != null) |
| | | defaultHttpClient.getConnectionManager().shutdown(); |
| | | if (bufferedReader != null) |
| | | bufferedReader.close(); |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | } |
| | |
| | | </where> |
| | | </select> |
| | | |
| | | <!-- 首页统计用 勿动 --> |
| | | <select id="getClassify" parameterType="string" resultType="com.dg.core.db.gen.entity.ClassifyAdministration"> |
| | | select id,classify_name from automessage_classify_administration |
| | | <where> |
| | | <if test="parentId != null and parentId != ''"> |
| | | AND parent_id=#{parentId} |
| | | </if> |
| | | <if test="classifyGrade != null and classifyGrade != ''"> |
| | | AND classify_grade = #{classifyGrade} |
| | | </if> |
| | | </where> |
| | | |
| | | </select> |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | </mapper> |
| | |
| | | consult_user_phone, |
| | | submit_user_phone, |
| | | guide_user_phone, |
| | | (select name from automessage_area_code_2022 where code=a.area_code)areaName, |
| | | area_code, |
| | | detailed_address, |
| | | create_time, |
| | |
| | | select count(id) from automessage_guide_repair_order |
| | | </select> |
| | | |
| | | |
| | | <!-- 首页统计 勿动 --> |
| | | <select id="countStatisticsNum" parameterType="string" resultType="integer"> |
| | | select count(id) from automessage_guide_repair_order |
| | | <where> |
| | |
| | | #{param} |
| | | </foreach> |
| | | </if> |
| | | <if test="classifyIds != null"> |
| | | and classify_id IN |
| | | <foreach collection="classifyIds" item="param" open="(" close=")" separator=","> |
| | | #{param} |
| | | </foreach> |
| | | </if> |
| | | <if test="time != null and time == 1 "> |
| | | and to_days(automessage_guide_repair_order.create_time) = to_days(now()) |
| | | </if> |
| | |
| | | </select> |
| | | |
| | | |
| | | <!-- 首页统计 勿动 --> |
| | | <select id="countStatisticsNum" resultType="integer"> |
| | | select count(id) from automessage_transaction_event |
| | | <where> |
| | | <if test="classifyIds != null"> |
| | | and classify_id IN |
| | | <foreach collection="classifyIds" item="param" open="(" close=")" separator=","> |
| | | #{param} |
| | | </foreach> |
| | | </if> |
| | | </where> |
| | | </select> |
| | | |
| | | |
| | | |
| | | |
| | | </mapper> |
| | |
| | | |
| | | @ApiOperation(value = "excel导入楼栋信息--注:以前的接口,不需要对接") |
| | | @PostMapping(value = "/import", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "房屋信息管理", operType = 0, businessType = "导入楼栋信息") |
| | | @OperLog(operModul = "房屋信息管理-导入楼栋信息", operType = 0, businessType = "导入楼栋信息") |
| | | public R downloadPopulationTemplate(@RequestParam MultipartFile file) { |
| | | InputStream inputStream; |
| | | try { |
| | |
| | | |
| | | @ApiOperation(value = "添加单元") |
| | | @PostMapping("/add/unit") |
| | | @OperLog(operModul = "房屋信息管理", operType = 1, businessType = "添加单元") |
| | | @OperLog(operModul = "房屋信息管理-添加单元", operType = 1, businessType = "添加单元") |
| | | public R addUnit(@RequestBody AddBuildingUnitDto addBuildingUnitDto) { |
| | | // 获取登陆用户绑定社区id |
| | | Long communityId = this.getLoginUserInfo().getCommunityId(); |
| | |
| | | |
| | | @ApiOperation(value = "修改单元") |
| | | @PostMapping("/edit/unit") |
| | | @OperLog(operModul = "房屋信息管理", operType = 2, businessType = "修改单元") |
| | | @OperLog(operModul = "房屋信息管理-修改单元", operType = 2, businessType = "修改单元") |
| | | public R editUnit(@RequestBody EditBuildingUnitDto editBuildingUnitDto) { |
| | | // 获取登陆用户绑定社区id |
| | | Long communityId = this.getLoginUserInfo().getCommunityId(); |
| | |
| | | |
| | | @ApiOperation("删除楼栋") |
| | | @GetMapping("/delete") |
| | | @OperLog(operModul = "房屋信息管理", operType = 3, businessType = "删除") |
| | | @OperLog(operModul = "房屋信息管理-删除", operType = 3, businessType = "删除") |
| | | public R delete(@RequestParam("id")Long id){ |
| | | return communityService.buildingDelete(id); |
| | | } |
| | |
| | | return partyBuildingService.deletePartyOrganization(partyOrganizationVO); |
| | | } |
| | | |
| | | //@OperLog(operModul = "党员管理", operType = 1) |
| | | @OperLog(operModul = "党员管理-新增党员", operType = 1) |
| | | @ApiOperation(value = "新增党员") |
| | | @PostMapping("addpartybuildingmember") |
| | | public R addPartyBuildingMember(@RequestBody PartyBuildingMemberVO partyBuildingMemberVO) { |
| | |
| | | |
| | | @ApiOperation(value = "excel导入实有人口") |
| | | @PostMapping(value = "/serve/import", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "实有人口导入") |
| | | @OperLog(operModul = "居民信息管理-实有人口导入", operType = 0, businessType = "实有人口导入") |
| | | public R downloadPopulationTemplate(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | |
| | | @ApiOperation(value = "excel导入吸毒人员") |
| | | @PostMapping(value = "/serve/importDrug", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "吸毒人员导入") |
| | | @OperLog(operModul = "居民信息管理-吸毒人员导入", operType = 0, businessType = "吸毒人员导入") |
| | | public R importDrug(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | |
| | | @ApiOperation(value = "excel导入社区矫正人员") |
| | | @PostMapping(value = "/serve/importCorrect", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "社区矫正人员导入") |
| | | @OperLog(operModul = "居民信息管理-社区矫正人员导入", operType = 0, businessType = "社区矫正人员导入") |
| | | public R importCorrect(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | |
| | | @ApiOperation(value = "excel导入重精人员") |
| | | @PostMapping(value = "/serve/importMajor", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "重精人员导入") |
| | | @OperLog(operModul = "居民信息管理-重精人员导入", operType = 0, businessType = "重精人员导入") |
| | | public R importMajor(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | |
| | | @ApiOperation(value = "excel导入邪教人员") |
| | | @PostMapping(value = "/serve/importCult", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "邪教人员导入") |
| | | @OperLog(operModul = "居民信息管理-邪教人员导入", operType = 0, businessType = "邪教人员导入") |
| | | public R importCult(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | @ApiOperation(value = "excel导入刑释人员") |
| | | @PostMapping(value = "/serve/importRehabilitation", consumes = "multipart/*", |
| | | headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "刑释人员导入") |
| | | @OperLog(operModul = "居民信息管理-刑释人员导入", operType = 0, businessType = "刑释人员导入") |
| | | public R importRehabilitation(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | |
| | | @ApiOperation(value = "excel导入重点上访人员") |
| | | @PostMapping(value = "/serve/importKey", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "重点上访人员导入") |
| | | @OperLog(operModul = "居民信息管理-重点上访人员导入", operType = 0, businessType = "重点上访人员导入") |
| | | public R importKey(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | @ApiOperation(value = "excel导入服刑人员") |
| | | @PostMapping(value = "/serve/importSentence", consumes = "multipart/*", |
| | | headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "服刑人员导入") |
| | | @OperLog(operModul = "居民信息管理-服刑人员导入", operType = 0, businessType = "服刑人员导入") |
| | | public R importSentence(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | @ApiOperation(value = "excel导入退役军人") |
| | | @PostMapping(value = "/serve/importVeterans", consumes = "multipart/*", |
| | | headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "退役军人导入") |
| | | @OperLog(operModul = "居民信息管理-退役军人导入", operType = 0, businessType = "退役军人导入") |
| | | public R importVeterans(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | @ApiOperation(value = "excel导入残疾人") |
| | | @PostMapping(value = "/serve/importDisability", consumes = "multipart/*", |
| | | headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "残疾人导入") |
| | | @OperLog(operModul = "居民信息管理-残疾人导入", operType = 0, businessType = "残疾人导入") |
| | | public R importDisability(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | @ApiOperation(value = "excel导入低保户") |
| | | @PostMapping(value = "/serve/importLowSecurity", consumes = "multipart/*", |
| | | headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "低保户导入") |
| | | @OperLog(operModul = "居民信息管理-低保户导入", operType = 0, businessType = "低保户导入") |
| | | public R importLowSecurity(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | @ApiOperation(value = "excel导入高龄老人") |
| | | @PostMapping(value = "/serve/importElder", consumes = "multipart/*", |
| | | headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "高龄老人导入") |
| | | @OperLog(operModul = "居民信息管理-高龄老人导入", operType = 0, businessType = "高龄老人导入") |
| | | public R importElder(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | @ApiOperation(value = "excel导入养老金人员") |
| | | @PostMapping(value = "/serve/importPension", consumes = "multipart/*", |
| | | headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "养老金人员导入") |
| | | @OperLog(operModul = "居民信息管理-养老金人员导入", operType = 0, businessType = "养老金人员导入") |
| | | public R importPension(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | */ |
| | | @ApiOperation(value = "excel-确认导入实有人口") |
| | | @PostMapping(value = "/import/confirm", consumes = "multipart/*", headers = "content-type=multipart/form-date") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "实有人口导入") |
| | | @OperLog(operModul = "居民信息管理-实有人口导入", operType = 0, businessType = "实有人口导入") |
| | | public R listSavePopulationConfirm(@RequestParam MultipartFile file, HttpServletRequest request) { |
| | | // 获取文件名 |
| | | String fileName = file.getOriginalFilename(); |
| | |
| | | |
| | | @ApiOperation(value = "编辑实有人口") |
| | | @PostMapping(value = "/edit") |
| | | @OperLog(operModul = "居民信息管理", operType = 2, businessType = "编辑") |
| | | @OperLog(operModul = "居民信息管理-编辑", operType = 2, businessType = "编辑") |
| | | public R editPopulationInfo(@RequestBody ComMngPopulationEditDTO populationEditDTO) { |
| | | LoginUserInfoVO loginUserInfo = getLoginUserInfo(); |
| | | return communityService.editPopulation(populationEditDTO, loginUserInfo.getCommunityId()); |
| | |
| | | |
| | | @ApiOperation(value = "批量删除实有人口") |
| | | @PostMapping("/delete") |
| | | @OperLog(operModul = "居民信息管理", operType = 3, businessType = "批量删除实有人口") |
| | | @OperLog(operModul = "居民信息管理-批量删除实有人口", operType = 3, businessType = "批量删除实有人口") |
| | | public R deletePopulations(@RequestBody List<Long> ids) { |
| | | return communityService.deletePopulations(ids, this.getCommunityId()); |
| | | } |
| | |
| | | |
| | | @ApiOperation(value = "实有人口-数据导出") |
| | | @PostMapping("/data/export") |
| | | @OperLog(operModul = "居民信息管理", operType = 0, businessType = "实有人口导出") |
| | | @OperLog(operModul = "居民信息管理-实有人口导出", operType = 0, businessType = "实有人口导出") |
| | | public R dataExportPopulation(@RequestBody List<Long> Ids) { |
| | | // 获取登陆用户 |
| | | LoginUserInfoVO loginUserInfo = this.getLoginUserInfo(); |