dialog_add_error.xml 9.38 KB
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:background="@drawable/bg_solid_white_10_top"
    android:orientation="vertical">

    <RelativeLayout
        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:text="加入错题本"
            android:textColor="@color/text_title"
            android:textSize="17sp"
            android:textStyle="bold" />

        <ImageView
            android:id="@+id/iv_back"
            android:layout_width="35dp"
            android:layout_height="35dp"
            android:layout_alignParentRight="true"
            android:layout_centerVertical="true"
            android:layout_marginRight="10dp"
            android:padding="10dp"
            android:src="@mipmap/ic_close" />
    </RelativeLayout>

    <androidx.recyclerview.widget.RecyclerView
        android:id="@+id/list_item"
        android:layout_width="match_parent"
        android:layout_height="30dp"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="10dp"
        android:layout_marginRight="20dp" />

    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="90dp"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:layout_marginRight="20dp">

        <RelativeLayout
            android:layout_width="match_parent"
            android:layout_height="match_parent"
            android:background="#F5F5F5">

            <ImageView
                android:id="@+id/iv_topic"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_centerVertical="true" />
        </RelativeLayout>
    </RelativeLayout>

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerVertical="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:text="年级"
        android:textColor="@color/text_title"
        android:textSize="15sp"
        android:textStyle="bold" />

    <androidx.appcompat.widget.AppCompatSpinner
        android:id="@+id/spinner_grade"
        style="@style/customSpinnerStyle"
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_centerHorizontal="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="10dp"
        android:layout_marginRight="20dp"
        android:background="@drawable/selector_for_custom_spinner"
        android:popupBackground="@drawable/shape_for_custom_spinner"
        android:scrollbars="none" />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerVertical="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:text="学期"
        android:textColor="@color/text_title"
        android:textSize="15sp"
        android:textStyle="bold" />

    <androidx.appcompat.widget.AppCompatSpinner
        android:id="@+id/spinner_grade1"
        style="@style/customSpinnerStyle"
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_centerHorizontal="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="10dp"
        android:layout_marginRight="20dp"
        android:background="@drawable/selector_for_custom_spinner"
        android:entries="@array/grade_array"
        android:popupBackground="@drawable/shape_for_custom_spinner"
        android:scrollbars="none" />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerVertical="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:text="科目"
        android:textColor="@color/text_title"
        android:textSize="15sp"
        android:textStyle="bold" />

    <androidx.appcompat.widget.AppCompatSpinner
        android:id="@+id/spinner_subject"
        style="@style/customSpinnerStyle"
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_centerHorizontal="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="10dp"
        android:layout_marginRight="20dp"
        android:background="@drawable/selector_for_custom_spinner"
        android:entries="@array/filter_subject"
        android:popupBackground="@drawable/shape_for_custom_spinner"
        android:scrollbars="none" />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerVertical="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:text="错误原因"
        android:textColor="@color/text_title"
        android:textSize="15sp"
        android:textStyle="bold" />

    <androidx.appcompat.widget.AppCompatSpinner
        android:id="@+id/spinner_reason"
        style="@style/customSpinnerStyle"
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_centerHorizontal="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="10dp"
        android:layout_marginRight="20dp"
        android:background="@drawable/selector_for_custom_spinner"
        android:entries="@array/filter_subject"
        android:popupBackground="@drawable/shape_for_custom_spinner"
        android:scrollbars="none" />

    <TextView
        android:id="@+id/tv_student"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerVertical="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:text="学生"
        android:textColor="@color/text_title"
        android:visibility="gone"
        android:textSize="15sp"
        android:textStyle="bold" />

    <androidx.appcompat.widget.AppCompatSpinner
        android:id="@+id/spinner_student"
        style="@style/customSpinnerStyle"
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_centerHorizontal="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="10dp"
        android:layout_marginRight="20dp"
        android:visibility="gone"
        android:background="@drawable/selector_for_custom_spinner"
        android:entries="@array/filter_subject"
        android:popupBackground="@drawable/shape_for_custom_spinner"
        android:scrollbars="none" />

    <TextView
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerVertical="true"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:text="来源"
        android:textColor="@color/text_title"
        android:textSize="15sp"
        android:textStyle="bold" />

    <RadioGroup
        android:id="@+id/type_radio"
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="10dp"
        android:orientation="horizontal">

        <RadioButton
            android:layout_width="65dp"
            android:layout_height="match_parent"
            android:layout_marginRight="20dp"
            android:background="@drawable/radio_button_selector"
            android:button="@null"
            android:gravity="center"
            android:text="课内"
            android:textColor="@drawable/radio_text_selector"
            android:textSize="14sp" />

        <RadioButton
            android:layout_width="65dp"
            android:layout_height="match_parent"
            android:layout_marginRight="20dp"
            android:background="@drawable/radio_button_selector"
            android:button="@null"
            android:gravity="center"
            android:text="课外"
            android:textColor="@drawable/radio_text_selector"
            android:textSize="14sp" />
    </RadioGroup>


    <RelativeLayout
        android:layout_width="match_parent"
        android:layout_height="40dp"
        android:layout_marginLeft="20dp"
        android:layout_marginTop="20dp"
        android:layout_marginRight="20dp"
        android:layout_marginBottom="15dp">

        <TextView
            android:id="@+id/add_topic"
            android:layout_width="250dp"
            android:layout_height="match_parent"
            android:layout_alignParentRight="true"
            android:background="@drawable/bg_soild_blue_5"
            android:gravity="center"
            android:textColor="@color/white"
            android:textSize="17sp" />

        <CheckBox
            android:id="@+id/checkbox"
            android:layout_width="wrap_content"
            android:layout_height="30dp"
            android:layout_centerVertical="true"
            android:button="@drawable/checkbox_selector"
            android:text="批量设置"
            android:paddingLeft="8dp"
            android:textColor="@color/text_title"
            android:textSize="14sp" />

    </RelativeLayout>
</LinearLayout>