Commit 38892880 by 东州 翁 Committed by chenzg

简化了籍贯的展示籍贯/展示所有籍贯接口,企业信息添加了新字段,修改了以前的修改企业信息和认证申请接口

parent ac383e23
......@@ -37,28 +37,34 @@ public class QyzxEntInfoM extends Model<QyzxEntInfoM> {
@Id
@GeneratedValue
@TableId (type = IdType.AUTO)
@ApiModelProperty(value="组织机构代码 组织机构代码",example="101")
@ApiModelProperty(value="组织机构代码 组织机构代码",example="4")
private Integer id;
@ApiModelProperty(value="企业名称 ",example="企业名称")
@ApiModelProperty(value="企业名称 ",example="优领人才")
private String name;
@ApiModelProperty(value="认证名 ",example="广东优领人才科技服务有限公司")
private String attestName;
@ApiModelProperty(value="企业简介 企业简介",example="101")
@ApiModelProperty(value="简介",example="公司福利好")
private String intro;
@ApiModelProperty(value="法人 ",example="刘德华")
private String operName;
@ApiModelProperty(value="企业规模 10人以下、10-19人、20-99人、100-500人、500人以上",example="101")
@ApiModelProperty(value="企业规模 10人以下、10-19人、20-99人、100-500人、500人以上",example="3")
private Integer size;
@ApiModelProperty(value="电话号码 ",example="18712345678")
private String phone;
@ApiModelProperty(value="所在地区",example="440111")
private Integer area;
@ApiModelProperty(value="办公地址 ",example=" 省/市/区 例:广东省/广州市/白云区")
@ApiModelProperty(value="办公地址 ",example="广从一路5号柏曼酒店3楼")
private String workAddress;
@ApiModelProperty(value="企业编码 ",example=" 例:YLZYCS(YL:优领简写;ZY:版本;CS:账户公司简称)")
@ApiModelProperty(value="企业简写 ",example=" 例:YLZYCS(YL:优领简写;ZY:版本;CS:账户公司简称)")
private String codes;
@ApiModelProperty(value="企业LOGO ",example="企业LOGO")
......@@ -70,13 +76,13 @@ public class QyzxEntInfoM extends Model<QyzxEntInfoM> {
@ApiModelProperty(value="开通渠道 1直属、2总代理、3独家代理、4一般代理商、5区域代理商",example="101")
private Integer openChannel;
@ApiModelProperty(value="联系人 ",example="刘德华")
@ApiModelProperty(value="联系人",example="刘德华")
private String linkMan;
@ApiModelProperty(value="联系人电话 ",example="18712345678")
private String linkManPhone;
@ApiModelProperty(value="统一社会信用代码 ",example=" 统一社会信用代码")
@ApiModelProperty(value="统一社会信用代码 ",example="统一社会信用代码")
private String creditCode;
@ApiModelProperty(value="是否上市 0:否 1:是",example="101")
......@@ -86,7 +92,16 @@ public class QyzxEntInfoM extends Model<QyzxEntInfoM> {
@ApiModelProperty(value="企业注册时间 ",example="企业注册时间")
private Date registerTime;
@ApiModelProperty(value="到期时间 ",example="到期时间")
@ApiModelProperty(value="营业执照 ",example="营业执照url ")
private String licenseUrl;
@ApiModelProperty(value="认证状态 ",example="0 认证中,1已认证,2认证失败 ")
private Integer attestStatus;
@ApiModelProperty(value="认证时间 ",example="2019-12-12 08:00:00")
private Date attestTime;
@ApiModelProperty(value="到期时间 ",example="2039-12-12 08:00:00")
private Date endTime;
@ApiModelProperty(value="企业版本,0试用,1标准,2专业, ",example="0")
......
......@@ -119,6 +119,23 @@ public class QyzxController {
.eq(orgCode != null, QyzxEntInfoM::getId, orgCode).one();
return ResultUtil.data(qyzxEntInfoM, "获取企业信息成功");
}
/**
* 添加/修改企业信息
*
* @param
* @return
*/
@PostMapping(value = "/ent")
@ApiOperation(value = "添加/修改企业信息", httpMethod = "POST", notes = "接口发布说明")
public Result<QyzxEntInfoM> addent(@CurrentUser UserBean userBean, @RequestBody QyzxEntInfoM qyzxEntInfoM) {
qyzxEntInfoM.setId(userBean.getOrgCode());
QyzxEntInfoM q = new LambdaQueryChainWrapper<QyzxEntInfoM>(qyzxEntInfoMMapper).eq(QyzxEntInfoM::getId, userBean.getOrgCode()).one();
qyzxEntInfoM.setRegisterTime(q.getRegisterTime());
qyzxEntInfoM.insertOrUpdate();
return ResultUtil.data(qyzxEntInfoM, "添加/修改企业");
}
/**
* 企业认证-申请
......@@ -128,14 +145,13 @@ public class QyzxController {
*/
@PostMapping(value = "/entauth")
@ApiOperation(value = "企业认证", httpMethod = "POST", notes = "接口发布说明")
public Result<QyzxEntAuth> entauth(@CurrentUser UserBean userBean, @RequestBody QyzxEntAuth qyzxEntAuth) {
public Result<QyzxEntInfoM> entauth(@CurrentUser UserBean userBean, @RequestBody QyzxEntInfoM qyzxEntInfoM) {
// 设置审核状态
qyzxEntAuth.setAuthType(CommonEnum.AUTH_TYPE_UNDEREVIEW.getType());
qyzxEntAuth.setId(userBean.getOrgCode());
// 插入数据
qyzxEntAuth.insert();
qyzxEntInfoM.setAttestStatus(CommonEnum.AUTH_TYPE_UNDEREVIEW.getType());
qyzxEntInfoM.setId(userBean.getOrgCode());
qyzxEntInfoM.updateById();
// }
return ResultUtil.data(qyzxEntAuth, "申请企业认证中");
return ResultUtil.data(qyzxEntInfoM, "申请企业认证中");
}
/**
......@@ -144,22 +160,18 @@ public class QyzxController {
* @param qyzxEntAuth
* @return
*/
@PostMapping(value = "/entauthcheck")
@ApiOperation(value = "企业认证-审核-通过/未通过", httpMethod = "POST", notes = "接口发布说明")
public Result<QyzxEntAuth> entauthcheck1(@CurrentUser UserBean userBean, @RequestBody QyzxEntAuth qyzxEntAuth) {
Integer id = qyzxEntAuth.getId();
Integer authType = qyzxEntAuth.getAuthType();
if (id == null || authType == null) {
return ResultUtil.error("参数缺少/异常");
}
QyzxEntAuth entAuth = QyzxEntAuth.builder().id(id).authType(authType).build();
boolean b = entAuth.updateById();
if (b) {
return ResultUtil.data(qyzxEntAuth, "企业认证-审批成功");
} else {
return ResultUtil.error("企业认证-审批失败");
}
}
/*
* @PostMapping(value = "/entauthcheck")
*
* @ApiOperation(value = "企业认证-审核-通过/未通过", httpMethod = "POST", notes =
* "接口发布说明") public Result<QyzxEntAuth> entauthcheck1(@CurrentUser UserBean
* userBean, @RequestBody QyzxEntAuth qyzxEntAuth) { Integer id =
* qyzxEntAuth.getId(); Integer authType = qyzxEntAuth.getAuthType(); if (id ==
* null || authType == null) { return ResultUtil.error("参数缺少/异常"); } QyzxEntAuth
* entAuth = QyzxEntAuth.builder().id(id).authType(authType).build(); boolean b
* = entAuth.updateById(); if (b) { return ResultUtil.data(qyzxEntAuth,
* "企业认证-审批成功"); } else { return ResultUtil.error("企业认证-审批失败"); } }
*/
/**
* 运营管理 企业认证-审核-通过/不通过(weng)
......@@ -167,22 +179,18 @@ public class QyzxController {
* @param qyzxEntAuth
* @return
*/
@PostMapping(value = "/entauthpass")
@ApiOperation(value = "企业认证-审核-通过", httpMethod = "POST", notes = "接口发布说明")
public Result<String> entauthpass(@RequestBody EntauthDto entauthDto) {// 2未通过,3通过
String msg = "企业认证不通过";
Integer type = entauthDto.getAuthType();
if (type != 2) {
type = 3;
msg = "企业认证成功";
}
boolean b = new LambdaUpdateChainWrapper<QyzxEntAuth>(qyzxEntAuthMapper)
.eq(QyzxEntAuth::getId, entauthDto.getOrgCode()).set(QyzxEntAuth::getAuthType, type).update();
if (b) {
return ResultUtil.data(msg);
}
return ResultUtil.error("企业认证未通过");
}
/*
* @PostMapping(value = "/entauthpass")
*
* @ApiOperation(value = "企业认证-审核-通过", httpMethod = "POST", notes = "接口发布说明")
* public Result<String> entauthpass(@RequestBody EntauthDto entauthDto) {//
* 2未通过,3通过 String msg = "企业认证不通过"; Integer type = entauthDto.getAuthType(); if
* (type != 2) { type = 3; msg = "企业认证成功"; } boolean b = new
* LambdaUpdateChainWrapper<QyzxEntAuth>(qyzxEntAuthMapper)
* .eq(QyzxEntAuth::getId,
* entauthDto.getOrgCode()).set(QyzxEntAuth::getAuthType, type).update(); if (b)
* { return ResultUtil.data(msg); } return ResultUtil.error("企业认证未通过"); }
*/
/**
* 显示企业的超级管理员
......@@ -592,26 +600,7 @@ public class QyzxController {
return ResultUtil.data(page, logBuyDto, "查询成功");
}
/**
* 添加/修改企业信息
*
* @param
* @return
*/
@PostMapping(value = "/ent")
@ApiOperation(value = "添加/修改企业信息", httpMethod = "POST", notes = "接口发布说明")
public Result<QyzxEntInfoM> addent(@CurrentUser UserBean userBean, @RequestBody QyzxEntInfoM qyzxEntInfoM) {
qyzxEntInfoM.insertOrUpdate();
Integer count = qyzxEmpEntAssoMapper.selectCount(new QueryWrapper<QyzxEmpEntAsso>()
.eq("emp_num", userBean.getEmpNum()).eq("org_code", qyzxEntInfoM.getId()));
if (count == null || count <= 0)
QyzxEmpEntAsso.builder().empNum(userBean.getEmpNum()).orgCode(qyzxEntInfoM.getId()).userType(1).status(1)
.build().insert();
// 添加关联表
QyzxEmpEntAsso.builder().empNum(userBean.getEmpNum()).orgCode(qyzxEntInfoM.getId()).userType(1).build()
.insertOrUpdate();
return ResultUtil.data(qyzxEntInfoM, "添加/修改企业");
}
/**
* 账号管理 获取账号
......
......@@ -40,6 +40,7 @@ import com.baomidou.mybatisplus.extension.service.additional.update.impl.LambdaU
import com.github.pagehelper.util.StringUtil;
import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport;
import cn.hutool.Hutool;
import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.date.BetweenFormater.Level;
import cn.hutool.core.date.DateUtil;
......@@ -240,15 +241,16 @@ public class YgglController {
// 添加三张表
// 员工权限表(未定)
// 员工企业关联表和员工档案,员工成长表(未定)
QyzxEmpEntAsso.builder().empNum(qyzxEmpLogin.getId()).orgCode(orgCode).userType(CommonEnum.U_TYPE_EMP.getType()).status(1).build().insert();// usertype2普通员工 status1正常
QyzxEmpEntAsso.builder().empNum(qyzxEmpLogin.getId()).orgCode(orgCode)
.userType(CommonEnum.U_TYPE_EMP.getType()).status(1).build().insert();// usertype2普通员工 status1正常
YgglMainEmp ygglMainEmp = YgglMainEmp.builder().name(name).phone(phone).zjType(zjType).zjNum(zjNum)
.jobType(jobType).rzTime(rzTime).syq(syq).sex(sex).empNum(qyzxEmpLogin.getId()).orgCode(orgCode)
.build();
ygglMainEmp.insert();
new LambdaUpdateChainWrapper<YgglMainEmp>(ygglMainEmpMapper)
.set(addygdaDto.getBmgwId()!=null, YgglMainEmp::getBmgwId, addygdaDto.getBmgwId())
.eq(YgglMainEmp::getOrgCode, orgCode).eq(YgglMainEmp::getId, ygglMainEmp.getId()).update();
.set(addygdaDto.getBmgwId() != null, YgglMainEmp::getBmgwId, addygdaDto.getBmgwId())
.eq(YgglMainEmp::getOrgCode, orgCode).eq(YgglMainEmp::getId, ygglMainEmp.getId()).update();
return ResultUtil.data(ygglMainEmp, "新添加员工档案成功!");
} else {
......@@ -258,14 +260,15 @@ public class YgglController {
if (ishad == null) {
// 添加三张表
// 员工权限表(未定)
QyzxEmpEntAsso.builder().empNum(login.getId()).orgCode(orgCode).userType(2).status(1).build().insert();// usertype2普通员工 status1正常
QyzxEmpEntAsso.builder().empNum(login.getId()).orgCode(orgCode).userType(2).status(1).build().insert();// usertype2普通员工
// status1正常
YgglMainEmp ygglMainEmp = YgglMainEmp.builder().name(name).phone(phone).zjType(zjType).zjNum(zjNum)
.jobType(jobType).rzTime(rzTime).syq(syq).sex(sex).empNum(login.getId()).orgCode(orgCode)
.build();
ygglMainEmp.insert();
new LambdaUpdateChainWrapper<YgglMainEmp>(ygglMainEmpMapper)
.set(addygdaDto.getBmgwId()!=null, YgglMainEmp::getBmgwId, addygdaDto.getBmgwId())
.eq(YgglMainEmp::getOrgCode, orgCode).eq(YgglMainEmp::getId, ygglMainEmp.getId()).update();
.set(addygdaDto.getBmgwId() != null, YgglMainEmp::getBmgwId, addygdaDto.getBmgwId())
.eq(YgglMainEmp::getOrgCode, orgCode).eq(YgglMainEmp::getId, ygglMainEmp.getId()).update();
return ResultUtil.data(ygglMainEmp, "添加员工档案成功!");
} else {
return ResultUtil.error("该手机号已被使用,请输入正确手机号");
......@@ -403,8 +406,8 @@ public class YgglController {
.eq("phone", e.getPhone()).eq("org_code", userBean.getOrgCode()));
if (ishad == null) {
// 员工权限表(未定)
QyzxEmpEntAsso.builder().empNum(login.getId()).orgCode(userBean.getOrgCode()).userType(2).status(1).build()
.insert();// userType2普通员工,status1正常
QyzxEmpEntAsso.builder().empNum(login.getId()).orgCode(userBean.getOrgCode()).userType(2).status(1)
.build().insert();// userType2普通员工,status1正常
YgglMainEmp emp = YgglMainEmp.builder().name(e.getName()).phone(e.getPhone()).zjType(0)
.zjNum(e.getZj()).jobType(jobType).rzTime(rzdate).updateTime(new Date())
.updateMan(userBean.getEmpNum()).syq(syq).sex(sex).jobNum(jobNum).empNum(login.getId())
......@@ -1505,44 +1508,70 @@ public class YgglController {
*
* @param
* @return
*//*
* @PostMapping(value = "/jg")
*
* @ApiOperation(value = "展示籍贯所有省市区", httpMethod = "POST", notes = "接口发布说明")
*
* @ApiOperationSupport(order = 60) public Result<List<YgjgDto>>
* selectjgs(@CurrentUser UserBean userBean, @RequestBody YgjgDto ygjgDto) {
* Integer type = ygjgDto.getType(); Integer upId = ygjgDto.getJgid();
* List<YgjgDto> maps = new ArrayList<YgjgDto>(); if (type == 1) { // 省份
* List<YgProDto> list = new LambdaQueryChainWrapper<YgProDto>(ygProDtoMapper)
* .select(YgProDto::getId, YgProDto::getProvince,
* YgProDto::getName).orderByAsc(YgProDto::getProvince) .list(); for (YgProDto
* pro : list) { maps.add(new YgjgDto(pro.getId(), pro.getProvince(),
* pro.getName(), null)); } } if (type == 2) { // 城市 List<YgCityDto> list = new
* LambdaQueryChainWrapper<YgCityDto>(ygCityDtoMapper) .select(YgCityDto::getId,
* YgCityDto::getCity, YgCityDto::getName).eq(YgCityDto::getProvince, upId)
* .orderByAsc(YgCityDto::getProvince).orderByAsc(YgCityDto::getCity).list();
* for (YgCityDto city : list) { maps.add(new YgjgDto(city.getId(),
* city.getCity(), city.getName(), null)); } } if (type == 3) { // 地区
* List<YgAreaDto> list = new
* LambdaQueryChainWrapper<YgAreaDto>(ygAreaDtoMapper) .select(YgAreaDto::getId,
* YgAreaDto::getName).eq(YgAreaDto::getCity, upId)
* .orderByAsc(YgAreaDto::getProvince).orderByAsc(YgAreaDto::getCity).list();
* for (YgAreaDto area : list) { maps.add(new YgjgDto(area.getId(),
* area.getId(), area.getName(), null)); } } // IYgjgDto iYgjgDto =
* PunishFactory.getPunish(type); // List<String> strings =
* iYgjgDto.exePunish(); // System.out.println(strings); if (!maps.isEmpty())
* return ResultUtil.data(maps, "展示籍贯成功"); return ResultUtil.success(null); }
*/
/**
* 展示籍贯/展示所有籍贯(威力增强版)
*
* @param
* @return
*/
@PostMapping(value = "/jg")
@ApiOperation(value = "展示籍贯所有省市区", httpMethod = "POST", notes = "接口发布说明")
@ApiOperationSupport(order = 60)
public Result<List<YgjgDto>> selectjgs(@CurrentUser UserBean userBean, @RequestBody YgjgDto ygjgDto) {
Integer type = ygjgDto.getType();
Integer upId = ygjgDto.getJgid();
List<YgjgDto> maps = new ArrayList<YgjgDto>();
if (type == 1) { // 省份
@PostMapping(value = "/jgshow")
@ApiOperation(value = "展示籍贯所有省市区威力增强版", httpMethod = "POST", notes = "接口发布说明")
@ApiOperationSupport(order = 388)
public Result<Map<String, String>> selectjgs1(@CurrentUser UserBean userBean, @RequestBody String jgid) {
// public Result<List<YgjgDto>> selectjgs1(@CurrentUser UserBean userBean,
// @RequestBody YgjgDto ygjgDto) {
Integer upId = Integer.valueOf(jgid);
// List<YgjgDto> maps = new ArrayList<YgjgDto>();
Map<String, String> maps = new HashMap<String, String>();
if (upId == null || upId % 100 != 0) { // 省份
List<YgProDto> list = new LambdaQueryChainWrapper<YgProDto>(ygProDtoMapper)
.select(YgProDto::getId, YgProDto::getProvince, YgProDto::getName).orderByAsc(YgProDto::getProvince)
.list();
for (YgProDto pro : list) {
maps.add(new YgjgDto(pro.getId(), pro.getProvince(), pro.getName(), null));
}
}
if (type == 2) { // 城市
list.forEach((item) -> maps.put((item.getId()).toString(), item.getName()));
} else if (upId % 10000 == 0) {
List<YgCityDto> list = new LambdaQueryChainWrapper<YgCityDto>(ygCityDtoMapper)
.select(YgCityDto::getId, YgCityDto::getCity, YgCityDto::getName).eq(YgCityDto::getProvince, upId)
.orderByAsc(YgCityDto::getProvince).orderByAsc(YgCityDto::getCity).list();
for (YgCityDto city : list) {
maps.add(new YgjgDto(city.getId(), city.getCity(), city.getName(), null));
}
}
if (type == 3) { // 地区
.select(YgCityDto::getId, YgCityDto::getProvince, YgCityDto::getCity, YgCityDto::getName)
.eq(YgCityDto::getProvince, upId).orderByAsc(YgCityDto::getProvince).orderByAsc(YgCityDto::getCity)
.list();
list.forEach((item) -> maps.put((item.getId()).toString(), item.getName()));
} else if (upId % 100 == 0) {
List<YgAreaDto> list = new LambdaQueryChainWrapper<YgAreaDto>(ygAreaDtoMapper)
.select(YgAreaDto::getId, YgAreaDto::getName).eq(YgAreaDto::getCity, upId)
.orderByAsc(YgAreaDto::getProvince).orderByAsc(YgAreaDto::getCity).list();
for (YgAreaDto area : list) {
maps.add(new YgjgDto(area.getId(), area.getId(), area.getName(), null));
}
list.forEach((item) -> maps.put((item.getId()).toString(), item.getName()));
}
// IYgjgDto iYgjgDto = PunishFactory.getPunish(type);
// List<String> strings = iYgjgDto.exePunish();
// System.out.println(strings);
if (!maps.isEmpty())
return ResultUtil.data(maps, "展示籍贯成功");
return ResultUtil.success(null);
return ResultUtil.data(maps, "展示籍贯成功");
}
/**
......@@ -1551,7 +1580,7 @@ public class YgglController {
* @param
* @return
*/
@PostMapping(value = "/jgp")
@PostMapping(value = "/jgprint")
@ApiOperation(value = "根据籍贯id显示籍贯城市名", httpMethod = "POST", notes = "接口发布说明")
@ApiOperationSupport(order = 61)
public Result<YgjgDto> selectjg(@CurrentUser UserBean userBean, @RequestBody YgjgDto jgcity) {
......@@ -1672,6 +1701,7 @@ public class YgglController {
/**
* 员工信息统计图
*
* @return 成功信息(weng)
*/
@GetMapping("/Cartogram")
......@@ -1689,51 +1719,55 @@ public class YgglController {
* (bean.getWorkage() == null) { bean.setWorkage(-1); } return true;
* }).collect(Collectors.toList());
*/
Map<String, Long> gw = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getGw,Collectors.counting()));
Map<String, Long> gw = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getGw, Collectors.counting()));
List<YgKVDto> gwList = new ArrayList<YgKVDto>();
for(Map.Entry<String, Long> entry : gw.entrySet()) {
gwList.add(new YgKVDto(entry.getKey(),entry.getValue().toString()));
for (Map.Entry<String, Long> entry : gw.entrySet()) {
gwList.add(new YgKVDto(entry.getKey(), entry.getValue().toString()));
}
Map<String, Long> bm = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getBm,Collectors.counting()));
Map<String, Long> bm = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getBm, Collectors.counting()));
List<YgKVDto> bmList = new ArrayList<YgKVDto>();
for(Map.Entry<String, Long> entry : bm.entrySet()) {
bmList.add(new YgKVDto(entry.getKey(),entry.getValue().toString()));
for (Map.Entry<String, Long> entry : bm.entrySet()) {
bmList.add(new YgKVDto(entry.getKey(), entry.getValue().toString()));
}
//Map<String, Map<String, Long>> bmgw = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getBm,Collectors.groupingBy(YgbintuDto::getGw,Collectors.counting())));
Map<String, Long> edu = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getEduname,Collectors.counting()));
// Map<String, Map<String, Long>> bmgw =
// bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getBm,Collectors.groupingBy(YgbintuDto::getGw,Collectors.counting())));
Map<String, Long> edu = bintu.stream()
.collect(Collectors.groupingBy(YgbintuDto::getEduname, Collectors.counting()));
List<YgKVDto> eduList = new ArrayList<YgKVDto>();
for(Map.Entry<String, Long> entry : edu.entrySet()) {
eduList.add(new YgKVDto(entry.getKey(),entry.getValue().toString()));
for (Map.Entry<String, Long> entry : edu.entrySet()) {
eduList.add(new YgKVDto(entry.getKey(), entry.getValue().toString()));
}
Map<Integer,Long> jobStatus = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getJobStatus,Collectors.counting()));
Map<Integer, Long> jobStatus = bintu.stream()
.collect(Collectors.groupingBy(YgbintuDto::getJobStatus, Collectors.counting()));
List<YgKVDto> jobStatusList = new ArrayList<YgKVDto>();
for(Entry<Integer, Long> entry : jobStatus.entrySet()) {
jobStatusList.add(new YgKVDto(entry.getKey().toString(),entry.getValue().toString()));
for (Entry<Integer, Long> entry : jobStatus.entrySet()) {
jobStatusList.add(new YgKVDto(entry.getKey().toString(), entry.getValue().toString()));
}
Map<String, Long> proname = bintu.stream().collect(Collectors.groupingBy(YgbintuDto::getProname,Collectors.counting()));
Map<String, Long> proname = bintu.stream()
.collect(Collectors.groupingBy(YgbintuDto::getProname, Collectors.counting()));
List<YgKVDto> pronameList = new ArrayList<YgKVDto>();
for(Entry<String, Long> entry : proname.entrySet()) {
pronameList.add(new YgKVDto(entry.getKey().toString(),entry.getValue().toString()));
for (Entry<String, Long> entry : proname.entrySet()) {
pronameList.add(new YgKVDto(entry.getKey().toString(), entry.getValue().toString()));
}
Map<String, Integer> workage = YgEnumInterface.workage.choose(bintu);
List<YgKVDto> workageList = new ArrayList<YgKVDto>();
for(Entry<String, Integer> entry : workage.entrySet()) {
workageList.add(new YgKVDto(entry.getKey().toString(),entry.getValue().toString()));
for (Entry<String, Integer> entry : workage.entrySet()) {
workageList.add(new YgKVDto(entry.getKey().toString(), entry.getValue().toString()));
}
Map<String, Integer> age = YgEnumInterface.age.choose(bintu);
List<YgKVDto> ageList = new ArrayList<YgKVDto>();
for(Entry<String, Integer> entry : age.entrySet()) {
ageList.add(new YgKVDto(entry.getKey().toString(),entry.getValue().toString()));
for (Entry<String, Integer> entry : age.entrySet()) {
ageList.add(new YgKVDto(entry.getKey().toString(), entry.getValue().toString()));
}
//在职
Integer zaizhi = jobStatus.get(1).intValue()+jobStatus.get(2).intValue();
//本月新入职
// 在职
Integer zaizhi = jobStatus.get(1).intValue() + jobStatus.get(2).intValue();
// 本月新入职
Integer xinruzhi = workage.get("本月新入职").intValue();
//本月离职
// 本月离职
Integer lizhi = ygglMainEmpMapper.benyueLz(orgCode);
//本月转正
// 本月转正
Integer zhuanzhen = ygglMainEmpMapper.benyueZz(orgCode);
//平均年龄
// 平均年龄
Integer nianlin = age.get("平均年龄").intValue();
YgCartogramDto ybp = new YgCartogramDto();
ybp.setOnTheJob(zaizhi);
......@@ -1741,7 +1775,7 @@ public class YgglController {
ybp.setDimission(lizhi);
ybp.setRegularization(zhuanzhen);
ybp.setAverageAge(nianlin);
ybp.setDepartment(bmList);
ybp.setPosition(gwList);
ybp.setEdu(eduList);
......@@ -1751,6 +1785,7 @@ public class YgglController {
ybp.setAge(ageList);
return ResultUtil.data(ybp, "获取员工管理统计图信息成功!");
}
/**
* 获取员工社保公积金
*
......
......@@ -21,6 +21,11 @@
<result column="is_on_stock" property="isOnStock" />
<result column="level" property="level" />
<result column="register_time" property="registerTime" />
<result column="license_url" property="licenseUrl" />
<result column="area" property="area" />
<result column="attest_name" property="attestName" />
<result column="attest_status" property="attestStatus" />
<result column="attest_time" property="attestTime" />
</resultMap>
<sql id="Base_Column_List">
......@@ -40,7 +45,12 @@
credit_code,
is_on_stock,
level,
register_time
register_time,
license_url,
area,
attest_name,
attest_status,
attest_time
</sql>
<!--
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment