Commit 073b1428 authored by Trio Saputra's avatar Trio Saputra

new updated

parent a42f40f5
......@@ -9,139 +9,162 @@
type="String" />
</data>
<RelativeLayout
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:background="@color/colorBackground"
tools:context=".activities.ProductActivity">
<com.google.android.material.card.MaterialCardView
android:id="@+id/cvProduct"
android:layout_width="160dp"
android:layout_height="160dp"
android:layout_centerHorizontal="true"
android:layout_margin="16dp"
app:cardCornerRadius="80dp">
<ImageView
android:id="@+id/ivProduct"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:src="@drawable/unnamed"/>
</com.google.android.material.card.MaterialCardView>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilProduct"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.google.android.material.textview.MaterialTextView
android:id="@+id/tvHeadProduct"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@id/cvProduct"
android:layout_marginStart="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etProduct"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Nama produk"
android:inputType="textCapWords"
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilPrice"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/tilProduct"
android:layout_marginStart="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default"
android:layout_toStartOf="@id/tilQuantity">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etPrice"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Harga"
android:inputType="number"
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
android:textSize="24dp"
android:layout_margin="@dimen/space_default"
android:text="Tambah Product"/>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilQuantity"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="96dp"
android:layout_height="wrap_content"
android:layout_below="@id/tilProduct"
android:layout_alignParentEnd="true"
android:layout_marginStart="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etQuantity"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Jumlah"
android:inputType="number"
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilCategory"
style="@style/Widget.MaterialComponents.TextInputLayout.FilledBox.ExposedDropdownMenu"
<ScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tilPrice"
android:layout_marginStart="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default">
<AutoCompleteTextView
android:id="@+id/spCategory"
android:layout_height="wrap_content">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilDescription"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/tilCategory"
android:layout_marginStart="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default">
android:layout_height="match_parent"
tools:context=".activities.ProductActivity">
<com.google.android.material.card.MaterialCardView
android:id="@+id/cvProduct"
android:layout_width="160dp"
android:layout_height="160dp"
android:layout_centerHorizontal="true"
android:layout_margin="16dp"
app:cardCornerRadius="80dp">
<ImageView
android:id="@+id/ivProduct"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:scaleType="centerCrop"
android:src="@drawable/unnamed"/>
</com.google.android.material.card.MaterialCardView>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilProduct"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/cvProduct"
android:layout_marginStart="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etProduct"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Nama produk"
android:inputType="textCapWords"
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilPrice"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/tilProduct"
android:layout_marginStart="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default"
android:layout_toStartOf="@id/tilQuantity">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etPrice"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Harga"
android:inputType="number"
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilQuantity"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="96dp"
android:layout_height="wrap_content"
android:layout_below="@id/tilProduct"
android:layout_alignParentEnd="true"
android:layout_marginStart="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etQuantity"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="Jumlah"
android:inputType="number"
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilCategory"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense.ExposedDropdownMenu"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tilPrice"
android:layout_marginStart="@dimen/space_default"
android:layout_marginBottom="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default">
<AutoCompleteTextView
android:id="@+id/spCategory"
android:layout_width="match_parent"
android:layout_height="wrap_content"/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/tilDescription"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.Dense"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/tilCategory"
android:layout_marginStart="@dimen/space_default"
android:layout_marginEnd="@dimen/space_default">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="start|top"
android:hint="Deskripsi produk"
android:inputType="textMultiLine"
android:lines="3"
android:maxLines="3"
android:text=""
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.button.MaterialButton
android:id="@+id/btnSubmit"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/tilDescription"
android:layout_margin="@dimen/space_default"
android:backgroundTint="@color/colorPrimary"
android:padding="16dp"
android:text="Tambah Produk"
android:textColor="@color/white"
app:cornerRadius="@dimen/space_default"
android:elevation="5dp" />
</RelativeLayout>
</ScrollView>
</LinearLayout>
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/etDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:gravity="start|top"
android:hint="Deskripsi produk"
android:inputType="textMultiLine"
android:lines="3"
android:maxLines="3"
android:text=""
android:textSize="@dimen/text_default" />
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.button.MaterialButton
android:id="@+id/btnSubmit"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/tilDescription"
android:layout_margin="@dimen/space_default"
android:backgroundTint="@color/colorPrimary"
android:padding="16dp"
android:text="Tambah Produk"
android:textColor="@color/white"
app:cornerRadius="@dimen/space_default"
android:elevation="5dp" />
</RelativeLayout>
</layout>
\ No newline at end of file
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