Merge remote-tracking branch 'origin/dev_third_stage' into dev_third_stage
This commit is contained in:
+2
@@ -53,10 +53,12 @@ public class LawsOpinionGatherEOController extends JeroController<LawsOpinionGat
|
||||
public Result<?> queryPageList(LawsOpinionGatherEO lawsOpinionGatherEO,
|
||||
@RequestParam(name="pageNo", defaultValue="1") Integer pageNo,
|
||||
@RequestParam(name="pageSize", defaultValue="10") Integer pageSize,
|
||||
@RequestParam(name="cut", defaultValue="cn") String cut,
|
||||
HttpServletRequest req) {
|
||||
QueryWrapper<LawsOpinionGatherEO> queryWrapper = QueryGenerator.initQueryWrapper(lawsOpinionGatherEO, req.getParameterMap());
|
||||
Page<LawsOpinionGatherEO> page = new Page<LawsOpinionGatherEO>(pageNo, pageSize);
|
||||
IPage<LawsOpinionGatherEO> pageList = lawsOpinionGatherEOService.page(page, queryWrapper);
|
||||
this.lawsOpinionGatherEOService.disposeData(pageList.getRecords(),cut);
|
||||
return Result.OK(pageList);
|
||||
}
|
||||
|
||||
|
||||
+3
@@ -4,6 +4,7 @@ import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import lombok.Data;
|
||||
@@ -77,6 +78,8 @@ public class LawsOpinionGatherEO implements Serializable {
|
||||
@Excel(name = "收集结果", width = 15)
|
||||
@ApiModelProperty(value = "收集结果")
|
||||
private String gatherResult;
|
||||
@TableField(exist = false)
|
||||
private String gatherResultShow;
|
||||
|
||||
/**发起日期*/
|
||||
@Excel(name = "发起日期", width = 15, format = "yyyy-MM-dd")
|
||||
|
||||
+6
@@ -67,4 +67,10 @@ public interface ILawsOpinionGatherEOService extends IService<LawsOpinionGatherE
|
||||
* @return
|
||||
*/
|
||||
Result<?> processCall(JSONObject jsonObject);
|
||||
|
||||
/**
|
||||
* 处理数据
|
||||
* @param lawsOpinionGatherEOList
|
||||
*/
|
||||
void disposeData(List<LawsOpinionGatherEO> lawsOpinionGatherEOList,String cut);
|
||||
}
|
||||
|
||||
+13
@@ -4,10 +4,12 @@ import com.alibaba.fastjson.JSONObject;
|
||||
import com.jero.common.api.vo.Result;
|
||||
import com.jero.common.exception.JeroBootException;
|
||||
import com.jero.modules.lawsOpinionGather.entity.LawsOpinionGatherEO;
|
||||
import com.jero.modules.lawsOpinionGather.enums.GatherResultEnum;
|
||||
import com.jero.modules.lawsOpinionGather.mapper.LawsOpinionGatherEOMapper;
|
||||
import com.jero.modules.lawsOpinionGather.service.ILawsOpinionGatherEOService;
|
||||
import com.jero.modules.project.enums.OperatorTypeEnum;
|
||||
import com.jero.modules.project.enums.RequestSourceEnum;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import java.util.List;
|
||||
@@ -124,4 +126,15 @@ public class LawsOpinionGatherEOServiceImpl extends ServiceImpl<LawsOpinionGathe
|
||||
}
|
||||
return new Result<>().success("调用成功!");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void disposeData(List<LawsOpinionGatherEO> lawsOpinionGatherEOList,String cut) {
|
||||
if(CollectionUtils.isNotEmpty(lawsOpinionGatherEOList)){
|
||||
lawsOpinionGatherEOList.forEach(lawsOpinionGather -> {
|
||||
if(StringUtils.isNotEmpty(lawsOpinionGather.getGatherResult())){
|
||||
lawsOpinionGather.setGatherResultShow(GatherResultEnum.getTextByValue(lawsOpinionGather.getGatherResult(),cut));
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user