添加请领接口及供应商接口
This commit is contained in:
parent
d87ba36dd1
commit
4ae7699729
|
|
@ -250,4 +250,14 @@ public class InvoicingApi {
|
||||||
return Result.OK(pageList);
|
return Result.OK(pageList);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ApiOperation(value = "查询全部供应商信息", notes = "查询全部供应商信息")
|
||||||
|
@AutoLog(value = "查询全部供应商信息")
|
||||||
|
@GetMapping(value = "/getGysList")
|
||||||
|
public Result<List<Map<String,Object>>> getGysList(MaterialInfoEntity materialInfoEntityDto,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
List<Map<String,Object>> pageList = invoicingApi.getGysList(materialInfoEntityDto,req);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,69 @@
|
||||||
|
package com.nu.modules.pad.qingling.api;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.nu.entity.*;
|
||||||
|
import com.nu.modules.invoicing.api.IInvoicingApi;
|
||||||
|
import com.nu.modules.invoicing.api.IQinglingApi;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/api/pad/qingling")
|
||||||
|
public class QinglingApi {
|
||||||
|
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IQinglingApi qinglingApi;
|
||||||
|
|
||||||
|
@ApiOperation(value = "查询请领包下的信息", notes = "查询请领包下的信息")
|
||||||
|
@GetMapping(value = "/queryPackageList")
|
||||||
|
public Result<IPage<MaterialInfoEntity>> queryPackageList(MaterialInfoEntity materialInfoEntityDto,
|
||||||
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
IPage<MaterialInfoEntity> pageList = qinglingApi.queryPackageList(pageNo, pageSize, materialInfoEntityDto,req);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ApiOperation(value = "查询请领包可请领的物料信息", notes = "查询请领包可请领的物料信息")
|
||||||
|
@GetMapping(value = "/queryWuliaoList")
|
||||||
|
public Result<IPage<MaterialInfoEntity>> queryWuliaoList(MaterialInfoEntity materialInfoEntityDto,
|
||||||
|
@RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
|
||||||
|
@RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
IPage<MaterialInfoEntity> pageList = qinglingApi.queryWuliaoList(pageNo, pageSize, materialInfoEntityDto,req);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ApiOperation(value="请领包物料添加", notes="请领包物料添加")
|
||||||
|
@AutoLog(value = "请领包物料添加")
|
||||||
|
@PostMapping(value = "/addMaterialPackageList")
|
||||||
|
public Result<String> addMaterialPackageList(@RequestBody List<MaterialPackageEntity> infoList) {
|
||||||
|
if (infoList == null || infoList.size() == 0){
|
||||||
|
return Result.error("请选择要添加的物料!");
|
||||||
|
}
|
||||||
|
String result = qinglingApi.addMaterialPackageList(infoList);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@AutoLog(value = "通过id删除请购信息")
|
||||||
|
@ApiOperation(value="通过id删除请购信息", notes="通过id删除请购信息")
|
||||||
|
@DeleteMapping(value = "/deletePackageById")
|
||||||
|
public Result<String> deletePackageById(@RequestParam(name="id",required=true) String id) {
|
||||||
|
qinglingApi.deletePackageById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -91,7 +91,8 @@ public class ShiroConfig {
|
||||||
}
|
}
|
||||||
|
|
||||||
filterChainDefinitionMap.put("/api/tplink/videoStorage/**", "anon"); //视频缓存存储接口
|
filterChainDefinitionMap.put("/api/tplink/videoStorage/**", "anon"); //视频缓存存储接口
|
||||||
// filterChainDefinitionMap.put("/api/pad/invoicing/**", "anon"); //测试进销存对应的接口
|
filterChainDefinitionMap.put("/api/pad/invoicing/**", "anon"); //测试进销存对应的接口
|
||||||
|
filterChainDefinitionMap.put("/api/pad/qingling/**", "anon"); //测试请领对应的接口
|
||||||
filterChainDefinitionMap.put("/iot/tq/api/electricityMeter/**", "anon"); //电表回调
|
filterChainDefinitionMap.put("/iot/tq/api/electricityMeter/**", "anon"); //电表回调
|
||||||
filterChainDefinitionMap.put("/api/pad/baseInfo/**", "anon"); //电表回调
|
filterChainDefinitionMap.put("/api/pad/baseInfo/**", "anon"); //电表回调
|
||||||
filterChainDefinitionMap.put("/iot/tq/api/waterMeter/**", "anon"); //水表回调
|
filterChainDefinitionMap.put("/iot/tq/api/waterMeter/**", "anon"); //水表回调
|
||||||
|
|
|
||||||
|
|
@ -82,4 +82,5 @@ public class CgdMainEntity implements Serializable {
|
||||||
private String cgdParamInfo;
|
private String cgdParamInfo;
|
||||||
|
|
||||||
private List<CgdInfoEntity> cgdInfoList;
|
private List<CgdInfoEntity> cgdInfoList;
|
||||||
|
private String suppliers;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,7 @@ public class MaterialCategoryEntity implements Serializable {
|
||||||
private Integer num;
|
private Integer num;
|
||||||
private String nuId;
|
private String nuId;
|
||||||
private String cgdId;
|
private String cgdId;
|
||||||
|
private String suppliers;
|
||||||
|
|
||||||
private java.lang.String appIconPath;
|
private java.lang.String appIconPath;
|
||||||
private java.lang.String appCheckIconPath;
|
private java.lang.String appCheckIconPath;
|
||||||
|
|
|
||||||
|
|
@ -125,4 +125,5 @@ public class MaterialInfoEntity implements Serializable {
|
||||||
private String typeName;
|
private String typeName;
|
||||||
private String medicationName;
|
private String medicationName;
|
||||||
private String isAdd;
|
private String isAdd;
|
||||||
|
private String delId;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,45 @@
|
||||||
|
package com.nu.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 护理单元请领包
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-12
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class MaterialPackageEntity implements Serializable {
|
||||||
|
|
||||||
|
/**id*/
|
||||||
|
private String id;
|
||||||
|
/**createBy*/
|
||||||
|
private String createBy;
|
||||||
|
/**createTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
private java.util.Date createTime;
|
||||||
|
/**updateBy*/
|
||||||
|
@ApiModelProperty(value = "updateBy")
|
||||||
|
private String updateBy;
|
||||||
|
/**updateTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
private java.util.Date updateTime;
|
||||||
|
/**护理单元*/
|
||||||
|
private String nuId;
|
||||||
|
/**物料*/
|
||||||
|
private String wlId;
|
||||||
|
}
|
||||||
|
|
@ -84,5 +84,6 @@ public class QgdInfoEntity implements Serializable {
|
||||||
private String materialImg;
|
private String materialImg;
|
||||||
private String tagType;
|
private String tagType;
|
||||||
private String tagName;
|
private String tagName;
|
||||||
|
private String suppliers;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -56,4 +56,6 @@ public interface IInvoicingApi {
|
||||||
Map<String, Object> getCgdTreeDataWlnum(MaterialCategoryEntity configMaterialCategory);
|
Map<String, Object> getCgdTreeDataWlnum(MaterialCategoryEntity configMaterialCategory);
|
||||||
|
|
||||||
String eddShoppingCartList(QgdInfoEntity qgdInfoEntity);
|
String eddShoppingCartList(QgdInfoEntity qgdInfoEntity);
|
||||||
|
|
||||||
|
List<Map<String, Object>> getGysList(MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,18 @@
|
||||||
|
package com.nu.modules.invoicing.api;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.nu.entity.MaterialInfoEntity;
|
||||||
|
import com.nu.entity.MaterialPackageEntity;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface IQinglingApi {
|
||||||
|
IPage<MaterialInfoEntity> queryPackageList(Integer pageNo, Integer pageSize, MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req);
|
||||||
|
|
||||||
|
String addMaterialPackageList(List<MaterialPackageEntity> infoList);
|
||||||
|
|
||||||
|
void deletePackageById(String id);
|
||||||
|
|
||||||
|
IPage<MaterialInfoEntity> queryWuliaoList(Integer pageNo, Integer pageSize, MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req);
|
||||||
|
}
|
||||||
|
|
@ -43,6 +43,18 @@
|
||||||
<version>2.0.0</version>
|
<version>2.0.0</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.nursingunit.boot</groupId>
|
||||||
|
<artifactId>nu-admin-local-api</artifactId>
|
||||||
|
<version>2.0.0</version>
|
||||||
|
<scope>compile</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.nursingunit.boot</groupId>
|
||||||
|
<artifactId>nu-admin-local-api</artifactId>
|
||||||
|
<version>2.0.0</version>
|
||||||
|
<scope>compile</scope>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|
|
||||||
|
|
@ -170,6 +170,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
queryWrapper.eq(StringUtils.isNotBlank(warehouseMaterialInfo.getCategoryId()),"category_id",warehouseMaterialInfo.getCategoryId());
|
queryWrapper.eq(StringUtils.isNotBlank(warehouseMaterialInfo.getCategoryId()),"category_id",warehouseMaterialInfo.getCategoryId());
|
||||||
queryWrapper.eq(StringUtils.isNotBlank(warehouseMaterialInfo.getTypeId()),"type_id",warehouseMaterialInfo.getTypeId());
|
queryWrapper.eq(StringUtils.isNotBlank(warehouseMaterialInfo.getTypeId()),"type_id",warehouseMaterialInfo.getTypeId());
|
||||||
queryWrapper.eq(StringUtils.isNotBlank(warehouseMaterialInfo.getMedicationId()),"medication_id",warehouseMaterialInfo.getMedicationId());
|
queryWrapper.eq(StringUtils.isNotBlank(warehouseMaterialInfo.getMedicationId()),"medication_id",warehouseMaterialInfo.getMedicationId());
|
||||||
|
queryWrapper.in(StringUtils.isNotBlank(warehouseMaterialInfo.getSuppliers()),"suppliers",warehouseMaterialInfo.getSuppliers());
|
||||||
if(StringUtils.isNotBlank(materialInfoEntityDto.getIsWaring()) && "1".equals(materialInfoEntityDto.getIsWaring())){
|
if(StringUtils.isNotBlank(materialInfoEntityDto.getIsWaring()) && "1".equals(materialInfoEntityDto.getIsWaring())){
|
||||||
queryWrapper.apply("kcsl <= lower_limit");
|
queryWrapper.apply("kcsl <= lower_limit");
|
||||||
}
|
}
|
||||||
|
|
@ -193,6 +194,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
queryWrapper.eq(StringUtils.isNotBlank(qgdInfoEntityDto.getTypeId()),"c.type_id",nuInvoicingQgdInfo.getTypeId());
|
queryWrapper.eq(StringUtils.isNotBlank(qgdInfoEntityDto.getTypeId()),"c.type_id",nuInvoicingQgdInfo.getTypeId());
|
||||||
queryWrapper.eq(StringUtils.isNotBlank(qgdInfoEntityDto.getMedicationId()),"c.medication_id",nuInvoicingQgdInfo.getMedicationId());
|
queryWrapper.eq(StringUtils.isNotBlank(qgdInfoEntityDto.getMedicationId()),"c.medication_id",nuInvoicingQgdInfo.getMedicationId());
|
||||||
queryWrapper.apply(StringUtils.isNotBlank(qgdInfoEntityDto.getWlParamInfo()),"( c.material_name like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' or c.material_no like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' or c.pinyin like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' or c.specification_model like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' ) ");
|
queryWrapper.apply(StringUtils.isNotBlank(qgdInfoEntityDto.getWlParamInfo()),"( c.material_name like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' or c.material_no like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' or c.pinyin like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' or c.specification_model like '%"+qgdInfoEntityDto.getWlParamInfo()+"%' ) ");
|
||||||
|
queryWrapper.in(StringUtils.isNotBlank(qgdInfoEntityDto.getSuppliers()),"c.suppliers",qgdInfoEntityDto.getSuppliers());
|
||||||
Page<QgdInfo> page = new Page<QgdInfo>(pageNo, pageSize);
|
Page<QgdInfo> page = new Page<QgdInfo>(pageNo, pageSize);
|
||||||
List<QgdInfo> list = qgdInfoMapper.queryShoppingCartList(page, queryWrapper);
|
List<QgdInfo> list = qgdInfoMapper.queryShoppingCartList(page, queryWrapper);
|
||||||
//封装返回结果
|
//封装返回结果
|
||||||
|
|
@ -401,6 +403,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
Map<String, QueryRuleEnum> customeRuleMap = new HashMap<>();
|
Map<String, QueryRuleEnum> customeRuleMap = new HashMap<>();
|
||||||
QueryWrapper<NuInvoicingCgdMain> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdMain, req.getParameterMap(), customeRuleMap);
|
QueryWrapper<NuInvoicingCgdMain> queryWrapper = QueryGenerator.initQueryWrapper(nuInvoicingCgdMain, req.getParameterMap(), customeRuleMap);
|
||||||
queryWrapper.apply(StringUtils.isNotBlank(cgdMainEntityDto.getCgdParamInfo()),"(cgd_no like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_name like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or qg_by like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_lxr like '%"+cgdMainEntityDto.getCgdParamInfo()+"%')");
|
queryWrapper.apply(StringUtils.isNotBlank(cgdMainEntityDto.getCgdParamInfo()),"(cgd_no like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_name like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or qg_by like '%"+cgdMainEntityDto.getCgdParamInfo()+"%' or gys_lxr like '%"+cgdMainEntityDto.getCgdParamInfo()+"%')");
|
||||||
|
queryWrapper.in(StringUtils.isNotBlank(cgdMainEntityDto.getSuppliers()),"gys_id",cgdMainEntityDto.getSuppliers());
|
||||||
Page<NuInvoicingCgdMain> page = new Page<>(pageNo, pageSize);
|
Page<NuInvoicingCgdMain> page = new Page<>(pageNo, pageSize);
|
||||||
List<NuInvoicingCgdMain> list = cgdMainMapper.selectList(page,queryWrapper);
|
List<NuInvoicingCgdMain> list = cgdMainMapper.selectList(page,queryWrapper);
|
||||||
IPage<CgdMainEntity> entityPage = new Page<>(page.getCurrent(), page.getSize(), page.getTotal());
|
IPage<CgdMainEntity> entityPage = new Page<>(page.getCurrent(), page.getSize(), page.getTotal());
|
||||||
|
|
@ -552,6 +555,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getCategoryId()),"b.category_id",configMaterialCategory.getCategoryId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getCategoryId()),"b.category_id",configMaterialCategory.getCategoryId());
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getTypeId()),"b.type_id",configMaterialCategory.getTypeId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getTypeId()),"b.type_id",configMaterialCategory.getTypeId());
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getMedicationId()),"b.medication_id",configMaterialCategory.getMedicationId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getMedicationId()),"b.medication_id",configMaterialCategory.getMedicationId());
|
||||||
|
queryWrapper.in(StringUtils.isNotBlank(configMaterialCategory.getSuppliers()),"b.suppliers",configMaterialCategory.getSuppliers());
|
||||||
List<ConfigMaterialInfo> list = configMaterialInfoMapper.getTreeDataWlnum(queryWrapper);
|
List<ConfigMaterialInfo> list = configMaterialInfoMapper.getTreeDataWlnum(queryWrapper);
|
||||||
map.put("success",true);
|
map.put("success",true);
|
||||||
map.put("message","物料数量");
|
map.put("message","物料数量");
|
||||||
|
|
@ -577,6 +581,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getCategoryId()),"b.category_id",configMaterialCategory.getCategoryId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getCategoryId()),"b.category_id",configMaterialCategory.getCategoryId());
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getTypeId()),"b.type_id",configMaterialCategory.getTypeId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getTypeId()),"b.type_id",configMaterialCategory.getTypeId());
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getMedicationId()),"b.medication_id",configMaterialCategory.getMedicationId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getMedicationId()),"b.medication_id",configMaterialCategory.getMedicationId());
|
||||||
|
queryWrapper.in(StringUtils.isNotBlank(configMaterialCategory.getSuppliers()),"b.suppliers",configMaterialCategory.getSuppliers());
|
||||||
List<ConfigMaterialInfo> list = configMaterialInfoMapper.getGwcTreeDataWlnum(queryWrapper);
|
List<ConfigMaterialInfo> list = configMaterialInfoMapper.getGwcTreeDataWlnum(queryWrapper);
|
||||||
map.put("success",true);
|
map.put("success",true);
|
||||||
map.put("message","物料数量");
|
map.put("message","物料数量");
|
||||||
|
|
@ -598,6 +603,7 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getCategoryId()),"b.category_id",configMaterialCategory.getCategoryId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getCategoryId()),"b.category_id",configMaterialCategory.getCategoryId());
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getTypeId()),"b.type_id",configMaterialCategory.getTypeId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getTypeId()),"b.type_id",configMaterialCategory.getTypeId());
|
||||||
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getMedicationId()),"b.medication_id",configMaterialCategory.getMedicationId());
|
queryWrapper.eq(StringUtils.isNotEmpty(configMaterialCategory.getMedicationId()),"b.medication_id",configMaterialCategory.getMedicationId());
|
||||||
|
queryWrapper.in(StringUtils.isNotBlank(configMaterialCategory.getSuppliers()),"b.suppliers",configMaterialCategory.getSuppliers());
|
||||||
List<ConfigMaterialInfo> list = configMaterialInfoMapper.getCgdTreeDataWlnum(queryWrapper);
|
List<ConfigMaterialInfo> list = configMaterialInfoMapper.getCgdTreeDataWlnum(queryWrapper);
|
||||||
map.put("success",true);
|
map.put("success",true);
|
||||||
map.put("message","物料数量");
|
map.put("message","物料数量");
|
||||||
|
|
@ -634,4 +640,17 @@ public class NuInvoicingCgdMainServiceImpl extends ServiceImpl<NuInvoicingCgdMai
|
||||||
qgdInfoMapper.updateById(qgdInfo);
|
qgdInfoMapper.updateById(qgdInfo);
|
||||||
return "0";
|
return "0";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Map<String, Object>> getGysList(MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req) {
|
||||||
|
List<ConfigSuppliersInfo> gysList = gysMapper.selectList(new QueryWrapper<ConfigSuppliersInfo>().eq("del_flag","0"));
|
||||||
|
List<Map<String, Object>> list = new ArrayList<>();
|
||||||
|
for(ConfigSuppliersInfo gys : gysList){
|
||||||
|
Map<String, Object> map = new HashMap<>();
|
||||||
|
map.put("suppliers",gys.getId());
|
||||||
|
map.put("suppliersName",gys.getSuppliersName());
|
||||||
|
list.add(map);
|
||||||
|
}
|
||||||
|
return list;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,163 @@
|
||||||
|
package com.nu.modules.qingling.controller;
|
||||||
|
|
||||||
|
import java.util.Arrays;
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.system.query.QueryGenerator;
|
||||||
|
import com.nu.modules.qingling.entity.NuConfigMaterialPackage;
|
||||||
|
import com.nu.modules.qingling.service.INuConfigMaterialPackageService;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import org.jeecg.common.system.base.controller.JeecgController;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import org.springframework.web.servlet.ModelAndView;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import org.jeecg.common.aspect.annotation.AutoLog;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 护理单元请领包
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-12
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Api(tags="护理单元请领包")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qinggou/nuConfigMaterialPackage")
|
||||||
|
@Slf4j
|
||||||
|
public class NuConfigMaterialPackageController extends JeecgController<NuConfigMaterialPackage, INuConfigMaterialPackageService> {
|
||||||
|
@Autowired
|
||||||
|
private INuConfigMaterialPackageService nuConfigMaterialPackageService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分页列表查询
|
||||||
|
*
|
||||||
|
* @param nuConfigMaterialPackage
|
||||||
|
* @param pageNo
|
||||||
|
* @param pageSize
|
||||||
|
* @param req
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "护理单元请领包-分页列表查询")
|
||||||
|
@ApiOperation(value="护理单元请领包-分页列表查询", notes="护理单元请领包-分页列表查询")
|
||||||
|
@GetMapping(value = "/list")
|
||||||
|
public Result<IPage<NuConfigMaterialPackage>> queryPageList(NuConfigMaterialPackage nuConfigMaterialPackage,
|
||||||
|
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||||
|
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||||
|
HttpServletRequest req) {
|
||||||
|
QueryWrapper<NuConfigMaterialPackage> queryWrapper = QueryGenerator.initQueryWrapper(nuConfigMaterialPackage, req.getParameterMap());
|
||||||
|
Page<NuConfigMaterialPackage> page = new Page<NuConfigMaterialPackage>(pageNo, pageSize);
|
||||||
|
IPage<NuConfigMaterialPackage> pageList = nuConfigMaterialPackageService.page(page, queryWrapper);
|
||||||
|
return Result.OK(pageList);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加
|
||||||
|
*
|
||||||
|
* @param nuConfigMaterialPackage
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "护理单元请领包-添加")
|
||||||
|
@ApiOperation(value="护理单元请领包-添加", notes="护理单元请领包-添加")
|
||||||
|
@RequiresPermissions("qinggou:nu_config_material_package:add")
|
||||||
|
@PostMapping(value = "/add")
|
||||||
|
public Result<String> add(@RequestBody NuConfigMaterialPackage nuConfigMaterialPackage) {
|
||||||
|
nuConfigMaterialPackageService.save(nuConfigMaterialPackage);
|
||||||
|
return Result.OK("添加成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 编辑
|
||||||
|
*
|
||||||
|
* @param nuConfigMaterialPackage
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "护理单元请领包-编辑")
|
||||||
|
@ApiOperation(value="护理单元请领包-编辑", notes="护理单元请领包-编辑")
|
||||||
|
@RequiresPermissions("qinggou:nu_config_material_package:edit")
|
||||||
|
@RequestMapping(value = "/edit", method = {RequestMethod.PUT,RequestMethod.POST})
|
||||||
|
public Result<String> edit(@RequestBody NuConfigMaterialPackage nuConfigMaterialPackage) {
|
||||||
|
nuConfigMaterialPackageService.updateById(nuConfigMaterialPackage);
|
||||||
|
return Result.OK("编辑成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id删除
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "护理单元请领包-通过id删除")
|
||||||
|
@ApiOperation(value="护理单元请领包-通过id删除", notes="护理单元请领包-通过id删除")
|
||||||
|
@RequiresPermissions("qinggou:nu_config_material_package:delete")
|
||||||
|
@DeleteMapping(value = "/delete")
|
||||||
|
public Result<String> delete(@RequestParam(name="id",required=true) String id) {
|
||||||
|
nuConfigMaterialPackageService.removeById(id);
|
||||||
|
return Result.OK("删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除
|
||||||
|
*
|
||||||
|
* @param ids
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@AutoLog(value = "护理单元请领包-批量删除")
|
||||||
|
@ApiOperation(value="护理单元请领包-批量删除", notes="护理单元请领包-批量删除")
|
||||||
|
@RequiresPermissions("qinggou:nu_config_material_package:deleteBatch")
|
||||||
|
@DeleteMapping(value = "/deleteBatch")
|
||||||
|
public Result<String> deleteBatch(@RequestParam(name="ids",required=true) String ids) {
|
||||||
|
this.nuConfigMaterialPackageService.removeByIds(Arrays.asList(ids.split(",")));
|
||||||
|
return Result.OK("批量删除成功!");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过id查询
|
||||||
|
*
|
||||||
|
* @param id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
//@AutoLog(value = "护理单元请领包-通过id查询")
|
||||||
|
@ApiOperation(value="护理单元请领包-通过id查询", notes="护理单元请领包-通过id查询")
|
||||||
|
@GetMapping(value = "/queryById")
|
||||||
|
public Result<NuConfigMaterialPackage> queryById(@RequestParam(name="id",required=true) String id) {
|
||||||
|
NuConfigMaterialPackage nuConfigMaterialPackage = nuConfigMaterialPackageService.getById(id);
|
||||||
|
if(nuConfigMaterialPackage==null) {
|
||||||
|
return Result.error("未找到对应数据");
|
||||||
|
}
|
||||||
|
return Result.OK(nuConfigMaterialPackage);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出excel
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param nuConfigMaterialPackage
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("qinggou:nu_config_material_package:exportXls")
|
||||||
|
@RequestMapping(value = "/exportXls")
|
||||||
|
public ModelAndView exportXls(HttpServletRequest request, NuConfigMaterialPackage nuConfigMaterialPackage) {
|
||||||
|
return super.exportXls(request, nuConfigMaterialPackage, NuConfigMaterialPackage.class, "护理单元请领包");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过excel导入数据
|
||||||
|
*
|
||||||
|
* @param request
|
||||||
|
* @param response
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("qinggou:nu_config_material_package:importExcel")
|
||||||
|
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||||
|
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
return super.importExcel(request, response, NuConfigMaterialPackage.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,59 @@
|
||||||
|
package com.nu.modules.qingling.entity;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import lombok.Data;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 护理单元请领包
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-12
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@TableName("nu_config_material_package")
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@ApiModel(value="nu_config_material_package对象", description="护理单元请领包")
|
||||||
|
public class NuConfigMaterialPackage implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/**id*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
@ApiModelProperty(value = "id")
|
||||||
|
private java.lang.String id;
|
||||||
|
/**createBy*/
|
||||||
|
@ApiModelProperty(value = "createBy")
|
||||||
|
private java.lang.String createBy;
|
||||||
|
/**createTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "createTime")
|
||||||
|
private java.util.Date createTime;
|
||||||
|
/**updateBy*/
|
||||||
|
@ApiModelProperty(value = "updateBy")
|
||||||
|
private java.lang.String updateBy;
|
||||||
|
/**updateTime*/
|
||||||
|
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||||
|
@ApiModelProperty(value = "updateTime")
|
||||||
|
private java.util.Date updateTime;
|
||||||
|
/**护理单元*/
|
||||||
|
@Excel(name = "护理单元", width = 15)
|
||||||
|
@ApiModelProperty(value = "护理单元")
|
||||||
|
private java.lang.String nuId;
|
||||||
|
/**物料*/
|
||||||
|
@Excel(name = "物料", width = 15)
|
||||||
|
@ApiModelProperty(value = "物料")
|
||||||
|
private java.lang.String wlId;
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,28 @@
|
||||||
|
package com.nu.modules.qingling.mapper;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
||||||
|
import com.nu.entity.MaterialInfoEntity;
|
||||||
|
import com.nu.entity.MaterialPackageEntity;
|
||||||
|
import com.nu.modules.qingling.entity.NuConfigMaterialPackage;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import org.jeecg.common.constant.CommonConstant;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 护理单元请领包
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-12
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface NuConfigMaterialPackageMapper extends BaseMapper<NuConfigMaterialPackage> {
|
||||||
|
|
||||||
|
IPage<MaterialInfoEntity> queryPackageList(IPage<MaterialInfoEntity> page, @Param(Constants.WRAPPER) QueryWrapper<MaterialInfoEntity> queryWrapper);
|
||||||
|
|
||||||
|
String addMaterialPackageList(List<MaterialPackageEntity> infoList);
|
||||||
|
|
||||||
|
IPage<MaterialInfoEntity> queryWuliaoList(IPage<MaterialInfoEntity> page, @Param(Constants.WRAPPER) QueryWrapper<MaterialInfoEntity> queryWrapper);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,16 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.nu.modules.qingling.mapper.NuConfigMaterialPackageMapper">
|
||||||
|
|
||||||
|
<select id="queryPackageList" resultType="com.nu.entity.MaterialInfoEntity">
|
||||||
|
select b.*,a.id as delId from nu_config_material_package a
|
||||||
|
left join nu_config_material_info b on a.wl_id = b.id
|
||||||
|
${ew.customSqlSegment}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="queryWuliaoList" resultType="com.nu.entity.MaterialInfoEntity">
|
||||||
|
select b.* from nu_config_material_info b
|
||||||
|
left join nu_config_material_package a on a.wl_id = b.id
|
||||||
|
${ew.customSqlSegment}
|
||||||
|
</select>
|
||||||
|
</mapper>
|
||||||
|
|
@ -0,0 +1,14 @@
|
||||||
|
package com.nu.modules.qingling.service;
|
||||||
|
|
||||||
|
import com.nu.modules.qingling.entity.NuConfigMaterialPackage;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 护理单元请领包
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-12
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface INuConfigMaterialPackageService extends IService<NuConfigMaterialPackage> {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,114 @@
|
||||||
|
package com.nu.modules.qingling.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.bean.BeanUtil;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.nu.entity.MaterialInfoEntity;
|
||||||
|
import com.nu.entity.MaterialPackageEntity;
|
||||||
|
import com.nu.modules.invoicing.api.IQinglingApi;
|
||||||
|
import com.nu.modules.qingling.entity.NuConfigMaterialPackage;
|
||||||
|
import com.nu.modules.qingling.mapper.NuConfigMaterialPackageMapper;
|
||||||
|
import com.nu.modules.qingling.service.INuConfigMaterialPackageService;
|
||||||
|
import com.nu.modules.sysconfig.ISysConfigApi;
|
||||||
|
import com.nu.modules.warehouseMaterialInfo.entity.BlWarehouseMaterialInfo;
|
||||||
|
import org.apache.commons.lang.StringUtils;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
import javax.servlet.http.HttpServletRequest;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: 护理单元请领包
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2025-11-12
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class NuConfigMaterialPackageServiceImpl extends ServiceImpl<NuConfigMaterialPackageMapper, NuConfigMaterialPackage> implements INuConfigMaterialPackageService, IQinglingApi {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private ISysConfigApi sysConfigApi;
|
||||||
|
|
||||||
|
private String serverNetUrl;
|
||||||
|
@Override
|
||||||
|
public IPage<MaterialInfoEntity> queryPackageList(Integer pageNo, Integer pageSize, MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req) {
|
||||||
|
QueryWrapper<MaterialInfoEntity> queryWrapper = new QueryWrapper<>();
|
||||||
|
queryWrapper.eq("a.nu_id", materialInfoEntityDto.getNuId());
|
||||||
|
queryWrapper.apply(StringUtils.isNotBlank(materialInfoEntityDto.getWlParamInfo()),"( b.material_name like '%"+materialInfoEntityDto.getWlParamInfo()+"%' or b.material_no like '%"+materialInfoEntityDto.getWlParamInfo()+"%' or b.pinyin like '%"+materialInfoEntityDto.getWlParamInfo()+"%' or b.specification_model like '%"+materialInfoEntityDto.getWlParamInfo()+"%' ) ");
|
||||||
|
|
||||||
|
Page<MaterialInfoEntity> page = new Page<>(pageNo, pageSize);
|
||||||
|
IPage<MaterialInfoEntity> pageList = baseMapper.queryPackageList(page, queryWrapper);
|
||||||
|
pageList.getRecords().forEach(info -> {
|
||||||
|
if (info.getMaterialImg() != null){
|
||||||
|
info.setMaterialImg(getImageNetUrl(info.getMaterialImg()));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return pageList;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String addMaterialPackageList(List<MaterialPackageEntity> infoList) {
|
||||||
|
List<NuConfigMaterialPackage> addList = BeanUtil.copyToList(infoList, NuConfigMaterialPackage.class);
|
||||||
|
for(NuConfigMaterialPackage info:addList){
|
||||||
|
baseMapper.insert(info);
|
||||||
|
}
|
||||||
|
return "1";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deletePackageById(String id) {
|
||||||
|
if (id.indexOf(",")>-1){
|
||||||
|
for (String param : id.split(",")){
|
||||||
|
baseMapper.deleteById(param);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<MaterialInfoEntity> queryWuliaoList(Integer pageNo, Integer pageSize, MaterialInfoEntity materialInfoEntityDto, HttpServletRequest req) {
|
||||||
|
QueryWrapper<MaterialInfoEntity> queryWrapper = new QueryWrapper<>();
|
||||||
|
// queryWrapper.ne("a.nu_id", materialInfoEntityDto.getNuId());
|
||||||
|
queryWrapper.apply(" (a.nu_id IS NULL OR a.nu_id <> '"+materialInfoEntityDto.getNuId()+"') ");
|
||||||
|
queryWrapper.eq("b.del_flag","0");
|
||||||
|
queryWrapper.apply(StringUtils.isNotBlank(materialInfoEntityDto.getWlParamInfo()),"( b.material_name like '%"+materialInfoEntityDto.getWlParamInfo()+"%' or b.material_no like '%"+materialInfoEntityDto.getWlParamInfo()+"%' or b.pinyin like '%"+materialInfoEntityDto.getWlParamInfo()+"%' or b.specification_model like '%"+materialInfoEntityDto.getWlParamInfo()+"%' ) ");
|
||||||
|
|
||||||
|
Page<MaterialInfoEntity> page = new Page<>(pageNo, pageSize);
|
||||||
|
IPage<MaterialInfoEntity> pageList = baseMapper.queryWuliaoList(page, queryWrapper);
|
||||||
|
pageList.getRecords().forEach(info -> {
|
||||||
|
if (info.getMaterialImg() != null){
|
||||||
|
info.setMaterialImg(getImageNetUrl(info.getMaterialImg()));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
return pageList;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取管理平台静态资源路径
|
||||||
|
*
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
private void getOpeMediaAddress() {
|
||||||
|
if (serverNetUrl == null || serverNetUrl.equals("")) {
|
||||||
|
JSONObject json = sysConfigApi.getByKey("ope_media_address");
|
||||||
|
if (json != null) {
|
||||||
|
String configValue = json.getString("configValue");
|
||||||
|
if (!configValue.endsWith("/")) {
|
||||||
|
configValue += "/";
|
||||||
|
}
|
||||||
|
serverNetUrl = configValue;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private String getImageNetUrl(String imageUrl) {
|
||||||
|
getOpeMediaAddress();
|
||||||
|
return serverNetUrl + imageUrl;
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue