Commit 19f00c42 authored by 姜敏's avatar 姜敏

添加颜色

parent 2060f676
......@@ -5,7 +5,12 @@ import android.view.inputmethod.EditorInfo;
import com.blankj.utilcode.util.KeyboardUtils;
import com.xingdata.zzdpos.R;
import com.xingdata.zzdpos.base.BaseActivity;
import com.xingdata.zzdpos.base.BaseSku;
import com.xingdata.zzdpos.databinding.ActivityStoreBinding;
import com.xingdata.zzdpos.model.Ms;
import com.xingdata.zzdpos.model.Sskugrp;
import java.util.List;
public class StoreActivity extends BaseActivity<StorePresenter, ActivityStoreBinding> implements StoreContract.View {
......@@ -27,4 +32,24 @@ public class StoreActivity extends BaseActivity<StorePresenter, ActivityStoreBin
return false;
});
}
@Override
public <Sku extends BaseSku> void loadSkus(List<Sku> skus, boolean isRefresh) {
}
@Override
public void loadSkugrps(List<Sskugrp> sskugrps) {
}
@Override
public void loadMss(List<Ms> mss) {
}
@Override
public <Sku extends BaseSku> void loadSearchResult(List<Sku> skus, boolean isRefresh) {
}
}
package com.xingdata.zzdpos.ui.vip.adapter;
import android.content.Context;
import android.support.annotation.Nullable;
import com.xingdata.zzdpos.R;
import com.xingdata.zzdpos.base.BaseAdapter;
import com.xingdata.zzdpos.databinding.ItemVipListItemBinding;
import com.xingdata.zzdpos.databinding.ItemVipRechargeItemBinding;
import com.xingdata.zzdpos.model.Vip;
import com.xingdata.zzdpos.model.VipRechangeOrder;
import java.util.List;
/**
* Created by JM_DEV on 2017/12/25.
*/
public class VipRechargeAdapter extends BaseAdapter<VipRechangeOrder, ItemVipRechargeItemBinding> {
private Context mContext;
public VipRechargeAdapter(Context mContext, @Nullable List<VipRechangeOrder> data) {
super(R.layout.item_vip_list_item, data);
this.mContext=mContext;
}
@Override
protected void convert(ItemVipRechargeItemBinding mViewBinding, VipRechangeOrder item) {
// mViewBinding.vipName.setText(item.getVipName());
// mViewBinding.vipMobile.setText(String.valueOf(item.getVipMobile()));
// mViewBinding.vipDiscount.setText(String.valueOf(item.getVipDefDiscount()));
}
}
......@@ -4,15 +4,25 @@ package com.xingdata.zzdpos.ui.vip.fragment;
* Created by JM_DEV on 2017/12/21.
*/
import android.support.v7.widget.LinearLayoutManager;
import com.blankj.utilcode.util.ToastUtils;
import com.xingdata.zzdpos.R;
import com.xingdata.zzdpos.base.BaseFragment;
import com.xingdata.zzdpos.databinding.FragmentVipinfoBinding;
import com.xingdata.zzdpos.model.VipRechangeOrder;
import com.xingdata.zzdpos.ui.vip.VipPresenter;
import com.xingdata.zzdpos.ui.vip.adapter.VipRechargeAdapter;
import java.util.ArrayList;
import java.util.List;
/**
* 会员信息界面
*/
public class VipInfoFragment extends BaseFragment<VipPresenter, FragmentVipinfoBinding> {
private VipRechargeAdapter vipRechargeAdapter;
private List<VipRechangeOrder> orders = new ArrayList<>();
@Override
public int getLayoutId() {
return R.layout.fragment_vipinfo;
......@@ -20,7 +30,16 @@ public class VipInfoFragment extends BaseFragment<VipPresenter, FragmentVipinfoB
@Override
public void initView() {
vipRechargeAdapter = new VipRechargeAdapter(getActivity(), orders);
mViewBinding.rechargeRecyclerView.setLayoutManager( new LinearLayoutManager(getActivity()));
mViewBinding.rechargeRecyclerView.setAdapter(vipRechargeAdapter);
mViewBinding.rechargeRefresh.setOnRefreshListener(this::onRefresh);
}
private void onRefresh() {
vipRechargeAdapter.addData(new ArrayList<VipRechangeOrder>());
mViewBinding.rechargeRefresh.setRefreshing(false);
ToastUtils.showShort("刷新成功");
}
@Override
......
......@@ -38,6 +38,9 @@ public class VipListFragment extends BaseFragment<VipPresenter, FragmentVipListB
mViewBinding.vipRecyclerView.setLayoutManager( new LinearLayoutManager(getActivity()));
mViewBinding.vipRecyclerView.setAdapter(vipListAdapter);
mViewBinding.vipRefresh.setOnRefreshListener(this::onRefresh);
mViewBinding.vipRecyclerView.setOnClickListener(view -> {
start(new VipInfoFragment());
});
}
private void onRefresh() {
......
......@@ -4,9 +4,126 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/white"
android:background="@color/bg"
android:orientation="vertical">
<include layout="@layout/title"/>
<include layout="@layout/title_pop" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/white"
android:orientation="horizontal">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="@dimen/all_margin"
android:layout_marginTop="@dimen/all_margin"
android:layout_weight="1"
android:background="@color/white"
android:orientation="vertical">
<TextView
style="@style/default_blacktext_bigstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="张思" />
<TextView
style="@style/default_blacktext_smallstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="13311525312" />
</LinearLayout>
<TextView
style="@style/default_blacktext_smallstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_margin="@dimen/all_margin"
android:text="@string/vip_info_discount" />
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/line_bg"></View>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/white"
android:gravity="center_vertical"
android:orientation="horizontal">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center_horizontal"
android:orientation="vertical">
<TextView
style="@style/default_blacktext_smallstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="可用金額" />
<TextView
style="@style/default_blacktext_bigstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="50.00"
android:textColor="@color/reddeep" />
</LinearLayout>
<View
android:layout_width="1dp"
android:layout_height="40dp"
android:background="@color/line_bg"></View>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center_horizontal"
android:orientation="vertical">
<TextView
style="@style/default_blacktext_smallstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="可用金額" />
<TextView
style="@style/default_blacktext_bigstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="160.00"
android:textColor="@color/reddeep" />
</LinearLayout>
</LinearLayout>
<View
android:layout_width="match_parent"
android:layout_height="1dp"
android:background="@color/line_bg"></View>
<android.support.v4.widget.SwipeRefreshLayout
android:id="@+id/recharge_refresh"
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.v7.widget.RecyclerView
android:id="@+id/rechargeRecyclerView"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</android.support.v4.widget.SwipeRefreshLayout>
</LinearLayout>
</layout>
\ No newline at end of file
<?xml version="1.0" encoding="utf-8"?>
<layout>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="center_vertical"
android:orientation="horizontal">
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="@dimen/all_margin"
android:background="@mipmap/pay_alipay" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_weight="1"
android:orientation="vertical">
<TextView
android:id="@+id/rechange_type"
style="@style/default_blacktext_bigstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="支付宝支付" />
<TextView
android:id="@+id/rechange_time"
style="@style/default_blacktext_smallstyle"
android:layout_width="wrap_content"
android:textColor="@color/black_likui"
android:layout_height="wrap_content"
android:text="08-09 10:10" />
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_margin="@dimen/all_margin"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="right"
android:orientation="vertical">
<TextView
android:id="@+id/rechange_money"
style="@style/default_blacktext_bigstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="+充值金额" />
<TextView
android:id="@+id/rechange_shop"
android:textColor="@color/black_likui"
style="@style/default_blacktext_smallstyle"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="充值总店" />
</LinearLayout>
</LinearLayout>
</layout>
\ No newline at end of file
......@@ -5,26 +5,24 @@
<variable
name="onClickListener"
type="com.xingdata.zzdpos.util.OnClickListener"/>
type="com.xingdata.zzdpos.util.OnClickListener" />
</data>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="@drawable/singleline_white_gray"
android:orientation="horizontal">
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="@drawable/singleline_white_gray"
android:orientation="horizontal">
<ImageButton
android:id="@+id/iv_back"
android:layout_width="?attr/actionBarSize"
android:layout_width="60dp"
android:layout_height="match_parent"
android:background="@color/transparent"
android:onClick="@{onClickListener}"
android:padding="@dimen/all_margin"
android:src="@mipmap/back_black"/>
android:background="@mipmap/go_back"
android:onClick="@{onClickListener}" />
<TextView
android:id="@+id/tv_title"
......@@ -33,7 +31,7 @@
android:layout_centerInParent="true"
android:text="标题"
android:textColor="@color/black_baozheng"
android:textSize="@dimen/text_secondary_title"/>
android:textSize="@dimen/text_secondary_title" />
</RelativeLayout>
......
<?xml version="1.0" encoding="utf-8"?>
<layout>
<data>
<variable
name="onClickListener"
type="com.xingdata.zzdpos.util.OnClickListener" />
</data>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="@drawable/singleline_white_gray"
android:orientation="horizontal">
<ImageButton
android:id="@+id/iv_back"
android:layout_width="?attr/actionBarSize"
android:layout_height="match_parent"
android:background="@mipmap/go_back"
android:onClick="@{onClickListener}" />
<TextView
android:id="@+id/tv_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:text="标题"
android:textColor="@color/black_baozheng"
android:textSize="@dimen/text_secondary_title" />
<ImageButton
android:id="@+id/pop_menu"
android:layout_width="60dp"
android:layout_height="match_parent"
android:layout_alignParentRight="true"
android:background="@mipmap/pop_menu"
android:onClick="@{onClickListener}" />
</RelativeLayout>
</layout>
\ No newline at end of file
......@@ -129,6 +129,8 @@
<string name="vip_message_point_amt_hint">积分可抵金额</string>
<string name="vip_message_point_cr_hint">(100积分=1元)</string>
<string name="vip_message_ticket_none">不使用优惠券</string>
<string name="vip_info_discount">折扣:%s折</string>
<!--抹零页面-->
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment