diff --git a/epmet-module/epmet-message/epmet-message-server/src/main/resources/db/migration/V0.3.17__alter_info_table_ucase.sql b/epmet-module/epmet-message/epmet-message-server/src/main/resources/db/migration/V0.3.17__alter_info_table_ucase.sql new file mode 100644 index 0000000000..aa545faaac --- /dev/null +++ b/epmet-module/epmet-message/epmet-message-server/src/main/resources/db/migration/V0.3.17__alter_info_table_ucase.sql @@ -0,0 +1,10 @@ +alter table info_profile change column publish_staff_id PUBLISH_STAFF_ID varchar(64) not null comment '发布人id'; +alter table info_profile change column content CONTENT varchar(512) not null comment '内容概要,取前100字'; +alter table info_profile change column first_att_id FIRST_ATT_ID varchar(64) comment '默认附件表的第一个条用于展示'; +alter table info_profile change column total_receiver TOTAL_RECEIVER int(11) not null comment '应读人数'; +alter table info_profile change column read_total READ_TOTAL int(11) not null default '0' comment '已读人数,插入是为0'; + +alter table info change column publish_staff_id PUBLISH_STAFF_ID varchar(64)not null comment '发布人id'; +alter table info change column content CONTENT varchar(1024) not null comment '内容,这里存储全部的内容。'; + +alter table info_group_receivers change column info_receiver_group_id INFO_RECEIVER_GROUP_ID varchar(64) not null comment '群组id'; \ No newline at end of file diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java index c30abd4025..b79418b280 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/CustomerStaffAgencyServiceImpl.java @@ -39,6 +39,7 @@ import com.epmet.service.CustomerDepartmentService; import com.epmet.service.CustomerGridService; import com.epmet.service.CustomerStaffAgencyService; import lombok.extern.slf4j.Slf4j; +import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.lang3.StringUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Service; @@ -241,9 +242,9 @@ public class CustomerStaffAgencyServiceImpl extends BaseServiceImpl queryOrgStaffs(OrgStaffFormDTO formDTO) { - Set agencyUserIds=customerStaffAgencyDao.selectAgencyStaffs(formDTO.getCustomerId(),formDTO.getAgencyIds()); - Set deptUserIds=customerStaffAgencyDao.selectDeptStaffs(formDTO.getCustomerId(),formDTO.getDeptIds()); - Set gridUserIds=customerStaffAgencyDao.selectGridStaffs(formDTO.getCustomerId(),formDTO.getGridIds()); + Set agencyUserIds= CollectionUtils.isNotEmpty(formDTO.getAgencyIds())?customerStaffAgencyDao.selectAgencyStaffs(formDTO.getCustomerId(),formDTO.getAgencyIds()):new HashSet<>(); + Set deptUserIds=CollectionUtils.isNotEmpty(formDTO.getDeptIds())?customerStaffAgencyDao.selectDeptStaffs(formDTO.getCustomerId(),formDTO.getDeptIds()):new HashSet<>(); + Set gridUserIds=CollectionUtils.isNotEmpty(formDTO.getGridIds())?customerStaffAgencyDao.selectGridStaffs(formDTO.getCustomerId(),formDTO.getGridIds()):new HashSet<>(); Set result=new LinkedHashSet(); result.addAll(agencyUserIds); result.addAll(deptUserIds);