Skip to content
This repository has been archived by the owner on Dec 31, 2023. It is now read-only.

Miu Shop - v1.0.0 #88

Merged
merged 458 commits into from
Dec 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
458 commits
Select commit Hold shift + click to select a range
5bb5dea
Fix UTF-8 when send email in ``sendWelcomeEmail`` method
hardingadonis Nov 24, 2023
aa4d68b
Send wellcome email when register successfully
hardingadonis Nov 24, 2023
1183166
Merge branch 'hoang_register_form' into vuong_register_form
hardingadonis Nov 24, 2023
d5984ee
Merge pull request #38 from hardingadonis/vuong_register_form
hardingadonis Nov 24, 2023
1a747a1
Merge pull request #32 from hardingadonis/hoang_register_form
GoldStarPro Nov 25, 2023
232c148
Change SearchServlet, ``name`` attribute to ``search-name``
hardingadonis Nov 25, 2023
8d833c5
Keep searched content in the search bar
hardingadonis Nov 25, 2023
d458e7f
Notification when not found any products
hardingadonis Nov 25, 2023
714a9b7
Add 404 error jsp page
hardingadonis Nov 25, 2023
8050a41
Update 404 error page
hardingadonis Nov 25, 2023
db35d03
Add 500 error jsp page
hardingadonis Nov 25, 2023
625901d
Merge pull request #39 from hardingadonis/vuong_fix_search
GoldStarPro Nov 25, 2023
1afbef0
Merge pull request #40 from hardingadonis/vuong_error_handling
GoldStarPro Nov 25, 2023
bfd5819
Remove unnecessary LABEL in ``Dockerfile`
hardingadonis Nov 25, 2023
f2fe56d
Add default charset and collation in ``Dockerfile``
hardingadonis Nov 25, 2023
f6fd7bc
Update ``Release Miu Shop`` action
hardingadonis Nov 25, 2023
e485c8a
Update ``Publish Miu Shop Images`` action
hardingadonis Nov 25, 2023
4cabf98
Merge pull request #41 from hardingadonis/hotfix_docker
GoldStarPro Nov 26, 2023
dc723ab
Merge pull request #42 from hardingadonis/update_actions
GoldStarPro Nov 26, 2023
dd62944
[CodeFactor] Apply fixes
code-factor Nov 26, 2023
09456a0
Update README.md
hardingadonis Nov 26, 2023
7545250
Change port from ``8080`` to ``80``
hardingadonis Nov 26, 2023
da0a60d
Update servlet name
hardingadonis Nov 26, 2023
ce43028
Merge pull request #43 from hardingadonis/dev-cf-autofix
GoldStarPro Nov 26, 2023
d33b30b
Merge pull request #44 from hardingadonis/fix_docker_compose
GoldStarPro Nov 26, 2023
f2f4e70
Merge pull request #45 from hardingadonis/update_servlet
GoldStarPro Nov 26, 2023
5e5e048
Add config for Imgbot
hardingadonis Nov 27, 2023
0bda26c
Merge pull request #47 from hardingadonis/config_imgbot
hardingadonis Nov 27, 2023
3318d5b
fix size 4 picture
yuhtnguyen Nov 27, 2023
8ac380e
Merge pull request #48 from hardingadonis/fix_picture
yuhtnguyen Nov 27, 2023
050f2d2
add 13 products
yuhtnguyen Nov 27, 2023
19032cb
Show cart in menu without login
hardingadonis Nov 27, 2023
c13a6d1
Add ``commomHandler`` js file
hardingadonis Nov 27, 2023
14834e5
Link ``commonHandler.js`` script
hardingadonis Nov 27, 2023
ac3f3b8
Call ``setTotalProductQuantityToCart`` method in all script js
hardingadonis Nov 27, 2023
1632290
Add toastify-js
hardingadonis Nov 27, 2023
461d63f
Use toastify-js
hardingadonis Nov 27, 2023
9627656
add 50 products
yuhtnguyen Nov 27, 2023
f9454c9
Merge pull request #50 from hardingadonis/vuong_add_to_cart
yuhtnguyen Nov 28, 2023
040d1ba
Merge pull request #49 from hardingadonis/thuy_add_product
yuhtnguyen Nov 28, 2023
2a1f5cc
Update .imgbotconfig
hardingadonis Nov 28, 2023
4ea70e2
Add prev and next button in pagination
hardingadonis Nov 28, 2023
e2d7925
Add tooltips when hover product cards
hardingadonis Nov 28, 2023
b4c6806
Add method for creating pagination
hardingadonis Nov 29, 2023
6972cbb
Add style for new pagination
hardingadonis Nov 29, 2023
aff0277
Update search jsp file
hardingadonis Nov 29, 2023
5f47917
Add css for overflow name of product card
hardingadonis Nov 29, 2023
383d710
Remove ``updateProductHeight`` function
hardingadonis Nov 29, 2023
c5bcc93
Move ``common.css`` to ``common`` folder
hardingadonis Nov 29, 2023
f21a39e
Merge pull request #52 from hardingadonis/hot_update
hardingadonis Nov 29, 2023
d2506ca
Fix small bug
hardingadonis Nov 29, 2023
33299fd
Update header jsp file
hardingadonis Nov 29, 2023
6f32690
Add CarServlet and cart jsp file
hardingadonis Nov 29, 2023
95544e0
Fix count total product in cart
hardingadonis Nov 29, 2023
0ad5d9c
Use encode and decode for json string in cookie
hardingadonis Nov 29, 2023
ad6d96a
Add ``encodeURIComponent`` method in Hash service
hardingadonis Nov 29, 2023
2e44d76
Add ``decodeURIComponent`` method in Hash serivce
hardingadonis Nov 29, 2023
b69810e
Merge pull request #53 from hardingadonis/vuong_fix_product_cart
GoldStarPro Nov 29, 2023
f1539b3
Update Hash.java
hardingadonis Nov 29, 2023
38c1a36
Merge pull request #54 from hardingadonis/hot_fix_add_to_cart
hardingadonis Nov 29, 2023
159ce68
Merge branch 'dev' into vuong_fix_pagination
GoldStarPro Nov 29, 2023
8be2400
Merge pull request #51 from hardingadonis/vuong_fix_pagination
GoldStarPro Nov 29, 2023
abcfde9
Update searchHandler.js
hardingadonis Nov 29, 2023
ef25d79
Optimize js code
hardingadonis Nov 29, 2023
48dbf55
Add ``getCartCookie`` method in CartServlet
hardingadonis Nov 29, 2023
2bb89fc
Update search.css
hardingadonis Nov 29, 2023
f5f9296
Update CartServlet
hardingadonis Nov 29, 2023
99d45fc
Add table for showing cart data in cart jsp file
hardingadonis Nov 29, 2023
36a3a02
Add cart page stylesheet
hardingadonis Nov 29, 2023
e67e2fd
Add cart page js handler
hardingadonis Nov 29, 2023
1dbc9b2
Fix css for cart page
hardingadonis Dec 3, 2023
d2653e4
Add inscrease and decrease quantity, update total price and delete pr…
hardingadonis Dec 3, 2023
e17571c
Add js code for updating total price of cart
hardingadonis Dec 3, 2023
656632c
Fix update total price and when quantity less than 1, then remove
hardingadonis Dec 3, 2023
960381d
Handle when increase max of amount product
hardingadonis Dec 3, 2023
83eb2f8
Merge pull request #55 from hardingadonis/vuong_cart_page
hardingadonis Dec 3, 2023
8442f2b
Update total product to cart in menu
hardingadonis Dec 3, 2023
790865c
Merge pull request #56 from hardingadonis/hotfix_cart_page
hardingadonis Dec 3, 2023
990d653
Fix spelling mistake
hardingadonis Dec 4, 2023
98b5427
Update header and footer pages
hardingadonis Dec 4, 2023
e2f01ad
Fix search page
hardingadonis Dec 4, 2023
0012aa7
Fix register page
hardingadonis Dec 4, 2023
a5e2acb
Finish profile page (css + js + jsp)
hardingadonis Dec 4, 2023
f7e8d8b
Add ``commons-fileupload`` dependency in ``pom.xml``
hardingadonis Dec 4, 2023
98719c3
Create ProfileServlet and finish it
hardingadonis Dec 4, 2023
2b18f6a
Remove 4.5 start in product page
hardingadonis Dec 4, 2023
4b33e65
Add ChangePasswordServlet
hardingadonis Dec 4, 2023
17ac2ff
Add change password jsp page
hardingadonis Dec 4, 2023
19ffa27
Add css & js code for change password page
hardingadonis Dec 4, 2023
d4e1d0c
Add notification when change password success
hardingadonis Dec 4, 2023
d5f6be0
Update profile page
hardingadonis Dec 4, 2023
fca7fb6
Update profile.jsp
hardingadonis Dec 4, 2023
8170d3a
Update change-password.jsp
hardingadonis Dec 4, 2023
1d46e7d
Fix spelling mistake
hardingadonis Dec 4, 2023
3b18112
Update change-password.jsp
hardingadonis Dec 4, 2023
ccd066e
Add delivery address page, servlet, css, js
hardingadonis Dec 4, 2023
cfb632b
Update README.md
hardingadonis Dec 4, 2023
be49e93
Update method ``toString`` of UserAddress detail
hardingadonis Dec 4, 2023
b6d320f
Merge pull request #57 from hardingadonis/vuong_profile_page
GoldStarPro Dec 4, 2023
be7a2f6
Merge pull request #59 from hardingadonis/vuong_change_password_page
GoldStarPro Dec 4, 2023
f22b43e
Add show and hide password
hardingadonis Dec 4, 2023
c33a6b9
Update database: use string for save user address
hardingadonis Dec 4, 2023
aa8bd32
Delete UserAddress class detail
hardingadonis Dec 4, 2023
b934137
Update User model and its DAO
hardingadonis Dec 4, 2023
b7a7bb4
Delete src/main/java/io/hardingadonis/miu/model/detail/UserAddress.java
hardingadonis Dec 4, 2023
08f3b6f
Merge pull request #63 from hardingadonis/change_user_address
hardingadonis Dec 4, 2023
05dd6c0
Merge pull request #62 from hardingadonis/change_user_address
hardingadonis Dec 4, 2023
a4f254e
Update cart page
hardingadonis Dec 4, 2023
6ea6bac
Update form for delivery address page
hardingadonis Dec 4, 2023
7395e32
Merge pull request #58 from hardingadonis/hotfix_product_page
yuhtnguyen Dec 4, 2023
61f865d
Merge pull request #61 from hardingadonis/hotfix_change_password_page
yuhtnguyen Dec 4, 2023
6989d2d
Merge pull request #60 from hardingadonis/hotfix_spelling_mistake
yuhtnguyen Dec 4, 2023
1c0f878
Finish delivery address page
hardingadonis Dec 5, 2023
31376b8
Update delivery address jsp page
hardingadonis Dec 5, 2023
42e55b7
Add add address jsp page, js, css
hardingadonis Dec 5, 2023
a7de6fa
Update Delivery Address Servlet
hardingadonis Dec 5, 2023
a2ad7c4
Create Add Address Servlet
hardingadonis Dec 5, 2023
8d97387
Add ``address`` column for order table
hardingadonis Dec 5, 2023
800ce4a
Update Order model
hardingadonis Dec 5, 2023
343211d
Update Order DAO
hardingadonis Dec 5, 2023
c86b048
Merge pull request #65 from hardingadonis/update_order_table
hardingadonis Dec 5, 2023
c149680
Merge pull request #66 from hardingadonis/update_order_table
hardingadonis Dec 5, 2023
1a7db36
Merge pull request #64 from hardingadonis/vuong_delivery_address_page
GoldStarPro Dec 5, 2023
a88d858
Update ``setup.sql`` database
hardingadonis Dec 5, 2023
633d8b1
Update Category DAO
hardingadonis Dec 5, 2023
32a2406
Add checkout jsp page
hardingadonis Dec 5, 2023
0ece347
Disable `Add to cart` button when amount equals 0
hardingadonis Dec 5, 2023
8a6a9f8
Update OrderDAO and ProductDAO
hardingadonis Dec 5, 2023
3c7eec8
Add handler for checkout with cod payment
hardingadonis Dec 5, 2023
1760262
bonus icon eye open-close at register and login
yuhtnguyen Dec 5, 2023
fef207e
Merge pull request #67 from hardingadonis/thuy_show_and_hide_password
yuhtnguyen Dec 5, 2023
a4d2f1e
Update
hardingadonis Dec 5, 2023
9019525
Merge pull request #68 from hardingadonis/vuong_checkout_page
yuhtnguyen Dec 5, 2023
b706b41
Fix
hardingadonis Dec 5, 2023
32c09bb
Merge pull request #69 from hardingadonis/vuong_checkout_page
hardingadonis Dec 5, 2023
41a4b99
The first stage
GoldStarPro Dec 5, 2023
dc84b0e
Delete Cart model and its DAO
hardingadonis Dec 5, 2023
247b4ab
Add ``VNPayConfig`` config class
hardingadonis Dec 5, 2023
5b8fd2f
Update ``VNPayConfig`` class
hardingadonis Dec 5, 2023
fcb87cb
Update checkout jsp page
hardingadonis Dec 5, 2023
f363b3b
Update checkout jsp page again
hardingadonis Dec 5, 2023
943044a
Update cart jsp page
hardingadonis Dec 5, 2023
661cc68
Update VNPay Config class
hardingadonis Dec 5, 2023
cb1ce5f
Add Checkout Success Servlet class
hardingadonis Dec 5, 2023
fe5bd9b
Add checkout success jsp page
hardingadonis Dec 5, 2023
a709e65
Update Checkout Servlet
hardingadonis Dec 5, 2023
1e12a7b
Merge pull request #70 from hardingadonis/vuong_checkout_page
yuhtnguyen Dec 5, 2023
50a5517
Add admin package and some relate Servlet, jsp, css file
GoldStarPro Dec 6, 2023
7522e99
Handle the cart when checkout with vnpay fail
hardingadonis Dec 6, 2023
a815709
Handle the checkout page when user has no deilivery address
hardingadonis Dec 6, 2023
b3833a0
Merge pull request #71 from hardingadonis/hotfix_vnpay
GoldStarPro Dec 6, 2023
6b9689f
Merge pull request #72 from hardingadonis/hotfix_no_address
GoldStarPro Dec 6, 2023
a613c0f
Add more method in ``OrderDAO`` and is implemet
hardingadonis Dec 6, 2023
6933c24
thuy_loginAdmin
yuhtnguyen Dec 6, 2023
3e344c6
Merge pull request #73 from hardingadonis/thuy_loginAdmin
yuhtnguyen Dec 6, 2023
52197c2
Update link for purchase history
hardingadonis Dec 6, 2023
e22c4c1
Add purchase history jsp page
hardingadonis Dec 6, 2023
d2b82ab
Add purchase history css
hardingadonis Dec 6, 2023
8f97065
Add purchase history js code
hardingadonis Dec 6, 2023
cb44494
Add purchase history servlet
hardingadonis Dec 6, 2023
2108e2c
Add ``doDelete`` method in PurchaseServlet class
hardingadonis Dec 6, 2023
e3e4193
Update purchase history jsp page
hardingadonis Dec 6, 2023
bdb78b0
Add action for cancel an order
hardingadonis Dec 6, 2023
cf8e52c
Update Purchase servlet page
hardingadonis Dec 6, 2023
ca5c34b
Add purchase history detail jsp page
hardingadonis Dec 6, 2023
b5d5252
Add purchase history detail servlet
hardingadonis Dec 6, 2023
6b795c9
Change ``checkout-success`` to ``checkout-status``
hardingadonis Dec 6, 2023
3336e4c
Update
hardingadonis Dec 6, 2023
8053b73
Delete src/main/webapp/view/web/checkout-success.jsp
hardingadonis Dec 6, 2023
b7f2bf2
Merge pull request #74 from hardingadonis/vuong_purchase_history_page
GoldStarPro Dec 7, 2023
83e7b95
Interface list_order
GoldStarPro Dec 7, 2023
ed77118
ListOrder Interface
GoldStarPro Dec 7, 2023
23cf9ce
Processing logic
GoldStarPro Dec 7, 2023
58cafbf
Change admin position
GoldStarPro Dec 7, 2023
3eed168
Update checkout status page for checkout
hardingadonis Dec 7, 2023
47ae94d
Admin Page UI
GoldStarPro Dec 7, 2023
b639f42
Fix bug configuration path
GoldStarPro Dec 7, 2023
d899afe
Edit Order Status
GoldStarPro Dec 7, 2023
510e7b8
Add ``getServerLink`` method in ``Server`` class
hardingadonis Dec 7, 2023
f1720b6
Update footer
hardingadonis Dec 7, 2023
f140daa
Increase products per page in search page
hardingadonis Dec 7, 2023
a87b0a4
Fix link for header_admin
GoldStarPro Dec 7, 2023
1926bb9
Add back button for purchase history detail page
hardingadonis Dec 7, 2023
238f8d1
Merge pull request #75 from hardingadonis/hotfix_all
GoldStarPro Dec 7, 2023
cd93005
show category list
yuhtnguyen Dec 7, 2023
30a9b55
Handle for deactivate user if they logged in
hardingadonis Dec 7, 2023
247ec2f
Remove send welcome email after register
hardingadonis Dec 7, 2023
0cf45f0
Add ``sendVerifyEmail`` method in Email service and its implementer
hardingadonis Dec 7, 2023
0a64834
Add Verify Servlet and its jsp page
hardingadonis Dec 7, 2023
5397528
Fix login jsp page
hardingadonis Dec 7, 2023
6ab697e
Complete User Management UI jsp
GoldStarPro Dec 7, 2023
81559b2
view detail of product
yuhtnguyen Dec 7, 2023
93f7b51
Function Delete User under Admin Role
GoldStarPro Dec 7, 2023
8cd6d85
Merge pull request #76 from hardingadonis/vuong_verify_user
GoldStarPro Dec 7, 2023
c652cd2
Add path for logout
GoldStarPro Dec 7, 2023
ae334fb
Add ``sendForgotPasswordEmail`` method in Email service and its implment
hardingadonis Dec 7, 2023
cbd36d0
add new product
yuhtnguyen Dec 7, 2023
2c0a47c
Bug in ListOrder
GoldStarPro Dec 7, 2023
f9fb553
Add forgot password in login page
hardingadonis Dec 7, 2023
77c0b7d
Update
hardingadonis Dec 7, 2023
aaf0a6c
Add forgot password functionally
hardingadonis Dec 7, 2023
23ead1e
Update fix bug
hardingadonis Dec 7, 2023
0f3bd82
Both admin
GoldStarPro Dec 7, 2023
42a11d2
Merge pull request #77 from hardingadonis/vuong_forgot_password
GoldStarPro Dec 7, 2023
3466747
Merge pull request #78 from hardingadonis/hoang_admin_dashboard
yuhtnguyen Dec 7, 2023
20c3c95
Merge branch 'hotfix_admin' into thuy_create_admin
hardingadonis Dec 7, 2023
4e60610
Merge pull request #79 from hardingadonis/thuy_create_admin
yuhtnguyen Dec 7, 2023
6a7c090
Big fix
hardingadonis Dec 7, 2023
f7c6f83
Big fix again
hardingadonis Dec 7, 2023
a3e2e63
Fix again
hardingadonis Dec 7, 2023
cb4c71f
Haizz
hardingadonis Dec 7, 2023
0911c58
Add preview images
hardingadonis Dec 7, 2023
29d2cda
Add database image
hardingadonis Dec 7, 2023
f812ae4
Add embedded link database
hardingadonis Dec 7, 2023
03a6fc5
Update README.md preview for user page
hardingadonis Dec 7, 2023
abcfe99
Add deployment in README.md
hardingadonis Dec 7, 2023
9edd546
[ImgBot] Optimize images
ImgBotApp Dec 7, 2023
ec01544
Merge pull request #81 from hardingadonis/imgbot
hardingadonis Dec 8, 2023
46ded98
Edit Order HTML
GoldStarPro Dec 8, 2023
82adb11
Fix bug
hardingadonis Dec 8, 2023
a04ad2c
add new category
yuhtnguyen Dec 8, 2023
991d2f4
Merge pull request #82 from hardingadonis/fix_bug
yuhtnguyen Dec 8, 2023
4adb39d
Hide status correctly
GoldStarPro Dec 8, 2023
8ec83b9
Responsive for header
hardingadonis Dec 8, 2023
c68307d
Update for header
hardingadonis Dec 8, 2023
51725dd
edit order modal
GoldStarPro Dec 8, 2023
4d20829
Update footer
hardingadonis Dec 8, 2023
8edca01
Update home page responsive
hardingadonis Dec 8, 2023
21a17d9
Update search page responsive
hardingadonis Dec 8, 2023
dc47c45
Update product page responsive
hardingadonis Dec 8, 2023
bca5940
Update add-address.jsp
hardingadonis Dec 8, 2023
e741121
Merge pull request #83 from hardingadonis/responsive
GoldStarPro Dec 8, 2023
a448be5
Edit order table format
GoldStarPro Dec 8, 2023
19e8809
add and edit category information
yuhtnguyen Dec 8, 2023
7c977dc
Update README.md
hardingadonis Dec 8, 2023
1208b64
Delete images conflict
hardingadonis Dec 8, 2023
fdd6afd
Merge pull request #84 from hardingadonis/vuong_update_readme
hardingadonis Dec 8, 2023
db23f16
add new product
yuhtnguyen Dec 8, 2023
46c0b43
Merge pull request #85 from hardingadonis/thuy_dl
yuhtnguyen Dec 8, 2023
47216ad
Finish
GoldStarPro Dec 8, 2023
f4914d2
Merge branch 'hotfix_admin' into hoang_admin_dashboard
hardingadonis Dec 8, 2023
7830da0
Merge pull request #86 from hardingadonis/hoang_admin_dashboard
GoldStarPro Dec 8, 2023
592203d
edit category
yuhtnguyen Dec 8, 2023
f516953
Update css for admin page
hardingadonis Dec 8, 2023
1ae1a4e
fix edit category
yuhtnguyen Dec 8, 2023
0dedafe
[CodeFactor] Apply fixes
code-factor Dec 8, 2023
7a9c075
Fix button exist
yuhtnguyen Dec 8, 2023
7061378
Update
hardingadonis Dec 8, 2023
e5d74a8
Merge pull request #87 from hardingadonis/hotfix_admin
yuhtnguyen Dec 8, 2023
28a9c4e
Update web.xml
hardingadonis Dec 8, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
13 changes: 13 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# These are supported funding model platforms

github: hardingadonis
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: hardingadonis
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
27 changes: 27 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: 'Build with Maven'

on: [push, pull_request]

jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]

name: 'Build with Maven'
runs-on: ${{ matrix.os }}

steps:
- name: 'Checkout repository'
uses: actions/checkout@v4

- name: 'Set up JDK 8'
uses: actions/setup-java@v3
with:
java-version: '8'
distribution: 'temurin'
architecture: 'x64'

- name: 'Build project with Maven'
run: mvn verify
62 changes: 62 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: 'Publish Miu Shop Images'

on:
workflow_run:
workflows: [Release Miu Shop]
types:
- completed
branches:
- main

jobs:
publish:
name: 'Publish Miu Shop Images'
runs-on: ubuntu-latest

if: ${{ github.event.workflow_run.conclusion == 'success' }}

permissions:
contents: read
packages: write

steps:
- name: 'Checkout repository'
uses: actions/checkout@v4

- name: 'Set up JDK 8'
uses: actions/setup-java@v3
with:
java-version: '8'
distribution: 'temurin'
architecture: 'x64'

- name: 'Build project with Maven'
run: |
mvn verify

- name: 'Get version'
id: get_version
run: |
chmod +x get_version.sh
echo "version=$(./get_version.sh)" >> $GITHUB_OUTPUT

- name: 'Login ghcr.io'
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: 'Publish Miu Shop Database'
working-directory: ${{ github.workspace }}/database
run: |
docker build . -t ghcr.io/hardingadonis/miu-shop-database:${{ steps.get_version.outputs.version }} -t ghcr.io/hardingadonis/miu-shop-database:latest
docker push ghcr.io/hardingadonis/miu-shop-database:${{ steps.get_version.outputs.version }}
docker push ghcr.io/hardingadonis/miu-shop-database:latest

- name: 'Publish Miu Shop Server'
working-directory: ${{ github.workspace }}/server
run: |
docker build . -t ghcr.io/hardingadonis/miu-shop-server:${{ steps.get_version.outputs.version }} -t ghcr.io/hardingadonis/miu-shop-server:latest
docker push ghcr.io/hardingadonis/miu-shop-server:${{ steps.get_version.outputs.version }}
docker push ghcr.io/hardingadonis/miu-shop-server:latest
36 changes: 36 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: 'Release Miu Shop'

on:
workflow_run:
workflows: [Build with Maven]
types:
- completed
branches:
- main

permissions:
contents: write

jobs:
release:
name: 'Release Miu Shop'
runs-on: ubuntu-latest

if: ${{ github.event.workflow_run.conclusion == 'success' }}

steps:
- name: 'Checkout repository'
uses: actions/checkout@v4

- name: 'Get version'
id: get_version
run: |
chmod +x get_version.sh
echo "version=$(./get_version.sh)" >> $GITHUB_OUTPUT

- name: 'Release Miu Shop'
uses: softprops/[email protected]
with:
name: 'Miu Shop ${{ steps.get_version.outputs.version }}'
tag_name: ${{ steps.get_version.outputs.version }}
generate_release_notes: true
10 changes: 10 additions & 0 deletions .imgbotconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"schedule": "daily",
"ignoredFiles": [
"src/main/webapp/assets/images/banners/*",
"src/main/webapp/assets/images/covers/*",
"src/main/webapp/assets/images/favicon/*"
],
"compressWiki": "false",
"minKBReduced": 0
}
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.

Copyright [yyyy] [name of copyright owner]
Copyright 2023 by Minh Vương

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand Down
108 changes: 106 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,106 @@
# miu-shop
Miu Shop is a website that sells M.O.I cosmetics that are written in Java.
# Miu Shop
[![build](https://github.com/hardingadonis/miu-shop/actions/workflows/build.yml/badge.svg)](https://github.com/hardingadonis/miu-shop/actions/workflows/build.yml)
[![publish](https://github.com/hardingadonis/miu-shop/actions/workflows/publish.yml/badge.svg)](https://github.com/hardingadonis/miu-shop/actions/workflows/publish.yml)
[![release](https://github.com/hardingadonis/miu-shop/actions/workflows/release.yml/badge.svg)](https://github.com/hardingadonis/miu-shop/actions/workflows/release.yml)
[![CodeFactor](https://www.codefactor.io/repository/github/hardingadonis/miu-shop/badge)](https://www.codefactor.io/repository/github/hardingadonis/miu-shop)
![GitHub top language](https://img.shields.io/github/languages/top/hardingadonis/miu-shop)
![GitHub repo size](https://img.shields.io/github/repo-size/hardingadonis/miu-shop)
![GitHub License](https://img.shields.io/github/license/hardingadonis/miu-shop)
> Miu Shop is a website that sells M.O.I cosmetics that are written in Java.


## Requirements
- JDK 8
- MySQL 8.1.0
- Tomcat 8.5
- Maven 3+


## Database
<details>
<summary>Database</summary>

<div style="margin-top: 20px">
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/database/database.svg"/>
</a>
</div>
</details>


## Preview
<details>
<summary>User page</summary>

<div style="margin-top: 20px">
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/about.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/add-address.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/cart.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/change-password.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/checkout.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/home.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/login.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/product.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/profile.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/purchase-history.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/purchase-history-detail.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/register.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/search.png"/>
</a>
<a href="https://github.com/hardingadonis/miu-shop">
<img src="preview/user/vnpay.png"/>
</a>
</div>
</details>

## Deployment
### Download `docker-compose.yml`:
```bash
curl -O https://raw.githubusercontent.com/hardingadonis/miu-shop/main/docker-compose.yml
```
### Run `docker-copmose`:
```bash
docker-compose up -d --build --force-recreate --remove-orphans --project-name miu
```
### Access `Miu Shop`:
- Open `http://localhost:80` in your browser.

