|
@ -46,6 +46,8 @@ public class HuzhouInformationMaterialServiceImpl extends ServiceImpl<HuzhouInfo |
|
|
public Page<HuzhouInformationMaterial> getInformationMaterialPageList(HuzhouInformationMaterial informationMaterial, |
|
|
public Page<HuzhouInformationMaterial> getInformationMaterialPageList(HuzhouInformationMaterial informationMaterial, |
|
|
Integer pageNo, |
|
|
Integer pageNo, |
|
|
Integer pageSize) { |
|
|
Integer pageSize) { |
|
|
|
|
|
SysUser currentUser = ShiroUtil.getCurrentUser(); |
|
|
|
|
|
String workplace = currentUser.getWorkplace(); |
|
|
String informationMaterialName = informationMaterial.getName(); |
|
|
String informationMaterialName = informationMaterial.getName(); |
|
|
String type = informationMaterial.getType(); |
|
|
String type = informationMaterial.getType(); |
|
|
Date publishTime = informationMaterial.getPublishTime(); |
|
|
Date publishTime = informationMaterial.getPublishTime(); |
|
@ -54,6 +56,7 @@ public class HuzhouInformationMaterialServiceImpl extends ServiceImpl<HuzhouInfo |
|
|
Page<HuzhouInformationMaterial> informationMaterialPage = new Page<>(pageNo, pageSize); |
|
|
Page<HuzhouInformationMaterial> informationMaterialPage = new Page<>(pageNo, pageSize); |
|
|
queryWrapper.like(StringUtils.isNotBlank(informationMaterialName),HuzhouInformationMaterial::getName,informationMaterialName); |
|
|
queryWrapper.like(StringUtils.isNotBlank(informationMaterialName),HuzhouInformationMaterial::getName,informationMaterialName); |
|
|
queryWrapper.eq(StringUtils.isNotBlank(type),HuzhouInformationMaterial::getType,type); |
|
|
queryWrapper.eq(StringUtils.isNotBlank(type),HuzhouInformationMaterial::getType,type); |
|
|
|
|
|
queryWrapper.eq(StringUtils.isNotBlank(workplace),HuzhouInformationMaterial::getDutyWorkplace,workplace); |
|
|
if(publishTime!=null){ |
|
|
if(publishTime!=null){ |
|
|
queryWrapper.eq(HuzhouInformationMaterial::getPublishTime,publishTime); |
|
|
queryWrapper.eq(HuzhouInformationMaterial::getPublishTime,publishTime); |
|
|
} |
|
|
} |
|
@ -155,6 +158,9 @@ public class HuzhouInformationMaterialServiceImpl extends ServiceImpl<HuzhouInfo |
|
|
informationMaterial.setDocumentPath(savePath); |
|
|
informationMaterial.setDocumentPath(savePath); |
|
|
informationMaterial.setSize(file.getSize()); |
|
|
informationMaterial.setSize(file.getSize()); |
|
|
informationMaterial.setStatus("1"); |
|
|
informationMaterial.setStatus("1"); |
|
|
informationMaterial.setDutyWorkplace(currentUser.getWorkplace()); |
|
|
// 设置责任单位
|
|
|
|
|
|
if (StringUtils.isNotBlank(currentUser.getWorkplace())){ |
|
|
|
|
|
informationMaterial.setDutyWorkplace(currentUser.getWorkplace()); |
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|