Advertisement
kitlolz012

book form xml

Nov 21st, 2023 (edited)
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
XML 24.67 KB | None | 0 0
  1. NOTE:
  2. Para makuha ung android:src="@drawable/baseline_content_copy_24" Sa Imageview Under Hotel Gcash Number Baka mag kaiba ung satin dahil sa device
  3.  
  4. Right click sa drawable > New > Vector Asset > click Clip art > Search Copy > Content Copy name > next > Finish
  5.  
  6.  
  7. XML CODE
  8. <?xml version="1.0" encoding="utf-8"?>
  9. <androidx.coordinatorlayout.widget.CoordinatorLayout
  10.    xmlns:android="http://schemas.android.com/apk/res/android"
  11.    xmlns:app="http://schemas.android.com/apk/res-auto"
  12.    xmlns:tools="http://schemas.android.com/tools"
  13.    android:layout_width="match_parent"
  14.    android:layout_height="match_parent"
  15.    android:fillViewport="true"
  16.    tools:context=".BookForm">
  17.  
  18.     <com.google.android.material.appbar.AppBarLayout
  19.        android:id="@+id/appbar"
  20.        android:layout_width="match_parent"
  21.        android:layout_height="wrap_content"
  22.        android:fitsSystemWindows="true"
  23.        android:background="@color/nocolor"
  24.        app:elevation="0dp"
  25.        app:liftOnScroll="true">
  26.  
  27.         <com.google.android.material.appbar.CollapsingToolbarLayout
  28.            android:layout_width="match_parent"
  29.            android:layout_height="wrap_content"
  30.            android:fitsSystemWindows="true"
  31.            app:contentScrim="@drawable/fragbg"
  32.            app:title="Make your reservation"
  33.            app:collapsedTitleTextColor="@color/white"
  34.            app:layout_scrollFlags="scroll|exitUntilCollapsed">
  35.  
  36.             <ImageView
  37.                android:layout_width="match_parent"
  38.                android:layout_height="120dp"
  39.                android:background="@drawable/fragbg"
  40.                app:layout_collapseMode="parallax"
  41.                app:layout_collapseParallaxMultiplier="0.7" />
  42.  
  43.             <androidx.appcompat.widget.Toolbar
  44.                android:id="@+id/toolbar"
  45.                android:layout_width="match_parent"
  46.                android:layout_height="?attr/actionBarSize"
  47.                app:layout_collapseMode="pin"
  48.                app:layout_scrollFlags="scroll|enterAlways" />
  49.  
  50.         </com.google.android.material.appbar.CollapsingToolbarLayout>
  51.     </com.google.android.material.appbar.AppBarLayout>
  52.  
  53.     <androidx.core.widget.NestedScrollView
  54.        android:layout_width="match_parent"
  55.        android:layout_height="match_parent"
  56.        app:layout_behavior="@string/appbar_scrolling_view_behavior">
  57.  
  58.         <LinearLayout
  59.            android:layout_width="match_parent"
  60.            android:layout_height="wrap_content"
  61.            android:orientation="vertical"
  62.            android:padding="16dp">
  63.  
  64.  
  65.             <com.google.android.material.textfield.TextInputLayout
  66.                android:layout_width="match_parent"
  67.                android:layout_height="wrap_content"
  68.                android:layout_marginTop="5dp"
  69.                android:hint="Full Name">
  70.  
  71.                 <com.google.android.material.textfield.TextInputEditText
  72.                    android:id="@+id/fullNameET"
  73.                    android:layout_width="match_parent"
  74.                    android:layout_height="wrap_content"
  75.                    android:padding="15dp"/>
  76.             </com.google.android.material.textfield.TextInputLayout>
  77.  
  78.             <LinearLayout
  79.                android:layout_width="match_parent"
  80.                android:layout_height="wrap_content"
  81.                android:layout_marginTop="5dp"
  82.                android:orientation="horizontal">
  83.                 <com.google.android.material.textfield.TextInputLayout
  84.                    android:layout_width="0dp"
  85.                    android:layout_height="wrap_content"
  86.                    android:layout_weight="1"
  87.                    android:hint="Check-In Date">
  88.  
  89.                     <com.google.android.material.textfield.TextInputEditText
  90.                        android:id="@+id/checkInDateET"
  91.                        android:layout_width="match_parent"
  92.                        android:layout_height="wrap_content"
  93.                        android:padding="15dp"
  94.                        android:focusable="false"
  95.                        android:clickable="true"
  96.                        android:focusableInTouchMode="false"/>
  97.                 </com.google.android.material.textfield.TextInputLayout>
  98.  
  99.                 <com.google.android.material.textfield.TextInputLayout
  100.                    android:layout_width="0dp"
  101.                    android:layout_height="wrap_content"
  102.                    android:layout_weight="1"
  103.                    android:hint="Check-Out Date">
  104.  
  105.                     <com.google.android.material.textfield.TextInputEditText
  106.                        android:id="@+id/checkOutDateET"
  107.                        android:layout_width="match_parent"
  108.                        android:layout_height="wrap_content"
  109.                        android:padding="15dp"
  110.                        android:focusable="false"
  111.                        android:clickable="true"
  112.                        android:focusableInTouchMode="false"/>
  113.                 </com.google.android.material.textfield.TextInputLayout>
  114.             </LinearLayout>
  115.  
  116.             <LinearLayout
  117.                android:layout_width="match_parent"
  118.                android:layout_height="wrap_content"
  119.                android:layout_marginTop="5dp"
  120.                android:orientation="horizontal">
  121.  
  122.                 <LinearLayout
  123.                    android:layout_width="0dp"
  124.                    android:layout_height="wrap_content"
  125.                    android:layout_gravity="center"
  126.                    android:layout_weight="1"
  127.                    android:gravity="center"
  128.                    android:orientation="vertical">
  129.  
  130.                     <TextView
  131.                        android:layout_width="wrap_content"
  132.                        android:layout_height="wrap_content"
  133.                        android:text="Adults"
  134.                        android:textSize="16sp" />
  135.  
  136.                     <LinearLayout
  137.                        android:layout_width="wrap_content"
  138.                        android:layout_height="wrap_content"
  139.                        android:orientation="horizontal"
  140.                        android:gravity="center">
  141.  
  142.                         <androidx.appcompat.widget.AppCompatButton
  143.                            android:id="@+id/minusButton"
  144.                            android:layout_width="35dp"
  145.                            android:layout_height="35dp"
  146.                            android:background="@drawable/box2"
  147.                            android:onClick="decrementValue"
  148.                            android:text="—"
  149.                            android:textColor="@color/textcolor"
  150.                            android:textSize="15sp"
  151.                            tools:ignore="TouchTargetSizeCheck" />
  152.  
  153.                         <TextView
  154.                            android:layout_width="wrap_content"
  155.                            android:layout_height="wrap_content"
  156.                            android:id="@+id/adultsNumberPicker"
  157.                            android:text="0"
  158.                            android:textSize="16sp"
  159.                            android:layout_marginHorizontal="10dp"/>
  160.  
  161.                         <androidx.appcompat.widget.AppCompatButton
  162.                            android:id="@+id/plusButton"
  163.                            android:layout_width="35dp"
  164.                            android:layout_height="35dp"
  165.                            android:background="@drawable/box2"
  166.                            android:onClick="incrementValue"
  167.                            android:text="+"
  168.                            android:textColor="@color/textcolor"
  169.                            android:textSize="15sp"
  170.                            tools:ignore="TouchTargetSizeCheck" />
  171.  
  172.                     </LinearLayout>
  173.                 </LinearLayout>
  174.  
  175.                 <LinearLayout
  176.                    android:layout_width="0dp"
  177.                    android:layout_height="wrap_content"
  178.                    android:layout_gravity="center"
  179.                    android:layout_weight="1"
  180.                    android:gravity="center"
  181.                    android:orientation="vertical">
  182.  
  183.                     <TextView
  184.                        android:layout_width="wrap_content"
  185.                        android:layout_height="wrap_content"
  186.                        android:text="Children"
  187.                        android:textSize="16sp" />
  188.  
  189.                     <LinearLayout
  190.                        android:layout_width="wrap_content"
  191.                        android:layout_height="wrap_content"
  192.                        android:orientation="horizontal"
  193.                        android:gravity="center">
  194.  
  195.                         <androidx.appcompat.widget.AppCompatButton
  196.                            android:id="@+id/minusButton2"
  197.                            android:layout_width="35dp"
  198.                            android:layout_height="35dp"
  199.                            android:background="@drawable/box2"
  200.                            android:onClick="decrementValue2"
  201.                            android:text="—"
  202.                            android:textColor="@color/textcolor"
  203.                            android:textSize="15sp"
  204.                            tools:ignore="TouchTargetSizeCheck" />
  205.  
  206.                         <TextView
  207.                            android:layout_width="wrap_content"
  208.                            android:layout_height="wrap_content"
  209.                            android:id="@+id/childrenNumberPicker"
  210.                            android:text="0"
  211.                            android:textSize="16sp"
  212.                            android:layout_marginHorizontal="10dp"/>
  213.  
  214.                         <androidx.appcompat.widget.AppCompatButton
  215.                            android:id="@+id/plusButton2"
  216.                            android:layout_width="35dp"
  217.                            android:layout_height="35dp"
  218.                            android:background="@drawable/box2"
  219.                            android:onClick="incrementValue2"
  220.                            android:text="+"
  221.                            android:textColor="@color/textcolor"
  222.                            android:textSize="15sp"
  223.                            tools:ignore="TouchTargetSizeCheck" />
  224.  
  225.                     </LinearLayout>
  226.                 </LinearLayout>
  227.  
  228.             </LinearLayout>
  229.  
  230.             <com.google.android.material.textfield.TextInputLayout
  231.                android:layout_width="match_parent"
  232.                android:layout_height="wrap_content"
  233.                android:layout_marginTop="5dp"
  234.                android:hint="Contact Number">
  235.  
  236.                 <com.google.android.material.textfield.TextInputEditText
  237.                    android:id="@+id/contactNumberET"
  238.                    android:layout_width="match_parent"
  239.                    android:layout_height="wrap_content"
  240.                    android:padding="15dp"/>
  241.             </com.google.android.material.textfield.TextInputLayout>
  242.  
  243.             <com.google.android.material.textfield.TextInputLayout
  244.                android:layout_width="match_parent"
  245.                android:layout_height="wrap_content"
  246.                android:layout_marginTop="5dp"
  247.                android:hint="Email">
  248.  
  249.                 <com.google.android.material.textfield.TextInputEditText
  250.                    android:id="@+id/emailET"
  251.                    android:layout_width="match_parent"
  252.                    android:layout_height="wrap_content"
  253.                    android:padding="15dp"/>
  254.             </com.google.android.material.textfield.TextInputLayout>
  255.  
  256.  
  257.             <LinearLayout
  258.                android:layout_width="match_parent"
  259.                android:layout_height="wrap_content"
  260.                android:layout_marginTop="5dp"
  261.                android:orientation="horizontal">
  262.  
  263.                 <TextView
  264.                    android:layout_width="0dp"
  265.                    android:layout_weight="1"
  266.                    android:layout_marginTop="10dp"
  267.                    android:layout_height="wrap_content"
  268.                    android:text="Select room type"
  269.                    android:textColor="@color/white"
  270.                    android:fontFamily="@font/roboto_bold"
  271.                    android:layout_marginVertical="10dp"
  272.                    android:textSize="16sp"/>
  273.  
  274.                 <Spinner
  275.                    android:id="@+id/roomPreferenceSpinner"
  276.                    android:layout_width="0dp"
  277.                    android:layout_weight="1"
  278.                    android:layout_height="wrap_content"
  279.                    android:layout_marginTop="10dp"
  280.                    android:layout_marginBottom="10dp"
  281.                    android:hint="Room Preference"
  282.                    style="@android:style/Widget.Spinner"
  283.                    android:padding="8dp"
  284.                    android:dropDownWidth="match_parent"
  285.                    android:contentDescription="Select your room preference"
  286.                    android:popupBackground="#FFF"/>
  287.             </LinearLayout>
  288.  
  289.             <LinearLayout
  290.                android:layout_width="match_parent"
  291.                android:layout_height="wrap_content"
  292.                android:orientation="vertical"
  293.                android:padding="16dp"
  294.                android:layout_marginBottom="10dp"
  295.                android:layout_marginTop="10dp"
  296.                android:background="@drawable/box2">
  297.  
  298.                 <TextView
  299.                    android:layout_width="wrap_content"
  300.                    android:layout_height="wrap_content"
  301.                    android:text="Deposit on this Account"
  302.                    android:textSize="20sp"
  303.                    android:layout_gravity="center_horizontal" />
  304.  
  305.                 <LinearLayout
  306.                    android:layout_width="match_parent"
  307.                    android:layout_height="wrap_content"
  308.                    android:orientation="horizontal">
  309.  
  310.                     <TextView
  311.                        android:layout_width="wrap_content"
  312.                        android:layout_height="wrap_content"
  313.                        android:text="Hotel Gcash Number : "
  314.                        android:textColor="@color/black"
  315.                        android:textSize="13sp"
  316.                        android:gravity="end"
  317.                        android:paddingEnd="1dp"/>
  318.  
  319.                     <TextView
  320.                        android:id="@+id/gcashDepositNumberET"
  321.                        android:layout_width="0dp"
  322.                        android:layout_weight="0.1"
  323.                        android:layout_height="wrap_content"
  324.                        android:padding="10dp"
  325.                        android:hint="Hotel Gcash Number"
  326.                        android:inputType="text"/>
  327.  
  328.                     <ImageView
  329.                        android:id="@+id/copyImageView"
  330.                        android:layout_width="wrap_content"
  331.                        android:layout_height="match_parent"
  332.                        android:contentDescription="Copy"
  333.                        android:paddingStart="1dp"
  334.                        android:src="@drawable/baseline_content_copy_24" />
  335.                 </LinearLayout>
  336.  
  337.  
  338.                 <!-- Hotel Gcash Name -->
  339.                 <LinearLayout
  340.                    android:layout_width="match_parent"
  341.                    android:layout_height="wrap_content"
  342.                    android:orientation="horizontal">
  343.  
  344.                     <TextView
  345.                        android:layout_width="wrap_content"
  346.                        android:layout_height="wrap_content"
  347.                        android:text="Hotel Gcash Name : "
  348.                        android:textColor="@color/black"
  349.                        android:textSize="13sp"
  350.                        android:gravity="end"
  351.                        android:paddingEnd="5dp"/>
  352.  
  353.                     <TextView
  354.                        android:id="@+id/gcashDepositNameET"
  355.                        android:layout_width="0dp"
  356.                        android:layout_weight="0.1"
  357.                        android:layout_height="wrap_content"
  358.                        android:padding="10dp"
  359.                        android:hint="Hotel Gcash Name"
  360.                        android:inputType="text"/>
  361.                 </LinearLayout>
  362.  
  363.                 <LinearLayout
  364.                    android:layout_width="wrap_content"
  365.                    android:layout_height="match_parent"
  366.                    android:orientation="horizontal">
  367.  
  368.                     <TextView
  369.                        android:layout_width="wrap_content"
  370.                        android:layout_height="wrap_content"
  371.                        android:text="Reserve Fee : "
  372.                        android:textColor="@color/black"
  373.                        android:textSize="16sp"
  374.                        android:gravity="end"
  375.                        android:paddingEnd="8dp"/>
  376.  
  377.                     <TextView
  378.                        android:id="@+id/reservefeeET"
  379.                        android:layout_width="0dp"
  380.                        android:layout_weight="1"
  381.                        android:layout_height="wrap_content"
  382.                        android:padding="15dp"
  383.                        android:hint="Reserve Fee"
  384.                        android:inputType="text"/>
  385.  
  386.  
  387.                 </LinearLayout>
  388.  
  389.  
  390.  
  391.  
  392.             </LinearLayout>
  393.  
  394.  
  395.             <TextView
  396.                android:layout_width="wrap_content"
  397.                android:layout_height="wrap_content"
  398.                android:text="Deposit Form"
  399.                android:textColor="@color/white"
  400.                android:fontFamily="@font/roboto_bold"
  401.                android:layout_marginVertical="10dp"
  402.                android:textSize="20sp"
  403.                android:layout_gravity="center_horizontal" />
  404.  
  405.  
  406.             <androidx.cardview.widget.CardView
  407.                android:layout_width="match_parent"
  408.                android:layout_height="wrap_content"
  409.                app:cardElevation="6dp"
  410.                android:layout_margin="5dp"
  411.                app:cardCornerRadius="20dp">
  412.  
  413.                 <LinearLayout
  414.                    android:layout_width="match_parent"
  415.                    android:layout_height="wrap_content"
  416.                    android:orientation="vertical"
  417.                    android:padding="16dp">
  418.  
  419.                     <TextView
  420.                        android:layout_width="wrap_content"
  421.                        android:layout_height="wrap_content"
  422.                        android:text="Enter your Gcash number"
  423.                        android:layout_marginBottom="15dp"
  424.                        android:fontFamily="@font/roboto_bold"
  425.                        android:textSize="16sp"/>
  426.  
  427.                     <com.google.android.material.textfield.TextInputLayout
  428.                        android:layout_width="match_parent"
  429.                        android:layout_height="wrap_content"
  430.                        android:hint="Gcash Number">
  431.  
  432.                         <com.google.android.material.textfield.TextInputEditText
  433.                            android:id="@+id/yourGcashNumberET"
  434.                            android:layout_width="match_parent"
  435.                            android:layout_height="wrap_content"
  436.                            android:padding="15dp"/>
  437.                     </com.google.android.material.textfield.TextInputLayout>
  438.  
  439.                 </LinearLayout>
  440.             </androidx.cardview.widget.CardView>
  441.  
  442.             <androidx.cardview.widget.CardView
  443.                android:layout_width="match_parent"
  444.                android:layout_height="wrap_content"
  445.                app:cardElevation="6dp"
  446.                android:layout_margin="5dp"
  447.                app:cardCornerRadius="20dp">
  448.  
  449.                 <LinearLayout
  450.                    android:layout_width="match_parent"
  451.                    android:layout_height="wrap_content"
  452.                    android:orientation="vertical"
  453.                    android:padding="16dp">
  454.  
  455.                     <TextView
  456.                        android:layout_width="wrap_content"
  457.                        android:layout_height="wrap_content"
  458.                        android:text="Enter your Gcash name"
  459.                        android:layout_marginBottom="15dp"
  460.                        android:fontFamily="@font/roboto_bold"
  461.                        android:textSize="16sp"/>
  462.  
  463.                     <com.google.android.material.textfield.TextInputLayout
  464.                        android:layout_width="match_parent"
  465.                        android:layout_height="wrap_content"
  466.                        android:hint="Gcash Name">
  467.  
  468.                         <com.google.android.material.textfield.TextInputEditText
  469.                            android:id="@+id/yourGcashNameET"
  470.                            android:layout_width="match_parent"
  471.                            android:layout_height="wrap_content"
  472.                            android:padding="15dp"/>
  473.                     </com.google.android.material.textfield.TextInputLayout>
  474.                 </LinearLayout>
  475.             </androidx.cardview.widget.CardView>
  476.  
  477.             <androidx.cardview.widget.CardView
  478.                android:layout_width="match_parent"
  479.                android:layout_height="wrap_content"
  480.                app:cardElevation="6dp"
  481.                android:layout_margin="5dp"
  482.                app:cardCornerRadius="20dp">
  483.  
  484.                 <LinearLayout
  485.                    android:layout_width="match_parent"
  486.                    android:layout_height="wrap_content"
  487.                    android:orientation="vertical"
  488.                    android:padding="16dp">
  489.  
  490.                     <TextView
  491.                        android:layout_width="wrap_content"
  492.                        android:layout_height="wrap_content"
  493.                        android:text="Enter your reference number"
  494.                        android:layout_marginBottom="15dp"
  495.                        android:fontFamily="@font/roboto_bold"
  496.                        android:textSize="16sp"/>
  497.  
  498.                     <com.google.android.material.textfield.TextInputLayout
  499.                        android:layout_width="match_parent"
  500.                        android:layout_height="wrap_content"
  501.                        android:hint="Reference Number">
  502.  
  503.                         <com.google.android.material.textfield.TextInputEditText
  504.                            android:id="@+id/referenceNumberET"
  505.                            android:layout_width="match_parent"
  506.                            android:layout_height="wrap_content"
  507.                            android:padding="15dp"/>
  508.                     </com.google.android.material.textfield.TextInputLayout>
  509.                 </LinearLayout>
  510.             </androidx.cardview.widget.CardView>
  511.  
  512.             <!-- Screenshot of the Gcash Receipt -->
  513.             <TextView
  514.                android:layout_width="wrap_content"
  515.                android:layout_height="wrap_content"
  516.                android:text="Screenshot of your Gcash receipt"
  517.                android:textSize="16sp" />
  518.  
  519.             <ImageView
  520.                android:id="@+id/attachedImageView"
  521.                android:layout_width="match_parent"
  522.                android:layout_height="wrap_content"
  523.                android:layout_gravity="center"
  524.                android:layout_marginTop="5dp"
  525.                android:layout_marginBottom="5dp"
  526.                android:scaleType="fitCenter"
  527.                android:visibility="gone" />
  528.  
  529.             <androidx.appcompat.widget.AppCompatButton
  530.                android:id="@+id/attachPhotoButton"
  531.                android:layout_width="140dp"
  532.                android:layout_height="48dp"
  533.                android:layout_gravity="start"
  534.                android:layout_marginTop="8dp"
  535.                android:background="@drawable/gradient2"
  536.                android:text="Attach Photo"
  537.                android:textColor="@color/textcolor"
  538.                android:textSize="14sp" />
  539.  
  540.             <ProgressBar
  541.                android:id="@+id/loadingProgressBar"
  542.                android:layout_width="wrap_content"
  543.                android:layout_height="wrap_content"
  544.                android:layout_gravity="center"
  545.                android:visibility="gone" />
  546.  
  547.  
  548.             <androidx.appcompat.widget.AppCompatButton
  549.                android:id="@+id/submitButton"
  550.                android:layout_width="190dp"
  551.                android:layout_height="50dp"
  552.                android:layout_gravity="center"
  553.                android:layout_marginTop="8dp"
  554.                android:background="@drawable/gradient2"
  555.                android:text="Submit"
  556.                android:textColor="@color/textcolor"
  557.                android:textSize="18sp" />
  558.  
  559.         </LinearLayout>
  560.  
  561.  
  562.     </androidx.core.widget.NestedScrollView>
  563. </androidx.coordinatorlayout.widget.CoordinatorLayout>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement