Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modal Update #4

Open
wants to merge 83 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
83 commits
Select commit Hold shift + click to select a range
bc47292
First commit
breshlyabanid22 Feb 18, 2024
4714487
Update README.md
breshlyabanid22 Feb 19, 2024
f1bb567
Update README.md
breshlyabanid22 Feb 19, 2024
77611b6
Update README.md
breshlyabanid22 Feb 19, 2024
addaa90
Login page changes
breshlyabanid22 Feb 21, 2024
f5744e1
Login page complete
breshlyabanid22 Feb 21, 2024
d665a9e
Merge branches 'main' and 'main' of https://github.com/breshlyabanid2…
breshlyabanid22 Feb 21, 2024
dc8a3a2
Update README.md
breshlyabanid22 Feb 21, 2024
6015e83
Update README.md
breshlyabanid22 Feb 21, 2024
bb7d22b
Update README.md
breshlyabanid22 Feb 21, 2024
be253fe
Update README.md
breshlyabanid22 Feb 21, 2024
e5435c2
Login page complete 2
breshlyabanid22 Feb 21, 2024
a02ec3f
Merge branch 'main' of https://github.com/breshlyabanid22/Lucaren
breshlyabanid22 Feb 21, 2024
d92a9d2
Sign Up page complete
breshlyabanid22 Feb 21, 2024
c0d7a6f
Login page additional styles
breshlyabanid22 Feb 22, 2024
b7079a3
Login page additionals 2
breshlyabanid22 Feb 22, 2024
f71f886
Update README.md
breshlyabanid22 Feb 24, 2024
128b4ce
Update README.md
breshlyabanid22 Feb 24, 2024
fb45332
Update README.md
breshlyabanid22 Feb 24, 2024
6cc59a8
Update README.md
breshlyabanid22 Feb 26, 2024
f965781
Added an update and upload profile feature
breshlyabanid22 Mar 1, 2024
ba0de0a
Merge branch 'main' of https://github.com/breshlyabanid22/Lucaren
breshlyabanid22 Mar 1, 2024
f9d9d71
Complete user profile update feature
breshlyabanid22 Mar 1, 2024
908063d
dependencies
breshlyabanid22 Mar 2, 2024
805dc82
installing Pillow
breshlyabanid22 Mar 2, 2024
ae4bfab
added comments
breshlyabanid22 Mar 4, 2024
9160f08
Deleted the dockers(coz we will not use it)
breshlyabanid22 Mar 4, 2024
6a47eab
added gitignore
breshlyabanid22 Mar 4, 2024
73cd54e
small updates
breshlyabanid22 Mar 4, 2024
49fc6c0
removed settings.py from git's tracking
breshlyabanid22 Mar 4, 2024
19a809a
add entries to gitignore
breshlyabanid22 Mar 4, 2024
5bc6391
Delete backend/media/images/mypfp.jpg
breshlyabanid22 Mar 4, 2024
f6cdd4c
Delete backend/media/images/mypfp_jKpBXSu.jpg
breshlyabanid22 Mar 4, 2024
b10b338
Delete backend/media/images/mypfp_jKpBXSu_5DFmP1o.jpg
breshlyabanid22 Mar 4, 2024
068cc7c
Delete backend/media/images/pfp_spongebob.jpg
breshlyabanid22 Mar 4, 2024
8379156
fixed formats and warnings
breshlyabanid22 Mar 7, 2024
ff7bf81
Merge branch 'main' of https://github.com/breshlyabanid22/Lucaren
breshlyabanid22 Mar 7, 2024
8b581ab
hide the arrow on input type number
breshlyabanid22 Mar 7, 2024
c816de3
finalized the profilesettings.jsx
breshlyabanid22 Mar 8, 2024
4952cf3
more small edits
breshlyabanid22 Mar 8, 2024
f63912a
edit
breshlyabanid22 Mar 8, 2024
b589629
test update
breshlyabanid22 Mar 8, 2024
798c49d
test
breshlyabanid22 Mar 8, 2024
3449b1b
edit
breshlyabanid22 Mar 8, 2024
6a0751a
new styles to profile settings modal
breshlyabanid22 Mar 9, 2024
18a873f
profile modal update
breshlyabanid22 Mar 9, 2024
08ea866
Merge pull request #1 from breshlyabanid22/breshly
breshlyabanid22 Mar 9, 2024
63fa002
fixed logout issue
breshlyabanid22 Mar 9, 2024
969e225
Merge branch 'main' of https://github.com/breshlyabanid22/Lucaren int…
breshlyabanid22 Mar 9, 2024
75979c1
Update: Closes the modal when click outside
breshlyabanid22 Mar 9, 2024
34ed2df
Update README.md
breshlyabanid22 Mar 12, 2024
8abedd6
added car listing component
breshlyabanid22 Mar 12, 2024
7d7c91b
Merge pull request #2 from breshlyabanid22/breshly
breshlyabanid22 Mar 12, 2024
0f70560
added car listing
breshlyabanid22 Mar 12, 2024
6682cb7
Merge pull request #3 from breshlyabanid22/breshly
breshlyabanid22 Mar 12, 2024
8061168
Can add car listing to the database
breshlyabanid22 Mar 13, 2024
e4d805d
Merge pull request #4 from breshlyabanid22/breshly
breshlyabanid22 Mar 13, 2024
1ab2170
new model update
breshlyabanid22 Mar 14, 2024
fb799f0
added style to car listing form
breshlyabanid22 Mar 14, 2024
40aa62c
Car Listing Complete
breshlyabanid22 Mar 14, 2024
5dd9322
car listing table added
breshlyabanid22 Mar 15, 2024
5f5791c
Cars.jsx added
breshlyabanid22 Mar 23, 2024
6a9238e
car sorting function done
breshlyabanid22 Mar 24, 2024
b3b8f72
Car.jsx update
breshlyabanid22 Mar 24, 2024
fc535ab
car rent update
breshlyabanid22 Mar 28, 2024
0e513ef
car listing edit and delete feature
breshlyabanid22 Mar 29, 2024
6ed2897
car listing edit,delete feature
breshlyabanid22 Mar 29, 2024
235cfc7
carlisting Updates
breshlyabanid22 Mar 30, 2024
0269557
carlisting edit/delete update
breshlyabanid22 Mar 31, 2024
657ccf4
Car listings update
breshlyabanid22 Apr 3, 2024
3a7102a
added rental booking
breshlyabanid22 Apr 5, 2024
7b064a1
added RentalBooking.jsx
breshlyabanid22 Apr 9, 2024
ef33b34
added Rental Booking Details
breshlyabanid22 Apr 9, 2024
c84c5a9
added Return car form
breshlyabanid22 Apr 10, 2024
6206a0e
added FeedBack Model
breshlyabanid22 Apr 12, 2024
7df99ba
added Reviews and Ratings feature
breshlyabanid22 Apr 28, 2024
982eaf8
Reviews/Feedback feature complete
breshlyabanid22 May 1, 2024
ba740b3
update on booking details
breshlyabanid22 May 1, 2024
915d245
added star rating and changed the date posted format
breshlyabanid22 May 1, 2024
ae714a0
update to available field
breshlyabanid22 May 13, 2024
49d16c5
Home and About.js update
breshlyabanid22 May 27, 2024
dba2251
added constants, assets and components folder
breshlyabanid22 May 28, 2024
fdffd69
Deleted the images folder and remove the settings.py from gitignore
breshlyabanid22 May 29, 2024
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
  •  
  •  
  •  
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 0 additions & 2 deletions .env

This file was deleted.

27 changes: 27 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Logs
logs
*.log
npm-debug.log*
yarn-debug.log*
yarn-error.log*
pnpm-debug.log*
lerna-debug.log*

node_modules
dist
dist-ssr
*.local
#Remove the settings.py from git's tracking, so any changes made in settings.py will not be tracked
backend/venv
backend/media/images/
backend/media
# Editor directories and files
.vscode/*
!.vscode/extensions.json
.idea
.DS_Store
*.suo
*.ntvs*
*.njsproj
*.sln
*.sw?
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,24 @@
# React/DjangoRF Authentication App
# Lucaren: React-Django Web Application

Authentication app using React and Django REST framework with session authentication.

[Lucaren Set-up Guide](https://breshlyabanid22.github.io/lucaren_setup_guide/)!

## Installations

* backend
```
pip install djangorestframework
pip install django-cors-headers
pip install mysqlclient
pip install pillow
```

* frontend
```
npm install axios
npm install react-bootstrap bootstrap
npm install react-router-dom
npm install -D tailwindcss postcss autoprefixer

```

12 changes: 0 additions & 12 deletions backend/Dockerfile

This file was deleted.

Binary file added backend/backend/__pycache__/__init__.cpython-310.pyc
Binary file not shown.
Binary file added backend/backend/__pycache__/__init__.cpython-312.pyc
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added backend/backend/__pycache__/urls.cpython-310.pyc
Binary file not shown.
Binary file added backend/backend/__pycache__/urls.cpython-312.pyc
Binary file not shown.
Binary file added backend/backend/__pycache__/wsgi.cpython-310.pyc
Binary file not shown.
Binary file added backend/backend/__pycache__/wsgi.cpython-312.pyc
Binary file not shown.
51 changes: 27 additions & 24 deletions backend/backend/settings.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,4 @@
"""
Django settings for backend project.

Generated by 'django-admin startproject' using Django 4.1.4.

For more information on this file, see
https://docs.djangoproject.com/en/4.1/topics/settings/

For the full list of settings and their values, see
https://docs.djangoproject.com/en/4.1/ref/settings/
"""

from pathlib import Path
import os
Expand All @@ -21,22 +11,13 @@
# See https://docs.djangoproject.com/en/4.1/howto/deployment/checklist/

# SECURITY WARNING: keep the secret key used in production secret!
SECRET_KEY = os.getenv('SECRET_KEY')
SECRET_KEY = 'django-insecure--o+^2-knvxng9b0p=hz8g6-l-y8h15%vn7)v2luv_2#$lq_xef'

# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = os.getenv('DEBUG')
DEBUG = True

ALLOWED_HOSTS = ['*']

CORS_ALLOWED_ORIGINS = [
'http://localhost',
'http://127.0.0.1',
'http://0.0.0.0',
]

CORS_ALLOW_CREDENTIALS = True


# Application definition

INSTALLED_APPS = [
Expand All @@ -52,9 +33,9 @@
]

MIDDLEWARE = [
'corsheaders.middleware.CorsMiddleware',
'django.middleware.security.SecurityMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'corsheaders.middleware.CorsMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
Expand All @@ -64,6 +45,7 @@

ROOT_URLCONF = 'backend.urls'


TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
Expand All @@ -88,8 +70,15 @@

DATABASES = {
'default': {
'ENGINE': 'django.db.backends.sqlite3',
'NAME': BASE_DIR / 'db.sqlite3',
'ENGINE': 'django.db.backends.mysql',
'NAME': 'lucaren', #create a database in your mysql named "lucaren"
'USER': 'lucaren', #Sa inyuha basin root ang username
'PASSWORD': '', #no password akoa
'HOST': 'localhost',
'PORT': '3307', # Sa inyuha basin 3306
'OPTIONS': {
'init_command': "SET sql_mode='STRICT_TRANS_TABLES'",
},
}
}

Expand Down Expand Up @@ -142,7 +131,21 @@
STATIC_URL = 'static/'
STATIC_ROOT = '/static/'

# Change this root to your actual root in your local computer
MEDIA_ROOT = 'C:/Users/Breshly/IM2/Lucaren2/App/backend/media'

MEDIA_ROOT = os.path.join(BASE_DIR, 'media')

# Default primary key field type
# https://docs.djangoproject.com/en/4.1/ref/settings/#default-auto-field

DEFAULT_AUTO_FIELD = 'django.db.models.BigAutoField'
CSRF_COOKIE_SECURE = True


CSRF_TRUSTED_ORIGINS = [
'http://localhost:5173',
]
CORS_ALLOW_CREDENTIALS = True
CORS_ORIGIN_ALLOW_ALL = True
CSRF_COOKIE_NAME = 'csrftoken'
7 changes: 4 additions & 3 deletions backend/backend/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,9 @@
"""
from django.contrib import admin
from django.urls import path, include

from django.conf import settings
from django.conf.urls.static import static
urlpatterns = [
path('admin/', admin.site.urls),
path('api/', include('user_api.urls')),
]
path('', include('user_api.urls')),
] + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
7 changes: 0 additions & 7 deletions backend/entrypoint.sh

This file was deleted.

Binary file added backend/media/images/profile_placeholder.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added backend/media/images/profile_placeholder_small.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file added backend/user_api/__pycache__/admin.cpython-310.pyc
Binary file not shown.
Binary file added backend/user_api/__pycache__/admin.cpython-312.pyc
Binary file not shown.
Binary file added backend/user_api/__pycache__/apps.cpython-310.pyc
Binary file not shown.
Binary file added backend/user_api/__pycache__/apps.cpython-312.pyc
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added backend/user_api/__pycache__/urls.cpython-310.pyc
Binary file not shown.
Binary file added backend/user_api/__pycache__/urls.cpython-312.pyc
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
31 changes: 31 additions & 0 deletions backend/user_api/migrations/0001_initial.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Generated by Django 5.0.2 on 2024-02-13 13:45

from django.db import migrations, models


class Migration(migrations.Migration):

initial = True

dependencies = [
('auth', '0012_alter_user_first_name_max_length'),
]

operations = [
migrations.CreateModel(
name='AppUser',
fields=[
('password', models.CharField(max_length=128, verbose_name='password')),
('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')),
('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')),
('user_id', models.AutoField(primary_key=True, serialize=False)),
('email', models.EmailField(max_length=50, unique=True)),
('username', models.CharField(max_length=50)),
('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.group', verbose_name='groups')),
('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.permission', verbose_name='user permissions')),
],
options={
'abstract': False,
},
),
]
18 changes: 18 additions & 0 deletions backend/user_api/migrations/0002_appuser_is_staff.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 5.0.2 on 2024-02-19 13:12

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('user_api', '0001_initial'),
]

operations = [
migrations.AddField(
model_name='appuser',
name='is_staff',
field=models.BooleanField(default=False),
),
]
18 changes: 18 additions & 0 deletions backend/user_api/migrations/0003_appuser_user_profile.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 5.0.2 on 2024-02-26 06:31

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('user_api', '0002_appuser_is_staff'),
]

operations = [
migrations.AddField(
model_name='appuser',
name='user_profile',
field=models.ImageField(blank=True, null=True, upload_to='images/'),
),
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 5.0.2 on 2024-02-28 03:14

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('user_api', '0003_appuser_user_profile'),
]

operations = [
migrations.AddField(
model_name='appuser',
name='firstname',
field=models.CharField(blank=True, max_length=50),
),
migrations.AddField(
model_name='appuser',
name='lastname',
field=models.CharField(blank=True, max_length=50),
),
]
18 changes: 18 additions & 0 deletions backend/user_api/migrations/0005_appuser_contact.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 5.0.2 on 2024-02-28 03:44

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('user_api', '0004_appuser_firstname_appuser_lastname'),
]

operations = [
migrations.AddField(
model_name='appuser',
name='contact',
field=models.CharField(blank=True, max_length=15),
),
]
25 changes: 25 additions & 0 deletions backend/user_api/migrations/0006_carlisting.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Generated by Django 5.0.3 on 2024-03-13 14:25

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('user_api', '0005_appuser_contact'),
]

operations = [
migrations.CreateModel(
name='CarListing',
fields=[
('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('make', models.CharField(max_length=50)),
('model', models.CharField(max_length=50)),
('model_year', models.PositiveIntegerField()),
('daily_rate', models.IntegerField()),
('transmission', models.CharField(choices=[('automatic', 'Automatic'), ('manual', 'Manual')], max_length=20)),
('image_file', models.ImageField(upload_to='car_images/')),
],
),
]
18 changes: 18 additions & 0 deletions backend/user_api/migrations/0007_alter_carlisting_id.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 5.0.3 on 2024-03-28 13:28

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('user_api', '0006_carlisting'),
]

operations = [
migrations.AlterField(
model_name='carlisting',
name='id',
field=models.AutoField(primary_key=True, serialize=False),
),
]
18 changes: 18 additions & 0 deletions backend/user_api/migrations/0008_rename_id_carlisting_car_id.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Generated by Django 5.0.3 on 2024-03-28 14:11

from django.db import migrations


class Migration(migrations.Migration):

dependencies = [
('user_api', '0007_alter_carlisting_id'),
]

operations = [
migrations.RenameField(
model_name='carlisting',
old_name='id',
new_name='car_id',
),
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Generated by Django 5.0.2 on 2024-03-30 04:32

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('user_api', '0008_rename_id_carlisting_car_id'),
]

operations = [
migrations.AlterField(
model_name='carlisting',
name='image_file',
field=models.ImageField(blank=True, upload_to='car_images/'),
),
migrations.AlterField(
model_name='carlisting',
name='transmission',
field=models.CharField(choices=[('Automatic', 'automatic'), ('Manual', 'manual')], max_length=20),
),
]
Loading