| | |
| | | */ |
| | | @Override |
| | | @PostMapping(GET_REF_PAGE) |
| | | public R<IPage<BtmTypeVO>> getRefPage(BaseQueryObject baseQueryObject) { |
| | | public R<Page<BtmTypeVO>> getRefPage(BaseQueryObject baseQueryObject) { |
| | | Map<String, String> conditionMap = baseQueryObject.getConditionMap(); |
| | | if (conditionMap == null){ |
| | | conditionMap = new HashMap<>(16); |
| | |
| | | query.setSize(pageHelper.getLimit()); |
| | | query.setCurrent(pageHelper.getPage()); |
| | | IPage<BtmType> page = btmTypeService.page(Condition.getPage(query), Condition.getQueryWrapper(queryObj).lambda().eq(BtmType::getDomain, domainValue).orderByAsc(BtmType::getId)); |
| | | IPage<BtmTypeVO> pageVO = new Page<>(); |
| | | Page<BtmTypeVO> pageVO = new Page<>(); |
| | | BeanUtil.copy(page,pageVO); |
| | | pageVO.setRecords(BtmTypeWrapper.build().listEntityVO(page.getRecords())); |
| | | R<IPage<BtmTypeVO>> r = R.data(pageVO); |
| | | R<Page<BtmTypeVO>> r = R.data(pageVO); |
| | | r.setSuccess(true); |
| | | return r; |
| | | } |
| | |
| | | ); |
| | | return R.data(voList); |
| | | } |
| | | |
| | | /** |
| | | * 获取业务类型,只有默认字段 |
| | | * |
| | | * @param btmTypeId 业务类型id |
| | | * @return 默认字段属性 |
| | | */ |
| | | @Override |
| | | public R<BtmTypeVO> getDefaultAttrByBtmId(String btmTypeId) { |
| | | return R.data(Optional.ofNullable(btmTypeService.getDefaultAttrByBtmId(btmTypeId)).orElseGet(BtmTypeVO::new)); |
| | | } |
| | | |
| | | /** |
| | | * 获取业务类型,有所有的字段 |
| | | * |
| | | * @param btmTypeId 业务类型id |
| | | * @return 所有字段 |
| | | */ |
| | | @Override |
| | | public R<BtmTypeVO> getAllAttributeByBtmId(String btmTypeId) { |
| | | return R.data(Optional.ofNullable(btmTypeService.getAllAttributeByBtmId(btmTypeId)).orElseGet(BtmTypeVO::new)); |
| | | } |
| | | |
| | | /** |
| | | * 获取业务类型,有所有的字段 |
| | | * |
| | | * @param btmTypeOid 业务类型主键 |
| | | * @return 所有字段 |
| | | */ |
| | | @Override |
| | | public R<BtmTypeVO> getAllAttributeByBtmOid(String btmTypeOid) { |
| | | return R.data(Optional.ofNullable(btmTypeService.getAllAttributeByBtmOid(btmTypeOid)).orElseGet(BtmTypeVO::new)); |
| | | } |
| | | } |