use of com.tony.billing.response.costrecord.CostRecordDetailResponse in project BillingDubbo by TonyJiangWJ.
the class CostRecordController method getDetail.
/**
* 获取详情
*
* @param request
* @return
*/
@RequestMapping(value = "/record/detail/get")
public CostRecordDetailResponse getDetail(@ModelAttribute("request") @Validated CostRecordDetailRequest request) {
CostRecordDetailResponse response = new CostRecordDetailResponse();
ResponseUtil.error(response);
try {
CostRecord record = costRecordService.findByTradeNo(request.getTradeNo(), request.getUserId());
if (record != null) {
response.setRecordDetail(formatDetailModel(record));
ResponseUtil.success(response);
}
} catch (Exception e) {
logger.error("/detail/get error", e);
}
return response;
}
Aggregations