## Contributors:

<a href="https://github.com/hardingadonis/miu-shop/graphs/contributors">
<img src="https://contrib.rocks/image?repo=hardingadonis/miu-shop" />
</a>


## Licenses:
- [Miu Shop](https://github.com/hardingadonis/miu-shop) is under the [Apache-2.0 license](https://github.com/hardingadonis/miu-shop/blob/main/LICENSE).
- [location_data.json](https://raw.githubusercontent.com/hardingadonis/miu-shop/main/database/location_data.json) is collected by [DiaGioiHanhChinhVN](https://github.com/kenzouno1/DiaGioiHanhChinhVN).
- [favicon](https://github.com/hardingadonis/miu-shop/blob/main/src/main/webapp/assets/images/favicon/favicon.png) is under the [flaticon](https://www.flaticon.com/free-icon/cosmetics_3194619).
- [male](https://github.com/hardingadonis/miu-shop/blob/main/src/main/webapp/assets/images/avatars/male.webp) is under the [flaticon](https://www.flaticon.com/free-icon/man_3741578).
- [female](https://github.com/hardingadonis/miu-shop/blob/main/src/main/webapp/assets/images/avatars/female.webp) is under the [flaticon](https://www.flaticon.com/free-icon/woman_3741715).
- [Login Page Cover Image](https://unsplash.com/photos/white-and-orange-plastic-bottle-7tDGb3HrITg), [About Page Cover Image](https://unsplash.com/photos/assorted-make-up-brushes-closed-up-photography-pxax5WuM7eY) are under the [Unsplash License](https://unsplash.com/license).
24 changes: 24 additions & 0 deletions database/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
FROM mysql:8.1.0

LABEL org.opencontainers.image.source=https://github.com/hardingadonis/miu-shop
LABEL org.opencontainers.image.description="Container that runs MySQL for Miu Shop"
LABEL org.opencontainers.image.licenses=Apache-2.0

LABEL [email protected]

# Copy the database schema to the container
COPY ./setup.sql /docker-entrypoint-initdb.d/setup.sql

# Set the empty password for the root user
ENV MYSQL_ALLOW_EMPTY_PASSWORD yes

# Set the default database name
ENV MYSQL_DATABASE=miu

# Set the default charset and collation
ENV LANG=C.UTF-8
ENV MYSQL_CHARSET=utf8mb4
ENV MYSQL_COLLATION=utf8mb4_general_ci

# Set the default port
EXPOSE 3306
Loading