private void makeData() { ERP_Member member = new ERP_Member(); member.setId("135698546"); member.setName("张三"); member.setSex("男"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12365954653"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setImageId(R.drawable.pic_head1); List<ERP_Order> records = new ArrayList<ERP_Order>(); ERP_Order order = new ERP_Order(); order.setOrderId("3569845522"); order.setOrderDate("2015-8-9 12:41"); order.setTotalAmount(120); records.add(order); order = new ERP_Order(); order.setOrderId("3569845698"); order.setOrderDate("2015-8-10 12:25"); order.setTotalAmount(135); records.add(order); member.setRecords(records); members.add(member); member = new ERP_Member(); member.setId("135698333"); member.setName("李红"); member.setSex("女"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12365698745"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head3); members.add(member); member = new ERP_Member(); member.setId("13569741"); member.setName("黄明"); member.setSex("男"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12365974981"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head2); members.add(member); member = new ERP_Member(); member.setId("135698011"); member.setName("李艳"); member.setSex("女"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12365969993"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head4); members.add(member); member = new ERP_Member(); member.setId("2659498546"); member.setName("陈杰"); member.setSex("男"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12365366217"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head6); members.add(member); member = new ERP_Member(); member.setId("1354445874"); member.setName("陈丹丹"); member.setSex("女"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12365951114"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head5); members.add(member); member = new ERP_Member(); member.setId("169845146"); member.setName("张科"); member.setSex("男"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12369878443"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head1); members.add(member); member = new ERP_Member(); member.setId("135693365"); member.setName("许晴"); member.setSex("女"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12399862872"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head3); members.add(member); member = new ERP_Member(); member.setId("135987412"); member.setName("张龙"); member.setSex("男"); member.setBalance(1000); member.setConsumeAmount(685); member.setConsumeCount(6); member.setMobile("12365933215"); member.setGrade("黄金会员"); member.setDate("2015-6-21"); member.setIntegral(1250); member.setRecords(records); member.setImageId(R.drawable.pic_head2); members.add(member); }
private void setDetail(ERP_Member member) { tv_member_name.setText(member.getName()); tv_member_id.setText("账号:" + member.getId()); tv_member_grade.setText(member.getGrade()); tv_member_balance.setText(member.getBalance() + "元"); tv_member_mobile.setText("手机:" + member.getMobile()); tv_member_date.setText("注册时间:" + member.getDate()); tv_member_integral.setText(member.getIntegral() + ""); tv_member_consume_amount.setText(member.getConsumeAmount() + "元"); tv_member_cousume_count.setText(member.getConsumeCount() + "次"); iv_member_head.setImageResource(member.getImageId()); if ("男".equals(member.getSex())) { iv_member_sex.setImageResource(R.drawable.man); } else { iv_member_sex.setImageResource(R.drawable.girl); } records = members.get(pos_member).getRecords(); adapter_record.update(records); }