订单的布局

//activity_main
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:orientation="vertical"
    tools:context="com.bwie.mydingdan.MainActivity">

    <RelativeLayout
        android:background="#fff"
        android:layout_width="match_parent"
        android:layout_height="50dp">
        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_centerInParent="true"
            android:textSize="20sp"
            android:text="订单列表"/>
        <ImageView
            android:id="@+id/image_btn"
            android:layout_width="25dp"
            android:layout_height="25dp"
            android:clickable="true"
            android:layout_alignParentRight="true"
            android:layout_centerVertical="true"
            android:layout_marginRight="20dp"
            android:background="@drawable/lv_icon"/>
    </RelativeLayout>
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="50dp"

        android:orientation="horizontal">
        <TextView
            android:id="@+id/text_daizhi"
            android:layout_width="0dp"
            android:layout_weight="1"
            android:gravity="center"
            android:layout_height="match_parent"
            android:textSize="16sp"
            android:background="@drawable/biankuang"
            android:text="待支付"/>
        <TextView
            android:id="@+id/text_yizhi"
            android:layout_width="0dp"
            android:layout_weight="1"
            android:gravity="center"
            android:layout_height="match_parent"
            android:textSize="16sp"
            android:background="@drawable/biankuang"
            android:text="已支付"/>
        <TextView
            android:id="@+id/text_yiqu"
            android:layout_width="0dp"
            android:layout_weight="1"
            android:gravity="center"
            android:layout_height="match_parent"
            android:textSize="16sp"
            android:background="@drawable/biankuang"
            android:text="已取消"/>
    </LinearLayout>
    <FrameLayout
        android:id="@+id/frame_layout"
        android:layout_width="match_parent"
        android:layout_height="match_parent"></FrameLayout>

</LinearLayout>
 
//frag_daizhi
<RelativeLayout
    xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent"
    android:layout_height="match_parent">
    <com.scwang.smartrefresh.layout.SmartRefreshLayout
        android:id="@+id/smart_refresh"
        android:layout_width="match_parent"
        android:layout_height="match_parent">
        <ScrollView
            android:layout_width="match_parent"
            android:layout_height="match_parent">
            <android.support.v7.widget.RecyclerView
                android:id="@+id/recycler_daizhi"
                android:layout_width="match_parent"
                android:layout_height="match_parent"></android.support.v7.widget.RecyclerView>
        </ScrollView>
    </com.scwang.smartrefresh.layout.SmartRefreshLayout>
    <RelativeLayout
        android:id="@+id/relative_bar"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerInParent="true">
        <ProgressBar
            android:layout_width="wrap_content"
            android:layout_height="wrap_content" />
    </RelativeLayout>

</RelativeLayout>
//item_dingdan适配器
<LinearLayout
    android:orientation="vertical"
    xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent"
    android:layout_height="wrap_content">
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_marginLeft="20dp"
        android:layout_marginRight="20dp"
        android:orientation="horizontal">
        <TextView
            android:id="@+id/text_title"
            android:layout_width="0dp"
            android:layout_weight="1"
            android:gravity="bottom"
            android:layout_height="match_parent"
            android:text="1111"/>
        <TextView
            android:id="@+id/text_daizhifu"
            android:layout_width="50dp"
            android:gravity="bottom"
            android:layout_height="match_parent"
            android:textColor="#ff0000"
            android:text="待支付"/>
    </LinearLayout>
    <TextView
        android:id="@+id/text_price"
        android:gravity="bottom"
        android:textColor="#ff0000"
        android:layout_marginLeft="20dp"
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:text="1111"/>
    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_marginLeft="20dp"
        android:layout_marginRight="20dp"
        android:orientation="horizontal">
        <TextView
            android:id="@+id/text_tame"
            android:layout_width="0dp"
            android:layout_weight="1"
            android:gravity="bottom"
            android:layout_height="match_parent"
            android:text="1111"/>
        <TextView
            android:id="@+id/text_btn"
            android:layout_width="70dp"
            android:gravity="center"
            android:layout_gravity="bottom"
            android:layout_height="30dp"
            android:background="@drawable/biankuang"
            android:text="取消订单"/>
    </LinearLayout>
    <TextView
        android:layout_marginTop="15dp"
        android:clickable="true"
        android:focusable="false"
        android:layout_width="match_parent"
        android:layout_height="1dp"
        android:background="#9999"/>

</LinearLayout>
//PopupWindow布局
<RelativeLayout
    xmlns:android="http://schemas.android.com/apk/res/android" android:layout_width="match_parent"
    android:layout_height="match_parent">
    <LinearLayout
        android:layout_width="100dp"
        android:layout_height="wrap_content"

        android:orientation="vertical">
        <TextView
            android:id="@+id/btn_daizhi"
            android:layout_width="match_parent"
            android:layout_weight="1"
            android:gravity="center"
            android:layout_height="0dp"
            android:textSize="16sp"
            android:padding="15dp"
            android:background="@drawable/select_dianji"
            android:text="待支付"/>
        <TextView
            android:id="@+id/btn_yizhi"
            android:layout_width="match_parent"
            android:layout_weight="1"
            android:gravity="center"
            android:layout_height="0dp"
            android:textSize="16sp"
            android:padding="15dp"
            android:background="@drawable/select_dianji"
            android:text="已支付"/>
        <TextView
            android:id="@+id/btn_yiqu"
            android:layout_width="match_parent"
            android:layout_weight="1"
            android:gravity="center"
            android:layout_height="0dp"
            android:textSize="16sp"
            android:padding="15dp"
            android:background="@drawable/select_dianji"
            android:text="已取消"/>
    </LinearLayout>
</RelativeLayout>

 

                
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值