| | |
| | | import com.google.gson.*; |
| | | import com.yeshi.buwan.domain.user.LoginUser; |
| | | import com.yeshi.buwan.domain.vip.UserVIPInfo; |
| | | import com.yeshi.buwan.domain.vip.VIPOrderRecord; |
| | | import com.yeshi.buwan.domain.vip.OrderRecord; |
| | | import com.yeshi.buwan.service.inter.LoginUserService; |
| | | import com.yeshi.buwan.service.inter.order.OrderService; |
| | | import com.yeshi.buwan.service.inter.vip.VIPService; |
| | | import com.yeshi.buwan.util.Constant; |
| | | import com.yeshi.buwan.util.StringUtil; |
| | |
| | | |
| | | @Resource |
| | | private VIPService vipService; |
| | | |
| | | @Resource |
| | | private OrderService orderService; |
| | | |
| | | @Resource |
| | | private LoginUserService loginUserService; |
| | |
| | | Integer state = null; |
| | | if (pay != null) { |
| | | if (pay) { |
| | | state = VIPOrderRecord.STATE_PAY; |
| | | state = OrderRecord.STATE_PAY; |
| | | } else { |
| | | state = VIPOrderRecord.STATE_NOT_PAY; |
| | | state = OrderRecord.STATE_NOT_PAY; |
| | | } |
| | | } |
| | | |
| | | List<VIPOrderRecord> list = vipService.listOrderRecord(uid, state, page, Constant.pageCount); |
| | | long count = vipService.countOrderRecord(uid, state); |
| | | List<OrderRecord> list = orderService.listOrderRecord(uid,null, state, page, Constant.pageCount); |
| | | long count = orderService.countOrderRecord(uid,null, state); |
| | | JSONObject data = new JSONObject(); |
| | | data.put("pageEntity", new PageEntity(page, Constant.pageCount, (int) count)); |
| | | data.put("list", getGson().toJson(list)); |