diff --git a/home/app/src/main/AndroidManifest.xml b/home/app/src/main/AndroidManifest.xml
index 56cea35..a3d2e00 100644
--- a/home/app/src/main/AndroidManifest.xml
+++ b/home/app/src/main/AndroidManifest.xml
@@ -64,6 +64,13 @@
android:name="android.app.lib_name"
android:value="" />
+
+
+
@@ -93,98 +100,98 @@
/>
parent, View view, int position, long id) {
diff --git a/home/app/src/main/java/com/k20411group03/home/ProductDetails.java b/home/app/src/main/java/com/k20411group03/home/ProductDetails.java
index d2f1b2d..5750adf 100644
--- a/home/app/src/main/java/com/k20411group03/home/ProductDetails.java
+++ b/home/app/src/main/java/com/k20411group03/home/ProductDetails.java
@@ -86,15 +86,6 @@ private void loadData(){
}
private void addEvents(){
-
- //back button
- binding.imvBack.setOnClickListener(new View.OnClickListener() {
- @Override
- public void onClick(View v) {
- finish();
- }
- });
-
binding.imvAdd.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View view) {
diff --git a/home/app/src/main/java/com/k20411group03/home/Sort.java b/home/app/src/main/java/com/k20411group03/home/Sort.java
deleted file mode 100644
index ab4c79e..0000000
--- a/home/app/src/main/java/com/k20411group03/home/Sort.java
+++ /dev/null
@@ -1,26 +0,0 @@
-package com.k20411group03.home;
-
-import androidx.appcompat.app.AppCompatActivity;
-
-import android.os.Bundle;
-import android.view.View;
-import android.widget.AdapterView;
-import android.widget.ArrayAdapter;
-import android.widget.AutoCompleteTextView;
-import android.widget.Toast;
-
-public class Sort extends AppCompatActivity {
-
-
-
-
- @Override
- protected void onCreate(Bundle savedInstanceState) {
- super.onCreate(savedInstanceState);
- setContentView(R.layout.activity_sort);
-
-
-}}
-
-
-
diff --git a/home/app/src/main/java/com/k20411group03/home/ThanhToanPre.java b/home/app/src/main/java/com/k20411group03/home/ThanhToanPre.java
index 87d2891..c3638e3 100644
--- a/home/app/src/main/java/com/k20411group03/home/ThanhToanPre.java
+++ b/home/app/src/main/java/com/k20411group03/home/ThanhToanPre.java
@@ -35,13 +35,13 @@ protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
//setContentView(R.layout.activity_thanh_toan_pre);
-// //Custom action bar
-// ActionBar actionBar = getSupportActionBar();
-// actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_CUSTOM);
-// actionBar.setDisplayShowCustomEnabled(true);
-// actionBar.setCustomView(R.layout.custom_action_bar);
-// actionBar.setDisplayUseLogoEnabled(true);
-// actionBar.setDisplayShowHomeEnabled(true);
+ //Custom action bar
+ ActionBar actionBar = getSupportActionBar();
+ actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_CUSTOM);
+ actionBar.setDisplayShowCustomEnabled(true);
+ actionBar.setCustomView(R.layout.custom_action_bar);
+ actionBar.setDisplayUseLogoEnabled(true);
+ actionBar.setDisplayShowHomeEnabled(true);
binding = ActivityThanhToanPreBinding.inflate(getLayoutInflater());
setContentView(binding.getRoot());
@@ -120,37 +120,49 @@ public void onClick(View view) {
});
}
+ //Thêm action
+ @Override
+ public boolean onCreateOptionsMenu(Menu menu) {
+ getMenuInflater().inflate(R.menu.main, menu);
+ return super.onCreateOptionsMenu(menu);
+ }
-// //Thêm action
-// @Override
-// public boolean onCreateOptionsMenu(Menu menu) {
-
-// getMenuInflater().inflate(R.menu.main, menu);
-// return super.onCreateOptionsMenu(menu);
-// }
-
-// //Sự kiện action bar
-// @Override
-// public boolean onOptionsItemSelected(@NonNull MenuItem item) {
-// switch (item.getItemId()) {
-// case R.id.action_search:
-// Intent intentSearch = new Intent(ThanhToanPre.this, ActivitySearch.class);
-// startActivity(intentSearch);
-// break;
-// case R.id.action_cart:
-// Intent intentCart = new Intent(ThanhToanPre.this, MainActivity.class);
-// startActivity(intentCart);
-// break;
-// case R.id.action_menu:
-// Intent intentMenu = new Intent(ThanhToanPre.this, MainMenu.class);
-// startActivity(intentMenu);
-// break;
-// }
-
-// return super.onOptionsItemSelected(item);
-// }
-
+ //Sự kiện action bar
+ @Override
+ public boolean onOptionsItemSelected(@NonNull MenuItem item) {
+ switch (item.getItemId()) {
+ case R.id.action_search:
+ Intent intentSearch = new Intent(ThanhToanPre.this, ActivitySearch.class);
+ startActivity(intentSearch);
+ break;
+ case R.id.action_cart:
+ Intent intentCart = new Intent(ThanhToanPre.this, MainActivity.class);
+ startActivity(intentCart);
+ break;
+ case R.id.action_BoSuuTap:
+ Intent intentBoSuuTap = new Intent(ThanhToanPre.this, ProductCollection.class);
+ intentBoSuuTap.putExtra("screenTitle", "Bộ sưu tập mới");
+ startActivity(intentBoSuuTap);
+ break;
+ case R.id.action_HangMoiVe:
+ Intent intentSanPhamMoi = new Intent(ThanhToanPre.this, ProductCollection.class);
+ intentSanPhamMoi.putExtra("screenTitle", "Hàng mới về");
+ startActivity(intentSanPhamMoi);
+ break;
+ case R.id.action_Flashsale:
+ Intent intentFlashsale = new Intent(ThanhToanPre.this, FlashSaleScreen.class);
+ startActivity(intentFlashsale);
+ break;
+ case R.id.action_SanPham:
+ Intent intentSanPham = new Intent(ThanhToanPre.this, ProductCollection.class);
+ intentSanPham.putExtra("screenTitle", "Sản phẩm");
+ startActivity(intentSanPham);
+ break;
+ }
+
+ return super.onOptionsItemSelected(item);
+ }
private void loadData() {
products = new ArrayList<>();
diff --git a/home/app/src/main/java/com/k20411group03/home/ThongBao.java b/home/app/src/main/java/com/k20411group03/home/ThongBao.java
index 8a399fa..256c030 100644
--- a/home/app/src/main/java/com/k20411group03/home/ThongBao.java
+++ b/home/app/src/main/java/com/k20411group03/home/ThongBao.java
@@ -97,9 +97,9 @@ private void loadData() {
notifications = new ArrayList<>();
notifications.add(new Notification(R.drawable.bannersale, "Giảm giá Noel", "Giảm lên đến 50% các sản phẩm sweater"));
- notifications.add(new Notification(R.drawable.bannersale, "Title 2", "Content 2"));
- notifications.add(new Notification(R.drawable.bannersale, "Title 3", "Content 3"));
- notifications.add(new Notification(R.drawable.bannersale, "Title 4", "Content 4"));
+ notifications.add(new Notification(R.drawable.jean001, "Cốc cốc cốc, bạn bỏ quên gì nè!", "Một sản phẩm quần jean đã được thêm vào giỏ hàng của bạn nhưng chưa được mua, đến ngay giỏ hàng để rinh ngay thôi nào!"));
+ notifications.add(new Notification(R.drawable.nha_giao_vietnam, "Mừng ngày Nhà giáo Việt Nam 20 - 11", "Mừng nhà giáo Việt Nam, The Weekdays giảm giá 20% cho tất cả các sản phẩm quần jean cho quý thầy!"));
+ notifications.add(new Notification(R.drawable.tiktok_channel, "Ra mắt kênh truyền thông TikTok của The Weekdays", "Tháng 11 vừa qua, thương hiệu thời trang nam The Weekdays đã thành lập kênh TikTok @theweekdaysvn để truyền tải thông điệp thời trang nam đến với tất cả các bạn trẻ. Hãy theo dõi kênh TikTok của The Weekdays để cập nhật những thông tin mới nhất về thương hiệu và những sản phẩm mới nhất của The Weekdays nhé!"));
adapterNoti = new NotificationAdapter(ThongBao.this, R.layout.thongbao_item, notifications);
binding.lvThongBao.setAdapter(adapterNoti);
diff --git a/home/app/src/main/java/com/k20411group03/home/TrangChu.java b/home/app/src/main/java/com/k20411group03/home/TrangChu.java
index 628b825..6b50fa0 100644
--- a/home/app/src/main/java/com/k20411group03/home/TrangChu.java
+++ b/home/app/src/main/java/com/k20411group03/home/TrangChu.java
@@ -266,8 +266,6 @@ public void onClick(View v) {
});
-
-
//Sự kiện khi click vào navigation bar
navigationView = findViewById(R.id.mn_home);
navigationView.setSelectedItemId(R.id.item_home);
diff --git a/home/app/src/main/java/com/k20411group03/home/member1.java b/home/app/src/main/java/com/k20411group03/home/member1.java
index 11703e2..3031cc7 100644
--- a/home/app/src/main/java/com/k20411group03/home/member1.java
+++ b/home/app/src/main/java/com/k20411group03/home/member1.java
@@ -182,6 +182,26 @@ private void signOut(){
.addOnFailureListener(e -> showToast("Unable to sign out"));
}
private void addEvents(){
+ //Đơn hàng của tôi
+
+ //Đã yêu thích
+ binding.btnYeuthich.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View view) {
+ Intent intent = new Intent(member1.this, Wishlist.class);
+ startActivity(intent);
+ }
+ });
+
+ //Voucher của tôi
+ binding.btnVouchercuatoi.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View view) {
+ Intent intent = new Intent(member1.this, voucher_main.class);
+ startActivity(intent);
+ }
+ });
+
//Bottom navigation
//navigationView = findViewById(R.id.mn_membership);
navigationView = binding.mnMembership;
diff --git a/home/app/src/main/java/com/k20411group03/home/voucher_main.java b/home/app/src/main/java/com/k20411group03/home/voucher_main.java
index d3982ff..2794426 100644
--- a/home/app/src/main/java/com/k20411group03/home/voucher_main.java
+++ b/home/app/src/main/java/com/k20411group03/home/voucher_main.java
@@ -28,13 +28,13 @@ protected void onCreate(Bundle savedInstanceState) {
binding = ActivityVoucherMainBinding.inflate(getLayoutInflater());
//setContentView(R.layout.activity_kho_voucher);
-// //Custom action bar
-// ActionBar actionBar = getSupportActionBar();
-// actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_CUSTOM);
-// actionBar.setDisplayShowCustomEnabled(true);
-// actionBar.setCustomView(R.layout.custom_action_bar);
-// actionBar.setDisplayUseLogoEnabled(true);
-// actionBar.setDisplayShowHomeEnabled(true);
+ //Custom action bar
+ ActionBar actionBar = getSupportActionBar();
+ actionBar.setDisplayOptions(ActionBar.DISPLAY_SHOW_CUSTOM);
+ actionBar.setDisplayShowCustomEnabled(true);
+ actionBar.setCustomView(R.layout.custom_action_bar);
+ actionBar.setDisplayUseLogoEnabled(true);
+ actionBar.setDisplayShowHomeEnabled(true);
setContentView(binding.getRoot());
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
@@ -43,34 +43,49 @@ protected void onCreate(Bundle savedInstanceState) {
loadData();
}
-// //Thêm action
-// @Override
-// public boolean onCreateOptionsMenu(Menu menu) {
-
-// getMenuInflater().inflate(R.menu.main, menu);
-// return super.onCreateOptionsMenu(menu);
-// }
-
-// //Sự kiện action bar
-// @Override
-// public boolean onOptionsItemSelected(@NonNull MenuItem item) {
-// switch (item.getItemId()) {
-// case R.id.action_search:
-// Intent intentSearch = new Intent(voucher_main.this, ActivitySearch.class);
-// startActivity(intentSearch);
-// break;
-// case R.id.action_cart:
-// Intent intentCart = new Intent(voucher_main.this, MainActivity.class);
-// startActivity(intentCart);
-// break;
-// case R.id.action_menu:
-// Intent intentMenu = new Intent(voucher_main.this, MainMenu.class);
-// startActivity(intentMenu);
-// break;
-// }
-
-// return super.onOptionsItemSelected(item);
-// }
+ //Thêm action
+ @Override
+ public boolean onCreateOptionsMenu(Menu menu) {
+
+ getMenuInflater().inflate(R.menu.main, menu);
+ return super.onCreateOptionsMenu(menu);
+ }
+
+ //Sự kiện action bar
+ @Override
+ public boolean onOptionsItemSelected(@NonNull MenuItem item) {
+ switch (item.getItemId()) {
+ case R.id.action_search:
+ Intent intentSearch = new Intent(voucher_main.this, ActivitySearch.class);
+ startActivity(intentSearch);
+ break;
+ case R.id.action_cart:
+ Intent intentCart = new Intent(voucher_main.this, MainActivity.class);
+ startActivity(intentCart);
+ break;
+ case R.id.action_BoSuuTap:
+ Intent intentBoSuuTap = new Intent(voucher_main.this, ProductCollection.class);
+ intentBoSuuTap.putExtra("screenTitle", "Bộ sưu tập mới");
+ startActivity(intentBoSuuTap);
+ break;
+ case R.id.action_HangMoiVe:
+ Intent intentSanPhamMoi = new Intent(voucher_main.this, ProductCollection.class);
+ intentSanPhamMoi.putExtra("screenTitle", "Hàng mới về");
+ startActivity(intentSanPhamMoi);
+ break;
+ case R.id.action_Flashsale:
+ Intent intentFlashsale = new Intent(voucher_main.this, FlashSaleScreen.class);
+ startActivity(intentFlashsale);
+ break;
+ case R.id.action_SanPham:
+ Intent intentSanPham = new Intent(voucher_main.this, ProductCollection.class);
+ intentSanPham.putExtra("screenTitle", "Sản phẩm");
+ startActivity(intentSanPham);
+ break;
+ }
+
+ return super.onOptionsItemSelected(item);
+ }
private void loadData() {
vouchers = new ArrayList<>();
diff --git a/home/app/src/main/res/drawable/ic_baseline_person.xml b/home/app/src/main/res/drawable/ic_baseline_person.xml
new file mode 100644
index 0000000..f02d532
--- /dev/null
+++ b/home/app/src/main/res/drawable/ic_baseline_person.xml
@@ -0,0 +1,5 @@
+
+
+
diff --git a/home/app/src/main/res/drawable/nha_giao_vietnam.png b/home/app/src/main/res/drawable/nha_giao_vietnam.png
new file mode 100644
index 0000000..c2f203e
Binary files /dev/null and b/home/app/src/main/res/drawable/nha_giao_vietnam.png differ
diff --git a/home/app/src/main/res/drawable/tiktok_channel.png b/home/app/src/main/res/drawable/tiktok_channel.png
new file mode 100644
index 0000000..4f3ff5d
Binary files /dev/null and b/home/app/src/main/res/drawable/tiktok_channel.png differ
diff --git a/home/app/src/main/res/layout/activity_sort.xml b/home/app/src/main/res/layout/activity_filter.xml
similarity index 95%
rename from home/app/src/main/res/layout/activity_sort.xml
rename to home/app/src/main/res/layout/activity_filter.xml
index 6d972d1..9bb7ec8 100644
--- a/home/app/src/main/res/layout/activity_sort.xml
+++ b/home/app/src/main/res/layout/activity_filter.xml
@@ -4,7 +4,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
- tools:context=".Sort"
+ tools:context=".Filter"
android:orientation="vertical">
@@ -64,7 +64,7 @@
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="Màu sắc:"
- android:textSize="30sp"
+ android:textSize="24sp"
android:layout_weight="4"
android:layout_gravity="center"
android:layout_marginLeft="10dp"/>
@@ -92,7 +92,7 @@
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="Kích cỡ:"
- android:textSize="30sp"
+ android:textSize="24sp"
android:layout_weight="4"
android:layout_gravity="center"
android:layout_marginLeft="10dp"/>
@@ -120,7 +120,7 @@
android:layout_width="0dp"
android:layout_height="wrap_content"
android:text="Giá:"
- android:textSize="30sp"
+ android:textSize="24sp"
android:layout_weight="4"
android:layout_gravity="center"
android:layout_marginLeft="10dp"/>
@@ -141,11 +141,12 @@
+ android:backgroundTint="@color/black"/>
\ No newline at end of file
diff --git a/home/app/src/main/res/layout/activity_product_details.xml b/home/app/src/main/res/layout/activity_product_details.xml
index 675eb7f..42803bd 100644
--- a/home/app/src/main/res/layout/activity_product_details.xml
+++ b/home/app/src/main/res/layout/activity_product_details.xml
@@ -13,28 +13,6 @@
android:layout_height="wrap_content"
android:orientation="vertical">
-
-
-
-
-
-
+ android:layout_marginTop="50dp"
+ android:layout_marginBottom="75dp"/>