|
如下 可以自定义参照的返回值
@Component(value = "customRef")
@BillRefer(desc = "customRef", refCode = "RefTable_47cf84cf81", busiObj = "testFeature")
public class CustomBillRefAction implements IYpdExtRefService {
private static final Logger logger = LoggerFactory.getLogger(CustomBillRefAction.class);
@Override
public Object queryRefData(BillQueryContext billContext) throws Exception {
logger.info(billContext.getRefQueryParam().getDomain());
int pageIndex = billContext.getPage().getPageIndex();
int pageSize = billContext.getPage().getPageSize();
//模拟数据
List<Map<String, Object>> recordList = new ArrayList<>();
for (int i = 0; i < 5; i++) {
Map<String, Object> map = new HashMap<>();
map.put("id", "" + i);
map.put("ziduan1", "" + i);
map.put("new2", i);
map.put("staffNew", "" + i);
map.put("staffNew_name", "" + i);
map.put("new4", "" + i);
map.put("verifyState", "" + i);
recordList.add(map);
}
Pager pager = new Pager(pageIndex, pageSize, recordList.size(), recordList);
return pager;
}
} |
|