<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@color/color_f0"
    android:orientation="vertical">

    <com.google.android.material.appbar.AppBarLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:background="@color/color_f0"
        android:orientation="vertical"
        app:elevation="@dimen/dp_0">

        <com.qmuiteam.qmui.widget.QMUITopBar
            android:id="@+id/cold_chain_history_order_top_bar"
            android:layout_width="match_parent"
            android:layout_height="@dimen/head_height"
            android:fitsSystemWindows="true"
            app:qmui_topbar_text_btn_color_state_list="@color/theme_white_color"
            app:qmui_topbar_title_color="@color/theme_white_color" />

        <androidx.constraintlayout.widget.ConstraintLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:focusable="true"
            android:focusableInTouchMode="true"
            android:padding="@dimen/dp_10"
            android:visibility="gone">

            <EditText
                android:id="@+id/ed_order_num_search"
                android:layout_width="0dp"
                android:layout_height="@dimen/dp_38"
                android:layout_marginRight="@dimen/dp_10"
                android:background="@drawable/shape_white_search_bg"
                android:hint="請輸入手機號或訂單號"
                android:inputType="number"
                android:paddingLeft="@dimen/dp_10"
                android:paddingRight="@dimen/dp_50"
                android:textColor="@color/theme_333_color"
                android:textColorHint="@color/color_ccc"
                android:textSize="@dimen/dp_14"
                app:layout_constraintLeft_toLeftOf="parent"
                app:layout_constraintRight_toRightOf="parent"
                app:layout_constraintTop_toTopOf="parent" />

            <ImageView
                android:id="@+id/iv_search_order"
                android:layout_width="@dimen/dp_50"
                android:layout_height="0dp"
                android:padding="@dimen/dp_10"
                android:src="@drawable/ic_search"
                app:layout_constraintBottom_toBottomOf="@id/ed_order_num_search"
                app:layout_constraintRight_toRightOf="@id/ed_order_num_search"
                app:layout_constraintTop_toTopOf="@id/ed_order_num_search" />

            <TextView
                android:id="@+id/tv_start_time"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginTop="@dimen/dp_10"
                android:textColor="@color/theme_333_color"
                android:textSize="@dimen/dp_14"
                app:layout_constraintLeft_toLeftOf="@id/ed_order_num_search"
                app:layout_constraintTop_toBottomOf="@id/ed_order_num_search" />

            <com.gingersoft.gsa.cloud.ui.view.TriangleView
                android:id="@+id/iv_start_time_triangle"
                android:layout_width="@dimen/dp_8"
                android:layout_height="@dimen/dp_5"
                android:layout_marginLeft="@dimen/dp_2"
                app:layout_constraintBottom_toBottomOf="@id/tv_start_time"
                app:layout_constraintLeft_toRightOf="@id/tv_start_time"
                app:layout_constraintTop_toTopOf="@id/tv_start_time"
                app:trv_direction="bottom" />

            <TextView
                android:id="@+id/tv_to"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginLeft="@dimen/dp_10"
                android:text="至"
                android:textColor="@color/theme_333_color"
                android:textSize="@dimen/dp_14"
                android:visibility="gone"
                app:layout_constraintBottom_toBottomOf="@id/iv_start_time_triangle"
                app:layout_constraintLeft_toRightOf="@id/iv_start_time_triangle"
                app:layout_constraintTop_toTopOf="@id/iv_start_time_triangle" />


            <TextView
                android:id="@+id/tv_end_time"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginLeft="@dimen/dp_10"
                android:textColor="@color/theme_333_color"
                android:textSize="@dimen/dp_14"
                android:visibility="gone"
                app:layout_constraintBottom_toBottomOf="@id/tv_to"
                app:layout_constraintLeft_toRightOf="@id/tv_to"
                app:layout_constraintTop_toTopOf="@id/tv_to" />

            <com.gingersoft.gsa.cloud.ui.view.TriangleView
                android:id="@+id/iv_end_time_triangle"
                android:layout_width="@dimen/dp_8"
                android:layout_height="@dimen/dp_5"
                android:layout_marginLeft="@dimen/dp_2"
                android:visibility="gone"
                app:layout_constraintBottom_toBottomOf="@id/tv_end_time"
                app:layout_constraintLeft_toRightOf="@id/tv_end_time"
                app:layout_constraintTop_toTopOf="@id/tv_end_time"
                app:trv_direction="bottom" />
        </androidx.constraintlayout.widget.ConstraintLayout>

        <com.google.android.material.tabs.TabLayout
            android:id="@+id/history_tabs"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:background="@color/white"
            app:tabPaddingEnd="-1dp"
            app:tabPaddingStart="-1dp"
            app:tabSelectedTextColor="@color/theme_color"
            app:tabTextColor="@color/color_ccc">

            <com.google.android.material.tabs.TabItem
                android:id="@+id/tabItem_completed"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="已完成" />

            <com.google.android.material.tabs.TabItem
                android:id="@+id/tabItem_cancelled"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:text="已取消" />

        </com.google.android.material.tabs.TabLayout>
    </com.google.android.material.appbar.AppBarLayout>

    <com.scwang.smartrefresh.layout.SmartRefreshLayout
        android:id="@+id/cold_chain_history_refresh_layout"
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <FrameLayout
            android:id="@+id/content_layout"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />
    </com.scwang.smartrefresh.layout.SmartRefreshLayout>
</LinearLayout>