[修改] 报告编辑流程

This commit is contained in:
bupengxiang
2023-05-15 17:51:40 +08:00
parent d8af4b7a03
commit 664efab332
12 changed files with 48 additions and 5 deletions
@@ -146,7 +146,10 @@ public class ITtReportManageActServiceImpl extends ServiceImpl<TtReportManageAct
ReportEntity reportEntity1 = new ReportEntity();
BeanUtil.copyProperties(ttReportManageAct,reportEntity1);
reportEntity1.setId(ttReportManageAct.getDataId());
reportDao.updateById(reportEntity);
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
reportEntity1.setCreateDate(sdf.format(ttReportManageAct.getCreateDate()));
reportEntity1.setUpdateDate(sdf.format(ttReportManageAct.getUpdateDate()));
reportDao.updateById(reportEntity1);
reportLog(reportEntity.getName(),"修改");
}
try {
@@ -5,6 +5,7 @@ import com.adc.da.excel.poi.excel.ExcelImportUtil;
import com.adc.da.excel.poi.excel.entity.ImportParams;
import com.adc.da.sys.constant.SysConstants;
import com.adc.da.sys.dao.mysql.UserOrgEODao;
import com.adc.da.sys.entity.OrgEO;
import com.adc.da.sys.entity.UserEO;
import com.adc.da.sys.entity.UserOrgEO;
import com.adc.da.sys.service.iservice.IUserEoService;
@@ -240,4 +241,13 @@ public class UserEOController extends BaseController<UserEO> {
}
@ApiOperation(value = "查询自己领导")
@GetMapping("getOwnLeader")
public ResponseMessage getOwnLeader(String userId){
UserEO userEoById = userEOService.getUserEoById(userId);
List<OrgEO> orgEOList = userEoById.getOrgEOList();
List<UserEO> leaderList = userEOService.getOwnLeader(orgEOList);
return Result.success(leaderList);
}
}
@@ -1,5 +1,6 @@
package com.adc.da.sys.dao.mysql;
import com.adc.da.sys.entity.OrgEO;
import com.adc.da.sys.entity.UserEO;
import com.adc.da.sys.vo.UserVO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
@@ -44,4 +45,6 @@ public interface UserEODao extends BaseMapper<UserEO> {
UserEO getUserEoById(@Param("usid") String usid);
UserEO selectUserByIdNodel(String userId);
List<UserEO> getOwnLeader(@Param("Vo") List<OrgEO> orgEOList);
}
@@ -149,4 +149,6 @@ public class UserEO extends BaseEntity implements Serializable {
@TableField(exist = false)
private String roleId;
@TableField("EMPLOYEE_TYPE_ID")
private String employeeTypeId;
}
@@ -5,10 +5,7 @@ import com.adc.da.sys.constant.UserBelongEnum;
import com.adc.da.sys.dao.mysql.UserEODao;
import com.adc.da.sys.dao.mysql.UserOrgEODao;
import com.adc.da.sys.dao.mysql.UserRoleEODao;
import com.adc.da.sys.entity.RoleEO;
import com.adc.da.sys.entity.UserEO;
import com.adc.da.sys.entity.UserOrgEO;
import com.adc.da.sys.entity.UserRoleEO;
import com.adc.da.sys.entity.*;
import com.adc.da.sys.service.iservice.IUserEoService;
import com.adc.da.sys.util.EncryptUtil;
import com.adc.da.sys.vo.UserImportVO;
@@ -335,6 +332,11 @@ public class UserEOServiceImpl implements IUserEoService {
return dao.selectUserByIdNodel(userId);
}
@Override
public List<UserEO> getOwnLeader(List<OrgEO> orgEOList) {
return dao.getOwnLeader(orgEOList);
}
void checkExcel(List<UserImportVO> list) {
if (CollectionUtils.isEmpty(list)) {
throw new AdcDaBaseException("数据不能为空");
@@ -1,5 +1,6 @@
package com.adc.da.sys.service.iservice;
import com.adc.da.sys.entity.OrgEO;
import com.adc.da.sys.entity.UserEO;
import com.adc.da.sys.vo.UserImportVO;
import com.adc.da.sys.vo.UserVO;
@@ -67,4 +68,6 @@ public interface IUserEoService {
* @return
*/
UserEO getUserByIdNodel(String userId);
List<UserEO> getOwnLeader(List<OrgEO> orgEOList);
}
@@ -55,4 +55,5 @@ public class UserVO {
*/
private List<OrgEO> orgEOList = new ArrayList();
private String employeeTypeId;
}
@@ -48,9 +48,13 @@
<select id="selectCountByOrgCode" resultType="java.lang.Long">
select count(1) from TS_ORG
<where>
status = 1
<if test="pageVO.orgCode != null and pageVO.orgCode != ''">
and org_code = #{pageVO.orgCode}
</if>
<if test="pageVO.id != null and pageVO.id != ''">
and id != #{pageVO.id}
</if>
</where>
</select>
</mapper>
@@ -256,6 +256,17 @@
#{id}
</foreach>
</select>
<select id="getOwnLeader" resultType="com.adc.da.sys.entity.UserEO">
select u.* from ts_user u
LEFT JOIN tr_user_org uo on u.usid = uo.USER_ID
<where>
uo.org_id in
<foreach collection="Vo" item="item" open="(" separator="," close=")">
#{item.Id}
</foreach>
and (u.level_id=5 or u.level_id=9) and u.employee_type_id = 1
</where>
</select>
</mapper>
@@ -48,9 +48,13 @@
<select id="selectCountByOrgCode" resultType="java.lang.Long">
select count(1) from TS_ORG
<where>
status = 1
<if test="pageVO.orgCode != null and pageVO.orgCode != ''">
and org_code = #{pageVO.orgCode}
</if>
<if test="pageVO.id != null and pageVO.id != ''">
and id != #{pageVO.id}
</if>
</where>
</select>
</mapper>