From 79cb72d7b959d1cc785968be8b5f025d8526b791 Mon Sep 17 00:00:00 2001 From: yangjun <1173114630@qq.com> Date: Mon, 27 Apr 2026 11:27:07 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../listener/WorkOrderMQListener.java | 18 ++ .../main/java/com/nu/dto/SysDepartDto.java | 258 ++++++++++++++++++ 2 files changed, 276 insertions(+) create mode 100644 nursing-unit-common/src/main/java/com/nu/dto/SysDepartDto.java diff --git a/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/mq/workorder/listener/WorkOrderMQListener.java b/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/mq/workorder/listener/WorkOrderMQListener.java index db90eb2..a20b1b7 100644 --- a/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/mq/workorder/listener/WorkOrderMQListener.java +++ b/nursing-unit-admin/nu-admin-biz/src/main/java/com/nu/mq/workorder/listener/WorkOrderMQListener.java @@ -3,6 +3,7 @@ package com.nu.mq.workorder.listener; import com.alibaba.fastjson.JSONObject; import com.aliyuncs.exceptions.ClientException; import com.baomidou.dynamic.datasource.toolkit.DynamicDataSourceContextHolder; +import com.nu.dto.SysDepartDto; import com.nu.dto.WorkOrderMQDto; import com.nu.entity.ErrorRecordLogEntity; import com.nu.entity.NuWxNoticeEntity; @@ -12,6 +13,7 @@ import com.nu.modules.errorrecordlog.IErrorRecordLogApi; import com.nu.modules.orgapplyinfo.entity.OrgApplyInfo; import com.nu.modules.orgapplyinfo.service.IOrgApplyInfoService; import com.nu.modules.wxnotice.IWxNoticeApi; +import com.nu.utils.RabbitMQUtil; import lombok.extern.slf4j.Slf4j; import org.jeecg.common.aspect.annotation.AutoLog; import org.jeecg.common.constant.enums.DySmsEnum; @@ -24,9 +26,11 @@ import org.springframework.amqp.rabbit.annotation.Exchange; import org.springframework.amqp.rabbit.annotation.Queue; import org.springframework.amqp.rabbit.annotation.QueueBinding; import org.springframework.amqp.rabbit.annotation.RabbitListener; +import org.springframework.beans.BeanUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; +import java.math.BigDecimal; import java.util.HashMap; import java.util.Map; @@ -42,6 +46,8 @@ public class WorkOrderMQListener { @Autowired private IWxNoticeApi wxNoticeApi; + @Autowired + private RabbitMQUtil rabbitMQUtil; /** * 工单回执 */ @@ -144,6 +150,18 @@ public class WorkOrderMQListener { sysDepartEntity.setMediaUrl(workOrderMQDto.getMediaUrl());//媒体资源路径 sysBaseAPI.updateById(sysDepartEntity); + SysDepartEntity sysDepartEntityInfo = sysBaseAPI.selectDepartById(sysDepartEntity.getId()); + + try { + SysDepartDto sysDepartDto = new SysDepartDto(); + BeanUtils.copyProperties(sysDepartEntityInfo, sysDepartDto); + sysDepartDto.setPayableAmount(BigDecimal.valueOf(8000)); + //初始化机构信息 + rabbitMQUtil.sendToExchange("hldy.org", workOrderMQDto.getOrgCode() + ".orgapply.addSysDepartDto", sysDepartDto); + } catch (Exception e) { + log.error("修改工单状态失败:{}", e.getMessage()); + } + try { //新增账号 diff --git a/nursing-unit-common/src/main/java/com/nu/dto/SysDepartDto.java b/nursing-unit-common/src/main/java/com/nu/dto/SysDepartDto.java new file mode 100644 index 0000000..8fa0dd0 --- /dev/null +++ b/nursing-unit-common/src/main/java/com/nu/dto/SysDepartDto.java @@ -0,0 +1,258 @@ +package com.nu.dto; + +import com.baomidou.mybatisplus.annotation.IdType; +import com.baomidou.mybatisplus.annotation.TableId; +import com.fasterxml.jackson.annotation.JsonFormat; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; +import org.jeecg.common.aspect.annotation.Dict; +import org.jeecgframework.poi.excel.annotation.Excel; +import org.springframework.format.annotation.DateTimeFormat; + +import java.io.Serializable; +import java.math.BigDecimal; +import java.util.Date; + +/** + *

+ * 部门表 + *

+ * + * @Author Steve + * @Since 2019-01-22 + */ +@Data +public class SysDepartDto implements Serializable { + private static final long serialVersionUID = 1L; + + /** + * ID + */ + @TableId(type = IdType.ASSIGN_ID) + private String id; + /** + * 父机构ID + */ + private String parentId; + /** + * 机构/部门名称 + */ + @Excel(name = "机构/部门名称", width = 15) + private String departName; + /** + * 英文名 + */ + @Excel(name = "英文名", width = 15) + private String departNameEn; + /** + * 缩写 + */ + private String departNameAbbr; + /** + * 排序 + */ + @Excel(name = "排序", width = 15) + private Integer departOrder; + /** + * 描述 + */ + @Excel(name = "描述", width = 15) + private String description; + /** + * 机构类型 + */ + private String orgType; + /** + * 机构编码 + */ + @Excel(name = "机构编码", width = 15) + private String orgCode; + /** + * 省份 + */ + @Excel(name = "省份", width = 30) + private String province; + /** + * 城市 + */ + @Excel(name = "城市", width = 30) + private String city; + /** + * 区县 + */ + @Excel(name = "区县", width = 30) + private String district; + /** + * 手机号 + */ + @Excel(name = "手机号", width = 15) + private String mobile; + /** + * 地址 + */ + @Excel(name = "地址", width = 15) + private String address; + /** + * 创建人 + */ + private String createBy; + /** + * 创建日期 + */ + @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private Date createTime; + /** + * 更新人 + */ + private String updateBy; + /** + * 更新日期 + */ + @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private Date updateTime; + + /** + * 加盟时间 + */ + @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + @ApiModelProperty(value = "加盟时间") + private Date franchiseTime; + /** + * 回复内容 + */ + private String headPath; + /** + * 回复时间 + */ + @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss") + @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss") + private Date replyTime; + /** + * 回复人 + */ + private String handleBy; + + /** + * 微信id + */ + @Excel(name = "微信id", width = 15) + @ApiModelProperty(value = "微信id") + private String openId; + /** + * 联系电话 + */ + @Excel(name = "联系电话", width = 15) + @ApiModelProperty(value = "联系电话") + private String tel; + /** + * 咨询人姓名 + */ + @Excel(name = "咨询人姓名", width = 15) + @ApiModelProperty(value = "咨询人姓名") + private String name; + /** + * 性别 + */ + @Excel(name = "性别", width = 15) + @ApiModelProperty(value = "性别") + private String sex; + /** + * 签发机关 + */ + @Excel(name = "签发机关", width = 15) + @ApiModelProperty(value = "签发机关") + private String issuingAuthority; + /** + * 企业名称 + */ + @Excel(name = "企业名称", width = 15) + @ApiModelProperty(value = "企业名称") + private String comName; + /** + * 企业注册地址 + */ + @Excel(name = "企业注册地址", width = 15) + @ApiModelProperty(value = "企业注册地址") + private String comRegisterAddress; + /** + * 企业信用代码 + */ + @Excel(name = "企业信用代码", width = 15) + @ApiModelProperty(value = "企业信用代码") + private String comCreditCode; + /** + * 企业法人 + */ + @Excel(name = "企业法人", width = 15) + @ApiModelProperty(value = "企业法人") + private String comLegalPerson; + /** + * 机构地址 + */ + @Excel(name = "机构地址", width = 15) + @ApiModelProperty(value = "机构地址") + private String orgAddress; + /** + * 机构负责人 + */ + @Excel(name = "机构负责人", width = 15) + @ApiModelProperty(value = "机构负责人") + private String orgLeader; + /** + * 机构负责人电话 + */ + @Excel(name = "机构负责人电话", width = 15) + @ApiModelProperty(value = "机构负责人电话") + private String orgLeaderPhone; + /** + * 机构楼宇牌号 + */ + @Excel(name = "机构楼宇牌号", width = 15) + @ApiModelProperty(value = "机构楼宇牌号") + private String orgBuildingNumber; + /** + * 机构房屋性质 + */ + @Excel(name = "机构房屋性质", width = 15) + @ApiModelProperty(value = "机构房屋性质") + private String orgPropertyType; + /** + * 机构建筑面积 + */ + @Excel(name = "机构建筑面积", width = 15) + @ApiModelProperty(value = "机构建筑面积") + private Double orgBuildingArea; + /** + * 机构省份 sys_category.id + */ + @Excel(name = "机构省份", width = 15) + @ApiModelProperty(value = "机构省份") + @Dict(dictTable = "sys_category", dicCode = "id", dicText = "name") + private String orgProvince; + /** + * 机构城市 sys_category.id + */ + @Excel(name = "机构城市", width = 15) + @ApiModelProperty(value = "机构城市") + @Dict(dictTable = "sys_category", dicCode = "id", dicText = "name") + private String orgCity; + /** + * 机构区域 sys_category.id + */ + @Excel(name = "机构区域", width = 15) + @ApiModelProperty(value = "机构区域") + @Dict(dictTable = "sys_category", dicCode = "id", dicText = "name") + private String orgDistrict; + + private String izPz; + private String orgNetUrl;//小程序机构后台网址 + @Excel(name = "应缴金额", width = 15) + private BigDecimal payableAmount; + + //update-begin---author:wangshuai ---date:20200308 for:[JTC-119]在部门管理菜单下设置部门负责人,新增字段负责人ids和旧的负责人ids + + +}