| | |
| | | import com.product.quartz.service.impl.SysJobService; |
| | | import com.product.util.BaseUtil; |
| | | import com.product.util.SystemParamReplace; |
| | | import com.product.util.UnifySQLFunction; |
| | | |
| | | import org.apache.commons.codec.binary.Base64; |
| | | import org.quartz.SchedulerException; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | StaffManagerService staffManagerService; |
| | | |
| | | public void sendWarnFeedBackMessage(FieldSetEntity fse) throws BaseException { |
| | | String userId = String.valueOf(SpringMVCContextHolder.getCurrentUser().getUser_id()); |
| | | fse.setValue( CmnConst.USER_ID,userId);//当前人作为消息发送人,其它预警接收人作为收消息人 |
| | | String parent_uuid = fse.getString("puuid"); |
| | | Set<String> receiverSet = this.getReceiver(fse.getString("parent_uuid")); |
| | | if (StringUtils.isEmpty(parent_uuid)) { |
| | |
| | | if (!StringUtils.isEmpty(leaderUserId)) { |
| | | receiverSet.add(leaderUserId); |
| | | } |
| | | String userId = String.valueOf(SpringMVCContextHolder.getCurrentUser().getUser_id()); |
| | | receiverSet.remove(userId); |
| | | if(receiverSet.isEmpty()){ |
| | | logger.error("发送消息,失败"); |
| | |
| | | sql.append("\n select org_level_code from product_sys_staffs sc inner join product_sys_org_levels d on sc.dept_uuid=d.uuid and sc.is_dept_manage=1 and user_id=?"); |
| | | sql.append("\n ) o on s.tricode like concat(o.org_level_code,'%')"); |
| | | sql.append("\n union all"); |
| | | sql.append("\n select ? from dual"); |
| | | sql.append("\n ").append(UnifySQLFunction.dualFunction("?")); |
| | | sql.append("\n) u on concat(',',i.receiver,',') like concat('%,',u.user_id,',%')"); |
| | | sql.append("\nwhere early_warning_uuid is not null"); |
| | | |