Merge branch 'dev' into test
This commit is contained in:
commit
83dd51fb1c
|
|
@ -24,9 +24,15 @@ public class SysNoticeController {
|
|||
|
||||
@ApiOperation(value = "查询通知公告列表")
|
||||
@GetMapping("/getList")
|
||||
public AjaxResult getList(@RequestParam(required = false, defaultValue = "", value = "keyword") String keyword)
|
||||
{
|
||||
public AjaxResult getList(@RequestParam(required = false, defaultValue = "", value = "keyword") String keyword) {
|
||||
List<SysNotice> list = service.getList(keyword);
|
||||
return AjaxResult.success("操作成功",list);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查询通知公告详细")
|
||||
@GetMapping("/getById")
|
||||
public AjaxResult getById(@RequestParam(required = false, defaultValue = "", value = "noticeId") Long noticeId) {
|
||||
SysNotice bean = service.getById(noticeId);
|
||||
return AjaxResult.success("操作成功",bean);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,4 +17,6 @@ public interface SysNoticeMapper {
|
|||
* @return
|
||||
*/
|
||||
List<SysNotice> getList(String keyword);
|
||||
|
||||
SysNotice getById(Long noticeId);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -15,4 +15,6 @@ public interface SysNoticeService {
|
|||
* @return
|
||||
*/
|
||||
List<SysNotice> getList(String keyword);
|
||||
|
||||
SysNotice getById(Long noticeId);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,4 +29,14 @@ public class SysNoticeServiceImpl implements SysNoticeService {
|
|||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
@Override
|
||||
public SysNotice getById(Long noticeId) {
|
||||
SysNotice bean = mapper.getById(noticeId);
|
||||
if (bean.getNoticeContent() != null){
|
||||
String noticeContent = Base64.getEncoder().encodeToString(bean.getNoticeContent());
|
||||
bean.setNoticeContentStr(noticeContent);
|
||||
}
|
||||
return bean;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -21,4 +21,18 @@
|
|||
</if>
|
||||
order by create_time desc
|
||||
</select>
|
||||
<select id="getById" resultType="com.bonus.sgzb.app.domain.SysNotice">
|
||||
select notice_id as noticeId,
|
||||
notice_title as noticeTitle,
|
||||
notice_type as noticeType,
|
||||
notice_content as noticeContent,
|
||||
status as status,
|
||||
create_by as createBy,
|
||||
create_time as createTime,
|
||||
update_by as updateBy,
|
||||
update_time as updateTime,
|
||||
remark as remark
|
||||
from sys_notice
|
||||
where status = '0' and notice_id = #{noticeId}
|
||||
</select>
|
||||
</mapper>
|
||||
|
|
|
|||
|
|
@ -82,4 +82,6 @@ public interface RepairAuditDetailsMapper
|
|||
int insertRepairDetails(RepairTaskDetails repairTaskDetails);
|
||||
|
||||
Long getBackId(Long repairId);
|
||||
|
||||
List<RepairAuditDetails> selectnotAuditByTaskId(Long taskId);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -172,6 +172,7 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
|
|||
}
|
||||
|
||||
List<RepairAuditDetails> auditAllList = repairAuditDetailsMapper.selectRepairAuditDetailsByTaskId(taskId);
|
||||
List<RepairAuditDetails> notAuditList = repairAuditDetailsMapper.selectnotAuditByTaskId(taskId);
|
||||
// 查询协议表
|
||||
TmTaskAgreement tmTaskAgreement = agreementMapper.selectTmTaskAgreementByTaskId(taskId);
|
||||
String taskCode ="";
|
||||
|
|
@ -241,7 +242,6 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
|
|||
// 创建报废任务
|
||||
BigDecimal scrapNum = scrapDetails.getScrapNum();
|
||||
if (scrapNum.compareTo(b) > 0) {
|
||||
// 添加退料任务
|
||||
ScrapApplyDetails scrapApplyDetails = new ScrapApplyDetails();
|
||||
scrapApplyDetails.setTaskId(scrapTaskId);
|
||||
scrapApplyDetails.setTypeId(typeId);
|
||||
|
|
@ -258,17 +258,15 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
|
|||
|
||||
}
|
||||
// 修饰审核通过时改修任务为已通过审核
|
||||
int i = 0;
|
||||
int j = 0;
|
||||
if (repairInputList != null){
|
||||
i = repairInputList.size();
|
||||
}
|
||||
if (scrapNumList != null){
|
||||
j = scrapNumList.size();
|
||||
}
|
||||
if (auditAllList.size() == (i + j)){
|
||||
if (auditDetailList != null){
|
||||
if (auditDetailList.size() == notAuditList.size()){
|
||||
task1.setTaskStatus(47);
|
||||
}
|
||||
}else if (auditAllList != null){
|
||||
if (auditAllList.size() == notAuditList.size()){
|
||||
task1.setTaskStatus(47);
|
||||
}
|
||||
}
|
||||
task1.setUpdateTime(new Date());
|
||||
task1.setUpdateBy(String.valueOf(SecurityUtils.getLoginUser().getUserid()));
|
||||
taskMapper.updateTmTask(task1);
|
||||
|
|
@ -280,7 +278,7 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
|
|||
}else {
|
||||
repairDetailList.addAll(auditAllList);
|
||||
}
|
||||
if(repairDetailList != null && repairDetailList.size() > 0){
|
||||
if(repairDetailList.size() > 0){
|
||||
if (repairDetailList.get(0).getCompanyId() != null){
|
||||
companyId = repairDetailList.get(0).getCompanyId();
|
||||
}
|
||||
|
|
@ -309,8 +307,7 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
|
|||
TmTask tmTask = new TmTask();
|
||||
tmTask.setTaskId(taskId);
|
||||
tmTask.setRemark(scrapAudit.getRemark());
|
||||
int i = repairDetailList.size();
|
||||
if (auditAllList.size() == i){
|
||||
if (repairDetailList.size() == notAuditList.size()){
|
||||
tmTask.setTaskStatus(48);
|
||||
}
|
||||
tmTask.setUpdateTime(new Date());
|
||||
|
|
@ -326,6 +323,7 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
|
|||
}
|
||||
}
|
||||
}else {
|
||||
if (auditAllList != null) {
|
||||
for (RepairAuditDetails bean : auditAllList){
|
||||
bean.setAuditBy(SecurityUtils.getLoginUser().getUserid());
|
||||
bean.setStatus(status);
|
||||
|
|
@ -333,6 +331,7 @@ public class RepairAuditDetailsServiceImpl implements IRepairAuditDetailsService
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -295,7 +295,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
dic.NAME taskStatusName,
|
||||
bui.unit_name unitName,
|
||||
bpl.lot_name projectName,
|
||||
tk.create_by createBy,
|
||||
su.user_name createBy,
|
||||
tk.create_time createTime,
|
||||
tk.remark,
|
||||
tk.CODE repairNum,
|
||||
|
|
@ -324,6 +324,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
LEFT JOIN ma_type mt ON rad.type_id = mt.type_id
|
||||
LEFT JOIN ma_type mt1 ON mt.parent_id = mt1.type_id
|
||||
left join ma_machine mma on rad.ma_id= mma.ma_id
|
||||
LEFT JOIN sys_user su ON su.user_id = tk.create_by
|
||||
WHERE
|
||||
tk.task_type = 45
|
||||
<if test="keyword != null and keyword != ''">
|
||||
|
|
@ -382,5 +383,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
from repair_apply_details
|
||||
where id = #{repairId}
|
||||
</select>
|
||||
<select id="selectnotAuditByTaskId" resultType="com.bonus.sgzb.material.domain.RepairAuditDetails">
|
||||
<include refid="selectRepairAuditDetailsVo"/>
|
||||
where task_id = #{taskId} and rd.STATUS = '0'
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
|
|
@ -59,7 +59,7 @@ public class SysProfileController extends BaseController {
|
|||
*/
|
||||
@GetMapping
|
||||
public AjaxResult profile() {
|
||||
String username = SecurityUtils.getUsername();
|
||||
String username = SecurityUtils.getLoginUser().getUsername();
|
||||
SysUser user = userService.selectUserByUserName(username);
|
||||
AjaxResult ajax = AjaxResult.success(user);
|
||||
ajax.put("roleGroup", userService.selectUserRoleGroup(username));
|
||||
|
|
|
|||
|
|
@ -19,25 +19,26 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||
</insert>
|
||||
|
||||
<select id="selectLogininforList" parameterType="com.bonus.sgzb.system.api.domain.SysLogininfor" resultMap="SysLogininforResult">
|
||||
select info_id, user_name, ipaddr, status, msg, access_time from sys_logininfor
|
||||
<where>
|
||||
select sl.info_id, sl.user_name, su.nick_name, sl.ipaddr, sl.status, sl.msg, sl.access_time
|
||||
from sys_logininfor as sl left join sys_user as su
|
||||
on sl.user_name = su.user_name
|
||||
WHERE 1=1
|
||||
<if test="ipaddr != null and ipaddr != ''">
|
||||
AND ipaddr like concat('%', #{ipaddr}, '%')
|
||||
AND sl.ipaddr like concat('%', #{ipaddr}, '%')
|
||||
</if>
|
||||
<if test="status != null and status != ''">
|
||||
AND status = #{status}
|
||||
AND sl.status = #{status}
|
||||
</if>
|
||||
<if test="userName != null and userName != ''">
|
||||
AND user_name like concat('%', #{userName}, '%')
|
||||
AND sl.user_name like concat('%', #{userName}, '%')
|
||||
</if>
|
||||
<if test="params.beginTime != null and params.beginTime != ''"><!-- 开始时间检索 -->
|
||||
AND access_time >= #{params.beginTime}
|
||||
AND sl.access_time >= #{params.beginTime}
|
||||
</if>
|
||||
<if test="params.endTime != null and params.endTime != ''"><!-- 结束时间检索 -->
|
||||
AND access_time <= #{params.endTime}
|
||||
AND sl.access_time <= #{params.endTime}
|
||||
</if>
|
||||
</where>
|
||||
order by info_id desc
|
||||
order by sl.info_id desc
|
||||
</select>
|
||||
|
||||
<delete id="deleteLogininforByIds" parameterType="Long">
|
||||
|
|
|
|||
Loading…
Reference in New Issue